# Payment advice: Sync to WeClapp (allocation write-back)

Sync payment advice allocations to WeClapp with retry controls.

After you link a **payment advice** to a **bank transaction** and confirm allocations, **Sync to weclapp** pushes payment applications to WeClapp. A background job processes the queue. If a job stays **queued** more than **five minutes**, Cortena offers **Retry** or **Cancel**.

**Who this is for:** AR ops using WeClapp OPOS who want Cortena-matched payment advice lines written back as allocations without re-keying in WeClapp.

Related: [Open items and payment write-back staging](https://help.cortena.ai/guides/advanced/open-items-write-back) and [Payment advice workspace](https://help.cortena.ai/guides/advanced/payment-advice-workspace).

## 1. Prerequisites

1. **Settings → Integrations → WeClapp** connected with API access.
2. Payment advice **matched** to receivable invoice lines (or hydrated WeClapp sales invoices).
3. **Bank transaction linked** to the payment advice (required for confirm and sync). See [Open items and payment write-back staging](https://help.cortena.ai/guides/advanced/open-items-write-back).

## 2. Sync to weclapp

1. Open the payment advice in **Receivables → Payment advices** (workspace).
2. Review line allocations and totals.
3. Click **Sync to weclapp**.

Cortena enqueues **allocation write-back**. The UI shows progress (queued → processing → completed or failed).

When the linked bank account is a WeClapp bank, prefer **Create payment application** semantics on each open item line.

## 3. Stuck queued (5 minutes)

If status remains **Queued** for more than **five minutes** after deploy or network issues:

1. Open the payment advice **Activity** or sync strip.
2. Choose **Retry** to re-enqueue write-back, or **Cancel** to abandon the stuck job and fix data before trying again.

Cancel does not delete the payment advice. It clears the stuck queue entry so you can edit links or allocations.

## Tips and limitations

- Write-back requires correct WeClapp customer and invoice mapping on each line.
- Multi-customer advices: see [Multi-customer payment advice sync to WeClapp](https://help.cortena.ai/guides/advanced/multi-customer-payment-advice-weclapp).
- Auto-settle when WeClapp already shows paid: [Payment advice auto-settle](https://help.cortena.ai/guides/advanced/payment-advice-auto-settle).

## Quick reference

| Task | Where |
| --- | --- |
| Sync | Payment advice workspace → **Sync to weclapp** |
| Bank link required | **Banking** reconciliation or PA link |
| Stuck queue | **Retry** / **Cancel** after 5 min queued |
| Per-invoice | **Receivables → Open items** → **Sync to weclapp** |
