TokenApi

TokenApi

new TokenApi()

Version:
  • 1.0

Token service.

Methods

getMtTokensByContractAddressAndOwnerAddress(xChainId, mtAddress, ownerAddress, opts, callback)

getMtTokensByContractAddressAndOwnerAddress Lists all tokens of a MT contract that are owned by the queried EOA address.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

ownerAddress String

EOA address

opts Object

Optional parameters

Properties
Name Type Description
cursor String

Offset for the next batch of items

size Number

Number of items to return (min=1, max=1000, default=100)

callback TokenApi~getMtTokensByContractAddressAndOwnerAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMtTokensWithBalance

getMtTokensByContractAddressAndOwnerAddressAndTokenId(xChainId, mtAddress, ownerAddress, tokenId, callback)

getMtTokensByContractAddressAndOwnerAddressAndTokenId Retrieves a specific MT information.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

ownerAddress String

Owner address

tokenId String

MT ID (hex)

callback TokenApi~getMtTokensByContractAddressAndOwnerAddressAndTokenIdCallback

The callback function, accepting three arguments: error, data, response data is of type: MtToken

getMtTokensByContractAddressAndTokenId(xChainId, mtAddress, tokenId, opts, callback)

getMtTokensByContractAddressAndTokenId Lists all EOA addresses who own the queried MT.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

tokenId String

MT ID (hex)

opts Object

Optional parameters

Properties
Name Type Description
cursor String

Offset for the next batch of items

size Number

Number of items to return (min=1, max=1000, default=100)

callback TokenApi~getMtTokensByContractAddressAndTokenIdCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMtTokens

getMtsByContractAddress(xChainId, mtAddress, opts, callback)

getMtsByContractAddress Lists all tokens minted from the queried MT contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

opts Object

Optional parameters

Properties
Name Type Description
size Number

Number of items to return (min=1, max=1000, default=100)

cursor String

Offset for the next batch of items

callback TokenApi~getMtsByContractAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMts

getNftById(xChainId, nftAddress, tokenId, callback)

getNftById Retrieve information for a specific NFT.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

tokenId String

NFT ID (HEX)

callback TokenApi~getNftByIdCallback

The callback function, accepting three arguments: error, data, response data is of type: Nft

getNftsByContractAddress(xChainId, nftAddress, opts, callback)

getNftsByContractAddress Specify an NFT contract to retrieve the information for all NFTs issued by the contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

opts Object

Optional parameters

Properties
Name Type Description
size Number

Maxium number of items to return (min=1, max=1000, default=100)

cursor String

Response offset

callback TokenApi~getNftsByContractAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableNfts

getNftsByOwnerAddress(xChainId, nftAddress, ownerAddress, opts, callback)

getNftsByOwnerAddress Specify the NFT contract and EOA to retrieve the information of the NFTs which the EOA currently owns and were issued by the NFT contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

ownerAddress String

EOA address

opts Object

Optional parameters

Properties
Name Type Description
size Number

Maximum number of items to return (min=1, max=1000, default=100)

cursor String

Response offset

callback TokenApi~getNftsByOwnerAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableNfts

Type Definitions

getMtTokensByContractAddressAndOwnerAddressCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndOwnerAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMtTokensWithBalance

The data returned by the service call.

response String

The complete HTTP response.

getMtTokensByContractAddressAndOwnerAddressAndTokenIdCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndOwnerAddressAndTokenId operation.

Parameters:
Name Type Description
error String

Error message, if any.

data MtToken

The data returned by the service call.

response String

The complete HTTP response.

getMtTokensByContractAddressAndTokenIdCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndTokenId operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMtTokens

The data returned by the service call.

response String

The complete HTTP response.

getMtsByContractAddressCallback(error, data, response)

Callback function to receive the result of the getMtsByContractAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMts

The data returned by the service call.

response String

The complete HTTP response.

getNftByIdCallback(error, data, response)

Callback function to receive the result of the getNftById operation.

Parameters:
Name Type Description
error String

Error message, if any.

data Nft

The data returned by the service call.

response String

The complete HTTP response.

getNftsByContractAddressCallback(error, data, response)

Callback function to receive the result of the getNftsByContractAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableNfts

The data returned by the service call.

response String

The complete HTTP response.

getNftsByOwnerAddressCallback(error, data, response)

Callback function to receive the result of the getNftsByOwnerAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableNfts

The data returned by the service call.

response String

The complete HTTP response.

TokenApi

new TokenApi(apiClientopt)

Constructs a new TokenApi.

Parameters:
Name Type Attributes Description
apiClient ApiClient <optional>

Optional API client implementation to use, default to ApiClient#instance if unspecified.

Methods

getMtTokensByContractAddressAndOwnerAddress(xChainId, mtAddress, ownerAddress, opts, callback)

