Skip to main content
POST
JavaScript

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

The Devbox ID.

Body

application/json

Parameters for minting an agent gateway token for a Devbox. The token lets the Devbox call the API described by the gateway config using the supplied credential, without ever receiving the credential itself.

gateway
string
required

The gateway config to use. Can be a gateway config ID (gwc_xxx) or name.

secret
string
required

The secret containing the credential. Can be a secret ID or name.

Response

Gateway token minted successfully.

devbox_id
string
required

The Devbox the token is bound to.

gateway_config_id
string
required

The ID of the gateway config the token proxies through.

token
string
required

The token to send to the gateway as a Bearer token in the Authorization header. Only accepted for requests originating from the bound Devbox.

url
string
required

The gateway URL to send requests to. Matches the value of the {prefix}_URL environment variable inside the Devbox.

endpoint
string
required

The target API endpoint the gateway proxies to.

auth_mechanism
object
required

How the gateway applies the credential to proxied requests.