Add an external link to a site's navigation
Creates an external navigation link at the site root or in a section group. External links require a section-based site structure and cannot be placed inside a section. The destination must be an absolute HTTP or HTTPS URL. Draft links and links whose adaptive condition does not match are omitted from published structure responses. Use the generic structure sort operation after creation to change sibling order.
A unique entity identifier
^[a-zA-Z0-9_-]+$The unique id of the site
Title of the site section
Description of the site section
Name of the icon
gearAbsolute HTTP or HTTPS destination URL
ID of the section group to create the link in. Omit to place it at the site root.
Whether the external link should be created in draft mode
Adaptive condition controlling whether visitors see the link
External link added to the site
The site has a simple structure or the parent group is invalid
Unexpected Error
POST /v1/orgs/{organizationId}/sites/{siteId}/external-links HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 237
{
"title": "text",
"localizedTitle": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"description": "text",
"localizedDescription": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"icon": "gear",
"url": "https://example.com",
"parent": "text",
"draft": true,
"condition": "text"
}{
"object": "site-external-link",
"id": "text",
"title": "text",
"localizedTitle": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"description": "text",
"localizedDescription": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"icon": "gear",
"url": "https://example.com",
"sectionGroup": "text",
"draft": true,
"condition": "text"
}Last updated
Was this helpful?