0.2.248 • Published 3 years ago

yatjs v0.2.248

Weekly downloads
-
License
BSD-3
Repository
-
Last release
3 years ago

id: sdk_nodejs_index

title: Node / Javascript SDK

:::caution The SDK code and documentation are in ALPHA state and are under heavy development. As a result, the apis are still in flux, and the documentation may be out of date with the code. :::

Emoji ID is a directory service that associates almost any type of structured data with a short, memorable identifier the emoji id.

This SDK is automatically generated by the OpenAPI Generator project:

  • API version: 0.2.248
  • Package version: 0.2.248
  • Build package: org.openapitools.codegen.languages.JavascriptClientCodegen

Installation

:::note Until y.at is launched publically, the NPM package will not be available. You can contact the Yat team to obtain a copy of the javascript SDK while the project is in Alpha. :::

For Node.js

npm

npm install yatjs --save

Finally, you need to build the module:

npm run build

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module". In this case you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

Please follow the installation instruction and execute the following JS code:

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

async function runDemo() {
    console.log(`Yat API calls will be made to ${api.basePath}`);
    api.basePath = 'https://y.at/api;
    console.log(`Changed base path. Now Yat API calls will be made to ${api.basePath}`);
    try {
        let res = await api.login("bob@example.com", "wrong_password");
        console.log("Logged in (Should not see this): ", res);
    } catch (res) {
        console.log(`Could not log in: ${res.error}`);
        try {
            await api.users().getAccount(); // Not logged in, should throw an error
        } catch (res) {
            console.log(`Cannot access account: ${res.error}`);
        }
    }
    try {
        await api.login("test@yatlabs.com", "real_password");
        console.log("Logged in.");
        let account = await api.users().getAccount();
        console.log("Account data:", account);
    } catch (res) {
        console.log(`Could not log in: ${res.error}`);
    }
}

runDemo()
    .then(() => console.log("Bye"))
    .catch(console.error);

Documentation for API Endpoints

Once you have a YatJs instance, all the sub-APIs are accessed through getters, for example, the cart api is available as yat.cart(). A full list of sub-APIs and their methods is:

API accessorMethodDescription
apiKeys()createApiKeyCreate new api key for current user
apiKeys()deleteApiKeyDelete provided api key
apiKeys()listApiKeysLoad api keys for user
cart()addItemsUpdate cart items by adding new items to the cart
cart()applyPromoCodeApply promo code
cart()checkoutCheckout last payment cart
cart()checkoutOrderCheckout saved cart by id
cart()clearCartRemove all items from cart
cart()convertOrderToDraftConvert pending payment cart back into Draft status
cart()deletePaymentMethodsDelete payment method
cart()getItemsReturn cart content
cart()listPaymentMethodsFetch payment methods for the user
cart()removeItemRemoves an order item from the cart
discounts()activateRandomYatCodeUse random yat code
discounts()addPubkeyForCodeAdd pubkey for code
discounts()listCodesFetch codes
discounts()revokePubkeyForCodeRevoke pubkey for code
emoji()emojiListList of supported emoji characters
emojiID()editEmojiIDEdit EmojiId
emojiID()emojiIDMetadata
emojiID()generateSignatureGenerates a signature for the Yat allowing it to be minted
emojiID()getStatsGet statistics for EmojiId
emojiID()linkRedirectRedirect by EmojiId link
emojiID()listEmojiIDsList user's Emoji Ids
emojiID()listExtendedList extended view user's Emoji Ids
emojiID()loadJsonLoad value from EmojiId key value store
emojiID()loadJsonIndexLoad value from EmojiId key value store with data keyed by YatJsonStoreKeys
emojiID()lookupEmojiIDLookup EmojiId
emojiID()lookupEmojiIdTickerLookup EmojiId data based on a symbol or ticker
emojiID()metadata
emojiID()randomReturn random Emoji
emojiID()recentReturn list of recently purchased emoji
emojiID()rhythmCalculate EmojiId rhythm score
emojiID()searchEmojiIDSearch for EmojiID
emojiID()storeJsonStore value under EmojiId key
keyManagement()addPubkeyAdd pubkey for current user
keyManagement()addPubkeyForUserAdd pubkey for user by user_id
keyManagement()createWalletGenerate custodial wallet
keyManagement()getPubkeysRetrieve pubkeys
keyManagement()getPubkeysForUserRetrieve pubkeys by user_id
lootBoxType()createTypeCreate a new lootbox category
lootBoxType()generateLootBoxesGenerates a set of loot boxes
lootBoxType()getTypesList all loot box categories
lootBoxes()createLootboxCreate a new lootbox
lootBoxes()deleteLootboxDelete a lootbox
lootBoxes()listLootboxesFetch lootboxes
lootBoxes()openLootboxOpen lootbox
lootBoxes()showLootboxShow information about lootbox
lootBoxes()updateLootboxUpdate a lootbox
organization()getBrandingLoad organization branding paramters
organization()setBrandingSet organization branding parameters
proxy()callProxyCalls a pre-defined proxy service with the provided data
transfer()deleteTransferMark transfer request as deleted
transfer()listFilteredList outgoing transfer requests for current or specified user If limit is omitted will display top 50 transfer requests
transfer()listIncomingList transfer requests assigned to user
transfer()receiverAcceptTransferAs a receiver, accept transfer request by id.
transfer()requestTransferTransfer eid to either the pubkey or email address supplied in the PUT data
transfer()resendCodeResend a new transfer OTP code for the current user, if the transfer allows it.
transfer()senderAcceptTransferAs a sender, confirm the transfer request by transfer id.
userAuthentication()loginLogin via password
userAuthentication()logoutInvalidates all user's access tokens
userAuthentication()magicLinkLoginGenerate magic link for login
userAuthentication()refreshTokenRefresh access token
userAuthentication()twoFactorAuthenticationTwo factor authentication
userFeature()readFeaturesList users features
userInterest()deleteUserInterestDestroys the user interest preventing this Emoji ID's notification emails from being sent for this user
userInterest()getInterestedUsersReturns a paginated list of user interest records associated with the user
userInterest()getUserInterestForYatGiven an EmojiId returns information about the user interest if a record exists for this user
userInterest()registerInterestCreate new interest in emoji to be notified when available
users()backupDisable2FADisable choosen 2FA provider or disable completely using backup code and user primary ID
users()confirm2FAConfirm two factor authentication update
users()createUserRegister a User
users()deleteUserDelete a user
users()disable2FADisable choosen 2FA provider or disable completely
users()enable2FAEnables two factor authentication method
users()getAccountCurrent user account
users()getAllUsersList users
users()loadLoad user data for a session
users()send2FASmsSend SMS 2FA code
users()showUserShow users
users()updateAccountUpdate the currently logged in user
users()updateUserByAdminUpdate a user as an admin
wallets()listWalletsFetch associated wallet addresses for the user
wallets()syncWalletAssociate new wallet address with user

