Trigger a repository process
POST
/api/admin/process/{id}
const url = 'https://example.com/api/admin/process/example';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"syncAssets":true,"syncDocs":true,"reloadGraph":true}'};
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://example.com/api/admin/process/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "syncAssets": true, "syncDocs": true, "reloadGraph": true }'Starts an asset sync, document sync, or GraphQL server reload for a repository. Requires admin.repositories.crawl or admin.repositories.migration.run.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
Repository configuration ID
string
Request Body
Section titled “Request Body”Media typeapplication/json
object
syncAssets
Queue an OCM asset sync for the repository
boolean
syncDocs
Start a document sync subprocess
boolean
reloadGraph
Reload the GraphQL server for the repository
boolean
Examplegenerated
{ "syncAssets": true, "syncDocs": true, "reloadGraph": true}Responses
Section titled “Responses”Process started
Media typeapplication/json
object
message
required
Human-readable status message
string
Example
{ "message": "Sync Process Started"}Access denied
Media typeapplication/json
object
error
required
Indicates an error occurred
boolean
message
required
Error message describing what went wrong
string
Example
{ "error": true, "message": "Item not found"}