Upload Metadata

Uploads metadata. After uploading the metadata, it returns an externally accessible public URI for that metadata.

Note

The URI in the response looks like this:

https://metadata-store.klaytnapi.com/{storage-id}/{fileName}.

  • {storage-id}(UUID) is an identifer automatically given to each user.
  • With no fileName: .../{storage-id}/{assetId}.json
  • With fileName (example: haha.json): .../{storage-id}/haha.json
Request
Security:
header Parameters
x-chain-id
required
string

Kaia Network Chain ID (1001 or 8217)

Request Body schema: application/json
required
object

JSON metadata

filename
string

A file name of your choice. File extension must be .json. If the file name is already taken you will get a duplicate key error.

Responses
200

Your request was successful.

400

The request is not valid.

post/v1/metadata
Request samples
application/json
{}
Response samples
application/json
{}