Update Preferences¶
Use /communication-preferences to update communication preferences on your account.
URI¶
PUT /api/v1/customers/{customerId}/communication-preferences
Headers¶
| Parameter | Mandatory | Data Type | Allowed Values | Description |
|---|---|---|---|---|
| Request-Tracking-Id | Y | String | Unique Identifier for each request | |
| Authorization | Y | String | Access token | |
| ClientId | Y | String | Will be provided by WM | |
| Accept | N | String | application/json or application/xml | Default is application/json |
| Content-Type | Y | String | application/json | Content Type of the request |
Request Parameters¶
Pass the following parameters in the request.
| Parameter | Mandatory | Data Type | Type | Description |
|---|---|---|---|---|
| customerId | Y | Number | path | Unique Customer Identifier |
Request Fields¶
| Parameter | Data Type | Description |
|---|---|---|
| category | String | Preference category (Service Notification, Service Exception) |
| channels | Object | The Channels details |
| name | String | Channel(Text,Email,Voice) |
| selections | Object | The selections details |
| value | String | Email or Phone Number depending on selection type |
| type | String | Selection type gives type of selection (Ex. Billing Mobile,Service Email) |
| audit_info | Object | Contains audit info |
| modified_by | String | Preference Modified By |
Response Fields¶
| Parameter | Data Type | Description |
|---|---|---|
| request_tracking_id | String | Unique Identifier from request |
| status | String | Success if request is successfull |
Tip
For information about how to test, see How To Test
Sample Request¶
PUT https://api.wm.com/v1/customers/123456789/communication-preferences
Sample Request Body¶
{ "preferences": [ { "category": "Service Exception", "channels": [ { "name": "Text", "selections": [ { "value": "1233454567", "type": "BPHONE", "is_opt_in": "Y" } ] } ] } ] , "audit_info": { "modified_by": "johnm" }}
Sample Response¶
{ "status": "Success", "request_tracking_id": "12"}