From 93f8cf1f6a9709fb7011ecb273cc6613dd40001e Mon Sep 17 00:00:00 2001 From: Miroslav Gatsanoga Date: Thu, 6 Jun 2024 00:07:45 +0300 Subject: [PATCH] feat: maxAutoAssociations updates for contract transactions (#359) Signed-off-by: Miroslav Gatsanoga --- services/contract_create.proto | 8 ++++++-- services/contract_update.proto | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/services/contract_create.proto b/services/contract_create.proto index e091f001..e5503368 100644 --- a/services/contract_create.proto +++ b/services/contract_create.proto @@ -167,8 +167,12 @@ message ContractCreateTransactionBody { string memo = 13; /** - * The maximum number of tokens that this contract can be automatically associated - * with (i.e., receive air-drops from). + * The maximum number of tokens that can be auto-associated with the contract.
+ * If this is less than or equal to `used_auto_associations`, or 0, then this contract + * MUST manually associate with a token before transacting in that token.
+ * This value MAY also be `-1` to indicate no limit.
+ * This value MUST NOT be less than `-1`.
+ * By default this value is 0 for contracts. */ int32 max_automatic_token_associations = 14; diff --git a/services/contract_update.proto b/services/contract_update.proto index 559fbdc0..cc8b714a 100644 --- a/services/contract_update.proto +++ b/services/contract_update.proto @@ -99,8 +99,12 @@ message ContractUpdateTransactionBody { } /** - * If set, the new maximum number of tokens that this contract can be - * automatically associated with (i.e., receive air-drops from). + * If set, modify the maximum number of tokens that can be auto-associated with the + * contract.
+ * If this is set and less than or equal to `used_auto_associations`, or 0, then this contract + * MUST manually associate with a token before transacting in that token.
+ * This value MAY also be `-1` to indicate no limit.
+ * This value MUST NOT be less than `-1`. */ google.protobuf.Int32Value max_automatic_token_associations = 11;