RequestBeam

Documentation

RequestBeam Docs

OpenAI Multimodal Responses

OpenAI-compatible Responses API. This endpoint uses OpenAI-style `input`, supports text, public image URLs, PDF file input, tool calls, reasoning options, and streaming parameters.

POSThttps://api.requestbeam.com/openai/responses

OpenAI-compatible Responses API. This endpoint uses OpenAI-style input, supports text, public image URLs, PDF file input, tool calls, reasoning options, and streaming parameters.

text
POST https://api.requestbeam.com/openai/responses

Authentication

All requests require Bearer Token authentication.

http
Authorization: Bearer YOUR_API_KEY

Body

modelstringrequiredDefault: gpt-5.4

Current active models with Responses support:

  • gpt-5.4
  • gpt-5.5
  • gpt-5.6-sol
  • gpt-5.6-terra
  • gpt-6-astra

See the Model Catalog for the models visible to the current API Key.

inputstring | object[]

Input content. Required unless a non-empty previous_response_id is provided. Omitting both fields or using an invalid input type returns 400 before billing.

Supported forms:

  • A string, equivalent to one user text input.
  • An array of input items for conversation history, multimodal input, and tool call results.

Each object in the input array may contain the following fields:

typestring

Input item type.

Common values:

  • message: a message input.
  • function_call_output: the result of a function tool call.
rolestring

Role when type=message.

Common values:

  • developer
  • system
  • user
  • assistant
contentstring | object[]

Message content.

Use a content-block array for multimodal requests. Content blocks support:

typestring

Content block type.

Currently supported:

  • input_text
  • input_image
  • input_file
textstring

Text content when type=input_text.

image_urlstring

Public image URL when type=input_image.

Only publicly accessible http:// or https:// image URLs are supported. Base64 Data URLs such as data:image/...;base64,... are not supported.

detailstringDefault: auto

Image detail level when type=input_image.

Common values:

  • auto
  • low
  • high
file_datastring

File content Data URL when type=input_file. PDFs may use data:application/pdf;base64,....

filenamestring

File name when type=input_file.

instructionsstring

System or developer instructions inserted into the model context.

max_output_tokensinteger

Optional maximum output tokens, as a positive integer. Omit this field to use the upstream default for the selected model. Depending on the model, the budget may include reasoning tokens as well as final text. A small budget can truncate the answer or be exhausted before final text; increasing it may increase cost.

streambooleanDefault: false

Whether to stream the response.

  • false: return one complete response
  • true: return OpenAI Responses-style SSE events
temperaturenumberDefault: 1.0

Sampling temperature, usually from 0 to 2.

top_pnumberDefault: 1.0

Nucleus sampling parameter, usually from 0 to 1.

textobject

Text output configuration.

text.formatobject

Text format configuration, such as { "type": "text" } or a JSON schema.

text.verbositystring

Output verbosity, such as low, medium, or high. Support depends on the selected model.

toolsobject[]

Tool definitions. Availability depends on the selected model and available features.

tool_choicestring | object

Tool selection policy.

parallel_tool_callsboolean

Whether parallel tool calls are allowed.

reasoningobject

Reasoning-related options.

includestring[]

Extra fields to include in the response.

prompt_cache_keystring

Prompt cache key for prompt cache reuse.

prompt_cache_retentionstring

Prompt cache retention policy. Supported values depend on the selected model and available features.

safety_identifierstring

Stable end-user identifier for safety controls.

storeboolean

Whether response state may be stored.

Model Parameter Differences

  • Native OpenAI-compatible Responses forwarding preserves top_p in the upstream request; validation and sampling behavior depend on the selected model and upstream. The checks on 2026-09-26 accepted top_p: 0.9 for gpt-5.5, gpt-5.6-sol, and gpt-5.6-terra. Acceptance and forwarding do not prove a sampling effect or guarantee support for other values, models, or later requests. Start with a minimal request.
  • Support on this page applies only to the regular /openai/responses endpoint. It does not imply that the same model supports /openai/responses/compact, WebSocket, or stateful previous_response_id.
  • The five GPT models listed above currently have no verified Compact channel. Compact requests are rejected before billing when no explicitly enabled channel is available. Ordinary Responses and Responses WebSocket remain available.

Request Examples

The examples below provide input. A continuation may omit input when it provides a valid previous_response_id and the selected channel supports stateful continuation. A response ID does not enable that capability on an unsupported channel. Tool results remain valid input items, including function_call_output.

