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

# Responses

> Use DeerAPI to call the Responses endpoint with request details, response details, examples, and an OpenAPI playground.

## Overview

Use this endpoint to call the Responses workflow through DeerAPI. The API reference on this page shows the request schema, response schema, authentication requirements, and runnable examples for the configured endpoint.

## Before you start

Use the DeerAPI base URL and pass your API Key in the `Authorization` header:

```text theme={null}
https://api.deerapi.com
```

```text theme={null}
Authorization: Bearer $DEERAPI_KEY
```

## Model selection

Choose a current model ID from the [live pricing page](https://api.deerapi.com/pricing). Model availability changes over time, so avoid copying a model ID from an old project without checking the live list first.

## Implementation notes

* Use the OpenAPI playground for the exact request fields accepted by this endpoint.
* Keep API Keys on the server side when you build production applications.
* Log the request ID from failed calls so support can investigate the request.
* Retry `429`, `500`, and `503` responses with exponential backoff.


## OpenAPI

````yaml /api/openapi/text/openai/post-responses.openapi.json POST /v1/responses
openapi: 3.1.0
info:
  title: Responses API
  version: 1.0.0
servers:
  - url: https://api.deerapi.com
security:
  - bearerAuth: []
paths:
  /v1/responses:
    post:
      summary: Responses
      operationId: responses
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: Use this field according to the endpoint schema.
              additionalProperties: true
              required:
                - input
              properties:
                model:
                  type: string
                  description: Use this field according to the endpoint schema.
                  default: gpt-5.4
                input:
                  type:
                    - string
                    - array
                  description: Use this field according to the endpoint schema.
                  items:
                    type: object
                    required:
                      - role
                      - content
                    properties:
                      role:
                        type: string
                        description: Use this field according to the endpoint schema.
                      content:
                        type:
                          - string
                          - array
                        description: Use this field according to the endpoint schema.
                        items:
                          type: object
                          properties:
                            type:
                              type: string
                              description: Use this field according to the endpoint schema.
                            text:
                              type: string
                              description: Use this field according to the endpoint schema.
                            image_url:
                              type: string
                              description: Use this field according to the endpoint schema.
                            file_url:
                              type: string
                              description: Use this field according to the endpoint schema.
                  default: Sample value
                instructions:
                  type: string
                  description: Use this field according to the endpoint schema.
                stream:
                  type: boolean
                  description: Use this field according to the endpoint schema.
                background:
                  type: boolean
                  description: Use this field according to the endpoint schema.
                previous_response_id:
                  type: string
                  description: Use this field according to the endpoint schema.
                conversation:
                  description: Use this field according to the endpoint schema.
                temperature:
                  type: number
                  description: Use this field according to the endpoint schema.
                  minimum: 0
                  maximum: 2
                max_output_tokens:
                  type: integer
                  description: Use this field according to the endpoint schema.
                top_p:
                  type: number
                  description: Use this field according to the endpoint schema.
                  minimum: 0
                  maximum: 1
                reasoning:
                  type: object
                  description: Use this field according to the endpoint schema.
                  properties:
                    effort:
                      type: string
                      description: Use this field according to the endpoint schema.
                      enum:
                        - none
                        - minimal
                        - low
                        - medium
                        - high
                        - xhigh
                    generate_summary:
                      type: string
                      description: Use this field according to the endpoint schema.
                      enum:
                        - auto
                        - concise
                        - detailed
                    summary:
                      type: string
                      description: Use this field according to the endpoint schema.
                      enum:
                        - auto
                        - concise
                        - detailed
                text:
                  type: object
                  description: Use this field according to the endpoint schema.
                  properties:
                    format:
                      type: object
                      description: Use this field according to the endpoint schema.
                      properties:
                        type:
                          type: string
                          description: Use this field according to the endpoint schema.
                        name:
                          type: string
                          description: Use this field according to the endpoint schema.
                        schema:
                          type: object
                          description: Use this field according to the endpoint schema.
                    verbosity:
                      type: string
                      description: Use this field according to the endpoint schema.
                      enum:
                        - low
                        - medium
                        - high
                tools:
                  type: array
                  description: Use this field according to the endpoint schema.
                  items:
                    type: object
                    properties:
                      type:
                        type: string
                        description: Use this field according to the endpoint schema.
                      name:
                        type: string
                        description: Use this field according to the endpoint schema.
                      description:
                        type: string
                        description: Use this field according to the endpoint schema.
                      parameters:
                        type: object
                        description: Use this field according to the endpoint schema.
                tool_choice:
                  description: Use this field according to the endpoint schema.
                parallel_tool_calls:
                  type: boolean
                  description: Use this field according to the endpoint schema.
                include:
                  type: array
                  description: Use this field according to the endpoint schema.
                  items:
                    type: string
                metadata:
                  type: object
                  description: Use this field according to the endpoint schema.
                truncation:
                  type: string
                  description: Use this field according to the endpoint schema.
                  enum:
                    - auto
                    - disabled
                store:
                  type: boolean
                  description: Use this field according to the endpoint schema.
                prompt_cache_key:
                  type: string
                  description: Use this field according to the endpoint schema.
                prompt_cache_retention:
                  type: string
                  description: Use this field according to the endpoint schema.
                  enum:
                    - in-memory
                    - 24h
                max_tool_calls:
                  type: integer
                  description: Use this field according to the endpoint schema.
                top_logprobs:
                  type: integer
                  description: Use this field according to the endpoint schema.
                  minimum: 0
                  maximum: 20
                stream_options:
                  type: object
                  description: Use this field according to the endpoint schema.
                  properties:
                    include_obfuscation:
                      type: boolean
                      description: Use this field according to the endpoint schema.
                prompt:
                  type: object
                  description: Use this field according to the endpoint schema.
                  properties:
                    id:
                      type: string
                      description: Use this field according to the endpoint schema.
                    variables:
                      type: object
                      description: Use this field according to the endpoint schema.
                      additionalProperties: true
                    version:
                      type: string
                      description: Use this field according to the endpoint schema.
                safety_identifier:
                  type: string
                  description: Use this field according to the endpoint schema.
                service_tier:
                  type: string
                  description: Use this field according to the endpoint schema.
                  enum:
                    - auto
                    - default
                    - flex
                    - priority
                user:
                  type: string
                  description: Use this field according to the endpoint schema.
                  deprecated: true
              default:
                model: gpt-5.4
                input: Write a short welcome message.
            examples:
              Text_Input:
                summary: Responses API
                value:
                  model: gpt-5.4
                  input: Write a short welcome message.
              Multi_Turn_Continuation:
                summary: Responses API
                value:
                  model: gpt-5-mini
                  previous_response_id: resp_abc123
                  input: Write a short welcome message.
              Structured_JSON:
                summary: Responses API
                value:
                  model: gpt-5-mini
                  input: Write a short welcome message.
                  text:
                    format:
                      type: json_schema
                      name: benefit_card
                      schema:
                        type: object
                        properties:
                          name:
                            type: string
                          summary:
                            type: string
                        required:
                          - name
                          - summary
                        additionalProperties: false
              Tool_Calling:
                summary: Responses API
                value:
                  model: gpt-4.1
                  input: Write a short welcome message.
                  tools:
                    - type: function
                      name: get_weather
                      description: Use this field according to the endpoint schema.
                      parameters:
                        type: object
                        properties:
                          city:
                            type: string
                        required:
                          - city
                  tool_choice: auto
            example:
              model: gpt-5.4
              input: Write a short welcome message.
      responses:
        '200':
          description: Use this field according to the endpoint schema.
          content:
            application/json:
              schema:
                type: object
                required:
                  - id
                  - object
                  - created_at
                  - status
                  - background
                  - content_filters
                  - error
                  - incomplete_details
                  - instructions
                  - max_output_tokens
                  - max_tool_calls
                  - model
                  - output
                  - parallel_tool_calls
                  - previous_response_id
                  - prompt_cache_key
                  - reasoning
                  - safety_identifier
                  - service_tier
                  - store
                  - temperature
                  - text
                  - tool_choice
                  - tools
                  - top_logprobs
                  - top_p
                  - truncation
                  - usage
                  - user
                  - metadata
                properties:
                  id:
                    type: string
                    description: Use this field according to the endpoint schema.
                  object:
                    type: string
                    description: Use this field according to the endpoint schema.
                  created_at:
                    type: integer
                  status:
                    type: string
                  background:
                    type: boolean
                  content_filters:
                    type: 'null'
                  error:
                    type: 'null'
                  incomplete_details:
                    type: 'null'
                  instructions:
                    type: 'null'
                  max_output_tokens:
                    type: 'null'
                  max_tool_calls:
                    type: 'null'
                  model:
                    type: string
                    description: Use this field according to the endpoint schema.
                  output:
                    type: array
                    description: Use this field according to the endpoint schema.
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        type:
                          type: string
                        status:
                          type: string
                        content:
                          type: array
                          items:
                            type: object
                            properties:
                              type:
                                type: string
                              annotations:
                                type: array
                                items:
                                  type: string
                              logprobs:
                                type: array
                                items:
                                  type: string
                              text:
                                type: string
                        role:
                          type: string
                        phase:
                          type: string
                          description: Use this field according to the endpoint schema.
                  output_text:
                    type:
                      - string
                      - 'null'
                    description: Use this field according to the endpoint schema.
                  parallel_tool_calls:
                    type: boolean
                  previous_response_id:
                    type: 'null'
                  prompt_cache_key:
                    type: 'null'
                  reasoning:
                    type: object
                    required:
                      - effort
                      - summary
                    properties:
                      effort:
                        description: Use this field according to the endpoint schema.
                      summary:
                        description: Use this field according to the endpoint schema.
                  safety_identifier:
                    type: 'null'
                  service_tier:
                    type: string
                  store:
                    type: boolean
                  temperature:
                    type: integer
                  text:
                    type: object
                    required:
                      - format
                      - verbosity
                    properties:
                      format:
                        type: object
                        required:
                          - type
                        properties:
                          type:
                            type: string
                      verbosity:
                        type: string
                  tool_choice:
                    type: string
                  tools:
                    type: array
                    items:
                      type: string
                  top_logprobs:
                    type: integer
                  top_p:
                    type: integer
                  truncation:
                    type: string
                  usage:
                    type: object
                    description: Use this field according to the endpoint schema.
                    required:
                      - input_tokens
                      - input_tokens_details
                      - output_tokens
                      - output_tokens_details
                      - total_tokens
                    properties:
                      input_tokens:
                        type: integer
                      input_tokens_details:
                        type: object
                        required:
                          - cached_tokens
                        properties:
                          cached_tokens:
                            type: integer
                      output_tokens:
                        type: integer
                      output_tokens_details:
                        type: object
                        required:
                          - reasoning_tokens
                        properties:
                          reasoning_tokens:
                            type: integer
                      total_tokens:
                        type: integer
                        description: Use this field according to the endpoint schema.
                  user:
                    description: Use this field according to the endpoint schema.
                  metadata:
                    type: object
                    properties: {}
                    additionalProperties: true
      x-codeSamples:
        - lang: Shell
          label: cURL
          source: |
            curl https://api.deerapi.com/v1/responses \
              -H "Content-Type: application/json" \
              -H "Authorization: Bearer $DEERAPI_KEY" \
              -d '{
                "model": "gpt-5.4",
                "input": "Write a short welcome message."
              }'
        - lang: Python
          label: requests
          source: |
            import os
            import requests

            url = "https://api.deerapi.com/v1/responses"
            headers = {
                "Authorization": "Bearer " + os.environ["DEERAPI_KEY"],
                "Content-Type": "application/json",
            }
            payload = {
              "model": "gpt-5.4",
              "input": "Write a short welcome message."
            }

            response = requests.post(url, headers=headers, json=payload)
            print(response.json())
        - lang: JavaScript
          label: fetch
          source: >
            const response = await fetch("https://api.deerapi.com/v1/responses",
            {
              method: "POST",
              headers: {
                Authorization: `Bearer ${process.env.DEERAPI_KEY}`,
                "Content-Type": "application/json",
              },
              body: JSON.stringify({
                "model": "gpt-5.4",
                "input": "Write a short welcome message."
              }),
            });


            console.log(await response.json());
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Use a DeerAPI API Key as a Bearer token.

````