Get account contract packages
Get a paginated list of account contract packages.
GET /accounts/{public_key}/contract-packages
This endpoint allows you to retrieve a paginated list of account contract packages. You can filter the results by owner public key, specify the page number and size, and choose the sorting order and field. Additionally, you can include optional deploys number data in the response. The example shows a sample response with relevant details for each contract package, including contract package hash, owner public key, name, description, metadata, latest version contract type ID, timestamp, icon URL, and deploys number.
Query params
None
Sorting
timestamp
Sort contract packages by timestamp.
Default sorting is timestamp DESC
Optional properties
deploys_number
int
account_info
ContractPackage owner account info
centralized_account_info
ContractPackage centralized account info
cspr_name
string
Owner's primary CSPR.name
Response
PaginatedResponse
<ContractPackage>
Example
curl -X 'GET' \
'https://api.testnet.cspr.cloud/account/017E80955A6D493A4A4B9F1B5DD23D2EDCDC2C8B00FCD9689F2F735F501BD088C5/contract-packages' \
-H 'Accept: application/json' \
-H 'Authorization: your_access_token_here'
{
"data": [
{
"contract_package_hash": "0038a63a09e0b600158d4648745930239aba43eb7a5e725ab1af12b49077100c",
"owner_public_key": "017e80955a6d493a4a4b9f1b5dd23d2edcdc2c8b00fcd9689f2f735f501bd088c5",
"name": null,
"description": null,
"metadata": {},
"latest_version_contract_type_id": null,
"timestamp": "2023-04-12T05:38:48Z",
"icon_url": null,
"website_url": null
},
{
"contract_package_hash": "004f02d03d1011ea71397363a34fbf038496be30ee2b1d88820c37cc9b9daeee",
"owner_public_key": "017e80955a6d493a4a4b9f1b5dd23d2edcdc2c8b00fcd9689f2f735f501bd088c5",
"name": "Wrap BTC",
"description": null,
"metadata": {
"name": "Wrap BTC",
"symbol": "WBTC",
"decimals": 8,
"balances_uref": "uref-4744c56c1ca94c6c1f3d2076d8b3fe474b03a86736143ad1921505b71b693b1f-007",
"total_supply_uref": "uref-f3771de0504c0dd74feb56f6e327add0ba89562022ff2816e98a8700673124e3-003"
},
"latest_version_contract_type_id": 2,
"timestamp": "2023-03-31T08:22:32Z",
"icon_url": null,
"website_url": null
},
...
{
"contract_package_hash": "0342537e19667f5c9b5ab976e302bcdfce04b5e681a6c535d330ae0c534203ab",
"owner_public_key": "017e80955a6d493a4a4b9f1b5dd23d2edcdc2c8b00fcd9689f2f735f501bd088c5",
"name": null,
"description": null,
"metadata": {},
"latest_version_contract_type_id": null,
"timestamp": "2022-11-11T05:14:46Z",
"icon_url": null,
"website_url": null
}
],
"item_count": 459,
"page_count": 46
}
Last updated