Merge duplicate jobs
Folds the jobs in mergeIds into this one, the one you keep, then deletes them. Their reports, interviews, hiring decisions and talent history move to the kept job, missing fields are filled in from them, and the app's rules apply: where both have a decision the more recent stays, and every report is kept. The kept job's description stays. It is irreversible and nothing is refunded. Preview it first with POST /v1/jobs/{id}/merge-preview. While Probb is still working on any of the records the answer is merge_work_in_progress; a record that is still being added, or a closed job, is merge_not_ready. Several records are merged one after another; if one stops the rest, the ones already merged stay merged and repeating the request finishes the rest. Repeating a finished merge returns replayed: true and changes nothing. Send an Idempotency-Key too. Emits job.deleted for each merged job and job.updated for the kept one.
Required scope: jobs:write.
Errors
- 400:
invalid_content_type,invalid_idempotency_key,invalid_json,request_body_too_large,unknown_field - 401:
authentication_required,invalid_api_key - 403:
api_access_disabled,insufficient_scope - 404:
job_not_found - 409:
idempotency_key_reused,idempotency_request_in_progress,merge_not_ready,merge_work_in_progress - 422:
invalid_parameter - 429:
rate_limit_exceeded - 500:
api_error - 503:
maintenance_mode,service_unavailable
ApiKeyAuthorizationBearer <probb_live_<id>_<secret>>id*stringThe job's ID.
1 <= length <= 200Idempotency-Key?stringMakes 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.
1 <= length <= 255application/json- body
mergeIds*array<>The duplicate jobs to fold into this one, at most 10. List each once, and not the one you keep.
1 <= items <= 10Success.
application/json- response
object*stringkeeper*The kept job after the merge.
merged*array<>replayed*booleanTrue when every record had already been merged into this one by an earlier call: nothing new happened.
# 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/ID_VALUE/merge" \ -H "Authorization: Bearer $PROBB_API_KEY" \ -H "Idempotency-Key: $REQUEST_KEY" \ -H 'Content-Type: application/json' \ --data-binary '{ "mergeIds": [ "job_duplicate_1" ]}'{ "object": "job_merge", "keeper": { "object": "job", "id": "string", "externalId": "string", "title": "string", "description": "string", "company": "string", "team": "string", "location": "string", "level": "string", "employmentType": "full_time", "status": "open", "closedAt": "2019-08-24T14:15:22Z", "closeReason": "filled", "revision": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" }, "merged": [ { "id": "string", "reportsMoved": -9007199254740991 } ], "replayed": true}