Initialize a Token

Request:

mutation {
  makeToken (
    input: {
      _tokenId: "7ae8c3b7-43a4-4ee3-99c8-812e101d3859"
      _chain: "ethereum-vertalo"
      _name: "Series A Token"
      _symbol: "SERIESA"
    }
  ) {
    token {
      contractsByTokenId {
        nodes {
          id
        }
      }
    }
  }
}
Response:

{
  "data": {
    "makeToken": {
      "token": {
        "contractsByTokenId": {
          "nodes": [
            {
              "id": "48e2486f-a988-4f92-9794-4df831c03879"
            }
          ]
        }
      }
    }
  }
}

In this example, the mutation initializes a new token for a round. There is a one-to-one relationship between round and token, with a token ID being automatically assigned at the creation of a round. The ID of the smart contract associated with the token is returned in the payload. The value for _tokenId can be derived as follows:

Request:

query {
  roundById (id: "3fb91ee2-eb13-4308-b4ca-1c968a6546a4") {
    tokenByTokenId {
      id
    }
  }
}
Response:

{
  "data": {
    "roundById": {
      "tokenByTokenId": {
        "id": "7ae8c3b7-43a4-4ee3-99c8-812e101d3859"
      }
    }
  }
}
What's on this Page