Scrape App Store privacy labels
curl --request POST \
--url http://localhost:3000/api/scrape \
--header 'Content-Type: application/json' \
--header 'Origin: <api-key>' \
--data '
{
"urls": [
"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580"
],
"resync": false
}
'import requests
url = "http://localhost:3000/api/scrape"
payload = {
"urls": ["https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580"],
"resync": False
}
headers = {
"Origin": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Origin: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
urls: ['https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580'],
resync: false
})
};
fetch('http://localhost:3000/api/scrape', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3000",
CURLOPT_URL => "http://localhost:3000/api/scrape",
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([
'urls' => [
'https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580'
],
'resync' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"Origin: <api-key>"
],
]);
$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 := "http://localhost:3000/api/scrape"
payload := strings.NewReader("{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Origin", "<api-key>")
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("http://localhost:3000/api/scrape")
.header("Origin", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3000/api/scrape")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Origin"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}"
response = http.request(request)
puts response.read_body{
"scraped": [
{
"id": 324684580,
"name": "Spotify - Music and Podcasts",
"url": "https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580",
"changeCount": 2,
"bundleId": "com.spotify.client",
"developer": "Spotify Ltd.",
"privacyPolicyUrl": "<string>",
"firstSeen": 123
}
],
"errors": [
{
"url": "<string>",
"error": "<string>"
}
]
}{
"error": "Admin token required"
}Scrape
Scrape App Store privacy labels
Fetches each App Store URL, parses the privacy section, and persists
the result. With resync: true, re-scrapes apps already in the DB and
produces change notifications.
POST
/
api
/
scrape
Scrape App Store privacy labels
curl --request POST \
--url http://localhost:3000/api/scrape \
--header 'Content-Type: application/json' \
--header 'Origin: <api-key>' \
--data '
{
"urls": [
"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580"
],
"resync": false
}
'import requests
url = "http://localhost:3000/api/scrape"
payload = {
"urls": ["https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580"],
"resync": False
}
headers = {
"Origin": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Origin: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
urls: ['https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580'],
resync: false
})
};
fetch('http://localhost:3000/api/scrape', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3000",
CURLOPT_URL => "http://localhost:3000/api/scrape",
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([
'urls' => [
'https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580'
],
'resync' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"Origin: <api-key>"
],
]);
$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 := "http://localhost:3000/api/scrape"
payload := strings.NewReader("{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Origin", "<api-key>")
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("http://localhost:3000/api/scrape")
.header("Origin", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3000/api/scrape")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Origin"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"urls\": [\n \"https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580\"\n ],\n \"resync\": false\n}"
response = http.request(request)
puts response.read_body{
"scraped": [
{
"id": 324684580,
"name": "Spotify - Music and Podcasts",
"url": "https://apps.apple.com/us/app/spotify-music-and-podcasts/id324684580",
"changeCount": 2,
"bundleId": "com.spotify.client",
"developer": "Spotify Ltd.",
"privacyPolicyUrl": "<string>",
"firstSeen": 123
}
],
"errors": [
{
"url": "<string>",
"error": "<string>"
}
]
}{
"error": "Admin token required"
}Authorizations
Same-origin CSRF check. The Origin header must match the request host;
enforced for every mutating verb (POST, PUT, PATCH, DELETE).
Body
application/json