Skip to main content

EluvioLive

EluvioLive is an application platform built on top of the Eluvio Content Fabric. It provides a consumer-facing marketplace for digital content: live performances, digital collectibles, etc.

This SDK provides tools for working with EluvioLive APIs and services.

Constructor​

new EluvioLive({
  configUrl,
  mainObjectId
}) → EluvioLive

Instantiate the EluvioLive SDK

Returns: New EluvioLive object connected to the specified content fabric and blockchain

Parameters

NameTypeRequiredDescription
configUrlstring✓

The Content Fabric configuration URL

mainObjectIdstring✓

The top-level Eluvio Live object ID

AccountShow​

AccountShow()

Show info about this account.

AddMinter​

AddMinter({
  addr,
  mintAddr
})

Add a minter to NFT or ElvToken

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT/ElvToken contract address

mintAddrstring✓

The address of the minter (key or helper contract)

AdminHealth​

AdminHealth({ host }) → Promise.<Object>

Get Admin API status from Authority Service

Returns: The API Response for the adm/health api

Parameters

NameTypeRequiredDescription
hoststring✓

Authority Service url (Optional)

ASNFTRedeemOffer​

ASNFTRedeemOffer({
  addr,
  offerId
})

Redeem an nft offer using the Authority Service

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

offerIdstring✓

The Offer ID

AsNftTransfer​

AsNftTransfer({
  addr,
  tokenId
}) → Promise.<Object>

Transfer the specified NFT token as the owner using Authority Service

Returns: NFT info JSON

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

CheckIsOwner​

CheckIsOwner({
  addr,
  tokenId
})

Checks if the current signer address owns the NFT token. Throws error if not owner.

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

ContentClearPolicy​

ContentClearPolicy({ objectId })

Get the content object policy from the Object metadata and the delegate from the Object's contract meta

Parameters

NameTypeRequiredDescription
objectIdstring✓

The NFT object ID

ContentGetPolicy​

ContentGetPolicy({ objectId })

Get the content object policy from the Object metadata and the delegate from the Object's contract meta

Parameters

NameTypeRequiredDescription
objectIdstring✓

The NFT object ID

ContentSetPolicy​

ContentSetPolicy({
  objectId,
  policyPath,
  data
})

Sets the content object policy

Parameters

NameTypeRequiredDescription
objectIdstring✓

The NFT object ID

policyPathstring✓

Path to the content policy file (eg. policy.yaml).

datastring✓

Metadata path within the policy object to link to

ContentSetPolicyDelegate​

ContentSetPolicyDelegate({
  objectId,
  delegateId
})

Sets the content object policy

Parameters

NameTypeRequiredDescription
objectIdstring✓

The NFT object ID

delegateIdstring✓

Path to the content policy file (eg. policy.yaml).

CreateNftContract​

CreateNftContract({
  tenantId,
  minterAddr,
  mintHelperAddr,
  collectionName,
  collectionSymbol,
  contractUri,
  proxyAddress,
  totalSupply,
  hold
}) → Promise.<Object>

Create a new NFT contract (ElvTradable, ERC-721-based) and set it up for this tenant

  • create a new contract
  • add minter
  • add NFT address to tenant 'tenant_nfts' group

TODO: preflight - ensure signer is a tenant admin

Returns: New contract address

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The tenant ID

minterAddrstring✓

Address of the minter (hex format) (Optional, Default uses tenant minter config)

mintHelperAddrstring✓

Address of the mint helper (hex format) (Optional, Default uses tenant minter config)

collectionNamestring✓

Short name for the ERC-721 contract

collectionSymbolstring✓

Short string for the ERC-721 contract

contractUristring✓

URI for the ERC-721 contract

proxyAddressstring✓

Proxy address for the ERC721 contract (Optional, Default uses tenant minter config)

totalSupplynumber✓

the mint cap for this template (should be called 'cap')

holdnumber✓

the hold period (seconds)

CreateNftTransferProxy​

CreateNftTransferProxy({}) → Promise.<Object>

Create a new NFT TransferProxy contract

Returns: New contract address

CreateWalletAccount​

CreateWalletAccount({
  email,
  tenant,
  callbackUrl,
  onlyCreateAccount,
  onlySendEmail,
  scheduleAt
}) → Promise.<Object>

create account for tenant

Returns: The API Response containing created account info

