Anthropic Gateway

Create an Anthropic message

Changed on

Send native Anthropic Messages requests through Respan using provider credentials configured in Respan. Authenticate with your Respan key in x-api-key for Anthropic SDKs or Authorization: Bearer for bearer clients.

post/api/anthropic/v1/messages

Request

  • Base URL
    https://api.respan.ai
  • URL
    https://api.respan.ai/api/anthropic/v1/messages
  • Auth
    none required

Headers

x-api-keystring required

Your Respan API key in Anthropic's native authentication header. Bearer authentication is also accepted.

anthropic-versionstring
anthropic-betastring

Request body

modelstring required
max_tokensinteger required
messagesobject[] required
streamboolean
respan_paramsobject

Response

Anthropic response or event stream.

object required

Changes

    • breaking

      request body became required

    • breaking

      the request property's minItems was increased to 1

    • info

      api operation id anthropicGateway_api_anthropic_v1_messages_create removed and replaced with api_anthropic_v1_messages_create

    • info

      api tag Anthropic Gateway added

    • info

      api tag anthropicGateway removed

    • info

      added the media type text/event-stream for the response with the status

    • info

      the header request parameter anthropic-version became optional

    • info

      added the non-success response with the status

    • info

      removed the non-success response with the status