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

# Serverless Responses

> Create responses on the verified Tensormesh Serverless host.

Use this page when you want the verified serverless responses endpoint over raw HTTP.

* Auth: `Authorization: Bearer <API_KEY>`
* Host: `https://serverless.tensormesh.ai`
* Model: pass a serverless model name in the JSON request body

If you are choosing between raw HTTP and the Python SDK, the matching SDK namespace is `client.inference.serverless.responses`.


## OpenAPI

````yaml api-reference/serverless.openapi.yaml POST /v1/responses
openapi: 3.1.0
info:
  title: Tensormesh Serverless Inference API
  version: 1.0.0
  description: |-
    OpenAI-compatible chat completions endpoint plus verified vLLM-compatible
    `/v1/models`, `/v1/completions`, `/v1/responses`, `/tokenize`,
    `/detokenize`, `/health`, and `/version` endpoints exposed through
    Tensormesh Serverless.

    Authentication: `Authorization: Bearer <API_KEY>` for `POST`
    inference requests. The public serverless host also serves
    `GET /v1/models`, `GET /health`, and `GET /version` without auth.

    If you have Control Plane access for the same Tensormesh environment,
    discover published serverless models with
    `tm billing pricing serverless list` and use the returned
    `pricing[].model` value in requests. If you are targeting a different
    serverless host override, or you only have inference credentials, get the
    model name from your Tensormesh environment before sending requests.
servers:
  - url: https://serverless.tensormesh.ai
    description: Tensormesh Serverless
security:
  - BearerAuth: []
tags:
  - name: inference.openapi_Inference
    x-displayName: Inference
paths:
  /v1/responses:
    post:
      tags:
        - inference.openapi_Inference
      summary: Create Response
      description: Create a response through the verified Serverless inference surface.
      operationId: create_serverless_response_v1_responses_post
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ResponseCreateRequest'
            example:
              model: openai/gpt-oss-20b
              input: Say hello.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ResponseCreateResponse'
            text/event-stream:
              schema:
                type: string
              example: >-
                data:
                {"id":"resp_1","object":"response","created_at":1,"model":"openai/gpt-oss-20b","output":[{"type":"message","content":[{"type":"output_text","text":"hello"}]}]}


                data: [DONE]
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
        '429':
          description: Rate Limited
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIErrorResponse'
      security:
        - BearerAuth: []
components:
  schemas:
    ResponseCreateRequest:
      type: object
      title: ResponseCreateRequest
      additionalProperties: true
      required:
        - model
        - input
      properties:
        model:
          type: string
          description: Serverless model name to use.
          example: openai/gpt-oss-20b
        input:
          description: Input passed to the responses endpoint.
        max_output_tokens:
          type: integer
          description: Optional limit for generated output tokens.
    ResponseCreateResponse:
      type: object
      title: ResponseCreateResponse
      additionalProperties: true
      required:
        - id
        - object
        - model
        - output
      properties:
        id:
          type: string
          example: resp_123
        object:
          type: string
          example: response
        created_at:
          type: integer
        model:
          type: string
        status:
          anyOf:
            - type: string
            - type: 'null'
        output:
          type: array
          items:
            $ref: '#/components/schemas/ResponseOutputItem'
    OpenAIErrorResponse:
      type: object
      title: OpenAIErrorResponse
      additionalProperties: true
      properties:
        error:
          anyOf:
            - $ref: '#/components/schemas/OpenAIError'
            - type: string
            - type: 'null'
          description: Error message (string) or structured error object.
    ResponseOutputItem:
      type: object
      title: ResponseOutputItem
      additionalProperties: true
      properties:
        id:
          type: string
          example: out_123
        type:
          type: string
          example: message
        role:
          anyOf:
            - type: string
            - type: 'null'
        status:
          anyOf:
            - type: string
            - type: 'null'
        content:
          type: array
          items:
            $ref: '#/components/schemas/ResponseOutputContent'
    OpenAIError:
      type: object
      title: OpenAIError
      additionalProperties: true
      properties:
        message:
          anyOf:
            - type: string
            - type: 'null'
          title: Message
        type:
          anyOf:
            - type: string
            - type: 'null'
          title: Type
        param:
          anyOf:
            - type: string
            - type: 'null'
          title: Param
        code:
          anyOf:
            - type: string
            - type: integer
            - type: 'null'
          title: Code
    ResponseOutputContent:
      type: object
      title: ResponseOutputContent
      additionalProperties: true
      properties:
        type:
          type: string
          example: output_text
        text:
          type: string
          example: hello
        annotations:
          anyOf:
            - type: array
              items:
                type: object
            - type: 'null'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API_KEY
      description: >-
        Bearer authentication using your serverless API key. Format: Bearer
        <API_KEY>

````