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

# Category information

> This endpoint lets you retrieve the data of a specific category.




## OpenAPI

````yaml /assets/openapi/openapi-bundled.yaml get /categories/{category_id}
openapi: 3.1.0
info:
  title: Partoo Rest API
  version: v2
  license:
    name: © Copyright Partoo
    url: https://www.partoo.co/en/gtu-api/
  x-logo:
    url: >-
      https://partoo-client-images.s3.amazonaws.com/logo-partoo-restapi-white.png
  description: >
    ## Introduction

    The Partoo Rest API allows you to automate all the actions that are possible
    to do in the Partoo Web Application.


    The Partoo Rest API can be used for many different purposes:
      - Create/update/delete your businesses & users if you are a client.
      - Create/subscribe/manage organizations, businesses & users if you are a reseller.
      - Retrieve data on businesses you have access to if you are a publisher.
      - ...
servers:
  - url: https://api.partoo.co/v2
    description: Production server
  - url: https://api.sandbox.partoo.co/v2
    description: Sandbox server (dev environment for clients & partners)
security:
  - ApiKeyAuth: []
paths:
  /categories/{category_id}:
    get:
      tags:
        - Categories
      summary: Category information
      description: |
        This endpoint lets you retrieve the data of a specific category.
      operationId: getCategory
      parameters:
        - in: path
          required: true
          name: category_id
          schema:
            $ref: '#/components/schemas/CategoryId'
        - $ref: '#/components/parameters/query_category_lang'
        - $ref: '#/components/parameters/query_category_return_live'
        - $ref: '#/components/parameters/query_category_with_names'
        - $ref: '#/components/parameters/query_category_with_countries'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CategorySql'
              examples:
                with default parameters:
                  value:
                    id: 4018
                    gmb_id: gcid:wood_industry
                    name: Industrie du bois
                    state: OK
                    block_push_long_description_on_gmb: false
                    live_id: null
                with_countries=true:
                  value:
                    id: 4018
                    gmb_id: gcid:wood_industry
                    name: Industrie du bois
                    state: OK
                    block_push_long_description_on_gmb: false
                    live_id: null
                    countries:
                      - RU
                      - FR
                with_names=true:
                  value:
                    id: 4018
                    gmb_id: gcid:wood_industry
                    name: Industrie du bois
                    state: OK
                    block_push_long_description_on_gmb: false
                    live_id: null
                    names:
                      - name: Wood industry
                        lang: de
                      - name: Wood industry
                        lang: es
                      - name: Wood industry
                        lang: ar
                      - name: Industrie du bois
                        lang: fr
                      - name: Wood industry
                        lang: en
                      - name: Wood industry
                        lang: it
                      - name: Wood industry
                        lang: pt-BR
                deprecated category with return_live=false:
                  value:
                    id: 7652
                    gmb_id: gcid:bailiff
                    name: ''
                    state: DEPRECATED
                    block_push_long_description_on_gmb: false
                    live_id: gcid:business_to_business_service
                deprecated category with return_live=true:
                  value:
                    id: 6715
                    gmb_id: gcid:business_to_business_service
                    name: Services aux entreprises
                    state: OK
                    block_push_long_description_on_gmb: false
                    live_id: null
        '400':
          $ref: '#/components/responses/400'
        '401':
          $ref: '#/components/responses/401'
components:
  schemas:
    CategoryId:
      oneOf:
        - type: integer
          description: Category id
        - type: string
          description: Google's category id
      description: Category id or Google's category id
      example: 5706 or gcid:bank
    CategorySql:
      type: object
      properties:
        id:
          $ref: '#/components/schemas/CategorySqlId'
        gmb_id:
          $ref: '#/components/schemas/CategorySqlGmbId'
        name:
          $ref: '#/components/schemas/CategoryName'
        names:
          $ref: '#/components/schemas/CategorySqlNames'
        state:
          $ref: '#/components/schemas/CategorySqlState'
        block_push_long_description_on_gmb:
          $ref: '#/components/schemas/CategorySqlBlockPushLong'
        countries:
          $ref: '#/components/schemas/CategoryCountries'
        live_id:
          $ref: '#/components/schemas/CategorySqlLiveId'
    Lang:
      description: Available language in the application
      type: string
      enum:
        - fr
        - en
        - es
        - it
        - pt-br
        - de
        - ar
        - nl
        - pl
        - cs
        - ca
        - sk
        - pt
        - lv
        - ro
        - bg
        - hu
      example: fr
    CategorySqlId:
      type: integer
      description: Category id
      example: 42
    CategorySqlGmbId:
      type: string
      description: >
        Unique category id. This is the id you should pass in
        business.categories array when creating/updating a business
      example: gcid:climbing_gym
    CategoryName:
      type: string
      description: Category name in given language or user's language
      example: Cabinet d'expertise comptable
    CategorySqlNames:
      type: array
      description: |
        Category names translated for available languages

        *If `with_names` is true*
      items:
        $ref: '#/components/schemas/CategorySqlName'
    CategorySqlState:
      type: string
      description: State of category ( OK or DEPRECATED )
      example: OK
    CategorySqlBlockPushLong:
      type: boolean
      description: >-
        Boolean indicating if the business long description can be pushed to
        Google when the business belongs to this category
      example: false
    CategoryCountries:
      type: array
      items:
        type: string
      description: >
        Array of strings representing the list of country codes in which the
        category is available


        *If `with_countries` is true*
      example:
        - FR
        - GB
        - IT
        - ES
    CategorySqlLiveId:
      type:
        - string
        - 'null'
      description: >-
        Live category id to which the category is mapped (deprecated categories
        are mapped to the closest category)
      example: gcid:sport_club
    CategorySqlName:
      type: object
      properties:
        name:
          type: string
          description: Translated category name
          example: salle d'escalade
        lang:
          type: string
          description: Available language in the application
          example: FR
  parameters:
    query_category_lang:
      in: query
      name: lang
      required: false
      schema:
        $ref: '#/components/schemas/Lang'
      description: >
        Language to get the category name. If not given, the user's language is
        used.
    query_category_return_live:
      in: query
      name: return_live
      description: Return the corresponding live category instead of the requested category
      required: false
      schema:
        type: boolean
        default: false
    query_category_with_names:
      in: query
      name: with_names
      description: >
        Returns an object representing the list of translations in the available
        languages for the requested category. See example on the right.


        If `with_names` is true, the translations will appear in the field
        __names__
      required: false
      schema:
        type: boolean
        default: false
    query_category_with_countries:
      in: query
      name: with_countries
      description: >
        Returns an array of strings representing the list of country codes in
        which the requested category is available.


        If `with_countries` is true, the country list will appear in the field
        __countries__
      required: false
      schema:
        type: boolean
        default: false
  responses:
    '400':
      description: Your request is incorrect
      content:
        application/json:
          schema:
            description: |
              Error that occcurs when your request is incorrect
            properties:
              errors:
                type: object
                description: The detail of the error encountered
                properties:
                  json:
                    type: object
    '401':
      description: You are not authenticated
      content:
        application/json:
          schema:
            description: Error that occurs when you are not authenticated
            type: object
            properties:
              errors:
                type: object
                description: The detail of the error encountered
                properties:
                  authentication:
                    type: string
                    default: User not authenticated
  securitySchemes:
    ApiKeyAuth:
      description: >
        The authentication system on Partoo API is using API Key that should be
        put in the header of the request (the name of the header is `x-APIKey`).
        An api_key is linked to a user. This user's role will give you different
        access level to the API features.
      type: apiKey
      in: header
      name: x-APIKey

````