Get AI Prompt Template
Endpoint
GET /apiops/settings/ai-prompt-templates/{entryName}/
Authentication
Requires a Personal API Access Token with admin privileges.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| entryName | string | Yes | Name of the entry to retrieve (case-insensitive) |
Query Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| projectId | string | No | admin | Scope project id. Omit for the admin/global scope. |
Response
Success Response (200 OK)
{
"status": "SUCCESS",
"resultList": [
{
"id": "665f3b2d8c4f5b0013cd91dd",
"projectId": "admin",
"name": "support-summary",
"description": "Summarize a support thread into three bullet points",
"messages": [
{ "role": "system", "content": "You summarize support conversations." },
{ "role": "user", "content": "Summarize the following thread: {{thread}}" }
],
"parameters": [
{ "name": "thread", "required": true }
],
"enabled": true,
"builtIn": false
}
],
"resultCount": 1
}
Response Fields
| Field | Type | Description |
|---|---|---|
| status | string | Response status: SUCCESS or FAILURE |
| resultList | array | Single-element list holding the requested entry |
| resultCount | integer | Always 1 on success |
Error Response (400 Bad Request)
Returned when the name is empty, no entry with that name is visible in the scope, or the caller lacks the ADMIN role.
{
"status": "FAILURE",
"resultMessage": "AI Prompt Template (name: support-summary) was not found!"
}
Error Response (401 Unauthorized)
{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}
cURL Example
curl -X GET \
"https://demo.apinizer.com/apiops/settings/ai-prompt-templates/support-summary/" \
-H "Authorization: Bearer YOUR_TOKEN"
Notes and Warnings
- Name Resolution:
- Names are matched case-insensitively within the scope's visible set (built-in ∪ admin-shared ∪ scope-owned)
- When the same name exists in more than one tier, the row the scope actually owns wins
- Admin Only: a project-scoped
AI_DEVELOPMENTtoken is not sufficient on this surface
Related Documentation
- List AI Prompt Templates - List all entries
- Update AI Prompt Template - Update an existing entry
- AI Prompt Templates API - Resource overview