Parameters

NameTypeRequiredDescription
emailstring✓

The email to create, or @filename to read a list of emails from file

tenantstring✓

The Tenant ID

callbackUrlstring✓

The base URL info for the link in the email

onlyCreateAccountboolean✓

only create the account

onlySendEmailboolean✓

only send email, do not create the account

scheduleAtstring✓

when to schedule the email

Domains​

Domains() → Promise.<Object>

Get the list of domains from the Main Live Object info/domains_map

Returns: List of domain objects

FabricTenantBalanceOf​

FabricTenantBalanceOf({
  objectId,
  ownerAddr
}) → Promise.<Object>

Get a list of the NFTs of this tenant owned by 'ownerAddr'

Returns: Number of tokens owned

Parameters

NameTypeRequiredDescription
objectIdstring✓

The ID of the tenant specific EluvioLive object

ownerAddrstring✓

A user address to check the balance of

IsMinter​

IsMinter({
  addr,
  mintAddr
})

check if minter to NFT or ElvToken

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT/ElvToken contract address

mintAddrstring✓

The address of the minter (key or helper contract)

List​

List({
  tenantId,
  tenantSlug
}) → Promise.<Object>

Get the list of Tenant marketplaces/sites from the Main Live Object No Tenant ID or Tenant Slug will return all tenants.

Returns: List or single Tenant Info

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The Tenant ID (Optional).

tenantSlugstring✓

The Tenant ID (Optional). No Tenant ID will return all tenants.

NFTAddRedeemableOffer​

NFTAddRedeemableOffer({ addr })

Add a redeemable offer to the NFT contract

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

NftBalanceOf​

NftBalanceOf({
  addr,
  ownerAddr
}) → Promise.<Object>

Get the NFT balance for a given user address

Returns: Number of tokens owned

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

ownerAddrstring✓

A user address to check the balance of

NftBuild​

NftBuild({
  library,
  hash,
  nftDir
}) → Promise.<Object>

Set the public/nft section based on asset metadata

For generative NFTs we use the following convention - nftDir must contain: One or more json files with a '.json' extension (for example: nft001.json, nft002.json) Example JSON File:

{ "count":3, (OPTIONAL, Default: 1) "name": "Example NFT", (OPTIONAL, Default: from Content Object) "display_name": "Example NFT", (OPTIONAL, Default: from Content Object) "description" : "This is an example NFT.", (OPTIONAL, Default: from Content Object) "rich_text" : "", (OPTIONAL, Default: from Content Object) "image": "https://image003", "embed_url":"https://videoURL003", "attributes:": [ { "trait_type":"trait01", "value": "test1", "rarity": 0.2 (OPTIONAL, If not present, it will be calculated) } ] }

The 'count' is an optional parameter to generate copies of this nft element inside the /public/nfts array

All other optional keys (name, display_name, description, etc) will override the NFT content object's value from /asset_metadata/nft if present.

The required key 'attributes' is an array of objects {"trait_type": "", "value": ""} and is used to calculate trait rarity. If rarity is already present in the attribute, it will be used instead.

Returns: The public/nft or public/nfts JSON

Parameters

NameTypeRequiredDescription
librarystring✓

ID

hashstring✓

The NFT Template hash or id

nftDirstring✓

Directory containing nft json file(s) for building nfts

NftBurn​

NftBurn({
  addr,
  tokenId
}) → Promise.<Object>

Burn the specified NFT token as the owner

Returns: NFT info JSON

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

NftGetPolicyAndPermissions​

NftGetPolicyAndPermissions({ nftAddress }) → object

Gets the nft policy and permissions for a given contract

Returns: object containing the policy string and the list of addresses from nft metadata

Parameters

NameTypeRequiredDescription
nftAddressstring✓

The NFT contract address. Can also be iqXXX format.

NftGetTransferFee​

NftGetTransferFee({ address }) → string

Gets the baseTransferFee of the NFT Contract

Returns: The fee as a big number sring

Parameters

NameTypeRequiredDescription
addressstring✓

The NFT contract address

NFTIsOfferActive​

NFTIsOfferActive({
  addr,
  offerId
})

Returns true if offer is active (has not been removed)

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

offerIdstring✓

The Offer ID

NFTIsOfferRedeemed​

NFTIsOfferRedeemed({
  addr,
  offerId
})

