---
title: GitBook API Integration on Truto
slug: gitbook
category: Knowledge Management
canonical: "https://truto.one/integrations/detail/gitbook/"
---

# GitBook API Integration on Truto



**Category:** Knowledge Management  
**Status:** Generally available

## MCP-ready AI tools

Truto exposes 59 tools for GitBook that AI agents can call directly.

- **list_all_git_book_user** — Get the currently authenticated user in GitBook. Returns the user object for the account associated with the active credentials.
- **get_single_git_book_user_by_id** — Get a single GitBook user by id. Returns the user object. Required: id.
- **update_a_git_book_user_by_id** — Update a GitBook user by id using a partial payload. Required: id.
- **list_all_git_book_organizations** — List all GitBook organizations accessible to the caller. Returns a collection of organization objects from the items array.
- **get_single_git_book_organization_by_id** — Get a single GitBook organization by id. Returns the full organization object. Required: id.
- **create_a_git_book_organization** — Create a new GitBook organization. Returns the created organization object.
- **update_a_git_book_organization_by_id** — Update an existing GitBook organization by id. Returns the updated organization object. Required: id.
- **delete_a_git_book_organization_by_id** — Delete a GitBook organization by id. Returns an empty response on success. Required: id.
- **list_all_git_book_organization_members** — List all members of a GitBook organization. Returns a collection of member objects. Required: organization_id.
- **get_single_git_book_organization_member_by_id** — Get a single GitBook organization member by id. Returns the member object for the specified member. Required: organization_id, id.
- **update_a_git_book_organization_member_by_id** — Update a GitBook organization member by id. Required: organization_id, id.
- **delete_a_git_book_organization_member_by_id** — Delete a GitBook organization member by id, removing them from the organization. Returns an empty response on success. Required: organization_id, id.
- **list_all_git_book_organization_invites** — List all pending invites for a GitBook organization. Returns a collection of invite items. Required: organization_id.
- **create_a_git_book_organization_invite** — Create a new invite for a GitBook organization. Required: organization_id.
- **delete_a_git_book_organization_invite_by_id** — Delete an existing invite from a GitBook organization. Returns an empty response on success. Required: organization_id, id.
- **list_all_git_book_organization_teams** — List all teams within a GitBook organization. Returns a collection of team objects. Required: organization_id.
- **get_single_git_book_organization_team_by_id** — Get a single team in a GitBook organization by id. Returns the team object. Required: organization_id, id.
- **create_a_git_book_organization_team** — Create a new team within a GitBook organization. Returns the created team object. Required: organization_id.
- **update_a_git_book_organization_team_by_id** — Update an existing team in a GitBook organization by id. Returns the updated team object. Required: organization_id, id.
- **delete_a_git_book_organization_team_by_id** — Delete a team from a GitBook organization by id. Returns an empty response on success. Required: organization_id, id.
- **list_all_git_book_team_members** — List members belonging to a specific team in a GitBook organization. Returns a collection of team member objects. Required: organization_id, team_id.
- **list_all_git_book_sites** — List gitbook sites belonging to an organization. Returns a collection of site items. Required: organization_id.
- **get_single_git_book_site_by_id** — Get a single gitbook site by id within an organization. Returns the site object. Required: organization_id, id.
- **create_a_git_book_site** — Create a new gitbook site within an organization. Returns the created site object. Required: organization_id.
- **update_a_git_book_site_by_id** — Update an existing gitbook site by id within an organization. Returns the updated site object. Required: organization_id, id.
- **delete_a_git_book_site_by_id** — Delete a gitbook site by id within an organization. Returns an empty response on success. Required: organization_id, id.
- **list_all_git_book_site_spaces** — List site spaces within a gitbook site. Returns a collection of site space items. Required: organization_id, site_id.
- **list_all_git_book_site_sections** — List all site sections for a gitbook site within an organization. Returns a collection of site section items. Required: organization_id, site_id.
- **list_all_git_book_site_redirects** — List redirects configured for a GitBook site within an organization. Returns a collection of redirect items. Required: organization_id, site_id.
- **list_all_git_book_site_share_links** — List all share links for a GitBook site. Returns a collection of share link items. Required: organization_id, site_id.
- **create_a_git_book_site_share_link** — Create a new share link for a GitBook site. Returns the created share link object. Required: organization_id, site_id.
- **delete_a_git_book_site_share_link_by_id** — Delete a share link from a GitBook site by id. Returns an empty response on success. Required: organization_id, site_id, id.
- **list_all_git_book_collections** — List all gitbook collections belonging to an organization. Returns a list of collection items. Required: organization_id.
- **get_single_git_book_collection_by_id** — Get a single gitbook collection by id. Returns the collection object.
- **create_a_git_book_collection** — Create a new gitbook collection within an organization. Required: organization_id.
- **update_a_git_book_collection_by_id** — Update an existing gitbook collection by id. Required: id.
- **delete_a_git_book_collection_by_id** — Delete a gitbook collection by id. Returns an empty response on success. Required: id.
- **list_all_git_book_spaces** — List gitbook spaces belonging to an organization. Returns an array of space objects. Required: organization_id.
- **get_single_git_book_space_by_id** — Get a single gitbook space by id. Returns the full space object. Required: id.
- **create_a_git_book_space** — Create a new gitbook space within an organization. Returns the created space object. Required: organization_id.
- **update_a_git_book_space_by_id** — Update an existing gitbook space by id. Returns the updated space object. Required: id.
- **delete_a_git_book_space_by_id** — Delete a gitbook space by id. Returns an empty response on success. Required: id.
- **get_single_git_book_space_content_by_id** — Get the content of a GitBook space. Returns the content structure for the specified space. Required: space_id.
- **list_all_git_book_pages** — List all pages in a GitBook space. Returns an array of page objects from the space's content. Required: space_id.
- **get_single_git_book_page_by_id** — Get a single page from a GitBook space by id. Returns the page object for the specified page. Required: space_id, id.
- **list_all_git_book_files** — List files within a GitBook space. Returns an array of file items belonging to the specified space. Required: space_id.
- **get_single_git_book_file_by_id** — Get a single file by id from a GitBook space. Returns the file object for the specified file. Required: space_id and id.
- **list_all_git_book_change_requests** — List change requests for a GitBook space. Returns a collection of change request items. Required: space_id.
- **get_single_git_book_change_request_by_id** — Get a single change request by id from a GitBook space. Returns the change request object. Required: space_id, id.
- **create_a_git_book_change_request** — Create a new change request in a GitBook space. Returns the created change request object. Required: space_id.
- **update_a_git_book_change_request_by_id** — Update an existing change request in a GitBook space. Returns the updated change request object. Required: space_id, id.
- **list_all_git_book_change_request_reviews** — List reviews for a GitBook change request within a space. Returns a collection of review items. Required: space_id, change_request_id.
- **create_a_git_book_change_request_review** — Create a review for a GitBook change request within a space. Required: space_id, change_request_id.
- **list_all_git_book_space_permissions_users** — List user permissions for a GitBook space. Returns a collection of user permission records associated with the specified space. Required: space_id.
- **list_all_git_book_space_permissions_teams** — List team permissions for a GitBook space. Returns the collection of team permission entries associated with the specified space. Required: space_id.
- **list_all_git_book_integrations** — List all integrations available in GitBook. Returns a collection of integration objects.
- **get_single_git_book_integration_by_id** — Get a single GitBook integration by id. Returns the full integration object. Required: id.
- **list_all_git_book_custom_hostnames** — List all custom hostnames configured for a GitBook organization. Returns a collection of custom hostname items. Required: organization_id.
- **get_single_git_book_custom_hostname_by_id** — Get a single custom hostname by id for a GitBook organization. Returns the custom hostname object. Required: organization_id, id.

