Skip to content

Welcome to the Jungle Commerce Xero App

This app integrates your Jungle Commerce account with your Xero account.

Choosing a Xero Organisation

When you connect the integration with Xero, Xero asks you to sign in and to choose an organisation. Your Xero user may have authorised this app for more than one organisation. In that case the app lists those organisations and asks you to choose the one to connect with your Jungle account. The app marks and preselects the organisation that is already connected to Jungle, so a reconnect lands on the organisation you configured.

The home page shows the name of the organisation the app is connected to. If your Xero user has access to more than one, a link under that name lets you choose a different organisation.

Reconnecting With Xero

If the app stops sending data to Xero because its access to your Xero organisation has lapsed, connect the integration with Xero again from the app's home page, then save your configuration. If the app asks you to choose an organisation, keep the preselected one, which is the organisation already connected to Jungle. The save stores the new connection, and nothing changes before it. Your existing settings are shown on the page, so you can save them as they are. Synchronisation resumes with the next scheduled sync.

Disconnected Organisations

Jungle support can mark a connected Xero organisation as disconnected, for example when its access to Xero has lapsed and nobody will reconnect it. The app then sends nothing to that organisation: no purchase orders, bills, credit notes or manual journals. Changes you make in Jungle meanwhile are not queued for later. Your settings for the organisation are kept.

To start synchronising again, reconnect as described in Reconnecting With Xero: connect the integration with Xero again, then save your configuration. A configuration save without a new Xero sign-in keeps the organisation disconnected. If your Jungle account is connected to more than one Xero organisation, the others carry on as before.

Configuration

After authenticating with Xero, you can configure the app from its home page.

Xero Account Codes

You must select the Xero accounts to use for synchronisation:

  • Cost of Goods Sold Account — used for COGS entries in inventory movement journals. Conventionally a Direct Costs account.
  • Inventory Account — used for purchase order and bill line items, credit note line items, and inventory movement journals. Conventionally a Current Asset account. Avoid Xero's Inventory account type: it is intended for Xero's own tracked inventory, which is incompatible with this app's journal-based stock accounting (Xero does not allow manual journal postings to tracked inventory accounts). Give it a default tax rate of GST on Expenses: purchase order, bill and credit note line items coded to this account inherit its default tax rate unless Line Item Tax Code Mapping is enabled, while journal lines are always posted as BAS Excluded regardless of the default.
  • Inventory Adjustment Account — used for inventory adjustment entries in journals. Conventionally a Direct Costs account, so that stock shrinkage and stocktake variances reduce gross profit alongside cost of goods sold. An Expense account also works, but adjustments then sit below gross profit and gross margin overstates the true cost of stock.

You can also optionally select:

Supplier Returns Clearing Account

The Supplier Returns Clearing Account is an optional "purchases returned not credited" account. When it is configured:

  • Supplier return fulfilments (stock physically shipped back to a supplier) appear in the daily manual journal, moving the cost of the returned stock out of the inventory account and into the clearing account.
  • Credit note line items are coded to the clearing account instead of the inventory account, so approving the credit note clears the clearing balance rather than crediting inventory a second time.
Event Debit Credit
Supplier return fulfilled (journal) Supplier Returns Clearing Account Inventory Account
Supplier credit note approved Accounts Payable Supplier Returns Clearing Account

The clearing account's running balance represents stock returned to suppliers that has not yet been credited. Once the supplier's credit note is approved, the balance for that return nets to zero; any residual amount is a price variance between the stock's cost at fulfilment and the credited amount.

Create this as a Current Asset account in Xero, with a default tax rate of GST on Expenses. Between fulfilment and credit the account carries a debit balance — stock the supplier owes you credit for — which is why it belongs on the balance sheet as a current asset rather than in the profit and loss. Do not use a bank account or the system Accounts Payable/Receivable accounts; Xero rejects manual journal lines and credit note lines against those. The default tax rate matters because credit note line items inherit it, and Line Item Tax Code Mapping does not apply to credit notes. A supplier credit note for taxable goods should reverse the GST claimed on the original bill; an account defaulting to BAS Excluded would produce credit notes with no GST. The GST is posted to Xero's GST control account, not to the clearing account, so the clearing balance still nets to zero. Journal lines are always posted as BAS Excluded regardless of the account's default. Confirm the tax rate with your accountant if you are not registered for GST or the returned goods are GST-free.

