Skip to content

add custom type JsonString used in custom_json_operation

Marcin Sobczyk requested to merge msobczyk/fix-custom-json into master

It will be possible to use this field in other operations also (account_create_operation, account_update_operation, account_update2_operation, comment_operation, create_claimed_account_operation, escrow_transfer_operation).

JsonString can be loaded from string, for example: {"items":"4917e8d8f71176796adc28c3d8b3f3ce9335cfbb-0"],"price":"0.450020","currency":"DEC","market":"monstercardstore","app":"monstercardstore","n":"PJTGpteasj"} Transaction containing operation with this field can be loaded from string or dumped to string and json in this field is double encoded as string, for example: {"ref_block_num": 56723, "ref_block_prefix": 1609051118, "expiration": "2024-06-10T07:41:42", "extensions": [], "signatures": [], "operations": [{"type": "custom_json_operation", "value": {"required_auths": ["alice"], "required_posting_auths": [], "id": "abrakadabra", "json": "{"items":["4917e8d8f71176796adc28c3d8b3f3ce9335cfbb-0"],"price":"0.450020","currency":"DEC","market":"monstercardstore","app":"monstercardstore","n":"PJTGpteasj"}"}}]}

Merge request reports

Loading