PUT api/Mail/{service_handle}/Contact?user={user}
Update one or more of the mail service contacts
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| service_handle |
Mail service handle |
string |
Required |
| user |
Optional user handle - if empty logged in user will be used |
string |
None. |
Body Parameters
New list of contacts - Handle and Type required.
Collection of UpdateContactToService| Name | Description | Type | Additional information |
|---|---|---|---|
| Handle |
Contact handle |
string |
Required |
| Type |
Contact type: |
string |
Required Matching regular expression pattern: A|B |
Request Formats
application/json, text/json
[
{
"Handle": "sample string 1",
"Type": "sample string 2"
},
{
"Handle": "sample string 1",
"Type": "sample string 2"
}
]
application/xml, text/xml
<ArrayOfUpdateContactToService xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models.Services">
<UpdateContactToService>
<Handle>sample string 1</Handle>
<Type>sample string 2</Type>
</UpdateContactToService>
<UpdateContactToService>
<Handle>sample string 1</Handle>
<Type>sample string 2</Type>
</UpdateContactToService>
</ArrayOfUpdateContactToService>
application/x-www-form-urlencoded
Response Information
Resource Description
Return codes
200 - ok
400 - bad request
401 - unauthorized
404 - not found
500 - internal server error
| Name | Description | Type | Additional information |
|---|---|---|---|
| Code |
Error code |
integer |
None. |
| Detail |
Error description |
string |
None. |
| Data |
Additional information |
Object |
None. |
Response Formats
application/json, text/json
[
{
"Code": 1,
"Detail": "sample string 2",
"Data": {}
},
{
"Code": 1,
"Detail": "sample string 2",
"Data": {}
}
]
application/xml, text/xml
<ArrayOfError xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Namebay.Rest.Api.Models">
<Error>
<Code>1</Code>
<Data />
<Detail>sample string 2</Detail>
</Error>
<Error>
<Code>1</Code>
<Data />
<Detail>sample string 2</Detail>
</Error>
</ArrayOfError>