Create a folder
const url = 'https://api.ebitex.io/content/management/v1/folders';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"name":"example","parentFolderId":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.ebitex.io/content/management/v1/folders \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "parentFolderId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'Creates a folder from { name, parentFolderId } and answers 201 Created with it. Omit parentFolderId for a top-level folder.
Creating inside a folder needs edit on that folder under the branch access rules, which apply to the key as they do to its role. The new folder inherits its parent’s access rules and allowed contracts until it declares its own.
Key: a management key with content.management.authoring.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
Examplegenerated
{ "name": "example", "parentFolderId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}Responses
Section titled “ Responses ”OK
missing_api_key or invalid_api_key: no key was sent, or it is unknown, revoked or expired.
payment_required: the organization’s subscription needs attention.
access_denied: the key’s role may view the parent folder but not edit it.
scope_denied: the key lacks this route’s scope. tier_required: the Content Management API needs the Pro plan or above. ip_denied: the caller’s address is outside the key’s allowed ranges. app_not_available: Content is not enabled for the organization.
parentFolderId names no folder, or one the key’s role cannot view.
Rate limit or quota exceeded; Retry-After says how long to wait. too_many_failed_authentications: too many bad keys from this address.