Guide menu · Quickstart
API guide
Quickstart
Issue your first document in a few minutes.
1. Create a key
#- Sign in as an organization admin.
- Open API and webhooks in the menu and choose Create key.
- Give it a name you will recognise, such as
Student records, and copy the key. It is shown only once.
Keep the key out of your code: put it in an environment variable, as every example in this guide does.
export SEALCHECK_API_KEY=sc_your_key_here
2. Find your template
#A template decides how the PDF looks. Your organization made at least one when it signed up. List them and note the id of the one you want.
You can skip this: without a template_id, your oldest template is used.
Request
curl 'https://truesealed.com/api/v1/templates' \
-H "Authorization: Bearer $SEALCHECK_API_KEY" \
-H 'Accept: application/json'
<?php
require 'vendor/autoload.php'; // composer require guzzlehttp/guzzle
$client = new GuzzleHttp\Client([
'base_uri' => 'https://truesealed.com/api/v1/',
'headers' => [
'Authorization' => 'Bearer '.getenv('SEALCHECK_API_KEY'),
'Accept' => 'application/json',
],
]);
$response = $client->get('templates');
$result = json_decode((string) $response->getBody(), true);
// Node.js 18 or later
const response = await fetch('https://truesealed.com/api/v1/templates', {
headers: {
Authorization: `Bearer ${process.env.SEALCHECK_API_KEY}`,
Accept: 'application/json',
},
});
const result = await response.json();
import os
import requests # pip install requests
response = requests.get(
"https://truesealed.com/api/v1/templates",
headers={
"Authorization": f"Bearer {os.environ['SEALCHECK_API_KEY']}",
"Accept": "application/json",
},
)
result = response.json()
{
"data": [
{
"id": "01m7p0nr39388waqvbw0radjxa",
"object": "template",
"name": "Certificate",
"orientation": "landscape"
}
]
}
3. Issue a document
#Send who it is for and what it is. The answer is the new document, with its own id and verification_url.
Because the example gives an email address, the holder is emailed their PDF straight away.
The Idempotency-Key header makes the request safe to retry: if your connection drops and you send it again, you get the same document back instead of a second one. Use something unique to this document in your own system, such as an enrolment number.
Request
curl -X POST 'https://truesealed.com/api/v1/documents' \
-H "Authorization: Bearer $SEALCHECK_API_KEY" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: enrolment-48213' \
-d '{
"recipient_name": "Ada Lovelace",
"recipient_email": "[email protected]",
"title": "Certificate in First Aid",
"template_id": "01m7p0nr39388waqvbw0radjxa",
"expires_at": "2028-03-01",
"fields": {
"grade": "Distinction"
}
}'
<?php
require 'vendor/autoload.php'; // composer require guzzlehttp/guzzle
$client = new GuzzleHttp\Client([
'base_uri' => 'https://truesealed.com/api/v1/',
'headers' => [
'Authorization' => 'Bearer '.getenv('SEALCHECK_API_KEY'),
'Accept' => 'application/json',
],
]);
$response = $client->post('documents', [
'headers' => [
'Idempotency-Key' => 'enrolment-48213',
],
'json' => [
'recipient_name' => 'Ada Lovelace',
'recipient_email' => '[email protected]',
'title' => 'Certificate in First Aid',
'template_id' => '01m7p0nr39388waqvbw0radjxa',
'expires_at' => '2028-03-01',
'fields' => [
'grade' => 'Distinction',
],
],
]);
$result = json_decode((string) $response->getBody(), true);
// Node.js 18 or later
const response = await fetch('https://truesealed.com/api/v1/documents', {
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.SEALCHECK_API_KEY}`,
Accept: 'application/json',
'Content-Type': 'application/json',
'Idempotency-Key': 'enrolment-48213',
},
body: JSON.stringify({
"recipient_name": "Ada Lovelace",
"recipient_email": "[email protected]",
"title": "Certificate in First Aid",
"template_id": "01m7p0nr39388waqvbw0radjxa",
"expires_at": "2028-03-01",
"fields": {
"grade": "Distinction"
}
}),
});
const result = await response.json();
import os
import requests # pip install requests
response = requests.post(
"https://truesealed.com/api/v1/documents",
headers={
"Authorization": f"Bearer {os.environ['SEALCHECK_API_KEY']}",
"Accept": "application/json",
"Idempotency-Key": "enrolment-48213",
},
json={
"recipient_name": "Ada Lovelace",
"recipient_email": "[email protected]",
"title": "Certificate in First Aid",
"template_id": "01m7p0nr39388waqvbw0radjxa",
"expires_at": "2028-03-01",
"fields": {
"grade": "Distinction",
},
},
)
result = response.json()
{
"data": {
"id": "rut4qvhw55lxp5zjzeduxv3qhkqkdqi2",
"object": "document",
"type": "generated",
"status": "valid",
"title": "Certificate in First Aid",
"recipient_name": "Ada Lovelace",
"recipient_email": "[email protected]",
"fields": {
"grade": "Distinction"
},
"issued_at": "2026-03-01",
"expires_at": "2028-03-01",
"revoked_at": null,
"revoked_reason": null,
"template_id": "01m7p0nr39388waqvbw0radjxa",
"replaces": null,
"verification_url": "https://truesealed.com/v/rut4qvhw55lxp5zjzeduxv3qhkqkdqi2",
"file_sha256": "3a7bd3e2360a3d29eea436fcfb7e44c735d117c42d1c1835420b6b9942dd4f1b",
"created_at": "2026-03-01T09:30:00+00:00"
}
}
4. Check it like anyone would
#Open the verification_url from the answer, or scan the QR code on the PDF. That is the page anyone sees: your organization's name, who the document is for, and whether it is valid, expired or revoked.
Anyone holding the PDF can also upload it on that page. It is compared with the fingerprint you got as file_sha256, so a changed copy shows as not matching.
Your document also appears under Documents in your organization's area, and the audit log shows the key's owner issued it.
Next steps
#- Add a webhook to hear when documents are checked or revoked.
- Handle errors and rate limits.
- Try each request with your key, right in this guide.