Builder codes
Builder codes, ownership, status, on-top fees, and approvals
Builder fee approvals
/accounts/{accountId}/builder-approvalsPath parameters
accountIdstringrequiredTrading account object id
Pattern^(0[xX])?[0-9a-fA-F]{1,64}$Example0xad23e722f3542ae36c276c1b303e30ae77c840a84db89c7215fa87bf92006691
Responses
Builder fee approvals for the account; empty array when none.
application/json
dataBuilderApproval[]requiredaccountIdstringrequiredPattern^0x[0-9a-f]{64}$Example0xad23e722f3542ae36c276c1b303e30ae77c840a84db89c7215fa87bf92006691builderIdstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example7nmaxFeeBpsstringrequiredBasis points (1/10000).
Pattern^-?(0|[1-9][0-9]*)n$Example8n
Example request
curl 'https://api.parchment.trade/accounts/0xad23e722f3542ae36c276c1b303e30ae77c840a84db89c7215fa87bf92006691/builder-approvals'const res = await fetch("https://api.parchment.trade/accounts/0xad23e722f3542ae36c276c1b303e30ae77c840a84db89c7215fa87bf92006691/builder-approvals");
const { data } = await res.json();Example response (200)
{
"data": [
{
"accountId": "0xad23e722f3542ae36c276c1b303e30ae77c840a84db89c7215fa87bf92006691",
"builderId": "7n",
"maxFeeBps": "8n"
}
]
}Builder owned by a wallet
/accounts/{walletAddress}/builderPath parameters
walletAddressstringrequiredWallet address
Pattern^(0[xX])?[0-9a-fA-F]{1,64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d
Responses
The wallet's builder object, or null. The same fields as the builder read.
application/json
datanull | Builderrequiredactivebooleanrequiredcodestring | nullfeeBpsstringrequiredBasis points (1/10000).
Pattern^-?(0|[1-9][0-9]*)n$Example8nidstringrequiredBuilder id.
Pattern^-?(0|[1-9][0-9]*)n$Example7nownerstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpayoutstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpendingstringrequiredBuilder cut parked for the payout address (base units).
Pattern^-?(0|[1-9][0-9]*)n$Example100000000nrevokeOpenbooleanrequiredselfServebooleanrequiredstatusstringrequiredOne ofactivepausedsuspendedtombstonedtotalEarnedstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example100000000n
Example request
curl 'https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builder'const res = await fetch("https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builder");
const { data } = await res.json();Example response (200)
{
"data": {
"active": true,
"code": "string",
"feeBps": "8n",
"id": "7n",
"owner": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"payout": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"pending": "100000000n",
"revokeOpen": true,
"selfServe": true,
"status": "active",
"totalEarned": "100000000n"
}
}Self-serve builder allowance
/accounts/{walletAddress}/builder-allowancePath parameters
walletAddressstringrequiredWallet address that creates self-serve codes
Pattern^(0[xX])?[0-9a-fA-F]{1,64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d
Responses
The wallet's self-serve allowance, counted like create_builder on chain: created live (not tombstoned) self-serve codes it registered, whoever owns them now (codes transferred to it do not count), limit (3) and remaining. n-suffixed decimal strings.
application/json
dataBuilderAllowancerequiredA wallet's self-serve builder allowance, counted like
create_builderon chain:createdlive (not tombstoned) self-serve codes it registered, whoever owns them now (codes transferred to it do not count),limitandremaining.createdstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example2nlimitstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example3nremainingstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example1n
Example request
curl 'https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builder-allowance'const res = await fetch("https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builder-allowance");
const { data } = await res.json();Example response (200)
{
"data": {
"created": "2n",
"limit": "3n",
"remaining": "1n"
}
}Builders controlled by a wallet
/accounts/{walletAddress}/buildersPath parameters
walletAddressstringrequiredBuilder owner wallet address
Pattern^(0[xX])?[0-9a-fA-F]{1,64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d
Responses
Builders controlled by the wallet; empty array when none.
application/json
dataBuilder[]requiredactivebooleanrequiredcodestring | nullfeeBpsstringrequiredBasis points (1/10000).
Pattern^-?(0|[1-9][0-9]*)n$Example8nidstringrequiredBuilder id.
Pattern^-?(0|[1-9][0-9]*)n$Example7nownerstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpayoutstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpendingstringrequiredBuilder cut parked for the payout address (base units).
Pattern^-?(0|[1-9][0-9]*)n$Example100000000nrevokeOpenbooleanrequiredselfServebooleanrequiredstatusstringrequiredOne ofactivepausedsuspendedtombstonedtotalEarnedstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example100000000n
Example request
curl 'https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builders'const res = await fetch("https://api.parchment.trade/accounts/0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d/builders");
const { data } = await res.json();Example response (200)
{
"data": [
{
"active": true,
"code": "string",
"feeBps": "8n",
"id": "7n",
"owner": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"payout": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"pending": "100000000n",
"revokeOpen": true,
"selfServe": true,
"status": "active",
"totalEarned": "100000000n"
}
]
}Builder by code
/builders/{code}Path parameters
codestringrequiredBuilder code
Responses
id, code, payout, owner, status, selfServe, feeBps, revokeOpen, active, pending, and totalEarned. id, feeBps, pending and totalEarned are n-suffixed decimal strings ("5000000n").
application/json
dataBuilderrequiredA registered builder.
activebooleanrequiredcodestring | nullfeeBpsstringrequiredBasis points (1/10000).
Pattern^-?(0|[1-9][0-9]*)n$Example8nidstringrequiredBuilder id.
Pattern^-?(0|[1-9][0-9]*)n$Example7nownerstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpayoutstring | nullPattern^0x[0-9a-f]{64}$Example0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0dpendingstringrequiredBuilder cut parked for the payout address (base units).
Pattern^-?(0|[1-9][0-9]*)n$Example100000000nrevokeOpenbooleanrequiredselfServebooleanrequiredstatusstringrequiredOne ofactivepausedsuspendedtombstonedtotalEarnedstringrequiredPattern^-?(0|[1-9][0-9]*)n$Example100000000n
Example request
curl 'https://api.parchment.trade/builders/string'const res = await fetch("https://api.parchment.trade/builders/string");
const { data } = await res.json();Example response (200)
{
"data": {
"active": true,
"code": "string",
"feeBps": "8n",
"id": "7n",
"owner": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"payout": "0x77b909b550ed11c45f1378c03c0954c0d77d320cdc938e35509564b1e505ce0d",
"pending": "100000000n",
"revokeOpen": true,
"selfServe": true,
"status": "active",
"totalEarned": "100000000n"
}
}