Gitea icon

Gitea

Interact with Gitea via API

Actions393

Overview

This node interacts with a user management API to retrieve authentication tokens associated with a specific user. It is useful in scenarios where you need to programmatically access or audit the tokens issued to a user, such as for security reviews, token management, or integration with other systems that require token information.

For example, you might use this node to:

  • Fetch all active tokens for a given username to monitor their usage.
  • Paginate through tokens if a user has many, by specifying page and limit parameters.
  • Integrate token retrieval into automated workflows for user session management.

Properties

Name Meaning
Username The username of the user whose tokens you want to retrieve. This is a required field.
Page The page number of results to return (1-based). Useful for paginating through tokens.
Limit The number of tokens to return per page. Controls the page size for pagination.

Output

The node outputs JSON data containing the list of tokens associated with the specified user. Each token entry typically includes details such as token ID, creation date, expiration, scopes, and other metadata relevant to the token.

If the API supports it, the output may be paginated according to the page and limit input properties.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API key credential to authenticate requests against the user management API.
  • The base URL for the API must be configured in the node credentials.
  • The node sends HTTP requests with headers set to accept and send JSON content.

Troubleshooting

  • Invalid Username: If the username does not exist, the API may return an error or empty result. Verify the username is correct.
  • Authentication Errors: Ensure the API key credential is valid and has sufficient permissions to read user tokens.
  • Pagination Issues: If page or limit are set incorrectly (e.g., negative numbers), the API may return errors or unexpected results. Use positive integers starting from 1 for page.
  • API Connectivity: Network issues or incorrect base URL configuration can cause request failures. Confirm the API endpoint is reachable.

Links and References

  • Refer to the user management API documentation for detailed information on token fields and pagination behavior.
  • Consult your API provider’s authentication guide for setting up the required API key credential.

Discussion