When this account is not configured, supplier return fulfilments are not reflected in the manual journal, and credit note line items are coded to the inventory account (the previous behaviour).

GRNI Clearing Account

The GRNI Clearing Account is an optional "goods received not invoiced" account. Stock from a supplier usually arrives before the supplier's invoice does. When this account is configured, the app accounts for that gap:

  • When stock is received from a supplier, the daily manual journal moves its cost into the Inventory account and accrues the same amount to the GRNI Clearing Account, on the day it is received.
  • Purchase bill line items — both the draft bill created when a purchase order closes and synchronised Jungle bills — are coded to the GRNI Clearing Account instead of the inventory account, so posting the bill clears the accrual rather than debiting inventory a second time.
  • Purchase order line items are coded to the GRNI Clearing Account as well. A purchase order in Xero posts nothing to your accounts, but Xero copies the line accounts onto any bill you create from it with Copy to → Bill, so that bill clears the accrual too.

Between the two, Xero shows both the stock and the obligation to pay for it.

Create this as a Current Liability account in Xero, with a default tax rate of GST on Expenses. The account is credited when stock is received and debited when the bill is posted, so its running balance is a credit — the value of stock received that the supplier has not yet invoiced — which is why it belongs on the balance sheet as a liability. Do not use a bank account or the system Accounts Payable/Receivable accounts. The default tax rate matters because bill line items inherit it unless Line Item Tax Code Mapping is enabled; Xero gives a new Current Liability account a default of BAS Excluded, which would produce bills with no GST.

Event Debit Credit
Stock received from a supplier (journal) Inventory Account GRNI Clearing Account
Supplier bill entered GRNI Clearing Account Accounts Payable

A Purchase Price Variance Account must be selected together with the GRNI Clearing Account. The received cost of the stock is what Jungle carries it at, and the Inventory account in Xero only ever moves by that received cost. Any later change to what the goods are expected to cost is journalled to the Purchase Price Variance Account, on the day the change is made:

  • If the supplier bills a different price than the stock was received at, the difference is journalled between the Purchase Price Variance Account and the GRNI Clearing Account, so that once the bill is posted the GRNI Clearing Account clears to zero for those goods.
  • If a receipt is later matched to a purchase order at a different price, the same happens for the difference between the received cost and the ordered price.
  • If a receipt turns out to have been a transfer between locations or a customer return rather than a purchase, its accrual is reversed out of both the Inventory account and the GRNI Clearing Account at the received cost, and nothing is posted to the variance account.

Worked example. Five units are received at $5.00 each on 3 March and the supplier's bill for $6.00 each is entered on 10 March:

Date Journal Inventory GRNI Clearing Variance Accounts Payable
3 March Stock received: Dr Inventory / Cr GRNI $25.00 +25.00 −25.00
10 March Bill matched: Dr Variance / Cr GRNI $5.00 −5.00 +5.00
10 March Bill posted: Dr GRNI / Cr Accounts Payable $30.00 +30.00 −30.00
Balance +25.00 0.00 +5.00 −30.00

A balance left in the GRNI Clearing Account at month end means goods have been received and not yet billed, or a bill has been posted for goods that were never received.

Create the Purchase Price Variance Account as an Expense account in Xero. Only journal lines are posted to it, and journal lines are always posted as BAS Excluded regardless of the account's default tax rate. Do not use a bank account or the system Accounts Payable/Receivable accounts.

Only enable these accounts in consultation with Jungle support. Switching over changes how your inventory purchases are accounted for, and requires every previously received item to have been billed (or had its billing obligation closed) first, so that the GRNI Clearing Account starts from zero.

