Defining Application Contacts (Messenger Connect)
|Current information about Live Connect is now available in the Windows Live Developer Center. The information in the following sections is provided for legacy purposes only.|
In this topic, you learn how to define application contacts for your application.
You can define application contacts in the following ways.
Set an Application Contact List (Messenger Connect) in the app-contacts tag of the Windows Live Messenger UI Controls.
Create and modify the Application Contact List (Messenger Connect) with the SetContacts, AddContacts, and RemoveContacts methods of the Microsoft.Live.Messenger.Applications.ApplicationContactCollection class.
For definitions of the application contact list and application contact list signature, see Application Contact List (Messenger Connect).
By default, you must sign the application contact list with the Messenger Application Key (Messenger Connect). If you omit application contact list signatures in your application as described in Messenger Application Key (Messenger Connect), then you can also define application contacts in the following ways.
An application can define application contacts, regardless of whether the application web site visitor is an authenticated Windows Live Messenger Web Toolkit user. If the site visitor is signed in on the site with the Windows Live Messenger Web Toolkit, then the application operates in User Authenticated Mode. If the visitor is an unknown user, or the user is not signed in, then the application operates in Application Authenticated Mode. Application Authenticated Mode enables sites to display user profile information to anonymous users.
The application contact list is accessed differently depending on the mode.
If the application is in User Authenticated Mode, the application contact list is available as the User.ApplicationContacts collection.
If the application is in Application Authenticated Mode, the application contact list is available as the Application.ApplicationContact collection.
For more details, see Application Authenticated Mode (Messenger Connect).
For a signed-in user, an application can designate a Windows Live contact as an application contact. For example, users A and B may be Messenger contacts, and they may be friends on a social networking web site. In this case, the web site can make A and B application contacts. If user A adds user B as an application contact, B appears in both the User.Contacts and User.ApplicationContacts collections. If B is not a Windows Live contact, B appears only in the User.ApplicationContacts collection.