curl --request GET \
--url https://api.example.com/v2/template/{id}{
"id": "<string>",
"type": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"created_by": "<string>",
"version": 123,
"body": "<string>",
"subject": "<string>",
"name": "<string>",
"postage": "<string>",
"status_code": 123,
"errors": [
{}
]
}curl --request GET \
--url https://api.example.com/v2/template/{id}{
"id": "<string>",
"type": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"created_by": "<string>",
"version": 123,
"body": "<string>",
"subject": "<string>",
"name": "<string>",
"postage": "<string>",
"status_code": 123,
"errors": [
{}
]
}Retrieves a template by ID. You can optionally specify a version number to retrieve a specific version of the template.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/alphagov/notifications-api/llms.txt
Use this file to discover all available pages before exploring further.
sms - SMS message templateemail - Email templateletter - Letter templatefirst - First classsecond - Second classeconomy - Economy classeurope - Europerest-of-world - Rest of worldcurl -X GET "https://api.notifications.service.gov.uk/v2/template/f33517ff-2a88-4f6e-b855-c550268ce08a" \
-H "Authorization: Bearer your_api_key_here"
{
"id": "f33517ff-2a88-4f6e-b855-c550268ce08a",
"type": "email",
"created_at": "2024-01-15T14:30:00.000000Z",
"updated_at": "2024-01-16T09:15:00.000000Z",
"created_by": "user@example.gov.uk",
"version": 3,
"body": "Hello ((name)),\n\nYour reference number is ((reference)).",
"subject": "Your application has been received",
"name": "Application confirmation email",
"postage": null
}
{
"status_code": 400,
"errors": [
{
"error": "ValidationError",
"message": "id is not a valid UUID"
}
]
}
{
"status_code": 403,
"errors": [
{
"error": "AuthError",
"message": "Invalid token: service not found"
}
]
}
{
"status_code": 404,
"errors": [
{
"error": "NoResultFound",
"message": "No result found"
}
]
}