Returns true if offer is redeemed

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

offerIdstring✓

The Offer ID

NftLookup​

NftLookup({
  addr,
  tokenId
}) → Promise.<Object>

Set the public/nft section based on asset metadata

Returns: NFT info JSON

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

NftMake​

NftMake({ assetMetadata }) → Promise.<Object>

Make the public/nft section based on asset metadata Prerequisites:

  • NFT contract set

Returns: The public/nft JSON

Parameters

NameTypeRequiredDescription
assetMetadataObject✓

The NFT Template asset metadata

NftMakeGenerative​

NftMakeGenerative({
  assetMetadata,
  hash,
  imagePath,
  attrs,
  rarity
}) → Promise.<Object>

Make a single element of the public/nfts section of a generative, multi image/video token based on asset metadata and input parameters. The public/nfts key is an array of objects, each equivalent to the single NFT public/nft section.

Prerequisites:

  • NFT contract set

Returns: The public/nfts JSON array element

Parameters

NameTypeRequiredDescription
assetMetadataObject✓

The NFT Template asset metadata

hashstring✓

NFT Template hash

imagePathstring✓

Local file path to the image

attrsObject✓

Extra attributes for this token

rarityObject✓

Stats for each trait and value

NftPackGetDist​

NftPackGetDist({ versionHash }) → object

Pack - retrieve pack spec and pack distribtion from an NFT Template using authd tenant-authenticated pack APIs. The spec and distribition are saved in JSON files.

Returns: file names where spec and dist are saved

Parameters

NameTypeRequiredDescription
versionHashstring✓

NFT Template object hash

NftPackSetDist​

NftPackSetDist({ versionHash }) → Promise.<Object>

Pack - set a previously created pack distribution in pack object metadata

Returns: The new object info

Parameters

NameTypeRequiredDescription
versionHashstring✓

NFT Template content hash

NftProxyBurn​

NftProxyBurn({
  addr,
  tokenId
}) → Promise.<Object>

Burn the specified NFT token as a proxy owner

Returns: NFT info JSON

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

NftProxyTransferFrom​

NftProxyTransferFrom({
  addr,
  fromAddr,
  toAddr,
  tokenId
}) → Promise.<Object>

Transfer an NFT as a proxy owner.

Returns: ?

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

fromAddrstring✓

The current owner of the token

toAddrstring✓

A user address to tranfer to

tokenIdinteger✓

The token ID

NFTRedeemOffer​

NFTRedeemOffer({
  addr,
  offerId
})

Redeem an nft offer using the contract directly

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

offerIdstring✓

The Offer ID

NFTRefresh​

NFTRefresh({
  tenant,
  maxNumber
}) → Promise.<Object>

Synchronize backend listings with fabric metadata for a specific tenant's NFT

Returns: The API Response containing list of Wallet Info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

maxNumberinteger✓

The address to mint to

NFTRemoveRedeemableOffer​

NFTRemoveRedeemableOffer({ addr })

Remove a redeemable offer from the NFT contract

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

NftSetPolicyAndPermissions​

NftSetPolicyAndPermissions({
  objectId,
  policyPath,
  addresses,
  clearAddresses // optional
})

Sets the nft policy and permissions for a given object throws error if something goes wrong.

Parameters

NameTypeRequiredDescription
objectIdstring✓

The NFT object ID

policyPathstring✓

Path to the policy file (eg. nft_owner_minter.yaml). Note that the policy must contain the minter address

addressesArray.<string>✓

Array of addresses to set the policy permissions

clearAddressesboolean

Clear existing permissions by writing an empty address list before applying the new ones

(default: false)

NftSetPolicyAndPermissionsBatch​

NftSetPolicyAndPermissionsBatch({
  objectIds,
  policyPath,
  addresses,
  clearAddresses // optional
}) → object

Batch version of NftSetPolicyAndPermissions.

Sets the same policy and permissions to a list of objects. Objects are processed in batches: within a batch all transactions are submitted sequentially (noce safety)

Returns: { succeeded: string[], failed: {objectId, error}[] }

Parameters

NameTypeRequiredDescription
objectIdsArray.<string>✓

The NFT object IDs (iq__... or hex address)

policyPathstring✓

Path to the policy file (eg. nft_owner_minter.yaml). Note that the policy must contain the minter address

