curl --request GET \
--url https://api.promptlayer.com/prompt-templates \
--header 'X-API-KEY: <x-api-key>'{
"has_next": true,
"has_prev": true,
"items": [
{
"id": 123,
"prompt_name": "<string>",
"prompt_template": {
"content": [
{
"text": "<string>",
"type": "text"
}
],
"input_variables": [],
"template_format": "f-string",
"type": "completion"
},
"metadata": {
"model": {
"provider": "<string>",
"name": "<string>",
"parameters": {}
},
"customField": "<string>"
},
"commit_message": "<string>",
"llm_kwargs": {},
"version": 123
}
],
"next_num": 123,
"prev_num": 123,
"page": 123,
"pages": 123,
"total": 123
}curl --request GET \
--url https://api.promptlayer.com/prompt-templates \
--header 'X-API-KEY: <x-api-key>'{
"has_next": true,
"has_prev": true,
"items": [
{
"id": 123,
"prompt_name": "<string>",
"prompt_template": {
"content": [
{
"text": "<string>",
"type": "text"
}
],
"input_variables": [],
"template_format": "f-string",
"type": "completion"
},
"metadata": {
"model": {
"provider": "<string>",
"name": "<string>",
"parameters": {}
},
"customField": "<string>"
},
"commit_message": "<string>",
"llm_kwargs": {},
"version": 123
}
],
"next_num": 123,
"prev_num": 123,
"page": 123,
"pages": 123,
"total": 123
}Filter prompt templates by release label (e.g., 'prod', 'dev', 'staging')
Successful Response
Show child attributes
Show child attributes
f-string, jinja2 completion "completion"When you optionally specify provider in the body, llm_kwargs will be returned for that specific provider and you can pass these kwargs to the provider's API directly.
Was this page helpful?