Platform-lane background-job inspection. List queued/running jobs, fetch one, and retry failures. Job payloads are always redacted (payload: null, payloadRedacted: true). Requires a platform credential, not a tenant bearer.
import { GatekeeperCore, PlatformJobsService } from '@orkait/sdk';
const jobs = new PlatformJobsService(core);Methods#
| Method | Returns | Notes |
|---|---|---|
list(filters?) | Page<Job> | filters: { status?, queue?, kind?, limit?, cursor? } |
get(id) | Job | single job |
retry(id) | Job | re-enqueue a failed/dead job |
Example#
const page = await jobs.list({ status: 'dead', limit: 50 });
for (const job of page.items) {
if (job.attemptCount < job.maxAttempts) {
await jobs.retry(job.id);
}
}