addressesArray.<string>✓

Array of addresses to set the policy permissions

clearAddressesboolean

Clear existing permissions by writing an empty address list before applying the new ones

(default: false)

NftSetTransferFee​

NftSetTransferFee({
  address,
  fee
}) → Promise.<Object>

Sets the baseTransferFee of the NFT Contract

Returns: The Contract transaction logs

Parameters

NameTypeRequiredDescription
addressstring✓

The NFT contract address

feestring✓

Fee in ETH to set as a big number string

NftSetTransferProxy​

NftSetTransferProxy({
  addr,
  proxyAddress
}) → Promise.<Object>

Set a TransferProxy for this NFT contract. If no proxy address is specified, create a new one. Must be run as the NFT contract owner.

Returns: New contract address

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT Transfer Proxy contract address

proxyAddressstring✓

The address of the proxy contract (optional)

NftShow​

NftShow({
  addr,
  mintHelper,
  minter,
  proxyAddr,
  showOwners,
  showOwnersViaContract,
  includeEmail,
  tokenId
}) → Promise.<Object>

Show info about this NFT

Returns: An object containing NFT info, including 'warnings'

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

mintHelperstring✓

Warn if this is not a minter for the NFT contract (hex)

minterstring✓

Warn if this is not the owner of the mint helper contract (hex)

proxyAddrstring✓

proxy owner address

showOwnersinteger✓

Enumerate all token owners using a fast indexed query. Only used if tokenId is undefined.

showOwnersViaContractinteger✓

Enumerate all token info up to the given amount. Only used if tokenId is undefined.

includeEmailstring✓

Include email address for owners, as bound to the given tenant ID. Only used if tokenId is undefined.

tokenIdinteger✓

The token ID to show info for. This will take precedence over showOwners

NftShowToken​

NftShowToken({
  addr,
  tokenId
}) → Promise.<Object>

Show info on one token in the NFT contract

Returns: An object containing token info, including 'warnings'

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT contract address

tokenIdinteger✓

The token ID

NftTemplateAddNftContract​

NftTemplateAddNftContract({
  objectId,
  nftAddr,
  collectionName,
  collectionSymbol,
  hold,
  contractUri,
  totalSupply
}) → Promise.<Object>

Create a new NFT contract and set it in the NFT Template object's metadata.

Returns: An object containing info about the new NFT

Parameters

NameTypeRequiredDescription
objectIdstring✓

The ID of the NFT Template

nftAddrstring✓

The NFT contract address (optional; by default create one)

collectionNamestring✓

Short name for the ERC-721 contract

collectionSymbolstring✓

Short string for the ERC-721 contract

holdstring✓

Hold period in seconds

contractUristring✓

URI for the ERC-721 contract

totalSupplystring✓

the mint cap for this template (should be called 'cap')

NftTransfer​

NftTransfer({
  addr,
  tokenId
}) → Promise.<Object>

Transfer the specified NFT token as the owner through contract

Returns: NFT info JSON

Parameters

NameTypeRequiredDescription
addrstring✓

Local NFT contract address

tokenIdinteger✓

External NFT token ID

readNftDir​

readNftDir({ nftDir }) → Promise.<Object>

Read image and attributes info from a directory

Required format:

  • the directory should contain a list of '*.json' files (flat, not in a hierarchy) Returns an array of objects containing:
  • imgFile - file name (no path)
  • imgFilePath - full path to source file
  • attrs - attributes object (optional)

Returns: The 'images' object and calculated rarity

Parameters

NameTypeRequiredDescription
nftDirstring✓

the directory containing the nft json files

RenounceMinter​

RenounceMinter()

Renounce the minter(msg.sender) from NFT or ElvToken

ShowMintHelper​

ShowMintHelper({ addr }) → Promise.<Object>

Show NFT mint helper info

Returns: Mint helper info object

Parameters

NameTypeRequiredDescription
addrstring✓

The mint helper contract address

ShowNftTransferProxy​

ShowNftTransferProxy({ addr }) → Promise.<Object>

Show NFT Transfer Proxy info

Returns: Proxy info object

Parameters

NameTypeRequiredDescription
addrstring✓

The NFT Transfer Proxy contract address

SiteSetDrop​

SiteSetDrop({
  libraryId,
  objectId,
  uuid,
  start,
  end,
  endVote,
  startMint,
  newUuid,
  update
}) → Promise.<Object>

