Skip to main content

EmojiIDApi

All URIs are relative to http://localhost

MethodHTTP requestDescription
editEmojiIDPATCH /emoji_id/{emoji_id}Edit EmojiId
emojiIDMetadataGET /emoji_id/{emoji_id}/metadata
generateSignaturePOST /emoji_id/{emoji_id}/generate_signatureGenerates a signature for the Yat allowing it to be minted
getStatsGET /emoji_id/{eid}/statsGet statistics for EmojiId
linkRedirectGET /redirectRedirect by EmojiId link
listEmojiIDsGET /emoji_idList user's Emoji Ids
listExtendedGET /emoji_id/extendedList extended view user's Emoji Ids
loadJsonGET /emoji_id/{eid}/json/{key}Load value from EmojiId key value store
loadJsonIndexGET /emoji_id/{eid}/jsonLoad value from EmojiId key value store with data keyed by YatJsonStoreKeys
lookupEmojiIDGET /emoji_id/{emoji_id}Lookup EmojiId
lookupEmojiIDPaymentGET /emoji_id/{emoji_id}/paymentLookup EmojiId Payment addresses
lookupEmojiIdTickerGET /emoji_id/{emoji_id}/{tag}Lookup EmojiId data based on a symbol or ticker
metadataGET /nft_transfers/metadata/{token_id}
randomGET /emoji_id/randomReturn random Emoji
recentGET /emoji_id/recentReturn list of recently purchased emoji
rhythmGET /emoji_id/{emoji_id}/rhythmCalculate EmojiId rhythm score
searchEmojiIDGET /emoji_id/searchSearch for EmojiID
storeJsonPOST /emoji_id/{eid}/json/{key}Store value under EmojiId key

editEmojiID#

/*** @returns Object**/async function editEmojiID(emojiId: String, body: EditRequest)

Edit EmojiId

Notes:#

