Class: UserAccountsClient

Inherits:
Object
  • Object
show all
Defined in:
lib/lockstep_sdk/clients/user_accounts.rb

Instance Method Summary collapse

Constructor Details

#initialize(lockstepsdk) ⇒ UserAccountsClient

Initialize the UserAccountsClient class with a lockstepsdk instance.

Parameters:

  • lockstepsdk (LockstepApi)

    The Lockstep API client object for this connection



22
23
24
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 22

def initialize(lockstepsdk)
    @lockstepsdk = lockstepsdk
end

Instance Method Details

#disable_user(id:) ⇒ Object

Disable the user referred to by this unique identifier.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • id (uuid)

    The unique Lockstep Platform ID number of this User



58
59
60
61
62
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 58

def disable_user(id:)
    path = "/api/v1/UserAccounts/#{id}"
    params = {}
    @lockstepsdk.request(:delete, path, nil, params)
end

#invite_userObject

Invite a user with the specified email to join your accounting group. The user will receive an email to set up their account.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • body (InviteSubmitModel)

    The user to invite



80
81
82
83
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 80

def invite_user()
    path = "/api/v1/UserAccounts/invite"
    @lockstepsdk.request(:post, path, body, nil)
end

#query_users(filter:, include_param:, order:, pageSize:, pageNumber:) ⇒ Object

Queries Users for this account using the specified filtering, sorting, nested fetch, and pagination rules requested. A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:



112
113
114
115
116
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 112

def query_users(filter:, include_param:, order:, pageSize:, pageNumber:)
    path = "/api/v1/UserAccounts/query"
    params = {:filter => filter, :include => include_param, :order => order, :pageSize => pageSize, :pageNumber => pageNumber}
    @lockstepsdk.request(:get, path, nil, params)
end

#reenable_user(id:) ⇒ Object

Reenable the user referred to by this unique identifier.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • id (uuid)

    The unique Lockstep Platform ID number of this User



69
70
71
72
73
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 69

def reenable_user(id:)
    path = "/api/v1/UserAccounts/reenable"
    params = {:id => id}
    @lockstepsdk.request(:post, path, nil, params)
end

#retrieve_invite_data(code:) ⇒ Object

Retrieves invite information for the specified invite token.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • code (uuid)

    The code of the invite



89
90
91
92
93
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 89

def retrieve_invite_data(code:)
    path = "/api/v1/UserAccounts/invite"
    params = {:code => code}
    @lockstepsdk.request(:get, path, nil, params)
end

#retrieve_user(id:, include_param:) ⇒ Object

Retrieves the User with this identifier.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • id (uuid)

    The unique ID number of the User to retrieve

  • include_param (string)

    To fetch additional data on this object, specify the list of elements to retrieve. Available collections: Notes, Attachments, CustomFields, AccountingRole



33
34
35
36
37
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 33

def retrieve_user(id:, include_param:)
    path = "/api/v1/UserAccounts/#{id}"
    params = {:include => include_param}
    @lockstepsdk.request(:get, path, nil, params)
end

#transfer_ownerObject

Transfer the ownership of a group to another user. This API must be called by the current owner of the group.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • body (TransferOwnerSubmitModel)


100
101
102
103
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 100

def transfer_owner()
    path = "/api/v1/UserAccounts/transfer-owner"
    @lockstepsdk.request(:post, path, body, nil)
end

#update_user(id:) ⇒ Object

Updates a User that matches the specified id with the requested information.

The PATCH method allows you to change specific values on the object while leaving other values alone. As input you should supply a list of field names and new values. If you do not provide the name of a field, that field will remain unchanged. This allows you to ensure that you are only updating the specific fields desired.

A User represents a person who has the ability to authenticate against the Lockstep Platform and use services such as Lockstep Inbox. A User is uniquely identified by an Azure identity, and each user must have an email address defined within their account. All Users must validate their email to make use of Lockstep platform services. Users may have different privileges and access control rights within the Lockstep Platform.

Parameters:

  • id (uuid)

    The unique ID number of the User to retrieve

  • body (object)

    A list of changes to apply to this User



47
48
49
50
51
# File 'lib/lockstep_sdk/clients/user_accounts.rb', line 47

def update_user(id:)
    path = "/api/v1/UserAccounts/#{id}"
    params = {}
    @lockstepsdk.request(:patch, path, body, params)
end