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

# Retrieve a category

> Retrieves a category and its options. Not every combination of option values can be made: send the values you have decided, in any number, and each value comes back with `available`, whether some product that can be made has that value together with every value you sent for the other options.

Walk to any product without guessing, one call for each value you add:

1. Call with `selections: {}`. If the returned `selections` suits you, pass it to `products.create`.
2. Otherwise pick a value with `available: true` for an option you have not sent, add it to `selections`, and call again.
3. Repeat until `selections` suits you.

Choosing only available values never dead-ends, and every product that can be made is reachable in any order. If the values you send cannot be made together, `canManufacture` is `false`: the values you sent that are marked unavailable are the conflict, and the available values of those options are the ways out.



## OpenAPI

````yaml /openapi.json post /categories/get
openapi: 3.1.1
info:
  title: Arcade API
  version: '1'
  description: >-
    Generate patterns and order them as manufactured products. Every request is
    a POST with a JSON body.
servers:
  - url: https://platform.arcade.ai/v1
    description: Production
  - url: https://staging-platform.arcade.ai/v1
    description: Staging
security:
  - apiKey: []
tags:
  - name: Patterns
    description: Patterns you generate.
  - name: Refine
    description: Edit, recolor, crop and extend patterns.
  - name: Jobs
    description: Long-running work.
  - name: References
    description: Images that guide generation.
  - name: Models
    description: The models that generate patterns.
  - name: Categories
    description: Product types and their options.
  - name: Products
    description: Products made from your patterns.
  - name: Checkouts
    description: Checkouts for ordering products.
  - name: Orders
    description: Your orders.
paths:
  /categories/get:
    post:
      tags:
        - Categories
      summary: Retrieve a category
      description: >-
        Retrieves a category and its options. Not every combination of option
        values can be made: send the values you have decided, in any number, and
        each value comes back with `available`, whether some product that can be
        made has that value together with every value you sent for the other
        options.


        Walk to any product without guessing, one call for each value you add:


        1. Call with `selections: {}`. If the returned `selections` suits you,
        pass it to `products.create`.

        2. Otherwise pick a value with `available: true` for an option you have
        not sent, add it to `selections`, and call again.

        3. Repeat until `selections` suits you.


        Choosing only available values never dead-ends, and every product that
        can be made is reachable in any order. If the values you send cannot be
        made together, `canManufacture` is `false`: the values you sent that are
        marked unavailable are the conflict, and the available values of those
        options are the ways out.
      operationId: categories.get
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                categoryId:
                  type: string
                  minLength: 1
                  description: Category ID, from categories.list
                selections:
                  type: object
                  propertyNames:
                    type: string
                    minLength: 1
                    description: Option key, from categories.get
                  additionalProperties:
                    type: string
                    minLength: 1
                    description: Option value, from categories.get
                  description: >-
                    The values you have decided, option key to option value, in
                    any number including none; options you leave out are open
                  default: {}
              required:
                - categoryId
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  categoryId:
                    type: string
                    minLength: 1
                    description: Category ID, from categories.list
                  name:
                    type: string
                  options:
                    type: array
                    items:
                      type: object
                      properties:
                        key:
                          type: string
                          description: Option key, as used in selections
                        label:
                          type: string
                        values:
                          type: array
                          items:
                            type: object
                            properties:
                              value:
                                type: string
                              label:
                                type: string
                              isDefault:
                                type: boolean
                              available:
                                type: boolean
                                description: >-
                                  Whether some product that can be made has this
                                  value together with every value you sent for
                                  the other options
                            required:
                              - value
                              - label
                              - isDefault
                              - available
                      required:
                        - key
                        - label
                        - values
                  selections:
                    type: object
                    propertyNames:
                      type: string
                      minLength: 1
                      description: Option key, from categories.get
                    additionalProperties:
                      type: string
                      minLength: 1
                      description: Option value, from categories.get
                    description: >-
                      A complete selection that keeps every value you sent: each
                      open option takes its default where that can still be
                      made, else another available value. Pass it to
                      products.create when canManufacture is true
                  canManufacture:
                    type: boolean
                    description: >-
                      Whether selections can be made; products.create uses the
                      lowest-priced maker that can make it. False when the
                      values you sent cannot be made together, and selections
                      then fills the open options with their defaults
                required:
                  - categoryId
                  - name
                  - options
                  - selections
                  - canManufacture
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: An API key from Settings → API keys in Arcade Studio.

````