Documentation for Models

AcceptTransfer

Properties

NameTypeDescriptionNotes
codeStringConfirmation OTP of either the sender or receiver of the transfer

AddItemsCartRequest

Properties

NameTypeDescriptionNotes
items[AddItemsCartRequestItems]New items to add to cart
tracking_dataObjectTracking dataoptional

AddItemsCartRequestItems

Properties

NameTypeDescriptionNotes
emoji_idStringEmojiID to buy

AdminNewLootBoxBody

Properties

NameTypeDescriptionNotes
statusStringStatus lootbox will be created in If status is `Used` lootbox with be automatically opened
yatsStringLootBox emoji IDs
owner_emailStringAssign lootbox an owner with matching email Should not be set if owner_id is setoptional
owner_idStringLootbox owner_id, required for Owned and Used lootboxesoptional

Enum: StatusEnum

  • Draft (value: "Draft")

  • Available (value: "Available")

  • Owned (value: "Owned")

  • Used (value: "Used")

AdminNewLootBoxType

Properties

NameTypeDescriptionNotes
configAdminNewLootBoxTypeConfig
descriptionStringA description for the loot box type
nameStringthe name of the loot box type

AdminNewLootBoxTypeConfig

Properties

NameTypeDescriptionNotes
guarantees[AdminNewLootBoxTypeConfigGuarantees]A set of guaranteed drops in this loot box type
max_base_scoreNumberThe upper bound (inclusive) rhythm score for standard yats in the loot box
max_lengthNumberMaximum yat length
min_base_scoreNumberThe lower bound (inclusive) rhythm score for standard yats in the loot box
min_lengthNumberMinimum yat length
sizeNumberThe number of yats in the loot box
weights[AdminNewLootBoxTypeConfigWeights]A set of probability weightings for chance-based drops

AdminNewLootBoxTypeConfigGuarantees

Properties

NameTypeDescriptionNotes
countNumberThe number of guaranteed drops of this type in the loot box
max_scoreNumberThe highest (inclusive) rhythm score range for guaranteed drop
min_scoreNumberThe lowest (inclusive) rhythm score range for guaranteed drop

AdminNewLootBoxTypeConfigWeights

Properties

NameTypeDescriptionNotes
iprNumberThe inverse probability ratio. This is a 1:n value. i.e. an ipr of 5 means a 1 in 5 chance of occurring, or 20%
max_scoreNumberThe highest (inclusive) rhythm score range for inclusion when the probability spec hits
min_scoreNumberThe lowest (inclusive) rhythm score range for inclusion when the probability spec hits

AdminUpdateLootBoxBody

Properties

NameTypeDescriptionNotes
owner_emailStringAssign lootbox an owner with matching email Should not be set if owner_id is setoptional
owner_idStringAssign lootbox an owner, if set requires status `Owned`optional
statusStringUpdate status If status is `Used` lootbox with be automatically openedoptional
yatsStringLootBox emoji IDsoptional

Enum: StatusEnum

  • Draft (value: "Draft")

  • Available (value: "Available")

  • Owned (value: "Owned")

  • Used (value: "Used")

AdminUpdateUserParameters

Properties

NameTypeDescriptionNotes
activation_sourceStringOptional: Source of activationoptional
current_passwordStringOptional: Current password, must be provided if one existsoptional
emailStringOptional: Emailoptional
first_nameStringOptional: First nameoptional
free_limitNumberOptional: Free limit for how many yats the user may purchaseoptional
last_nameStringOptional: Last nameoptional
passwordStringOptional: User passwordoptional
roleStringOptional: Update the user roleoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

ApplyPromoCodeRequest

Properties

NameTypeDescriptionNotes
codeStringCode to apply

BackupDisableBody

Properties

NameTypeDescriptionNotes
backup_codeStringBackup code
alternate_idStringAlternate identifieroptional
disable_allBooleanMake this method defaultoptional
emailStringEmailoptional
providerStringTwo factor authentication backendoptional

Enum: ProviderEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

CheckoutCartRequest

Properties

NameTypeDescriptionNotes
methodStringPayment method type
amountNumberAmount paid in cash. Applicable and required only for `Cash` payment option for Admin.optional
cancel_urlStringURL user will be redirected if payment cancelled Required for Stripe Checkoutoptional
external_referenceStringExternal reference for cash payment. Applicable and required only for `Cash` payment option for Admin.optional
pubkeyStringOptional: The user's public key to associate with this emoji id. If provided will use this pubkey otherwise will default to the first pubkey returned for the user.optional
success_urlStringURL user will be redirected after successful payment Required for Stripe Checkoutoptional
tracking_dataObjectOptional: tracking dataoptional

