From e68091be6672a507da0117aa0e09d7cf8e78c347 Mon Sep 17 00:00:00 2001 From: Rob Walworth Date: Thu, 23 May 2024 15:24:45 -0500 Subject: [PATCH] docs: add commonTransactionParams in anticipation of #209 being merged Signed-off-by: Rob Walworth --- .../accountUpdateTransaction.md | 222 ++++++++++-------- 1 file changed, 120 insertions(+), 102 deletions(-) diff --git a/test-specifications/crypto-service/accountUpdateTransaction.md b/test-specifications/crypto-service/accountUpdateTransaction.md index 9cbefbe..7c68f08 100644 --- a/test-specifications/crypto-service/accountUpdateTransaction.md +++ b/test-specifications/crypto-service/accountUpdateTransaction.md @@ -30,19 +30,19 @@ https://docs.hedera.com/hedera/sdks-and-apis/rest-api ### Input Parameters -| Parameter Name | Type | Required/Optional | Description/Notes | -|---------------------------|--------------|-------------------|--------------------------------------------------------------------------------------------------------------------------------------------| -| accountId | string | optional | The ID of the account to update. | -| key | string | optional | DER-encoded hex string representation for private or public keys. KeyLists and ThresholdKeys are the hex of the serialized protobuf bytes. | -| autoRenewPeriod | int64 | optional | Units of seconds | -| expirationTime | int64 | optional | Epoch time | -| receiverSignatureRequired | bool | optional | | -| memo | string | optional | | -| maxAutoTokenAssociations | int32 | optional | | -| stakedAccountId | string | optional | | -| stakedNodeId | int64 | optional | | -| declineStakingReward | bool | optional | | -| signerKeys | list | optional | List of DER-encoded hex strings of all additional private keys required to sign. | +| Parameter Name | Type | Required/Optional | Description/Notes | +|---------------------------|--------------------------------------------------|-------------------|--------------------------------------------------------------------------------------------------------------------------------------------| +| accountId | string | optional | The ID of the account to update. | +| key | string | optional | DER-encoded hex string representation for private or public keys. KeyLists and ThresholdKeys are the hex of the serialized protobuf bytes. | +| autoRenewPeriod | int64 | optional | Units of seconds | +| expirationTime | int64 | optional | Epoch time | +| receiverSignatureRequired | bool | optional | | +| memo | string | optional | | +| maxAutoTokenAssociations | int32 | optional | | +| stakedAccountId | string | optional | | +| stakedNodeId | int64 | optional | | +| declineStakingReward | bool | optional | | +| commonTransactionParams | [json object](../commonTransactionParameters.md) | optional | | ### Output Parameters @@ -60,11 +60,11 @@ The tests contained in this specification will assume that a valid account was a - The ID of the account to update. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|-----------------------------------------------------------------------------------|-------------------------------------------------------------------------------|---------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with no updates | accountId=, signerKeys=[] | The account update succeeds. | N | -| 2 | Updates an account with no updates without signing with the account's private key | accountId= | The account creation fails with an INVALID_SIGNATURE response code from the network. | N | -| 3 | Updates an account with no account ID | | The account creation fails with an INVALID_ACCOUNT_ID response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|-----------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with no updates | accountId=, commonTransactionParams.signers=[] | The account update succeeds. | N | +| 2 | Updates an account with no updates without signing with the account's private key | accountId= | The account creation fails with an INVALID_SIGNATURE response code from the network. | N | +| 3 | Updates an account with no account ID | | The account creation fails with an INVALID_ACCOUNT_ID response code from the network. | N | #### JSON Request Example @@ -95,17 +95,17 @@ The tests contained in this specification will assume that a valid account was a - The desired new key of the account. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|---------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with a new valid ED25519 public key | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new ED25519 key. | N | -| 2 | Updates an account with a new valid ECDSAsecp256k1 public key | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new ECDSAsecp256k1 key. | N | -| 3 | Updates an account with a new valid ED25519 private key | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new ED25519 key. | N | -| 4 | Updates an account with a new valid ECDSAsecp256k1 private key | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new ECDSAsecp256k1 key. | N | -| 5 | Updates an account with a new valid valid KeyList of ED25519 and ECDSAsecp256k1 private and public keys | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new KeyList. | N | -| 6 | Updates an account with a new valid KeyList of nested KeyLists (three levels) | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new nested KeyList. | N | -| 7 | Updates an account with a new valid ThresholdKey of ED25519 and ECDSAsecp256k1 private and public keys | accountId=, key=, signerKeys=[, ] | The account update succeeds and the account has the new ThresholdKey. | N | -| 8 | Updates an account with a new key without signing with the new key | accountId=, key=, signerKeys=[] | The account update fails with a INVALID_SIGNATURE response code from the network. | N | -| 9 | Updates an account with a new public key and signs with an incorrect private key | accountId=, key=, signerKeys=[, ] | The account update fails with response code INVALID_SIGNATURE | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|---------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with a new valid ED25519 public key | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new ED25519 key. | N | +| 2 | Updates an account with a new valid ECDSAsecp256k1 public key | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new ECDSAsecp256k1 key. | N | +| 3 | Updates an account with a new valid ED25519 private key | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new ED25519 key. | N | +| 4 | Updates an account with a new valid ECDSAsecp256k1 private key | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new ECDSAsecp256k1 key. | N | +| 5 | Updates an account with a new valid valid KeyList of ED25519 and ECDSAsecp256k1 private and public keys | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new KeyList. | N | +| 6 | Updates an account with a new valid KeyList of nested KeyLists (three levels) | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new nested KeyList. | N | +| 7 | Updates an account with a new valid ThresholdKey of ED25519 and ECDSAsecp256k1 private and public keys | accountId=, key=, commonTransactionParams.signers=[, ] | The account update succeeds and the account has the new ThresholdKey. | N | +| 8 | Updates an account with a new key without signing with the new key | accountId=, key=, commonTransactionParams.signers=[] | The account update fails with a INVALID_SIGNATURE response code from the network. | N | +| 9 | Updates an account with a new public key and signs with an incorrect private key | accountId=, key=, commonTransactionParams.signers=[, ] | The account update fails with response code INVALID_SIGNATURE | N | #### JSON Request Example @@ -117,10 +117,12 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.768", "key": "302A300506032B6570032100EA746B07CFA75F9273BDC3F2495A43DE15720719DA6ED70AEC2D829ACC6A4ECD", - "signerKeys": [ - "302E020100300506032B657004220420DE6788D0A09F20DED806F446C02FB929D8CD8D17022374AFB3739A1D50BA72C8", - "302E020100300506032B657004220420C212D124233D70BA8F6F07BF01A44E98418799E3F8ABD2B42C69EC03B53A4E1B" - ] + "commonTransactionParams": { + "signers": [ + "302E020100300506032B657004220420DE6788D0A09F20DED806F446C02FB929D8CD8D17022374AFB3739A1D50BA72C8", + "302E020100300506032B657004220420C212D124233D70BA8F6F07BF01A44E98418799E3F8ABD2B42C69EC03B53A4E1B" + ] + } } } ``` @@ -141,14 +143,14 @@ The tests contained in this specification will assume that a valid account was a - The desired new auto-renew period for the account. The account is charged to extend its expiration date every ‘this many’ seconds. If it doesn't have enough balance, it extends as long as possible. If it is empty when it expires, then it is deleted. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with an auto renew period set to 60 days (5,184,000 seconds) | accountId=, autoRenewPeriod=5184000, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 5,184,000 seconds. | N | -| 2 | Updates an account with an auto renew period set to -1 seconds | accountId=, autoRenewPeriod=-1, signerKeys=[] | The account update fails with an INVALID_RENEWAL_PERIOD response code from the network. | N | -| 3 | Updates an account with an auto renew period set to the minimum period of 30 days (2,592,000 seconds) | accountId=, autoRenewPeriod=2592000, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 2,592,000 seconds. | N | -| 4 | Updates an account with an auto renew period set to the minimum period of 30 days minus one second (2,591,999 seconds) | accountId=, autoRenewPeriod=2591999, signerKeys=[] | The account update fails with an AUTORENEW_DURATION_NOT_IN_RANGE response code from the network. | N | -| 5 | Updates an account with an auto renew period set to the maximum period of 8,000,001 seconds | accountId=, autoRenewPeriod=8000001, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 8,000,001 seconds. | N | -| 6 | Updates an account with an auto renew period set to the maximum period plus one seconds (8,000,002 seconds) | accountId=, autoRenewPeriod=8000002, signerKeys=[] | The account update fails with an AUTORENEW_DURATION_NOT_IN_RANGE response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with an auto renew period set to 60 days (5,184,000 seconds) | accountId=, autoRenewPeriod=5184000, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 5,184,000 seconds. | N | +| 2 | Updates an account with an auto renew period set to -1 seconds | accountId=, autoRenewPeriod=-1, commonTransactionParams.signers=[] | The account update fails with an INVALID_RENEWAL_PERIOD response code from the network. | N | +| 3 | Updates an account with an auto renew period set to the minimum period of 30 days (2,592,000 seconds) | accountId=, autoRenewPeriod=2592000, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 2,592,000 seconds. | N | +| 4 | Updates an account with an auto renew period set to the minimum period of 30 days minus one second (2,591,999 seconds) | accountId=, autoRenewPeriod=2591999, commonTransactionParams.signers=[] | The account update fails with an AUTORENEW_DURATION_NOT_IN_RANGE response code from the network. | N | +| 5 | Updates an account with an auto renew period set to the maximum period of 8,000,001 seconds | accountId=, autoRenewPeriod=8000001, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 8,000,001 seconds. | N | +| 6 | Updates an account with an auto renew period set to the maximum period plus one seconds (8,000,002 seconds) | accountId=, autoRenewPeriod=8000002, commonTransactionParams.signers=[] | The account update fails with an AUTORENEW_DURATION_NOT_IN_RANGE response code from the network. | N | #### JSON Request Example @@ -160,9 +162,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.32511", "autoRenewPeriod": 5184000, - "signerKeys": [ - "302E020100300506032B657004220420DE6788D0A09F20DED806F446C02FB929D8CD8D17022374AFB3739A1D50BA72C8" - ] + "commonTransactionParams": { + "signers": [ + "302E020100300506032B657004220420DE6788D0A09F20DED806F446C02FB929D8CD8D17022374AFB3739A1D50BA72C8" + ] + } } } ``` @@ -183,14 +187,14 @@ The tests contained in this specification will assume that a valid account was a - The desired new expiration time of the account. This is the time at which the account will expire and attempt to extend its expiration date. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|----------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with an expiration time set to 60 days (5,184,000 seconds) | accountId=, expirationTime=5184000, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 5,184,000 seconds. | N | -| 2 | Updates an account with an expiration time set to -1 seconds | accountId=, expirationTime=-1, signerKeys=[] | The account update fails with an EXPIRATION_REDUCTION_NOT_ALLOWED response code from the network. | N | -| 3 | Updates an account with an expiration time set to the minimum period of 30 days (2,592,000 seconds) | accountId=, expirationTime=2592000, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 2,592,000 seconds. | N | -| 4 | Updates an account with an expiration time set to the minimum period of 30 days minus one second (2,591,999 seconds) | accountId=, expirationTime=2591999, signerKeys=[] | The account update fails with an INVALID_EXPIRATION_TIME response code from the network. | N | -| 5 | Updates an account with an expiration time set to the maximum period of 8,000,001 seconds | accountId=, expirationTime=8000001, signerKeys=[] | The account update succeeds and the account's auto renew period should equal 8,000,001 seconds. | N | -| 6 | Updates an account with an expiration time set to the maximum period plus one seconds (8,000,002 seconds) | accountId=, expirationTime=8000002, signerKeys=[] | The account update fails with an INVALID_EXPIRATION_TIME response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|----------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with an expiration time set to 60 days (5,184,000 seconds) | accountId=, expirationTime=5184000, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 5,184,000 seconds. | N | +| 2 | Updates an account with an expiration time set to -1 seconds | accountId=, expirationTime=-1, commonTransactionParams.signers=[] | The account update fails with an EXPIRATION_REDUCTION_NOT_ALLOWED response code from the network. | N | +| 3 | Updates an account with an expiration time set to the minimum period of 30 days (2,592,000 seconds) | accountId=, expirationTime=2592000, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 2,592,000 seconds. | N | +| 4 | Updates an account with an expiration time set to the minimum period of 30 days minus one second (2,591,999 seconds) | accountId=, expirationTime=2591999, commonTransactionParams.signers=[] | The account update fails with an INVALID_EXPIRATION_TIME response code from the network. | N | +| 5 | Updates an account with an expiration time set to the maximum period of 8,000,001 seconds | accountId=, expirationTime=8000001, commonTransactionParams.signers=[] | The account update succeeds and the account's auto renew period should equal 8,000,001 seconds. | N | +| 6 | Updates an account with an expiration time set to the maximum period plus one seconds (8,000,002 seconds) | accountId=, expirationTime=8000002, commonTransactionParams.signers=[] | The account update fails with an INVALID_EXPIRATION_TIME response code from the network. | N | #### JSON Request Example @@ -202,9 +206,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.8993", "expirationTime": 5184000, - "signerKeys": [ - "302E020100300506032B657004220420C212D124233D70BA8F6F07BF01A44E98418799E3F8ABD2B42C69EC03B53A4E1B" - ] + "commonTransactionParams": { + "signers": [ + "302E020100300506032B657004220420C212D124233D70BA8F6F07BF01A44E98418799E3F8ABD2B42C69EC03B53A4E1B" + ] + } } } ``` @@ -225,10 +231,10 @@ The tests contained in this specification will assume that a valid account was a - The desired new receiver signature required policy for the account. If true, this account's key must sign any transaction depositing into this account (in addition to all withdrawals). -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|---------------------------------------------------------|----------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account to require a receiving signature | accountId=, receiverSignatureRequired=true, signerKeys=[] | The account creation succeeds and the account requires a receiving signature. | N | -| 2 | Updates an account to not require a receiving signature | accountId=, receiverSignatureRequired=false, signerKeys=[] | The account creation succeeds and the account doesn't require a receiving signature. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|---------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account to require a receiving signature | accountId=, receiverSignatureRequired=true, commonTransactionParams.signers=[] | The account creation succeeds and the account requires a receiving signature. | N | +| 2 | Updates an account to not require a receiving signature | accountId=, receiverSignatureRequired=false, commonTransactionParams.signers=[] | The account creation succeeds and the account doesn't require a receiving signature. | N | #### JSON Request Example @@ -240,9 +246,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.5483", "receiverSignatureRequired": true, - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ``` @@ -263,12 +271,12 @@ The tests contained in this specification will assume that a valid account was a - The desired new memo of the account (UTF-8 encoding max 100 bytes). -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|----------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with a memo that is a valid length | accountId=, memo="testmemo", signerKeys=[] | The account update succeeds and the account's memo equals “testmemo”. | N | -| 2 | Updates an account with a memo that is the minimum length | accountId=, memo="", signerKeys=[] | The account update succeeds and the account's memo is empty. | N | -| 3 | Updates an account with a memo that is the maximum length | accountId=, memo="This is a really long memo but it is still valid because it is 100 characters exactly on the money!!", signerKeys=[] | The account update succeeds and the account's memo equals "This is a really long memo but it is still valid because it is 100 characters exactly on the money!!". | N | -| 4 | Updates an account with a memo that exceeds the maximum length | accountId=, memo="This is a long memo that is not valid because it exceeds 100 characters and it should fail the test!!", signerKeys=[] | The account update fails with a MEMO_TOO_LONG response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|----------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with a memo that is a valid length | accountId=, memo="testmemo", commonTransactionParams.signers=[] | The account update succeeds and the account's memo equals “testmemo”. | N | +| 2 | Updates an account with a memo that is the minimum length | accountId=, memo="", commonTransactionParams.signers=[] | The account update succeeds and the account's memo is empty. | N | +| 3 | Updates an account with a memo that is the maximum length | accountId=, memo="This is a really long memo but it is still valid because it is 100 characters exactly on the money!!", commonTransactionParams.signers=[] | The account update succeeds and the account's memo equals "This is a really long memo but it is still valid because it is 100 characters exactly on the money!!". | N | +| 4 | Updates an account with a memo that exceeds the maximum length | accountId=, memo="This is a long memo that is not valid because it exceeds 100 characters and it should fail the test!!", commonTransactionParams.signers=[] | The account update fails with a MEMO_TOO_LONG response code from the network. | N | #### JSON Request Example @@ -280,9 +288,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.553", "memo": "testmemo", - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ``` @@ -303,12 +313,12 @@ The tests contained in this specification will assume that a valid account was a - The new desired max automatic token associations for the account. The maximum number of tokens with which an account can be implicitly associated. Defaults to 0 and up to a maximum value of 5000. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|--------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with a max token association that is a valid amount | accountId=, maxAutoTokenAssociations=100, signerKeys=[] | The account update succeeds and the account has 100 automatic token associations. | N | -| 2 | Updates an account with a max token association that is the minimum value | accountId=, maxAutoTokenAssociations=0, signerKeys=[] | The account update succeeds and the account has 0 automatic token associations. | N | -| 3 | Updates an account with a max token association that is the maximum value | accountId=, maxAutoTokenAssociations=5000, signerKeys=[] | The account update succeeds and the account has 5000 automatic token associations. | N | -| 4 | Updates an account with a max token association that exceeds the maximum value | accountId=, maxAutoTokenAssociations=5001, signerKeys=[] | The account update fails with a REQUESTED_NUM_AUTOMATIC_ASSOCIATIONS_EXCEEDS_ASSOCIATION_LIMIT response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|--------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with a max token association that is a valid amount | accountId=, maxAutoTokenAssociations=100, commonTransactionParams.signers=[] | The account update succeeds and the account has 100 automatic token associations. | N | +| 2 | Updates an account with a max token association that is the minimum value | accountId=, maxAutoTokenAssociations=0, commonTransactionParams.signers=[] | The account update succeeds and the account has 0 automatic token associations. | N | +| 3 | Updates an account with a max token association that is the maximum value | accountId=, maxAutoTokenAssociations=5000, commonTransactionParams.signers=[] | The account update succeeds and the account has 5000 automatic token associations. | N | +| 4 | Updates an account with a max token association that exceeds the maximum value | accountId=, maxAutoTokenAssociations=5001, commonTransactionParams.signers=[] | The account update fails with a REQUESTED_NUM_AUTOMATIC_ASSOCIATIONS_EXCEEDS_ASSOCIATION_LIMIT response code from the network. | N | #### JSON Request Example @@ -320,9 +330,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.53671", "maxAutoTokenAssociations": 100, - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ``` @@ -345,15 +357,15 @@ The tests contained in this specification will assume that a valid account was a - OR - The ID of the new desired node to which this account is staked. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|---------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account with the staked account ID set to the operators account ID | accountId=, stakedAccountId=, signerKeys=[] | The account update succeeds and the account has a staking account ID equal to the input account ID. | N | -| 2 | Updates an account with the staked node ID set to a valid node ID | accountId=, stakedNodeId=, signerKeys=[] | The account update succeeds and the account has a staking node ID equal to the input node ID. | N | -| 3 | Updates an account with the staked account ID set to an account ID that doesn't exist | accountId=, stakedAccountId="123.456.789", signerKeys=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | -| 4 | Updates an account with the staked node ID set to a node ID that doesn't exist | accountId=, stakedNodeId=123456789, signerKeys=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | -| 5 | Updates an account with the staked account ID set to an empty account ID | accountId=, stakedAccountId="", signerKeys=[] | The account update fails with and SDK internal error. | N | -| 6 | Updates an account with the staked node ID set to an invalid node ID | accountId=, stakedNodeId=-100, signerKeys=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | -| 7 | Updates an account with a staked account ID and a staked node ID | accountId=, stakedAccountId=, stakedNodeId=, signerKeys=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|---------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account with the staked account ID set to the operators account ID | accountId=, stakedAccountId=, commonTransactionParams.signers=[] | The account update succeeds and the account has a staking account ID equal to the input account ID. | N | +| 2 | Updates an account with the staked node ID set to a valid node ID | accountId=, stakedNodeId=, commonTransactionParams.signers=[] | The account update succeeds and the account has a staking node ID equal to the input node ID. | N | +| 3 | Updates an account with the staked account ID set to an account ID that doesn't exist | accountId=, stakedAccountId="123.456.789", commonTransactionParams.signers=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | +| 4 | Updates an account with the staked node ID set to a node ID that doesn't exist | accountId=, stakedNodeId=123456789, commonTransactionParams.signers=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | +| 5 | Updates an account with the staked account ID set to an empty account ID | accountId=, stakedAccountId="", commonTransactionParams.signers=[] | The account update fails with and SDK internal error. | N | +| 6 | Updates an account with the staked node ID set to an invalid node ID | accountId=, stakedNodeId=-100, commonTransactionParams.signers=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | +| 7 | Updates an account with a staked account ID and a staked node ID | accountId=, stakedAccountId=, stakedNodeId=, commonTransactionParams.signers=[] | The account update fails with an INVALID_STAKING_ID response code from the network. | N | #### JSON Request Examples @@ -365,9 +377,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.7388", "stakedAccountId": "0.0.3", - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ``` @@ -380,9 +394,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.7388", "stakedNodeId": 10, - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ``` @@ -403,10 +419,10 @@ The tests contained in this specification will assume that a valid account was a - The new desired decline rewards policy for the account. If true, the account declines receiving a staking reward. -| Test no | Name | Input | Expected response | Implemented (Y/N) | -|---------|---------------------------------------------------------|------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------|-------------------| -| 1 | Updates an account that declines staking rewards | accountId=, declineStakingRewards=true, signerKeys=[] | The account update succeeds and the account declines staking rewards. | N | -| 2 | Updates an account that doesn't decline staking rewards | accountId=, declineStakingRewards=false, signerKeys=[] | The account update succeeds and the account doesn't decline staking rewards. | N | +| Test no | Name | Input | Expected response | Implemented (Y/N) | +|---------|---------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------|-------------------| +| 1 | Updates an account that declines staking rewards | accountId=, declineStakingRewards=true, commonTransactionParams.signers=[] | The account update succeeds and the account declines staking rewards. | N | +| 2 | Updates an account that doesn't decline staking rewards | accountId=, declineStakingRewards=false, commonTransactionParams.signers=[] | The account update succeeds and the account doesn't decline staking rewards. | N | #### JSON Request Example @@ -418,9 +434,11 @@ The tests contained in this specification will assume that a valid account was a "params": { "accountId": "0.0.983", "declineStakingRewards": true, - "signerKeys": [ - "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" - ] + "commonTransactionParams": { + "signers": [ + "302e020100300506032b65700422042031f8eb3e77a04ebe599c51570976053009e619414f26bdd39676a5d3b2782a1d" + ] + } } } ```