Overview
This node is designed to obtain an access token from the Larkbase API using provided application credentials. It supports retrieving either a Tenant Access Token for internal organizational applications or an App Access Token for user-installed applications. This node is useful in scenarios where subsequent API calls require authentication via these tokens, such as automating workflows that interact with Larkbase services.
Use Case Examples
- A user wants to automate data retrieval from Larkbase and needs to authenticate using a Tenant Access Token.
- An application installed by a user requires an App Access Token to perform authorized API requests within a workflow.
Properties
| Name | Meaning |
|---|---|
| App ID | The App ID of the Larkbase application, required for authentication. |
| App Secret | The App Secret of the Larkbase application, used alongside the App ID for authentication. This is a password-type field to keep the secret secure. |
| Access Token Type | Specifies the type of token to retrieve: either a Tenant Access Token for internal organizational apps or an App Access Token for user-installed apps. |
Output
JSON
access_token- The access token string obtained from Larkbase API.expires_in- The duration in seconds before the token expires.token_type- The type of token retrieved (tenant_access_token or app_access_token).requesturl- The URL used to request the token, with partial App ID for security.
responsecode- The response code from the Larkbase API indicating success or error.msg- The response message from the Larkbase API.
Dependencies
- axios for HTTP requests
- an API key credential for App ID and App Secret
Troubleshooting
- Common issues include missing or incorrect App ID or App Secret, which will cause authentication failures.
- If the API returns an error code, the node throws an error with the message from the API response; ensure credentials and token type are correct.
- Network issues or incorrect API endpoint URLs can cause request failures; verify network connectivity and endpoint correctness.
Links
- Larkbase API Documentation - Official documentation for Larkbase API including token retrieval endpoints and usage.