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.
Help CenterOpenAPI SpecStatus
OverviewInquiriesTransactionsRelayAPI ReferenceChangelog
OverviewInquiriesTransactionsRelayAPI ReferenceChangelog
  • Getting Started
    • Introduction
    • Quickstart Tutorial
  • API Overview
    • API Keys
    • Authentication
    • Protocol
    • Response Body
    • Idempotence
    • Pagination
    • Rate Limiting
    • Downloading Files
    • API Logs
    • Request IDs
  • Versioning
    • API Changelog
    • Versioning
  • Troubleshooting
    • Error Handling
  • API Reference
    • OpenAPI Specification
    • Cases
    • Connect
    • Documents
    • Inquiries
    • List Items
    • Lists
    • OAuth
      • POSTCreate a Privacy Pass
      • POSTCreate a Relay
      • POSTGenerate a Relay claim
    • Reports
    • Transactions
    • Verifications
    • Workflows
  • Webhooks
LogoLogo
Help CenterOpenAPI SpecStatus
API ReferenceRelay

Create a Relay

POST
https://api.withpersona.com/api/privacy/v1/relays
POST
/api/privacy/v1/relays
$curl -X POST https://api.withpersona.com/api/privacy/v1/relays \
> -H "Content-Type: application/json" \
> -d '{
> "claim-type": "age_over18_germany"
>}'
1{
2 "relay-token": "relay_AbcDeFGhIjKlMnOpQrStUvWxYz1",
3 "relay-secret": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
4 "relay-session-access-token": "eyJhbGciOiJSUzI1NiJ9.eyJzdWIiOiJyZWxzZXNzX0FiYyJ9.signature"
5}
Creates a new Relay.
Was this page helpful?
Previous

Generate a Relay claim

Next
Built with

Headers

Key-InflectionenumOptional
Determines casing for the API response.
Allowed values:
Persona-VersionenumOptional
Server API version. More info on versioning can be found [here](https://docs.withpersona.com/versioning).

Request

This endpoint expects an object.
claim-typestringRequired
Possible values: - live_human_presence - age_over18_germany - age_over18_united_kingdom - age_over18_verified - age_over18_france - age_over18_italy - age_over18_brazil - age_over18_australia - age_over16_australia - age_over21_verified Do not assume this is a static enumeration; Persona may add new claim types in the future without a versioned update.
encryption-key-pemstring or nullOptional

Optional RSA public key (PEM-encoded, 2048-4096 bits). When provided, claim payloads returned by subsequent reads will be encrypted with RSA OAEP. Pass null to receive unencrypted claim payloads.

Response

Returns the Relay tokens needed to redeem and read the claim.
relay-tokenstring

Public Relay identifier. Use this token in subsequent calls to /relays/{relay-token}/generate-claim.

relay-secretstring

Secret value tied to this Relay. Returned only at creation and must be passed in the Persona-Relay-Secret header for any read of the claim payload.

relay-session-access-tokenstring

Encoded JWT used by Persona’s client SDK to load the associated Inquiry Session in the end-user’s browser or device.

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
409
Conflict Error
422
Unprocessable Entity Error
429
Too Many Requests Error

Server API version. More info on versioning can be found here.

Possible values:

  • live_human_presence
  • age_over18_germany
  • age_over18_united_kingdom
  • age_over18_verified
  • age_over18_france
  • age_over18_italy
  • age_over18_brazil
  • age_over18_australia
  • age_over16_australia
  • age_over21_verified

Do not assume this is a static enumeration; Persona may add new claim types in the future without a versioned update.