Skip to main content

Swift API client for YatLib

caution

The SDK code and documetnation 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.

Installation#

CocoaPods#

Add pod 'YatLib' to your project's Podfile

Run pod install

Documentation for API Endpoints#

ClassMethodHTTP requestDescription
ApiKeysAPIcreateApiKeyPOST /api_keysCreate new api key for current user
ApiKeysAPIdeleteApiKeyDELETE /api_keys/{id}Delete provided api key
ApiKeysAPIlistApiKeysGET /api_keysLoad api keys for user
CartAPIaddItemsPOST /cartUpdate cart items by adding new items to the cart
CartAPIapplyPromoCodePOST /cart/promo_codeApply promo code
CartAPIcheckoutPOST /cart/checkoutCheckout last payment cart
CartAPIcheckoutOrderPOST /cart/checkout/{id}Checkout saved cart by id
CartAPIclearCartDELETE /cartRemove all items from cart
CartAPIconvertOrderToDraftPOST /cart/convert_to_draftConvert pending payment cart back into Draft status
CartAPIdeletePaymentMethodsDELETE /payment_methods/{id}Delete payment method
CartAPIgetItemsGET /cartReturn cart content
CartAPIlistPaymentMethodsGET /payment_methodsFetch payment methods for the user
CartAPIremoveItemDELETE /cart/cart_items/{cart_item_id}Removes an order item from the cart
DiscountsAPIactivateRandomYatCodePOST /codes/{code_id}/random_yatUse random yat code
DiscountsAPIaddPubkeyForCodePOST /codes/{code_id}/pubkeys/{pubkey}Add pubkey for code
DiscountsAPIlistCodesGET /codesFetch codes
DiscountsAPIrevokePubkeyForCodeDELETE /codes/{code_id}/pubkeys/{pubkey}Revoke pubkey for code
EmojiAPIemojiListGET /emojiList of supported emoji characters
EmojiIDAPIeditEmojiIDPATCH /emoji_id/{emoji_id}Edit EmojiId
EmojiIDAPIemojiIDMetadataGET /emoji_id/{emoji_id}/metadata
EmojiIDAPIgenerateSignaturePOST /emoji_id/{emoji_id}/generate_signatureGenerates a signature for the Yat allowing it to be minted
EmojiIDAPIgetStatsGET /emoji_id/{eid}/statsGet statistics for EmojiId
EmojiIDAPIlinkRedirectGET /redirectRedirect by EmojiId link
EmojiIDAPIlistEmojiIDsGET /emoji_idList user's Emoji Ids
EmojiIDAPIlistExtendedGET /emoji_id/extendedList extended view user's Emoji Ids
EmojiIDAPIloadJsonGET /emoji_id/{eid}/json/{key}Load value from EmojiId key value store
EmojiIDAPIloadJsonIndexGET /emoji_id/{eid}/jsonLoad value from EmojiId key value store with data keyed by YatJsonStoreKeys
EmojiIDAPIlookupEmojiIDGET /emoji_id/{emoji_id}Lookup EmojiId
EmojiIDAPIlookupEmojiIDPaymentGET /emoji_id/{emoji_id}/paymentLookup EmojiId Payment addresses
EmojiIDAPIlookupEmojiIdTickerGET /emoji_id/{emoji_id}/{tag}Lookup EmojiId data based on a symbol or ticker
EmojiIDAPImetadataGET /nft_transfers/metadata/{token_id}
EmojiIDAPIrandomGET /emoji_id/randomReturn random Emoji
EmojiIDAPIrecentGET /emoji_id/recentReturn list of recently purchased emoji
EmojiIDAPIrhythmGET /emoji_id/{emoji_id}/rhythmCalculate EmojiId rhythm score
EmojiIDAPIsearchEmojiIDGET /emoji_id/searchSearch for EmojiID
EmojiIDAPIstoreJsonPOST /emoji_id/{eid}/json/{key}Store value under EmojiId key
KeyManagementAPIaddPubkeyPOST /pubkeys/{pubkey}Add pubkey for current user
KeyManagementAPIaddPubkeyForUserPOST /users/{user_id}/pubkeys/{pubkey}Add pubkey for user by user_id
KeyManagementAPIcreateWalletPOST /pubkeysGenerate custodial wallet
KeyManagementAPIgetPubkeysGET /pubkeysRetrieve pubkeys
KeyManagementAPIgetPubkeysForUserGET /users/{user_id}/pubkeysRetrieve pubkeys by user_id
LootBoxTypeAPIcreateTypePOST /lootbox_typeCreate a new lootbox category
LootBoxTypeAPIgenerateLootBoxesPOST /lootbox_type/generateGenerates a set of loot boxes
LootBoxTypeAPIgetTypesGET /lootbox_typeList all loot box categories
LootBoxesAPIcreateLootboxPOST /lootboxesCreate a new lootbox
LootBoxesAPIdeleteLootboxDELETE /lootboxes/{id}Delete a lootbox
LootBoxesAPIlistLootboxesGET /lootboxesFetch lootboxes
LootBoxesAPIopenLootboxPOST /lootboxes/{id}/openOpen lootbox
LootBoxesAPIshowLootboxGET /lootboxes/{id}Show information about lootbox
LootBoxesAPIupdateLootboxPATCH /lootboxes/{id}Update a lootbox
OrganizationAPIgetBrandingGET /organizations/{id}/brandingLoad organization branding paramters
OrganizationAPIsetBrandingPUT /organizations/{id}/brandingSet organization branding parameters
ProxyAPIcallProxyPOST /proxyCalls a pre-defined proxy service with the provided data
TransferAPIdeleteTransferDELETE /transfers/{transfer_id}Mark transfer request as deleted
TransferAPIlistFilteredGET /transfersList outgoing transfer requests for current or specified user If limit is omitted will display top 50 transfer requests
TransferAPIlistIncomingGET /transfers/incomingList transfer requests assigned to user
TransferAPIreceiverAcceptTransferPOST /transfers/{transfer_id}/receiver_acceptAs a receiver, accept transfer request by id.
TransferAPIrequestTransferPOST /transfersTransfer eid to either the pubkey or email address supplied in the PUT data
TransferAPIresendCodePOST /transfers/{transfer_id}/resend_codeResend a new transfer OTP code for the current user, if the transfer allows it.
TransferAPIsenderAcceptTransferPOST /transfers/{transfer_id}/sender_acceptAs a sender, confirm the transfer request by transfer id.
UserAuthenticationAPIloginPOST /auth/tokenLogin via password
UserAuthenticationAPIlogoutPOST /logoutInvalidates all user's access tokens
UserAuthenticationAPImagicLinkLoginPOST /auth/magic_linkGenerate magic link for login
UserAuthenticationAPIrefreshTokenPOST /auth/token/refreshRefresh access token
UserAuthenticationAPItwoFactorAuthenticationPOST /auth/2faTwo factor authentication
UserFeatureAPIreadFeaturesGET /user_featuresList users features
UserInterestAPIdeleteUserInterestDELETE /user_interests/{emoji_id}Destroys the user interest preventing this Emoji ID's notification emails from being sent for this user
UserInterestAPIgetInterestedUsersGET /user_interestsReturns a paginated list of user interest records associated with the user
UserInterestAPIgetUserInterestForYatGET /user_interests/{emoji_id}Given an EmojiId returns information about the user interest if a record exists for this user
UserInterestAPIregisterInterestPOST /user_interestsCreate new interest in emoji to be notified when available
UsersAPIbackupDisable2FAPOST /account/2fa/backup_disableDisable choosen 2FA provider or disable completely using backup code and user primary ID
UsersAPIconfirm2FAPOST /account/2fa/confirmConfirm two factor authentication update
UsersAPIcreateUserPOST /usersRegister a User
UsersAPIdeleteUserDELETE /users/{id}Delete a user
UsersAPIdisable2FAPOST /account/2fa/disableDisable choosen 2FA provider or disable completely
UsersAPIenable2FAPOST /account/2fa/enableEnables two factor authentication method
UsersAPIgetAccountGET /accountCurrent user account
UsersAPIgetAllUsersGET /usersList users
UsersAPIloadGET /account/loadLoad user data for a session
UsersAPIsend2FASmsPOST /account/2fa/sms_codeSend SMS 2FA code
UsersAPIshowUserGET /users/{id}Show users
UsersAPIupdateAccountPATCH /accountUpdate the currently logged in user
UsersAPIupdateUserByAdminPATCH /users/{id}Update a user as an admin
WalletsAPIlistWalletsGET /walletsFetch associated wallet addresses for the user
WalletsAPIsyncWalletPOST /walletsAssociate new wallet address with user

Documentation For Models#

Documentation For Authorization#

JWT#

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header

apiKey#

  • Type: API key
  • API key parameter name: Authorization,X-Api-Key
  • Location: HTTP header

two_factor#

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header

Author#