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.
Trust CenterStatusSupportGet a demoPlatform
DocumentationEvals API ReferenceIntegrations & OTELPlatform SettingsSelf-HostingGuidesChangelog
DocumentationEvals API ReferenceIntegrations & OTELPlatform SettingsSelf-HostingGuidesChangelog
  • Get Started
    • Introduction
    • Quickstart
    • Authentication
    • Data Models
    • API Conventions
  • Data Models
      • GETList Prompts
      • POSTPush Prompts
        • GETList Commits
        • GETPull Prompts By Commit
  • Evals
  • Legacy
LogoLogo
Trust CenterStatusSupportGet a demoPlatform
Data ModelsPromptsCommits

Pull Prompts By Commit

GET
https://api.confident-ai.com/v1/prompts/:alias/commits/:hash
GET
/v1/prompts/:alias/commits/:hash
$curl -G https://api.confident-ai.com/v1/prompts/PROMPT-ALIAS/commits/bab04ce \
> -H "CONFIDENT_API_KEY: <PROJECT-API-KEY>" \
> -d branch=MY-BRANCH
1{
2 "success": true,
3 "data": {
4 "id": "prv_abc123",
5 "hash": "bab04ce",
6 "type": "TEXT",
7 "interpolationType": "FSTRING",
8 "outputType": "TEXT",
9 "version": "00.00.01",
10 "label": "my-label",
11 "text": "Hello, {{name}}!",
12 "modelSettings": {
13 "provider": "OPEN_AI",
14 "name": "gpt-4o",
15 "temperature": 0.7
16 }
17 },
18 "deprecated": false
19}

Retrieves a prompt with alias and the specific hash from your Confident AI account.

Was this page helpful?
Previous

List Branches

Next
Built with

Path parameters

aliasstringRequired
The unique alias of the prompt.
hashstringRequired
The unique hash of the commit.

Headers

CONFIDENT_API_KEYstringRequired
The API key of your Confident AI project.

Query parameters

branchstringOptional
The unique name of a branch.

Response

successboolean
This is true if the prompt was successfully retrieved.
dataobject
deprecatedboolean
This is true if this endpoint is deprecated.