Create
Create an XvP settlement from an XvP add-on factory, add local and external flows, configure cutoff and HTLC details, then submit the reviewed settlement.
The XvP settlement wizard creates one settlement contract from a selected XvP add-on factory. Use the wizard when at least one leg settles on the current chain. Add external flows only for matching legs that settle on another chain under the same settlement terms.
The wizard has three steps: Asset Flows, Configuration, then Summary. You can move between steps while the draft is valid. If you leave the wizard before creating the settlement, the platform asks you to confirm because unsaved draft values are not submitted.
Prerequisites
- Access to the XvP Settlement add-on in the platform
- Permission to create settlements for the selected XvP add-on factory
- Wallet addresses for the parties sending and receiving assets
- Token contract addresses for the assets being exchanged
- For external flows: the external chain ID, token decimals, and either a precomputed hashlock or the raw secret used to derive one
- For V3 XvP factories: the ISO 3166-1 numeric country code for the settlement
Create a settlement
Open the XvP add-on page
In the sidebar, open the XvP add-on factory you want to use, then click Create Settlement.
The settlement is created against that factory. If you operate more than one XvP add-on factory, confirm that you are on the correct add-on page before opening the wizard.
Add asset flows
On the Asset Flows step, add the transfers that make up the settlement. Each flow needs a token address, a sender, a recipient, and an amount.
Click Add Local Flow for on-chain transfers, or Add External Flow for matching transfers on another chain.
Every settlement needs at least one local flow. The wizard keeps that last local row in place even when the exchange also includes external legs.
| Flow type | Purpose | Required fields | Amount precision |
|---|---|---|---|
| Local | A transfer executed by the current XvP settlement | Token address, sender wallet, recipient wallet, amount | Token symbol and decimals come from the asset |
| External | A matching transfer coordinated on another chain | Token address, sender wallet, recipient wallet, amount, chain ID, token decimals | Token decimals are entered before the amount field |
For larger exchanges, click Import Flows to upload JSON files. The wizard appends imported flows to the existing rows, accepts up to five files at a time, and previews each batch before you confirm.
Configure settlement options
On the Configuration step, enter the settlement-level details.
| Option | Description |
|---|---|
| Name | A clear settlement name, such as BOND-for-USDC Trade |
| Cutoff date | The future deadline after which the settlement can no longer proceed |
| Auto-execute | When enabled, the settlement executes automatically after required local approvals are complete. External-flow settlements also require the matching secret to be revealed. |
| Country | Shown for V3 XvP factories. Use the ISO 3166-1 numeric country code for the settlement. |
For V3 factories, confirm the country code on this step before continuing to the summary. The field is not shown for earlier factory versions.
If the settlement contains any external flow, select one HTLC mode:
- "Enter hashlock" when a counterparty has already shared the
0x-prefixed 32-byte hashlock for the external leg. - "Enter secret" when you want the platform to derive the hashlock from a raw secret that is at least 32 characters long. You can generate a mnemonic secret in the wizard or paste your own; the wizard shows the derived hashlock for review.
Review and create
On the Summary step, review the settlement before submission:
- Verify every asset address, wallet address, and amount, including the external chain value for any external flows.
- Confirm the cutoff date gives every sender enough time to approve.
- For external flows, confirm the hashlock matches the value expected by the counterparties.
Click Create and authenticate with your PIN or OTP to submit the transaction. The platform validates the final request before submission, including the local-flow requirement and the hashlock or secret requirement for settlements with external flows.
After creation
Once the transaction is submitted:
- The settlement appears in the XvP add-on settlement list once the creation transaction is processed and indexed.
- The settlement detail page shows the settlement ID, current status, and any pending approval steps for each flow.
- Senders for local flows can approve and lock their assets into the settlement.
- For external-flow settlements, coordinate the shared hashlock and secret handling with the counterparties responsible for the other chain.
Import flows from JSON
For complex settlements with many flows, you can import flow rows from JSON files.
- On Asset Flows, click Import Flows.
- Upload up to five
.jsonfiles. - Review the parsed flows in the import dialog.
- Click Import Flows to append them to the wizard.
Each file must contain a JSON array of flow objects. The import file contains flow rows only, not the settlement name, cutoff date, auto-execute setting, country, secret, or hashlock.
[
{
"type": "local",
"assetId": "0x1234567890abcdef1234567890abcdef12345678",
"assetSymbol": "USDC",
"assetDecimals": 6,
"from": "0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"to": "0xbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb",
"amount": "1000000"
},
{
"type": "external",
"assetId": "0x567890abcdef1234567890abcdef1234567890ab",
"from": "0xcccccccccccccccccccccccccccccccccccccccc",
"to": "0xdddddddddddddddddddddddddddddddddddddddd",
"amount": "500000000000000000",
"externalChainId": 1,
"externalAssetDecimals": 18
}
]Field reference:
| Field | Required for local | Required for external | Description |
|---|---|---|---|
type | Yes | Yes | "local" or "external" |
assetId | Yes | Yes | Token contract address (checksummed) |
from | Yes | Yes | Sender wallet |
to | Yes | Yes | Recipient wallet |
amount | Yes | Yes | Amount as a string in the token's smallest unit |
assetSymbol | Yes | No | Token symbol; required for display formatting |
assetDecimals | Yes | No | Token decimals; required for display formatting |
externalChainId | No | Yes | Chain ID for external flows |
externalAssetDecimals | No | Yes | Decimals for external flows |
Imported files must be valid JSON arrays. If a file is empty, malformed, not an array, or missing required fields, the wizard shows the validation error before import. Local flows must include assetSymbol and assetDecimals. The payload uses these fields to format the displayed amount.
Next steps
Once the settlement is created, senders for local flows must approve and lock their assets. See the walkthrough for a complete example of a local settlement from creation to execution.
Local senders must approve each outgoing flow before the settlement can execute. This page shows the approval steps and what to check for each flow type.
Follow a complete local settlement end to end, from creation through execution, with a worked example.