Table of Contents

Class UsersResource

Namespace
Google.Apis.Admin.Directory.directory_v1
Assembly
Google.Apis.Admin.Directory.directory_v1.dll

The "users" collection of methods.

public class UsersResource
Inheritance
UsersResource
Inherited Members

Constructors

UsersResource(IClientService)

Constructs a new resource.

public UsersResource(IClientService service)

Parameters

service IClientService

Properties

Aliases

Gets the Aliases resource.

public virtual UsersResource.AliasesResource Aliases { get; }

Property Value

UsersResource.AliasesResource

Photos

Gets the Photos resource.

public virtual UsersResource.PhotosResource Photos { get; }

Property Value

UsersResource.PhotosResource

Methods

Delete(string)

Deletes a user.

public virtual UsersResource.DeleteRequest Delete(string userKey)

Parameters

userKey string

Identifies the user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.DeleteRequest

Get(string)

Retrieves a user.

public virtual UsersResource.GetRequest Get(string userKey)

Parameters

userKey string

Identifies the user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.GetRequest

Insert(User)

Creates a user.

public virtual UsersResource.InsertRequest Insert(User body)

Parameters

body User

The body of the request.

Returns

UsersResource.InsertRequest

List()

Retrieves a paginated list of either deleted users or all users in a domain.

public virtual UsersResource.ListRequest List()

Returns

UsersResource.ListRequest

MakeAdmin(UserMakeAdmin, string)

Makes a user a super administrator.

public virtual UsersResource.MakeAdminRequest MakeAdmin(UserMakeAdmin body, string userKey)

Parameters

body UserMakeAdmin

The body of the request.

userKey string

Identifies the user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.MakeAdminRequest

Patch(User, string)

Updates a user using patch semantics. The update method should be used instead, since it also supports patch semantics and has better performance. This method is unable to clear fields that contain repeated objects (addresses, phones, etc). Use the update method instead.

public virtual UsersResource.PatchRequest Patch(User body, string userKey)

Parameters

body User

The body of the request.

userKey string

Identifies the user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.PatchRequest

SignOut(string)

Sign a user out of all web and device sessions and reset their sign-in cookies. User will have to sign in by authenticating again.

public virtual UsersResource.SignOutRequest SignOut(string userKey)

Parameters

userKey string

Identifies the target user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.SignOutRequest

Undelete(UserUndelete, string)

Undeletes a deleted user.

public virtual UsersResource.UndeleteRequest Undelete(UserUndelete body, string userKey)

Parameters

body UserUndelete

The body of the request.

userKey string

The immutable id of the user

Returns

UsersResource.UndeleteRequest

Update(User, string)

Updates a user. This method supports patch semantics, meaning you only need to include the fields you wish to update. Fields that are not present in the request will be preserved, and fields set to null will be cleared.

public virtual UsersResource.UpdateRequest Update(User body, string userKey)

Parameters

body User

The body of the request.

userKey string

Identifies the user in the API request. The value can be the user's primary email address, alias email address, or unique user ID.

Returns

UsersResource.UpdateRequest

Watch(Channel)

Watch for changes in users list

public virtual UsersResource.WatchRequest Watch(Channel body)

Parameters

body Channel

The body of the request.

Returns

UsersResource.WatchRequest