## How it works

1. **Link your customer's GitBook account.** Use Truto's frontend SDK; we handle every OAuth and API key flow so you don't need to create the OAuth app.
2. **Authentication is automatic.** Truto refreshes tokens, stores credentials securely, and injects them into every API request.
3. **Call Truto's API to reach GitBook.** The Proxy API is a 1-to-1 mapping of the GitBook API.
4. **Get a unified response format.** Every response uses a single shape, with cursor-based pagination and data in the `result` field.

## Use cases

- **Power AI support agents with GitBook knowledge** — Customer support and AI copilot platforms can let users connect their GitBook workspace to ingest spaces, pages, and collections into a vector store, grounding chatbot responses in the customer's own documentation.
- **Keep API docs in sync with code changes** — API management, CI/CD, and developer tooling platforms can push documentation updates as Change Requests in GitBook, ensuring published docs stay aligned with the latest API spec while preserving human review.
- **Automate release notes and spec drafts** — Project management and engineering tools can auto-generate draft pages in a designated GitBook space when epics ship, eliminating the manual documentation tax on engineers.
- **Provision documentation access during onboarding** — HR, IT, and identity platforms can invite new hires to GitBook organizations, assign them to teams, and audit space-level permissions as part of automated onboarding and offboarding flows.
- **Centralize knowledge in enterprise search** — Enterprise search and internal wiki aggregators can crawl GitBook spaces, pages, and files to make customer documentation discoverable alongside other internal knowledge sources.

