curl --request POST \
--url https://app.polygon-one.com/api/ppwr/quantities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
[
{
"articleNumber": "<string>",
"periodYear": 2050,
"market": "<string>",
"quantity": 123
}
]
'import requests
url = "https://app.polygon-one.com/api/ppwr/quantities"
payload = [
{
"articleNumber": "<string>",
"periodYear": 2050,
"market": "<string>",
"quantity": 123
}
]
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([
{articleNumber: '<string>', periodYear: 2050, market: '<string>', quantity: 123}
])
};
fetch('https://app.polygon-one.com/api/ppwr/quantities', 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.polygon-one.com/api/ppwr/quantities",
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([
[
'articleNumber' => '<string>',
'periodYear' => 2050,
'market' => '<string>',
'quantity' => 123
]
]),
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://app.polygon-one.com/api/ppwr/quantities"
payload := strings.NewReader("[\n {\n \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\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://app.polygon-one.com/api/ppwr/quantities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("[\n {\n \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.polygon-one.com/api/ppwr/quantities")
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 \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\n }\n]"
response = http.request(request)
puts response.read_body{
"jobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "queued",
"statusUrl": "/api/import-jobs/6f7a…"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "batchTooLarge",
"maxBatchSize": 5000
}{
"error": "<string>",
"details": "<unknown>"
}Mengen übermitteln
The recurring ERP feed: how many pieces of each SKU were placed on which market in which year. Asynchronous — the request stages an import job and returns 202 with a jobId; poll GET /api/import-jobs/{jobId} (needs packaging:read) until status is terminal. Row validation runs BEFORE staging, so a malformed batch is a 400 you see immediately, never a job that fails minutes later. At most 5000 rows (413), at least one row (400). Restatement is the norm: the upsert is idempotent on (articleNumber, periodYear, market). After each accepted batch every packaging unit’s placed figure is recomputed as the sum of its linked SKUs’ quantities; a figure a human entered in the app is never overwritten and surfaces in the job result’s conflicts. The feed writes unit-level placements only — per-size figures are entered in the app and are neither read, overwritten nor cleared by a push. Requires packaging:write; customer workspace with the PPWR module enabled — see the guide.
curl --request POST \
--url https://app.polygon-one.com/api/ppwr/quantities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
[
{
"articleNumber": "<string>",
"periodYear": 2050,
"market": "<string>",
"quantity": 123
}
]
'import requests
url = "https://app.polygon-one.com/api/ppwr/quantities"
payload = [
{
"articleNumber": "<string>",
"periodYear": 2050,
"market": "<string>",
"quantity": 123
}
]
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([
{articleNumber: '<string>', periodYear: 2050, market: '<string>', quantity: 123}
])
};
fetch('https://app.polygon-one.com/api/ppwr/quantities', 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.polygon-one.com/api/ppwr/quantities",
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([
[
'articleNumber' => '<string>',
'periodYear' => 2050,
'market' => '<string>',
'quantity' => 123
]
]),
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://app.polygon-one.com/api/ppwr/quantities"
payload := strings.NewReader("[\n {\n \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\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://app.polygon-one.com/api/ppwr/quantities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("[\n {\n \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.polygon-one.com/api/ppwr/quantities")
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 \"articleNumber\": \"<string>\",\n \"periodYear\": 2050,\n \"market\": \"<string>\",\n \"quantity\": 123\n }\n]"
response = http.request(request)
puts response.read_body{
"jobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "queued",
"statusUrl": "/api/import-jobs/6f7a…"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "batchTooLarge",
"maxBatchSize": 5000
}{
"error": "<string>",
"details": "<unknown>"
}Autorisierungen
API key generated in Settings > API Keys. Include as Authorization: Bearer <key>.
Body
- object[]
- object
One placed-quantity row for POST /api/ppwr/quantities. Upsert key: (articleNumber, periodYear, market) — re-pushing a period with corrected numbers is the normal flow.
Internal article number of an existing article. An unknown number is the row error unknownArticleNumber; a key repeated inside one batch is first-seen-wins plus duplicateInFile on the later rows.
Calendar reporting year.
2000 <= x <= 2100ISO alpha-2 market code (case-insensitive, stored upper-case).
^[A-Za-z]{2}$Pieces placed on that market in that year. Required and non-negative — a blank quantity is a broken feed row, not zero.
Antwort
Batch accepted — async import job staged. Nothing imported yet; poll the job.