Enum: MethodEnum

  • Free (value: "Free")

  • CoinbaseCommerce (value: "CoinbaseCommerce")

  • Stripe (value: "Stripe")

  • Cash (value: "Cash")

  • PayPal (value: "PayPal")

Confirm2Fa

Properties

NameTypeDescriptionNotes
codeStringTwo factor authentication code
refresh_tokenStringRefresh token obtained from login request

Confirm2FaUpdate

Properties

NameTypeDescriptionNotes
codeStringAuth code of new 2FA provider

CreateApiKeyBody

Properties

NameTypeDescriptionNotes
nameString
expires_atDateoptional
scopesStringoptional

Enum: ScopesEnum

  • adminCart:update (value: "adminCart:update")

  • adminEmoji:destroy (value: "adminEmoji:destroy")

  • adminEmoji:load (value: "adminEmoji:load")

  • adminEmoji:register (value: "adminEmoji:register")

  • adminEmoji:transfer (value: "adminEmoji:transfer")

  • adminEmoji:updateFeatures (value: "adminEmoji:updateFeatures")

  • adminEmoji:updateSecureData (value: "adminEmoji:updateSecureData")

  • adminEmoji:write (value: "adminEmoji:write")

  • adminFeatureUser:read (value: "adminFeatureUser:read")

  • adminInvites:write (value: "adminInvites:write")

  • adminInvites:list (value: "adminInvites:list")

  • adminLootbox:read (value: "adminLootbox:read")

  • adminLootbox:write (value: "adminLootbox:write")

  • adminNotifications:write (value: "adminNotifications:write")

  • adminUser:bypass2fa (value: "adminUser:bypass2fa")

  • adminUser:load (value: "adminUser:load")

  • adminUser:loginAs (value: "adminUser:loginAs")

  • adminUser:twoFactorAuthDestroy (value: "adminUser:twoFactorAuthDestroy")

  • adminUser:roleUpdate (value: "adminUser:roleUpdate")

  • cart:show (value: "cart:show")

  • cart:update (value: "cart:update")

  • code:delete (value: "code:delete")

  • code:read (value: "code:read")

  • code:write (value: "code:write")

  • user:createApiKey (value: "user:createApiKey")

  • domainAction:read (value: "domainAction:read")

  • domainEvent:read (value: "domainEvent:read")

  • edition:delete (value: "edition:delete")

  • edition:read (value: "edition:read")

  • edition:write (value: "edition:write")

  • emojiGroups:delete (value: "emojiGroups:delete")

  • emojiGroups:read (value: "emojiGroups:read")

  • emojiGroups:write (value: "emojiGroups:write")

  • emoji::transfer (value: "emoji::transfer")

  • feature::delete (value: "feature::delete")

  • feature::read (value: "feature::read")

  • feature::write (value: "feature::write")

  • lootbox:use (value: "lootbox:use")

  • order:paymentOverride (value: "order:paymentOverride")

  • order:read (value: "order:read")

  • order:readSelf (value: "order:readSelf")

  • order:refund (value: "order:refund")

  • order:refundOverride (value: "order:refundOverride")

  • order:resendConfirmation (value: "order:resendConfirmation")

  • organization:admin (value: "organization:admin")

  • organizationCode:admin (value: "organizationCode:admin")

  • organizationEmoji:list (value: "organizationEmoji:list")

  • organizationEmoji:write (value: "organizationEmoji:write")

  • organizationList:read (value: "organizationList:read")

  • organization:read (value: "organization:read")

  • organizationUser:admin (value: "organizationUser:admin")

  • organizationUser:read (value: "organizationUser:read")

  • organization:write (value: "organization:write")

  • nftSignature:write (value: "nftSignature:write")

  • nftToken:destroy (value: "nftToken:destroy")

  • nftTransfer:read (value: "nftTransfer:read")

  • paymentMethod:destroy (value: "paymentMethod:destroy")

  • paymentMethod:read (value: "paymentMethod:read")

  • paymentMethod:setDefault (value: "paymentMethod:setDefault")

  • adminPriceParameters:read (value: "adminPriceParameters:read")

  • adminPriceParameters:write (value: "adminPriceParameters:write")

  • refund:read (value: "refund:read")

  • token:refresh (value: "token:refresh")

  • auth:twoFactor (value: "auth:twoFactor")

  • user:activate (value: "user:activate")

  • userData:update (value: "userData:update")

  • user:delete (value: "user:delete")

  • user:deleteSelf (value: "user:deleteSelf")

  • userEmail:verify (value: "userEmail:verify")

  • userEmoji:list (value: "userEmoji:list")

  • userInterest:delete (value: "userInterest:delete")

  • userInterest:read (value: "userInterest:read")

  • userInterest:write (value: "userInterest:write")

  • user:list (value: "user:list")

  • userPubkeys:list (value: "userPubkeys:list")

  • userPubkeys:write (value: "userPubkeys:write")

  • user:show (value: "user:show")

  • user:write (value: "user:write")

  • user:writeSelf (value: "user:writeSelf")

CurrentUser

Properties

NameTypeDescriptionNotes
features[CurrentUserFeatures]Enabled features for the user
global_scopesStringA list of fine-grained permissions the user may perform.
organization_roles{String: String}The role this user has in each organisation. Organisations are currently not used, but are reserved for future operations.
organization_scopes{String: String}The scopes that are granted to this user for each organisation. Organisations are currently not used, but are reserved for future operations.
pending_transfersStringList of transfers pending acceptance on current user side
pubkeysStringA list of this user's public keys. When yats are deployed to the blockchain, users prove ownership of their Yats with digital signatures, proving knowledge of the private keys that \"own\" the yat. In the centralised implementation of Yat, the server will custody the users' wallets and private keys, but in other respects the ownership model is the same.
roleStringThe role assigned to this user. Roles grant authority to user accounts to perform certain actions.
userCurrentUserUser
everflow_transaction_idStringtransaction id indicating if the user signed up from a partner via everflow redirectoptional

