Prerequisites
Before starting this workflow, your integration must already have:- Authentication with the
accounting-entries:writescope. See Accounting Enrichment API Scopes. - The receipt file to upload, in a supported format (PDF, PNG, JPEG, HEIC).
- The last four digits of the Pleo card used for the transaction.
- The required transaction details for matching:
amount,currency,merchant_name, and at least one ofperformed_atorsettled_at(optionallyemail). See Transaction Details.
Workflow Overview
Step 1: Build the Enrichment Payload
Using the receipt and transaction details already available from prerequisites, encode the receipt file as Base64. For the full list of required and optional parameters, see Request Parameters. The encoded string is submitted in thereceipts array in the request body.
Step 2: Submit the Enrichment Request
Endpoint: POST/v2/accounting-entries:enrich
Submit transaction details as query parameters and the encoded receipt in the request body:
Step 3: Handle the Response
Pleo returns areceiptStatus with every response. For status definitions, see Receipt Statuses.
UPLOADED: Enrichment is complete. Store theaccountingEntryIdfor reference.ACCEPTED: Pleo is retrying asynchronously. No action required; retrying will create duplicate receipts.ADDED_TO_RECEIPT_INBOX: Pleo could not make a reliable match. The receipt is placed in the spender’s Pleo Receipt Inbox, accessible on mobile, for manual matching. Retry if within your retry window, otherwise stop.UNRESOLVED: The request could not be processed. Investigate the transaction details and do not retry with the same payload.
Applying Tags (Optional)
Tags apply Accounting Dimensions (Pleo Tags) to the matched accounting entry at enrichment time. For full details on how tags work, see Tags Sync. Include validated Pleo Tag UUIDs in the request body alongside the receipt:- Retrieve tag IDs from your Tags Sync implementation: do not use hardcoded IDs.
- Confirm each tag ID is present and not archived in your most recent synced snapshot.
- If any ID cannot be validated, re-fetch from the Pleo Tags API and remap where possible.
- If valid IDs cannot be resolved, omit the
tagsfield and submit the receipt only.
tags field.