GitBook Space Content API

Manage pages and content within a space.

Business capability
Content Management AE-170.70

Operations 25

GET /spaces/{spaceId}/search Full-text search across all pages in a space #
GET /spaces/{spaceId}/content Get the current published content revision of a space #
POST /spaces/{spaceId}/content/template Apply a content template to populate a space with initial pages #
GET /spaces/{spaceId}/content/pages List all pages in a space with their hierarchy and metadata #
GET /spaces/{spaceId}/content/files List all uploaded files and assets in a space #
GET /spaces/{spaceId}/content/files/{fileId} Get a specific uploaded file from a space by its ID #
GET /spaces/{spaceId}/content/page/{pageId} Get a single page from a space by its ID #
GET /spaces/{spaceId}/content/path/{pagePath} Get a page from a space by its URL path #
GET /spaces/{spaceId}/content/reusable-contents/{reusableContentId} Get a reusable content block from a space by its ID #
POST /spaces/{spaceId}/content/computed/document Compute and render a document from a structured content source #
POST /spaces/{spaceId}/content/computed/revision Compute and render a full revision from a structured content source #
GET /spaces/{spaceId}/documents/{documentId} Get a raw document from a space by its document ID #
GET /spaces/{spaceId}/revisions/{revisionId} Get a specific historical revision of a space #
GET /spaces/{spaceId}/revisions/{revisionId}/changes Get semantic content changes introduced by a revision #
GET /spaces/{spaceId}/revisions/{revisionId}/pages List all pages in a specific historical revision of a space #
GET /spaces/{spaceId}/revisions/{revisionId}/files List all files (images, assets) in a specific space revision #
GET /spaces/{spaceId}/revisions/{revisionId}/files/{fileId} Get a specific file from a space revision by its file ID #
GET /spaces/{spaceId}/revisions/{revisionId}/page/{pageId} Get a page from a specific historical revision by its page ID #
GET /spaces/{spaceId}/revisions/{revisionId}/page/{pageId}/document Get the raw document body of a page in a historical revision #
GET /spaces/{spaceId}/revisions/{revisionId}/path/{pagePath} Get a page from a specific historical revision by its URL path #
GET /spaces/{spaceId}/revisions/{revisionId}/reusable-contents/{reusableContentId} Get a reusable content block from a historical revision by its ID #
GET /spaces/{spaceId}/revisions/{revisionId}/reusable-contents/{reusableContentId}/document Get the document body of a reusable content block in a historical revision #
GET /spaces/{spaceId}/pdf Get a temporary URL to download a space or page as PDF #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/gitbook:gitbook-space-content-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

gitbook-space-content-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: GitBook Space Content API
  description: The GitBook API
  termsOfService: https://policies.gitbook.com
  contact:
    name: API Support
    url: https://gitbook.com/support
    email: support@gitbook.com
  version: 0.0.1-beta
servers:
- url: '{host}/v1'
  variables:
    host:
      default: https://api.gitbook.com
security:
- user: []
- user-internal: []
- user-staff: []
- integration: []
- integration-installation: []
tags:


# --- truncated at 32 KB (176 KB total) ---
# Full source: https://artifacts.apis.io/gitbook/openapi/gitbook-space-content-api-openapi.yml