UserProfileService Web Service

The User Profile Service Web service namespace is an arbitrary name for a reference to the UserProfileService.asmx Web service in Microsoft Office SharePoint Server 2007.

The UserProfileService class in the Web service includes methods to manage user profiles. For example, to add a link to the My Links page on the My Site for the specified account name, you use the AddLink method of the UserProfileService class. To remove a colleague from the My Colleagues page for the specified account name, you use the RemoveColleague method.

You can also use the relevant properties of various classes in the User Profile Service Web service namespace to get or set a particular property. For example, to get or set common memberships that two user profiles share, you use the Memberships property in the InCommonData class. To specify or determine whether a property value was changed for a particular user profile property, you use the IsValueChanged property of the PropertyData class.

The User Profile Service Web service provides a user profile interface for remote clients to read and create user profiles. To use the User Profile Service Web service library, you must generate a proxy class in either Microsoft Visual C# or Microsoft Visual Basic through which you can call the various Web service methods.

The Web Services Description Language (WSDL) for the User Profile Service Web service endpoint is accessed through UserProfileService.asmx?wsdl.

The following example shows the format of the URL to the User Profile Service Web service WSDL file.

http://<server>/<customsite>/_vti_bin/UserProfileService.asmx

If you do not have a custom site, you can use the following URL.

http://<server>/_vti_bin/UserProfileService.asmx

It is recommended that you create a custom site, and then use the URL that includes the custom site in the URL format.

The following table describes each element in the URL.

URL element

Description

server

The name of the server on which Microsoft Office SharePoint Server 2007 is deployed.

customsite

A custom Office SharePoint Server 2007 site that the server administrator creates.

<endpointname>.asmx

The name of the Web service endpoint. For the User Profile Service Web service, it is UserProfileService.asmx.

For more information about the WSDL format, see the World Wide Web Consortium (W3C) WSDL Specification.

Classes

  Class Description
Public class ContactData Represents a user profile contact that contains information about the contact.
Public class GetUserProfileByIndexResult Represents information about a user profile.
Public class InCommonData Represents the colleagues, memberships, and manager data in common between two user profiles.
Public class MemberGroupData Represents information about a member group.
Public class MembershipData Contains information about a membership.
Public class OrganizationProfileData Represents an organization.
Public class PinnedLinkData Represents information about a pinned link.
Public class PropertyData Contains user profile property information.
Public class PropertyInfo Represents the information about a user profile property.
Public class QuickLinkData Represents the information about a quick link.
Public class SPTimeZone Represents the time zone setting that is implemented on a SharePoint 2010 website.
Public class UserProfileService Provides a Web service to manage user profiles.
Public class ValueData Represents the value of a property for a user profile.

Enumerations

  Enumeration Description
Public enumeration ChoiceTypes Defines the type of choice list for a user profile property.
Public enumeration MembershipSource Represents the source of a member group involved in a particular membership.
Public enumeration Privacy Represents the privacy level that specifies the set of users who are allowed to access a protected resource.
Public enumeration SuggestionType Specifies the type of suggestion.