Explore how adaptive content transforms your docs into a dynamic, tailored experience for every user.
Read the docs
LogoLogo
ProductPricingLog inSign up
  • Documentation
  • Developers
  • Guides
  • Changelog
  • Help Center
  • Getting Started
    • Developer Documentation
    • Quickstart
    • Development
    • Publishing
  • Integrations
    • Introduction
    • Using the CLI
    • Configuration
    • ContentKit
      • Component reference
    • Integration runtime
  • Client library
  • Guides
    • Creating a custom unfurl action
    • Creating interactive blocks
    • Referencing your integration in Markdown
    • Working with HTTP requests
    • Using the CLI in CI/CD
  • GitBook API
    • Introduction
    • Authentication
    • API reference
      • Organizations
        • Organization members
        • Organization invites
        • Organization AI ask
      • Docs sites
        • Site share links
        • Site structure
        • Site auth
        • Site preview
        • Site customization
        • Site spaces
        • Site sections
        • Site section groups
        • Site redirects
        • Site MCP servers
        • Site ads
        • Site users
        • Site insights
        • Site AI ask
      • Collections
        • Collection users
        • Collection teams
      • Spaces
        • Space content
        • Space comments
        • Space embeds
        • Space users
        • Space teams
        • Space integrations
        • Git
      • Change requests
        • Change request content
        • Change request contributors
        • Change request reviewers
        • Change request comments
      • Translations
        • Glossary
      • Integrations
      • URLs
      • OpenAPI
        • OpenAPI spec versions
      • Conversations
      • Custom fonts
      • Subdomains
      • Users
      • Teams
        • Team members
      • SSO
      • Storage
      • Custom hostnames
      • System info
    • Rate limiting
    • Pagination
    • Errors
  • Marketplace
    • Overview
    • Submit your app for review
  • Resources
    • Concepts
    • Changelog
    • ContentKit playground
    • GitHub examples
Powered by GitBook
On this page
  1. GitBook API
  2. API reference

Custom fonts

Bring your own fonts to personalize your documentation style.

Was this helpful?

LogoLogo

Resources

  • Showcase
  • Enterprise
  • Status

Company

  • Careers
  • Blog
  • Community

Policies

  • Subprocessors
  • Terms of Service
CtrlK
  • The CustomizationFontDefinition object
  • GETList all custom fonts
  • PUTCreate a custom font
  • GETGet a custom font by its ID
  • POSTUpdate a custom font
  • DELETEDelete a custom font

Was this helpful?

Upload and manage custom fonts for branding or aesthetic purposes. Once added, fonts can be applied to your spaces or sites to achieve a unique look.

The CustomizationFontDefinition object

Attributes
all ofOptional

The CustomizationFontDefinition object

List all custom fonts

get
Authorizations
Path parameters
organizationIdstringRequired

The unique id of the organization

Responses
200

OK

application/json
Responseall of
404

Not Found

application/json
get

Create a custom font

put
Authorizations
Path parameters
organizationIdstringRequired

The unique id of the organization

Body

Defines a custom font and associated font faces with storage references.

fontFamilystring · min: 1 · max: 50Required

The human-readable font-family name used in CSS (e.g., "Open Sans", "Playfair Display").

Responses
201

Custom font created successfully.

application/json
Responseall of
404

Not Found

application/json
412

Invalid request data, such as missing required font weights.

application/json
put

Get a custom font by its ID

get
Authorizations
Path parameters
organizationIdstringRequired

The unique id of the organization

fontIdstringRequired

The unique ID of a font

Responses
200

Custom font.

application/json
Responseall of
404

Organization or font not found.

application/json
get

Update a custom font

post
Authorizations
Path parameters
organizationIdstringRequired

The unique id of the organization

fontIdstringRequired

The unique ID of a font

Body

Defines a custom font and associated font faces with storage references.

fontFamilystring · min: 1 · max: 50Optional

The human-readable font-family name used in CSS (e.g., "Open Sans", "Playfair Display").

Responses
201

Custom font created successfully.

application/json
Responseall of
404

Not Found

application/json
412

Invalid request data, such as missing required font weights.

application/json
post

Delete a custom font

delete
Authorizations
Path parameters
organizationIdstringRequired

The unique id of the organization

fontIdstringRequired

The unique ID of a font

Responses
204

Organization or font not found.

205

Custom font deleted successfully.

delete

No content

{
  "id": "text",
  "custom": true,
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "sources": [
        {
          "url": "https://example.com",
          "format": "woff2"
        }
      ]
    }
  ],
  "permissions": {
    "edit": true
  }
}
{
  "id": "text",
  "custom": true,
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "sources": [
        {
          "url": "https://example.com",
          "format": "woff2"
        }
      ]
    }
  ],
  "permissions": {
    "edit": true
  }
}
GET /v1/orgs/{organizationId}/fonts HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "next": {
    "page": "text"
  },
  "count": 1,
  "items": [
    {
      "id": "text",
      "custom": true,
      "fontFamily": "text",
      "fontFaces": [
        {
          "weight": 1,
          "sources": [
            {
              "url": "https://example.com",
              "format": "woff2"
            }
          ]
        }
      ],
      "permissions": {
        "edit": true
      }
    }
  ]
}
PUT /v1/orgs/{organizationId}/fonts HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 68

{
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "storageKey": "text"
    }
  ]
}
GET /v1/orgs/{organizationId}/fonts/{fontId} HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "id": "text",
  "custom": true,
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "sources": [
        {
          "url": "https://example.com",
          "format": "woff2"
        }
      ]
    }
  ],
  "permissions": {
    "edit": true
  }
}
POST /v1/orgs/{organizationId}/fonts/{fontId} HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 68

{
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "storageKey": "text"
    }
  ]
}
DELETE /v1/orgs/{organizationId}/fonts/{fontId} HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "id": "text",
  "custom": true,
  "fontFamily": "text",
  "fontFaces": [
    {
      "weight": 1,
      "sources": [
        {
          "url": "https://example.com",
          "format": "woff2"
        }
      ]
    }
  ],
  "permissions": {
    "edit": true
  }
}