Skip to main content
This page describes how data from the Accounting System is mapped to Pleo’s Vendors API during Vendor Sync. Data mapping ensures that vendors from the AS are reflected accurately in Pleo’s Vendors.

Implementation

Vendors: Data Mapping

Map the following datapoints from AS vendor records to Pleo Vendors API fields.

Using externalId and code

code and externalId can be the same value if the AS has no separate stable identifier beyond the account code. externalId is what Pleo uses for matching, so it must never change for a given vendor across sync runs. Only set code and externalId to the same value if the AS’s account codes are themselves immutable. If the AS can renumber account codes (for example, during a chart-of-accounts reorganisation), do not use the code as externalId. Use a separate, AS-internal record identifier that does not change when the code does, so matching continues to work after a renumbering event.

Handling Invalid AS Field Values

This mapping assumes the AS returns valid values for each field. If an AS vendor record has a blank, malformed, or non-ISO country or defaultCurrency (for example, a legacy record with no country set, or a free-text currency name instead of an ISO 4217 code), do not fail the entire sync run and do not write the invalid value into Pleo as-is.
  • country is optional on the Vendors API. Skip writing it for that vendor, log it for investigation, and still process the vendor’s other valid fields and matching/state transition normally.
  • defaultCurrency is required on the Vendors API (VendorCreateRequest and VendorUpdateRequest both reject a request that omits it), so it can’t simply be skipped. Either skip the create or update for that vendor and log it for investigation, or send a fallback value and continue: fall back to the Vendor’s existing defaultCurrency already on Pleo (update only), or to a fallback currency your integration preconfigures for the company. Log the invalid value for investigation either way.
Treat a required field being unusable as a per-vendor data-quality issue, not a reason to abort the run or silently guess a value.

Matching Field

Vendors are matched to their AS counterparts using the externalId field on both ends. The externalId is the stable identifier used to track a vendor across sync runs, even if its name, code, or other details change.

Vendor State


What Comes Next?