# Me Actions Details on the various actions that can be performed on the Me resource, including the expected parameters and the potential responses. ##### Contents * [Add Recent Item](#add-recent-item) * [Change Password](#change-password) * [Delete](#delete) * [Disable Two Factor Auth](#disable-two-factor-auth) * [Disconnect Github](#disconnect-github) * [Disconnect Twitter](#disconnect-twitter) * [Enable Two Factor Auth](#enable-two-factor-auth) * [Fetch Recent Items](#fetch-recent-items) * [Get](#get) * [Patch](#patch) * [Payload Counts](#payload-counts) * [Refresh Token](#refresh-token) * [Transfer Resources](#transfer-resources) * [Verify Email](#verify-email)
## Add Recent Item Adds an item to a recent item list ```ruby result = client.me.add_recent_item(data: my_data) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.addRecentItem. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | data | [Recent Item](_schemas.md#recent-item) | Y | Object containing recent item info | | [Recent Item Example](_schemas.md#recent-item-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Recent Item List](_schemas.md#recent-item-list) | Updated recent item list | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Change Password Changes the current user's password and optionally logs out all other sessions ```ruby result = client.me.change_password(data: my_data) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.changePassword. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | data | [Change Password](_schemas.md#change-password) | Y | Object containing the password change info | | [Change Password Example](_schemas.md#change-password-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Authenticated User](_schemas.md#authenticated-user) | A new, valid, auth token (potentially all previous tokens are now invalid) | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Delete Deletes the current user ```ruby result = client.me.delete(credentials: my_credentials) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.delete. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | credentials | [User Credentials](_schemas.md#user-credentials) | Y | User authentication credentials | | [User Credentials Example](_schemas.md#user-credentials-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Success](_schemas.md#success) | If the user was successfully deleted | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Disable Two Factor Auth Disables two factor auth for the current user ```ruby result = client.me.disable_two_factor_auth(data: my_data) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.disableTwoFactorAuth. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | data | [Disable Two Factor Auth](_schemas.md#disable-two-factor-auth) | Y | Object containing two factor auth properties | | [Disable Two Factor Auth Example](_schemas.md#disable-two-factor-auth-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Updated user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Disconnect Github Disconnects the user from Github ```ruby result = client.me.disconnect_github(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.disconnectGithub. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Updated user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Disconnect Twitter Disconnects the user from Twitter ```ruby result = client.me.disconnect_twitter(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.disconnectTwitter. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Updated user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Enable Two Factor Auth Enables two factor auth for the current user ```ruby result = client.me.enable_two_factor_auth(data: my_data) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.enableTwoFactorAuth. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | data | [Enable Two Factor Auth](_schemas.md#enable-two-factor-auth) | Y | Object containing two factor auth properties | | [Enable Two Factor Auth Example](_schemas.md#enable-two-factor-auth-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Updated user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Fetch Recent Items Gets a recent item list ```ruby result = client.me.fetch_recent_items(itemType: my_item_type) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, all.User.read, me.*, or me.fetchRecentItems. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | parentId | string | N | Parent id of the recent list | | 575ec8687ae143cd83dc4a97 | | itemType | undefined | Y | Item type to get the recent list of. Accepted values are: application, device, flow, dashboard, organization | | application | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Recent Item List](_schemas.md#recent-item-list) | Recent item list | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Get Retrieves information on the current user ```ruby result = client.me.get(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, all.User.read, me.*, or me.get. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | includeRecent | undefined | N | Should the user include recent app/dashboard info | | true | | summaryExclude | string | N | Comma-separated list of summary fields to exclude from user summary | | payloadCount | | summaryInclude | string | N | Comma-separated list of summary fields to include in user summary | | payloadCount | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Current user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- |
## Patch Updates information about the current user ```ruby result = client.me.patch(user: my_user) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.patch. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | user | [Me Patch](_schemas.md#me-patch) | Y | Object containing new user properties | | [Me Patch Example](_schemas.md#me-patch-example) | | summaryExclude | string | N | Comma-separated list of summary fields to exclude from user summary | | payloadCount | | summaryInclude | string | N | Comma-separated list of summary fields to include in user summary | | payloadCount | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Me](_schemas.md#me) | Updated user information | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Payload Counts Returns payload counts for the time range specified for all applications the current user owns ```ruby result = client.me.payload_counts(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, all.User.read, me.*, or me.payloadCounts. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | start | string | N | Start of range for payload count query (ms since epoch) | | 0 | | end | string | N | End of range for payload count query (ms since epoch) | | 1465790400000 | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Payload Counts](_schemas.md#payload-counts) | Payload counts, by type and source | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Refresh Token Returns a new auth token based on the current auth token ```ruby result = client.me.refresh_token(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, or me.*. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Authenticated User](_schemas.md#authenticated-user) | Successful token regeneration | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request | | 401 | [Error](_schemas.md#error) | Unauthorized error if authentication fails |
## Transfer Resources Moves resources to a new owner ```ruby result = client.me.transfer_resources(transfer: my_transfer) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.transferResources. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | transfer | [Resource Transfer](_schemas.md#resource-transfer) | Y | Object containing properties of the transfer | | [Resource Transfer Example](_schemas.md#resource-transfer-example) | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Success](_schemas.md#success) | If resource transfer was successful | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |
## Verify Email Sends an email verification to the user ```ruby result = client.me.verify_email(optional_params) puts result ``` #### Authentication The client must be configured with a valid api access token to call this action. The token must include at least one of the following scopes: all.User, me.*, or me.verifyEmail. #### Available Parameters | Name | Type | Required | Description | Default | Example | | ---- | ---- | -------- | ----------- | ------- | ------- | | losantdomain | string | N | Domain scope of request (rarely needed) | | example.com | #### Successful Responses | Code | Type | Description | | ---- | ---- | ----------- | | 200 | [Success](_schemas.md#success) | If email verification was successfully sent | #### Error Responses | Code | Type | Description | | ---- | ---- | ----------- | | 400 | [Error](_schemas.md#error) | Error if malformed request |