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 Chapter resource with the Get Many operation, it retrieves multiple chapter records from the BookStack system.

Common scenarios where this node is beneficial include:

  • Fetching a list of all chapters within a book or across the system for reporting or synchronization.
  • Automating content management workflows by retrieving chapter data to process or display elsewhere.
  • Integrating BookStack chapter data into other systems or dashboards.

For example, you might use this node to get all chapters in a specific book to generate a table of contents or to export chapter metadata for backup purposes.

Properties

Name Meaning
Tool Description Choose how to determine the resource and operation: either "Set Automatically" or "Set Manually".
Request Description (Shown only if "Tool Description" is set to "Set Automatically") Describe your request in natural language, e.g., "List all chapters in the book API Documentation". The system will parse this description to select the appropriate resource and operation automatically.

Note: Since the user requested details only for the Chapter resource and Get Many operation, the relevant properties are limited to these two inputs. Other properties related to manual resource/operation selection or creation/update/delete operations are not applicable here.

Output

The output is an array of JSON objects representing the retrieved chapters. Each item corresponds to one chapter resource returned by the BookStack API under the data property of the response.

The structure of each chapter object typically includes fields like:

  • id: Unique identifier of the chapter.
  • name: The chapter's title.
  • book_id: Identifier of the book the chapter belongs to.
  • Other metadata fields as provided by the BookStack API.

No binary data output is involved in this operation.

Dependencies

  • Requires connection to a BookStack instance via its API.
  • Needs an API token credential configured in n8n with base URL and authentication tokens.
  • The node uses HTTP requests authenticated with a token header to communicate with the BookStack API.
  • Pagination support is implemented using offset-based pagination with parameters count and offset.

Troubleshooting

  • Common issues:

    • Incorrect or missing API credentials will cause authentication failures.
    • Providing an invalid base URL or token will result in connection errors.
    • If the BookStack API endpoint is unreachable, network errors will occur.
    • Misformatted or ambiguous request descriptions when using automatic mode may lead to unexpected resource/operation selection.
  • Error messages:

    • Authentication errors usually indicate invalid or expired tokens; verify and update credentials.
    • HTTP 404 errors may mean the resource path is incorrect or the resource does not exist.
    • Validation errors from the API can occur if required parameters are missing or malformed.
  • Resolutions:

    • Double-check API credentials and base URL configuration.
    • Use manual mode to explicitly specify resource and operation if automatic parsing fails.
    • Ensure network connectivity to the BookStack server.
    • Review the request description for clarity when using automatic mode.

Links and References

Discussion