BookStack icon

BookStack

Consume BookStack API

Overview

This node integrates with the BookStack API to manage various BookStack resources such as books, pages, chapters, shelves, users, roles, attachments, and tags. Specifically for the User - Delete operation, it allows you to delete a user resource by specifying its ID.

Common scenarios where this node is beneficial include automating content management workflows in BookStack, such as removing obsolete or inactive users programmatically, cleaning up user accounts, or integrating user management into broader automation pipelines.

Practical example: Automatically deleting a user account when they leave an organization by triggering this node with the user's ID.

Properties

Name Meaning
Tool Description Choose how to determine the resource and operation:
- Set Automatically
- Set Manually
Request Description (Shown only if "Set Automatically" is selected) Describe your request in natural language; the system attempts to infer the resource and operation automatically. Example: "Delete user with ID 123".
ID The unique identifier of the user resource to delete. Required for delete operation.

Output

The output JSON contains the response from the BookStack API after attempting to delete the user. Typically, for a successful delete operation, the API returns confirmation data or an empty object indicating success.

  • json: The main field containing the API response.
  • If the deletion fails, the output may contain an error message under json.error.

No binary data is produced by this node.

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 DELETE requests to the endpoint /users/{id} to perform the deletion.

Troubleshooting

  • Common issues:

    • Invalid or missing user ID: The node requires a valid user ID to delete. Ensure the ID is correct and exists.
    • Authentication errors: Verify that the API credentials are correctly set up and have sufficient permissions to delete users.
    • Network or connectivity problems: Confirm that the BookStack API base URL is reachable from the n8n environment.
  • Error messages:

    • "error": "User not found": The specified user ID does not exist. Check the ID.
    • "error": "Unauthorized" or similar: Authentication failed. Recheck API credentials.
    • Other HTTP errors (e.g., 400, 403, 500): Review API documentation and server logs for details.
  • To handle errors gracefully, enable the node's "Continue On Fail" option to capture errors in the output without stopping the workflow.

Links and References

Discussion