Metadata API

Download OpenAPI specification:Download

Introduction

The Metadata API helps DApp (Decentalized Application) developers to manage assets and metadata for their tokens.

Asset and metadata are used when you mint Kaia's KIP-17 Tokens (NFTs), KIP-37 Tokens (MTs).

An asset refers to an image or a video file of an NFT or MT. When you mint an NFT or MT, you first have to upload the asset and include the returned asset URI in the metadata when minting the token. Metadata originally refers to "data of data". In the context of NFTs or MTs, it refers to the properties (name, description, image URL etc.) of the tokens. It is stored in JSON format.

Metadata API enables you to do the following actions:

  • upload assets
  • upload metadata
  • provide an externally accessible URI for the assets and metadata

Error Code

This section contains the errors that might occur when using Metadata API. KAS uses HTTP status codes. Error code tables can be found here.

Authentication

basic

KAS uses Basic HTTP Auth. All requests must have a correct Authorization header. You can create the Credential for Basic Auth by using username as AccessKey ID and password as SecretAccessKey obtained on KAS Console.

NOTE

The KAS account credentials grant access to all services of KAS and own all rights to the Kaia account created by Wallet API, which means they can execute value transfer of assets on the Kaia account (such as KAIA) or a Transaction execution. To keep your KAS/Kaia account secure, do not share your KAS API Secret Access Key with others and manage it safely.

cURL

  curl --location --request GET 'https://kip7-api.klaytnapi.com/v1/contract' \
  -u ${your_accessKeyId}:${your_secretAccessKey} \
  --header 'x-chain-id: 1001' \
  --header 'Content-Type: application/json'
Security Scheme Type HTTP
HTTP Authorization Scheme basic