Swing Points Program is Live 🚀 Learn More →

Sign

Deprecated
post
https://swap.prod.swing.xyz
/v0/transfer/sign

Generate a signature required by the claim. This is only required for transactions routing through the WORMHOLE bridge.

bridge
string
required
txId
string
required

Transaction hash

Example:
0x00000....000
userAddress
string
required

User's wallet address

useNativeTokenToClaim
boolean

Only required if bridge is cross swap. Default false which will use relayer fee

fromChain
string
required

Source chain slug

Example:
ethereum
toChain
string
required

Dest chain slug. Only required in Wormhole bridge. Optional in Nxtp bridge

Example:
ethereum
txHash
string
required

Transaction Hash returned by signer (e.g. metamask) on source chain.

OK

hash
string
required

hash of the signature that will be the input of the claim function

relayerFee
string

relayer fee of the signature that will be the input of the claim function

useNativeTokenToClaim
boolean

This will be used in '/claim' endpoint

associatedTokenTx
string

Unsigned tx data to create associated token account. This is the optional, only for Solana

Body
curl --request POST \
--url https://swap.prod.swing.xyz/v0/transfer/sign \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"bridge": "string",
"txId": "0x00000....000",
"userAddress": "string",
"useNativeTokenToClaim": true,
"fromChain": "ethereum",
"toChain": "ethereum",
"txHash": "string"
}'
Response Example
1
{
2
"hash": "0x2657fff6d3aaa4caf12960ddc810d2cf5c00e725aae84a5ac34fbead7e1b4671",
3
"relayerFee": "300000",
4
"useNativeTokenToClaim": false
5
}