When these accounts are not configured, stock received from suppliers is not reflected in the manual journal until its bill is entered, and bill line items are coded to the inventory account (the previous behaviour).

Purchase Order Synchronisation

Use the Enable synchronization of Jungle purchase orders to Xero purchase orders checkbox to control whether Jungle purchase orders are synchronised as purchase orders in Xero. This toggle only controls the purchase order itself; draft bill creation on PO close is controlled separately by the next setting.

Draft Bill On Purchase Order Close

Use the Automatically create a draft purchase bill in Xero when a Jungle purchase order is closed checkbox to control whether closing a Jungle purchase order produces a draft bill in Xero. When unchecked, closed Jungle purchase orders will not generate a bill — leaving the bill to be entered manually in Xero. This setting is enabled by default.

While the draft bill remains in Draft in Xero, later changes to the closed purchase order in Jungle — including edits to its individual line items — are carried onto the draft bill. Once the bill has been submitted for approval, approved, or paid in Xero, it is left alone.

Xero bills have no line discount. A discounted purchase order line therefore appears on the bill at its discounted unit price, with up to four decimal places, so that the line total matches the purchase order. For example, 6 units at $260.15 with 8% off appear as 6 at $239.338, a line total of $1,436.03. Synchronised Jungle bills show discounted lines the same way.

Received Quantities Only On Draft Bills

Use the Only include received quantities on the draft purchase bill created when a purchase order is closed checkbox to control what lands on the draft bill described above. This setting is disabled by default, and only affects the draft bill created on purchase order close — the Xero purchase order itself (if purchase order synchronisation is enabled) always carries the quantities that were ordered.

When enabled, the draft bill reflects the stock you actually received rather than what was ordered:

  • A line that was fully received is billed as normal.
  • A line that was partially received is billed at its received quantity (unit prices are unchanged).
  • A line with nothing received is left off the bill entirely.
  • If nothing on the purchase order was received, no draft bill is created at all.

Quantities received after the purchase order has been closed are not picked up automatically — adjust the draft bill in Xero if stock arrives later.

When disabled (the default), the draft bill carries every line at its ordered quantity, as before.

Bill Synchronisation

Use the Enable synchronization of Jungle bills to Xero draft bills checkbox to control whether Jungle bills are synchronised to Xero as draft bills. This is separate from the purchase order settings above — a Jungle bill is a distinct entity from a purchase order, and from the draft bill that can be created when a purchase order is closed. This setting is disabled by default.

Line Item Tax Code Mapping

Use the Map tax code from Jungle line items to Xero line items checkbox to control whether the tax code set on Jungle line items is carried onto the corresponding Xero line items. This setting is disabled by default, and applies to all three document flows: purchase order synchronisation, the draft bill created when a purchase order is closed, and bill synchronisation.

When enabled, each line item's tax code maps as follows:

Jungle line item tax code Xero tax rate
GST GST on Expenses (10%)
GST_FREE GST Free Expenses
not set the Xero account's default rate

Because Jungle unit prices are GST-exclusive, documents created with this setting enabled are marked as tax-exclusive in Xero, so Xero adds GST on top of the line amounts where applicable.

When disabled (the default), no tax type is sent and every line item relies on the default tax rate of its Xero account, as before.

These tax rates are specific to Australian Xero organisations.

Location Filtering

If enabled, the Synchronize data for specific Jungle locations only option restricts synchronisation to the Jungle locations you select. The list shows your top-level locations, and selecting one includes every location inside it. When this option is not enabled, data from all locations is synchronised.

Locations that are disabled in Jungle are hidden from the list. Tick Show disabled locations to list and select them, for example a closed warehouse whose remaining stock movements and documents you still want in Xero. A disabled location is marked [disabled] in the list. A disabled location that you have already selected always stays in the list, so saving the configuration never drops it from the filter.

The filter applies to everything the app sends to Xero:

Data sent to Xero Location the filter checks
Daily manual journal: cost of goods sold, adjustments, and stock received (GRNI) The location of each stock movement or receipt
Purchase orders, and the draft bill created when a purchase order is closed The purchase order's ordered-to location
Bills The bill's ordered-to location
Credit notes for supplier returns The location the supplier return ships from