Enum: GlobalScopesEnum

  • adminCart:update (value: "adminCart:update")

  • adminEmoji:destroy (value: "adminEmoji:destroy")

  • adminEmoji:load (value: "adminEmoji:load")

  • adminEmoji:register (value: "adminEmoji:register")

  • adminEmoji:transfer (value: "adminEmoji:transfer")

  • adminEmoji:updateFeatures (value: "adminEmoji:updateFeatures")

  • adminEmoji:updateSecureData (value: "adminEmoji:updateSecureData")

  • adminEmoji:write (value: "adminEmoji:write")

  • adminFeatureUser:read (value: "adminFeatureUser:read")

  • adminInvites:write (value: "adminInvites:write")

  • adminInvites:list (value: "adminInvites:list")

  • adminLootbox:read (value: "adminLootbox:read")

  • adminLootbox:write (value: "adminLootbox:write")

  • adminNotifications:write (value: "adminNotifications:write")

  • adminUser:bypass2fa (value: "adminUser:bypass2fa")

  • adminUser:load (value: "adminUser:load")

  • adminUser:loginAs (value: "adminUser:loginAs")

  • adminUser:twoFactorAuthDestroy (value: "adminUser:twoFactorAuthDestroy")

  • adminUser:roleUpdate (value: "adminUser:roleUpdate")

  • cart:show (value: "cart:show")

  • cart:update (value: "cart:update")

  • code:delete (value: "code:delete")

  • code:read (value: "code:read")

  • code:write (value: "code:write")

  • user:createApiKey (value: "user:createApiKey")

  • domainAction:read (value: "domainAction:read")

  • domainEvent:read (value: "domainEvent:read")

  • edition:delete (value: "edition:delete")

  • edition:read (value: "edition:read")

  • edition:write (value: "edition:write")

  • emojiGroups:delete (value: "emojiGroups:delete")

  • emojiGroups:read (value: "emojiGroups:read")

  • emojiGroups:write (value: "emojiGroups:write")

  • emoji::transfer (value: "emoji::transfer")

  • feature::delete (value: "feature::delete")

  • feature::read (value: "feature::read")

  • feature::write (value: "feature::write")

  • lootbox:use (value: "lootbox:use")

  • order:paymentOverride (value: "order:paymentOverride")

  • order:read (value: "order:read")

  • order:readSelf (value: "order:readSelf")

  • order:refund (value: "order:refund")

  • order:refundOverride (value: "order:refundOverride")

  • order:resendConfirmation (value: "order:resendConfirmation")

  • organization:admin (value: "organization:admin")

  • organizationCode:admin (value: "organizationCode:admin")

  • organizationEmoji:list (value: "organizationEmoji:list")

  • organizationEmoji:write (value: "organizationEmoji:write")

  • organizationList:read (value: "organizationList:read")

  • organization:read (value: "organization:read")

  • organizationUser:admin (value: "organizationUser:admin")

  • organizationUser:read (value: "organizationUser:read")

  • organization:write (value: "organization:write")

  • nftSignature:write (value: "nftSignature:write")

  • nftToken:destroy (value: "nftToken:destroy")

  • nftTransfer:read (value: "nftTransfer:read")

  • paymentMethod:destroy (value: "paymentMethod:destroy")

  • paymentMethod:read (value: "paymentMethod:read")

  • paymentMethod:setDefault (value: "paymentMethod:setDefault")

  • adminPriceParameters:read (value: "adminPriceParameters:read")

  • adminPriceParameters:write (value: "adminPriceParameters:write")

  • refund:read (value: "refund:read")

  • token:refresh (value: "token:refresh")

  • auth:twoFactor (value: "auth:twoFactor")

  • user:activate (value: "user:activate")

  • userData:update (value: "userData:update")

  • user:delete (value: "user:delete")

  • user:deleteSelf (value: "user:deleteSelf")

  • userEmail:verify (value: "userEmail:verify")

  • userEmoji:list (value: "userEmoji:list")

  • userInterest:delete (value: "userInterest:delete")

  • userInterest:read (value: "userInterest:read")

  • userInterest:write (value: "userInterest:write")

  • user:list (value: "user:list")

  • userPubkeys:list (value: "userPubkeys:list")

  • userPubkeys:write (value: "userPubkeys:write")

  • user:show (value: "user:show")

  • user:write (value: "user:write")

  • user:writeSelf (value: "user:writeSelf")

