Knit API Documentation
Step 1: Create CPN Wallet
{{baseUrl}}/api/v1/managed-signing/walletsCreate a managed signing wallet for CPN integration. This wallet will hold your USDC and sign payment authorizations.
Headers
X-API-KEY: Your API key for authentication.Accept: Set toapplication/jsonto receive responses in JSON format.Content-Type: Set toapplication/json.
Request Body
{
"type": "EVM",
"networks": ["MATIC_MAINNET"],
"merchantCallbackUrl": "https://your-domain.com/cpn-callback"
}| Field | Type | Required | Description |
|---|---|---|---|
type | string | Yes | Must be EVM for CPN |
networks | array | Yes | Include MATIC_MAINNET for Polygon CPN |
merchantCallbackUrl | string | No | URL for receiving signing callbacks |
Sample Request
curl --location -g '{{baseUrl}}/api/v1/managed-signing/wallets' \
--header 'X-API-KEY: {{apiKey}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"type": "EVM",
"networks": ["MATIC_MAINNET"],
"merchantCallbackUrl": "https://your-domain.com/cpn-callback"
}'Sample Response
Sample Response
{
"statusCode": 201,
"message": "Wallet created",
"data": {
"id": "<local-wallet-id>",
"businessId": "<business-id>",
"type": "EVM",
"networks": ["MATIC_MAINNET"],
"network": "MATIC_MAINNET",
"address": "0x...",
"hdPath": "m/44'/60'/0'/0/0",
"keyId": "<key-id>",
"isActive": true,
"merchantCallbackUrl": "https://your-domain.com/cpn-callback",
"createdAt": "2026-01-20T18:30:40.912Z",
"updatedAt": "2026-01-20T18:30:40.912Z"
},
"success": true
}Important
- Save the
id(local wallet ID) - you'll need it for all subsequent API calls - Save the
address- this is your wallet's blockchain address for receiving USDC - Fund this wallet with MATIC for gas (needed for the one-time Permit2 approval)
Next Step
Proceed to Create Policy to configure CPN-specific signing rules.