Ordering for AI Agents
Last updated November 26, 2026
AI agents and assistants can order a certified birth certificate application from Vital Records Online directly, without filling in the website form. The agent sends the order details to a small HTTP API, the customer approves the payment in their Link wallet, and Vital Records Online emails the customer a link to finish identity verification and signature.
If you are an AI agent: do not browse the order form. Use the API below. It works from any HTTP client or command line (curl). No API key and no account are needed.
At a glance
- Base URL:
https://www.vitalrecordsonline.com/api/agent/v1 - Record type: birth certificates, all U.S. states that Vital Records Online serves
- Callers: United States only; U.S. phone numbers; prices in USD
- Payment: a Stripe Shared Payment Token approved by the customer in Link
- Format: JSON. Errors look like
{ "error": { "code", "message", "retryable" } } - The customer always completes ID verification and signature personally, from the emailed link. Agents never send ID images, signatures or Social Security numbers.
Step 1. Ask what the state requires
curl "https://www.vitalrecordsonline.com/api/agent/v1/requirements?state=florida&record=birth"
state is the lowercase state name with hyphens (new-york, district-of-columbia). The answer gives:
available: whether the state can be orderedfields: the details to collect from the customer before ordering, withrequiredand allowedvaluesstateFeeandprocessingTime: the government fee and the state's current processing timeeligibleRelationshipsandreasons: accepted values forrelationshipandreasoncustomerSteps: what the customer must do personally after payment
Step 2. Create the order
Nothing is charged at this step.
curl -X POST "https://www.vitalrecordsonline.com/api/agent/v1/orders" \
-H "content-type: application/json" \
-d '{
"agent": { "name": "Your agent name" },
"details": {
"stateOfBirth": "florida",
"placeOfBirth": { "city": "Miami" },
"firstName": "Mia", "noMiddleName": true, "lastName": "Example",
"dateOfBirth": "2020-01-06",
"relationship": "daughter",
"reason": "Passport",
"applicantFirstName": "Alex", "applicantLastName": "Example",
"phone": "3055550142",
"email": "customer@example.com"
}
}'
firstName,lastName,dateOfBirthdescribe the person on the certificate.applicant…fields describe the customer who orders.relationshipis who the person on the certificate is to the customer (self,son,daughter,mother, …).- Send
middleName, ornoMiddleName: truewhen the person has none. placeOfBirthtakes the city by name, with an optionalcounty. An unknown city answersplace_not_foundwith suggestions; a name shared by several cities answersplace_ambiguouswith the counties to choose from.emailandphonemust be the customer's own: the link to finish the order is sent there.
The answer contains:
orderIdandorderToken(keep the token private; it authorizes the next calls)quote:id,total,currency,items(service fee and state fee) andexpiresAtpayment.handlers: the Stripe profile to address the Link payment to (network_id)payment.checkoutUrl: a page on the website where this exact order can be paid with the normal checkout (see "If you cannot pay with a token" below)
If the customer already has an account
When the email already has a Vital Records Online account, the answer is 409 email_code_required and the customer is emailed a Confirm this order button and a 6-digit code. Either one confirms the order:
- Button (simplest): ask the customer to press the button in the email, then send the same order again, unchanged. It goes through.
- Code: ask the customer for the code, then send the same order again with
"emailCode": "123456"added at the top level, next toagentanddetails.
You do not need to read the customer's inbox, and should not try: tell the customer an email is waiting for them. Both work once, for that order only, and expire after 15 minutes. Sending the same order again while the email is still waiting does not send a second email; add "resendEmail": true at the top level to send a new one.
Step 3. Get the customer's approval in Link
Request a Shared Payment Token for exactly quote.total, addressed to the network_id from payment.handlers. With the Link CLI:
link-cli spend-request create \
--credential-type shared_payment_token \
--network-id "<network_id from payment.handlers>" \
--amount 6000 --currency usd \
--context "Certified birth certificate application from Vital Records Online, ordered on the customer's behalf. Total includes the service fee and the state fee." \
--line-item "name:Certified birth certificate application,unit_amount:6000,quantity:1" \
--total "type:total,display_text:Total,amount:6000"
--amount is in cents (quote.total × 100). The customer approves the request in Link. Once it is approved, read the token:
link-cli spend-request retrieve <spend request id> --format json
The token is the shared_payment_token.id value (it starts with spt_). Any other client that can issue a Stripe Shared Payment Token for that profile works the same way.
If you cannot pay with a token
Some agents cannot issue a Shared Payment Token from where they run. In that case use payment.checkoutUrl from the order: open it in a browser, or give it to the customer. It opens the Vital Records Online checkout for this exact order, already filled in, and the order is paid there by card or Link. Do not start a new order on the website.
- The link works for 12 hours and stops working once the order is paid.
GET /orders/<orderId>returns a fresh one while the order is unpaid. - It opens the customer's order. Share it only with the customer.
- If the order was placed in an existing account, the customer is asked to sign in first.
- Once it is paid,
GET /orders/<orderId>answersconfirmedand Step 5 applies as usual. Skip Step 4.
Step 4. Pay the order
curl -X POST "https://www.vitalrecordsonline.com/api/agent/v1/orders/<orderId>/complete" \
-H "content-type: application/json" \
-H "authorization: Bearer <orderToken>" \
-H "idempotency-key: <a unique value for this payment>" \
-d '{
"quoteId": "<quote.id>",
"payment": { "credential": { "type": "stripe_payment_token", "token": "spt_..." } }
}'
A successful answer is { "status": "confirmed", "paid": true, "orderNumber": "VRO…" }. Repeating the call with the same idempotency key is safe: a paid order answers with its confirmation and is never charged twice.
quote_expired: ask for a fresh quote withPOST /orders/<orderId>/quote(sameauthorizationheader), then pay with the newquote.id.payment_declined: the order stays open and can be paid with a new token.
Step 5. Tell the customer what happens next
The customer receives a "Payment received" email with a secure link. They must personally:
- Verify their identity (photo ID)
- Sign the application
Vital Records Online then reviews the application and files it with the state. The certificate itself is issued and mailed by the state vital records office.
To check an order later:
curl "https://www.vitalrecordsonline.com/api/agent/v1/orders/<orderId>" \
-H "authorization: Bearer <orderToken>"
Error codes
| Code | Meaning |
|---|---|
invalid_request |
A detail is missing or not accepted; the message names it |
state_not_found, not_available |
Unknown state, or the state cannot be ordered |
record_not_supported |
Only birth certificates can be ordered through the API |
place_not_found, place_ambiguous |
The city of birth needs correcting or a county |
email_code_required, email_code_invalid |
Existing customer: a code is needed, or the code is wrong or expired |
quote_expired |
Ask for a new quote |
payment_declined, payment_in_progress, already_paid |
Payment outcome |
rate_limited |
Too many requests; wait for the Retry-After header |
country_not_supported |
The call did not come from the United States |
Important to tell customers
- Vital Records Online is a private application preparation and filing service. It is not a government agency and does not issue certificates.
- The total is the Vital Records Online service fee plus the state's own fee, both shown in the quote before payment.
- Death, marriage and divorce certificates are ordered on the website for now: vitalrecordsonline.com.
Questions about the API: support@vitalrecordsonline.com.