Class RedactionJob

All Implemented Interfaces:
HasId, StripeActiveObject, StripeObjectInterface

public class RedactionJob extends ApiResource implements HasId
The Redaction Job object redacts Stripe objects. You can use it to coordinate the removal of personal information from selected objects, making them permanently inaccessible in the Stripe Dashboard and API.
  • Constructor Details

    • RedactionJob

      public RedactionJob()
  • Method Details

    • cancel

      public RedactionJob cancel() throws StripeException
      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.

      Throws:
      StripeException
    • cancel

      public RedactionJob cancel(RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • cancel

      public RedactionJob cancel(Map<String,Object> params) throws StripeException
      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.

      Throws:
      StripeException
    • cancel

      public RedactionJob cancel(Map<String,Object> params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • cancel

      public RedactionJob cancel(RedactionJobCancelParams params) throws StripeException
      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.

      Throws:
      StripeException
    • cancel

      public RedactionJob cancel(RedactionJobCancelParams params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • create

      public static RedactionJob create(Map<String,Object> params) throws StripeException
      Creates a redaction job. When a job is created, it will start to validate.
      Throws:
      StripeException
    • create

      public static RedactionJob create(Map<String,Object> params, RequestOptions options) throws StripeException
      Creates a redaction job. When a job is created, it will start to validate.
      Throws:
      StripeException
    • create

      public static RedactionJob create(RedactionJobCreateParams params) throws StripeException
      Creates a redaction job. When a job is created, it will start to validate.
      Throws:
      StripeException
    • create

      public static RedactionJob create(RedactionJobCreateParams params, RequestOptions options) throws StripeException
      Creates a redaction job. When a job is created, it will start to validate.
      Throws:
      StripeException
    • list

      public static RedactionJobCollection list(Map<String,Object> params) throws StripeException
      Returns a list of redaction jobs.
      Throws:
      StripeException
    • list

      public static RedactionJobCollection list(Map<String,Object> params, RequestOptions options) throws StripeException
      Returns a list of redaction jobs.
      Throws:
      StripeException
    • list

      Returns a list of redaction jobs.
      Throws:
      StripeException
    • list

      public static RedactionJobCollection list(RedactionJobListParams params, RequestOptions options) throws StripeException
      Returns a list of redaction jobs.
      Throws:
      StripeException
    • retrieve

      public static RedactionJob retrieve(String job) throws StripeException
      Retrieves the details of a previously created redaction job.
      Throws:
      StripeException
    • retrieve

      public static RedactionJob retrieve(String job, RequestOptions options) throws StripeException
      Retrieves the details of a previously created redaction job.
      Throws:
      StripeException
    • retrieve

      public static RedactionJob retrieve(String job, Map<String,Object> params, RequestOptions options) throws StripeException
      Retrieves the details of a previously created redaction job.
      Throws:
      StripeException
    • retrieve

      public static RedactionJob retrieve(String job, RedactionJobRetrieveParams params, RequestOptions options) throws StripeException
      Retrieves the details of a previously created redaction job.
      Throws:
      StripeException
    • run

      public RedactionJob run() throws StripeException
      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.

      Throws:
      StripeException
    • run

      public RedactionJob run(RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • run

      public RedactionJob run(Map<String,Object> params) throws StripeException
      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.

      Throws:
      StripeException
    • run

      public RedactionJob run(Map<String,Object> params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • run

      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.

      Throws:
      StripeException
    • run

      public RedactionJob run(RedactionJobRunParams params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • update

      public RedactionJob update(Map<String,Object> params) throws StripeException
      Updates the properties of a redaction job without running or canceling the job.

      If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.

      Throws:
      StripeException
    • update

      public RedactionJob update(Map<String,Object> params, RequestOptions options) throws StripeException
      Updates the properties of a redaction job without running or canceling the job.

      If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.

      Throws:
      StripeException
    • update

      public RedactionJob update(RedactionJobUpdateParams params) throws StripeException
      Updates the properties of a redaction job without running or canceling the job.

      If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.

      Throws:
      StripeException
    • update

      public RedactionJob update(RedactionJobUpdateParams params, RequestOptions options) throws StripeException
      Updates the properties of a redaction job without running or canceling the job.

      If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.

      Throws:
      StripeException
    • validate

      public RedactionJob validate() throws StripeException
      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.

      Throws:
      StripeException
    • validate

      public RedactionJob validate(RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • validate

      public RedactionJob validate(Map<String,Object> params) throws StripeException
      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.

      Throws:
      StripeException
    • validate

      public RedactionJob validate(Map<String,Object> params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • validate

      public RedactionJob validate(RedactionJobValidateParams params) throws StripeException
      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.

      Throws:
      StripeException
    • validate

      public RedactionJob validate(RedactionJobValidateParams params, RequestOptions options) throws StripeException
      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.

      Throws:
      StripeException
    • setResponseGetter

      public void setResponseGetter(StripeResponseGetter responseGetter)
      Description copied from interface: StripeActiveObject
      Method is used by the containing object or StripeResponseGetter implementations to set the StripeResponseGetter instance used to make further requests.
      Specified by:
      setResponseGetter in interface StripeActiveObject
      Overrides:
      setResponseGetter in class ApiResource
      Parameters:
      responseGetter - the StripeResponseGetter instance to use for making further requests.
    • getCreated

      public Long getCreated()
      Time at which the object was created. Measured in seconds since the Unix epoch.
    • getLivemode

      public Boolean getLivemode()
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • getObject

      public String getObject()
      String representing the object's type. Objects of the same type share the same value.

      Equal to privacy.redaction_job.

    • getObjects

      public RedactionJob.Objects getObjects()
      The objects to redact in this job.
    • getStatus

      public String getStatus()
      The status of the job.

      One of canceled, canceling, created, failed, ready, redacting, succeeded, or validating.

    • getValidationBehavior

      public String getValidationBehavior()
      Validation behavior determines how a job validates objects for redaction eligibility. Default is error.

      One of error, or fix.

    • setCreated

      public void setCreated(Long created)
      Time at which the object was created. Measured in seconds since the Unix epoch.
    • setId

      public void setId(String id)
      Unique identifier for the object.
    • setLivemode

      public void setLivemode(Boolean livemode)
      Has the value true if the object exists in live mode or the value false if the object exists in test mode.
    • setObject

      public void setObject(String object)
      String representing the object's type. Objects of the same type share the same value.

      Equal to privacy.redaction_job.

    • setObjects

      public void setObjects(RedactionJob.Objects objects)
      The objects to redact in this job.
    • setStatus

      public void setStatus(String status)
      The status of the job.

      One of canceled, canceling, created, failed, ready, redacting, succeeded, or validating.

    • setValidationBehavior

      public void setValidationBehavior(String validationBehavior)
      Validation behavior determines how a job validates objects for redaction eligibility. Default is error.

      One of error, or fix.

    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getId

      public String getId()
      Unique identifier for the object.
      Specified by:
      getId in interface HasId