diff --git a/frontend/src/app/services/message-translation-service/message-store.ts b/frontend/src/app/services/message-translation-service/message-store.ts index ab51438b6..9fbd7e14b 100644 --- a/frontend/src/app/services/message-translation-service/message-store.ts +++ b/frontend/src/app/services/message-translation-service/message-store.ts @@ -1,18 +1,18 @@ import { HederaResponseCode } from "@guardian/interfaces"; export const MessagesMap = new Map(); -MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION, 'For any error not handled by specific error codes listed below.'); -MessagesMap.set(HederaResponseCode.PAYER_ACCOUNT_NOT_FOUND, 'Payer account does not exist.'); -MessagesMap.set(HederaResponseCode.INVALID_NODE_ACCOUNT, 'Node Account provided does not match the node account of the node the transaction was submitted to.'); -MessagesMap.set(HederaResponseCode.TRANSACTION_EXPIRED, 'Pre-Check error when TransactionValidStart + transactionValidDuration is less than current consensus time.'); +MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION, 'For any error not handled by specific error codes listed below'); +MessagesMap.set(HederaResponseCode.PAYER_ACCOUNT_NOT_FOUND, 'Payer account does not exist'); +MessagesMap.set(HederaResponseCode.INVALID_NODE_ACCOUNT, 'Node Account provided does not match the node account of the node the transaction was submitted to'); +MessagesMap.set(HederaResponseCode.TRANSACTION_EXPIRED, 'Pre-Check error when TransactionValidStart + transactionValidDuration is less than current consensus time'); MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION_START, 'Transaction start time is greater than current consensus time'); -MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION_DURATION, 'valid transaction duration is a positive non zero number that does not exceed 120 seconds'); +MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION_DURATION, 'Valid transaction duration is a positive non zero number that does not exceed 120 seconds'); MessagesMap.set(HederaResponseCode.INVALID_SIGNATURE, 'The transaction signature is not valid'); MessagesMap.set(HederaResponseCode.MEMO_TOO_LONG, 'Transaction memo size exceeded 100 bytes'); MessagesMap.set(HederaResponseCode.INSUFFICIENT_TX_FEE, 'The fee provided in the transaction is insufficient for this type of transaction'); MessagesMap.set(HederaResponseCode.INSUFFICIENT_PAYER_BALANCE, 'The payer account has insufficient cryptocurrency to pay the transaction fee'); MessagesMap.set(HederaResponseCode.DUPLICATE_TRANSACTION, 'This transaction ID is a duplicate of one that was submitted to this node or reached consensus in the last 180 seconds (receipt period)'); -MessagesMap.set(HederaResponseCode.BUSY, 'If API is throttled out'); +MessagesMap.set(HederaResponseCode.BUSY, 'The API is throttled out'); MessagesMap.set(HederaResponseCode.NOT_SUPPORTED, 'The API is not currently supported'); MessagesMap.set(HederaResponseCode.INVALID_FILE_ID, 'The file id is invalid or does not exist'); MessagesMap.set(HederaResponseCode.INVALID_ACCOUNT_ID, 'The account id is invalid or does not exist'); @@ -21,75 +21,75 @@ MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION_ID, 'Transaction id is no MessagesMap.set(HederaResponseCode.RECEIPT_NOT_FOUND, 'Receipt for given transaction id does not exist'); MessagesMap.set(HederaResponseCode.RECORD_NOT_FOUND, 'Record for given transaction id does not exist'); MessagesMap.set(HederaResponseCode.INVALID_SOLIDITY_ID, 'The solidity id is invalid or entity with this solidity id does not exist'); -MessagesMap.set(HederaResponseCode.UNKNOWN, 'This node has submitted this transaction to the network. Status of the transaction is currently unknown.'); +MessagesMap.set(HederaResponseCode.UNKNOWN, 'This node has submitted this transaction to the network. Status of the transaction is currently unknown'); MessagesMap.set(HederaResponseCode.SUCCESS, 'The transaction succeeded'); -MessagesMap.set(HederaResponseCode.FAIL_INVALID, 'There was a system error and the transaction failed because of invalid request parameters.'); -MessagesMap.set(HederaResponseCode.FAIL_FEE, 'There was a system error while performing fee calculation, reserved for future.'); -MessagesMap.set(HederaResponseCode.FAIL_BALANCE, 'There was a system error while performing balance checks, reserved for future.'); +MessagesMap.set(HederaResponseCode.FAIL_INVALID, 'There was a system error and the transaction failed because of invalid request parameters'); +MessagesMap.set(HederaResponseCode.FAIL_FEE, 'There was a system error while performing fee calculation, reserved for future'); +MessagesMap.set(HederaResponseCode.FAIL_BALANCE, 'There was a system error while performing balance checks, reserved for future'); MessagesMap.set(HederaResponseCode.KEY_REQUIRED, 'Key not provided in the transaction body'); MessagesMap.set(HederaResponseCode.BAD_ENCODING, 'Unsupported algorithm/encoding used for keys in the transaction'); MessagesMap.set(HederaResponseCode.INSUFFICIENT_ACCOUNT_BALANCE, 'When the account balance is not sufficient for the transfer'); MessagesMap.set(HederaResponseCode.INVALID_SOLIDITY_ADDRESS, 'During an update transaction when the system is not able to find the Users Solidity address'); MessagesMap.set(HederaResponseCode.INSUFFICIENT_GAS, 'Not enough gas was supplied to execute transaction'); -MessagesMap.set(HederaResponseCode.CONTRACT_SIZE_LIMIT_EXCEEDED, 'contract byte code size is over the limit'); -MessagesMap.set(HederaResponseCode.LOCAL_CALL_MODIFICATION_EXCEPTION, 'local execution (query) is requested for a function which changes state'); +MessagesMap.set(HederaResponseCode.CONTRACT_SIZE_LIMIT_EXCEEDED, 'Contract byte code size is over the limit'); +MessagesMap.set(HederaResponseCode.LOCAL_CALL_MODIFICATION_EXCEPTION, 'Local execution (query) is requested for a function which changes state'); MessagesMap.set(HederaResponseCode.CONTRACT_REVERT_EXECUTED, 'Contract REVERT OPCODE executed'); -MessagesMap.set(HederaResponseCode.CONTRACT_EXECUTION_EXCEPTION, 'For any contract execution related error not handled by specific error codes listed above.'); +MessagesMap.set(HederaResponseCode.CONTRACT_EXECUTION_EXCEPTION, 'For any contract execution related error not handled by specific error codes listed above'); MessagesMap.set(HederaResponseCode.INVALID_RECEIVING_NODE_ACCOUNT, 'In Query validation, account with +ve(amount) value should be Receiving node account, the receiver account should be only one account in the list'); MessagesMap.set(HederaResponseCode.MISSING_QUERY_HEADER, 'Header is missing in Query request'); MessagesMap.set(HederaResponseCode.ACCOUNT_UPDATE_FAILED, 'The update of the account failed'); MessagesMap.set(HederaResponseCode.INVALID_KEY_ENCODING, 'Provided key encoding was not supported by the system'); MessagesMap.set(HederaResponseCode.NULL_SOLIDITY_ADDRESS, 'null solidity address'); -MessagesMap.set(HederaResponseCode.CONTRACT_UPDATE_FAILED, 'update of the contract failed'); -MessagesMap.set(HederaResponseCode.INVALID_QUERY_HEADER, 'the query header is invalid'); +MessagesMap.set(HederaResponseCode.CONTRACT_UPDATE_FAILED, 'Update of the contract failed'); +MessagesMap.set(HederaResponseCode.INVALID_QUERY_HEADER, 'The query header is invalid'); MessagesMap.set(HederaResponseCode.INVALID_FEE_SUBMITTED, 'Invalid fee submitted'); MessagesMap.set(HederaResponseCode.INVALID_PAYER_SIGNATURE, 'Payer signature is invalid'); -MessagesMap.set(HederaResponseCode.KEY_NOT_PROVIDED, 'The keys were not provided in the request.'); -MessagesMap.set(HederaResponseCode.INVALID_EXPIRATION_TIME, 'Expiration time provided in the transaction was invalid.'); +MessagesMap.set(HederaResponseCode.KEY_NOT_PROVIDED, 'The keys were not provided in the request'); +MessagesMap.set(HederaResponseCode.INVALID_EXPIRATION_TIME, 'Expiration time provided in the transaction was invalid'); MessagesMap.set(HederaResponseCode.NO_WACL_KEY, 'WriteAccess Control Keys are not provided for the file'); -MessagesMap.set(HederaResponseCode.FILE_CONTENT_EMPTY, 'The contents of file are provided as empty.'); +MessagesMap.set(HederaResponseCode.FILE_CONTENT_EMPTY, 'The contents of file are provided as empty'); MessagesMap.set(HederaResponseCode.INVALID_ACCOUNT_AMOUNTS, 'The crypto transfer credit and debit do not sum equal to 0'); MessagesMap.set(HederaResponseCode.EMPTY_TRANSACTION_BODY, 'Transaction body provided is empty'); MessagesMap.set(HederaResponseCode.INVALID_TRANSACTION_BODY, 'Invalid transaction body provided'); -MessagesMap.set(HederaResponseCode.INVALID_SIGNATURE_TYPE_MISMATCHING_KEY, 'the type of key (base ed25519 key, KeyList, or ThresholdKey) does not match the type of signature (base ed25519 signature, SignatureList, or ThresholdKeySignature)'); -MessagesMap.set(HederaResponseCode.INVALID_SIGNATURE_COUNT_MISMATCHING_KEY, 'the number of key (KeyList, or ThresholdKey) does not match that of signature (SignatureList, or ThresholdKeySignature). e.g. if a keyList has 3 base keys, then the corresponding signatureList should also have 3 base signatures.'); -MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH_BODY, 'the livehash body is empty'); -MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH, 'the livehash data is missing'); -MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH_KEYS, 'the key list is empty'); -MessagesMap.set(HederaResponseCode.INVALID_LIVE_HASH_SIZE, 'the livehash data is not the output of a SHA-384 digest'); -MessagesMap.set(HederaResponseCode.EMPTY_QUERY_BODY, 'the query body is empty'); -MessagesMap.set(HederaResponseCode.EMPTY_LIVE_QUERY, 'the query body is empty'); -MessagesMap.set(HederaResponseCode.LIVE_HASH_NOT_FOUND, 'the livehash is not present'); -MessagesMap.set(HederaResponseCode.ACCOUNT_ID_DOES_NOT_EXIST, 'the account id passed has not yet been created.'); -MessagesMap.set(HederaResponseCode.LIVE_HASH_ALREADY_EXISTS, 'the livehash already exists for a given account'); +MessagesMap.set(HederaResponseCode.INVALID_SIGNATURE_TYPE_MISMATCHING_KEY, 'The type of key (base ed25519 key, KeyList, or ThresholdKey) does not match the type of signature (base ed25519 signature, SignatureList, or ThresholdKeySignature)'); +MessagesMap.set(HederaResponseCode.INVALID_SIGNATURE_COUNT_MISMATCHING_KEY, 'The number of key (KeyList, or ThresholdKey) does not match that of signature (SignatureList, or ThresholdKeySignature). e.g. if a keyList has 3 base keys, then the corresponding signatureList should also have 3 base signatures'); +MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH_BODY, 'The livehash body is empty'); +MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH, 'The livehash data is missing'); +MessagesMap.set(HederaResponseCode.EMPTY_LIVE_HASH_KEYS, 'The key list is empty'); +MessagesMap.set(HederaResponseCode.INVALID_LIVE_HASH_SIZE, 'The livehash data is not the output of a SHA-384 digest'); +MessagesMap.set(HederaResponseCode.EMPTY_QUERY_BODY, 'The query body is empty'); +MessagesMap.set(HederaResponseCode.EMPTY_LIVE_QUERY, 'The query body is empty'); +MessagesMap.set(HederaResponseCode.LIVE_HASH_NOT_FOUND, 'The livehash is not present'); +MessagesMap.set(HederaResponseCode.ACCOUNT_ID_DOES_NOT_EXIST, 'The account id passed has not yet been created'); +MessagesMap.set(HederaResponseCode.LIVE_HASH_ALREADY_EXISTS, 'The livehash already exists for a given account'); MessagesMap.set(HederaResponseCode.INVALID_FILE_WACL, 'File WACL keys are invalid'); MessagesMap.set(HederaResponseCode.SERIALIZATION_FAILED, 'Serialization failure'); MessagesMap.set(HederaResponseCode.TRANSACTION_OVERSIZE, 'The size of the Transaction is greater than transactionMaxBytes'); MessagesMap.set(HederaResponseCode.TRANSACTION_TOO_MANY_LAYERS, 'The Transaction has more than 50 levels'); MessagesMap.set(HederaResponseCode.CONTRACT_DELETED, 'Contract is marked as deleted'); -MessagesMap.set(HederaResponseCode.PLATFORM_NOT_ACTIVE, 'the platform node is either disconnected or lagging behind.'); -MessagesMap.set(HederaResponseCode.KEY_PREFIX_MISMATCH, 'one public key matches more than one prefixes on the signature map'); +MessagesMap.set(HederaResponseCode.PLATFORM_NOT_ACTIVE, 'The platform node is either disconnected or lagging behind'); +MessagesMap.set(HederaResponseCode.KEY_PREFIX_MISMATCH, 'One public key matches more than one prefixes on the signature map'); MessagesMap.set(HederaResponseCode.PLATFORM_TRANSACTION_NOT_CREATED, 'Transaction not created by platform due to large backlog'); -MessagesMap.set(HederaResponseCode.INVALID_RENEWAL_PERIOD, 'auto renewal period is not a positive number of seconds'); -MessagesMap.set(HederaResponseCode.INVALID_PAYER_ACCOUNT_ID, 'the response code when a smart contract id is passed for a crypto API request'); -MessagesMap.set(HederaResponseCode.ACCOUNT_DELETED, 'the account has been marked as deleted'); -MessagesMap.set(HederaResponseCode.FILE_DELETED, 'the file has been marked as deleted'); -MessagesMap.set(HederaResponseCode.ACCOUNT_REPEATED_IN_ACCOUNT_AMOUNTS, 'same accounts repeated in the transfer account list'); -MessagesMap.set(HederaResponseCode.SETTING_NEGATIVE_ACCOUNT_BALANCE, 'attempting to set negative balance value for crypto account'); -MessagesMap.set(HederaResponseCode.OBTAINER_REQUIRED, 'when deleting smart contract that has crypto balance either transfer account or transfer smart contract is required'); -MessagesMap.set(HederaResponseCode.OBTAINER_SAME_CONTRACT_ID, 'when deleting smart contract that has crypto balance you can not use the same contract id as transferContractId as the one being deleted'); -MessagesMap.set(HederaResponseCode.OBTAINER_DOES_NOT_EXIST, 'transferAccountId or transferContractId specified for contract delete does not exist'); -MessagesMap.set(HederaResponseCode.MODIFYING_IMMUTABLE_CONTRACT, 'attempting to modify (update or delete a immutable smart contract, i.e. one created without a admin key)'); +MessagesMap.set(HederaResponseCode.INVALID_RENEWAL_PERIOD, 'Auto renewal period is not a positive number of seconds'); +MessagesMap.set(HederaResponseCode.INVALID_PAYER_ACCOUNT_ID, 'The response code when a smart contract id is passed for a crypto API request'); +MessagesMap.set(HederaResponseCode.ACCOUNT_DELETED, 'The account has been marked as deleted'); +MessagesMap.set(HederaResponseCode.FILE_DELETED, 'The file has been marked as deleted'); +MessagesMap.set(HederaResponseCode.ACCOUNT_REPEATED_IN_ACCOUNT_AMOUNTS, 'Same accounts repeated in the transfer account list'); +MessagesMap.set(HederaResponseCode.SETTING_NEGATIVE_ACCOUNT_BALANCE, 'Attempting to set negative balance value for crypto account'); +MessagesMap.set(HederaResponseCode.OBTAINER_REQUIRED, 'When deleting smart contract that has crypto balance either transfer account or transfer smart contract is required'); +MessagesMap.set(HederaResponseCode.OBTAINER_SAME_CONTRACT_ID, 'When deleting smart contract that has crypto balance you can not use the same contract id as transferContractId as the one being deleted'); +MessagesMap.set(HederaResponseCode.OBTAINER_DOES_NOT_EXIST, 'TransferAccountId or transferContractId specified for contract delete does not exist'); +MessagesMap.set(HederaResponseCode.MODIFYING_IMMUTABLE_CONTRACT, 'Attempting to modify (update or delete a immutable smart contract, i.e. one created without a admin key)'); MessagesMap.set(HederaResponseCode.FILE_SYSTEM_EXCEPTION, 'Unexpected exception thrown by file system functions'); -MessagesMap.set(HederaResponseCode.AUTORENEW_DURATION_NOT_IN_RANGE, 'the duration is not a subset of [MINIMUM_AUTORENEW_DURATION,MAXIMUM_AUTORENEW_DURATION]'); -MessagesMap.set(HederaResponseCode.ERROR_DECODING_BYTESTRING, 'Decoding the smart contract binary to a byte array failed. Check that the input is a valid hex string.'); +MessagesMap.set(HederaResponseCode.AUTORENEW_DURATION_NOT_IN_RANGE, 'The duration is not a subset of [MINIMUM_AUTORENEW_DURATION,MAXIMUM_AUTORENEW_DURATION]'); +MessagesMap.set(HederaResponseCode.ERROR_DECODING_BYTESTRING, 'Decoding the smart contract binary to a byte array failed. Check that the input is a valid hex string'); MessagesMap.set(HederaResponseCode.CONTRACT_FILE_EMPTY, 'File to create a smart contract was of length zero'); MessagesMap.set(HederaResponseCode.CONTRACT_BYTECODE_EMPTY, 'Bytecode for smart contract is of length zero'); MessagesMap.set(HederaResponseCode.INVALID_INITIAL_BALANCE, 'Attempt to set negative initial balance'); -MessagesMap.set(HederaResponseCode.INVALID_RECEIVE_RECORD_THRESHOLD, 'attempt to set negative receive record threshold'); -MessagesMap.set(HederaResponseCode.INVALID_SEND_RECORD_THRESHOLD, 'attempt to set negative send record threshold'); +MessagesMap.set(HederaResponseCode.INVALID_RECEIVE_RECORD_THRESHOLD, 'Attempt to set negative receive record threshold'); +MessagesMap.set(HederaResponseCode.INVALID_SEND_RECORD_THRESHOLD, 'Attempt to set negative send record threshold'); MessagesMap.set(HederaResponseCode.ACCOUNT_IS_NOT_GENESIS_ACCOUNT, 'Special Account Operations should be performed by only Genesis account, return this code if it is not Genesis Account'); -MessagesMap.set(HederaResponseCode.PAYER_ACCOUNT_UNAUTHORIZED, 'The fee payer account doesn\'t have permission to submit such Transaction'); +MessagesMap.set(HederaResponseCode.PAYER_ACCOUNT_UNAUTHORIZED, 'The fee payer account doesn\'T have permission to submit such Transaction'); MessagesMap.set(HederaResponseCode.INVALID_FREEZE_TRANSACTION_BODY, 'FreezeTransactionBody is invalid'); MessagesMap.set(HederaResponseCode.FREEZE_TRANSACTION_BODY_NOT_FOUND, 'FreezeTransactionBody does not exist'); MessagesMap.set(HederaResponseCode.TRANSFER_LIST_SIZE_LIMIT_EXCEEDED, 'Exceeded the number of accounts (both from and to) allowed for crypto transfer list'); @@ -101,7 +101,7 @@ MessagesMap.set(HederaResponseCode.INVALID_FEE_FILE, 'Failed to update fee file' MessagesMap.set(HederaResponseCode.INVALID_EXCHANGE_RATE_FILE, 'Failed to update exchange rate file'); MessagesMap.set(HederaResponseCode.INSUFFICIENT_LOCAL_CALL_GAS, 'Payment tendered for contract local call cannot cover both the fee and the gas'); MessagesMap.set(HederaResponseCode.ENTITY_NOT_ALLOWED_TO_DELETE, 'Entities with Entity ID below 1000 are not allowed to be deleted'); -MessagesMap.set(HederaResponseCode.AUTHORIZATION_FAILED, 'Violating one of these rules: 1) treasury account can update all entities below 0.0.1000, 2) account 0.0.50 can update all entities from 0.0.51 - 0.0.80, 3) Network Function Master Account A/c 0.0.50 - Update all Network Function accounts & perform all the Network Functions listed below, 4) Network Function Accounts: i) A/c 0.0.55 - Update Address Book files (0.0.101/102), ii) A/c 0.0.56 - Update Fee schedule (0.0.111), iii) A/c 0.0.57 - Update Exchange Rate (0.0.112).'); +MessagesMap.set(HederaResponseCode.AUTHORIZATION_FAILED, 'Violating one of these rules: 1) treasury account can update all entities below 0.0.1000, 2) account 0.0.50 can update all entities from 0.0.51 - 0.0.80, 3) Network Function Master Account A/c 0.0.50 - Update all Network Function accounts & perform all the Network Functions listed below, 4) Network Function Accounts: i) A/c 0.0.55 - Update Address Book files (0.0.101/102), ii) A/c 0.0.56 - Update Fee schedule (0.0.111), iii) A/c 0.0.57 - Update Exchange Rate (0.0.112)'); MessagesMap.set(HederaResponseCode.FILE_UPLOADED_PROTO_INVALID, 'Fee Schedule Proto uploaded but not valid (append or update is required)'); MessagesMap.set(HederaResponseCode.FILE_UPLOADED_PROTO_NOT_SAVED_TO_DISK, 'Fee Schedule Proto uploaded but not valid (append or update is required)'); MessagesMap.set(HederaResponseCode.FEE_SCHEDULE_FILE_PART_UPLOADED, 'Fee Schedule Proto File Part uploaded'); @@ -109,16 +109,16 @@ MessagesMap.set(HederaResponseCode.EXCHANGE_RATE_CHANGE_LIMIT_EXCEEDED, 'The cha MessagesMap.set(HederaResponseCode.MAX_CONTRACT_STORAGE_EXCEEDED, 'Contract permanent storage exceeded the currently allowable limit'); MessagesMap.set(HederaResponseCode.MAX_GAS_LIMIT_EXCEEDED, 'Gas exceeded currently allowable gas limit per transaction'); MessagesMap.set(HederaResponseCode.MAX_FILE_SIZE_EXCEEDED, 'File size exceeded the currently allowable limit'); -MessagesMap.set(HederaResponseCode.INVALID_TOPIC_ID, 'The Topic ID specified is not in the system.'); +MessagesMap.set(HederaResponseCode.INVALID_TOPIC_ID, 'The Topic ID specified is not in the system'); MessagesMap.set(HederaResponseCode.INVALID_ADMIN_KEY, 'A provided admin key was invalid'); MessagesMap.set(HederaResponseCode.INVALID_SUBMIT_KEY, 'A provided submit key was invalid'); -MessagesMap.set(HederaResponseCode.UNAUTHORIZED, 'An attempted operation was not authorized (ie - a deleteTopic for a topic with no adminKey).'); -MessagesMap.set(HederaResponseCode.INVALID_TOPIC_MESSAGE, 'A ConsensusService message is empty.'); -MessagesMap.set(HederaResponseCode.INVALID_AUTORENEW_ACCOUNT, 'The autoRenewAccount specified is not a valid, active account.'); -MessagesMap.set(HederaResponseCode.AUTORENEW_ACCOUNT_NOT_ALLOWED, 'An adminKey was not specified on the topic, so there must not be an autoRenewAccount.'); -MessagesMap.set(HederaResponseCode.TOPIC_EXPIRED, 'The topic has expired, was not automatically renewed, and is in a 7 day grace period before the topic will be deleted unrecoverably. This error response code will not be returned until autoRenew functionality is supported by HAPI.'); +MessagesMap.set(HederaResponseCode.UNAUTHORIZED, 'An attempted operation was not authorized (ie - a deleteTopic for a topic with no adminKey)'); +MessagesMap.set(HederaResponseCode.INVALID_TOPIC_MESSAGE, 'A ConsensusService message is empty'); +MessagesMap.set(HederaResponseCode.INVALID_AUTORENEW_ACCOUNT, 'The autoRenewAccount specified is not a valid, active account'); +MessagesMap.set(HederaResponseCode.AUTORENEW_ACCOUNT_NOT_ALLOWED, 'An adminKey was not specified on the topic, so there must not be an autoRenewAccount'); +MessagesMap.set(HederaResponseCode.TOPIC_EXPIRED, 'The topic has expired, was not automatically renewed, and is in a 7 day grace period before the topic will be deleted unrecoverably. This error response code will not be returned until autoRenew functionality is supported by HAPI'); MessagesMap.set(HederaResponseCode.INVALID_CHUNK_NUMBER, 'Chunk number must be from 1 to total (chunks) inclusive'); -MessagesMap.set(HederaResponseCode.INVALID_CHUNK_TRANSACTION_ID, 'For every chunk, the payer account that is part of initialTransactionID must match the Payer Account of this transaction. The entire initialTransactionID should match the transactionID of the first chunk, but this is not checked or enforced by Hedera except when the chunk number is 1.'); +MessagesMap.set(HederaResponseCode.INVALID_CHUNK_TRANSACTION_ID, 'For every chunk, the payer account that is part of initialTransactionID must match the Payer Account of this transaction. The entire initialTransactionID should match the transactionID of the first chunk, but this is not checked or enforced by Hedera except when the chunk number is 1'); MessagesMap.set(HederaResponseCode.INVALID_RECEIVE_RECORD_THRESHOLD, '[Deprecated v0.8.0] Attempt to set negative receive record threshold'); MessagesMap.set(HederaResponseCode.INVALID_SEND_RECORD_THRESHOLD, '[Deprecated v0.8.0] Attempt to set negative send record threshold'); MessagesMap.set(HederaResponseCode.ACCOUNT_FROZEN_FOR_TOKEN, 'Account is frozen and cannot transact with the token'); @@ -170,7 +170,7 @@ MessagesMap.set(HederaResponseCode.IDENTICAL_SCHEDULE_ALREADY_CREATED, 'A schedu MessagesMap.set(HederaResponseCode.INVALID_ZERO_BYTE_IN_STRING, 'A string field in the transaction has a UTF-8 encoding with the prohibited zero byte'); MessagesMap.set(HederaResponseCode.SCHEDULE_ALREADY_DELETED, 'A schedule being signed or deleted has already been deleted'); MessagesMap.set(HederaResponseCode.SCHEDULE_ALREADY_EXECUTED, 'A schedule being signed or deleted has already been executed'); -MessagesMap.set(HederaResponseCode.MESSAGE_SIZE_TOO_LARGE, 'ConsensusSubmitMessage request\'s message size is larger than allowed.'); +MessagesMap.set(HederaResponseCode.MESSAGE_SIZE_TOO_LARGE, 'ConsensusSubmitMessage request\'s message size is larger than allowed'); MessagesMap.set(HederaResponseCode.OPERATION_REPEATED_IN_BUCKET_GROUPS, 'An operation was assigned to more than one throttle group in a given bucket'); MessagesMap.set(HederaResponseCode.BUCKET_CAPACITY_OVERFLOW, 'The capacity needed to satisfy all opsPerSec groups in a bucket overflowed a signed 8-byte integral type'); MessagesMap.set(HederaResponseCode.NODE_CAPACITY_NOT_SUFFICIENT_FOR_OPERATION, 'Given the network size in the address book, the node-level capacity for an operation would never be enough to accept a single request; usually means a bucket burstPeriod should be increased'); @@ -181,9 +181,9 @@ MessagesMap.set(HederaResponseCode.UNPARSEABLE_THROTTLE_DEFINITIONS, 'The new co MessagesMap.set(HederaResponseCode.INVALID_THROTTLE_DEFINITIONS, 'The new throttle definitions system file were invalid, and no more specific error could be divined'); MessagesMap.set(HederaResponseCode.ACCOUNT_EXPIRED_AND_PENDING_REMOVAL, 'The transaction references an account which has passed its expiration without renewal funds available, and currently remains in the ledger only because of the grace period given to expired entities'); MessagesMap.set(HederaResponseCode.INVALID_TOKEN_MAX_SUPPLY, 'Invalid token max supply'); -MessagesMap.set(HederaResponseCode.INVALID_TOKEN_NFT_SERIAL_NUMBER, 'Invalid token nft serial number'); -MessagesMap.set(HederaResponseCode.INVALID_NFT_ID, 'Invalid nft id'); -MessagesMap.set(HederaResponseCode.METADATA_TOO_LONG, 'Nft metadata is too long'); +MessagesMap.set(HederaResponseCode.INVALID_TOKEN_NFT_SERIAL_NUMBER, 'Invalid token NFT serial number'); +MessagesMap.set(HederaResponseCode.INVALID_NFT_ID, 'Invalid NFT id'); +MessagesMap.set(HederaResponseCode.METADATA_TOO_LONG, 'NFT metadata is too long'); MessagesMap.set(HederaResponseCode.BATCH_SIZE_LIMIT_EXCEEDED, 'Repeated operations count exceeds the limit'); MessagesMap.set(HederaResponseCode.INVALID_QUERY_RANGE, 'The range of data to be gathered is out of the set boundaries'); MessagesMap.set(HederaResponseCode.FRACTION_DIVIDES_BY_ZERO, 'A custom fractional fee set a denominator of zero'); @@ -213,47 +213,47 @@ MessagesMap.set(HederaResponseCode.CUSTOM_FEE_CHARGING_EXCEEDED_MAX_ACCOUNT_AMOU MessagesMap.set(HederaResponseCode.INSUFFICIENT_SENDER_ACCOUNT_BALANCE_FOR_CUSTOM_FEE, 'The sender account in the token transfer transaction could not afford a custom fee'); MessagesMap.set(HederaResponseCode.SERIAL_NUMBER_LIMIT_REACHED, 'Currently, no more than 4,294,967,295 NFTs may be minted for a given unique token type'); MessagesMap.set(HederaResponseCode.CUSTOM_ROYALTY_FEE_ONLY_ALLOWED_FOR_NON_FUNGIBLE_UNIQUE, 'Only tokens of type NON_FUNGIBLE_UNIQUE can have royalty fees'); -MessagesMap.set(HederaResponseCode.NO_REMAINING_AUTOMATIC_ASSOCIATIONS, 'The account has reached the limit on the automatic associations count.'); +MessagesMap.set(HederaResponseCode.NO_REMAINING_AUTOMATIC_ASSOCIATIONS, 'The account has reached the limit on the automatic associations count'); MessagesMap.set(HederaResponseCode.EXISTING_AUTOMATIC_ASSOCIATIONS_EXCEED_GIVEN_LIMIT, 'Already existing automatic associations are more than the new maximum automatic associations'); MessagesMap.set(HederaResponseCode.REQUESTED_NUM_AUTOMATIC_ASSOCIATIONS_EXCEEDS_ASSOCIATION_LIMIT, 'Cannot set the number of automatic associations for an account more than the maximum allowed token associations tokens.maxPerAccount'); MessagesMap.set(HederaResponseCode.TOKEN_IS_PAUSED, 'Token is paused. This Token cannot be a part of any kind of Transaction until unpaused'); MessagesMap.set(HederaResponseCode.TOKEN_HAS_NO_PAUSE_KEY, 'Pause key is not set on token'); MessagesMap.set(HederaResponseCode.INVALID_PAUSE_KEY, 'The provided pause key was invalid'); -MessagesMap.set(HederaResponseCode.FREEZE_UPDATE_FILE_DOES_NOT_EXIST, 'The update file in a freeze transaction body must exist.'); -MessagesMap.set(HederaResponseCode.FREEZE_UPDATE_FILE_HASH_DOES_NOT_MATCH, 'The hash of the update file in a freeze transaction body must match the in-memory hash.'); -MessagesMap.set(HederaResponseCode.NO_UPGRADE_HAS_BEEN_PREPARED, 'A FREEZE_UPGRADE transaction was handled with no previous update prepared.'); -MessagesMap.set(HederaResponseCode.NO_FREEZE_IS_SCHEDULED, 'A FREEZE_ABORT transaction was handled with no scheduled freeze.'); -MessagesMap.set(HederaResponseCode.UPDATE_FILE_HASH_CHANGED_SINCE_PREPARE_UPGRADE, 'The update file hash when handling a FREEZE_UPGRADE transaction differs from the file hash at the time of handling the PREPARE_UPGRADE transaction.'); -MessagesMap.set(HederaResponseCode.FREEZE_START_TIME_MUST_BE_FUTURE, 'The given freeze start time was in the (consensus) past.'); -MessagesMap.set(HederaResponseCode.PREPARED_UPDATE_FILE_IS_IMMUTABLE, 'The prepared update file cannot be updated or appended until either the upgrade has been completed, or a FREEZE_ABORT has been handled.'); -MessagesMap.set(HederaResponseCode.FREEZE_ALREADY_SCHEDULED, 'Once a freeze is scheduled, it must be aborted before any other type of freeze can be performed.'); +MessagesMap.set(HederaResponseCode.FREEZE_UPDATE_FILE_DOES_NOT_EXIST, 'The update file in a freeze transaction body must exist'); +MessagesMap.set(HederaResponseCode.FREEZE_UPDATE_FILE_HASH_DOES_NOT_MATCH, 'The hash of the update file in a freeze transaction body must match the in-memory hash'); +MessagesMap.set(HederaResponseCode.NO_UPGRADE_HAS_BEEN_PREPARED, 'A FREEZE_UPGRADE transaction was handled with no previous update prepared'); +MessagesMap.set(HederaResponseCode.NO_FREEZE_IS_SCHEDULED, 'A FREEZE_ABORT transaction was handled with no scheduled freeze'); +MessagesMap.set(HederaResponseCode.UPDATE_FILE_HASH_CHANGED_SINCE_PREPARE_UPGRADE, 'The update file hash when handling a FREEZE_UPGRADE transaction differs from the file hash at the time of handling the PREPARE_UPGRADE transaction'); +MessagesMap.set(HederaResponseCode.FREEZE_START_TIME_MUST_BE_FUTURE, 'The given freeze start time was in the (consensus) past'); +MessagesMap.set(HederaResponseCode.PREPARED_UPDATE_FILE_IS_IMMUTABLE, 'The prepared update file cannot be updated or appended until either the upgrade has been completed, or a FREEZE_ABORT has been handled'); +MessagesMap.set(HederaResponseCode.FREEZE_ALREADY_SCHEDULED, 'Once a freeze is scheduled, it must be aborted before any other type of freeze can be performed'); MessagesMap.set(HederaResponseCode.FREEZE_UPGRADE_IN_PROGRESS, 'If an NMT upgrade has been prepared, the following operation must be a FREEZE_UPGRADE. (To issue a FREEZE_ONLY, submit a FREEZE_ABORT first.)'); -MessagesMap.set(HederaResponseCode.UPDATE_FILE_ID_DOES_NOT_MATCH_PREPARED, 'If an NMT upgrade has been prepared, the subsequent FREEZE_UPGRADE transaction must confirm the id of the file to be used in the upgrade.'); -MessagesMap.set(HederaResponseCode.UPDATE_FILE_HASH_DOES_NOT_MATCH_PREPARED, 'If an NMT upgrade has been prepared, the subsequent FREEZE_UPGRADE transaction must confirm the hash of the file to be used in the upgrade.'); +MessagesMap.set(HederaResponseCode.UPDATE_FILE_ID_DOES_NOT_MATCH_PREPARED, 'If an NMT upgrade has been prepared, the subsequent FREEZE_UPGRADE transaction must confirm the id of the file to be used in the upgrade'); +MessagesMap.set(HederaResponseCode.UPDATE_FILE_HASH_DOES_NOT_MATCH_PREPARED, 'If an NMT upgrade has been prepared, the subsequent FREEZE_UPGRADE transaction must confirm the hash of the file to be used in the upgrade'); MessagesMap.set(HederaResponseCode.CONSENSUS_GAS_EXHAUSTED, 'Consensus throttle did not allow execution of this transaction. System is throttled at'); -MessagesMap.set(HederaResponseCode.REVERTED_SUCCESS, 'A precompiled contract succeeded, but was later reverted.'); -MessagesMap.set(HederaResponseCode.MAX_STORAGE_IN_PRICE_REGIME_HAS_BEEN_USED, 'All contract storage allocated to the current price regime has been consumed.'); -MessagesMap.set(HederaResponseCode.INVALID_ALIAS_KEY, 'An alias used in a CryptoTransfer transaction is not the serialization of a primitive Key message--that is, a Key with a single Ed25519 or ECDSA(secp256k1) public key and no unknown protobuf fields.'); -MessagesMap.set(HederaResponseCode.UNEXPECTED_TOKEN_DECIMALS, 'A fungible token transfer expected a different number of decimals than the involved type actually has.'); +MessagesMap.set(HederaResponseCode.REVERTED_SUCCESS, 'A precompiled contract succeeded, but was later reverted'); +MessagesMap.set(HederaResponseCode.MAX_STORAGE_IN_PRICE_REGIME_HAS_BEEN_USED, 'All contract storage allocated to the current price regime has been consumed'); +MessagesMap.set(HederaResponseCode.INVALID_ALIAS_KEY, 'An alias used in a CryptoTransfer transaction is not the serialization of a primitive Key message--that is, a Key with a single Ed25519 or ECDSA(secp256k1) public key and no unknown protobuf fields'); +MessagesMap.set(HederaResponseCode.UNEXPECTED_TOKEN_DECIMALS, 'A fungible token transfer expected a different number of decimals than the involved type actually has'); MessagesMap.set(HederaResponseCode.INVALID_PROXY_ACCOUNT_ID, 'The proxy account id is invalid or does not exist'); MessagesMap.set(HederaResponseCode.INVALID_TRANSFER_ACCOUNT_ID, 'The transfer account id in CryptoDelete transaction is invalid or does not exist'); MessagesMap.set(HederaResponseCode.INVALID_FEE_COLLECTOR_ACCOUNT_ID, 'The fee collector account id in TokenFeeScheduleUpdate is invalid or does not exist'); -MessagesMap.set(HederaResponseCode.ALIAS_IS_IMMUTABLE, 'The alias already set on an account cannot be updated using CryptoUpdate transaction.'); -MessagesMap.set(HederaResponseCode.SPENDER_ACCOUNT_SAME_AS_OWNER, 'An approved allowance specifies a spender account that is the same as the hbar/token owner account.owner account.'); -MessagesMap.set(HederaResponseCode.AMOUNT_EXCEEDS_TOKEN_MAX_SUPPLY, 'The establishment or adjustment of an approved allowance cause the token allowance to exceed the token maximum supply.'); -MessagesMap.set(HederaResponseCode.NEGATIVE_ALLOWANCE_AMOUNT, 'The specified amount for an approved allowance cannot be negative.'); -MessagesMap.set(HederaResponseCode.CANNOT_APPROVE_FOR_ALL_FUNGIBLE_COMMON, 'The approveForAll flag cannot be set for a fungible token.'); -MessagesMap.set(HederaResponseCode.SPENDER_DOES_NOT_HAVE_ALLOWANCE, 'The spender does not have an existing approved allowance with the hbar/token owner.'); -MessagesMap.set(HederaResponseCode.AMOUNT_EXCEEDS_ALLOWANCE, 'The transfer amount exceeds the current approved allowance for the spender account.'); -MessagesMap.set(HederaResponseCode.MAX_ALLOWANCES_EXCEEDED, 'The payer account of an approveAllowances or adjustAllowance transaction is attempting to go beyond the maximum allowed number of allowances.'); -MessagesMap.set(HederaResponseCode.EMPTY_ALLOWANCES, 'No allowances have been specified in the approval transaction.'); -MessagesMap.set(HederaResponseCode.SPENDER_ACCOUNT_REPEATED_IN_ALLOWANCES, 'Spender is repeated more than once in Crypto or Token or NFT allowance lists in a single CryptoApproveAllowance transaction.'); -MessagesMap.set(HederaResponseCode.REPEATED_SERIAL_NUMS_IN_NFT_ALLOWANCES, 'Serial numbers are repeated in nft allowance for a single spender account'); +MessagesMap.set(HederaResponseCode.ALIAS_IS_IMMUTABLE, 'The alias already set on an account cannot be updated using CryptoUpdate transaction'); +MessagesMap.set(HederaResponseCode.SPENDER_ACCOUNT_SAME_AS_OWNER, 'An approved allowance specifies a spender account that is the same as the hbar/token owner account.owner account'); +MessagesMap.set(HederaResponseCode.AMOUNT_EXCEEDS_TOKEN_MAX_SUPPLY, 'The establishment or adjustment of an approved allowance cause the token allowance to exceed the token maximum supply'); +MessagesMap.set(HederaResponseCode.NEGATIVE_ALLOWANCE_AMOUNT, 'The specified amount for an approved allowance cannot be negative'); +MessagesMap.set(HederaResponseCode.CANNOT_APPROVE_FOR_ALL_FUNGIBLE_COMMON, 'The approveForAll flag cannot be set for a fungible token'); +MessagesMap.set(HederaResponseCode.SPENDER_DOES_NOT_HAVE_ALLOWANCE, 'The spender does not have an existing approved allowance with the hbar/token owner'); +MessagesMap.set(HederaResponseCode.AMOUNT_EXCEEDS_ALLOWANCE, 'The transfer amount exceeds the current approved allowance for the spender account'); +MessagesMap.set(HederaResponseCode.MAX_ALLOWANCES_EXCEEDED, 'The payer account of an approveAllowances or adjustAllowance transaction is attempting to go beyond the maximum allowed number of allowances'); +MessagesMap.set(HederaResponseCode.EMPTY_ALLOWANCES, 'No allowances have been specified in the approval transaction'); +MessagesMap.set(HederaResponseCode.SPENDER_ACCOUNT_REPEATED_IN_ALLOWANCES, 'Spender is repeated more than once in Crypto or Token or NFT allowance lists in a single CryptoApproveAllowance transaction'); +MessagesMap.set(HederaResponseCode.REPEATED_SERIAL_NUMS_IN_NFT_ALLOWANCES, 'Serial numbers are repeated in NFT allowance for a single spender account'); MessagesMap.set(HederaResponseCode.FUNGIBLE_TOKEN_IN_NFT_ALLOWANCES, 'Fungible common token used in NFT allowances'); MessagesMap.set(HederaResponseCode.NFT_IN_FUNGIBLE_TOKEN_ALLOWANCES, 'Non fungible token used in fungible token allowances'); -MessagesMap.set(HederaResponseCode.INVALID_ALLOWANCE_OWNER_ID, 'The account id specified as the owner is invalid or does not exist.'); -MessagesMap.set(HederaResponseCode.INVALID_ALLOWANCE_SPENDER_ID, 'The account id specified as the spender is invalid or does not exist.'); -MessagesMap.set(HederaResponseCode.REPEATED_ALLOWANCES_TO_DELETE, 'If the CryptoDeleteAllowance transaction has repeated crypto or token or Nft allowances to delete.'); -MessagesMap.set(HederaResponseCode.INVALID_DELEGATING_SPENDER, 'If the account Id specified as the delegating spender is invalid or does not exist.'); -MessagesMap.set(HederaResponseCode.DELEGATING_SPENDER_CANNOT_GRANT_APPROVE_FOR_ALL, 'The delegating Spender cannot grant approveForAll allowance on a NFT token type for another spender.'); -MessagesMap.set(HederaResponseCode.DELEGATING_SPENDER_DOES_NOT_HAVE_APPROVE_FOR_ALL, 'The delegating Spender cannot grant allowance on a NFT serial for another spender as it doesnt not have approveForAll granted on token-owner.'); +MessagesMap.set(HederaResponseCode.INVALID_ALLOWANCE_OWNER_ID, 'The account id specified as the owner is invalid or does not exist'); +MessagesMap.set(HederaResponseCode.INVALID_ALLOWANCE_SPENDER_ID, 'The account id specified as the spender is invalid or does not exist'); +MessagesMap.set(HederaResponseCode.REPEATED_ALLOWANCES_TO_DELETE, 'If the CryptoDeleteAllowance transaction has repeated crypto or token or NFT allowances to delete'); +MessagesMap.set(HederaResponseCode.INVALID_DELEGATING_SPENDER, 'If the account Id specified as the delegating spender is invalid or does not exist'); +MessagesMap.set(HederaResponseCode.DELEGATING_SPENDER_CANNOT_GRANT_APPROVE_FOR_ALL, 'The delegating Spender cannot grant approveForAll allowance on a NFT token type for another spender'); +MessagesMap.set(HederaResponseCode.DELEGATING_SPENDER_DOES_NOT_HAVE_APPROVE_FOR_ALL, 'The delegating Spender cannot grant allowance on a NFT serial for another spender as it doesnt not have approveForAll granted on token-owner');