Session Providers

Session providers represent the providers that are actively connected to a session. Each session can have multiple providers, and providers can be added or removed during the session lifecycle.

Session Providers object

Attributes

object

String

String representing the object's type

id

String

Unique session provider identifier

status

String

Provider status

usage

Object

Usage statistics

tool_filter

Object

Tool filter configuration

provider_id

String

Provider ID

session_id

String

Parent session ID

from_template_id

StringNullable

Source template ID

from_template_provider_id

StringNullable

Source template provider ID

deployment

Object

config

Object

auth_config

ObjectNullable

created_at

Date

Timestamp when created

updated_at

Date

Timestamp when last updated

{
"object": "session.provider",
"id": "spr_3cDeFgHjKlMnPqRs",
"status": "active",
"usage": {},
"tool_filter": {
"type": "v1.allow_all"
},
"provider_id": "pro_5gHjKlMnPqRsTuVw",
"session_id": "ses_4dEfGhJkLmNpQrSt",
"from_template_id": "stm_2bCdEfGhJkLmNpQr",
"from_template_provider_id": "stp_3cDeFgHjKlMnPqRs",
"deployment": {
"object": "provider.deployment#preview",
"id": "pde_1aBcDeFgHjKlMnPq",
"name": "Production",
"description": "Production deployment",
"metadata": {},
"provider_id": "pro_5gHjKlMnPqRsTuVw",
"created_at": "2025-09-15T10:30:00.000Z",
"updated_at": "2026-01-10T14:45:00.000Z"
},
"config": {
"object": "provider.config#preview",
"id": "pcf_7dEfGhJkLmNpQrSt",
"name": "Production Config",
"description": "Configuration for production environment",
"metadata": {},
"provider_id": "pro_5gHjKlMnPqRsTuVw",
"created_at": "2025-09-15T10:30:00.000Z",
"updated_at": "2026-01-10T14:45:00.000Z"
},
"auth_config": {
"object": "provider.auth_config#preview"
},
"created_at": "2025-09-15T10:30:00.000Z",
"updated_at": "2026-01-10T14:45:00.000Z"
}

List session providers

Returns a paginated list of providers connected to a session.

Query Parameters

limit

NumberOptional

Maximum number of items to return (1-100)

after

StringOptional

Return items after this ID

before

StringOptional

Return items before this ID

cursor

StringOptional

Pagination cursor from a previous response

order

EnumOptional

Sort order for results

id

UnionOptional

Filter by session provider ID(s)

session_id

UnionOptional

Filter by session ID(s)

session_template_id

UnionOptional

Filter by session template ID(s)

provider_id

UnionOptional

Filter by provider ID(s)

provider_deployment_id

UnionOptional

Filter by provider deployment ID(s)

provider_config_id

UnionOptional

Filter by provider config ID(s)

provider_auth_config_id

UnionOptional

Filter by provider auth config ID(s)

status

UnionOptional

Filter by provider status

GEThttp://api.metorial.com/session-providers
curl -X GET "https://api.metorial.com/session-providers" \
-H "Authorization: Bearer metorial_sk_..."

Get session provider

Retrieves a specific provider connected to a session.

URL Parameters

session_provider_id

String

The unique identifier for the session_provider

GEThttp://api.metorial.com/session-providers/:session_provider_id
curl -X GET "https://api.metorial.com/session-providers/ses_Rm4Mnheq2bfEPhBhP7SY" \
-H "Authorization: Bearer metorial_sk_..."

Create session provider

Adds a new provider to an active session.

Request Body

session_id

String

tool_filters

UnionOptionalNullable
POSThttp://api.metorial.com/session-providers
curl -X POST "https://api.metorial.com/session-providers" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer metorial_sk_..." \
-d '{
"session_id": "example_session_id",
"tool_filters": {
"type": "example_type",
"keys": [
"example_item"
]
}
}'

Update session provider

Updates a provider connected to a session.

URL Parameters

session_provider_id

String

The unique identifier for the session_provider

Request Body

tool_filters

UnionOptionalNullable
PATCHhttp://api.metorial.com/session-providers/:session_provider_id
curl -X PATCH "https://api.metorial.com/session-providers/ses_Rm4Mnheq2bfEPhBhP7SY" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer metorial_sk_..." \
-d '{
"tool_filters": {
"type": "example_type",
"keys": [
"example_item"
]
}
}'

Delete session provider

Removes a provider from a session.

URL Parameters

session_provider_id

String

The unique identifier for the session_provider

DELETEhttp://api.metorial.com/session-providers/:session_provider_id
curl -X DELETE "https://api.metorial.com/session-providers/ses_Rm4Mnheq2bfEPhBhP7SY" \
-H "Authorization: Bearer metorial_sk_..."