Enum: {String: String}

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: {String: String}

  • adminCart:update (value: "adminCart:update")

  • adminEmoji:destroy (value: "adminEmoji:destroy")

  • adminEmoji:load (value: "adminEmoji:load")

  • adminEmoji:register (value: "adminEmoji:register")

  • adminEmoji:transfer (value: "adminEmoji:transfer")

  • adminEmoji:updateFeatures (value: "adminEmoji:updateFeatures")

  • adminEmoji:updateSecureData (value: "adminEmoji:updateSecureData")

  • adminEmoji:write (value: "adminEmoji:write")

  • adminFeatureUser:read (value: "adminFeatureUser:read")

  • adminInvites:write (value: "adminInvites:write")

  • adminInvites:list (value: "adminInvites:list")

  • adminLootbox:read (value: "adminLootbox:read")

  • adminLootbox:write (value: "adminLootbox:write")

  • adminNotifications:write (value: "adminNotifications:write")

  • adminUser:bypass2fa (value: "adminUser:bypass2fa")

  • adminUser:load (value: "adminUser:load")

  • adminUser:loginAs (value: "adminUser:loginAs")

  • adminUser:twoFactorAuthDestroy (value: "adminUser:twoFactorAuthDestroy")

  • adminUser:roleUpdate (value: "adminUser:roleUpdate")

  • cart:show (value: "cart:show")

  • cart:update (value: "cart:update")

  • code:delete (value: "code:delete")

  • code:read (value: "code:read")

  • code:write (value: "code:write")

  • user:createApiKey (value: "user:createApiKey")

  • domainAction:read (value: "domainAction:read")

  • domainEvent:read (value: "domainEvent:read")

  • edition:delete (value: "edition:delete")

  • edition:read (value: "edition:read")

  • edition:write (value: "edition:write")

  • emojiGroups:delete (value: "emojiGroups:delete")

  • emojiGroups:read (value: "emojiGroups:read")

  • emojiGroups:write (value: "emojiGroups:write")

  • emoji::transfer (value: "emoji::transfer")

  • feature::delete (value: "feature::delete")

  • feature::read (value: "feature::read")

  • feature::write (value: "feature::write")

  • lootbox:use (value: "lootbox:use")

  • order:paymentOverride (value: "order:paymentOverride")

  • order:read (value: "order:read")

  • order:readSelf (value: "order:readSelf")

  • order:refund (value: "order:refund")

  • order:refundOverride (value: "order:refundOverride")

  • order:resendConfirmation (value: "order:resendConfirmation")

  • organization:admin (value: "organization:admin")

  • organizationCode:admin (value: "organizationCode:admin")

  • organizationEmoji:list (value: "organizationEmoji:list")

  • organizationEmoji:write (value: "organizationEmoji:write")

  • organizationList:read (value: "organizationList:read")

  • organization:read (value: "organization:read")

  • organizationUser:admin (value: "organizationUser:admin")

  • organizationUser:read (value: "organizationUser:read")

  • organization:write (value: "organization:write")

  • nftSignature:write (value: "nftSignature:write")

  • nftToken:destroy (value: "nftToken:destroy")

  • nftTransfer:read (value: "nftTransfer:read")

  • paymentMethod:destroy (value: "paymentMethod:destroy")

  • paymentMethod:read (value: "paymentMethod:read")

  • paymentMethod:setDefault (value: "paymentMethod:setDefault")

  • adminPriceParameters:read (value: "adminPriceParameters:read")

  • adminPriceParameters:write (value: "adminPriceParameters:write")

  • refund:read (value: "refund:read")

  • token:refresh (value: "token:refresh")

  • auth:twoFactor (value: "auth:twoFactor")

  • user:activate (value: "user:activate")

  • userData:update (value: "userData:update")

  • user:delete (value: "user:delete")

  • user:deleteSelf (value: "user:deleteSelf")

  • userEmail:verify (value: "userEmail:verify")

  • userEmoji:list (value: "userEmoji:list")

  • userInterest:delete (value: "userInterest:delete")

  • userInterest:read (value: "userInterest:read")

  • userInterest:write (value: "userInterest:write")

  • user:list (value: "user:list")

  • userPubkeys:list (value: "userPubkeys:list")

  • userPubkeys:write (value: "userPubkeys:write")

  • user:show (value: "user:show")

  • user:write (value: "user:write")

  • user:writeSelf (value: "user:writeSelf")

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

CurrentUserFeatures

Properties

NameTypeDescriptionNotes
codeString
idString

CurrentUserUser

Properties

NameTypeDescriptionNotes
created_atDate
free_limitNumber
idString
pubkeysString
remaining_free_emojiNumber
roleString
two_factor_should_promptBoolean
updated_atDate
alternate_idStringoptional
deactivated_atDateoptional
emailStringoptional
email_verified_atDateoptional
first_nameStringoptional
last_nameStringoptional
sourceStringoptional
two_factor_authStringoptional
two_factor_last_prompted_atDateoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: TwoFactorAuthEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

Disable2FABody

Properties

NameTypeDescriptionNotes
disable_allBooleanMake this method default
providerStringTwo factor authentication backendoptional

Enum: ProviderEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

DisplayApiKey

Properties

NameTypeDescriptionNotes
api_keyString
created_atDate
nameString
scopesString
expires_atDateoptional

