Retrieves the details of a previously created redaction job.

Parameters

  • jobstringRequired

    RedactionJob object identifier

Returns

Returns the RedactionJob object.

GET /v1/privacy/redaction_jobs/:id
curl https://api.stripe.com/v1/privacy/redaction_jobs/prj_123 \
-u "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2:"
Response
{
"id": "prj_123",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "ready",
"validation_behavior": "error"
}

Returns a list of redaction jobs.

Parameters

No parameters.

More parameters

  • ending_beforestring

  • limitinteger

  • starting_afterstring

Returns

Returns a list of RedactionJob objects.

GET /v1/privacy/redaction_jobs
curl https://api.stripe.com/v1/privacy/redaction_jobs \
-u "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2:"
Response
{
"object": "list",
"url": "/v1/privacy/redaction_jobs",
"has_more": false,
"data": [
{
"id": "prj_123",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "validating",
"validation_behavior": "error"
},
{
"id": "prj_456",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "success",
"validation_behavior": "fix"
}
]
}

You can cancel a redaction job when it’s in one of these statuses: ready, failed.

Canceling the redaction job will abandon its attempt to redact the configured objects. A canceled job cannot be used again.

Parameters

  • jobstringRequired

    RedactionJob object identifier

Returns

Returns the RedactionJob object if successful. Otherwise, returns an error.

POST /v1/privacy/redaction_jobs/:id/cancel
curl -X POST https://api.stripe.com/v1/privacy/redaction_jobs/prj_123/cancel \
-u "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2:"
Response
{
"id": "prj_123",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "canceling",
"validation_behavior": "error"
}

Run a redaction job in a ready status.

When you run a job, the configured objects will be redacted asynchronously. This action is irreversible and cannot be canceled once started.

The status of the job will move to redacting. Once all of the objects are redacted, the status will become succeeded. If the job’s validation_behavior is set to fix, the automatic fixes will be applied to objects at this step.

Parameters

  • jobstringRequired

    RedactionJob object identifier

Returns

Returns the RedactionJob object if successful. Otherwise, returns an error.

POST /v1/privacy/redaction_jobs/:id/run
curl -X POST https://api.stripe.com/v1/privacy/redaction_jobs/prj_123/run \
-u "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2:"
Response
{
"id": "prj_123",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "redacting",
"validation_behavior": "error"
}

Validate a redaction job when it is in a failed status.

When a job is created, it automatically begins to validate on the configured objects’ eligibility for redaction. Use this to validate the job again after its validation errors are resolved or the job’s validation_behavior is changed.

The status of the job will move to validating. Once all of the objects are validated, the status of the job will become ready. If there are any validation errors preventing the job from running, the status will become failed.

Parameters

  • jobstringRequired

    RedactionJob object identifier

Returns

Returns the RedactionJob object if successful. Otherwise, returns an error.

POST /v1/privacy/redaction_jobs/:id/validate
curl -X POST https://api.stripe.com/v1/privacy/redaction_jobs/prj_123/validate \
-u "sk_test_BQokikJ...2HlWgH4olfQ2sk_test_BQokikJOvBiI2HlWgH4olfQ2:"
Response
{
"id": "prj_123",
"object": "privacy.redaction_job",
"created": 1234567890,
"livemode": true,
"status": "validating",
"validation_behavior": "error"
}