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

# Get a generation

> Retrieve a generation's status, outputs, or failure details.

<Note>This feature is in beta. During beta, endpoint schemas and behavior may change or be removed.</Note>


## OpenAPI

````yaml https://www.rainbrand.com/api/v1/spec.json get /generations/{id}
openapi: 3.1.1
info:
  title: Rainbrand API
  version: 1.0.0
servers:
  - url: https://www.rainbrand.com/api/v1
security:
  - apiKey: []
  - bearer: []
tags:
  - name: Uploads
    description: >-
      Stage private local files for brand sources, the Library, and other
      supported operations.
  - name: Account
    description: >-
      Inspect the authenticated account — profile, credit balance, and
      accessible workspaces.
  - name: Brands
    description: Manage brands and brand identity.
  - name: Library
    description: Add, list, and remove a brand's images, video, and audio.
  - name: Images
    description: Retrieve and manage images.
  - name: Videos
    description: Retrieve and manage video files.
  - name: Audio
    description: Retrieve and manage audio files.
  - name: Briefs
    description: Get brand guidance and selected assets for a specific task.
  - name: Models
    description: Find available models and check their inputs.
  - name: Generations
    description: Create and retrieve model generations.
  - name: Reviews
    description: >-
      Check an asset against a brand's color, typography, logo, and copy
      guidance.
paths:
  /generations/{id}:
    get:
      tags:
        - Generations
      summary: Get a generation
      description: Retrieve a generation's status, outputs, or failure details.
      operationId: generations.get
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            description: Generation ID returned when the request started.
        - name: wait
          in: query
          schema:
            anyOf:
              - type: boolean
              - enum:
                  - '0'
                  - '1'
                  - 'true'
                  - 'false'
                type: string
            default: false
            description: >-
              Wait for completion or failure. A timeout leaves generation
              running.
          allowEmptyValue: true
          allowReserved: true
        - name: timeout
          in: query
          schema:
            type: integer
            minimum: 1
            maximum: 295
            default: 120
            description: Maximum wait in seconds when wait is true.
          allowEmptyValue: true
          allowReserved: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: uuid
                        description: Generation ID returned when the request started.
                      status:
                        enum:
                          - pending
                          - generating
                          - completed
                          - failed
                        type: string
                        description: Current generation status.
                      type:
                        type: string
                        description: >-
                          Requested output type. Known values: image, video,
                          audio, svg; more may be added.
                      model:
                        type: string
                        description: Exact model ID returned by GET /models.
                      brandSessionId:
                        type: string
                        format: uuid
                        description: Brand the generation belongs to.
                      outputs:
                        type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                              format: uuid
                            type:
                              type: string
                            url:
                              type: string
                              format: uri
                            available:
                              type: boolean
                            mimeType:
                              type: string
                          required:
                            - type
                            - available
                            - mimeType
                        description: >-
                          Output files in provider order. Empty until the
                          generation completes.
                      failure:
                        anyOf:
                          - type: object
                            properties:
                              code:
                                const: upstream_failed
                              message:
                                type: string
                              retryable:
                                type: boolean
                                description: >-
                                  True when a new attempt with the same request
                                  may succeed; if you sent an Idempotency-Key,
                                  use a new key for it. False when the request
                                  must change first, or when a video may still
                                  be finishing and already billed.
                              providerMessage:
                                anyOf:
                                  - type: string
                                  - type: 'null'
                                description: >-
                                  The provider's explanation of why it rejected
                                  the request, with links and secrets removed.
                                  Null when the provider gave none, or when the
                                  failure concerns Rainbrand's own account or a
                                  provider-side error. Its wording can change.
                            required:
                              - code
                              - message
                              - retryable
                              - providerMessage
                          - type: 'null'
                        description: >-
                          Failure details, or null when generation has not
                          failed.
                      createdAt:
                        type: string
                        format: date-time
                        description: Time the generation was created.
                    required:
                      - id
                      - status
                      - type
                      - model
                      - brandSessionId
                      - outputs
                      - failure
                      - createdAt
                required:
                  - data
        '401':
          description: '401'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerationsGet401ErrorResponse'
        '403':
          description: '403'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerationsGet403ErrorResponse'
        '404':
          description: '404'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerationsGet404ErrorResponse'
        '429':
          description: '429'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerationsGet429ErrorResponse'
          headers:
            Retry-After:
              description: >-
                Seconds until the applicable request or operation limit resets.
                Present when the limiter can calculate the delay.
              schema:
                type: integer
                minimum: 0
components:
  schemas:
    GenerationsGet401ErrorResponse:
      type: object
      properties:
        error:
          allOf:
            - $ref: '#/components/schemas/ApiError'
            - anyOf:
                - type: object
                  properties:
                    code:
                      const: UNAUTHORIZED
                    status:
                      const: 401
                    message:
                      type: string
                      default: Invalid or missing API credentials
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      type: string
                    status:
                      type: integer
                    message:
                      type: string
                    data: {}
                  required:
                    - code
                    - status
                    - message
      required:
        - error
    GenerationsGet403ErrorResponse:
      type: object
      properties:
        error:
          allOf:
            - $ref: '#/components/schemas/ApiError'
            - anyOf:
                - type: object
                  properties:
                    code:
                      const: ACCOUNT_BANNED
                    status:
                      const: 403
                    message:
                      type: string
                      default: This account has been suspended.
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      const: FORBIDDEN
                    status:
                      const: 403
                    message:
                      type: string
                      default: Plan upgrade required
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      type: string
                    status:
                      type: integer
                    message:
                      type: string
                    data: {}
                  required:
                    - code
                    - status
                    - message
      required:
        - error
    GenerationsGet404ErrorResponse:
      type: object
      properties:
        error:
          allOf:
            - $ref: '#/components/schemas/ApiError'
            - anyOf:
                - type: object
                  properties:
                    code:
                      const: GENERATION_NOT_FOUND
                    status:
                      const: 404
                    message:
                      type: string
                      default: Generation not found
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      const: BRAND_NOT_FOUND
                    status:
                      const: 404
                    message:
                      type: string
                      default: Brand not found
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      type: string
                    status:
                      type: integer
                    message:
                      type: string
                    data: {}
                  required:
                    - code
                    - status
                    - message
      required:
        - error
    GenerationsGet429ErrorResponse:
      type: object
      properties:
        error:
          allOf:
            - $ref: '#/components/schemas/ApiError'
            - anyOf:
                - type: object
                  properties:
                    code:
                      const: TOO_MANY_REQUESTS
                    status:
                      const: 429
                    message:
                      type: string
                      default: Rate limit exceeded
                    data: {}
                  required:
                    - code
                    - status
                    - message
                - type: object
                  properties:
                    code:
                      type: string
                    status:
                      type: integer
                    message:
                      type: string
                    data: {}
                  required:
                    - code
                    - status
                    - message
      required:
        - error
    ApiError:
      type: object
      properties:
        code:
          type: string
        status:
          type: integer
        message:
          type: string
        data: {}
      required:
        - code
        - status
        - message
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: 'Rainbrand API key, for example `x-api-key: bloom_sk_...`.'
    bearer:
      type: http
      scheme: bearer
      description: >-
        Rainbrand API key (`Bearer bloom_sk_...`) or Rainbrand OAuth access
        token.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.