getMtTokensByContractAddressAndOwnerAddress Lists all tokens of a MT contract that are owned by the queried EOA address.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

ownerAddress String

EOA address

opts Object

Optional parameters

Properties
Name Type Description
cursor String

Offset for the next batch of items

size Number

Number of items to return (min=1, max=1000, default=100)

callback TokenApi~getMtTokensByContractAddressAndOwnerAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMtTokensWithBalance

getMtTokensByContractAddressAndOwnerAddressAndTokenId(xChainId, mtAddress, ownerAddress, tokenId, callback)

getMtTokensByContractAddressAndOwnerAddressAndTokenId Retrieves a specific MT information.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

ownerAddress String

Owner address

tokenId String

MT ID (hex)

callback TokenApi~getMtTokensByContractAddressAndOwnerAddressAndTokenIdCallback

The callback function, accepting three arguments: error, data, response data is of type: MtToken

getMtTokensByContractAddressAndTokenId(xChainId, mtAddress, tokenId, opts, callback)

getMtTokensByContractAddressAndTokenId Lists all EOA addresses who own the queried MT.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

tokenId String

MT ID (hex)

opts Object

Optional parameters

Properties
Name Type Description
cursor String

Offset for the next batch of items

size Number

Number of items to return (min=1, max=1000, default=100)

callback TokenApi~getMtTokensByContractAddressAndTokenIdCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMtTokens

getMtsByContractAddress(xChainId, mtAddress, opts, callback)

getMtsByContractAddress Lists all tokens minted from the queried MT contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

mtAddress String

MT contract address to look up

opts Object

Optional parameters

Properties
Name Type Description
size Number

Number of items to return (min=1, max=1000, default=100)

cursor String

Offset for the next batch of items

callback TokenApi~getMtsByContractAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableMts

getNftById(xChainId, nftAddress, tokenId, callback)

getNftById Retrieve information for a specific NFT.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

tokenId String

NFT ID (HEX)

callback TokenApi~getNftByIdCallback

The callback function, accepting three arguments: error, data, response data is of type: Nft

getNftsByContractAddress(xChainId, nftAddress, opts, callback)

getNftsByContractAddress Specify an NFT contract to retrieve the information for all NFTs issued by the contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

opts Object

Optional parameters

Properties
Name Type Description
size Number

Maxium number of items to return (min=1, max=1000, default=100)

cursor String

Response offset

callback TokenApi~getNftsByContractAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableNfts

getNftsByOwnerAddress(xChainId, nftAddress, ownerAddress, opts, callback)

getNftsByOwnerAddress Specify the NFT contract and EOA to retrieve the information of the NFTs which the EOA currently owns and were issued by the NFT contract.

## Size

* The size query parameter is optional (minimum = 1, maximum = 1000, default = 100).
* Submitting negative values result in errors.
* Submitting zero results in a query with size=100, which is the default value.
* Submitting values greater than 1000 result in queries with size=1000, which is the maximum value.

Parameters:
Name Type Description
xChainId String

Klaytn network chain ID (1001 or 8217)

nftAddress String

NFT contract address

ownerAddress String

EOA address

opts Object

Optional parameters

Properties
Name Type Description
size Number

Maximum number of items to return (min=1, max=1000, default=100)

cursor String

Response offset

callback TokenApi~getNftsByOwnerAddressCallback

The callback function, accepting three arguments: error, data, response data is of type: PageableNfts

Type Definitions

getMtTokensByContractAddressAndOwnerAddressCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndOwnerAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMtTokensWithBalance

The data returned by the service call.

response String

The complete HTTP response.

getMtTokensByContractAddressAndOwnerAddressAndTokenIdCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndOwnerAddressAndTokenId operation.

Parameters:
Name Type Description
error String

Error message, if any.

data MtToken

The data returned by the service call.

response String

The complete HTTP response.

getMtTokensByContractAddressAndTokenIdCallback(error, data, response)

Callback function to receive the result of the getMtTokensByContractAddressAndTokenId operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMtTokens

The data returned by the service call.

response String

The complete HTTP response.

getMtsByContractAddressCallback(error, data, response)

Callback function to receive the result of the getMtsByContractAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableMts

The data returned by the service call.

response String

The complete HTTP response.

getNftByIdCallback(error, data, response)

Callback function to receive the result of the getNftById operation.

Parameters:
Name Type Description
error String

Error message, if any.

data Nft

The data returned by the service call.

response String

The complete HTTP response.

getNftsByContractAddressCallback(error, data, response)

Callback function to receive the result of the getNftsByContractAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableNfts

The data returned by the service call.

response String

The complete HTTP response.

getNftsByOwnerAddressCallback(error, data, response)

Callback function to receive the result of the getNftsByOwnerAddress operation.

Parameters:
Name Type Description
error String

Error message, if any.

data PageableNfts

The data returned by the service call.

response String

The complete HTTP response.