Enum: ScopesEnum

  • adminCart:update (value: "adminCart:update")

  • adminEmoji:destroy (value: "adminEmoji:destroy")

  • adminEmoji:load (value: "adminEmoji:load")

  • adminEmoji:register (value: "adminEmoji:register")

  • adminEmoji:transfer (value: "adminEmoji:transfer")

  • adminEmoji:updateFeatures (value: "adminEmoji:updateFeatures")

  • adminEmoji:updateSecureData (value: "adminEmoji:updateSecureData")

  • adminEmoji:write (value: "adminEmoji:write")

  • adminFeatureUser:read (value: "adminFeatureUser:read")

  • adminInvites:write (value: "adminInvites:write")

  • adminInvites:list (value: "adminInvites:list")

  • adminLootbox:read (value: "adminLootbox:read")

  • adminLootbox:write (value: "adminLootbox:write")

  • adminNotifications:write (value: "adminNotifications:write")

  • adminUser:bypass2fa (value: "adminUser:bypass2fa")

  • adminUser:load (value: "adminUser:load")

  • adminUser:loginAs (value: "adminUser:loginAs")

  • adminUser:twoFactorAuthDestroy (value: "adminUser:twoFactorAuthDestroy")

  • adminUser:roleUpdate (value: "adminUser:roleUpdate")

  • cart:show (value: "cart:show")

  • cart:update (value: "cart:update")

  • code:delete (value: "code:delete")

  • code:read (value: "code:read")

  • code:write (value: "code:write")

  • user:createApiKey (value: "user:createApiKey")

  • domainAction:read (value: "domainAction:read")

  • domainEvent:read (value: "domainEvent:read")

  • edition:delete (value: "edition:delete")

  • edition:read (value: "edition:read")

  • edition:write (value: "edition:write")

  • emojiGroups:delete (value: "emojiGroups:delete")

  • emojiGroups:read (value: "emojiGroups:read")

  • emojiGroups:write (value: "emojiGroups:write")

  • emoji::transfer (value: "emoji::transfer")

  • feature::delete (value: "feature::delete")

  • feature::read (value: "feature::read")

  • feature::write (value: "feature::write")

  • lootbox:use (value: "lootbox:use")

  • order:paymentOverride (value: "order:paymentOverride")

  • order:read (value: "order:read")

  • order:readSelf (value: "order:readSelf")

  • order:refund (value: "order:refund")

  • order:refundOverride (value: "order:refundOverride")

  • order:resendConfirmation (value: "order:resendConfirmation")

  • organization:admin (value: "organization:admin")

  • organizationCode:admin (value: "organizationCode:admin")

  • organizationEmoji:list (value: "organizationEmoji:list")

  • organizationEmoji:write (value: "organizationEmoji:write")

  • organizationList:read (value: "organizationList:read")

  • organization:read (value: "organization:read")

  • organizationUser:admin (value: "organizationUser:admin")

  • organizationUser:read (value: "organizationUser:read")

  • organization:write (value: "organization:write")

  • nftSignature:write (value: "nftSignature:write")

  • nftToken:destroy (value: "nftToken:destroy")

  • nftTransfer:read (value: "nftTransfer:read")

  • paymentMethod:destroy (value: "paymentMethod:destroy")

  • paymentMethod:read (value: "paymentMethod:read")

  • paymentMethod:setDefault (value: "paymentMethod:setDefault")

  • adminPriceParameters:read (value: "adminPriceParameters:read")

  • adminPriceParameters:write (value: "adminPriceParameters:write")

  • refund:read (value: "refund:read")

  • token:refresh (value: "token:refresh")

  • auth:twoFactor (value: "auth:twoFactor")

  • user:activate (value: "user:activate")

  • userData:update (value: "userData:update")

  • user:delete (value: "user:delete")

  • user:deleteSelf (value: "user:deleteSelf")

  • userEmail:verify (value: "userEmail:verify")

  • userEmoji:list (value: "userEmoji:list")

  • userInterest:delete (value: "userInterest:delete")

  • userInterest:read (value: "userInterest:read")

  • userInterest:write (value: "userInterest:write")

  • user:list (value: "user:list")

  • userPubkeys:list (value: "userPubkeys:list")

  • userPubkeys:write (value: "userPubkeys:write")

  • user:show (value: "user:show")

  • user:write (value: "user:write")

  • user:writeSelf (value: "user:writeSelf")

DisplayFeature

Properties

NameTypeDescriptionNotes
codeString
idString

DisplayOrder

Properties

NameTypeDescriptionNotes
amount_overpaid_in_centsNumberAmount overpaid in cents
created_atDateA UTC timestamp for when this order was initially created.
eligible_for_refundBooleanWhether an order is eligible for a refund via an admin.
idStringThe unique identifier for this order
misc_refunded_total_in_centsNumberThe total of miscellaneous refund amounts retirned to the order.
order_items[DisplayOrderOrderItems]The list of individual line items making up this order.
order_numberStringThe order number is the last 8 characters of the order's ID for user display purposes.
refunded_total_in_centsNumberThe total of refund amounts for the order.
remaining_due_in_centsNumberRemaining due in cents to mark the cart as Paid
statusStringThe order of the status. Orders start in 'Draft' status, then move to 'PendingPayment' and finally, 'Paid', unless they are 'Cancelled'.
total_in_centsNumberThe sum of all the items in this order, plus fees, in USD cents.
updated_atDateA UTC timestamp for the last time any field in this order was modified.
userDisplayOrderUser
user_idStringThe identifier of the user placing this order
expires_atDateCheckout carts have a limited time before they expire. This prevents users from blocking inventory from being sold to other customers. The expiry time is configurable on the server and is typically 5 minutes.optional
organization_idStringThe organization id of the user, if applicable. This will generally be null, unless the purchase is coming via a referral programme.optional
paid_atDateA UTC timestamp for when payment for this order was received. Will be null if no payment has been made yet.optional
payment_method_dataDisplayOrderPaymentMethodDataoptional
seconds_until_expiryNumberA convenience field indicating how long before `expires_at` is reached.optional

Enum: StatusEnum

  • Cancelled (value: "Cancelled")

  • Draft (value: "Draft")

  • Paid (value: "Paid")

  • PendingPayment (value: "PendingPayment")

DisplayOrderOrderItems

Properties

NameTypeDescriptionNotes
client_fee_in_centsNumberThe fee attributable to the referral partner, in addition to the nominal unit price, in USD cents.
company_fee_in_centsNumberThe fee attributable to the service host or company, in addition to the nominal unit price, in USD cents.
created_atDateA UTC timestamp for when this order item was created.
idStringA unique identifier for this order item
item_typeStringThe type of order. Current enumerations are EmojiId and Discount
order_idStringThe id of the order this order item
quantityNumberThe number of items in the line order. For emoji id sales, this should always be one.
refunded_quantityNumberThe number of items refunded. For emoji id sales, this should always at most be one.
unit_price_in_centsNumberThe nominal, non-discounted price of the item, in USD cents.
updated_atDateA UTC timestamp for when any field in the order item was modified.
code_idStringThe code associated with this order item for providing a discount.optional
emoji_idObjectThe emoji id that is being purchasedoptional
main_idStringMain item IDoptional
main_tableObjectMain item tableoptional
marked_invalid_atDateA UTC timestamp for when this order item was marked as invalid.optional
marked_invalid_at_reasonStringMarked invalid at reason Taken / PendingPurchaseoptional
parent_idStringParent order item's ID, set for discounts and feesoptional
rhythm_scoreNumberThe rhythm score belonging to this order item, only set for order items containing EmojiIds.optional

