Ask for the organization's data to be erased
curl --request POST \
--url https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"message": ""
}'import requests
url = "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request"
payload = { "message": "" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({message: ''})
};
fetch('https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'message' => ''
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request"
payload := strings.NewReader("{\n \"message\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"message\": \"\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"message\": \"\"\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created": "2023-11-07T05:31:56Z",
"respond_by": "2023-12-25",
"decided_at": "2023-11-07T05:31:56Z",
"decision_note": "<string>",
"plan": {
"relationship_end": "2023-12-25",
"respond_by": "2023-12-25",
"erasable": [
{
"category": "prospection",
"count": 123
}
],
"retained": [
{
"category": "accounting",
"reference": "<string>",
"until": "2023-12-25"
}
],
"blockers": [
"active_service"
]
},
"outcome": "<unknown>"
}Privacy
Ask for the organization's data to be erased
Registers the request with the retention plan as it was shown, sends the acknowledgement that states the one-month deadline, and puts the request in the staff review queue.
POST
/
v1
/
organizations
/
{organization_id}
/
privacy
/
erasure-request
Ask for the organization's data to be erased
curl --request POST \
--url https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"message": ""
}'import requests
url = "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request"
payload = { "message": "" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({message: ''})
};
fetch('https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'message' => ''
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request"
payload := strings.NewReader("{\n \"message\": \"\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"message\": \"\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onetsolutions.net/v1/organizations/{organization_id}/privacy/erasure-request")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"message\": \"\"\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created": "2023-11-07T05:31:56Z",
"respond_by": "2023-12-25",
"decided_at": "2023-11-07T05:31:56Z",
"decision_note": "<string>",
"plan": {
"relationship_end": "2023-12-25",
"respond_by": "2023-12-25",
"erasable": [
{
"category": "prospection",
"count": 123
}
],
"retained": [
{
"category": "accounting",
"reference": "<string>",
"until": "2023-12-25"
}
],
"blockers": [
"active_service"
]
},
"outcome": "<unknown>"
}Authorizations
Use Authorization: Bearer <token> header. Token can be a JWT token or an API key (format: sk-onetsolutions-...).
Path Parameters
Body
application/json
Maximum string length:
2000Response
pending- Awaiting reviewapproved- Approved, erasure runningexecuted- Executedrefused- Refusedcancelled- Cancelled by the customer
Available options:
pending, approved, executed, refused, cancelled Show child attributes
Show child attributes
⌘I