Add and remove records in EmojiId, update merkle_root and signature too. Certain tags, such as CryptocurrenyAddress, EmojiNick, EmojiDescription, EmojiPreferred, Redirect only allow a single value to be stored by default. Only the latest values will be stored and older values deleted. To allow multiple values for the same tag pass in true for bypass_single_restrictions Access notes: user expected to own the emoji's pubkey, have Admin role or be power member of organization if pubkey belongs to organization, otherwise operation will fail.

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let body = new YatJs.EditRequest(); // EditRequest // populate body...
try {  let res = await api.emojiID().editEmojiID(emojiId, body);  // res is of type Object  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
bodyEditRequest

Return type#

Object

Authorization#

apiKey

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

emojiIDMetadata#

/*** @returns ShapeMatch**/async function emojiIDMetadata(emojiId: String)

Example#

const yat = require('yatjs');const api = new yat.YatJs();

let emojiId = "emojiId_example"; // String // populate emojiId...
try {  let res = await api.emojiID().emojiIDMetadata(emojiId);  // res is of type ShapeMatch  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString

Return type#

ShapeMatch

Authorization#

No authorization required

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

generateSignature#

/*** @returns SignatureResponse**/async function generateSignature(emojiId: String, body: SignatureRequest)

Generates a signature for the Yat allowing it to be minted

Notes:#

If the yat has any active transfers for it or is in the pending transfer period this action fails

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let body = new YatJs.SignatureRequest(); // SignatureRequest // populate body...
try {  let res = await api.emojiID().generateSignature(emojiId, body);  // res is of type SignatureResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
bodySignatureRequest

Return type#

SignatureResponse

Authorization#

two_factor

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

getStats#

/*** @returns EmojiStatsResponse**/async function getStats(eid: String)

Get statistics for EmojiId

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let eid = "eid_example"; // String // populate eid...
try {  let res = await api.emojiID().getStats(eid);  // res is of type EmojiStatsResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
eidString

Return type#

EmojiStatsResponse

Authorization#

apiKey

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

linkRedirect#

/*** @returns null**/async function linkRedirect(emojiId: String, link: String)

Redirect by EmojiId link

Notes:#

Will redirect to a link if it is part of Emoji ID

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let link = "link_example"; // String // populate link...
try {  await api.emojiID().linkRedirect(emojiId, link);  console.log('API called successfully.');} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
linkString

Return type#

null (empty response body)

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: Not defined

listEmojiIDs#

/*** @returns [String]**/async function listEmojiIDs(opts)

List user's Emoji Ids

Notes:#

If no parameters provided will return all Emoji Ids of current user. When user_id or organization_id specified the endpoint will return the Emoji Ids owned by specified user or organization, requires Admin or organization power user access. Result is an array of emoji ids in display format (i.e. with all skin tone modifiers applied) [\"๐ŸคŸ๐Ÿพ๐Ÿ—๐Ÿ‘ฝ๐Ÿ‘ป\",\"๐ŸŒˆ๐Ÿ‘๐Ÿฟ๐Ÿ’ฏ\"]

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let opts = {  'organizationId': null, // String | Lookup emojis owned by `organization_id`,  requires organization power user role  'userId': null // String | Lookup emojis owned by `user_id`,  requires Admin role};try {  let res = await api.emojiID().listEmojiIDs(opts);  // res is of type [String]  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
organizationIdString
Lookup emojis owned by `organization_id`, requires organization power user role[optional]
userIdString
Lookup emojis owned by `user_id`, requires Admin role[optional]

Return type#

[String]

Authorization#

apiKey

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

listExtended#

/*** @returns [EmojiListItem]**/async function listExtended(opts)

List extended view user's Emoji Ids

Notes:#

Will return list of user's Emoji Ids with canonical and display representation. Display representation is Emoji Id with applied modifiers. If no parameters provided will return all Emoji Ids of the current user. When user_id or organization_id is specified the endpoint will return the Emoji Ids owned by the specified user or organization, requires Admin or organization power user access.

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let opts = {  'organizationId': null, // String | Lookup emojis owned by `organization_id`,  requires organization power user role  'userId': null // String | Lookup emojis owned by `user_id`,  requires Admin role};try {  let res = await api.emojiID().listExtended(opts);  // res is of type [EmojiListItem]  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
organizationIdString
Lookup emojis owned by `organization_id`, requires organization power user role[optional]
userIdString
Lookup emojis owned by `user_id`, requires Admin role[optional]

Return type#

[EmojiListItem]

Authorization#

apiKey

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

loadJson#

/*** @returns LoadJsonResponse**/async function loadJson(eid: String, key: String)

Load value from EmojiId key value store

Notes:#

Any data stored previously can be retrieved as a json object in EmojiID key value store. In the case when there was no data associated with EmojiID key before it will return empty object. User should have AdminEmojiWrite scope or own emoji

Example#

const yat = require('yatjs');const api = new yat.YatJs();

let eid = "eid_example"; // String | EmojiID// populate eid...
let key = "key_example"; // String | Key to store data// populate key...
try {  let res = await api.emojiID().loadJson(eid, key);  // res is of type LoadJsonResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
eidStringEmojiID
keyStringKey to store data

Return type#

LoadJsonResponse

Authorization#

No authorization required

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

loadJsonIndex#

/*** @returns {String: LoadJsonResponse}**/async function loadJsonIndex(eid: String, keys: [String])

Load value from EmojiId key value store with data keyed by YatJsonStoreKeys

Notes:#

Any data stored previously can be retrieved as a json object in EmojiID key value store. In the case when there was no data associated with EmojiID key before it will return empty object. User should have AdminEmojiWrite scope or own emoji

Example#

const yat = require('yatjs');const api = new yat.YatJs();

let eid = "eid_example"; // String // populate eid...
let keys = ["null"]; // [String] | Key to store data// populate keys...
try {  let res = await api.emojiID().loadJsonIndex(eid, keys);  // res is of type {String: LoadJsonResponse}  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
eidString
keys[String]
Key to store data

Return type#

{String: LoadJsonResponse}

Authorization#

No authorization required

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

lookupEmojiID#

/*** @returns LookupResponse**/async function lookupEmojiID(emojiId: String, opts)

Lookup EmojiId

Notes:#

Will filter and return data from supplied tags, If tags filter is not supplied will return all tags attached. It will also try to get views for the past month, if not available will return -1. This method is called when a user wants to look up an Emoji ID's records such as a crypto address or a redirect

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let opts = {  'tags': "tags_example" // String | Comma-separated list of tags to display, skip it to display all, e.g. `?tags=0x0001,0x1001`};try {  let res = await api.emojiID().lookupEmojiID(emojiId, opts);  // res is of type LookupResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
tagsStringComma-separated list of tags to display, skip it to display all, e.g. `?tags=0x0001,0x1001`[optional]

Return type#

LookupResponse

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

lookupEmojiIDPayment#

/*** @returns PaymentAddressResponse**/async function lookupEmojiIDPayment(emojiId: String, opts)

Lookup EmojiId Payment addresses

Notes:#

Will filter and return data from supplied tags, If tags filter is not supplied will return all payment tags attached. This method is called when a user wants to look up an Emoji ID's payment records and return a KV pair This endpoint returns a single result for each category type (except 0x6300) which it returns a unique 0x6300:short_name:settlement_network key instead. If there are multiple results for a crypto type it takes the most recent value unless there is a value that has the default flag set, in which case it uses the most recent default value.

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let opts = {  'tags': "tags_example" // String | Comma-separated list of tags to display, skip it to display all, e.g. `?tags=0x0001,0x1001`};try {  let res = await api.emojiID().lookupEmojiIDPayment(emojiId, opts);  // res is of type PaymentAddressResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
tagsStringComma-separated list of tags to display, skip it to display all, e.g. `?tags=0x0001,0x1001`[optional]

Return type#

PaymentAddressResponse

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

lookupEmojiIdTicker#

/*** @returns EidResponse**/async function lookupEmojiIdTicker(emojiId: String, tag: String)

Lookup EmojiId data based on a symbol or ticker

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String // populate emojiId...
let tag = "tag_example"; // String // populate tag...
try {  let res = await api.emojiID().lookupEmojiIdTicker(emojiId, tag);  // res is of type EidResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString
tagString

Return type#

EidResponse

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

metadata#

/*** @returns Metadata**/async function metadata(tokenId: Number)

Example#

const yat = require('yatjs');const api = new yat.YatJs();

let tokenId = 789; // Number // populate tokenId...
try {  let res = await api.emojiID().metadata(tokenId);  // res is of type Metadata  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
tokenIdNumber

Return type#

Metadata

Authorization#

No authorization required

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

random#

/*** @returns RandomResult**/async function random()

Return random Emoji

Notes:#

Returns price, availability and other information for random emoji

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
try {  let res = await api.emojiID().random();  // res is of type RandomResult  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

This endpoint does not have any parameters.

Return type#

RandomResult

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

recent#

/*** @returns RecentlyPurchasedResult**/async function recent()

Return list of recently purchased emoji

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
try {  let res = await api.emojiID().recent();  // res is of type RecentlyPurchasedResult  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

This endpoint does not have any parameters.

Return type#

RecentlyPurchasedResult

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

rhythm#

/*** @returns RhythmResponse**/async function rhythm(emojiId: String)

Calculate EmojiId rhythm score

Notes:#

The rhythm score is an indicator of a Yat's prestige, or status. Factors that affect the rhythm are length, shape, and the popularity of emojis present in the yat. The yat rhythm ranges from 1 (least prestigious) to 100 (most prestigious).

Example#

const yat = require('yatjs');const api = new yat.YatJs();

let emojiId = "emojiId_example"; // String // populate emojiId...
try {  let res = await api.emojiID().rhythm(emojiId);  // res is of type RhythmResponse  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdString

Return type#

RhythmResponse

Authorization#

No authorization required

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

searchEmojiID#

/*** @returns SearchResult**/async function searchEmojiID(emojiId: String)

Search for EmojiID

Notes:#

Returns price, availability and other information on emoji and its alternates (similar EmojiIDs that are currently available)

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let emojiId = "emojiId_example"; // String | Emoji ID in percent url-encoded form// populate emojiId...
try {  let res = await api.emojiID().searchEmojiID(emojiId);  // res is of type SearchResult  console.log('API called successfully. Result: ', res);} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
emojiIdStringEmoji ID in percent url-encoded form

Return type#

SearchResult

Authorization#

JWT

HTTP request headers#

  • Content-Type: Not defined
  • Accept: /

storeJson#

/*** @returns null**/async function storeJson(eid: String, key: String, body: StoreJsonBody)

Store value under EmojiId key

Notes:#

Any data can be stored as a json object, this data is stored in a centralized DB and is not taking blockchain storage. In addition to unformatted data this endpoint allows to edit tags in the same way as edit endpoint allows to. User should have AdminEmojiWrite scope or own emoji

Example#

const yat = require('yatjs');const api = new yat.YatJs();
await api.login("[email protected]", "your_password");
let eid = "eid_example"; // String | EmojiID// populate eid...
let key = "key_example"; // String | Key to store data// populate key...
let body = new YatJs.StoreJsonBody(); // StoreJsonBody // populate body...
try {  await api.emojiID().storeJson(eid, key, body);  console.log('API called successfully.');} catch (error) {  console.error(error);}

Parameters#

NameTypeDescriptionNotes
eidStringEmojiID
keyStringKey to store data
bodyStoreJsonBody

Return type#

null (empty response body)

Authorization#

apiKey

HTTP request headers#

  • Content-Type: Not defined
  • Accept: Not defined