In this article

The page's title should always be the Snap's name.  For example, File Reader. 

Overview

Use this Snap to perform the following operations on the users list in your Slack Workspace.

Provide a functional overview of the Snap. Do not mention anything about the Snap's internal technology or techniques. The user should be able to understand what the Snap. Include a screenshot of a well-configured Snap 600px.  

Prerequisites

Add valid Slack Scopes based on the intended operation. You must have the owner or administrator privileges to perform some of these operations. See Required Slack Scopes below for details.

Required Slack Scopes

Any action you want to perform within a Slack Workspace, additionally needs appropriate Scopes assigned to your appSee the Scope and Permissions article in Slack API documentation for the complete list and each Account page under Configuring Slack Accounts for information on defining Scopes for your app.

To

Bot Token Accounts
(scope)

User Token Accounts
(user_scope)
View lists of users in the Workspace to select fromusers:readusers:read
  • Add new users to the Workspace
  • Remove user from the Workspace
N/Aadmin.users:write 

List all prerequisites for using the Snap as a bullet list. Use direct sentences. For example, in case of a Write-type Snap a prerequisite would be that the user must have write access. Include links to external official documentation, if required. Use "None." if there no prerequisites. 

Support for Ultra Pipelines

Works in Ultra Pipelines.

Limitations

List all Snap-specific limitations as a bullet list. Limitations can be imposed by the Snap's development environment and also by the endpoint's API. List both. Use direct sentences. Include links to external official documentation, if required. Use "None.: if there are no limitations.  

Known Issues

None.

Snap Input and Output

Type of view: Document/Binary/Both. Get number of views from the Views tab in the Snap. List at least three compatible Snaps in each category. Provide a brief of the input/output required. If the input/output is optional then preface the description with "Optional." For example, "Transaction data complying with the Orderful schema as a JSON document."

Input/OutputType of ViewNumber of ViewsExamples of Upstream and Downstream SnapsDescription
Input 

Document

  • Min: 0
  • Max: 1
  • Mapper
  • Copy
  • JSON Generator
A document containing information required to perform a specific User operation.
Output

Document

  • Min: 1
  • Max: 1
  • Mapper
  • Join
  • JSON Formatter
  • File Writer

A document containing the result (success/failure) of performing the selected User operation.

Snap Settings

Parameter NameData TypeDescriptionDefault ValueExample 
LabelString
User OperationsUser Operations
OperationDrop-down list

Select an operation from the following list of permitted user operations and specify the corresponding details needed:

  • User Info: To view the details of the user like full name, team, permissions, user's account status, time zone. Requires User ID.
  • Add User: To add a new user to the Workspace. Requires User ID, Team ID, and the permissions Is Restricted, Is Ultra Restricted
  • Remove User: To add a new user to the Workspace. Requires User ID, Team ID.
User InfoUser Info
User IDString/Expression/Suggestion

Required for User Operations.

Click the  icon and select a user from the suggested values which are typically the list of users available in the Workspace. Alternatively, you can enter one or more usernames and/or user IDs, separated by commas, in one of the following formats.

  • @user.name:<11-character alphanumeric user ID> OR
  • @user.name OR
  • <11-character alphanumeric user ID>

For User Info: To retrieve the user information.

For Add User: To add the new user with the corresponding User ID.

For Remove User: To delete the user corresponding to the User ID.


N/A@user.name:W01A94P7MK1
Team IDString/Expression/Suggestion

Required for User Operations - Add User and Remove User

Click the  icon and select a Team (Workspace) ID from the suggested list of Team IDs to add the user to or remove the user from. 

N/AT01BLQ3PNMB
Is RestrictedCheck box

Required for User operation - Add User

Select this check box to restrict the user's access to only multiple channels. If selected, the user is considered as a guest user with limited access. Do not select this check box if the user should be a Full Member.

Not selectedSelected
Is Ultra RestrictedCheck box

Required for User operation - Add User

Select this check box to restrict the user's access to a single channel. If selected, the user is considered as a guest user with very limited access. Do not select this check box if the user should be a Full Member.

Not selectedSelected
Snap ExecutionDrop-down list

Select one of the three following modes in which the Snap executes:

  • Validate & Execute. Performs limited execution of the Snap and generates a data preview during Pipeline validation, then performs full execution of the Snap (unlimited records) during Pipeline runtime.
  • Execute only. Performs full execution of the Snap during Pipeline execution without generating preview data.
  • Disabled. Disables the Snap and all Snaps downstream from it.

Execute onlyValidate & Execute

Troubleshooting

You can get information for this section from the Snap's source code, typically the Messages.java file in GitHub. Ask the developer to access this file. Do not use "Please" in the Reason or Resolution. If there is "Please" in the error message then contact the developer to have it removed as needed.

ErrorReasonResolution
Enter the error message that is displayed.

Unable to suggest workspaces; Reason: missing_scope

Briefly describe why this error is triggered. An experienced user will be able to troubleshoot the error looking at the reason itself.

You do not have the required permissions to list the users of this Workspace and perform the selected operation.

List the steps that the user must take, if necessary, to rectify this error. If a procedure is extensive, add it as a separate section after this table and reference it with a link in this cell.

For except User Operation - User Info, ensure that you have the required admin or owner privileges to perform the operations on users. Also make sure that you have assigned the required Scopes to your Slack app.

IO error while validating the given token, Reason: timeoutThe Snap connection with your Slack App could not be established due to a timeout error during token validation.Check you network connectivity, account configuration and retry running/validating your Pipeline/Snap.
Failure: Input error, Reason: User ID missingThis Snap does not perform any action in the absence of a valid User ID.Ensure to provide a valid User ID (typically select from the suggested users list)and save your Snap settings.

Examples

Retrieving a User's Information and Writing it to a File

Example title must be gerunds in title case.

This example demonstrates the only user operation that you can perform without admin/owner privileges on your Slack app, that is User Info. using the User Operations Snap. All operations carried out in this example are for demonstration purposes only and the Pipeline reflects the actual/real-time behavior but not the values, either used or retrieved.

We use the User Operations Snap with User Info operation selected, to retrieve the user's information. We also provide the User ID of the user in this Snap. Alternatively, you can select the user from the suggested list of users using the  icon. The Snap fetches the user's details and presents it in the output (see the following Output).

User OperationsOutput

To write the extracted user information into a file for further use, we connect a JSON Formatter Snap and a File Writer Snap, in that order. See the preview of the file we created using the File Writer Snap below.

Download this Pipeline

Add a download link to the Pipeline in the the "Download" text above. Explain the Pipeline/Snap configuration in detail if a complex enough example has been used. Ensure that the functionality you are trying to illustrate is captured correctly. Include caveats as appropriate. To insert link: Press Ctrl + K --> Files --> Select the SLP file corresponding to the example. 

Downloads

  1. Download and import the Pipeline into SnapLogic.
  2. Configure Snap accounts as applicable.
  3. Provide Pipeline parameters as applicable.

Edit the Excerpt Include macro below to link to the Snap Pack page for this Snap page. Ensure that the heading Snap Pack History is not within the Snap Pack's history Excerpt. 


See Also

Provide links to the endpoint's official documentation, any relevant or related internal documentation, and any other links you have referred to on this page. Care should be taken when referencing external sites/documentation that it is an official site/documentation. Do not refer to forums such as stackoverflow.