2xxxx codes

Error codes 2xxxx indicate business logic related issues with input (failed preconditions, validations etc.).

21000

Message

One or more preconditions failed

Description

The provided input data are valid, but do not conform some of the prerequisites of the requested operation

Details

Contains details about the failed preconditions. See error codes of the details below

What to do

Check the details field for additional information

21000-1001

Message

asset with uinque Id uniqueAssetId does not exist

Description

the requested operation requires, that the asset with the 'uniqueAssetId' exists prior to execution of this operation

What to do

check that correct uniqueAssetId is used

Arguments

uniqueAssetId

21000-1002

Message

the user userId does not own asset uniqueAssetId issuer's address assetIssuerAddress

Description

the requested operation requires, that the user, requesting the operation, owns the wallet, that was used to create the asset

What to do

- check that correct uniqueAssetId is used

- check that correct user in requesting the operation

- check that the 'assetIssuerAddress' wallet is added to user's wallet

Arguments

userId

uniqueAssetId

assetIssuerAddress

21000-1003

Message

invalid units amount provided (must be positive integer): providedAmount

Description

the amount of sparks is less than or equal to zero

What to do

check the value of the sparks and provide correct value of providedAmount

Arguments

providedAmount

21000-1004

Message

spark factor is not defined for the asset uniqueAssetId

Description

the requested operation requires, that the spark factor is defined for the asset, but it's actually missing

What to do

add sparkFactor to the asset description

Arguments

uniqueAssetId

21000-1005

Message

the user userId does not own signer address signerAddress

Description

the user does not own the signer address

What to do

check that the 'assetIssuerAddress' wallet is added to user's wallet

Arguments

userId

signerAddress

21000-1006

Message

not enough sparks on the balance. Address: signerAddress, uniqueAssetId: uniqueAssetId, required amount: requiredAmount, actual amount: actualAmount

Description

the requested operation requires, that there's at least 'actualAmount' of sparks on the 'signerAddress' asset balance

What to do

add enough sparks of the asset to the 'signerAddress'

Arguments

signerAddress

uniqueAssetId

requiredAmount

actualAmount

21000-1007

Message

the instance is configured to operate on assets from ledger configuredLedgerId, but the requested asset 'uniqueAssetId' is from ledger assetLedgerId

Description

the requested operation requires, that the asset with the 'uniqueAssetId' was created in the ledger, that is configured for the current instance

What to do

check that correct uniqueAssetId is used

Arguments

configuredLedgerId

uniqueAssetId

assetLedgerId

21000-1008

Message

the source asset with id 'sourceUniqueAssetId' is already linked to the asset with id 'targetUniqueAssetId'

Description

it is not possible to link an already liked asset

What to do

check that the targetUniqueAssetId belongs to an asset that is not yet linked

Arguments

sourceUniqueAssetId

targetUniqueAssetId

21000-1009

Message

the source asset with id 'sourceUniqueAssetId' is not linked to the asset with id 'targetUniqueAssetId'

Description

it is not possible to unlink assets which are not linked

What to do

check that the targetUniqueAssetId of a linked asset is used

Arguments

sourceUniqueAssetId

targetUniqueAssetId

22000

Message

One or more validations failed

Description

The provided input data are correct, but do not conform some of the prerequisites of the requested operation

Details

contains details about the failed validations. See error codes of the details below

What to do

Check the details field for additional information

22000-2001

Message

Either asset name or issuer address should be provided in search request

Description

when executing a search, either asset name or issuer address or both should be provided in search request, but both fields are empty

What to do

fill either or both of the requested fields

22000-2002

Message

Issuer address value should be 40 or 42 symbol long

Description

When executing a search a valid address should be provided: it should be 40 characters long or 42 if prefixed with 0x

What to do

Provide a correct issuer address

22000-2003

Message

Valid language code should be provided for asset

Description

A created asset must have a value for the field 'Language'

What to do

Assign a correct value taken from the document db collection of attributes

22000-2004

Message

Valid jurisdiction should be provided for asset

Description

A created asset must have a value for the field 'jurisdiction'

What to do

Assign a correct value taken from the document db collection of attributes

22000-2005

Message

Asset's unit of measure is not valid

Description

An incorrect value is provided for the asset's property 'UnitOfMeasure'

What to do

Assign a correct value taken from the document db collection of attributes

22000-2006

Message

Asset's spark factor is not valid

Description

An incorrect value is provided or the asset's property 'SparkFactor'

What to do

Provide a valid number for the asset's property 'SparkFactor'

22000-2007