Set start dates for a drop event (all stages)

Returns: An object containing new drop info

Parameters

NameTypeRequiredDescription
libraryIdstring✓

The 'properties' library ID

objectIdstring✓

The ID of the site object

uuidstring✓

UUID of the drop (a site may contain multiple)

startstring✓

the start date of the event

endstring✓

the end date of the event (optional)

endVotestring✓

the start date of the post vote stage (optional)

startMintstring✓

the start date of the mint stage (optional)

newUuidboolean✓

create a new UUID for the drop (optional)

updatestring✓

Tenant-level EluvioLive object ID, to update

SiteShow​

SiteShow({
  libraryId,
  objectId
}) → Promise.<Object>

Show info about this site (event)

Returns: An object containing site info, including 'warnings'

Parameters

NameTypeRequiredDescription
libraryIdstring✓

The 'properties' library ID

objectIdstring✓

The ID of the site object

TenantAddNft​

TenantAddNft({
  tenantId,
  nftAddr
})

Add an NFT contract to the tenant's 'tenant_nfts' group

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

nftAddrstring✓

= The address of the NFT contract (hex format)

TenantBalanceOf​

TenantBalanceOf({
  tenantId,
  ownerAddr,
  maxNumber
}) → Promise.<Object>

Get a list of the NFTs of this tenant owned by 'ownerAddr'

Returns: Number of tokens owned

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

ownerAddrstring✓

A user address to check the balance of

maxNumberinteger✓

Max number of NFTs returned

TenantCreateMinterConfig​

TenantCreateMinterConfig({ tenant }) → Promise.<Object>

Create minter configuration using the authority service

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantDeleteMinterConfig​

TenantDeleteMinterConfig({ tenant }) → Promise.<Object>

Delete minter configuration using the authority service

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantDeployHelperContracts​

TenantDeployHelperContracts({ tenant }) → Promise.<Object>

Deploy minter helper contract using the authority service

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantGetMinterConfig​

TenantGetMinterConfig({ tenant }) → Promise.<Object>

Get minter configuration from authority service

Returns: The API Response for the tenant's minter configuration

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantGroupInfo​

TenantGroupInfo()

Show group info about this tenant.

TenantHasNft​

TenantHasNft({
  tenantId,
  nftAddr
})

Returns true if an NFT contract is in the tenant's 'tenant_nfts' group

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

nftAddrstring✓

= The address of the NFT contract (hex format)

TenantMint​

TenantMint({
  tenant,
  marketplace,
  sku,
  addr
}) → Promise.<Object>

Mint an NFT using Tenant Auth

Returns: API Response Object

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

marketplacestring✓

Marketplace ID of the NFT

skustring✓

SKU of the NFTs

addrstring✓

The address to mint to

TenantNftList​

TenantNftList({ tenantId })

Returns list of NFT contracts in the tenant's 'tenant_nfts' group

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

TenantPathAuthServiceRequest​

TenantPathAuthServiceRequest({
  path,
  method,
  queryParams,
  headers
}) → Promise.<Object>

Authority Service API request using path auth. Typically used for GET and DELETE

Returns: The API Response

Parameters

NameTypeRequiredDescription
pathstring✓

The request endpoint

methodstring✓

The rquest method

queryParamsObject✓

The query parameters

headersObject✓

The headers

TenantPrimarySales​

TenantPrimarySales({
  tenant,
  marketplace
}) → Promise.<Object>

Get primary sales history for the tenant

Returns: The API Response containing primary sales info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

marketplacestring✓

The marketplace ID

TenantPublishData​

TenantPublishData({
  tenant,
  host,
  contentHash,
  updateLinks,
  env
}) → Promise.<Object>

Submits a new content version hash of this account's Tenant Object for updating to the Eluvio Live Tree.

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

hoststring✓

Authority Service url (Optional)

contentHashstring✓

Version hash of the new Tenant Object to submit

updateLinksboolean✓

True to update links

envstring✓

Environment to update -- "production" or "staging", default production

TenantPublishPrivate​

TenantPublishPrivate({
  tenant,
  host,
  env
}) → Promise.<Object>

Submits info to authd about the existence of a private (non-media-wallet-enabled) tenant. The key reason for this is to allow the tenant to get its DB tables initialized.

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

