Approve one declared watch
const url = 'http://localhost:11044/api/v1/realms/example/watch-approvals/example/grant';const options = {method: 'POST', headers: {'X-Embabel-Api-Key': '<X-Embabel-Api-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:11044/api/v1/realms/example/watch-approvals/example/grant \ --header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>'JSON fields: installationId, expectedRevision.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Name of the admitted realm whose watch is approved; the body’s installationId and expectedRevision must name its current installation, or the change answers 409
Name of a watch the realm’s admitted capture declares, as the list route returns it; an undeclared name answers 400, and one already approved 409
Responses
Section titled “Responses”OK
A captured realm’s declared watches and their approvals, as GET /realms/{realmName}/watch-approvals and the grant and revoke routes answer, with the installation and revision the next change must name back
object
Digest of the realm content this installation admitted
The realm installation the watches belong to; a grant or revoke must send it back
The installation’s revision, after the change on a grant or revoke; the next grant or revoke must send it back as expectedRevision
Every watch the admitted realm declares, each with whether it is approved
One watch a captured realm declares: the lens it re-reads, its cron schedule, and whether the owner has approved it
object
True when the owner has approved this watch, so its schedule runs; approving it grants nothing on the lens or its handler
Id of the realm’s own lens the watch re-reads
Cron expression it re-reads the lens on, already checked against the host’s minimum interval
The watch’s name, as the grant and revoke routes take it

