ShareAI Platform Docs

Create a text response

Use the ShareAI Responses API for stateless text generation, explicit conversation history and Responses streaming events.

View as Markdown
On this page
POST https://api.shareai.now/api/v1/responses

Generate a text response from a prompt or conversation.

Base URL
https://api.shareai.now
Authentication
Bearer API key or approved OAuth access token

Choose this API when your application uses the Responses text-message format. Supply the conversation on every request; responses are not stored for later retrieval.

Send a request#

cURL

curl --fail-with-body --request POST \
  "https://api.shareai.now/api/v1/responses" \
  -H "Authorization: Bearer $SHAREAI_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{
  "model": "YOUR_CHAT_MODEL",
  "input": "Explain semantic search in two sentences.",
  "instructions": "Use plain language.",
  "store": false,
  "stream": false
}'

Request fields#

FieldValue
modelAn available chat model allowed by your credential.
inputA nonempty string, or up to 256 text messages.
instructionsOptional system instructions prepended to the conversation.
storefalse; storing responses is unsupported.
streamfalse for JSON or true for Responses SSE events.

Continue a conversation#

Send earlier messages in input alongside the next user message. Supported roles are user, assistant, system and developer. Developer instructions use the system role internally. Message content can be text or input_text/output_text parts.

JSON

{
  "model": "YOUR_CHAT_MODEL",
  "input": [
    {
      "role": "user",
      "content": "What is semantic search?"
    },
    {
      "role": "assistant",
      "content": "It finds results by meaning rather than exact words."
    },
    {
      "role": "user",
      "content": "Give one example."
    }
  ],
  "store": false
}

Read the result#

The JSON response is a response object. Read the assistant text from output[].content[] entries with type output_text. Check the response status: completed is a finished response; incomplete can indicate a token limit. Public usage is currently null; use Console Usage to inspect processed usage.

Stream a response#

Set stream: true and parse SSE. Events include response.created, response.output_text.delta and a terminal response.completed, response.incomplete or response.failed. Append text deltas in order and handle the terminal status explicitly.

Supported subset#

This endpoint supports text generation. Stored responses, previous_response_id, retrieval/deletion, tools, image input, background requests and generation settings such as temperature are unsupported and rejected. For message-based generation settings supported by Chat Completions, use Chat Completions.

Use an OAuth access token#

Replace the API key in the Authorization header with an approved OAuth access token. The surcharge scope and accepted usage plan are required for account-funded inference. Identity-only scopes do not authorize spending. See scopes and permissions.

Last updated September 15, 2026

ShareAI Platform Docs
All documentation

Search by title or content.

Ask about this page

Choose an assistant to explore this page. You can also copy the page and paste it into your conversation.

Ask ChatGPTAsk ClaudeAsk GrokAsk ShareAI