Skip to main content
GET
/
snippet
/
variation
Get a snippet variation
curl --request GET \
  --url https://www.getsnippets.ai/api/prompts/snippet/variation \
  --header 'Authorization: Bearer <token>'
{
"success": true,
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"content": {
"type": "plaintext",
"content": "Hello, world!"
},
"snippet_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"variant_order_index": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"usage": {
"remainingRequests": 123
}
}

Authorizations

Authorization
string
header
required

API key authentication using Bearer token. Include your API key in the Authorization header.

Query Parameters

snippetId
string<uuid>
required

The ID of the parent snippet

variationId
string<uuid>
required

The ID of the variation

Response

Variation retrieved successfully

success
boolean
Example:

true

data
object
usage
object