Deploy the caller's Polymarket deposit wallet and set its trading approvals
Creates the user’s deposit wallet — a per-user ERC-1967 proxy on Polygon, deployed through Polymarket’s relayer at a deterministic CREATE2 address derived from the owner EOA. Two relayer operations run: the deployment, then a signed batch setting the CTF/collateral approvals the venue needs.
Idempotent on the deployment leg. Re-submitting for an already-deployed owner is treated as a no-op success and comes back with deploy_tx_id: null.
It does not move user funds — it deploys a contract and grants approvals. The approval batch is signed server-side under the user’s delegated key; the batch deadline window is one hour, and each relayer transaction is waited on for up to 120 s.
A successful response means the submitted approval batch has confirmed. batch_tx_id is empty when no batch was submitted.
Auth & scope. Requires trade:execute for polymarket, identity ownership, and the mutation gate.
curl --request POST \
--url https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>' \
--data '
{
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnkey_org_id": "<string>",
"owner_address": "<string>"
}
'import requests
url = "https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard"
payload = {
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnkey_org_id": "<string>",
"owner_address": "<string>"
}
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
user_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
turnkey_org_id: '<string>',
owner_address: '<string>'
})
};
fetch('https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard', 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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard",
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([
'user_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'turnkey_org_id' => '<string>',
'owner_address' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Api-Key: <api-key>",
"X-Api-Secret: <api-key>",
"X-Client-Id: <api-key>"
],
]);
$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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard"
payload := strings.NewReader("{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"deposit_wallet_address": "<string>",
"batch_tx_id": "<string>",
"success": true,
"deploy_tx_id": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "Unauthorized"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}Authorizations
Credential client id (kairos_ck_...). Must be sent together with X-Api-Key and X-Api-Secret.
64-char hex API key.
64-char hex API secret.
Body
The common identity body shared by the deposit-wallet endpoints. All three fields are checked against the authenticated caller and can only ever CONFIRM authority, never grant it — omitting them is not an option here, but supplying someone else's is a 403.
Response
Wallet deployed (or already present) and approvals submitted.
Response for POST /exchanges/polymarket/deposit-wallet/onboard.
The deterministic (CREATE2) ERC-1967 proxy address for this owner.
Relayer transaction id for the confirmed trading-approval batch. Empty when no batch was submitted (approvals already present or optional approvals skipped).
Relayer transaction id for the proxy deployment. null when the wallet was already deployed — the relayer is idempotent and that case is treated as success.
Was this page helpful?
curl --request POST \
--url https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: <api-key>' \
--header 'X-Api-Secret: <api-key>' \
--header 'X-Client-Id: <api-key>' \
--data '
{
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnkey_org_id": "<string>",
"owner_address": "<string>"
}
'import requests
url = "https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard"
payload = {
"user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turnkey_org_id": "<string>",
"owner_address": "<string>"
}
headers = {
"X-Client-Id": "<api-key>",
"X-Api-Key": "<api-key>",
"X-Api-Secret": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Client-Id': '<api-key>',
'X-Api-Key': '<api-key>',
'X-Api-Secret': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
user_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
turnkey_org_id: '<string>',
owner_address: '<string>'
})
};
fetch('https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard', 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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard",
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([
'user_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'turnkey_org_id' => '<string>',
'owner_address' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-Api-Key: <api-key>",
"X-Api-Secret: <api-key>",
"X-Client-Id: <api-key>"
],
]);
$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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard"
payload := strings.NewReader("{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Client-Id", "<api-key>")
req.Header.Add("X-Api-Key", "<api-key>")
req.Header.Add("X-Api-Secret", "<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://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard")
.header("X-Client-Id", "<api-key>")
.header("X-Api-Key", "<api-key>")
.header("X-Api-Secret", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://execution.kairos.trade/exchanges/polymarket/deposit-wallet/onboard")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Client-Id"] = '<api-key>'
request["X-Api-Key"] = '<api-key>'
request["X-Api-Secret"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"user_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"turnkey_org_id\": \"<string>\",\n \"owner_address\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"deposit_wallet_address": "<string>",
"batch_tx_id": "<string>",
"success": true,
"deploy_tx_id": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "Unauthorized"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}{
"error": "<string>",
"error_details": {
"code": "FUNDS_INSUFFICIENT_USDC",
"message": "<string>",
"actions": [
{
"action": "enable_trading",
"label": "Add Funds",
"primary": true,
"url": "<string>"
}
],
"details": "<string>",
"metadata": {}
},
"code": "<string>"
}
