Encryption API
Encrypt JSON payloads via API without implementing JWE yourself
On this page· 15 sections
Overview#
If you are unable to implement JWE encryption in your own systems, Figure provides an API endpoint that encrypts a JSON payload on your behalf using Figure's public key. The encrypted output is a standard JWE compact serialization string that can be used anywhere Figure expects encrypted data — for example, as a query parameter when redirecting a borrower to Figure.
Part of Data protection
The Encryption API produces the same JWE you'd create yourself. To learn how Figure protects borrower data, or to encrypt payloads in your own systems instead, see Data protection (JWE).
Authentication#
This endpoint uses the same authentication as all other Figure Partner API endpoints:
apikeyheader — Your API key, provided during onboarding.
See API basics for more information on required headers.
Request#
https://api.test.figure.com /encryption /v1 /encryptHeaders#
Body#
The request body is any valid JSON object representing the data you want to encrypt. For example, if you are encrypting inquiry prefill data:
Example request#
Response#
The encrypted field contains a JWE compact serialization string (five base64url-encoded segments separated by periods). See JSON Web Encryption (JWE) for details on the JWE format.
Store a payload request#
Use the payload request endpoint when Figure should store the payload and return a redirect URL for a relevant user based on payloadType to open a Figure-hosted flow with pre-filled data. Unlike /encryption/v1/encrypt, this endpoint does not return the encrypted payload in the response.
Request#
https://api.test.figure.com /encryption /v1 /payload-requestsTop-level fields#
payloadType matrix#
Figure builds redirectUrl from the path and payloadUuid in the matrix. If your organization has a configured branded HELOC host, that host is used for both payload types; the path still depends on payloadType (see matrix). A branded host is optional—not every partner uses one.
Payload shape depends on payloadType
Select the tab that matches your payloadType. HELOC_INQUIRY always uses the canonical applicant / property contract. HELOC_APPLICATION uses the flat register prepop shape shown in the application tab.
Enum values for employmentType, ownershipType, and occupancyType match HELOC enum types (occupancyType uses PropertyType: PRIMARY, SECONDARY, INVESTMENT).
payloadType selects which payload schema applies (see the matrix and examples above).
loanOriginatorUuid is required for HELOC_INQUIRY. For HELOC_APPLICATION, supply it at the top level or inside the payload according to your onboarding contract when the payload identifies the loan originator. It is also required when your API key is authorized for more than one organization. If both the top-level request and the payload include a loan originator id, they must match.
An encrypted version of the above payload is also accepted:
Minimum required fields (payload)#
Rules apply on create; all other documented fields are optional (partial pre-fill is allowed).
For HELOC_INQUIRY, do not send register-flat top-level fields (email, propertyAddress, phoneNumber, and similar), legacy metadata / offer blocks, property.ownership (use ownershipType), or property.propertyType (use occupancyType).
Response#
The path in redirectUrl depends on payloadType (see matrix). The example above shows a register URL for HELOC_APPLICATION; inquiry responses use the inquiry path from the matrix.
After create#
HELOC_INQUIRY: Route the loan originator toredirectUrl. They sign in to Lead Portal if needed, then open the HELOC create-inquiry experience with fields pre-filled from the stored payload.HELOC_APPLICATION: Route the borrower toredirectUrlto continue the HELOC application flow.
Send the relevant user to redirectUrl after create. Stored payloads are fetched by Figure frontends over authenticated APIs; partners only need to retain requestPayloadUuid for support correlation, not to call fetch themselves. Requests are matched by identity email (or similar value) to prevent erroneous decryption attempts. Users are authenticated before decryption is allowed.