info_get_deploy

This method retrieves a Deploy from a network. It requires a deploy_hash to query the Deploy.

This method will use 10 Compute Units.


Reference: Here

Parameters

  1. deploy_hash - string The deploy hash

  2. finalized_approvals - boolean Determines whether to return the Deploy with the finalized approvals substituted (Optional)

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "info_get_deploy",
  "params": [
    "30a84ef0e046b5d700ad176096db87118df3f25a20b15b2d5579194aae199c2b",
    true
  ]
}

Returned Value

  • api_version - string RPC API version

  • deploy - item containing a smart contract along with the requester's signature(s)

    • approvals - list of structs containing a signature and the public key of the signer

      • signature - string hex-encoded cryptographic signature, including the algorithm tag prefix

      • signer - string hex-encoded public key including algorithm tag prefix

    • hash - hex-encoded Deploy hash

    • header - the header portion of a Deploy

      • account - string hex-encoded public key including algorithm tag prefix

      • body_hash - string body hash digest

      • chain_name - string A user defined string

      • dependencies - list of hex-encoded Deploy hash dependencies

      • gas_price - integer

      • timestamp - string RFC 3339 timestamp

      • ttl - string human-readable duration

    • payment - Represents possible variants of an executable Deploy

      • ModuleBytes - Executable specified as raw bytes that represent WASM code and an instance of RuntimeArgs

        • module_bytes - Hex-encoded raw WASM bytes. There are some special cases around passing module_bytes for payment code

        • args - list of runtime arguments

    • session

      • Transfer - A native transfer which does not contain or reference a WASM code

        • args - list of runtime arguments

  • execution_results - list of ExecutionResult

    • block_hash - hash of the block

    • result - The result of executing a single Deploy

      • effect

      • transfers - list of transfer addresses

      • cost - string

