When the payer will press the "Play now with Flywire" button from a Xero invoice, it will be redirected to an unique tracking page in Flywire, which is specific for the created Xero integration. This page will also receive the unique id of the invoice being paid from Xero.
Using the above information Flywire will initiate a call to Xero to fetch the invoice and contact related details and prefill the Flywire payment form with that data before presenting it to the payer.
When the payment is made and its status changes over time, Flywire will initiate a call to Xero again and again to create a payment object for the invoice when the payment gets guaranteed, or make the created payment object null in case the payment is cancelled.
In order to initiate calls to Xero, Flywire will use an access token that is stored in each integration. This token is retrieved from Xero when Flywire will show the popup to authenticate with Xero and the authentication is completed.
There is a button when editing an integration called "Disconnect". Clicking on it will remove the stored token from the integration. After this Flywire will not be able to connect to that Xero account anymore.