Actions28
- File Actions
- Multipart Upload File Actions
- Permission Member Actions
- Permissionpublic Actions
- Statistic Actions
- Media Actions
- Multipart Upload Media Actions
- Comment Actions
- Subscription Actions
- Document Import Actions
Overview
This node, part of the "Lark Files" integration, allows users to update common permission settings of a document stored in Lark's file management system. It is useful for managing access control and sharing options on documents programmatically within an n8n workflow.
Typical use cases include:
- Adjusting who can comment or share a document.
- Enabling or disabling external access or invitations.
- Locking or unlocking a document to prevent further changes.
- Customizing security and sharing entities related to the document permissions.
For example, a user might automate updating a document’s permissions after it is created or shared, ensuring that only certain groups or external users have access, or locking the document once finalized.
Properties
Name | Meaning |
---|---|
Authentication | Method of authentication to use: either "Tenant Token" or "OAuth2". |
Type | The type of the permission object (string). This typically specifies the kind of document or permission context, e.g., Wiki nodes (partially supported). |
Token | Required. The unique token identifier of the file/document whose permissions are being updated. |
Comment Entity | Identifier string representing the entity allowed to comment on the document. |
External Access | Boolean flag indicating whether external access to the document is enabled (true ) or disabled (false ). |
Invite External | Boolean flag indicating whether inviting external users to the document is allowed (true ) or not (false ). |
Link Share Entity | Identifier string representing the entity allowed to share the document via link. |
Lock Switch | Boolean flag to lock (true ) or unlock (false ) the document, controlling edit permissions. |
Security Entity | Identifier string representing the security entity associated with the document permissions. |
Share Entity | Identifier string representing the entity allowed to share the document. |
Custom Body | A JSON object allowing the user to specify a fully custom request body for the API call instead of using the predefined fields. This enables advanced customization of the permission update payload. |
Options > Use Custom Body | Boolean option to toggle between using the standard input fields or providing a custom JSON body for the request. |
Output
The node outputs JSON data representing the response from the Lark API after attempting to update the document's permission settings. This typically includes status information about the update operation, such as success confirmation or error details.
No binary data output is produced by this node.
Dependencies
- Requires an active connection to Lark's Open API service at
https://open.larksuite.com/open-apis
. - Requires authentication credentials, either a Tenant Token or OAuth2 token, configured in n8n.
- The node uses JSON content-type headers and expects/returns JSON-formatted data.
Troubleshooting
- Invalid or missing token: If the provided file token is incorrect or missing, the API will reject the request. Ensure the token is valid and correctly specified.
- Authentication errors: Using invalid or expired credentials will cause authentication failures. Verify that the API key or OAuth2 token is current and properly configured.
- Permission denied: Attempting to update permissions without sufficient rights may result in authorization errors. Confirm that the authenticated user has permission to modify the document.
- Malformed custom body: When using the custom JSON body option, ensure the JSON structure matches the API expectations; otherwise, the request may fail.
- Network issues: Connectivity problems to the Lark API endpoint will cause request failures. Check network access and proxy settings if applicable.
Links and References
- Lark Docs File Management API Overview
- Lark API Permissions Documentation (for detailed permission objects and usage)