Blocklet Server icon

Blocklet Server

Consume Blocklet Server API

User → Get Users

AI-generated

Overview

This node operation fetches a list of users from the Blocklet Server API based on various filtering, sorting, and paging parameters. It is useful for scenarios where you need to retrieve user data for a specific Blocklet app (team) with options to filter by role, search keyword, user DIDs, and tags. It also supports including additional user-related data such as tags, connected accounts, and passports. Sorting by update, creation, or last login date and paginating results are supported to manage large datasets efficiently.

Use Case Examples

  1. Retrieve all users of a Blocklet app with a specific role and include their tags and connected accounts.
  2. Search users by name or email keyword and paginate the results to display 50 users per page.
  3. Filter users by a list of user DIDs and sort them by their last login date in descending order.

Properties

Name Meaning
App DID DID of the blocklet app (team) to specify which team's users to fetch.
Enabled Connected Account Whether to search the connected account of the user.
User Role Filter users by their role within the team.
Search Keyword (by Name, Email, Did) Filter users by a search keyword matching name, email, or DID.
User DIDs Filter users by a list of user DIDs.
Tags Filter users by tags associated with them.
Include Tags Whether to include the tags of the user in the output.
Include Connected Accounts Whether to include the connected accounts of the user in the output.
Include Passports Whether to include the passports of the user in the output.
Sort Sorting options for the user list, including sorting by updated at, created at, or last login at timestamps.
Paging Paging options to specify the page number and page size for the user list.

Output

JSON

  • users - Array of user objects matching the filter criteria, including optional tags, connected accounts, and passports based on input parameters.

Dependencies

  • Blocklet Server API
  • An API key credential for Blocklet Server API authentication

Troubleshooting

  • Common issues include invalid or missing App DID, which will cause the API request to fail.
  • Incorrect filter parameters such as invalid user DIDs or tags may result in empty or unexpected results.
  • If the API key credential is not set or invalid, authentication errors will occur.
  • Error messages from the API will be propagated; ensure the parameters conform to the API specification.

Links

Discussion