When any transaction is posted we will look at profiles and the contact associated with a transaction and look for an existing Xero Contact. When the Contact does not exist in Xero the Contact is automatically created in Xero and then an internal connection is made between the Loft Profile and the Xero Contact.
During our synchronization and before an entire batch of transactions get posted we
Pull every contact from Xero, updating existing contacts and creating new ones. When this happens the agents AP and AR balance in Loft is also synchronized.
Push new payable agents to Xero. Push new payable organizations to xero.
After we pull every contact we look for every Xero contact that is not Linked with a Loft Profile and try to link them based on the following best match:
When the email is exactly the same we match them and create a link email@example.com = firstname.lastname@example.org
When the name is contained in the other and matches 60% of the length we match them and create a link
4. Loft then looks for any changes in Loft that are different between Xero contacts and Loft contacts (name, email, addresses) and pushes those changes to Xero as an update to the contact record.
When an Agent is paid to their Organization
If an Agent is paid to an Organization Loft will post all bills and credit notes to the Organization name. The invoicing in Xero will also be in the Organization's name as in order to allocate credit notes, the billing or invoices name needs to match the name posted from Loft. As a result we’ve created the following rule:
Agent and Organization Syncing Rule
If the Agent is paid to the Organization Loft will sync the AR balance of the Organization in Xero to the Agents profile in Loft. Unless the Organization profile has No ($0) AR Balance, in that case Loft will pull in any balance that the Agent has in Accounts Receivable.
Please note that if you archive the Agent in Xero the Agent profile will not have a Linked Xero contact so it's ok that this field is empty. The Organization should show the Linked Xero contact as the Organization in Xero.
You can use this Linked Xero Contact field to manually associate the profile in Loft to Xero if necessary.
For agents/regular contacts paid to their contact name, you will add in their Linked Xero contact below
Agents/Contacts paid to their organization,
The agent/contact Linked Xero Contact field MUST be blank
and their organization profile MUST have the Linked Xero Contact populated in that field, if missing, you can add it in by searching within the field. If you have more than one contact in the dropdown or only the agent's name, this is a good indication that either the contact hasn't been changed in Xero or you haven't synced Xero via the Xero page in Loft to bring in the changes. Remember every change you make in Xero to contacts will need a Xero Sync!
In Summary; if an Agent is paid to an Organization and you do not have an Agent contact in Xero you will see the Linked contact to the Organization name in Xero. If you are maintaining both Agent and an Organization profiles in Xero you will see the Agent linked to the Agent and the Organization linked to the Organization.
When you choose to disable the Xero Sync in the profile in Loft it will no longer try to match any of the above criteria. If it is currently ‘Linked’ to a Xero contact AP and AR balances will continue to update.