While the filter is enabled, a purchase order, bill or supplier return with no location in Jungle is not synchronised. The filter applies from the time you save it, and it does not remove anything already in Xero. A document from another location that reached Xero before you enabled the filter stays there, and the app no longer updates it.

One Jungle account can be connected to more than one Xero organisation, for example a head office organisation and a franchisee's own organisation. Each organisation has its own configuration, including its own location filter and sync options. When a purchase order, bill or supplier return changes in Jungle, every connected organisation checks it against its own filter and settings, so a franchisee's documents reach the franchisee's Xero and head office's reach head office's.

Sales Channel Filtering

If enabled, the Synchronize COGS for specific sales channels only option lets you restrict cost of goods sold (COGS) synchronisation to selected Jungle sales channels. When this option is not enabled, COGS from all sales channels is synchronised.

This applies to the COGS entries in the daily inventory-movement manual journal. Both fulfilment (consumed inventory from sales orders) and customer returns are filtered by the same selected channels, so the journal's debits and credits stay balanced. Movements that are not tied to a sales order — such as inventory adjustments and transfers — are always synchronised regardless of this setting. Movements whose originating order has no known sales channel are excluded while this option is enabled.

This setting can be combined with Location Filtering: a movement must satisfy both filters to be synchronised.

Inventory Adjustment Journal Lines

The Synchronize inventory adjustment journal lines option (enabled by default) controls whether inventory-adjustment entries are included in the daily manual journal. When unchecked, the adjustment-account lines from inventory adjustments are omitted entirely, leaving only the COGS entries (consumed inventory from sales orders, and received inventory for customer returns). Combined with Sales Channel Filtering, this lets a merchant send only the COGS for selected sales channels to a Xero account, and nothing else.

Split Journal Lines by Location

Use the Split manual journal lines by location option to break the daily manual journal down by location. When enabled, instead of one aggregated line per account, the journal has one line per (account, location) combination, with the location name included in the line description (e.g. CONSUME - Sydney Warehouse (Net Qty: 3)). Lines are grouped by the movement's top-level (warehouse) location. Movements that have no location are grouped under an Unassigned label.

The journal still balances and the total per account is unchanged — this option only changes how lines are split. When the option is disabled (the default), movements are aggregated into a single line pair per account, as before.

Location Tracking Categories

When Split manual journal lines by location is enabled, you can additionally map each top-level Jungle location to a Xero tracking category option. This tags each location's journal lines with the appropriate tracking option so you can report on the data by location within a single Xero organisation.