Enum: ItemTypeEnum

  • Discount (value: "Discount")

  • LootBox (value: "LootBox")

  • EmojiId (value: "EmojiId")

Enum: MarkedInvalidAtReasonEnum

  • Taken (value: "Taken")

  • PendingPurchase (value: "PendingPurchase")

DisplayOrderPaymentMethodData

Properties

NameTypeDescriptionNotes
client_secretStringClient Secret for the `Stripe` method for Elements and Checkout
methodStringPayment method
methods[DisplayOrderPaymentMethodDataMethods]Metadata for `CoinbaseCommerce` payment method
payment_intent_idStringPayment method ID for `Stripe` method
cancel_urlStringCancel url for `Stripe` method when using Checkoutoptional
invoice_idStringInvoice ID for the `Stripe` method for Elementsoptional
session_idStringInvoice ID for the `Stripe` method for Checkoutoptional
success_urlStringSuccess url for `Stripe` method when using Checkoutoptional

Enum: MethodEnum

  • CoinbaseCommerce (value: "CoinbaseCommerce")

  • Stripe (value: "Stripe")

DisplayOrderPaymentMethodDataMethods

Properties

NameTypeDescriptionNotes
addressString
amountNumber
currencyString
titleString

DisplayOrderUser

Properties

NameTypeDescriptionNotes
created_atDate
free_limitNumber
idString
pubkeysString
remaining_free_emojiNumber
roleString
two_factor_should_promptBoolean
updated_atDate
alternate_idStringoptional
deactivated_atDateoptional
emailStringoptional
email_verified_atDateoptional
first_nameStringoptional
last_nameStringoptional
sourceStringoptional
two_factor_authStringoptional
two_factor_last_prompted_atDateoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: TwoFactorAuthEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

DisplayTransferRequest

Properties

NameTypeDescriptionNotes
clear_on_transferBoolean
created_atDate
eidString
emailString
idString
recipient_idString
accepted_atDateoptional
deleted_atDateoptional
messageStringoptional
sender_code_accepted_atDateoptional

DisplayUser

Properties

NameTypeDescriptionNotes
created_atDate
free_limitNumber
idString
pubkeysString
remaining_free_emojiNumber
roleString
two_factor_should_promptBoolean
updated_atDate
alternate_idStringoptional
deactivated_atDateoptional
emailStringoptional
email_verified_atDateoptional
first_nameStringoptional
last_nameStringoptional
sourceStringoptional
two_factor_authStringoptional
two_factor_last_prompted_atDateoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: TwoFactorAuthEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

DisplayUserExtended

Properties

NameTypeDescriptionNotes
emoji_idsString
alternate_idStringoptional
created_atDateoptional
deactivated_atDateoptional
emailStringoptional
email_verified_atDateoptional
first_nameStringoptional
free_limitNumberoptional
idStringoptional
last_nameStringoptional
pubkeysStringoptional
remaining_free_emojiNumberoptional
roleStringoptional
sourceStringoptional
two_factor_authStringoptional
two_factor_last_prompted_atDateoptional
two_factor_should_promptBooleanoptional
updated_atDateoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: TwoFactorAuthEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

EditRequest

Properties

NameTypeDescriptionNotes
deleteStringOptional: hashes of records to deleteoptional
insert[EditRequestInsert]Optional: list of records to addoptional
merkle_rootStringOptional: merkle root (use WASM to generate)optional
signatureStringOptional: signature (use WASM to generate)optional

EditRequestInsert

Properties

NameTypeDescriptionNotes
dataStringCategory data in text format
tagStringCategory ID as a hex number

EidResponse

Properties

NameTypeDescriptionNotes
statusBooleanResponse status. If true, the requested data will be in the result field, null otherwise
errorEidResponseErroroptional
result[EidResponseResult]Records associated with EmojiIDoptional

EidResponseError

Properties

NameTypeDescriptionNotes
codeStringError code
reasonString

EidResponseResult

Properties

NameTypeDescriptionNotes
dataStringCategory data in text or hex encoded formats
hashStringHash identifies record, can be used to delete records
tagStringCategory as a hex string number

EmojiListItem

Properties

NameTypeDescriptionNotes
canonical_formatString
chain_formatString
display_formatString
flippable_emojiBoolean
generationNumber
mintedBoolean
rhythm_scoreNumber
shapeEmojiListItemShape
shortnameString
blocked_untilDateoptional
token_idNumberoptional

EmojiListItemShape

Properties

NameTypeDescriptionNotes
patternObjectoptional
shapeStringoptional

Enum: ShapeEnum

  • Repeaters (value: "Repeaters")

  • Eye Heart (value: "Eye Heart")

  • Bookends (value: "Bookends")

  • Adoptables (value: "Adoptables")

EmojiStatsResponse

Properties

NameTypeDescriptionNotes
emoji_idString
metrics[EmojiStatsResponseMetrics]

EmojiStatsResponseMetrics

Properties

NameTypeDescriptionNotes
descriptionString
finish_dateDate
keyStringCounter object
metricStringCounter type
start_dateDate
valueNumberCounter value

