For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dashboard
User GuideDeveloper GuidesAPI Reference
User GuideDeveloper GuidesAPI Reference
    • Overview
  • Runtype API
      • GETList context templates
      • POSTCreate context template
      • GETGet context template
      • PUTUpdate context template
      • DELDelete context template
Dashboard
LogoLogo
Runtype APIContext Templates

Create context template

POST
/v1/context-templates
POST
/v1/context-templates
$curl -X POST https://api.runtype.com/v1/context-templates \
> -H "Authorization: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "config": {
> "http": {
> "headers": {
> "Authorization": "Bearer {{api_token}}",
> "Content-Type": "application/json"
> },
> "method": "GET",
> "url": "https://api.example.com/{{endpoint}}"
> },
> "outputVariable": "apiResponse"
> },
> "name": "API Call Template",
> "type": "api-call"
>}'
1{
2 "config": {},
3 "createdAt": "string",
4 "id": "string",
5 "name": "string",
6 "organizationId": "string",
7 "type": "string",
8 "updatedAt": "string",
9 "userId": "string"
10}
Create a new context template. The config is validated based on the template type.
Was this page helpful?
Previous

Get context template

Next
Built with

Authentication

AuthorizationBearer
API key or Clerk session token

Request

This endpoint expects a map from strings to any.

Response

Created context template
configmap from strings to any
createdAtstring
idstring
namestring
organizationIdstring or null
typestring
updatedAtstring
userIdstring

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
500
Internal Server Error