Listings
Update listing snapshot settings
Updates daily snapshot count and optional snapshot/boost time windows for one or more listings.
Update listing snapshot settings
curl --request PATCH \
--url https://app.pricepirate.com/api/v1/listings/snapshot-settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"listingKeys": [
{
"source": "IDEALO",
"country": "DE",
"externalId": "123456789"
}
],
"numberOfDailySnapshots": 4,
"snapshotTimeRangeStart": "2025-01-01T08:00:00Z",
"snapshotTimeRangeEnd": "2025-01-01T20:00:00Z",
"boostTimeRangeEnabled": true,
"boostTimeRangeStart": "2025-01-01T12:00:00Z",
"boostTimeRangeEnd": "2025-01-01T15:00:00Z",
"boostFactor": 3
}
'import requests
url = "https://app.pricepirate.com/api/v1/listings/snapshot-settings"
payload = {
"listingKeys": [
{
"source": "IDEALO",
"country": "DE",
"externalId": "123456789"
}
],
"numberOfDailySnapshots": 4,
"snapshotTimeRangeStart": "2025-01-01T08:00:00Z",
"snapshotTimeRangeEnd": "2025-01-01T20:00:00Z",
"boostTimeRangeEnabled": True,
"boostTimeRangeStart": "2025-01-01T12:00:00Z",
"boostTimeRangeEnd": "2025-01-01T15:00:00Z",
"boostFactor": 3
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
listingKeys: [{source: 'IDEALO', country: 'DE', externalId: '123456789'}],
numberOfDailySnapshots: 4,
snapshotTimeRangeStart: '2025-01-01T08:00:00Z',
snapshotTimeRangeEnd: '2025-01-01T20:00:00Z',
boostTimeRangeEnabled: true,
boostTimeRangeStart: '2025-01-01T12:00:00Z',
boostTimeRangeEnd: '2025-01-01T15:00:00Z',
boostFactor: 3
})
};
fetch('https://app.pricepirate.com/api/v1/listings/snapshot-settings', 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://app.pricepirate.com/api/v1/listings/snapshot-settings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'listingKeys' => [
[
'source' => 'IDEALO',
'country' => 'DE',
'externalId' => '123456789'
]
],
'numberOfDailySnapshots' => 4,
'snapshotTimeRangeStart' => '2025-01-01T08:00:00Z',
'snapshotTimeRangeEnd' => '2025-01-01T20:00:00Z',
'boostTimeRangeEnabled' => true,
'boostTimeRangeStart' => '2025-01-01T12:00:00Z',
'boostTimeRangeEnd' => '2025-01-01T15:00:00Z',
'boostFactor' => 3
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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 := "https://app.pricepirate.com/api/v1/listings/snapshot-settings"
payload := strings.NewReader("{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.patch("https://app.pricepirate.com/api/v1/listings/snapshot-settings")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.pricepirate.com/api/v1/listings/snapshot-settings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}"
response = http.request(request)
puts response.read_body{
"listing": {
"source": "IDEALO",
"country": "DE",
"externalId": "123456789",
"numberOfDailySnapshots": 4
},
"listings": [],
"updatedCount": 1
}{
"error": {
"code": "BAD_REQUEST",
"message": "JSON body must be an object",
"details": "Validation details may be included for invalid inputs.",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Missing or invalid Authorization header",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "FORBIDDEN",
"message": "Forbidden",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Resource not found",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "idempotency_key_reuse",
"message": "Idempotency-Key was already used for a different request",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit exceeded",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}Authorizations
Public API token passed as Authorization: Bearer .
Headers
Required for write requests. Reuse the same key only when retrying the exact same request.
Body
application/json
Snapshot settings to apply to the selected listing keys.
Minimum array length:
1Show child attributes
Show child attributes
Required range:
1 <= x <= 16Required range:
2 <= x <= 10Response
Successful response.
Was this page helpful?
⌘I
Update listing snapshot settings
curl --request PATCH \
--url https://app.pricepirate.com/api/v1/listings/snapshot-settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"listingKeys": [
{
"source": "IDEALO",
"country": "DE",
"externalId": "123456789"
}
],
"numberOfDailySnapshots": 4,
"snapshotTimeRangeStart": "2025-01-01T08:00:00Z",
"snapshotTimeRangeEnd": "2025-01-01T20:00:00Z",
"boostTimeRangeEnabled": true,
"boostTimeRangeStart": "2025-01-01T12:00:00Z",
"boostTimeRangeEnd": "2025-01-01T15:00:00Z",
"boostFactor": 3
}
'import requests
url = "https://app.pricepirate.com/api/v1/listings/snapshot-settings"
payload = {
"listingKeys": [
{
"source": "IDEALO",
"country": "DE",
"externalId": "123456789"
}
],
"numberOfDailySnapshots": 4,
"snapshotTimeRangeStart": "2025-01-01T08:00:00Z",
"snapshotTimeRangeEnd": "2025-01-01T20:00:00Z",
"boostTimeRangeEnabled": True,
"boostTimeRangeStart": "2025-01-01T12:00:00Z",
"boostTimeRangeEnd": "2025-01-01T15:00:00Z",
"boostFactor": 3
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
listingKeys: [{source: 'IDEALO', country: 'DE', externalId: '123456789'}],
numberOfDailySnapshots: 4,
snapshotTimeRangeStart: '2025-01-01T08:00:00Z',
snapshotTimeRangeEnd: '2025-01-01T20:00:00Z',
boostTimeRangeEnabled: true,
boostTimeRangeStart: '2025-01-01T12:00:00Z',
boostTimeRangeEnd: '2025-01-01T15:00:00Z',
boostFactor: 3
})
};
fetch('https://app.pricepirate.com/api/v1/listings/snapshot-settings', 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://app.pricepirate.com/api/v1/listings/snapshot-settings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'listingKeys' => [
[
'source' => 'IDEALO',
'country' => 'DE',
'externalId' => '123456789'
]
],
'numberOfDailySnapshots' => 4,
'snapshotTimeRangeStart' => '2025-01-01T08:00:00Z',
'snapshotTimeRangeEnd' => '2025-01-01T20:00:00Z',
'boostTimeRangeEnabled' => true,
'boostTimeRangeStart' => '2025-01-01T12:00:00Z',
'boostTimeRangeEnd' => '2025-01-01T15:00:00Z',
'boostFactor' => 3
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Idempotency-Key: <idempotency-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 := "https://app.pricepirate.com/api/v1/listings/snapshot-settings"
payload := strings.NewReader("{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Idempotency-Key", "<idempotency-key>")
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.patch("https://app.pricepirate.com/api/v1/listings/snapshot-settings")
.header("Idempotency-Key", "<idempotency-key>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.pricepirate.com/api/v1/listings/snapshot-settings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Idempotency-Key"] = '<idempotency-key>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"listingKeys\": [\n {\n \"source\": \"IDEALO\",\n \"country\": \"DE\",\n \"externalId\": \"123456789\"\n }\n ],\n \"numberOfDailySnapshots\": 4,\n \"snapshotTimeRangeStart\": \"2025-01-01T08:00:00Z\",\n \"snapshotTimeRangeEnd\": \"2025-01-01T20:00:00Z\",\n \"boostTimeRangeEnabled\": true,\n \"boostTimeRangeStart\": \"2025-01-01T12:00:00Z\",\n \"boostTimeRangeEnd\": \"2025-01-01T15:00:00Z\",\n \"boostFactor\": 3\n}"
response = http.request(request)
puts response.read_body{
"listing": {
"source": "IDEALO",
"country": "DE",
"externalId": "123456789",
"numberOfDailySnapshots": 4
},
"listings": [],
"updatedCount": 1
}{
"error": {
"code": "BAD_REQUEST",
"message": "JSON body must be an object",
"details": "Validation details may be included for invalid inputs.",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Missing or invalid Authorization header",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "FORBIDDEN",
"message": "Forbidden",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Resource not found",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "idempotency_key_reuse",
"message": "Idempotency-Key was already used for a different request",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit exceeded",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}{
"error": {
"code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"requestId": "1b11c2c2-7c6f-44d9-9980-02a77681b91f"
}
}