BookStack icon

BookStack

Consume BookStack API

Overview

This node integrates with the BookStack API to manage various resources such as books, pages, chapters, shelves, users, roles, attachments, and tags. Specifically for the User resource with the Update operation, it allows updating user details by specifying the user ID and the fields to modify.

The node supports two modes of operation:

  • Automatic mode: You describe your request in natural language, and the node attempts to infer the resource and operation.
  • Manual mode: You explicitly select the resource and operation and provide necessary parameters.

Practical examples include:

  • Updating a user's profile information by providing their ID and new details.
  • Modifying user permissions or roles (if supported by the API).
  • Automating user updates based on dynamic input descriptions.

This node is beneficial when you want to automate content and user management workflows within BookStack without manually interacting with its API.

Properties

Name Meaning
Tool Description Choose how to determine the resource and operation: "Set Automatically" or "Set Manually".
Request Description (Shown if "Set Automatically") Describe your request in natural language; the system infers action. Example: "Update user with ID 123".
ID The unique identifier of the user to update. Required for update operations.

Note: For the User resource Update operation, only the ID property is explicitly required from the provided properties snippet. Other user-specific fields are not detailed here but would typically be included depending on the API's capabilities.

Output

The node outputs an array of JSON objects corresponding to each input item processed. Each output object contains the response from the BookStack API after performing the update operation on the user resource.

The structure of the JSON output reflects the updated user data returned by the API, including any modified fields.

If an error occurs during processing, and the node is configured to continue on failure, the output will contain an error field with the error message for that item.

No binary data output is indicated.

Dependencies

  • Requires connection to a BookStack instance via its API.
  • Needs an API authentication token credential configured in n8n with:
    • Base URL of the BookStack API.
    • Authorization token and secret.
  • The node uses HTTP requests authenticated with these credentials to perform operations.

Troubleshooting

  • Common issues:

    • Incorrect or missing user ID will cause the update to fail.
    • Invalid or expired API tokens will result in authentication errors.
    • Insufficient permissions for the API token may prevent updating users.
    • Malformed request body if required fields are missing or invalid.
  • Error messages:

    • Authentication errors: Check API token validity and permissions.
    • Resource not found: Verify the user ID exists.
    • Validation errors: Ensure all required fields for update are correctly provided.
  • To resolve errors, verify credentials, confirm user IDs, and ensure the request body matches API expectations.

Links and References

Discussion