Message

Asset's class is not valid

Description

An incorrect value is provided for the asset's property 'AssetClass'

What to do

Assign a correct value taken from the document db collection of attributes

22000-2008

Message

The number of sections in Asset custom definition item's SectionsPathNames differs from SectionsPath

Description

The number of sections in Asset custom definition item's SectionsPathNames differs from SectionsPath. For example, SectionPath="[main][fields][name]" has three sections and SectionsPathNames has only two "[Main][Asset properties]"

What to do

Either provide the same number of section names in SectionsPathNames as for SectionsPath or leave it empty. In latter case the names will be copied from SectionsPath

22000-2009

Message

Offered asset unqueId must be specified in request

Description

The request does not contain a value for the required property OfferedAssetId

What to do

Provide a value for the property OfferedAssetId

22000-2010

Message

Desired asset unqueId must be specified in request

Description

The request does not contain a value for the required property DesiredAssetId

What to do

Provide a value for the property DesiredAssetId

22000-2011

Message

Desired and offered assets unqueIds must differ

Description

Same values are provided for both OfferedAssetId and DesiredAssetId properties in the request

What to do

Provide different values for the properties OfferedAssetId and DesiredAssetId

22000-2012

Message

Either offered or desired amount of sparks must be specified in request but not both

Description

It is required, that either OfferedAmount or DesiredAmount value is specified in the request (not both)

What to do

Check that one and only one property (either OfferedAmount or DesiredAmount) is assigned a value

22000-2013

Message

Signer address must be specified

Description

An authenticated user can have different owned address, so the signer address must be specified

What to do

Provide a value for the property SignerAddress

22000-2014

Message

Input amount must be a positive integer

Description

Incorrect value is specified for the property InputAmount

What to do

Provide a positive integer value for the property InputAmount

22000-2015

Message

Array of supply ids must contain at least one supply id

Description

The SupplyIds property must be a non-empty array

What to do

Provide a correct value (non-empty array) for the SupplyIds property

22000-2016

Message

Array of target unique asset ids must not be empty

Description

The TargetAssetIds property must be a non-empty array

What to do

Provide a correct value (non-empty array) for the TargetAssetIds property

22000-2017

Message

User can delete only his own data. Calling user:callingUserUser to delete:userToDelete

Description

The user id of currently logged-in user is different than the id, provided as parameter for deletion

What to do

Provide the userId as parameter same as the current user id

22000-2018

Message

Desired amount must be a positive integer

Description

The request contains incorrect value of DesiredAmount, it must be positive integer

What to do

Provide correct value in sparks for the

DesiredAmount

22000-2019

Message

Target address must be specified

Description

The request does not contain a value for the required property TargetAddress

What to do

Provide the address TargetAddress to which sparks will be sent when invoice is paid

22000-2020

Message

The due date is required and must be in the future

Description

The request contains incorrect value of DueOn, it must be the date in the future (more than current date)

What to do

Provide correct date for the

DueOn

22000-2021

Message

Asset's currency is not valid

Description

The request contains incorrect value of

CurrencyCode

What to do

Check the list of available currencies by calling GET /Currencies and provide correct value for CurrencyCode

22000-2022

Message

Unit of measure field is not supported for current asset type

Description

The request contains value of

UnitOfMeasureCode though the asset has the type which doesn't support property UnitOfMeasureCode, asset should have CurrencyCode instead

What to do

Remove UnitOfMeasureCode from the request or change the asset

22000-2023

Message

Currency field is not supported for current asset type

Description

The request contains value of

CurrencyCode though the asset has the type which doesn't support property CurrencyCode, asset should have UnitOfMeasureCode instead

What to do

Remove CurrencyCode from the request or change the asset

22000-2024

Message

Wallet with EthereumAddress already exists

Description

The wallet address which was used as EthereumAddress in the request already exists in the list of wallets of the specified UserId

What to do

Provide correct request data: new EthereumAddress for the specified UserId or new UserId for the specified EthereumAddress

22000-2025

Message

Warp desired asset warpDesiredUniqueAssetId does not match the invoice asset invoiceUniqueAssetId"

Description

The result of the warp execution gives the units of an asset that is different form the asset defined in the invoice

What to do

When paying an invoice with WARP, the WARP desired asset must correspond to the asset defined in the invoice.

22000-2026

Message

The output amount after warp execution is not sufficient

Description

The result of the warp execution gives an amount that is less than the amount defined in the invoice

What to do

Specify the higher amount. Or better use the input amount provided in the result of the WARP search

Last updated