Skip to main content
The Transfer workflow moves holdings of an instrument from a sender to a receiver. Transfers use the Canton Network Token Standard, so wallets and apps can integrate them through either the V1 (CIP-56) or the V2 (CIP-112) Standard API.

Overview

When the sender creates a transfer, the Registry App picks the kind of transfer in this order:
You can jump straight to a section: API integration · Transfer pre-approval · Transfer · Troubleshooting.
To merge holding UTXOs, transfer the combined amount to yourself with all holdings to merge as inputHoldingCids. The input holdings may have different labels. The result is a single holding carrying the label set as receiver label. If the transfer amount is smaller than the sum of the input amounts, the rest is left as change on the specified sender account.

Prerequisites

For all transfers:
  • The registrar must have created the AllocationFactory contract, see Token Standard APIs.
  • The input holdings must be unlocked, belong to the sender, and cover the transfer amount.
  • The sender and receiver accounts must be registry accounts.
  • requestedAt must be in the past, and the transfer must complete before executeBefore.
In addition, for direct and offer transfers:
  • The registrar must have created the TransferRule contract for the instrument.
  • The sender and the receiver must satisfy the instrument’s holder credential requirements. If no holder credential requirements are defined, the credential check passes for any party. See How Requirements Are Evaluated.
  • The instrument must not be paused. While it’s paused, only the registrar can create transfer offers as the sender, and direct transfers and offer acceptances only succeed if the registrar is the receiver.
  • If the blocklist check is enabled for the instrument, neither the sender nor the receiver may be on the registrar’s blocklist.

API integration

The Registry App implements both versions of the Token Standard transfer API: Use V2 if the registrar supports it, and fall back to V1 otherwise. To check which versions a registrar supports, call the GET /api/token-standard/v0/registrars/{registrarParty}/registry/metadata/v1/info endpoint, as outlined in Token Standard APIs. Every API step follows the same pattern:
  1. Call the Token Standard off-ledger API to get the factory or choice context and the contracts that must be disclosed.
  2. Exercise the interface choice through the JSON Ledger API, passing the choice context in extraArgs.context and the contracts in disclosedContracts.
The endpoint paths are relative to the base URL of your environment, see Base URLs. Replace {registrarParty} with the party ID of the instrument admin.
For offers and self-transfers, the factory is the registrar’s AllocationFactory contract. Despite its name, it implements the Token Standard TransferFactory interfaces as well as the allocation interfaces, and it is also used for mints and burns. The name is kept for backwards compatibility. For direct transfers, the factory is the receiver’s TransferPreapproval contract.

Set up a transfer pre-approval

A receiver can pre-approve incoming transfers so they complete directly, without accepting each transfer offer. A pre-approval only covers transfers to the receiver’s basic account, that is, transfers with an empty receiver account ID (""). Transfers to any other account of the receiver always create a transfer offer. A pre-approval covers one instrument admin and either up to 10 specific instruments, or all instruments of that admin if no instruments are listed.
Transfer pre-approvals are specific to the Registry App and are not part of the Token Standard. Wallet providers must integrate the TransferPreapproval template directly.
  1. Go to Preapprovals and click Create Preapproval.
  2. Select the instrument admin.
  3. Optionally, enter up to 10 instrument IDs. Leave this empty to pre-approve all instruments of the admin.
  4. Submit the pre-approval.

Transfer

The sender creates the transfer. For transfer offers, the receiver then accepts or rejects it.
1

Sender creates the transfer

  1. Go to Transfers and click Create Transfer. The Offer a Transfer dialog opens.
  2. Select the instrument.
  3. Select the sender holding label, which is the account ID to send from. The transfer is sent from holdings with this label, and the amount is capped to their balance.
  4. Enter the receiver and the amount to transfer.
  5. Optionally, enter a receiver label, which is the receiver’s account ID. Leave it empty to transfer to the receiver’s basic account.
  6. Set Execute before: 3 days, 7 days, or a custom date.
  7. Optionally, enter a reference.
  8. Submit the transfer.
If the receiver label is empty and the receiver has a matching pre-approval, the transfer completes directly. Otherwise, the transfer offer is listed under Transfers until the receiver accepts or rejects it, or you withdraw it.
2

Receiver accepts or rejects the transfer offer

Only needed if the transfer kind is offer.
  1. Go to Transfers and select the transfer offer.
  2. Click Accept or Reject.
After acceptance, the holding is shown under Holdings for the receiver. After rejection, the sender’s holdings are unlocked.
3

Optional: Sender withdraws the transfer offer

The sender can withdraw a transfer offer until the receiver accepts it. The sender’s holdings are unlocked.
Go to Transfers, select the transfer offer, and click Withdraw.

Labels

A label is the account ID of a holding. It is the id of the sender or receiver Account in the V2 API, and the label of the resulting Holding contract. Labels let a party keep holdings of the same instrument in separate accounts. The basic account of a holding is the account with the holding’s owner as the owner, the account ID "", and no provider. See Accounts and Labels.
  • The sender sets both the sender label and the receiver label when creating the transfer. They are part of the transfer, and TransferInstruction_Accept doesn’t take a label, so the receiver can’t change the receiver label when accepting a transfer offer.
  • If no label is set, the basic account with account ID "" is used.
  • Through the API, input holdings may have any label. Holdings with a different label are faded in to the sender account before the transfer, see Input Holdings and Fade-in. The dApp UI only selects input holdings that match the sender label.
  • Transfer pre-approvals only apply to transfers to the receiver’s basic account. A transfer only completes directly through a pre-approval if the receiver label is "". Otherwise, a transfer offer is created.
  • The sender and receiver accounts must be registry accounts.
  • V1 wallets are unaware of accounts. See V1 wallet compatibility for how mixed input labels are handled.

Troubleshooting

Next steps