To configure it:

  1. Enable Split manual journal lines by location.
  2. Choose a Xero tracking category from the dropdown (only the org's active categories are listed).
  3. For each top-level Jungle location, choose the tracking option it should map to, or leave it as No tracking.

Only top-level (warehouse) locations are shown, since that is the level the journal is grouped by. Locations that are disabled in Jungle are hidden until you tick Show disabled locations; a disabled location that already has a mapping always stays listed, so saving the configuration keeps its mapping. Locations left as No tracking (or any location with no mapping) have their lines posted untagged. Aggregate totals per account are unchanged — tracking categories only tag the existing lines. If you turn off Split manual journal lines by location, the tracking-category mapping is ignored.

Purchase Orders

Whenever a purchase order is created in Jungle, this app will create the same purchase order in Xero. If the PO supplier doesn't yet exist in Xero, it will be created. Jungle will set the Xero purchase order number to the Jungle purchase order reference.

If the purchase order supplier already exists as a contact in Xero, the purchase order will be linked to that contact. If the contact doesn't already exist in Xero, it will be created.

If the Jungle purchase order has no supplier, it will be created in Xero against a contact called Default Jungle Supplier.

Whenever a purchase order is updated in Jungle, the updates will be applied in Xero.

If the Jungle purchase order has a status of Closed and the Automatically create a draft purchase bill in Xero when a Jungle purchase order is closed setting is enabled (the default), this app will also create a corresponding purchase bill (invoice) in Xero. The purchase bill will be created with a DRAFT status, and will be updated in Xero if the Jungle purchase order is modified thereafter. By default the bill carries every purchase order line at its ordered quantity; enable Received Quantities Only On Draft Bills to bill only the quantities that were actually received.

A new Xero purchase order or draft bill is only created once Xero has confirmed that none exists for the Jungle purchase order. If Xero cannot be reached or answers with an error (for example a rate limit), the sync is retried later rather than creating a duplicate.

Purchase order (and bill) line items will be created using the inventory account code configured in the app — bill line items use the GRNI Clearing Account instead when one is configured. You can set these account codes from the app's configuration page after authenticating with Xero. By default, Jungle does not explicitly set the tax rate on these line items and instead relies on the default tax rate for the account in question. Enable Line Item Tax Code Mapping to carry the tax code from the Jungle line items instead.

A purchase order line that has been cancelled in Jungle is left off the Xero purchase order and off the draft bill. Jungle keeps a cancelled line on the purchase order, listed under Cancelled Line Items; for example, when you edit a line and split it in two, the original line stays behind as cancelled. Only the active lines reach Xero, so the Xero totals match the Jungle totals. If a line is cancelled after the purchase order has been synchronised, the next update removes it from the Xero purchase order and from the draft bill while they are still editable in Xero.

Purchase Order Status

The status of a purchase order is mapped from Jungle to Xero as follows:

Jungle Status Xero Status
Draft DRAFT
Approved AUTHORISED
Submitted AUTHORISED
Accepted AUTHORISED
Closed BILLED
Voided DELETED

A purchase order whose line items have all been removed in Jungle before it has ever been synchronised to Xero is not created in Xero — Xero does not accept purchase orders without line items. For a closed purchase order, the draft purchase bill described above is still created when that setting is enabled (unless Received Quantities Only On Draft Bills is enabled, in which case a purchase order with nothing received produces no bill).

Bills

A Jungle bill is a distinct entity from a purchase order. When Enable synchronization of Jungle bills to Xero draft bills is enabled, this app creates a draft bill (an ACCPAY invoice) in Xero for each Jungle bill, and keeps it up to date as the bill changes in Jungle.

Jungle emits an event for the bill and for each of its line items, and the app reacts to all of them — so a bill that is edited line by line still ends up correct in Xero. Repeated events for the same unchanged bill are deduplicated, so the stream of events Jungle emits for one bill results in a single write to Xero.

The bill is created with a DRAFT status, using the Jungle bill's reference as the Xero invoice number. The Jungle bill's issue date and due date are carried across to the Xero bill's date and due date; if either is not set in Jungle, the corresponding Xero date is left for Xero to default. If a draft bill with that invoice number already exists in Xero for the same supplier, it is updated in place; if that supplier's bill exists in any other status, it is left untouched. Documents that merely share the number — a sales invoice, or a bill belonging to a different contact — are never touched: a new draft bill is created alongside them instead. Once a bill has been synced, the app records the Xero invoice's ID against the Jungle bill so the two stay linked. As for purchase orders, a new bill is only created once Xero has confirmed none exists — other failures (for example Xero being temporarily unavailable) are retried rather than creating a duplicate.

The bill supplier is resolved to a Xero contact the same way as for purchase orders — an existing contact is reused, otherwise a new one is created, and a bill with no supplier is created against the Default Jungle Supplier contact. Bill line items are created using the configured inventory account code — or the GRNI Clearing Account when one is configured — relying on that account's default tax rate unless Line Item Tax Code Mapping is enabled.

A bill line that has been cancelled in Jungle is left off the Xero bill. Jungle keeps a cancelled line on the bill, listed under Cancelled Line Items; for example, when you edit a line and split it in two, the original line stays behind as cancelled. Only the active lines reach Xero, so the Xero bill total matches the Jungle bill total. If a line is cancelled after the bill has been synchronised, the next update removes it from the Xero draft bill.

Xero Manual Journals From Jungle Inventory Movements

This app will synchronise inventory movement information from Jungle to Xero. The app will periodically retrieve Jungle inventory movements of relevant types, and will convert these to manual journal entries. Each day's movements become one draft manual journal, named Jungle Journal - YYYY-MM-DD after the day it covers (Australia/Brisbane time) and dated that day, so the journal lands in that day's accounts however late it is created. If the app regenerates a past day's journal, that journal keeps its own day as its date. These movements are mapped as follows:

Jungle Inventory Movement Xero Manual Journal Entry
Consumed inventory from sales orders Cost of inventory is added as a positive number to the COGS account, and a negative number to the inventory account
Received inventory for customer returns Cost of inventory is added as a negative number to the COGS account, and a positive number to the inventory account
Unpacked inventory from sales order allocations Cost of inventory is added as a negative number to the COGS account, and a positive number to the inventory account (reversing the original COGS entry)
Positive inventory adjustments Cost of inventory is added as a negative number to the adjustment account, and a positive number to the inventory account
Negative inventory adjustments Cost of inventory is added as a positive number to the adjustment account, and a negative number to the inventory account

If a GRNI Clearing Account is configured, supplier receipts and later changes to their expected cost are also journalled, on the day they happen:

Jungle Event Xero Manual Journal Entry
Stock received from a supplier Received cost is added as a positive number to the inventory account, and a negative number to the GRNI clearing account
Receipt matched to a bill or purchase order at a different price The price difference is added as a positive number (dearer) or negative number (cheaper) to the purchase price variance account, and the opposite to the GRNI clearing account
Receipt re-matched to a transfer or customer return Received cost is added as a negative number to the inventory account, and a positive number to the GRNI clearing account (reversing the original entry)

These lines appear as GRNI and GRNI VARIANCE in the journal.

If a Supplier Returns Clearing Account is configured, two further movement types are journalled:

Jungle Inventory Movement Xero Manual Journal Entry
Consumed inventory for supplier returns Cost of inventory is added as a positive number to the supplier returns clearing account, and a negative number to the inventory account
Unpacked inventory from supplier return allocations Cost of inventory is added as a negative number to the supplier returns clearing account, and a positive number to the inventory account (reversing the original entry)

A line pair whose amount rounds to $0.00 is left out of the journal, because Xero rejects a zero line. This happens when a day's movements of one type cancel out, for example an adjustment and its reversal on the same day. If every line rounds to $0.00, the app sends no journal for that day.

Inventory adjustments that reverse (unpack) an allocation to a transfer or customer return are not reflected in the manual journal. These are treated symmetrically with the original packing movements, which are also not journalled. Supplier return allocations follow the same rule unless a Supplier Returns Clearing Account is configured, as described above.

The COGS entries above (consumed inventory from sales orders, and received inventory for customer returns) can optionally be restricted to specific sales channels — see Sales Channel Filtering.

This app creates one manual journal per day in Xero. The app marks the start and end of day according to the AEST timezone.

By default, the entries above are aggregated into a single line pair per account. You can instead split them per location and tag each location's lines with a Xero tracking category — see Split Journal Lines by Location and Location Tracking Categories. This does not change the aggregate total per account; it only changes how the lines are split and tagged.

Journal line items are created with a tax rate of: BAS Excluded.

Credit Notes

When a supplier return is Approved in Jungle, this app will create a corresponding credit note in Xero. The credit note will be linked to the same supplier on the supplier return (in Xero this may create a new supplier if none exists with the same name and id).

Credit notes will include line items for each returned product, with quantities and pricing (cost price of the product). Line items use the configured inventory account code — or the Supplier Returns Clearing Account when one is configured. The tax rate is not explicitly set — it relies on the default tax rate for the account. The credit note will be created with a DRAFT status in Xero.

Credit notes in Xero will not be updated if they have any status other than DRAFT; however, credit notes with DRAFT status will be updated when line item changes occur. A new credit note is only created once Xero has confirmed none exists for the supplier return's reference — other failures are retried rather than creating a duplicate.