cURL
curl --request POST \
--url https://api.osohq.com/api/bulk_delete \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
[
{
"predicate": "<string>",
"args": [
{
"type": "<string>",
"id": "<string>"
}
]
}
]
'import requests
url = "https://api.osohq.com/api/bulk_delete"
payload = [
{
"predicate": "<string>",
"args": [
{
"type": "<string>",
"id": "<string>"
}
]
}
]
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([{predicate: '<string>', args: [{type: '<string>', id: '<string>'}]}])
};
fetch('https://api.osohq.com/api/bulk_delete', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.osohq.com/api/bulk_delete"
payload := strings.NewReader("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\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.osohq.com/api/bulk_delete")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.osohq.com/api/bulk_delete")
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 {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]"
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.osohq.com/api/bulk_delete");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);{
"message": "<string>"
}{
"message": "<string>"
}Centralized Authorization Data
Post bulk delete
deprecated
Delete many facts in a single transaction.
DEPRECATED: Prefer POST /batch with payload [{"deletes": <bulk_data>}].
POST
/
bulk_delete
cURL
curl --request POST \
--url https://api.osohq.com/api/bulk_delete \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
[
{
"predicate": "<string>",
"args": [
{
"type": "<string>",
"id": "<string>"
}
]
}
]
'import requests
url = "https://api.osohq.com/api/bulk_delete"
payload = [
{
"predicate": "<string>",
"args": [
{
"type": "<string>",
"id": "<string>"
}
]
}
]
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([{predicate: '<string>', args: [{type: '<string>', id: '<string>'}]}])
};
fetch('https://api.osohq.com/api/bulk_delete', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.osohq.com/api/bulk_delete"
payload := strings.NewReader("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\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.osohq.com/api/bulk_delete")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.osohq.com/api/bulk_delete")
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 {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]"
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.osohq.com/api/bulk_delete");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("[\n {\n \"predicate\": \"<string>\",\n \"args\": [\n {\n \"type\": \"<string>\",\n \"id\": \"<string>\"\n }\n ]\n }\n]", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);{
"message": "<string>"
}{
"message": "<string>"
}Was this page helpful?
⌘I