Submit Endpoint
Submit transactions directly to the blockchain with optional confirmation waiting.
Endpoint
POST /wallet/submit
Requires: Wallet & Agent API enabled, non-read-only key.
Overview
Submit raw EVM transactions directly to the blockchain. Unlike the Agent Prompt which uses natural language, this endpoint accepts explicit transaction parameters.
- Direct submission — Bypass the AI agent for pre-built transactions
- Synchronous response — Returns transaction hash immediately
- Optional confirmation — Wait for on-chain confirmation or return immediately
- Full control — Specify exact gas, nonce, and calldata
Request
{
"transaction": {
"to": "0x1234567890abcdef1234567890abcdef12345678",
"chainId": 8453,
"value": "1000000000000000000",
"data": "0x..."
},
"description": "Transfer 1 ETH",
"waitForConfirmation": true
}
| Field | Type | Description | Required |
|---|---|---|---|
transaction.to | string | Destination address | Yes |
transaction.chainId | number | Chain ID (8453=Base, 1=Ethereum, 137=Polygon, 130=Unichain, 480=World Chain, 42161=Arbitrum, 56=BNB Chain) | Yes |
transaction.value | string | Value in wei | No |
transaction.data | string | Calldata (hex string) | No |
transaction.gas | string | Gas limit | No |
transaction.gasPrice | string | Gas price (legacy) | No |
transaction.maxFeePerGas | string | Max fee per gas (EIP-1559) | No |
transaction.maxPriorityFeePerGas | string | Max priority fee (EIP-1559) | No |
transaction.nonce | number | Transaction nonce | No |
description | string | Human-readable description for logging | No |
waitForConfirmation | boolean | Wait for tx confirmation (default: true) | No |
Response
Success (200 OK)
{
"success": true,
"transactionHash": "0xabc123...",
"status": "success",
"blockNumber": "12345678",
"gasUsed": "21000",
"signer": "0x1234...5678",
"chainId": 8453
}
Access Control
- Read-only keys are rejected with 403
- Allowed recipients configured on the key will block ALL raw submissions (can't verify recipients from calldata). Use the Agent Prompt instead, which enforces allowed recipients through the agent.
Examples
curl
curl -X POST https://api.bankr.bot/wallet/submit \
-H "X-API-Key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"transaction": {
"to": "0x1234567890abcdef1234567890abcdef12345678",
"chainId": 8453,
"value": "1000000000000000000"
},
"description": "Send 1 ETH"
}'
Bankr CLI
bankr wallet submit tx --to 0x... --chain-id 8453 --value 1000000000000000000
bankr wallet submit json '{"to":"0x...","chainId":8453,"value":"1000000000000000000"}'
Backward Compatibility
POST /agent/submit still works but is deprecated and requires walletApiEnabled.