Skip to main content

Get Setup Contract Status

Reports the progress of a setup's contract deployment: for each deploy step, the status and error of its most recent transaction. Poll it after Create Node Setup or Deploy Setup Contracts; the deployment is finished when every step, executediamondcut last, is 3 (Done). For the deployed addresses use Get Setup Contracts.

The status is scoped to the setup, so a new setup on a wallet and network that already have a deployed setup reports its own progress.

Required permission: contract:deploy

Request​

GET /v2/admin/nodes/{node_id}/setups/{setup_id}/contracts/status

Parameters​

NameTypeInDescription
node_idstringpathRequired. The node's id
setup_idstringpathRequired. The setup's id

Headers​

NameDescription
AuthorizationRequired. Bearer <access_token>

Example​

curl --request GET \
--url '{{baseUrl}}/v2/admin/nodes/6a4bef2b1e781b11c22e9707/setups/6a552db09c6088e126a4be87/contracts/status' \
--header 'Authorization: Bearer <access_token>'

Response​

{
"data": {
"diamondcut": { "status": 3, "error": null },
"diamond": { "status": 3, "error": null },
"diamondloupe": { "status": 3, "error": null },
"ownership": { "status": 3, "error": null },
"fee": { "status": 3, "error": null },
"burn": { "status": 3, "error": null },
"rent": { "status": 4, "error": "insufficient funds for gas" },
"otc": { "status": null, "error": null },
"secondary": { "status": null, "error": null },
"listing": { "status": null, "error": null },
"executediamondcut": { "status": null, "error": null }
}
}

Response Fields​

FieldTypeDescription
dataobjectOne entry per deploy step, always all eleven: diamondcut, diamond, diamondloupe, ownership, fee, burn, rent, otc, secondary, listing, executediamondcut
data.<step>.statusinteger | nullStatus of the step's latest transaction: 1 Started, 2 InProgress, 3 Done, 4 Error, 5 PendingReceipt. null when the step has not been attempted yet
data.<step>.errorstring | nullFailure reason of that transaction, when it failed

A step in 4 is retried by calling Deploy Setup Contracts.

Errors​

Every refusal from this endpoint is answered with HTTP 409, whatever its code.

StatusCodeDescription
40910016node_id or setup_id is not a valid id
40910001Node not found, or the setup does not exist or belongs to another node (node domain 2)
40910005The node is outside your part of the hierarchy (node domain 2)
40910000Unexpected server-side failure

See Errors for the error format and common codes.