Contract

The Contract stream provides updates about newly added contracts

GET /contracts

Optional properties

None

Query params

PropertyTypeDescription

contract_package_hash

string

Comma-separated list of contract packages

deploy_hash

string

Comma-separated list of deploy hashes

Events

EventDescription

created

Notifies about a newly added contract

Response

WebSocketMessage<Contract>

Example

wscat -c 'wss://streaming.testnet.cspr.cloud/contracts?contract_package_hash=dd631e240a22c300b703b7999e2e979b2906b76ff37efbe8dc5c1dba09438615' \
  -H 'authorization: 55f79117-fc4d-4d60-9956-65423f39a06a'
{
  "data": {
    "contract_hash": "3cbc06931a08459595f5ce393077578dc90aa07090de244d1868ccaf83e02751",
    "contract_package_hash": "dd631e240a22c300b703b7999e2e979b2906b76ff37efbe8dc5c1dba09438615",
    "deploy_hash": "71d954db5263876d74d8553f92ba12d5dd2f0df8ad030b0f5aa5687d87da696e",
    "contract_type_id": null,
    "timestamp": "2022-05-05T16:23:14.532Z",
    "contract_version": 1,
    "is_disabled": false
  },
  "action": "created",
  "extra": null,
  "timestamp": "2024-02-26T12:19:11.936636143Z"
}

Last updated