Class: SafetyKit::Resources::DeletionRequests
- Inherits:
-
Object
- Object
- SafetyKit::Resources::DeletionRequests
- Defined in:
- lib/safety_kit/resources/deletion_requests.rb,
sig/safety_kit/resources/deletion_requests.rbs
Overview
Submit end-user deletion requests. Accepted requests are processed asynchronously.
Instance Method Summary collapse
-
#create(subject_user_id:, external_request_id: nil, requested_at: nil, request_options: {}) ⇒ SafetyKit::Models::DeletionRequestCreateResponse
Some parameter documentations has been truncated, see Models::DeletionRequestCreateParams for more details.
-
#initialize(client:) ⇒ DeletionRequests
constructor
private
A new instance of DeletionRequests.
Constructor Details
#initialize(client:) ⇒ DeletionRequests
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of DeletionRequests.
42 43 44 |
# File 'lib/safety_kit/resources/deletion_requests.rb', line 42 def initialize(client:) @client = client end |
Instance Method Details
#create(subject_user_id:, external_request_id: nil, requested_at: nil, request_options: {}) ⇒ SafetyKit::Models::DeletionRequestCreateResponse
Some parameter documentations has been truncated, see Models::DeletionRequestCreateParams for more details.
Submit an end-user data deletion request. SafetyKit validates the request, durably queues it, and asynchronously deletes the stored data associated with the subject user.
28 29 30 31 32 33 34 35 36 37 |
# File 'lib/safety_kit/resources/deletion_requests.rb', line 28 def create(params) parsed, = SafetyKit::DeletionRequestCreateParams.dump_request(params) @client.request( method: :post, path: "v1/deletion_requests", body: parsed, model: SafetyKit::Models::DeletionRequestCreateResponse, options: ) end |