更新 TransactionAttributes
要修改存储的 TransactionAttributes
,使用新值更新 JSON 对象的内容。在以下示例中,密钥 NewKey1
和 NewKey2
已添加至 TransactionAttributes
。这些密钥分别与值 NewValue1
和 NewValue2
配对。
{ "SchemaVersion": "1.0", "Actions": [ { "Type": "PlayAudio", "Parameters": { "ParticipantTag": "
LEG-A
", "AudioSource": { "Type": "S3", "BucketName": "mtg1-sipmedia-app-iad
", "Key": "Welcome3.wav
" } } } ], "TransactionAttributes": { "NewKey1
": "NewValue1
", "NewKey2
": "NewValue2
" } }
在前面的示例中,如果您将 NewValue1
传递给 key1
,则 key1
的现有值将被替换为 NewValue1
。但是,将值传递给 NewKey1
会创建新的密钥/值对。