hoststring✓

Authority Service url (Optional)

envstring✓

Environment to update -- "production" or "staging", default production

TenantRemoveNft​

TenantRemoveNft({
  tenantId,
  nftAddr
})

Remove an NFT contract from the tenant's 'tenant_nfts' group

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

nftAddrstring✓

= The address of the NFT contract (hex format)

TenantReplaceMinterConfig​

TenantReplaceMinterConfig({ tenant }) → Promise.<Object>

Replaces minter configuration using the authority service

Returns: The API Response for the request

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantSecondarySales​

TenantSecondarySales({ tenant }) → Promise.<Object>

Get secondary sales history for the tenant

Returns: The API Response containing primary sales info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantSessionsCsv​

TenantSessionsCsv({
  tenant,
  start_ts,
  end_ts
}) → Promise.<Object>

Fetch session data from the analytics API for a tenant

Returns: The API Response containing session csv info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

start_tsint✓

Start timestamp in seconds since epoch

end_tsint✓

End timestamp in seconds since epoch

TenantSetTokenURI​

TenantSetTokenURI({
  requestType,
  tenantId,
  contractAddress,
  tokenURI,
  tokenId,
  host,
  csv
}) → Promise.<Object>

Set the Token URI for an NFT. Currently only setting one and a time. Will support types, single, batch and all.

Returns: An object containing tenant info, including 'warnings'

Parameters

NameTypeRequiredDescription
requestTypestring✓

The type of request: single, batch, all

tenantIdstring✓

The ID of the tenant (iten***)

contractAddressstring✓

The NFT contract address

tokenURIstring✓

The new token URI

tokenIdint✓

The NFT token ID

hoststring✓

The host to use for the request, undefined to use config

csvstring✓

The CSV file to use for the request, undefined to use config

TenantShow​

TenantShow({ tenantId }) → Promise.<Object>

Show info about this tenant. Currently only listing NFT marketplaces.

Returns: An object containing tenant info, including 'warnings'

Parameters

NameTypeRequiredDescription
tenantIdstring✓

The ID of the tenant (iten***)

TenantTicketsGenerate​

TenantTicketsGenerate({
  tenant,
  otp,
  otpClass,
  quantity,
  emails,
  embedUrlBase
}) → Promise.<Object>

Generate tickets (NTP) as a tenant.

Tickets may be bound to emails - in this case, the list of emails has to be supplied as an argument, and the 'quantity' is no longer allowed.

Note that technically tickets can be bound to any user identifier. Emails are the most common but other IDs such as usernames or oauth/openid subject IDs are also used, so there is no required format for the strings in the file.

Optionally creates embed URLs for each ticket code generated, based on a template URL that contains all required embed URL parameters except for the ticket and optionally email.

Returns: Tickets API Response Object

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

otpstring✓

The OTP ID

otpClassinteger✓

The OTP class (4 or 5) (default 5)

quantityinteger✓

Number of tickets to generate

emailsstring✓

File containing one email per line

embedUrlBasestring✓

Base embed URL, used to generate embed URLs for each ticket

TenantTransferFailures​

TenantTransferFailures({ tenant }) → Promise.<Object>

Get failed transfer report for the tenant. Used to identify payments collected on failed transfers.

Returns: The API Response containing the failed transfers report

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantUnifiedSales​

TenantUnifiedSales({ tenant }) → Promise.<Object>

Get unified primary&secondary sales history for the tenant

Returns: The API Response containing primary sales info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

TenantUpdateTokenURI​

TenantUpdateTokenURI({
  tenantId,
  contractAddress,
  hash,
  dryRun
}) → Promise.<Object>

Update all token URIs for a given contract to the new hash provided as argument.

Returns: An object containing operation result

Parameters

NameTypeRequiredDescription
tenantIdstring✓

Tenant ID (iten format)

contractAddressstring✓

The NFT contract address

hashstring✓

The new NFT template object hash

dryRunbool✓

Dry run flag (default 'true')

TenantWallets​

TenantWallets({
  tenant,
  maxNumber
}) → Promise.<Object>

Get the list of wallets bound by the Tenant

Returns: The API Response containing list of Wallet Info

Parameters

NameTypeRequiredDescription
tenantstring✓

The Tenant ID

maxNumberinteger✓

The address to mint to