UNPKG

7.95 kBTypeScriptView Raw
1/**
2 * Container class for changed identities
3 */
4export interface ChangedIdentities {
5 /**
6 * Changed Identities
7 */
8 identities?: Identity[];
9 /**
10 * More data available, set to true if pagesize is specified.
11 */
12 moreData?: boolean;
13 /**
14 * Last Identity SequenceId
15 */
16 sequenceContext?: ChangedIdentitiesContext;
17}
18/**
19 * Context class for changed identities
20 */
21export interface ChangedIdentitiesContext {
22 /**
23 * Last Group SequenceId
24 */
25 groupSequenceId?: number;
26 /**
27 * Last Identity SequenceId
28 */
29 identitySequenceId?: number;
30 /**
31 * Last Group OrganizationIdentitySequenceId
32 */
33 organizationIdentitySequenceId?: number;
34 /**
35 * Page size
36 */
37 pageSize?: number;
38}
39export interface CreateScopeInfo {
40 adminGroupDescription?: string;
41 adminGroupName?: string;
42 creatorId?: string;
43 parentScopeId?: string;
44 scopeName?: string;
45 scopeType?: GroupScopeType;
46}
47export interface FrameworkIdentityInfo {
48 displayName?: string;
49 identifier?: string;
50 identityType?: FrameworkIdentityType;
51 role?: string;
52}
53export declare enum FrameworkIdentityType {
54 None = 0,
55 ServiceIdentity = 1,
56 AggregateIdentity = 2,
57 ImportedIdentity = 3
58}
59export interface GroupMembership {
60 active?: boolean;
61 descriptor?: IdentityDescriptor;
62 id?: string;
63 queriedId?: string;
64}
65export declare enum GroupScopeType {
66 Generic = 0,
67 ServiceHost = 1,
68 TeamProject = 2
69}
70export interface Identity extends IdentityBase {
71}
72/**
73 * Base Identity class to allow "trimmed" identity class in the GetConnectionData API Makes sure that on-the-wire representations of the derived classes are compatible with each other (e.g. Server responds with PublicIdentity object while client deserializes it as Identity object) Derived classes should not have additional [DataMember] properties
74 */
75export interface IdentityBase {
76 /**
77 * The custom display name for the identity (if any). Setting this property to an empty string will clear the existing custom display name. Setting this property to null will not affect the existing persisted value (since null values do not get sent over the wire or to the database)
78 */
79 customDisplayName?: string;
80 descriptor?: IdentityDescriptor;
81 /**
82 * Identity Identifier. Also called Storage Key, or VSID
83 */
84 id?: string;
85 /**
86 * True if the identity has a membership in any Azure Devops group in the organization.
87 */
88 isActive?: boolean;
89 /**
90 * True if the identity is a group.
91 */
92 isContainer?: boolean;
93 masterId?: string;
94 /**
95 * Id of the members of the identity (groups only).
96 */
97 memberIds?: string[];
98 memberOf?: IdentityDescriptor[];
99 members?: IdentityDescriptor[];
100 metaTypeId?: number;
101 properties?: any;
102 /**
103 * The display name for the identity as specified by the source identity provider.
104 */
105 providerDisplayName?: string;
106 resourceVersion?: number;
107 socialDescriptor?: string;
108 /**
109 * Subject descriptor of a Graph entity.
110 */
111 subjectDescriptor?: string;
112 uniqueUserId?: number;
113}
114export interface IdentityBatchInfo {
115 descriptors?: IdentityDescriptor[];
116 identityIds?: string[];
117 includeRestrictedVisibility?: boolean;
118 propertyNames?: string[];
119 queryMembership?: QueryMembership;
120 socialDescriptors?: string[];
121 subjectDescriptors?: string[];
122}
123/**
124 * An Identity descriptor is a wrapper for the identity type (Windows SID, Passport) along with a unique identifier such as the SID or PUID.
125 */
126export interface IdentityDescriptor {
127 /**
128 * The unique identifier for this identity, not exceeding 256 chars, which will be persisted.
129 */
130 identifier?: string;
131 /**
132 * Type of descriptor (for example, Windows, Passport, etc.).
133 */
134 identityType?: string;
135}
136export interface IdentityRightsTransferData {
137 userPrincipalNameMappings?: {
138 [key: string]: string;
139 };
140}
141export interface IdentityScope {
142 administrators?: IdentityDescriptor;
143 id: string;
144 isActive?: boolean;
145 isGlobal?: boolean;
146 localScopeId?: string;
147 name?: string;
148 parentId?: string;
149 scopeType?: GroupScopeType;
150 securingHostId?: string;
151 subjectDescriptor?: string;
152}
153/**
154 * Identity information.
155 */
156export interface IdentitySelf {
157 /**
158 * The UserPrincipalName (UPN) of the account. This value comes from the source provider.
159 */
160 accountName?: string;
161 /**
162 * The display name. For AAD accounts with multiple tenants this is the display name of the profile in the home tenant.
163 */
164 displayName?: string;
165 /**
166 * This represents the name of the container of origin. For AAD accounts this is the tenantID of the home tenant. For MSA accounts this is the string "Windows Live ID".
167 */
168 domain?: string;
169 /**
170 * This is the VSID of the home tenant profile. If the profile is signed into the home tenant or if the profile has no tenants then this Id is the same as the Id returned by the profile/profiles/me endpoint. Going forward it is recommended that you use the combined values of Origin, OriginId and Domain to uniquely identify a user rather than this Id.
171 */
172 id?: string;
173 /**
174 * The type of source provider for the origin identifier. For MSA accounts this is "msa". For AAD accounts this is "aad".
175 */
176 origin?: string;
177 /**
178 * The unique identifier from the system of origin. If there are multiple tenants this is the unique identifier of the account in the home tenant. (For MSA this is the PUID in hex notation, for AAD this is the object id.)
179 */
180 originId?: string;
181 /**
182 * For AAD accounts this is all of the tenants that this account is a member of.
183 */
184 tenants?: TenantInfo[];
185}
186export interface IdentitySnapshot {
187 groups?: Identity[];
188 identityIds?: string[];
189 memberships?: GroupMembership[];
190 scopeId?: string;
191 scopes?: IdentityScope[];
192}
193export interface IdentityUpdateData {
194 id?: string;
195 index?: number;
196 updated?: boolean;
197}
198export interface PagedIdentities {
199 continuationToken?: string[];
200 identities?: Identity[];
201}
202export declare enum QueryMembership {
203 /**
204 * Query will not return any membership data
205 */
206 None = 0,
207 /**
208 * Query will return only direct membership data
209 */
210 Direct = 1,
211 /**
212 * Query will return expanded membership data
213 */
214 Expanded = 2,
215 /**
216 * Query will return expanded up membership data (parents only)
217 */
218 ExpandedUp = 3,
219 /**
220 * Query will return expanded down membership data (children only)
221 */
222 ExpandedDown = 4
223}
224export declare enum ReadIdentitiesOptions {
225 None = 0,
226 FilterIllegalMemberships = 1
227}
228export interface SwapIdentityInfo {
229 id1?: string;
230 id2?: string;
231}
232export interface TenantInfo {
233 homeTenant?: boolean;
234 tenantId?: string;
235 tenantName?: string;
236 verifiedDomains?: string[];
237}
238export declare var TypeInfo: {
239 CreateScopeInfo: any;
240 FrameworkIdentityInfo: any;
241 FrameworkIdentityType: {
242 enumValues: {
243 none: number;
244 serviceIdentity: number;
245 aggregateIdentity: number;
246 importedIdentity: number;
247 };
248 };
249 GroupScopeType: {
250 enumValues: {
251 generic: number;
252 serviceHost: number;
253 teamProject: number;
254 };
255 };
256 IdentityBatchInfo: any;
257 IdentityScope: any;
258 IdentitySnapshot: any;
259 QueryMembership: {
260 enumValues: {
261 none: number;
262 direct: number;
263 expanded: number;
264 expandedUp: number;
265 expandedDown: number;
266 };
267 };
268 ReadIdentitiesOptions: {
269 enumValues: {
270 none: number;
271 filterIllegalMemberships: number;
272 };
273 };
274};