## What you can build

- **Full content sync across the GitBook hierarchy** — Traverse organizations, collections, spaces, and pages to mirror the entire documentation tree into your product with structured metadata.
- **Change Request–based publishing workflow** — Programmatically create change requests, push updates, and trigger reviews so automated edits flow through GitBook's branch-and-merge review process before going live.
- **Site and share link management** — List published sites, manage their spaces and sections, and generate or revoke share links to control who can access documentation portals.
- **Team and member provisioning** — Create organization invites, manage teams, and update or remove members to automate access provisioning for internal knowledge bases.
- **Permissions auditing for sensitive docs** — Report on which users and teams have access to specific spaces so security and compliance tools can flag overexposed documentation.
- **File and asset ingestion** — Pull GitBook files alongside pages to build complete knowledge indexes that include attachments, images, and uploaded assets.

## FAQs

### How does authentication work for end users connecting their GitBook account?

Truto handles the GitBook auth flow on your behalf, including token storage and refresh. Your users connect their GitBook organization through a hosted connection flow, and your app calls Truto's unified endpoints without managing credentials directly.

### Can I write content back to GitBook, or is the integration read-only?

The integration supports both. You can read users, organizations, spaces, pages, files, and permissions, and you can write by creating spaces, collections, sites, share links, organization invites, teams, and change requests with reviews.

### How should automated documentation updates be published?

GitBook's recommended pattern is to create a Change Request rather than overwriting live content. Use the change request and change request review tools to propose updates and route them through human review before merge.

### How is GitBook's hierarchy represented?

Content is organized as Organizations → Collections → Spaces → Pages, with Sites representing published portals over one or more spaces. The available list and get tools let you traverse each level and fetch page-level content for indexing.

### Can I audit who has access to specific GitBook spaces?

Yes. You can list user-level and team-level permissions on a space, list organization teams and their members, and reconcile this against your own identity system for access reviews.

### How fresh is the data my application receives?

Data is fetched on-demand via Truto's API calls, so reads always reflect GitBook's current state. For ongoing sync, you can schedule polling against the list endpoints to detect changes to spaces, pages, change requests, and members.

## Related reading

- [Connect GitBook to ChatGPT: Manage Content and Team Collaboration](https://truto.one/blog/connect-gitbook-to-chatgpt-manage-content-and-team-collaboration/) — Learn how to securely connect GitBook to ChatGPT using an MCP server. Automate documentation updates, search team wikis, and manage change requests with AI.
- [Connect GitBook to Claude: Administer Spaces and Organization Data](https://truto.one/blog/connect-gitbook-to-claude-administer-spaces-and-organization-data/) — Learn how to connect GitBook to Claude using a managed MCP server. Automate documentation updates, manage organization permissions, and handle change requests.
- [Connect GitBook to AI Agents: Sync Documents and Change Requests](https://truto.one/blog/connect-gitbook-to-ai-agents-sync-documents-and-change-requests/) — Learn how to connect GitBook to AI agents using Truto's tools endpoint. Automate documentation workflows, sync spaces, and manage change requests programmatically.
