Skip to main content
GET
List Prompts
Returns a paginated list of AI prompts with optional filtering by section, route, tag, search term, and active status.

Authentication

Requires JWT Bearer token (Cognito) with admin role.

Query Parameters

string
Filter by agent pipeline sectionValues: parser, gap_detector, risk_analysis, report_generationExample: gap_detector
string
Filter by associated frontend routeExample: /assessments/:id/gap-detector
string
Filter by a specific tagExample: production
Full-text search across prompt name, system prompt, and user prompt templateExample: market risk
boolean
Filter by active status
  • true — active prompts only
  • false — inactive prompts only
  • omit — all prompts
number
default:"1"
Page number (1-indexed)Minimum: 1Example: 2
number
default:"20"
Number of results per pageMinimum: 1
Maximum: 100
Default: 20

Response

object
Paginated prompt list container
array
Array of prompt objects
string
Prompt UUID
string
Human-readable prompt name (max 200 characters)Example: Gap Detection — Market Risk v2
string
Agent pipeline sectionValues: parser, gap_detector, risk_analysis, report_generation
string
Optional sub-section grouping (max 100 characters)Example: Market Risk
string
Frontend route that uses this promptExample: /assessments/:id/gap-detector
array
Risk category names this prompt applies toExample: ["Market Risk", "Credit Risk"]
array
Free-form tags for filtering and organizationExample: ["v2", "production", "reviewed"]
number
Current version number (auto-incremented on update)
boolean
Whether this prompt is active and used by Bedrock agentsOnly one prompt per section should be active at a time.
string
System-level prompt establishing persona, task, and constraints
string
User-turn prompt template with variable substitution supportVariables: {{category_1}}, {{category_2}}, {{categories}}
string
Tone and style instructions (max 500 characters)Example: Professional, analytical, concise. Use bullet points.
string
Output format instructions (max 5000 characters)Example: Return JSON with keys: gaps, severity, recommendations
array
Few-shot examples for model guidanceEach example has:
  • input (string): Example user input
  • output (string): Expected model output
object
Additional context configuration
  • persona (string): Persona definition
  • sources (array): Reference sources
  • constraints (string): Operational constraints
  • guardrails (string): Safety guardrails
number
Number of comments on this prompt (denormalized for performance)
string
ISO 8601 timestamp of creation
string
ISO 8601 timestamp of last update
number
Total number of prompts matching the filters
number
Current page number (1-indexed)
number
Number of results per page
number
Total number of pages

Example Request

Example Response

Error Responses

error
Missing or invalid Bearer token
error
Forbidden — admin role required

Source Code

Implementation: packages/api/src/prompts/prompts.controller.ts:53