curl --request GET \
--url https://api.nestapi.com/v1/nesting/export \
--header 'Accept: <accept>' \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"NestingRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": true
},
"RenderPartLabelMode": "None",
"PartLabelHeight": 123,
"PartPreviewRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": true
}
}
'import requests
url = "https://api.nestapi.com/v1/nesting/export"
payload = {
"NestingRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": True
},
"RenderPartLabelMode": "None",
"PartLabelHeight": 123,
"PartPreviewRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": True
}
}
headers = {
"Accept": "<accept>",
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
Accept: '<accept>',
Authorization: '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
NestingRenderSettings: {
RenderFormat: 'PNG',
xDimension: 123,
yDimension: 123,
BackColorARGB: '<string>',
OutlineLineColorARGB: '<string>',
PartFillColorARGB: '<string>',
AutomaticallyChoosePartFillColor: true
},
RenderPartLabelMode: 'None',
PartLabelHeight: 123,
PartPreviewRenderSettings: {
RenderFormat: 'PNG',
xDimension: 123,
yDimension: 123,
BackColorARGB: '<string>',
OutlineLineColorARGB: '<string>',
PartFillColorARGB: '<string>',
AutomaticallyChoosePartFillColor: true
}
})
};
fetch('https://api.nestapi.com/v1/nesting/export', 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://api.nestapi.com/v1/nesting/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'NestingRenderSettings' => [
'RenderFormat' => 'PNG',
'xDimension' => 123,
'yDimension' => 123,
'BackColorARGB' => '<string>',
'OutlineLineColorARGB' => '<string>',
'PartFillColorARGB' => '<string>',
'AutomaticallyChoosePartFillColor' => true
],
'RenderPartLabelMode' => 'None',
'PartLabelHeight' => 123,
'PartPreviewRenderSettings' => [
'RenderFormat' => 'PNG',
'xDimension' => 123,
'yDimension' => 123,
'BackColorARGB' => '<string>',
'OutlineLineColorARGB' => '<string>',
'PartFillColorARGB' => '<string>',
'AutomaticallyChoosePartFillColor' => true
]
]),
CURLOPT_HTTPHEADER => [
"Accept: <accept>",
"Authorization: <api-key>",
"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://api.nestapi.com/v1/nesting/export"
payload := strings.NewReader("{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("Accept", "<accept>")
req.Header.Add("Authorization", "<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.get("https://api.nestapi.com/v1/nesting/export")
.header("Accept", "<accept>")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nestapi.com/v1/nesting/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Accept"] = '<accept>'
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}"
response = http.request(request)
puts response.read_body{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}Generate a production export for a completed nest
Generates an export from a completed nesting result and delivers it asynchronously to your webhook.
This call does not return the export in the response body. It validates the request up front, queues the export, and returns immediately with { "Success": true }. When the export has been generated it is POSTed to the WebHookUri you supply.
The request is validated synchronously before it is queued — a malformed or unsatisfiable request is rejected here with a clear error rather than being accepted and failing silently later. See the responses below.
Use ResponseType to choose what is produced. Each type requires the matching settings block to have been supplied on the original nesting request (a missing block is rejected up front):
Result(0) — part-placement details for the result. No settings required.Render(1) — a base64-encoded render (SVG or PNG) of the layout. RequiresRenderSettings.DXF(2) — a base64-encoded DXF file of the nested layout. RequiresDXFExportSettings.ReportSource(3) — statistics and base64 renderings for report generation. RequiresReportSourceSettings.RemnantExport(4) — a base64-encoded zip of DXF files representing the remnants. RequiresRemnantGenerationSettings.Runtime(5) — information about the result together with a render. SeeReportSourceRenderingSettingsbelow: on a GET it uses the original request’sReportSourceSettings(rejected if none were supplied); POST to this endpoint to supply the render settings on the call itself.PartsExport(6) — a DXF export of the individual part geometry. RequiresPartExportSettings.
Each ResponseType may be requested once per result by default; requesting an export you have already requested returns an error.
curl --request GET \
--url https://api.nestapi.com/v1/nesting/export \
--header 'Accept: <accept>' \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"NestingRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": true
},
"RenderPartLabelMode": "None",
"PartLabelHeight": 123,
"PartPreviewRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": true
}
}
'import requests
url = "https://api.nestapi.com/v1/nesting/export"
payload = {
"NestingRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": True
},
"RenderPartLabelMode": "None",
"PartLabelHeight": 123,
"PartPreviewRenderSettings": {
"RenderFormat": "PNG",
"xDimension": 123,
"yDimension": 123,
"BackColorARGB": "<string>",
"OutlineLineColorARGB": "<string>",
"PartFillColorARGB": "<string>",
"AutomaticallyChoosePartFillColor": True
}
}
headers = {
"Accept": "<accept>",
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
Accept: '<accept>',
Authorization: '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
NestingRenderSettings: {
RenderFormat: 'PNG',
xDimension: 123,
yDimension: 123,
BackColorARGB: '<string>',
OutlineLineColorARGB: '<string>',
PartFillColorARGB: '<string>',
AutomaticallyChoosePartFillColor: true
},
RenderPartLabelMode: 'None',
PartLabelHeight: 123,
PartPreviewRenderSettings: {
RenderFormat: 'PNG',
xDimension: 123,
yDimension: 123,
BackColorARGB: '<string>',
OutlineLineColorARGB: '<string>',
PartFillColorARGB: '<string>',
AutomaticallyChoosePartFillColor: true
}
})
};
fetch('https://api.nestapi.com/v1/nesting/export', 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://api.nestapi.com/v1/nesting/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'NestingRenderSettings' => [
'RenderFormat' => 'PNG',
'xDimension' => 123,
'yDimension' => 123,
'BackColorARGB' => '<string>',
'OutlineLineColorARGB' => '<string>',
'PartFillColorARGB' => '<string>',
'AutomaticallyChoosePartFillColor' => true
],
'RenderPartLabelMode' => 'None',
'PartLabelHeight' => 123,
'PartPreviewRenderSettings' => [
'RenderFormat' => 'PNG',
'xDimension' => 123,
'yDimension' => 123,
'BackColorARGB' => '<string>',
'OutlineLineColorARGB' => '<string>',
'PartFillColorARGB' => '<string>',
'AutomaticallyChoosePartFillColor' => true
]
]),
CURLOPT_HTTPHEADER => [
"Accept: <accept>",
"Authorization: <api-key>",
"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://api.nestapi.com/v1/nesting/export"
payload := strings.NewReader("{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("Accept", "<accept>")
req.Header.Add("Authorization", "<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.get("https://api.nestapi.com/v1/nesting/export")
.header("Accept", "<accept>")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nestapi.com/v1/nesting/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Accept"] = '<accept>'
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"NestingRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n },\n \"RenderPartLabelMode\": \"None\",\n \"PartLabelHeight\": 123,\n \"PartPreviewRenderSettings\": {\n \"RenderFormat\": \"PNG\",\n \"xDimension\": 123,\n \"yDimension\": 123,\n \"BackColorARGB\": \"<string>\",\n \"OutlineLineColorARGB\": \"<string>\",\n \"PartFillColorARGB\": \"<string>\",\n \"AutomaticallyChoosePartFillColor\": true\n }\n}"
response = http.request(request)
puts response.read_body{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}{
"Success": true,
"Error": "<string>"
}Authorizations
Headers
Accept Header
application/json Query Parameters
The completed job to export. This is NestIdentifier in the webhook payload, and is the id returned from the nesting endpoint.
The specific result to export. This is ResultIdentity in the webhook payload and in GET /v1/nesting/status.
Which export to generate. Accepts the name or the integer — see the endpoint description for the meaning of each value and the settings it requires.
Result, Render, DXF, ReportSource, RemnantExport, Runtime, PartsExport The URL the generated export is POSTed to when it is ready. Required, and must be an absolute HTTPS URL — without it the export has nowhere to be delivered.
Uri
Body
Render settings for a Runtime export, supplied on a POST to this endpoint. When omitted (and always on a GET) the original nesting request's ReportSourceSettings are used instead; a Runtime export with neither is rejected. Ignored for every other ResponseType.
Settings for the renderings generated for a ReportSource: the per-nest layout render and the per-part preview render, plus how parts are labelled.
Settings for the generation of requested nesting result renderings
Show child attributes
Show child attributes
How each part is labelled in the nest rendering (none, identifier, or part name). Values: None — No part labels; ID — Label each part with its identifier; PartName — Label each part with its part name.
None, ID, PartName Height of the part label text, in millimetres. Left null for automatic sizing.
Settings for the generation of requested nesting result renderings
Show child attributes
Show child attributes
Response
The export request was accepted and queued for delivery to your webhook.