From bb6a0c33d7ed0fba07bc12f616d963a86d8e54fd Mon Sep 17 00:00:00 2001 From: Gabriel Cardona Date: Fri, 3 Feb 2023 18:32:55 -0800 Subject: [PATCH] Alphabetize collections. Add optional params to body. --- Avalanche.postman_collection.json | 442 ++++++------------ ...anche-Environment.postman_environment.json | 103 ++-- 2 files changed, 208 insertions(+), 337 deletions(-) diff --git a/Avalanche.postman_collection.json b/Avalanche.postman_collection.json index dc2661c..ae3f74f 100644 --- a/Avalanche.postman_collection.json +++ b/Avalanche.postman_collection.json @@ -1,8 +1,9 @@ { "info": { - "_postman_id": "72e39b9d-49f8-416f-89db-118fcb994d21", + "_postman_id": "1ee7a070-3262-42d5-9cb2-3ec00a0a5d5e", "name": "Avalanche", - "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", + "_exporter_id": "12086068" }, "item": [ { @@ -587,35 +588,6 @@ }, "response": [] }, - { - "name": "exportAVAX", - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.exportAVAX\",\n \"params\" :{\n \"from\": [\"{{xchainAddress}}\"],\n \"to\":\"{{cchainbech32address}}\",\n \"amount\": 4000001000000,\n \"destinationChain\": \"C\",\n \"changeAddr\": \"{{xchainAddress}}\",\n \"username\":\"{{avalancheUsername}}\",\n \"password\":\"{{avalanchePassword}}\" \n }\n}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "{{baseURL}}/ext/bc/X", - "host": [ - "{{baseURL}}" - ], - "path": [ - "ext", - "bc", - "X" - ] - }, - "description": "Export AVAX from the X-Chain to both the P-Chain as well as the C-Chain. After calling this method, you must call either the P-Chain’s `importAVAX` method or the C-Chain's `importAVAX` method to complete the transfer. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-exportavax)" - }, - "response": [] - }, { "name": "exportKey", "request": { @@ -652,7 +624,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" : 1,\n \"method\" :\"avm.getAllBalances\",\n \"params\" :{\n \"address\":\"{{xchainAddress}}\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" : 1,\n \"method\" :\"avm.getAddressTxs\",\n \"params\" :{\n \"address\":\"{{xchainAddress}}\",\n \"assetID\": \"AVAX\",\n \"pageSize\": 20,\n \"cursor\": 0\n }\n}", "options": { "raw": { "language": "json" @@ -799,7 +771,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.getTx\",\n \"params\" :{\n \"txID\":\"2QouvFWUbjuySRxeX5xMbNCuAaKWfbk5FeEa2JmoF85RKLk2dD\",\n \"encoding\": \"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.getTx\",\n \"params\" :{\n \"txID\":\"{{txID}}\",\n \"encoding\": \"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -828,7 +800,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"id\": 1,\n \"method\": \"avm.getTxStatus\",\n \"params\": {\n \"txID\": \"2HHr7xUJgWiLESV7g8T3oWfWvdpWJXd4Hctj6U3KhzUN6EsgBG\"\n }\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"id\": 1,\n \"method\": \"avm.getTxStatus\",\n \"params\": {\n \"txID\": \"{{txID}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -857,7 +829,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.getUTXOs\",\n \"params\" :{\n \"addresses\":[\"{{xchainAddress}}\"],\n \"limit\": 5,\n \"sourceChain\": \"X\",\n \"encoding\": \"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.getUTXOs\",\n \"params\" :{\n \"addresses\":[\"{{xchainAddress}}\"],\n \"limit\": 5,\n \"sourceChain\": \"X\",\n \"encoding\": \"hex\",\n \"startIndex\": { \n \"address\": \"{{xchainAddress}}\",\n \"utxo\": \"{{utxo}}\"\n }\n }\n}", "options": { "raw": { "language": "json" @@ -909,13 +881,13 @@ "response": [] }, { - "name": "importAVAX", + "name": "importKey", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.importAVAX\",\n \"params\" :{\n \"username\":\"{{avalancheUsername}}\",\n \"password\":\"{{avalanchePassword}}\",\n \"sourceChain\": \"C\",\n \"to\":\"{{xchainAddress}}\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.importKey\",\n \"params\" :{\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\",\n \"privateKey\":\"{{privkey}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -933,7 +905,7 @@ "X" ] }, - "description": "Finalize a transfer of AVAX from either the P-Chain to the X-Chain or the C-Chain to the X-Chain.\n\nBefore this method is called, you must call either the P-Chain’s `exportAVAX` method or the C-Chain’s `exportAVAX` method to initiate the transfer. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-importavax)" + "description": "Give a user control over an address by providing the private key that controls the address. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-importkey)" }, "response": [] }, @@ -966,35 +938,6 @@ }, "response": [] }, - { - "name": "importKey", - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.importKey\",\n \"params\" :{\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\",\n \"privateKey\":\"{{privkey}}\"\n }\n}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "{{baseURL}}/ext/bc/X", - "host": [ - "{{baseURL}}" - ], - "path": [ - "ext", - "bc", - "X" - ] - }, - "description": "Give a user control over an address by providing the private key that controls the address. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-importkey)" - }, - "response": [] - }, { "name": "listAddresses", "request": { @@ -1111,35 +1054,6 @@ }, "response": [] }, - { - "name": "sendAsManager", - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.sendAsManager\",\n \"params\" :{ \n \"assetID\" : \"{{avaxAssetId}}\",\n \"amount\" : 2000000,\n \"feeFrom\": [\"{{xchainAddress}}\"],\n \"feeChangeAddr\": \"{{xchainAddress}}\",\n \"from\" : [\"{{xchainAddress}}\"],\n \"to\" : \"{{xchainAddress}}\",\n \"changeAddr\": \"{{xchainAddress}}\",\n \"memo\" : \"{{memo}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\" \n }\n}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "{{baseURL}}/ext/bc/X", - "host": [ - "{{baseURL}}" - ], - "path": [ - "ext", - "bc", - "X" - ] - }, - "description": "Send a quantity of an asset to an address. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-send)" - }, - "response": [] - }, { "name": "sendMultiple", "request": { @@ -1197,35 +1111,6 @@ "description": "Send a quantity of an asset to an address. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-sendnft)" }, "response": [] - }, - { - "name": "updateManagedAsset", - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"avm.updateManagedAsset\",\n \"params\" :{ \n \"assetID\" : {{avaxAssetId}},\n \"frozen\": true,\n \"manager\":{\n \"threshold\": 1,\n \"addresses\": [\n \"{{xchainAddress}}\"\n ]\n },\n \"from\" : [\"{{xchainAddress}}\"],\n \"to\" : \"{{xchainAddress}}\",\n \"changeAddr\": \"{{xchainAddress}}\",\n \"memo\" : \"{{memo}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\" \n }\n}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "{{baseURL}}/ext/bc/X", - "host": [ - "{{baseURL}}" - ], - "path": [ - "ext", - "bc", - "X" - ] - }, - "description": "Send a quantity of an asset to an address. [More info](https://docs.avax.network/build/apis/exchange-chain-x-chain-api#avm-send)" - }, - "response": [] } ], "description": "The X-Chain, Avalanche’s native platform for creating and trading assets, is an instance of the Avalanche Virtual Machine (AVM). This API allows clients to create and trade assets on the X-Chain and other instances of the AVM. [More info](https://docs.avax.network/v1.0/en/api/avm)" @@ -2237,13 +2122,13 @@ "name": "X-Chain Transactions", "item": [ { - "name": "getLastAccepted", + "name": "getContainerByID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"2dGz8JSfX17QqW12pARrt2iWNhXdcpXMYPVSYRn9HrReGpMXqQ\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2262,7 +2147,7 @@ "tx" ] }, - "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" + "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" }, "response": [] }, @@ -2297,13 +2182,13 @@ "response": [] }, { - "name": "getContainerByID", + "name": "getContainerRange", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"2dGz8JSfX17QqW12pARrt2iWNhXdcpXMYPVSYRn9HrReGpMXqQ\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2322,18 +2207,18 @@ "tx" ] }, - "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" + "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" }, "response": [] }, { - "name": "getContainerRange", + "name": "getIndex", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"2dGz8JSfX17QqW12pARrt2iWNhXdcpXMYPVSYRn9HrReGpMXqQ\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2352,18 +2237,18 @@ "tx" ] }, - "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" + "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" }, "response": [] }, { - "name": "getIndex", + "name": "getLastAccepted", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"2dGz8JSfX17QqW12pARrt2iWNhXdcpXMYPVSYRn9HrReGpMXqQ\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2382,7 +2267,7 @@ "tx" ] }, - "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" + "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" }, "response": [] }, @@ -2422,13 +2307,13 @@ "name": "X-Chain Vertices", "item": [ { - "name": "getLastAccepted", + "name": "getContainerByID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2447,7 +2332,7 @@ "vtx" ] }, - "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" + "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" }, "response": [] }, @@ -2482,13 +2367,13 @@ "response": [] }, { - "name": "getContainerByID", + "name": "getContainerRange", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2507,18 +2392,18 @@ "vtx" ] }, - "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" + "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" }, "response": [] }, { - "name": "getContainerRange", + "name": "getIndex", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"kLBLyNrBr9rjHFBScjvogspz167wrTD47SqbTsLk6YGGnjHwZ\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2537,18 +2422,18 @@ "vtx" ] }, - "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" + "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" }, "response": [] }, { - "name": "getIndex", + "name": "getLastAccepted", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"kLBLyNrBr9rjHFBScjvogspz167wrTD47SqbTsLk6YGGnjHwZ\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2567,7 +2452,7 @@ "vtx" ] }, - "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" + "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" }, "response": [] }, @@ -2607,13 +2492,13 @@ "name": "P-Chain Blocks", "item": [ { - "name": "getLastAccepted", + "name": "getContainerByID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2632,7 +2517,7 @@ "block" ] }, - "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" + "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" }, "response": [] }, @@ -2667,13 +2552,13 @@ "response": [] }, { - "name": "getContainerByID", + "name": "getContainerRange", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2692,18 +2577,18 @@ "block" ] }, - "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" + "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" }, "response": [] }, { - "name": "getContainerRange", + "name": "getIndex", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"4AqeFPxtTW4B5D6oR8gRZTvRKnnqkUWiV6mUNZxjUMbQKYWpi\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2722,18 +2607,18 @@ "block" ] }, - "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" + "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" }, "response": [] }, { - "name": "getIndex", + "name": "getLastAccepted", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"4AqeFPxtTW4B5D6oR8gRZTvRKnnqkUWiV6mUNZxjUMbQKYWpi\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2752,7 +2637,7 @@ "block" ] }, - "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" + "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" }, "response": [] }, @@ -2792,13 +2677,13 @@ "name": "C-Chain Blocks", "item": [ { - "name": "getLastAccepted", + "name": "getContainerByID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2817,7 +2702,7 @@ "block" ] }, - "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" + "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" }, "response": [] }, @@ -2852,13 +2737,13 @@ "response": [] }, { - "name": "getContainerByID", + "name": "getContainerRange", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerByID\",\n \"params\": {\n \"containerID\":\"8JeLjRDCojGAZXYNvLDxeU7XhKaTiMzJsSEue7d37kA1n1Htm\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2877,18 +2762,18 @@ "block" ] }, - "description": "Get container by ID. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerbyid)" + "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" }, "response": [] }, { - "name": "getContainerRange", + "name": "getIndex", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getContainerRange\",\n \"params\": {\n \"startIndex\":0,\n \"numtoFetch\":10,\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"4AqeFPxtTW4B5D6oR8gRZTvRKnnqkUWiV6mUNZxjUMbQKYWpi\",\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2907,18 +2792,18 @@ "block" ] }, - "description": "Returns containers with indices in [startIndex, startIndex+1, ... , startIndex + numToFetch - 1]. numToFetch must be in \\[0,1024\\] [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getcontainerrange)" + "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" }, "response": [] }, { - "name": "getIndex", + "name": "getLastAccepted", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getIndex\",\n \"params\": {\n \"containerID\":\"4AqeFPxtTW4B5D6oR8gRZTvRKnnqkUWiV6mUNZxjUMbQKYWpi\",\n \"encoding\":\"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"index.getLastAccepted\",\n \"params\": {\n \"encoding\":\"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -2937,7 +2822,7 @@ "block" ] }, - "description": "Get a container's index. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getindex)" + "description": "Get the most recently accepted container. [More info](https://docs.avax.network/build/avalanchego-apis/index-api#index.getlastaccepted)" }, "response": [] }, @@ -2980,13 +2865,13 @@ "name": "Info", "item": [ { - "name": "getBlockchainID", + "name": "isBootstrapped", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getBlockchainID\",\n \"params\": {\n \"alias\":\"X\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.isBootstrapped\",\n \"params\": {\n \"chain\": \"X\"\n }\n}", "options": { "raw": { "language": "json" @@ -3003,18 +2888,18 @@ "info" ] }, - "description": "Given a blockchain’s alias, get its ID. [More info](https://docs.avax.network/build/avalanchego-apis/info#infogetblockchainid)" + "description": "Check whether a given chain is done bootstrapping. [More info](https://docs.avax.network/build/avalanchego-apis/info-api#infoisbootstrapped)" }, "response": [] }, { - "name": "getNetworkID", + "name": "getBlockchainID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNetworkID\",\n \"params\" :{\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getBlockchainID\",\n \"params\": {\n \"alias\":\"X\"\n }\n}", "options": { "raw": { "language": "json" @@ -3031,18 +2916,18 @@ "info" ] }, - "description": "Get the ID of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnetworkid)" + "description": "Given a blockchain’s alias, get its ID. [More info](https://docs.avax.network/build/avalanchego-apis/info#infogetblockchainid)" }, "response": [] }, { - "name": "getNetworkName", + "name": "getNetworkID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNetworkName\",\n \"params\" :{\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNetworkID\",\n \"params\" :{\n }\n}", "options": { "raw": { "language": "json" @@ -3059,18 +2944,18 @@ "info" ] }, - "description": "Get the name of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnetworkname)" + "description": "Get the ID of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnetworkid)" }, "response": [] }, { - "name": "getNodeID", + "name": "getNetworkName", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeID\",\n \"params\" :{\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNetworkName\",\n \"params\" :{\n }\n}", "options": { "raw": { "language": "json" @@ -3087,18 +2972,18 @@ "info" ] }, - "description": "Get the name of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeid)" + "description": "Get the name of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnetworkname)" }, "response": [] }, { - "name": "getNodeIP", + "name": "getNodeID", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeIP\",\n \"params\" :{\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeID\",\n \"params\" :{\n }\n}", "options": { "raw": { "language": "json" @@ -3115,18 +3000,18 @@ "info" ] }, - "description": "Get the IP of this node. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeip)" + "description": "Get the name of the network this node is participating in. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeid)" }, "response": [] }, { - "name": "getNodeVersion", + "name": "getNodeIP", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeVersion\",\n \"params\" :{\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeIP\",\n \"params\" :{\n }\n}", "options": { "raw": { "language": "json" @@ -3143,18 +3028,18 @@ "info" ] }, - "description": "Get the version of this node. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeversion)" + "description": "Get the IP of this node. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeip)" }, "response": [] }, { - "name": "isBootstrapped", + "name": "getNodeVersion", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.isBootstrapped\",\n \"params\": {\n \"chain\": \"X\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.getNodeVersion\",\n \"params\" :{\n }\n}", "options": { "raw": { "language": "json" @@ -3171,7 +3056,7 @@ "info" ] }, - "description": "Check whether a given chain is done bootstrapping. [More info](https://docs.avax.network/build/avalanchego-apis/info-api#infoisbootstrapped)" + "description": "Get the version of this node. [More info](https://docs.avax.network/build/apis/info-api#info-getnodeversion)" }, "response": [] }, @@ -3232,13 +3117,13 @@ "response": [] }, { - "name": "uptime", + "name": "peers", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.uptime\"\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.peers\",\n \"params\" :{\n \"nodeIDs\": []\n }\n}", "options": { "raw": { "language": "json" @@ -3255,18 +3140,18 @@ "info" ] }, - "description": "Returns the network's observed uptime of this node. [More info](https://docs.avax.network/build/avalanchego-apis/info-api#info-uptime)" + "description": "Get description of peer connections. [More info](https://docs.avax.network/build/apis/info-api#info-peers)" }, "response": [] }, { - "name": "peers", + "name": "uptime", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.peers\",\n \"params\" :{\n \"nodeIDs\": []\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"info.uptime\"\n}", "options": { "raw": { "language": "json" @@ -3283,7 +3168,7 @@ "info" ] }, - "description": "Get description of peer connections. [More info](https://docs.avax.network/build/apis/info-api#info-peers)" + "description": "Returns the network's observed uptime of this node. [More info](https://docs.avax.network/build/avalanchego-apis/info-api#info-uptime)" }, "response": [] } @@ -3537,7 +3422,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addDelegator\",\n \"params\": {\n \"nodeId\":\"{{avalancheNodeId}}\",\n \"startTime\":1613347036,\n \"endTime\":1631215800,\n \"stakeAmount\":200000000000,\n \"rewardAddress\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addDelegator\",\n \"params\": {\n \"nodeId\":\"{{avalancheNodeId}}\",\n \"startTime\":1613347036,\n \"endTime\":1631215800,\n \"stakeAmount\":200000000000,\n \"rewardAddress\": \"{{pchainAddress}}\",\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3560,13 +3445,13 @@ "response": [] }, { - "name": "addValidator", + "name": "addSubnetValidator", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addValidator\",\n \"params\": {\n \"nodeID\":\"{{avalancheNodeId}}\",\n \"startTime\":1606245174,\n \"endTime\":1608837056,\n \"stakeAmount\":2000000000000,\n \"rewardAddress\": \"{{pchainAddress}}\",\n \"delegationFeeRate\":10,\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addSubnetValidator\",\n \"params\": {\n \"nodeID\":\"{{avalancheNodeId}}\",\n \"subnetID\":\"{{avalancheSubnetId}}\",\n \"startTime\":1625782598,\n \"endTime\":1627078419,\n \"weight\":20,\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3584,18 +3469,18 @@ "P" ] }, - "description": "Add a validator to the Default Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformadddefaultsubnetvalidator)" + "description": "Add a validator to a Subnet other than the Default Subnet. The validator must validate the Default Subnet for the entire duration they validate this Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformaddnondefaultsubnetvalidator)" }, "response": [] }, { - "name": "addSubnetValidator", + "name": "addValidator", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addSubnetValidator\",\n \"params\": {\n \"nodeID\":\"{{avalancheNodeId}}\",\n \"subnetID\":\"{{avalancheSubnetId}}\",\n \"startTime\":1625782598,\n \"endTime\":1627078419,\n \"weight\":20,\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.addValidator\",\n \"params\": {\n \"nodeID\":\"{{avalancheNodeId}}\",\n \"startTime\":1606245174,\n \"endTime\":1608837056,\n \"stakeAmount\":2000000000000,\n \"rewardAddress\": \"{{pchainAddress}}\",\n \"delegationFeeRate\":10,\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3613,7 +3498,7 @@ "P" ] }, - "description": "Add a validator to a Subnet other than the Default Subnet. The validator must validate the Default Subnet for the entire duration they validate this Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformaddnondefaultsubnetvalidator)" + "description": "Add a validator to the Default Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformadddefaultsubnetvalidator)" }, "response": [] }, @@ -3653,7 +3538,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.createBlockchain\",\n \"params\" : {\n \"vmID\":\"avm\",\n \"SubnetID\":\"{{avalancheSubnetId}}\",\n \"name\":\"My new avm\",\n \"genesisData\": \"111115LHK2ZCYttSKPmmhsTDSuKiCkmHz65nUS1YqybvjirwGLLt376k1RwnTt72WobPqrG7rmgrKVqSq6VxDsKXYGnRmfhdLCEhsYjM\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.createBlockchain\",\n \"params\" : {\n \"vmID\":\"avm\",\n \"SubnetID\":\"{{avalancheSubnetId}}\",\n \"name\":\"My new avm\",\n \"genesisData\": \"111115LHK2ZCYttSKPmmhsTDSuKiCkmHz65nUS1YqybvjirwGLLt376k1RwnTt72WobPqrG7rmgrKVqSq6VxDsKXYGnRmfhdLCEhsYjM\",\n \"encoding\": \"hex\",\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3705,13 +3590,13 @@ "response": [] }, { - "name": "getBalance", + "name": "exportAVAX", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getBalance\",\n \"params\" :{\n \"address\":\"P-custom1u6eth2fg33ye63mnyu5jswtj326jaypvhyar45\" \n }\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.exportAVAX\",\n \"params\": {\n \"to\":\"{{xchainAddress}}\",\n \"amount\":54321,\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\",\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3729,18 +3614,18 @@ "P" ] }, - "description": "Get the balance of an asset controlled by a given address. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetbalance)" + "description": "Send AVAX from an account on the C-Chain to an address on the X-Chain.\nThis transaction must be signed with the key of the account that the AVAX is sent from and which pays the transaction fee.\nAfter issuing this transaction, you must call the X-Chain’s `importAVA` method to complete the transfer. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformexportavax)" }, "response": [] }, { - "name": "getBlockchains", + "name": "exportKey", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlockchains\",\n \"params\": {},\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.exportKey\",\n \"params\" :{\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\",\n \"address\": \"{{pchainAddress}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -3758,18 +3643,18 @@ "P" ] }, - "description": "Get all the blockchains that exist (excluding the P-Chain). [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetblockchains)" + "description": "Get the private key that controls a given address.\nThe returned private key can be added to a user with `platform.importKey`. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformexportkey)" }, "response": [] }, { - "name": "timestamp", + "name": "getBalance", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlockchains\",\n \"params\": {},\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getBalance\",\n \"params\" :{\n \"addresses\":[\"{{pchainAddress}}\"] \n }\n}", "options": { "raw": { "language": "json" @@ -3787,18 +3672,18 @@ "P" ] }, - "description": "Get all the blockchains that exist (excluding the P-Chain). [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetblockchains)" + "description": "Get the balance of an asset controlled by a given address. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetbalance)" }, "response": [] }, { - "name": "getBlockchainStatus", + "name": "getBlock", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlockchainStatus\",\n \"params\":{\n \"blockchainID\":\"{{avalanceBlockchainId}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlock\",\n \"params\": {\n \"blockID\": \"{{blockID}}\",\n \"encoding\": \"hex\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3816,18 +3701,18 @@ "P" ] }, - "description": "Get the status of a blockchain. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetblockchainstatus)" + "description": "Get a block by its ID. [More info](https://docs.avax.network/apis/avalanchego/apis/p-chain#platformgetblock)" }, "response": [] }, { - "name": "getCurrentSupply", + "name": "getBlockchains", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getCurrentSupply\",\n \"params\": {}\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlockchains\",\n \"params\": {},\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3845,18 +3730,18 @@ "P" ] }, - "description": "Returns an upper bound on the number of AVAX that exist. This is an upper bound because it does not account for burnt tokens, including transaction fees. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetcurrentsupply)" + "description": "Get all the blockchains that exist (excluding the P-Chain). [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetblockchains)" }, "response": [] }, { - "name": "getTotalStake", + "name": "getBlockchainStatus", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTotalStake\",\n \"params\": {}\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getBlockchainStatus\",\n \"params\":{\n \"blockchainID\":\"{{avalanceBlockchainId}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3874,18 +3759,18 @@ "P" ] }, - "description": "Get the total amount of nAVAX staked on the Primary Network. [More info](https://docs.avax.network/build/avalanchego-apis/p-chain#platformgettotalstake)" + "description": "Get the status of a blockchain. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetblockchainstatus)" }, "response": [] }, { - "name": "getCurrentValidators", + "name": "getCurrentSupply", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getCurrentValidators\",\n \"params\": {\n \"subnetID\":null,\n \"nodeIDs\":[]\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getCurrentSupply\",\n \"params\": {\n \"subnetID\": \"{{avalancheSubnetId}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -3903,18 +3788,18 @@ "P" ] }, - "description": "List the current validators of the given Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetcurrentvalidators)" + "description": "Returns an upper bound on the number of AVAX that exist. This is an upper bound because it does not account for burnt tokens, including transaction fees. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetcurrentsupply)" }, "response": [] }, { - "name": "getMaxStakeAmount", + "name": "getCurrentValidators", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getMaxStakeAmount\",\n \"params\": {\n \"subnetID\":\"\",\n \"nodeID\":\"\",\n \"startTime\": 123,\n \"endTime\": 321\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getCurrentValidators\",\n \"params\": {\n \"subnetID\":null,\n \"nodeIDs\":[]\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3966,13 +3851,13 @@ "response": [] }, { - "name": "getMinStake", + "name": "getMaxStakeAmount", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getMinStake\",\n \"params\": {}\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getMaxStakeAmount\",\n \"params\": {\n \"subnetID\":\"\",\n \"nodeID\":\"\",\n \"startTime\": 123,\n \"endTime\": 321\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -3990,18 +3875,18 @@ "P" ] }, - "description": "Returns the minimum stake amount [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetminstake)" + "description": "List the current validators of the given Subnet. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetcurrentvalidators)" }, "response": [] }, { - "name": "getRewardUTXOs", + "name": "getMinStake", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getRewardUTXOs\",\n \"params\" :{\n \"txID\":\"2nmH8LithVbdjaXsxVQCQfXtzN9hBbmebrsaEYnLM9T32Uy2Y4\",\n \"encoding\": \"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getMinStake\",\n \"params\": {\n \"subnetID\": \"{{avalancheSubnetId}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -4019,18 +3904,18 @@ "P" ] }, - "description": "Returns the UTXOs that were rewarded after the provided transaction's staking or delegation period ended." + "description": "Returns the minimum stake amount [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetminstake)" }, "response": [] }, { - "name": "getStake", + "name": "getPendingValidators", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getStake\",\n \"params\": {\n \"addresses\": [\"{{pchainAddress}}\"],\n \"encoding\": \"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getPendingValidators\",\n \"params\": {\n \"subnetID\": null,\n \"nodeIDs\": []\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -4048,18 +3933,18 @@ "P" ] }, - "description": "Returns the staked amount for an array of addresses [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetstake)" + "description": "List the validators in the pending validator set of the specified Subnet. Each validator is not currently validating the Subnet but will in the future. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetpendingvalidators)" }, "response": [] }, { - "name": "getTxStatus", + "name": "getRewardUTXOs", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getTxStatus\",\n \"params\": {\n \"txID\": \"23CLURk1Czf1aLui1VdcuWSiDeFskfp3Sn8TQG7t6NKfeQRYDj\",\n \"includeReason\": true\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getRewardUTXOs\",\n \"params\" :{\n \"txID\":\"2nmH8LithVbdjaXsxVQCQfXtzN9hBbmebrsaEYnLM9T32Uy2Y4\",\n \"encoding\": \"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -4077,18 +3962,18 @@ "P" ] }, - "description": "Returns the status of a platform chain transaction." + "description": "Returns the UTXOs that were rewarded after the provided transaction's staking or delegation period ended." }, "response": [] }, { - "name": "getPendingValidators", + "name": "getStake", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getPendingValidators\",\n \"params\": {\n \"subnetID\": null,\n \"nodeIDs\": []\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getStake\",\n \"params\": {\n \"addresses\": [\"{{pchainAddress}}\"],\n \"encoding\": \"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -4106,7 +3991,7 @@ "P" ] }, - "description": "List the validators in the pending validator set of the specified Subnet. Each validator is not currently validating the Subnet but will in the future. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetpendingvalidators)" + "description": "Returns the staked amount for an array of addresses [More info](https://docs.avax.network/v1.0/en/api/platform/#platformgetstake)" }, "response": [] }, @@ -4117,7 +4002,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getStakingAssetID\",\n \"params\": {}\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getStakingAssetID\",\n \"params\": {\n \"subnetID\": \"{{avalancheSubnetId}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -4146,7 +4031,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getSubnets\",\n \"params\": {},\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.getSubnets\",\n \"params\": {\n \"ids\": [\"{{avalancheSubnetId}}\"]\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" @@ -4168,35 +4053,6 @@ }, "response": [] }, - { - "name": "getTx", - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTx\",\n \"params\" :{\n \"txID\":\"Cy7cZUot6DCUUDz1VuA2C7vFVWSzW3DgLhYXUAiLWH8BKafbH\",\n \"encoding\": \"hex\"\n }\n}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "{{baseURL}}/ext/bc/P", - "host": [ - "{{baseURL}}" - ], - "path": [ - "ext", - "bc", - "P" - ] - }, - "description": "Returns the specified transaction [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetbalance)" - }, - "response": [] - }, { "name": "getTimestamp", "request": { @@ -4227,13 +4083,13 @@ "response": [] }, { - "name": "getTxStatus", + "name": "getTotalStake", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTxStatus\",\n \"params\" :{\n \"txID\":\"2C3AVShejyq6mLhEXvEGCnpaQi8tRwudBhSbT34hFiytffEFoe\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTotalStake\",\n \"params\": {\n \"subnetID\": \"{{avalancheSubnetId}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -4251,18 +4107,18 @@ "P" ] }, - "description": "Returns the specified transaction [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetbalance)" + "description": "Get the total amount of nAVAX staked on the Primary Network. [More info](https://docs.avax.network/build/avalanchego-apis/p-chain#platformgettotalstake)" }, "response": [] }, { - "name": "getUTXOs", + "name": "getTx", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getUTXOs\",\n \"params\" :{\n \"addresses\":[\"P-custom18jma8ppw3nhx5r4ap8clazz0dps7rv5u9xde7p\"],\n \"sourceChain\": \"X\",\n \"limit\": 5,\n \"encoding\": \"hex\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTx\",\n \"params\" :{\n \"txID\":\"Cy7cZUot6DCUUDz1VuA2C7vFVWSzW3DgLhYXUAiLWH8BKafbH\",\n \"encoding\": \"hex\"\n }\n}", "options": { "raw": { "language": "json" @@ -4280,18 +4136,18 @@ "P" ] }, - "description": "Get the UTXOs that reference a given address. [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetutxos)" + "description": "Returns the specified transaction [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetbalance)" }, "response": [] }, { - "name": "getValidatorsAt", + "name": "getTxStatus", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getValidatorsAt\",\n \"params\" :{\n \"height\": 0,\n \"subnetID\": \"11111111111111111111111111111111LpoYY\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getTxStatus\",\n \"params\" :{\n \"txID\":\"2C3AVShejyq6mLhEXvEGCnpaQi8tRwudBhSbT34hFiytffEFoe\"\n }\n}", "options": { "raw": { "language": "json" @@ -4309,18 +4165,18 @@ "P" ] }, - "description": "Get the validators and their weights of a subnet or the Primary Network at a given P-Chain height. [More info](https://docs.avax.network/build/avalanchego-apis/platform-chain-p-chain-api#platform-getvalidatorsat)" + "description": "Returns the specified transaction [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetbalance)" }, "response": [] }, { - "name": "exportAVAX", + "name": "getUTXOs", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.exportAVAX\",\n \"params\": {\n \"to\":\"{{xchainAddress}}\",\n \"amount\":54321,\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getUTXOs\",\n \"params\" :{\n \"addresses\":[\"{{pchainAddress}}\"],\n \"sourceChain\": \"P\",\n \"limit\": 5,\n \"encoding\": \"hex\",\n \"startIndex\": {\n \"address\": \"{{pchainAddress}}\",\n \"utxo\": \"LUC1cmcxnfNR9LdkACS2ccGKLEK7SYqB4gLLTycQfg1koyfSq\"\n }\n }\n}", "options": { "raw": { "language": "json" @@ -4338,18 +4194,18 @@ "P" ] }, - "description": "Send AVAX from an account on the C-Chain to an address on the X-Chain.\nThis transaction must be signed with the key of the account that the AVAX is sent from and which pays the transaction fee.\nAfter issuing this transaction, you must call the X-Chain’s `importAVA` method to complete the transfer. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformexportavax)" + "description": "Get the UTXOs that reference a given address. [More info](https://docs.avax.network/v1.0/en/api/avm/#avmgetutxos)" }, "response": [] }, { - "name": "exportKey", + "name": "getValidatorsAt", "request": { "method": "POST", "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.exportKey\",\n \"params\" :{\n \"username\": \"{{avalancheUsername}}\",\n \"password\": \"{{avalanchePassword}}\",\n \"address\": \"{{pchainAddress}}\"\n }\n}", + "raw": "{\n \"jsonrpc\":\"2.0\",\n \"id\" :1,\n \"method\" :\"platform.getValidatorsAt\",\n \"params\" :{\n \"height\": 0,\n \"subnetID\": \"{{avalancheSubnetId}}\"\n }\n}", "options": { "raw": { "language": "json" @@ -4367,7 +4223,7 @@ "P" ] }, - "description": "Get the private key that controls a given address.\nThe returned private key can be added to a user with `platform.importKey`. [More info](https://docs.avax.network/v1.0/en/api/platform/#platformexportkey)" + "description": "Get the validators and their weights of a subnet or the Primary Network at a given P-Chain height. [More info](https://docs.avax.network/build/avalanchego-apis/platform-chain-p-chain-api#platform-getvalidatorsat)" }, "response": [] }, @@ -4378,7 +4234,7 @@ "header": [], "body": { "mode": "raw", - "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.importAVAX\",\n \"params\": {\n \"username\":\"{{avalancheUsername}}\",\n \"password\":\"{{avalanchePassword}}\",\n \"sourceChain\": \"X\",\n \"to\":\"{{pchainAddress}}\"\n },\n \"id\": 1\n}", + "raw": "{\n \"jsonrpc\": \"2.0\",\n \"method\": \"platform.importAVAX\",\n \"params\": {\n \"username\":\"{{avalancheUsername}}\",\n \"password\":\"{{avalanchePassword}}\",\n \"sourceChain\": \"X\",\n \"to\":\"{{pchainAddress}}\",\n \"from\": [\"{{pchainAddress}}\"],\n \"changeAddr\": \"{{pchainAddress}}\"\n },\n \"id\": 1\n}", "options": { "raw": { "language": "json" diff --git a/Example-Avalanche-Environment.postman_environment.json b/Example-Avalanche-Environment.postman_environment.json index 26b916a..137eb8e 100644 --- a/Example-Avalanche-Environment.postman_environment.json +++ b/Example-Avalanche-Environment.postman_environment.json @@ -3,27 +3,7 @@ "name": "Example-Avalanche-Environment", "values": [ { - "key": "protocol", - "value": "http", - "enabled": true - }, - { - "key": "host", - "value": "localhost", - "enabled": true - }, - { - "key": "port", - "value": "9650", - "enabled": true - }, - { - "key": "avalancheUsername", - "value": "YOUR_USERNAME", - "enabled": true - }, - { - "key": "avalanchePassword", + "key": "authPassword", "value": "YOUR_PASSWORD", "enabled": true }, @@ -38,65 +18,100 @@ "enabled": true }, { - "key": "avalancheSubnetId", - "value": "2bGsYJorY6X7RhjPBFs3kYjiNEHo4zGrD2eeyZbb43T2KKi7fM", + "key": "avalanchePassword", + "value": "YOUR_PASSWORD", "enabled": true }, { - "key": "avaxAssetId", - "value": "2fombhL7aGPwj3KH4bfrmJwW6PVnMobf9Y2fn9GwxiAAJyFDbe", + "key": "avalancheSubnetId", + "value": "2bGsYJorY6X7RhjPBFs3kYjiNEHo4zGrD2eeyZbb43T2KKi7fM", "enabled": true }, - { - "key": "xchainAddress", - "value": "X-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", + { + "key": "avalancheUsername", + "value": "YOUR_USERNAME", "enabled": true }, { - "key": "pchainAddress", - "value": "P-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", + "key": "avaxAssetId", + "value": "2fombhL7aGPwj3KH4bfrmJwW6PVnMobf9Y2fn9GwxiAAJyFDbe", "enabled": true }, - { + { + "key": "baseURL", + "value": "https://api.avax.network", + "enabled": true + }, + { + "key": "blockID", + "value": "d7WYmb8VeZNHsny3EJCwMm6QA37s1EHwMxw1Y71V3FqPZ5EFG", + "enabled": true + }, + { "key": "cchainAddress", "value": "0x820891f8b95daf5ea7d7ce7667e6bba2dd5c5594", "enabled": true }, + { + "key": "cchainbech32address", + "value": "C-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", + "enabled": true + }, { "key": "cchainPassphrase", "value": "YOUR_PASSWORD", "enabled": true }, { - "key": "privkey", - "value": "PrivateKey-ewoqjP7PxY4yr3iLTpLisriqt94hdyDFNgchSxGGztUrTXtNN", + "key": "customSubnetID", + "value": "j87H8JFHc3wWQ8FQ3P8gGyu9UHdPcz3BcqNTvJKUG6AJ6DDpF", "enabled": true }, { - "key": "authPassword", - "value": "YOUR_PASSWORD", + "key": "host", + "value": "localhost", "enabled": true }, { - "key": "cchainbech32address", - "value": "C-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", + "key": "memo", + "value": "2ug3siZMAGvW7bvgsaV4NZtvCSF8iuCnRGavujqT32qJ3AW", + "enabled": true + }, + { + "key": "pchainAddress", + "value": "P-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", "enabled": true }, { - "key": "customSubnetID", - "value": "j87H8JFHc3wWQ8FQ3P8gGyu9UHdPcz3BcqNTvJKUG6AJ6DDpF", + "key": "port", + "value": "9650", + "enabled": true + }, + { + "key": "privkey", + "value": "PrivateKey-ewoqjP7PxY4yr3iLTpLisriqt94hdyDFNgchSxGGztUrTXtNN", "enabled": true }, { - "key": "memo", - "value": "2ug3siZMAGvW7bvgsaV4NZtvCSF8iuCnRGavujqT32qJ3AW", + "key": "protocol", + "value": "http", "enabled": true + }, + { + "key": "txID", + "value": "P4SBqRTDAqJBjeRoDvptCCjPWnzzDZPmK9L7WQ7F9ec8zCtP3", + "enabled": true }, { - "key": "baseURL", - "value": "https://api.avax.network", + "key": "utxo", + "value": "KGDvUZzdJRWNYTy2ktU4Huay3UueZ94qNeBfRASnDDdzEYxvu", "enabled": true - } + }, + { + "key": "xchainAddress", + "value": "X-local18jma8ppw3nhx5r4ap8clazz0dps7rv5u00z96u", + "enabled": true + } ], "_postman_variable_scope": "environment", "_postman_exported_at": "2022-05-06T12:16:42.269Z",