Lark Contacts icon

Lark Contacts

Lark Contacts Management

Overview

This node allows partial modification of user information within the "Contacts User" resource in Lark (a collaboration platform). It is designed to update specific fields of a user's profile without needing to resend the entire user data. This is useful for scenarios where only certain attributes of a user need to be updated, such as changing their job title, mobile number, or department assignments.

Practical examples include:

  • Updating an employee's phone number or email address after they change contact details.
  • Modifying organizational structure by changing department IDs or positions.
  • Adjusting user visibility settings like mobile visibility or frozen status.
  • Adding or updating custom attributes related to the user.

Properties

Name Meaning
Authentication Method of authentication: either "Tenant Token" or "OAuth2".
User Id The unique identifier of the user to modify; must match the user_id_type in the query parameter.
Avatar Key Key representing the user's avatar image.
City User's city.
Country User's country.
Custom Attrs A collection of custom attributes with JSON values to add or update on the user profile.
Department Ids List of department IDs the user belongs to.
Description Description or notes about the user.
Email User's email address.
Employee No Employee number or code.
Employee Type Numeric type categorizing the employee.
En Name User's English name.
Ent Email Password Password for enterprise email (if applicable).
Enterprise Email Enterprise email address.
Gender Numeric gender value.
Idp Type Identity provider type string.
Is Frozen Boolean indicating if the user account is frozen (disabled).
Job Title User's job title.
Join Time Timestamp or numeric representation of the user's join date/time.
Leader User Id User ID of the leader or manager of this user.
Mobile User's mobile phone number.
Mobile Visible Boolean indicating if the mobile number is visible to others.
Name User's full name.
Nickname User's nickname.
Orders Collection of order objects specifying department and user ordering within departments.
Positions Collection of position objects describing user's roles, leadership, and major position status.
Work Station User's work station or location.
Custom Body JSON object allowing sending a fully custom request body instead of individual fields.
Options > Use Custom Body Boolean flag to indicate whether to use the custom JSON body instead of individual properties.

Output

The node outputs JSON data representing the response from the Lark API after attempting to modify the user information. This typically includes confirmation of the updated fields or error messages if the update failed.

No binary data output is involved.

Dependencies

  • Requires access to Lark's Open API endpoints at https://open.larksuite.com/open-apis.
  • Requires authentication via either a Tenant Token or OAuth2 credentials configured in n8n.
  • Proper permissions/scopes must be granted to the API credentials to modify user information.

Troubleshooting

  • Common issues:

    • Incorrect or missing User Id will cause the API call to fail.
    • Insufficient permissions on the API token may result in authorization errors.
    • Providing invalid field values (e.g., wrong data types or invalid department IDs) can cause validation errors.
    • Using both individual fields and custom body simultaneously may lead to conflicts; ensure only one method is used based on the "Use Custom Body" option.
  • Error messages:

    • "User not found" — Verify the User Id is correct and exists.
    • "Unauthorized" — Check that the API credentials are valid and have required scopes.
    • "Invalid parameters" — Review the input fields for correct types and allowed values.
    • "Request body malformed" — If using custom body, ensure JSON syntax and structure are correct.

Links and References

Discussion