UpdateEmailAddressOfSNSEmailEndpoint
API Request
URLs
PUT zstack/v1/sns/application-endpoints/emails/email-addressesHeaders
Authorization: OAuth the-session-uuidBody
Note: In
the preceding sample, both systemTags and userTags are optional.
These two fields can be included in the body structure.
{
"updateEmailAddressOfSNSEmailEndpoint": {
"emailAddressUuid": "cb2b3d85e0da3a299c52c23510ba15dd",
"endpointUuid": "f305528eb6773a73beac3f94f79d3017",
"emailAddress": "example@zstack.io"
},
"systemTags": [],
"userTags": []
}
Note: In
the preceding sample, both systemTags and userTags are optional.
These two fields can be included in the body structure.Curl
Sample
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X PUT -d '{"updateEmailAddressOfSNSEmailEndpoint":{"emailAddressUuid":"cb2b3d85e0da3a299c52c23510ba15dd","endpointUuid":"f305528eb6773a73beac3f94f79d3017","emailAddress":"example@zstack.io"}}' http://localhost:8080/zstack/v1/sns/application-endpoints/emails/email-addressesRequest Parameters
| Name | Type | Location | Description | Optional Value | Starting Version |
|---|---|---|---|---|---|
| emailAddressUuid | String | body (contained in the updateEmailAddressOfSNSEmailEndpoint structure) | The email address UUID. | 5.0.0 | |
| endpointUuid | String | body (contained in the updateEmailAddressOfSNSEmailEndpoint structure) | The endpoint UUID. | 5.0.0 | |
| emailAddress | String | body (contained in the updateEmailAddressOfSNSEmailEndpoint structure) | The address of the new email. | 5.0.0 | |
| systemTags | List | body | Optional. The system tags. | 3.7.0 | |
| userTags | List | body | Optional. The user tags. | 3.7.0 |
API Response
Sample
Response
{
"inventory": {
"uuid": "4d5bf84154764c9fb6e91c6739081bcf",
"emailAddress": "example@zstack.io",
"endpointUuid": "aac215a1d95d43c4ba4cad7ed3ad1670",
"createDate": "Dec 25, 2023 2:07:43 PM",
"lastOpDate": "Dec 25, 2023 2:07:43 PM"
}
}| Name | Type | Description | Starting Version |
|---|---|---|---|
| success | boolean | 5.0.0 | |
| error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 3.7.0 |
| inventory | SNSEmailAddressInventory | See inventory. | 3.7.0 |
#error
| Name | Type | Description | Starting Version |
|---|---|---|---|
| code | String | The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. | 3.7.0 |
| description | String | The brief description of the error. | 3.7.0 |
| details | String | The details about the error. | 3.7.0 |
| elaboration | String | The reserved field. Default value: null. | 3.7.0 |
| opaque | LinkedHashMap | The reserved field. Default value: null. | 3.7.0 |
| cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 3.7.0 |
#inventory
| Name | Type | Description | Starting Version |
|---|---|---|---|
| uuid | String | The resource UUID. | 3.7.0 |
| emailAddress | String | 3.7.0 | |
| endpointUuid | String | 3.7.0 | |
| createDate | Timestamp | The creation date. | 5.0.0 |
| lastOpDate | Timestamp | The last operation date. | 5.0.0 |
SDK Sample
Java
SDK
UpdateEmailAddressOfSNSEmailEndpointAction action = new UpdateEmailAddressOfSNSEmailEndpointAction();
action.emailAddressUuid = "cb2b3d85e0da3a299c52c23510ba15dd";
action.endpointUuid = "f305528eb6773a73beac3f94f79d3017";
action.emailAddress = "example@zstack.io";
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
UpdateEmailAddressOfSNSEmailEndpointAction.Result res = action.call();Python
SDK
UpdateEmailAddressOfSNSEmailEndpointAction action = UpdateEmailAddressOfSNSEmailEndpointAction()
action.emailAddressUuid = "cb2b3d85e0da3a299c52c23510ba15dd"
action.endpointUuid = "f305528eb6773a73beac3f94f79d3017"
action.emailAddress = "example@zstack.io"
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
UpdateEmailAddressOfSNSEmailEndpointAction.Result res = action.call()