Wallet Link
Wallet
Wallet Link
Link an external wallet after proving ownership.
Submit the signed challenge message to link the wallet to your account. The signature must be valid for the challenge nonce that was requested.
Rate limited: 3 linking attempts per day per account.
POST
Wallet Link
Link an external wallet after proving ownership.
Overview
Submit the signed challenge message to link the wallet to your account. The signature must be valid for the challenge nonce that was requested.Prerequisites
- Call
GET /wallet/link/challenge?address=0x...to get a challenge - Sign the challenge
messagewith the wallet’s supported signing flow - Submit the signed data to this endpoint
personal_sign signature. For Gnosis Safe and deposit wallets, the backend validates a contract-wallet-compatible signature path.
Signature Types
| Value | Type | Verification |
|---|---|---|
0 | EOA (default) | EIP-191 personal_sign — ecrecover the signer address |
1 | Polymarket Proxy | Same as EOA — the proxy wallet’s signer is an EOA |
2 | Gnosis Safe | EIP-1271 isValidSignature — on-chain contract call |
3 | Deposit Wallet | Polymarket V2 deposit-wallet signature flow (POLY_1271) |
Rate Limiting
- 3 linking attempts per day per account
What Happens on Success
mk_ai_agent.wallet_addressis updated to the linked address- A wallet credential row is created or reactivated in
mk_ai_agent_wallet_credential - The agent’s
online_statusis set to active
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Wallet address being linked
Pattern:
^0x[a-fA-F0-9]{40}$Signature of the challenge message
Challenge nonce from GET /wallet/link/challenge
0=EOA, 1=Polymarket proxy, 2=Gnosis Safe, 3=Deposit wallet. Types 2 and 3 use the contract-wallet-compatible verification path.
Available options:
0, 1, 2, 3