Import content into a space from a website
A unique entity identifier
^[a-zA-Z0-9_-]+$ID of the site the import is for, to list it among that site's imports. Only needed when the target space does not belong to the site yet — a site being set up, whose space is attached once the import has started. Otherwise the site is resolved from the space.
Enhance the imported content with AI
trueImport run created successfully.
Type of Object, always equals to "import-run"
Unique ID of the import
Date when the import has started
Filled when the imported is in status "completed"
Date when the import was requested
Date when the import was last updated
Status of the import
Reason for the import failure when status is failed.
Where the content is imported from.
ID of the site the target space belongs to, when it belongs to exactly one.
ID of the user who started the import.
Bad Request
Not Found
POST /v1/org/{organizationId}/imports HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 149
{
"source": {
"type": "website",
"url": "https://example.com"
},
"target": {
"space": "text",
"changeRequest": "text",
"page": "text"
},
"site": "text",
"enhance": true
}{
"object": "import-run",
"id": "text",
"startedAt": "2026-01-01T00:00:00.000Z",
"completedAt": "2026-01-01T00:00:00.000Z",
"createdAt": "2026-01-01T00:00:00.000Z",
"updatedAt": "2026-01-01T00:00:00.000Z",
"status": "pending",
"reason": "text",
"source": {
"type": "website",
"url": "https://example.com"
},
"target": {
"space": "text",
"changeRequest": "text",
"page": "text"
},
"site": "text",
"createdBy": "text",
"urls": {
"location": "https://example.com"
},
"pages": [
{
"id": "text",
"sourceURL": "text",
"type": "page",
"status": "complete"
}
]
}Last updated
Was this helpful?