ProfileRestClient class
Basisklasse, die zum Senden von Anforderungen an VSS-REST-APIs verwendet werden soll (abgeleitet von).
- Extends
static RESOURCE_AREA_ID: string
Eigenschaftswert
string
Profil erstellen
function createProfile(createProfileContext: CreateProfileContext, autoCreate?: boolean): Promise<Profile>
Parameter
- createProfileContext
- CreateProfileContext
Kontext für die Profilerstellung
- autoCreate
-
boolean
Automatisches Erstellen eines Profils
Gibt zurück
Promise<Profile>
function deleteProfileAttribute(id: string, descriptor: string): Promise<void>
Parameter
- id
-
string
- descriptor
-
string
Gibt zurück
Promise<void>
function getAvatar(id: string, size?: string, format?: string): Promise<Avatar>
Parameter
- id
-
string
- size
-
string
- format
-
string
Gibt zurück
Promise<Avatar>
function getAvatarPreview(container: any, id: string, size?: string, format?: string, displayName?: string): Promise<Avatar>
Parameter
- container
-
any
- id
-
string
- size
-
string
- format
-
string
- displayName
-
string
Gibt zurück
Promise<Avatar>
Ruft ein Benutzerprofil ab.
function getProfile(id: string, details?: boolean, withAttributes?: boolean, partition?: string, coreAttributes?: string, forceRefresh?: boolean): Promise<Profile>
Parameter
- id
-
string
Die ID des Zielbenutzerprofils innerhalb desselben organization oder "ich", um das Profil des aktuell authentifizierten Benutzers abzurufen.
- details
-
boolean
Geben Sie öffentliche Profilinformationen wie Anzeigename, E-Mail-Adresse, Land usw. zurück. Wenn false, wird der withAttributes-Parameter ignoriert.
- withAttributes
-
boolean
Wenn true, ruft die Attribute (benannte Schlüssel-Wert-Paare beliebiger Daten) ab, die dem Profil zugeordnet sind. Der Partitionsparameter muss auch einen Wert aufweisen.
- partition
-
string
Die Partition (benannte Gruppe) von Attributen, die zurückgegeben werden sollen.
- coreAttributes
-
string
Eine durch Trennzeichen getrennte Liste der zurückzugebenden Hauptprofilattribute. Gültige Werte sind Email, Avatar, DisplayName und ContactWithOffers.
- forceRefresh
-
boolean
Wird in dieser Version der API nicht verwendet.
Gibt zurück
Promise<Profile>
function getProfileAttribute(id: string, descriptor: string): Promise<ProfileAttribute>
Parameter
- id
-
string
- descriptor
-
string
Gibt zurück
Promise<ProfileAttribute>
function getProfileAttributes(id: string, partition: string, modifiedSince?: string, modifiedAfterRevision?: string, withCoreAttributes?: boolean, coreAttributes?: string): Promise<ProfileAttribute[]>
Parameter
- id
-
string
- partition
-
string
- modifiedSince
-
string
- modifiedAfterRevision
-
string
- withCoreAttributes
-
boolean
- coreAttributes
-
string
Gibt zurück
Promise<ProfileAttribute[]>
function resetAvatar(id: string): Promise<void>
Parameter
- id
-
string
Gibt zurück
Promise<void>
function setAvatar(container: any, id: string): Promise<void>
Parameter
- container
-
any
- id
-
string
Gibt zurück
Promise<void>
function setProfileAttribute(container: any, id: string, descriptor: string): Promise<void>
Parameter
- container
-
any
- id
-
string
- descriptor
-
string
Gibt zurück
Promise<void>
function setProfileAttributes(attributesCollection: VssJsonCollectionWrapperV<ProfileAttributeBase<any>[]>, id: string): Promise<void>
Parameter
- attributesCollection
- id
-
string
Gibt zurück
Promise<void>
Update profile (Profil aktualisieren)
function updateProfile(profile: Profile, id: string): Promise<void>
Parameter
- profile
- Profile
Update profile (Profil aktualisieren)
- id
-
string
Profil-ID
Gibt zurück
Promise<void>