Overview
This node is designed to obtain an access token from the Larkbase API using provided App ID and App Secret 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 automated workflows require authenticated access to Larkbase services, such as integrating Larkbase data or functionalities into other systems or automations.
Use Case Examples
- Automating the retrieval of a Tenant Access Token to authenticate internal organizational apps.
- Fetching an App Access Token for applications installed by end users to enable API interactions within an n8n 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 access token to retrieve: either a Tenant Access Token for internal apps or an App Access Token for user-installed apps. |
Output
JSON
access_token- The retrieved access token string used for authenticating API requests.expires_in- The duration in seconds before the token expires.token_type- The type of token retrieved, either tenant_access_token or app_access_token.requesturl- The URL used to request the token, partially masked App ID included for reference.
responsecode- The response code from the Larkbase API indicating success or error.msg- The message from the Larkbase API response providing additional information.
Dependencies
- Requires network access to Larkbase API endpoints.
- Needs App ID and App Secret credentials for authentication.
Troubleshooting
- Common errors include missing or incorrect App ID or App Secret, which will cause authentication failures.
- If the API response code is non-zero, the node throws an error with the API message; verify credentials and token type.
- Ensure the selected token type matches the intended use case (tenant vs app token).
- Network connectivity issues to the Larkbase API endpoint can cause request failures.