2024-10-30 17:33:59 -04:00
|
|
|
# Introduction
|
|
|
|
`DeleteMember` is one of the SOAP actions the [Contact Sharing Service](../sharingservice.md) provides.
|
|
|
|
|
2024-11-20 16:19:42 -05:00
|
|
|
Deletes a member from the Allow List (AL), Block List (BL), or the Pending List (PL).
|
|
|
|
To delete a contact from the Forward List (FL), read the [`ABContactDelete`](../sharingservice/abcontactdelete.md) article.
|
2024-10-30 17:33:59 -04:00
|
|
|
|
|
|
|
# Client/Request
|
|
|
|
The template used in this action is described on the [Address Book Service](../abservice.md) main page.
|
|
|
|
|
|
|
|
## DeleteMember
|
|
|
|
This element has only one attribute:
|
|
|
|
* `xmlns:` Is always set to `http://www.msn.com/webservices/AddressBook`.
|
|
|
|
|
|
|
|
### serviceHandle
|
|
|
|
This element contains three children:
|
|
|
|
* `<Id>`: This is always set to `0`.
|
2024-11-19 15:23:28 -05:00
|
|
|
* `<Type>`: The type of this member:
|
|
|
|
* `Messenger`: This is a Messenger contact.
|
|
|
|
* `Profile`: This is your profile.
|
|
|
|
* `<ForeignId>`: If `<Type>` is `Profile`, this should be `MyProfile`,
|
|
|
|
otherwise leave empty but do not convert to an empty element.
|
2024-10-30 17:33:59 -04:00
|
|
|
|
|
|
|
### memberships
|
|
|
|
This element only contains `<Membership>` elements.
|
|
|
|
|
|
|
|
#### Membership
|
|
|
|
This element contains two children:
|
|
|
|
* `<MemberRole>`: The type of list:
|
2024-11-19 15:23:28 -05:00
|
|
|
* `Allow`: The Allow List (AL).
|
|
|
|
* `Block`: The Block List (BL).
|
|
|
|
* `Pending`: The Pending List (RL).
|
|
|
|
* `ProfileExpression`: Your profile.
|
2024-10-30 17:33:59 -04:00
|
|
|
* `<Members>`: Explained below.
|
|
|
|
|
|
|
|
##### Members
|
|
|
|
This element only contains `<Member>` elements.
|
|
|
|
|
|
|
|
###### Member
|
|
|
|
This element has two attributes:
|
|
|
|
* `xsi:type`: The type of this `<Member>`:
|
2024-11-19 15:23:28 -05:00
|
|
|
* `PassportMember`
|
|
|
|
* `EmailMember`
|
|
|
|
* `PhoneMember`
|
|
|
|
* `RoleMember`: Only valid for `ProfileExpression`.
|
2024-10-30 17:33:59 -04:00
|
|
|
* `xmlns:xsi`: This is always set to `http://www.w3.org/2001/XMLSchema-instance`.
|
|
|
|
|
|
|
|
This element contains three children:
|
|
|
|
* `<Type>`: The type of this `<Member>`:
|
2024-11-19 15:23:28 -05:00
|
|
|
* `Passport`
|
|
|
|
* `Email`
|
|
|
|
* `Phone`
|
2024-10-30 17:33:59 -04:00
|
|
|
* `<MembershipId>`: The ID of the membership you would like to delete.
|
|
|
|
* `<State>`: This is usually only set to `Accepted`, but `Pending` is a valid value.
|
2024-11-19 15:23:28 -05:00
|
|
|
* `<Deleted>`: Should this member be deleted? (Only set to `true` in `UpdateMember`?)
|
|
|
|
|
|
|
|
This element may instead contain one of the following mutually exclusive children instead of `<MembershipId>`:
|
|
|
|
1. `<PassportName>`: The user handle associated with this membership.
|
|
|
|
2. `<Email>`: The e-mail address associated with this membership.
|
|
|
|
3. `<PhoneNumber>`: The phone number associated with this membership.
|
|
|
|
|
|
|
|
This element also contains the following children IF the role is set to `ProfileExpression`:
|
|
|
|
* `<Id>`: Always `Allow`.
|
|
|
|
* `<DefiningService>`: Contains the following:
|
|
|
|
* `<Id>`: Always `0`.
|
|
|
|
* `<Type>`: Always `Messenger`.
|
|
|
|
* `<ForeignId>`: Always empty content, but not an empty element.
|
|
|
|
* `<MaxRoleRecursionDepth>`: Always `0`.
|
|
|
|
* `<MaxDegreesSeparationDepth>`: Always `0`.
|
2024-10-30 17:33:59 -04:00
|
|
|
|
|
|
|
# Server/Response
|
|
|
|
The template used in this action is described on the [Address Book Service](../abservice.md) main page.
|
|
|
|
|
|
|
|
## DeleteMemberResponse
|
|
|
|
This empty element has only one attribute:
|
|
|
|
* `xmlns:` Is always set to `http://www.msn.com/webservices/AddressBook`.
|
2024-11-19 15:23:28 -05:00
|
|
|
|
|
|
|
# Examples
|
|
|
|
|
|
|
|
## Client/Request
|
|
|
|
```
|
|
|
|
POST /abservice/SharingService.asmx HTTP/1.1
|
|
|
|
SOAPAction: http://www.msn.com/webservices/AddressBook/DeleteMember
|
|
|
|
Cache-Control: no-cache
|
|
|
|
Content-Type: text/xml; charset=utf-8
|
2024-11-20 16:19:42 -05:00
|
|
|
Content-Length: 1438
|
2024-11-19 15:23:28 -05:00
|
|
|
|
|
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
|
|
<soap:Envelope
|
|
|
|
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
|
|
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
|
|
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
|
|
|
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
|
|
|
|
>
|
|
|
|
<soap:Header>
|
|
|
|
<ABApplicationHeader
|
|
|
|
xmlns="http://www.msn.com/webservices/AddressBook"
|
|
|
|
>
|
|
|
|
<ApplicationID>996CDE1E-AA53-4477-B943-2BE802EA6166</ApplicationID>
|
|
|
|
<IsMigration>false</IsMigration>
|
|
|
|
<PartnerScenario>Timer</PartnerScenario>
|
|
|
|
</ABApplicationHeader>
|
|
|
|
<ABAuthHeader
|
|
|
|
xmlns="http://www.msn.com/webservices/AddressBook"
|
|
|
|
>
|
|
|
|
<ManagedGroupRequest>false</ManagedGroupRequest>
|
|
|
|
<TicketToken>t=ticket&p=profile</TicketToken>
|
|
|
|
</ABAuthHeader>
|
|
|
|
</soap:Header>
|
|
|
|
<soap:Body>
|
|
|
|
<DeleteMember
|
|
|
|
xmlns="http://www.msn.com/webservices/AddressBook"
|
|
|
|
>
|
|
|
|
<serviceHandle>
|
|
|
|
<Id>0</Id>
|
|
|
|
<Id>Messenger</Id>
|
|
|
|
<ForeignId></ForeignId>
|
|
|
|
</serviceHandle>
|
|
|
|
<memberships>
|
|
|
|
<Membership>
|
|
|
|
<MemberRole>Allow</MemberRole>
|
|
|
|
<Members>
|
|
|
|
<Member
|
|
|
|
xsi:type="PassportMember"
|
|
|
|
>
|
|
|
|
<Type>Passport</Type>
|
|
|
|
<State>Accepted</State>
|
|
|
|
<PassportName>anotheruser@hotmail.com</PassportName>
|
|
|
|
</Member>
|
|
|
|
</Members>
|
|
|
|
</Membership>
|
|
|
|
</memberships>
|
2024-11-20 16:19:42 -05:00
|
|
|
</DeleteMember>
|
2024-11-19 15:23:28 -05:00
|
|
|
</soap:Body>
|
|
|
|
</soap:Envelope>
|
|
|
|
```
|
|
|
|
|
|
|
|
## Server/Response
|
|
|
|
```
|
|
|
|
HTTP/1.1 200 OK
|
|
|
|
Content-Type: text/xml
|
2024-11-20 16:19:42 -05:00
|
|
|
Content-Length: 771; charset=utf-8
|
2024-11-19 15:23:28 -05:00
|
|
|
|
|
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
|
|
<soap:Envelope
|
|
|
|
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
|
|
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
|
|
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
|
|
|
>
|
|
|
|
<soap:Header>
|
|
|
|
<ServiceHeader
|
|
|
|
xmlns="http://www.msn.com/webservices/AddressBook"
|
|
|
|
>
|
|
|
|
<Version>12.01.1111.0000</Version>
|
|
|
|
<CacheKey>12r1;MjAyNC0xMS0xOVQxNzo0ODowOS44MDNa</CacheKey>
|
|
|
|
<CacheKeyChanged>true</CacheKeyChanged>
|
|
|
|
<PreferredHostName>contacts.example.com</PreferredHostName>
|
|
|
|
<SessionId>ecfaf8c7-e388-4571-8641-b061a0ac4bdc</SessionId>
|
|
|
|
</ServiceHeader>
|
|
|
|
</soap:Header>
|
|
|
|
<soap:Body>
|
|
|
|
<DeleteMemberResponse
|
|
|
|
xmlns="http://www.msn.com/webservices/AddressBook"
|
|
|
|
/>
|
|
|
|
</soap:Body>
|
|
|
|
</soap:Envelope>
|
|
|
|
```
|