Create DDS Statement
curl --request POST \
--url https://app.polygon-one.com/api/dds-statements \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"supplierId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"articles": [
{
"articleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
]
}
'import requests
url = "https://app.polygon-one.com/api/dds-statements"
payload = {
"supplierId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"articles": [
{
"articleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
]
}
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({
supplierId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
articles: [{articleId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', amount: 1}]
})
};
fetch('https://app.polygon-one.com/api/dds-statements', 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/dds-statements",
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([
'supplierId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'articles' => [
[
'articleId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'amount' => 1
]
]
]),
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/dds-statements"
payload := strings.NewReader("{\n \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\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://app.polygon-one.com/api/dds-statements")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.polygon-one.com/api/dds-statements")
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 \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}DDS-Erklärungen
DDS-Erklärung erstellen
Create a new Due Diligence Statement. The supplier must exist and the specified articles must be linked to that supplier. The DDS is created in draft status.
POST
/
api
/
dds-statements
Create DDS Statement
curl --request POST \
--url https://app.polygon-one.com/api/dds-statements \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"supplierId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"articles": [
{
"articleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
]
}
'import requests
url = "https://app.polygon-one.com/api/dds-statements"
payload = {
"supplierId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"articles": [
{
"articleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"amount": 1
}
]
}
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({
supplierId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
articles: [{articleId: '3c90c3cc-0d44-4b50-8888-8dd25736052a', amount: 1}]
})
};
fetch('https://app.polygon-one.com/api/dds-statements', 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/dds-statements",
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([
'supplierId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'articles' => [
[
'articleId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'amount' => 1
]
]
]),
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/dds-statements"
payload := strings.NewReader("{\n \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\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://app.polygon-one.com/api/dds-statements")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.polygon-one.com/api/dds-statements")
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 \"supplierId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"articles\": [\n {\n \"articleId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"amount\": 1\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}{
"error": "<string>",
"details": "<unknown>"
}Autorisierungen
API key generated in Settings > API Keys. Include as Authorization: Bearer <key>.
Body
application/json
The supplier for this DDS. All articles must be linked to this supplier.
import = goods entering the EU, export = goods leaving the EU, trade = intra-EU trade, domestic_production = produced within the EU
Verfügbare Optionen:
import, export, trade, domestic_production Minimum array length:
1Show child attributes
Show child attributes
Antwort
DDS statement created successfully
ID of the newly created DDS statement
⌘I