Docs
API reference

Draft candidate feedback for several candidates

POST
/api/v1/jobs/{jobId}/candidate-kits/draft

Drafts candidate feedback for up to 25 of the job's reports at once, and answers 202 with a batch. Drafting runs in the background, a few reports at a time, as the key's owner; follow the batch with GET /v1/jobs/{jobId}/candidate-kits/draft/{batchId} until done is true. A report that already has a draft is drafted at once and left as it is. A report that cannot have feedback is unsupported with a reason (an earlier version of Probb, an unfinished analysis, no requirements, no saved candidate, or a report that is not part of the job) and the rest are queued. Nothing is sent to any candidate: drafts stay private to your organization until you release them, for several candidates with POST /v1/jobs/{jobId}/candidate-kits/release. The key's owner must be a member or admin. Send an Idempotency-Key so a retry returns the same batch instead of drafting again. Answers candidate_feedback_disabled for the whole batch while an admin has turned candidate feedback off in the organization settings.

Required scope: reports:write.

Errors

  • 400: invalid_content_type, invalid_idempotency_key, invalid_json, invalid_request, request_body_too_large, unknown_field
  • 401: authentication_required, invalid_api_key
  • 403: api_access_disabled, candidate_feedback_disabled, insufficient_scope, permission_denied
  • 404: job_not_found
  • 409: idempotency_key_reused, idempotency_request_in_progress
  • 422: invalid_parameter
  • 429: rate_limit_exceeded
  • 500: api_error
  • 503: maintenance_mode, service_unavailable

Authorization

ApiKey
headerAuthorizationBearer <probb_live_<id>_<secret>>

Path Parameters

jobId*string

The job's ID.

Length1 <= length <= 200

Header Parameters

Idempotency-Key?string

Makes retries safe. Repeating a request with the same key and body within 24 hours returns the original response with Idempotent-Replayed: true. The same key with a different body, or from a different API key, returns idempotency_key_reused.

Length1 <= length <= 255

Request Body

application/json
  1. body
reportIds*array<>

The job's reports to draft feedback for, at most 25. A report sent twice counts once. A report that is not part of the job is skipped, never revealed.

Items1 <= items <= 25

Response Body

Success.

application/json
  1. response
object*string
id*string

The batch's ID, to follow with GET /v1/jobs/{jobId}/candidate-kits/draft/{batchId}.

jobId*string

The job.

createdAt*string
Formatdate-time
done*boolean

True when nothing is left queued: every report is drafted, skipped or failed.

counts*
items*array<>
Example Request
# Set PROBB_URL and PROBB_API_KEY. Replace any *_VALUE placeholder and any example ID (such as job_example) with a real one.# Idempotency-Key is optional. Reuse the same key and body when retrying one logical write.curl --fail-with-body -X POST "$PROBB_URL/api/v1/jobs/JOB_ID_VALUE/candidate-kits/draft" \  -H "Authorization: Bearer $PROBB_API_KEY" \  -H "Idempotency-Key: $REQUEST_KEY" \  -H 'Content-Type: application/json' \  --data-binary '{  "reportIds": [    "rep_example_1",    "rep_example_2",    "rep_example_3"  ]}'
Example Response
{  "object": "candidate_kit_batch",  "id": "string",  "jobId": "string",  "createdAt": "2019-08-24T14:15:22Z",  "done": true,  "counts": {    "queued": -9007199254740991,    "drafted": -9007199254740991,    "unsupported": -9007199254740991,    "failed": -9007199254740991  },  "items": [    {      "reportId": "string",      "status": "queued",      "reason": "legacy_version",      "message": "string",      "candidateKitId": "string"    }  ]}