---
title: /getCoins
slug: getcoins
createdAt: 2024-01-09T12:30:00.567Z
---

{
  "id": "36-wnpAEnB4VEdaC-4s0k",
  "type": "api-oas-v2",
  "data": {
    "method": "POST",
    "url": "http://1.1.1.1/getCoins",
    "servers": [
      {
        "url": "http://1.1.1.1/getCoins"
      }
    ],
    "name": "",
    "description": "<p>param None</p>\n<ul>\n<li>return - list of all coin symbols in the system, and data about them</li>\n</ul>",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "optional",
          "name": "body",
          "type": "object",
          "customType": "getCoinsRequest",
          "schema": [
            {
              "name": "FunctionData",
              "kind": "optional",
              "type": "object",
              "example": "",
              "schema": []
            },
            {
              "name": "Meta",
              "kind": "optional",
              "type": "object",
              "modelRef": "#/components/schemas/MetaTokengetCoins",
              "customType": "MetaTokengetCoins",
              "schema": [
                {
                  "name": "FunctionName",
                  "kind": "optional",
                  "type": "string",
                  "description": "The Function to be called",
                  "example": "getCoins",
                  "default": "getCoins"
                },
                {
                  "name": "RandomData",
                  "kind": "optional",
                  "type": "string",
                  "description": "Random Data",
                  "example": "288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229",
                  "default": "288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229"
                },
                {
                  "name": "Destination",
                  "kind": "optional",
                  "type": "string",
                  "description": "Id of the server",
                  "example": "",
                  "default": "b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea"
                },
                {
                  "name": "Time",
                  "kind": "optional",
                  "type": "string",
                  "description": "UTC Time of execution",
                  "example": "2021-02-07T18:37:46.948Z",
                  "default": "2021-02-07T18:37:46.948Z"
                },
                {
                  "name": "Source",
                  "kind": "optional",
                  "type": "string",
                  "description": "User public key",
                  "example": "",
                  "default": "048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99"
                },
                {
                  "name": "AccessToken",
                  "kind": "optional",
                  "type": "string",
                  "description": "Token used for authentication purposes",
                  "example": "51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087",
                  "default": "51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087"
                }
              ]
            }
          ],
          "modelRef": "#/components/schemas/getCoinsRequest",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "success",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "schema": [
              {
                "name": "FunctionData",
                "kind": "optional",
                "type": "object",
                "example": "",
                "schema": [
                  {
                    "name": "Coins",
                    "kind": "optional",
                    "type": "array",
                    "description": "Array with every coin used in the wallets",
                    "example": "",
                    "itemType": "object",
                    "customType": "object[]",
                    "schema": [
                      {
                        "name": "CoinDataSignedByCold",
                        "kind": "optional",
                        "type": "object",
                        "description": "The data sent and signed from the cold wallet",
                        "example": "",
                        "schema": [
                          {
                            "name": "Data",
                            "kind": "optional",
                            "type": "object",
                            "example": "",
                            "schema": [
                              {
                                "name": "CoinsFamily",
                                "kind": "optional",
                                "type": "string",
                                "description": "enum for CoinsFamily",
                                "example": " 0 for Native coins (all the coins other than EVM coins and ERC20 tokens), 1 for EVM (Ethereum Virtual Machine) coins - https://ethereum.org/en/developers/docs/evm/ , 2 for ERC20 tokens"
                              },
                              {
                                "name": "AddressRegex",
                                "kind": "optional",
                                "type": "string",
                                "description": "The pattern used for this currency's addresses",
                                "example": "^([13][a-km-zA-HJ-NP-Z1-9]{25,34}|bc1[ac-hj-np-zAC-HJ-NP-Z02-9]{11,71})$",
                                "default": "^([13][a-km-zA-HJ-NP-Z1-9]{25,34}|bc1[ac-hj-np-zAC-HJ-NP-Z02-9]{11,71})$"
                              },
                              {
                                "name": "AmountRegex",
                                "kind": "optional",
                                "type": "string",
                                "description": "The pattern used for this currency's amount",
                                "example": "^(0|[1-9]\\\\d{0,7}){1}(\\\\.\\\\d{1,8})?$",
                                "default": "^(0|[1-9]\\\\d{0,7}){1}(\\\\.\\\\d{1,8})?$"
                              },
                              {
                                "name": "Decimal",
                                "kind": "optional",
                                "type": "integer",
                                "description": "Number of decimals this currency works with",
                                "example": 8,
                                "default": 8
                              },
                              {
                                "name": "FeeDecimal",
                                "kind": "optional",
                                "type": "integer",
                                "description": "Number of decimals this currency uses for the fee",
                                "example": 8,
                                "default": 8
                              },
                              {
                                "name": "FeeRegex",
                                "kind": "optional",
                                "type": "string",
                                "description": "The pattern used for this currency's fee",
                                "example": "^([1-9]\\\\d{0,7}){1}$",
                                "default": "^([1-9]\\\\d{0,7}){1}$"
                              },
                              {
                                "name": "Key",
                                "kind": "optional",
                                "type": "integer",
                                "description": "Id of the currency in our system (between 0 and the amount of currencies)",
                                "example": 0,
                                "default": 0
                              },
                              {
                                "name": "Name",
                                "kind": "optional",
                                "type": "string",
                                "description": "The name of this currency",
                                "example": "Bitcoin",
                                "default": "Bitcoin"
                              },
                              {
                                "name": "Symbol",
                                "kind": "optional",
                                "type": "string",
                                "description": "The symbol of this currency",
                                "example": "BTC",
                                "default": "BTC"
                              },
                              {
                                "name": "Time",
                                "kind": "optional",
                                "type": "string",
                                "description": "Time of this operation",
                                "example": "2021-02-11 12:54:46.251",
                                "default": "2021-02-11 12:54:46.251"
                              },
                              {
                                "name": "Type",
                                "kind": "optional",
                                "type": "string",
                                "description": "The type of this currency",
                                "example": "Coin",
                                "default": "Coin"
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "name": "CoinSymbol",
                        "kind": "optional",
                        "type": "string",
                        "description": "The symbol of the coin used in this operation",
                        "example": "BTC",
                        "default": "BTC"
                      }
                    ]
                  },
                  {
                    "name": "SelectedCurrencySignedByCold",
                    "kind": "optional",
                    "type": "object",
                    "description": "The FIAT currency used by the Wallets",
                    "example": "",
                    "schema": [
                      {
                        "name": "Data",
                        "kind": "optional",
                        "type": "object",
                        "example": "",
                        "schema": [
                          {
                            "name": "Country",
                            "kind": "optional",
                            "type": "string",
                            "description": "Country selected",
                            "example": "Country",
                            "default": "Country"
                          },
                          {
                            "name": "Description",
                            "kind": "optional",
                            "type": "string",
                            "description": "Description of the FIAT currency",
                            "example": "US Dollar",
                            "default": "US Dollar"
                          },
                          {
                            "name": "DigitalCode",
                            "kind": "optional",
                            "type": "string",
                            "description": "Digital Code of this FIAT currency",
                            "example": "840",
                            "default": "840"
                          },
                          {
                            "name": "Name",
                            "kind": "optional",
                            "type": "string",
                            "description": "The Name of the used currency",
                            "example": "USD",
                            "default": "USD"
                          },
                          {
                            "name": "Symbol",
                            "kind": "optional",
                            "type": "string",
                            "description": "The symbol used with this currency",
                            "example": "$",
                            "default": "$"
                          },
                          {
                            "name": "Time",
                            "kind": "optional",
                            "type": "string",
                            "description": "Time of this operation",
                            "example": "2021-02-11 12:54:46.251",
                            "default": "2021-02-11 12:54:46.251"
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "name": "CoinsPrice",
                    "kind": "optional",
                    "type": "integer",
                    "description": "Coin price as defined in the system",
                    "example": 35000,
                    "default": 35000
                  },
                  {
                    "name": "NodeStatus",
                    "kind": "optional",
                    "type": "integer",
                    "description": "NodeStatusEnum<br> * 0 Disabled * 1 Disconnected * 2 Unsynced * 3 Synced",
                    "example": 3,
                    "default": 3
                  }
                ]
              },
              {
                "name": "Meta",
                "kind": "optional",
                "type": "object",
                "modelRef": "#/components/schemas/MetaResponse",
                "customType": "MetaResponse",
                "schema": [
                  {
                    "name": "AccessToken",
                    "kind": "optional",
                    "type": "string",
                    "description": "The new access token generated after this operation",
                    "example": "a3e816b5bc04302d99da94705ec2309a4a63fe10d6aed3c5f6fc9e7ff27c6be6",
                    "default": "a3e816b5bc04302d99da94705ec2309a4a63fe10d6aed3c5f6fc9e7ff27c6be6"
                  },
                  {
                    "name": "Destination",
                    "kind": "optional",
                    "type": "string",
                    "description": "Id of the server",
                    "example": "042c671aeb148d9b2bb4918399c4c925f3764248c5ab2d5194ab0f32664132834692699a75e7fafb5af35f183b7d8a68bdc3b3e6ebfaff8ab555b9a3caf8090622",
                    "default": "042c671aeb148d9b2bb4918399c4c925f3764248c5ab2d5194ab0f32664132834692699a75e7fafb5af35f183b7d8a68bdc3b3e6ebfaff8ab555b9a3caf8090622"
                  },
                  {
                    "name": "Source",
                    "kind": "optional",
                    "type": "string",
                    "description": "User public key",
                    "example": "df4b76a23067a9d782d09a7372ed526ec713cf6d771fac4dbdb9610f7af36d570a157eed76986b8e85afde12888d10d10bef461399e490f3d7e4db44cde1b6e355",
                    "default": "df4b76a23067a9d782d09a7372ed526ec713cf6d771fac4dbdb9610f7af36d570a157eed76986b8e85afde12888d10d10bef461399e490f3d7e4db44cde1b6e355"
                  },
                  {
                    "name": "Time",
                    "kind": "optional",
                    "type": "string",
                    "description": "UTC Time of execution",
                    "example": "2021-02-14 09:58:52.320",
                    "default": "2021-02-14 09:58:52.320"
                  }
                ]
              }
            ],
            "isExpanded": true
          }
        ]
      }
    ],
    "examples": {
      "languages": [
        {
          "id": "example-0-curl",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request POST \\\n     --url http://1.1.1.1/getCoins \\\n     --header 'accept: application/json' \\\n     --header 'content-type: application/json' \\\n     --data '{\n     \"Meta\": {\n     \"FunctionName\": \"getCoins\",\n     \"RandomData\": \"288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229\",\n     \"Destination\": \"b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea\",\n     \"Time\": \"2021-02-07T18:37:46.948Z\",\n     \"Source\": \"048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99\",\n     \"AccessToken\": \"51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087\"\n     }\n     }'"
        },
        {
          "id": "example-1-javascript",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar raw = JSON.stringify({\n   \"Meta\": {\n      \"FunctionName\": \"getCoins\",\n      \"RandomData\": \"288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229\",\n      \"Destination\": \"b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea\",\n      \"Time\": \"2021-02-07T18:37:46.948Z\",\n      \"Source\": \"048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99\",\n      \"AccessToken\": \"51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087\"\n   }\n});\n\nvar requestOptions = {\n   method: 'POST',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"http://1.1.1.1/getCoins\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "example-2-ruby",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"http://1.1.1.1/getCoins\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Post.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\nrequest.body = JSON.dump({\n   \"Meta\": {\n      \"FunctionName\": \"getCoins\",\n      \"RandomData\": \"288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229\",\n      \"Destination\": \"b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea\",\n      \"Time\": \"2021-02-07T18:37:46.948Z\",\n      \"Source\": \"048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99\",\n      \"AccessToken\": \"51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087\"\n   }\n})\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "example-3-python",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"http://1.1.1.1/getCoins\"\n\npayload = json.dumps({\n   \"Meta\": {\n      \"FunctionName\": \"getCoins\",\n      \"RandomData\": \"288cd49d4b8bf00e7d6114b78d5668d5581d6b953fafef779133caa844cd4229\",\n      \"Destination\": \"b9cb8afe52f1d52521cf2b62dfe12146156ad5328f83c62c20c7da81b263356a61340de745c858998544c041798b01c2f4fac31bebe52a19280a32cd57d6d374ea\",\n      \"Time\": \"2021-02-07T18:37:46.948Z\",\n      \"Source\": \"048b99461a70a49abe63fd585cb224177a22a92d2e9e4ddfbc0027887bee9d1843388f42a3eb2e740565e115ad8b7981abf59e3b03b771f4b063b53c517d7a9d99\",\n      \"AccessToken\": \"51311c84d2c8fd2fafbe56ceb1fb30a99d3417abfc55769577338ab286798087\"\n   }\n})\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "example-0-curl"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// success\n{\n  \"FunctionData\": {\n    \"Coins\": [\n      {\n        \"CoinDataSignedByCold\": {\n          \"Data\": {\n            \"CoinsFamily\": \" 0 for Native coins (all the coins other than EVM coins and ERC20 tokens), 1 for EVM (Ethereum Virtual Machine) coins - https://ethereum.org/en/developers/docs/evm/ , 2 for ERC20 tokens\",\n            \"AddressRegex\": \"^([13][a-km-zA-HJ-NP-Z1-9]{25,34}|bc1[ac-hj-np-zAC-HJ-NP-Z02-9]{11,71})$\",\n            \"AmountRegex\": \"^(0|[1-9]\\\\\\\\d{0,7}){1}(\\\\\\\\.\\\\\\\\d{1,8})?$\",\n            \"Decimal\": 8,\n            \"FeeDecimal\": 8,\n            \"FeeRegex\": \"^([1-9]\\\\\\\\d{0,7}){1}$\",\n            \"Key\": 0,\n            \"Name\": \"Bitcoin\",\n            \"Symbol\": \"BTC\",\n            \"Time\": \"2021-02-11 12:54:46.251\",\n            \"Type\": \"Coin\"\n          }\n        },\n        \"CoinSymbol\": \"BTC\"\n      }\n    ],\n    \"SelectedCurrencySignedByCold\": {\n      \"Data\": {\n        \"Country\": \"Country\",\n        \"Description\": \"US Dollar\",\n        \"DigitalCode\": \"840\",\n        \"Name\": \"USD\",\n        \"Symbol\": \"$\",\n        \"Time\": \"2021-02-11 12:54:46.251\"\n      }\n    },\n    \"CoinsPrice\": 35000,\n    \"NodeStatus\": 3\n  },\n  \"Meta\": {\n    \"AccessToken\": \"a3e816b5bc04302d99da94705ec2309a4a63fe10d6aed3c5f6fc9e7ff27c6be6\",\n    \"Destination\": \"042c671aeb148d9b2bb4918399c4c925f3764248c5ab2d5194ab0f32664132834692699a75e7fafb5af35f183b7d8a68bdc3b3e6ebfaff8ab555b9a3caf8090622\",\n    \"Source\": \"df4b76a23067a9d782d09a7372ed526ec713cf6d771fac4dbdb9610f7af36d570a157eed76986b8e85afde12888d10d10bef461399e490f3d7e4db44cde1b6e355\",\n    \"Time\": \"2021-02-14 09:58:52.320\"\n  }\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "id": "M07kffPpZHCWS22BN1aRX",
      "type": "paragraph",
      "children": [
        {
          "text": "param None",
          "id": "DulzzZZWwOnZgnGwvM-Ci"
        }
      ]
    },
    {
      "id": "wjMrmTvyBdmQR4LkStNVw",
      "type": "bulleted-list",
      "children": [
        {
          "id": "_TyqWKGK5eY0wIfod2oYk",
          "type": "list-item",
          "children": [
            {
              "id": "YDvgw9OrTA2mPsWnyIYe6",
              "type": "list-item-child",
              "children": [
                {
                  "text": "return - list of all coin symbols in the system, and data about them",
                  "id": "Nj9Oc6KvGR426gFpDOUtm"
                }
              ]
            }
          ]
        }
      ]
    }
  ]
}