{
  "jsonrpc": "2.0",
  "result": {
    "api_version": "1.4.13",
    "deploy": {
      "approvals": [
        {
          "signature": "0285d7731f32cc593d8aa0f29c1fcea2fbbd5aea3fb8f200eb239551e564df2fa77f9b4c7dc5306d3f247e7cca8a9644b241e2ac65e0b301b96a4d32d74f131a00",
          "signer": "0203f3f44c9e80e2cedc1a2909631a3adea8866ee32187f74d0912387359b0ff36a2"
        }
      ],
      "hash": "30a84ef0e046b5d700ad176096db87118df3f25a20b15b2d5579194aae199c2b",
      "header": {
        "account": "0203f3f44c9e80e2cedc1a2909631a3adea8866ee32187f74d0912387359b0ff36a2",
        "body_hash": "322eaebfafefcc2b3ca36c8b87c390cb54efe791919acf754dec0fef377fbf76",
        "chain_name": "casper",
        "dependencies": [],
        "gas_price": 1,
        "timestamp": "2023-05-10T19:00:24.011Z",
        "ttl": "30m"
      },
      "payment": {
        "ModuleBytes": {
          "args": [
            [
              "amount",
              {
                "bytes": "0400e1f505",
                "cl_type": "U512",
                "parsed": "100000000"
              }
            ]
          ],
          "module_bytes": ""
        }
      },
      "session": {
        "Transfer": {
          "args": [
            [
              "amount",
              {
                "bytes": "050038d2aef5",
                "cl_type": "U512",
                "parsed": "1055200000000"
              }
            ],
            [
              "target",
              {
                "bytes": "a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91",
                "cl_type": {
                  "ByteArray": 32
                },
                "parsed": "a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91"
              }
            ],
            [
              "id",
              {
                "bytes": "010100000000000000",
                "cl_type": {
                  "Option": "U64"
                },
                "parsed": 1
              }
            ]
          ]
        }
      }
    },
    "execution_results": [
      {
        "block_hash": "9101f229626475dcb558a8c9fd83e6bbb2c8d3497b953927fc320ccc4f78b8e2",
        "result": {
          "Success": {
            "cost": "100000000",
            "effect": {
              "operations": [],
              "transforms": [
                {
                  "key": "account-hash-a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91",
                  "transform": "Identity"
                },
                {
                  "key": "account-hash-a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d2469afeb99130f0be7c9ce230a84149e6d756e306ef8cf5b8a49d5182e41676",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d63c44078a1931b5dc4b80a7a0ec586164fd0470ce9f8b23f6d93b9e86c5944d",
                  "transform": "Identity"
                },
                {
                  "key": "hash-7cc1b1db4e08bbfe7bacf8e1ad828a5d9bcccbb33e55d322808c3a88da53213a",
                  "transform": "Identity"
                },
                {
                  "key": "hash-4475016098705466254edd18d267a9dad43e341d4dafadb507d0fe3cf2d4a74b",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": {
                    "WriteCLValue": {
                      "bytes": "08d801e4e19fcfa002",
                      "cl_type": "U512",
                      "parsed": "189379469946126808"
                    }
                  }
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": {
                    "AddUInt512": "100000000"
                  }
                },
                {
                  "key": "account-hash-a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91",
                  "transform": "Identity"
                },
                {
                  "key": "account-hash-a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d2469afeb99130f0be7c9ce230a84149e6d756e306ef8cf5b8a49d5182e41676",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d63c44078a1931b5dc4b80a7a0ec586164fd0470ce9f8b23f6d93b9e86c5944d",
                  "transform": "Identity"
                },
                {
                  "key": "hash-7cc1b1db4e08bbfe7bacf8e1ad828a5d9bcccbb33e55d322808c3a88da53213a",
                  "transform": "Identity"
                },
                {
                  "key": "hash-4475016098705466254edd18d267a9dad43e341d4dafadb507d0fe3cf2d4a74b",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": {
                    "WriteCLValue": {
                      "bytes": "08d801e4e19fcfa002",
                      "cl_type": "U512",
                      "parsed": "189379469946126808"
                    }
                  }
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": {
                    "AddUInt512": "100000000"
                  }
                },
                {
                  "key": "hash-7cc1b1db4e08bbfe7bacf8e1ad828a5d9bcccbb33e55d322808c3a88da53213a",
                  "transform": "Identity"
                },
                {
                  "key": "hash-4475016098705466254edd18d267a9dad43e341d4dafadb507d0fe3cf2d4a74b",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-12bd0108a698041bd98ac39db956de52403bad4123c940a5d2fb7f435b43b500",
                  "transform": "Identity"
                },
                {
                  "key": "balance-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef",
                  "transform": {
                    "WriteCLValue": {
                      "bytes": "08d8c91133aacea002",
                      "cl_type": "U512",
                      "parsed": "189378414746126808"
                    }
                  }
                },
                {
                  "key": "balance-12bd0108a698041bd98ac39db956de52403bad4123c940a5d2fb7f435b43b500",
                  "transform": {
                    "AddUInt512": "1055200000000"
                  }
                },
                {
                  "key": "transfer-1b8c3660dec25c2c9ee8cd042c9f2e6036101b33af704081a83e5547896588da",
                  "transform": {
                    "WriteTransfer": {
                      "amount": "1055200000000",
                      "deploy_hash": "30a84ef0e046b5d700ad176096db87118df3f25a20b15b2d5579194aae199c2b",
                      "from": "account-hash-496d542527e1a29f576ab7c3f4c947bfcdc9b4145f75f6ec40e36089432d7351",
                      "gas": "0",
                      "id": 1,
                      "source": "uref-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef-007",
                      "target": "uref-12bd0108a698041bd98ac39db956de52403bad4123c940a5d2fb7f435b43b500-004",
                      "to": "account-hash-a6aef97ebac242632334efa31cb20587301c18c6e5cc5a8905c2e6ba641a2d91"
                    }
                  }
                },
                {
                  "key": "deploy-30a84ef0e046b5d700ad176096db87118df3f25a20b15b2d5579194aae199c2b",
                  "transform": {
                    "WriteDeployInfo": {
                      "deploy_hash": "30a84ef0e046b5d700ad176096db87118df3f25a20b15b2d5579194aae199c2b",
                      "from": "account-hash-496d542527e1a29f576ab7c3f4c947bfcdc9b4145f75f6ec40e36089432d7351",
                      "gas": "100000000",
                      "source": "uref-7950bf87377371651e0927198e2bc73074a43a804037cc4e20f4a2c21115b7ef-007",
                      "transfers": [
                        "transfer-1b8c3660dec25c2c9ee8cd042c9f2e6036101b33af704081a83e5547896588da"
                      ]
                    }
                  }
                },
                {
                  "key": "hash-d2469afeb99130f0be7c9ce230a84149e6d756e306ef8cf5b8a49d5182e41676",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d63c44078a1931b5dc4b80a7a0ec586164fd0470ce9f8b23f6d93b9e86c5944d",
                  "transform": "Identity"
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": "Identity"
                },
                {
                  "key": "hash-d2469afeb99130f0be7c9ce230a84149e6d756e306ef8cf5b8a49d5182e41676",
                  "transform": "Identity"
                },
                {
                  "key": "hash-7cc1b1db4e08bbfe7bacf8e1ad828a5d9bcccbb33e55d322808c3a88da53213a",
                  "transform": "Identity"
                },
                {
                  "key": "hash-4475016098705466254edd18d267a9dad43e341d4dafadb507d0fe3cf2d4a74b",
                  "transform": "Identity"
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": "Identity"
                },
                {
                  "key": "balance-9f562e619b2517b86df968aeacf1c2a11e14777453b6ed6b2731da59f564178d",
                  "transform": "Identity"
                },
                {
                  "key": "balance-fe327f9815a1d016e1143db85e25a86341883949fd75ac1c1e7408a26c5b62ef",
                  "transform": {
                    "WriteCLValue": {
                      "bytes": "00",
                      "cl_type": "U512",
                      "parsed": "0"
                    }
                  }
                },
                {
                  "key": "balance-9f562e619b2517b86df968aeacf1c2a11e14777453b6ed6b2731da59f564178d",
                  "transform": {
                    "AddUInt512": "100000000"
                  }
                }
              ]
            },
            "transfers": [
              "transfer-1b8c3660dec25c2c9ee8cd042c9f2e6036101b33af704081a83e5547896588da"
            ]
          }
        }
      }
    ]
  },
  "id": 1
}
curl https://mainnet.casper.validationcloud.io/v1/<YOUR_API_KEY_HERE> \
    -X POST \
    -H "Content-Type: application/json" \
    -d '{"id":1,"jsonrpc":"2.0","method":"info_get_deploy","params":[]}'

Last updated