Skip to content

Xero tenant & contacts

Complement Xero integration with data-model context: tenants, contacts, and application linkage.

  • leekimerp/api/xero.py — OAuth, webhooks, sync_contact_with_tenant, create_contact, update_sync_status
  • leekimerp/tasks.pyupdate_new_xero_contact (commented in hooks.py for Application on_update)
  • DocTypes under lee_kim_alliance_erp/doctype/ matching Xero* (e.g. Xero Contact, Xero Tenants — verify exact names in repo)
flowchart LR
APP[Application] -. optional .-> XC[Xero Contact]
XT[Xero Tenant / settings] --> API[xero.py sync]
API --> XERO[Xero Cloud]
  • Whitelisted methods in api/xero.py (see API inventory)
  • Webhook: xero_webhook_connection
  • Stored OAuth tokens (obtain_xero_oauth2_token, store_xero_oauth2_token)
  • ERPNext Customer, Item, Sales Invoice when syncing into native ERP flow
  • Per-tenant Xero credentials and webhook signing secret (get_app_webhook_secret)
  • update_new_xero_contact on Application on_update is commented out in hooks.py — confirm with product before re-enabling.