> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pointset.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Create subscription

> Creates a subscription for a city and entity type. A scrape job is automatically enqueued.



## OpenAPI

````yaml post /v1/subscriptions
openapi: 3.1.0
info:
  title: Pointset API
  version: v1
  description: >-
    The Pointset location intelligence API. Subscribe to cities and entity types
    to receive continuously updated data about real-world places.
servers:
  - url: https://api.pointset.io
security: []
paths:
  /v1/subscriptions:
    post:
      tags:
        - Subscriptions
      summary: Create subscription
      description: >-
        Creates a subscription for a city and entity type. A scrape job is
        automatically enqueued.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                city:
                  type: string
                  minLength: 1
                  example: London
                entity_type:
                  type: string
                  minLength: 1
                  example: restaurant
                fields:
                  type: array
                  items:
                    type: string
                    minLength: 1
                  minItems: 1
                  example:
                    - phone
                    - rating
                    - website
              required:
                - city
                - entity_type
                - fields
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Subscription'
        '402':
          description: Plan limit reached
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PlanLimitError'
        '422':
          description: Validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    Subscription:
      type: object
      properties:
        id:
          type: string
          format: uuid
        account_id:
          type: string
          format: uuid
        city:
          type: string
          example: London
        entity_type:
          type: string
          example: restaurant
        fields:
          type: array
          items:
            type: string
          example:
            - phone
            - rating
            - website
        status:
          type: string
          enum:
            - active
            - paused
            - cancelled
          example: active
        data_status:
          type: string
        field_assessments:
          type: object
          additionalProperties:
            nullable: true
        created_at:
          type: string
        updated_at:
          type: string
        cancelled_at:
          type: string
          nullable: true
      required:
        - id
        - account_id
        - city
        - entity_type
        - fields
        - status
        - data_status
        - field_assessments
        - created_at
        - updated_at
        - cancelled_at
    PlanLimitError:
      type: object
      properties:
        error:
          type: string
        limit:
          type: integer
        current:
          type: integer
      required:
        - error
        - limit
        - current
    Error:
      type: object
      properties:
        error:
          type: string
      required:
        - error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````