Options
All
  • Public
  • Public/Protected
  • All
Menu

Class UsersApi

Hierarchy

  • UsersApi

Index

Constructors

constructor

  • new UsersApi(basePath?: string): UsersApi

Properties

Protected basePath

basePath: string = "https://dev.azure.com/"

defaultHeaders

defaultHeaders: any

Methods

createUser

  • createUser(params: object, extraQueryParams?: any, extraFetchParams?: any): Promise<GraphUser>
  • Materialize an existing AAD or MSA user into the VSTS account. NOTE: Created users are not active in an account unless they have been explicitly assigned a parent group at creation time or have signed in and been autolicensed through AAD group memberships. Adding a user to an account is required before the user can be added to VSTS groups or assigned an asset. The body of the request must be a derived type of GraphUserCreationContext: * GraphUserMailAddressCreationContext - Create a new user using the mail address as a reference to an existing user from an external AD or AAD backed provider. * GraphUserOriginIdCreationContext - Create a new user using the OriginID as a reference to an existing user from an external AD or AAD backed provider. * GraphUserPrincipalNameCreationContext - Create a new user using the principal name as a reference to an existing user from an external AD or AAD backed provider. If the user to be added corresponds to a user that was previously deleted, then that user will be restored. Optionally, you can add the newly created user as a member of an existing VSTS group and/or specify a custom storage key for the user.

    Parameters

    • params: object
    • Optional extraQueryParams: any
    • Optional extraFetchParams: any

    Returns Promise<GraphUser>

deleteUser

  • deleteUser(params: object, extraQueryParams?: any, extraFetchParams?: any): Promise<__type>
  • Disables a user. The user will still be visible, but membership checks for the user will return false.”

    Parameters

    • params: object
      • apiVersion: string
      • organization: string
      • userDescriptor: string
    • Optional extraQueryParams: any
    • Optional extraFetchParams: any

    Returns Promise<__type>

getUser

  • getUser(params: object, extraQueryParams?: any, extraFetchParams?: any): Promise<GraphUser>
  • Get a user by its descriptor.

    Parameters

    • params: object
      • apiVersion: string
      • organization: string
      • userDescriptor: string
    • Optional extraQueryParams: any
    • Optional extraFetchParams: any

    Returns Promise<GraphUser>

listUsers

  • listUsers(params: object, extraQueryParams?: any, extraFetchParams?: any): Promise<ArrayWrapper<GraphUser>>
  • Get a list of all users in a given scope. Since the list of users may be large, results are returned in pages of users. If there are more results than can be returned in a single page, the result set will contain a continuation token for retrieval of the next set of results.

    Parameters

    • params: object
      • apiVersion: string
      • Optional continuationToken?: string
      • organization: string
      • Optional subjectTypes?: string
    • Optional extraQueryParams: any
    • Optional extraFetchParams: any

    Returns Promise<ArrayWrapper<GraphUser>>

Generated using TypeDoc