Enable2FABody

Properties

NameTypeDescriptionNotes
defaultBooleanMake this method default
providerStringTwo factor authentication backend
phoneStringPhone number required for `SMS` provideroptional

Enum: ProviderEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

Enable2FAResponse

Properties

NameTypeDescriptionNotes
backup_codesStringOne time backup codes to loginoptional
ga_qr_code_svgStringGA secret as QR code in svg imageoptional
ga_secretStringGA base32 encoded secret, will be null when code is disabledoptional
phone_last_digitsStringPhone last digitsoptional

ListOfCodeAvailability

Properties

NameTypeDescriptionNotes
data[ListOfCodeAvailabilityData]optional
pagingListOfCodeAvailabilityPagingoptional

ListOfCodeAvailabilityData

Properties

NameTypeDescriptionNotes
total_usesNumber
activatorStringoptional
availableNumberoptional
code_typeStringoptional
created_atDateoptional
deleted_atDateoptional
discount_as_percentageNumberoptional
discount_in_centsNumberoptional
end_dateDateoptional
idStringoptional
max_emojis_per_userNumberoptional
max_usesNumberoptional
nameStringoptional
organization_idStringoptional
patternObjectoptional
redemption_codeStringoptional
start_dateDateoptional
updated_atDateoptional

Enum: ActivatorEnum

  • RedemptionCode (value: "RedemptionCode")

  • SecretKey (value: "SecretKey")

Enum: CodeTypeEnum

  • Discount (value: "Discount")

  • RandomYat (value: "RandomYat")

ListOfCodeAvailabilityPaging

Properties

NameTypeDescriptionNotes
dirString
limitNumber
pageNumber
sortString
tags{String: Object}
totalNumber

Enum: DirEnum

  • Asc (value: "Asc")

  • Desc (value: "Desc")

ListOfDisplayTransferRequest

Properties

NameTypeDescriptionNotes
data[ListOfDisplayTransferRequestData]optional
pagingListOfCodeAvailabilityPagingoptional

ListOfDisplayTransferRequestData

Properties

NameTypeDescriptionNotes
clear_on_transferBoolean
created_atDate
eidString
emailString
idString
recipient_idString
accepted_atDateoptional
deleted_atDateoptional
messageStringoptional
sender_code_accepted_atDateoptional

ListOfDisplayUserExtended

Properties

NameTypeDescriptionNotes
data[ListOfDisplayUserExtendedData]optional
pagingListOfCodeAvailabilityPagingoptional

ListOfDisplayUserExtendedData

Properties

NameTypeDescriptionNotes
emoji_idsString
alternate_idStringoptional
created_atDateoptional
deactivated_atDateoptional
emailStringoptional
email_verified_atDateoptional
first_nameStringoptional
free_limitNumberoptional
idStringoptional
last_nameStringoptional
pubkeysStringoptional
remaining_free_emojiNumberoptional
roleStringoptional
sourceStringoptional
two_factor_authStringoptional
two_factor_last_prompted_atDateoptional
two_factor_should_promptBooleanoptional
updated_atDateoptional

Enum: RoleEnum

  • Admin (value: "Admin")

  • OrgController (value: "OrgController")

  • OrgMember (value: "OrgMember")

  • OrgOwner (value: "OrgOwner")

  • Bot (value: "Bot")

  • Super (value: "Super")

  • User (value: "User")

Enum: TwoFactorAuthEnum

  • GoogleAuthenticator (value: "GoogleAuthenticator")

  • SMS (value: "SMS")

ListOfPublicLootBox

Properties

NameTypeDescriptionNotes
data[ListOfPublicLootBoxData]optional
pagingListOfCodeAvailabilityPagingoptional

ListOfPublicLootBoxData

Properties

NameTypeDescriptionNotes
average_rhythm_scoreNumberAverage score of emoji IDs in loot box
created_atDate
idString
pricesNumberThe prices of the yats in the box, in cents
scoresNumberThe rhythm scores of the yats in the box
statusStringStatus loot box will be created in
total_valueNumberTotal value of EmojiIDs in the Loot Box
yatsStringLoot box yats
lootbox_typeListOfPublicLootBoxLootboxTypeoptional
lootbox_type_idStringFor Admin: The type of loot box, if applicableoptional
ownerListOfPublicLootBoxOwneroptional
owner_idStringLoot box owner_id, required for Owned and Used loot boxesoptional

Enum: StatusEnum

  • Draft (value: "Draft")

  • Available (value: "Available")

  • Owned (value: "Owned")

  • Used (value: "Used")

ListOfPublicLootBoxLootboxType

Properties

NameTypeDescriptionNotes
configListOfPublicLootBoxLootboxTypeConfig
created_atDateThe timestamp for when this loot box type was created
descriptionStringA more detailed description of the loot box type
idStringThe loot box type id
nameStringThe name of this loot box type

ListOfPublicLootBoxLootboxTypeConfig

Properties

NameTypeDescriptionNotes
guarantees[AdminNewLootBoxTypeConfigGuarantees]A set of guaranteed drops in this loot box type
max_base_scoreNumberThe upper bound (inclusive) rhythm score for standard yats in the loot box
max_lengthNumberMaximum yat length
min_base_scoreNumberThe lower bound (inclusive) rhythm score for standard yats in the loot box
min_lengthNumberMinimum yat length
sizeNumberThe number of yats in the loot box
weights[AdminNewLootBoxTypeConfigWeights]A set of probability weightings for chance-based drops

ListOfPublicLootBoxOwner

Properties

NameTypeDescriptionNotes
created_atDate
free_limitNumber
idString
pubkeysString
remaining_free_emojiNumber

**rol

0.2.248

3 years ago

0.2.115

3 years ago