bridge/interfaces/WrapTokenOptions.md
Options for wrapping a token (e.g., MUSIC → GMUSIC)
Wrapping transfers a token from its native channel to the asset channel, converting it to its wrapped counterpart. This is required for tokens like MUSIC to be traded on the DEX.
Example
const result = await wrapService.wrapToken({
tokenId: '$MUSIC|Unit|none|none',
amount: '100.5',
});
Properties
| Property | Type | Description |
|---|---|---|
amount | string | Amount to wrap (decimal string, e.g., "100.5") |
recipient? | string | Optional GalaChain recipient address (defaults to the sender) |
tokenId | TokenClassKeyInput | Token to wrap (source token on native channel), by its class key: the pipe form ("$MUSIC|Unit|none|none") or the object ({ collection: '$MUSIC', ... }). A bare symbol ("MUSIC") is refused (INVALID_TOKEN_REFERENCE): symbols are not unique. |
token id class key input invalid reference