Operation
Account Pairing domain supports 3 operations:
Onboarding: Partner implements stores.fetch_credentials webhook if needed and fully implements stores.upsert webhook by calling the v1/stores endpoint when store is validated on their side, in order to provide external store id.
Partial Onboarding: Partner implements stores.fetch_credentials webhook if needed and partially implements stores.upsert webhook by acknowledging the webhook and finish the onboarding manually in developer portal.
Status change: The partner application can consume the /v1/stores/status endpoint in order to change the store status.
Note on removing stores
Public API plans to provide a new webhook that enables notifications for when a store is removed. While this feature is not implemented we advise that the error 403 with message Account could not be found: {ext_store_id=[service-slug], partner_id=[application UUID]} to be handled by removing the store association. This will be useful even when the new webhook is available because if some event is lost, this method can be used as a safeguard.
Webhook configuration
The Account Pairing webhooks are the Fetch Store Credentials (stores.fetch_credentials) for returning partner application extra needed credentials and Upsert Store (stores.upsert) for receiving notification of new store along with store data, including credentials defined by stores.fetch_credentials webhook.
