curl --request POST \
--url https://api-partner.houdiniswap.com/v2/dex/chainSignatures \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"quoteId": "69a02882f48d56c923119d95",
"addressFrom": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"previousSignature": {
"signature": "<string>",
"key": "<string>",
"swapRequiredMetadata": {}
},
"signatureKey": "permit",
"signatureStep": 1
}
'import requests
url = "https://api-partner.houdiniswap.com/v2/dex/chainSignatures"
payload = {
"quoteId": "69a02882f48d56c923119d95",
"addressFrom": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"previousSignature": {
"signature": "<string>",
"key": "<string>",
"swapRequiredMetadata": {}
},
"signatureKey": "permit",
"signatureStep": 1
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
quoteId: '69a02882f48d56c923119d95',
addressFrom: '0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40',
previousSignature: {signature: '<string>', key: '<string>', swapRequiredMetadata: {}},
signatureKey: 'permit',
signatureStep: 1
})
};
fetch('https://api-partner.houdiniswap.com/v2/dex/chainSignatures', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-partner.houdiniswap.com/v2/dex/chainSignatures",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'quoteId' => '69a02882f48d56c923119d95',
'addressFrom' => '0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40',
'previousSignature' => [
'signature' => '<string>',
'key' => '<string>',
'swapRequiredMetadata' => [
]
],
'signatureKey' => 'permit',
'signatureStep' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-partner.houdiniswap.com/v2/dex/chainSignatures"
payload := strings.NewReader("{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-partner.houdiniswap.com/v2/dex/chainSignatures")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-partner.houdiniswap.com/v2/dex/chainSignatures")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}"
response = http.request(request)
puts response.read_body[
{
"key": "permit",
"type": "chained",
"step": 1,
"totalSteps": 2,
"isComplete": false,
"data": {
"primaryType": "Permit",
"domain": {
"name": "USD Coin",
"version": "2",
"chainId": 1,
"verifyingContract": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48"
},
"types": {
"Permit": [
{
"name": "owner",
"type": "address"
},
{
"name": "spender",
"type": "address"
},
{
"name": "value",
"type": "uint256"
},
{
"name": "nonce",
"type": "uint256"
},
{
"name": "deadline",
"type": "uint256"
}
]
},
"message": {
"owner": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"spender": "0x1111111254eeb25477b68fb85ed929f73a960582",
"value": "1000000000",
"nonce": "3",
"deadline": "1767225600"
}
}
}
]{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"fields": {},
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}Get next chain signature
Returns the next signature in a multi-step chain, for swaps needing more than one (e.g. permit + bridge).
- only needed when Get token approval data returned a signature of type
CHAINED - sign the returned data, post it back, repeat until
isCompleteis true
curl --request POST \
--url https://api-partner.houdiniswap.com/v2/dex/chainSignatures \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"quoteId": "69a02882f48d56c923119d95",
"addressFrom": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"previousSignature": {
"signature": "<string>",
"key": "<string>",
"swapRequiredMetadata": {}
},
"signatureKey": "permit",
"signatureStep": 1
}
'import requests
url = "https://api-partner.houdiniswap.com/v2/dex/chainSignatures"
payload = {
"quoteId": "69a02882f48d56c923119d95",
"addressFrom": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"previousSignature": {
"signature": "<string>",
"key": "<string>",
"swapRequiredMetadata": {}
},
"signatureKey": "permit",
"signatureStep": 1
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
quoteId: '69a02882f48d56c923119d95',
addressFrom: '0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40',
previousSignature: {signature: '<string>', key: '<string>', swapRequiredMetadata: {}},
signatureKey: 'permit',
signatureStep: 1
})
};
fetch('https://api-partner.houdiniswap.com/v2/dex/chainSignatures', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-partner.houdiniswap.com/v2/dex/chainSignatures",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'quoteId' => '69a02882f48d56c923119d95',
'addressFrom' => '0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40',
'previousSignature' => [
'signature' => '<string>',
'key' => '<string>',
'swapRequiredMetadata' => [
]
],
'signatureKey' => 'permit',
'signatureStep' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api-partner.houdiniswap.com/v2/dex/chainSignatures"
payload := strings.NewReader("{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api-partner.houdiniswap.com/v2/dex/chainSignatures")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-partner.houdiniswap.com/v2/dex/chainSignatures")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"quoteId\": \"69a02882f48d56c923119d95\",\n \"addressFrom\": \"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40\",\n \"previousSignature\": {\n \"signature\": \"<string>\",\n \"key\": \"<string>\",\n \"swapRequiredMetadata\": {}\n },\n \"signatureKey\": \"permit\",\n \"signatureStep\": 1\n}"
response = http.request(request)
puts response.read_body[
{
"key": "permit",
"type": "chained",
"step": 1,
"totalSteps": 2,
"isComplete": false,
"data": {
"primaryType": "Permit",
"domain": {
"name": "USD Coin",
"version": "2",
"chainId": 1,
"verifyingContract": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48"
},
"types": {
"Permit": [
{
"name": "owner",
"type": "address"
},
{
"name": "spender",
"type": "address"
},
{
"name": "value",
"type": "uint256"
},
{
"name": "nonce",
"type": "uint256"
},
{
"name": "deadline",
"type": "uint256"
}
]
},
"message": {
"owner": "0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40",
"spender": "0x1111111254eeb25477b68fb85ed929f73a960582",
"value": "1000000000",
"nonce": "3",
"deadline": "1767225600"
}
}
}
]{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"fields": {},
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}{
"message": "<string>",
"code": "<string>",
"requestId": "<string>"
}Authorizations
Send Authorization: <ApiKey>:<ApiSecret> — joined by a colon, raw. No Bearer prefix, no base64.
Body
Quote ID from a prior quote response.
"69a02882f48d56c923119d95"
EVM address from which the amount will be deducted
^0x[0-9a-fA-F]{40}$"0xb7dE6b6eEBF7401aFea5a49D6405C9048fEf2d40"
Previous signature object from the wallet signing step
Show child attributes
Show child attributes
Key for the signature in the chain, returned from the previous approve or chainSignatures call
"permit"
Step number in the signature chain sequence
x >= 01
Response
The next signature in the chain
The EIP-712 payload for the wallet to sign.
Show child attributes
Show child attributes
single — sign it and you are done. chained — sign it, then call Get next chain signature for the next one.
single, chained How many signatures this chain needs in total. 1 for a single signature.
Which signature this is, counting from 1.
True on the last signature of the chain — stop asking for more once you see it.
Identifies this signature. Pass it as key to Get next chain signature to fetch the next step.
Provider data attached to this signature. Send it back unchanged with the signed result — the swap fails without it.
Show child attributes
Show child attributes