Text

json
{
  "model": "gpt-5.4",
  "input": "Hello, introduce yourself in one sentence."
}

Codex CLI-Style Parameters

json
{
  "model": "gpt-5.5",
  "input": "Reply with READY only.",
  "reasoning": {
    "effort": "xhigh"
  },
  "store": false,
  "text": {
    "verbosity": "low"
  },
  "stream": true
}

Image Understanding

json
{
  "model": "gpt-5.4",
  "input": [
    {
      "type": "message",
      "role": "user",
      "content": [
        {
          "type": "input_text",
          "text": "What is in this image?"
        },
        {
          "type": "input_image",
          "image_url": "https://example.com/cat.png",
          "detail": "high"
        }
      ]
    }
  ]
}

File Input

Use file_data plus filename to submit PDF content. file_data must be a complete Data URL.

json
{
  "model": "gpt-5.4",
  "input": [
    {
      "type": "message",
      "role": "user",
      "content": [
        {
          "type": "input_text",
          "text": "Summarize the key points in this PDF."
        },
        {
          "type": "input_file",
          "file_data": "data:application/pdf;base64,JVBERi0xLjQKJc...",
          "filename": "report.pdf"
        }
      ]
    }
  ]
}

Image and File Input

json
{
  "model": "gpt-5.4",
  "input": [
    {
      "type": "message",
      "role": "user",
      "content": [
        {
          "type": "input_text",
          "text": "Give three conclusions based on the image and attachment."
        },
        {
          "type": "input_image",
          "image_url": "https://example.com/chart.png",
          "detail": "high"
        },
        {
          "type": "input_file",
          "file_data": "data:application/pdf;base64,JVBERi0xLjQKJc...",
          "filename": "notes.pdf"
        }
      ]
    }
  ]
}

Streaming Output

json
{
  "model": "gpt-5.4",
  "stream": true,
  "input": [
    {
      "role": "user",
      "content": [
        {
          "type": "input_text",
          "text": "Explain this diagram step by step."
        },
        {
          "type": "input_image",
          "image_url": "https://example.com/diagram.png"
        }
      ]
    }
  ]
}

Response

Non-streaming responses follow OpenAI Responses style. Actual fields may vary with selected model capabilities.

idstring

Unique response identifier.

objectstring

Response object type, usually response.

created_atinteger

Creation timestamp.

modelstring

Actual model used.

outputobject[]

Output item list. Common items include message, function_call, and tool-related output.

usageobject

Token usage statistics, such as input_tokens, output_tokens, and total_tokens.

Success Example

json
{
  "id": "resp_123",
  "object": "response",
  "created_at": 1766534400,
  "model": "gpt-5.4",
  "output": [
    {
      "type": "message",
      "role": "assistant",
      "content": [
        {
          "text": "The image shows a cat, and the attachment is a document about pet care."
        }
      ]
    }
  ],
  "usage": {
    "input_tokens": 128,
    "output_tokens": 42,
    "total_tokens": 170
  }
}

Streaming Response

When stream=true, the endpoint returns Server-Sent Events.

text
event: response.output_text.delta
data: {"type":"response.output_text.delta","delta":"The image"}

event: response.completed
data: {"type":"response.completed","response":{"id":"resp_123"}}

Read events until response.completed or the connection closes.

Error Response

See Error Codes and Troubleshooting for the full code reference, protocol differences, and diagnostic steps.

Platform-generated HTTP errors use the flat fields below instead of an error wrapper. Some upstream errors may retain their original structure; errors inside an already-started SSE stream do not follow this HTTP response example.

json
{
  "code": 40000,
  "message": "Insufficient credit. Required: 30000, Available: 20000",
  "type": "api_error"
}

Notes

  • The Responses endpoint uses input, not messages. If your client only sends messages, use /openai/v1/chat/completions.
  • Image input uses input_image; image_url must be a public http:// or https:// URL. Base64 Data URLs are not supported for images.
  • File input uses input_file. For PDFs, use file_data plus filename; file_data should be a complete data:application/pdf;base64,... URL.
  • Audio input/output, image generation tools, file search, and other advanced capabilities depend on the selected model and available features.
  • The fields listed on this page form the current public Responses request contract; do not assume unlisted fields are available.
  • /openai/responses is the recommended public path.
  • /v1/responses follows the same public request and response contract.
  • /compat/v1/responses follows the same public request and response contract.
  • /openai/v1/responses follows the same public request and response contract.