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

# Active Subscription

> This method allows you to check if the authenticated bearer token (`Authorization: Bearer <API_KEY>`) has access to Remapdb’s API.



## OpenAPI

````yaml /openapi.json get /subscription
openapi: 3.0.0
info:
  title: Remapdb REST API Documentation
  description: >
    Vehicle Tuning Database API - For Tuning services and Tuners.


    Access comprehensive vehicle details, including types, manufacturers,
    models, engines, ECU and TCU info, tuning tools, dyno charts, and available
    tuning or remap stages with their performance gains.
  termsOfService: https://remapdb.com/terms
  contact:
    name: Remapdb.com
    url: https://remapdb.com
  version: '1.0'
  x-logo:
    url: https://cdn.remapdb.com/logos/remapdb-logo-default-full-light.svg
    altText: Remapdb REST API Documentation
servers:
  - url: https://api.remapdb.com/v1
security:
  - bearerAuth: []
tags:
  - name: Response and Errors
    description: >
      - API will always respond with json, content type: **application/json**.

      - Successfull response will return HTTP **2XX** ***(Success)*** response
      code.

      - Error response will return either HTTP **4XX** ***(Client Error)*** or
      HTTP **5XX** ***(Server Error)***.


      On error, API will return error object. It will contain the appropriate
      error **code** *(integer)* and a **message** *(string)*.

      The HTTP response code will be the same as the error code.


      Error Schema:

      ```json json_schema

      {
        "type": "object",
        "properties": {
          "code": {
            "type": "integer"
          },
          "message": {
            "type": "string"
          }
        }
      }

      ```


      Error Example:

      ```json http

      {
        "code": 404,
        "message": "Method doesnt exist."
      }

      ```
    x-traitTag: true
  - name: Language
    description: >
      All API methods accept custom language. It can be set via the
      **"Accept-Language"** header. Content of the header should be the code of
      the language you are requesting.


      #### Available languages:

      Code | Name

      ---------|----------
       `bg` | Bulgarian
       `da` | Danish
       `de` | German
       `en` | English **(default)**
       `es` | Spanish
       `et` | Estonian
       `fi` | Finnish
       `fr` | French
       `hr` | Croatian
       `it` | Italian
       `lt` | Lithuanian
       `lv` | Latvian
       `nb` | Norwegian Bokmål
       `nl` | Dutch
       `nn` | Norwegian Nynorsk
       `pt` | Portuguese
       `ru` | Russian
       `sv` | Swedish
       `tr` | Turkish
       `zs` | Chinese

      If no "accept-language" header is set, the API will use the default
      language - English.


      Following example shows how to set the language to Dutch (`nl`) using
      curl:

      ```json http

      curl 'https://api.remapdb.com/v1/search?query=audi' \

      --header 'Accept-Language: nl'

      ```
    x-traitTag: true
  - name: Rate Limits
    description: >
      To ensure optimal service performance and prevent abuse, this API enforces
      rate limiting.
        - Rate limits apply to all API methods.
        - Limits are tied to each API key and subscription plan and reset every minute.
        - If the rate limit is exceeded, the API will return error code **401** with the message: **“This API key has reached the time limit for this method”**.
    x-traitTag: true
  - name: Client SDKs
    description: >
      Remapdb offers OpenAPI v3 specification which can be used with any
      OpenAPI/Swagger client generator to generate your own client SDK.

      Download OpenAPI specification:
      [https://docs.remapdb.com/openapi.json](https://docs.remapdb.com/openapi.json).



      Following SDK's are automatically generated:

      Language | Link

      ----------|----------

      PHP |
      [https://github.com/remapdb-api/remapdb-php-sdk](https://github.com/remapdb-api/remapdb-php-sdk)

      JavaScript |
      [https://github.com/remapdb-api/remapdb-js-sdk](https://github.com/remapdb-api/remapdb-js-sdk)
    x-traitTag: true
  - name: Subscription
    description: >
      Most of the API methods require an active API subscription. The following
      method allows you to obtain information about your current API
      subscription.


      More info about Remapdb's API subscription can be found here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)
    x-displayName: API Subscription
  - name: Types
    description: >
      Obtain information about the vehicle types. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**
    x-displayName: Vehicle Types
  - name: Manufacturers
    description: >
      Obtain information about vehicle manufacturers. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**
  - name: Models
    description: >
      Obtain information about vehicle models. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**
  - name: Generations
    description: >
      Obtain information about model generations. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**      
  - name: Engines
    description: >
      Obtain information about vehicle engines. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**     
  - name: Search
    description: >
      Searches through manufacturers, models, generations and engines. 


      **Active API subscription required. Get it here:
      [https://app.remapdb.com/api](https://app.remapdb.com/api)**
paths:
  /subscription:
    get:
      tags:
        - Subscription
      summary: Active Subscription
      description: >-
        This method allows you to check if the authenticated bearer token
        (`Authorization: Bearer <API_KEY>`) has access to Remapdb’s API.
      operationId: check_subscription
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/subscription'
              examples:
                Active subscription:
                  value:
                    api_key: string
                    scopes:
                      - vdb_read
                    calls_limit: 60
                    created: '2024-12-04T08:05:15+00:00'
                    subscription:
                      id: 0
                      start_date: '2024-12-04T08:05:15+00:00'
                      end_date: '2028-12-04T08:05:15+00:00'
                      api_access: true
                      is_active: true
                Inactive subscription:
                  value:
                    api_key: string
                    scopes:
                      - vdb_read
                    calls_limit: 60
                    created: '2022-12-04T08:05:15+00:00'
                    subscription:
                      id: 0
                      start_date: '2022-12-04T08:05:15+00:00'
                      end_date: '2023-12-04T08:05:15+00:00'
                      api_access: true
                      is_active: false
        '401':
          $ref: '#/components/responses/error_401'
        '403':
          $ref: '#/components/responses/error_403'
        '404':
          $ref: '#/components/responses/error_404'
        '406':
          $ref: '#/components/responses/error_406'
        '429':
          $ref: '#/components/responses/error_429'
        '500':
          $ref: '#/components/responses/error_500'
        default:
          $ref: '#/components/responses/error_default'
      security:
        - bearerAuth: []
components:
  schemas:
    subscription:
      additionalProperties: false
      properties:
        api_key:
          description: >-
            The API key used as the bearer token in `Authorization: Bearer
            <API_KEY>`.
          maxLength: 2048
          pattern: ^[^\u0000-\u001F\u007F]*$
          type: string
        calls_limit:
          description: >-
            The maximum number of API requests that can be made within the
            configured access window.
          example: 60
          type: integer
          x-stoplight:
            id: rcsq3dtzpxxxm
        created:
          description: ISO 8601 date
          example: '2024-12-04T08:05:15Z'
          format: date-time
          maxLength: 2048
          pattern: ^[^\u0000-\u001F\u007F]*$
          type: string
          x-stoplight:
            id: icktjotpy6g1i
        scopes:
          description: >-
            Array with strings. Contains all the access scopes that this API key
            has.
          items:
            $ref: '#/components/schemas/access_scope'
          maxItems: 1000
          type: array
        subscription:
          $ref: '#/components/schemas/subscription_subscription'
      title: API Subscription
      type: object
      x-examples:
        Example 1:
          api_key: string
          calls_limit: 60
          created: '2024-12-04T08:05:15+00:00'
          scopes:
            - vdb_read
          subscription:
            api_access: true
            end_date: '2028-12-04T08:05:15+00:00'
            id: 0
            is_active: true
            plan_sku: max
            start_date: '2024-12-04T08:05:15+00:00'
    access_scope:
      description: The name of the access scope.
      example: vdb_read
      maxLength: 2048
      pattern: ^[^\u0000-\u001F\u007F]*$
      title: Access scope
      type: string
      x-examples:
        Example 1: vdb_read
    subscription_subscription:
      additionalProperties: false
      description: Object which contains the subscription information.
      properties:
        api_access:
          description: Can this subscription access the API.
          type: boolean
          x-stoplight:
            id: x9o01g1qugtmd
        end_date:
          description: Subscription end date. ISO 8601 format.
          example: '2024-12-04T08:05:15Z'
          format: date-time
          maxLength: 2048
          pattern: ^[^\u0000-\u001F\u007F]*$
          type: string
          x-stoplight:
            id: qzeesxg0ymgsb
          nullable: true
        id:
          description: Subscription ID
          type: integer
          x-stoplight:
            id: yod35rmvjze6b
        plan_sku:
          description: Subscription plan SKU. MCP access requires API or MAX plan.
          example: max
          nullable: true
          type: string
        is_active:
          description: Shows if description is active or not.
          type: boolean
          x-stoplight:
            id: bygnz6z7i0tlz
        start_date:
          description: Date when subscription started. ISO 8601 format.
          example: '2024-12-04T08:05:15Z'
          format: date-time
          maxLength: 2048
          pattern: ^[^\u0000-\u001F\u007F]*$
          type: string
          x-stoplight:
            id: hi3rd4wo3ilq0
          nullable: true
      type: object
    error:
      additionalProperties: false
      description: Error object
      properties:
        code:
          description: >-
            Error code. Typically it will be the same as the returtned HTTP
            response code.
          example: 404
          type: integer
        message:
          description: Error message.
          example: Not found
          maxLength: 2048
          pattern: ^[^\u0000-\u001F\u007F]*$
          type: string
          x-stoplight:
            id: iaxsxsm0kqi9n
      title: Error
      type: object
      x-examples:
        Bad Request:
          code: 400
          message: Bad request / Malformed parameter
        Internal Server Error:
          code: 500
          message: Internal Server Error
        Invalid API key:
          code: 403
          message: Invalid API key
        Method Not Found:
          code: 404
          message: Method not found
        No API Access:
          code: 401
          message: API access is not enabled for this subscription
        No active subscription:
          code: 401
          message: This method requires an active subscription.
        No permissions:
          code: 401
          message: This API key does not have enough permissions
  responses:
    error_401:
      description: Request is unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            No API access:
              value:
                code: 401
                message: API access is not enabled for this subscription.
            No enough permissions:
              value:
                code: 401
                message: This API key does not have enough permissions
            No active subscription:
              value:
                code: 401
                message: This method requires an active subscription.
            Other:
              value:
                code: 401
                message: Request unauthorized
    error_403:
      description: Request forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Invalid API key:
              value:
                code: 403
                message: Invalid API key
            Other:
              value:
                code: 403
                message: Request is forbidden
    error_404:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Not found:
              value:
                code: 404
                message: Not found
    error_406:
      description: Not Acceptable
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Not Acceptable:
              value:
                code: 406
                message: Requested response format is not acceptable
    error_429:
      description: Too Many Requests
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Rate limit exceeded:
              value:
                code: 429
                message: Too many requests
    error_500:
      description: Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Server Error:
              value:
                code: 500
                message: Internal Server Error
    error_default:
      description: Unexpected error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/error'
          examples:
            Unexpected:
              value:
                code: 500
                message: Unexpected error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: |-
        All API methods require Bearer authentication.
        Use your existing API key as the bearer token.

        Authorization header format: `Authorization: Bearer YOUR_API_KEY`.

````