@cutoptim/engine 1.6.0 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/types.gen.d.ts +35 -0
- package/dist/types.gen.js +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
package/dist/types.gen.d.ts
CHANGED
|
@@ -190,6 +190,10 @@ export interface NestStock {
|
|
|
190
190
|
exclusions?: Array<NestZone>;
|
|
191
191
|
/** Echoed on every sheet cut from this stock row. */
|
|
192
192
|
meta?: Record<string, unknown>;
|
|
193
|
+
/** Marker mode: this row is a ROLL of width `w` and free length (fabric, leather, film, any roll good). Give `w` only — no `h`, `polygon` or `exclusions` — and make it the only stock row. The answer is ONE sheet `w` wide whose `h` is the shortest length found (also `metrics.length`), edge gap included at both ends. Both engines: `lbf` answers synchronously; `max` (async) starts from that marker and spends `options.timeBudgetMs` on a strip search that may shorten it, never lengthen it. */
|
|
194
|
+
roll?: boolean;
|
|
195
|
+
/** With `roll` only: the longest the marker may be (at most 200000). Parts that do not fit within it are returned in `unplaced` — a roll never becomes a second sheet. Omit it and the length is unbounded up to 200000. */
|
|
196
|
+
maxLength?: number;
|
|
193
197
|
}
|
|
194
198
|
/** Solve options. All optional. */
|
|
195
199
|
export interface NestOptions {
|
|
@@ -288,6 +292,8 @@ export interface NestMetrics {
|
|
|
288
292
|
cutLength: number;
|
|
289
293
|
/** Σ `sheets[].pierces`. */
|
|
290
294
|
pierces: number;
|
|
295
|
+
/** Present only for a `roll` (marker mode): the marker length — the `h` of the one sheet, from the roll start to the far edge gap, rounded up to 0.001, in your unit. 0 when no part fits the roll width. */
|
|
296
|
+
length?: number;
|
|
291
297
|
}
|
|
292
298
|
/** Sheets used per request stock ROW ("quantity per sheet size"). The unit is the row, not the size: two rows with the same w × h but a different price or meta are two entries. */
|
|
293
299
|
export interface NestStockUsage {
|
|
@@ -313,6 +319,17 @@ export interface UnplacedNest {
|
|
|
313
319
|
name: string;
|
|
314
320
|
/** How many copies could not be placed. */
|
|
315
321
|
qty: number;
|
|
322
|
+
/** Only in `unplaced`, and only when the engine can tell. `too_large`: the part alone fits no rectangular sheet of its material — its bounding box plus the edge gap (`edgeClearance`, else `minSeparation`) on both sides is bigger than the sheet at every allowed rotation; `minSheet` says what would fit. `no_room`: it fits a sheet on its own, but no sheet had room left (limited stock with `respectStock`, spacing, the other parts). Absent when the job has a polygon sheet the part does not obviously fit. */
|
|
323
|
+
reason?: "too_large" | "no_room";
|
|
324
|
+
/** With `reason: "too_large"` only: the smallest rectangular sheet that holds this part alone, edge gap included on both sides, at the allowed rotation with the smallest bounding box. Rounded up to 0.001. */
|
|
325
|
+
minSheet?: {
|
|
326
|
+
/** Minimum sheet width. */
|
|
327
|
+
w: number;
|
|
328
|
+
/** Minimum sheet height (length). */
|
|
329
|
+
h: number;
|
|
330
|
+
/** The rotation, in degrees, these dimensions are for. */
|
|
331
|
+
rotation: number;
|
|
332
|
+
};
|
|
316
333
|
}
|
|
317
334
|
/** One material's totals across the sheets cut from it. */
|
|
318
335
|
export interface NestMaterialSummary {
|
|
@@ -1184,6 +1201,24 @@ export interface UsageResponse {
|
|
|
1184
1201
|
env?: "test";
|
|
1185
1202
|
/** Present (`"tenant"`) only for a key CutOptim issues to its own first-party service. Absent for every key you create in the dashboard. */
|
|
1186
1203
|
keyClass?: "tenant";
|
|
1204
|
+
trial?: UsageTrial;
|
|
1205
|
+
}
|
|
1206
|
+
/** Present only for a TEST key of an account without an Engine API subscription: such a key runs inside a free trial. While it is present, `used`, `limit` and `remaining` count the whole trial (not a calendar month) and `periodEnd` is the trial's last day. After `endsAt` every call answers 403 `key_revoked` with a message that names the trial. Absent for live keys and for test keys of a subscribed account. */
|
|
1207
|
+
export interface UsageTrial {
|
|
1208
|
+
/** When the trial ends (UTC timestamp). */
|
|
1209
|
+
endsAt: string;
|
|
1210
|
+
/** Calls allowed in the whole trial, across all the account's test keys. */
|
|
1211
|
+
callsLimit: number;
|
|
1212
|
+
/** Calls counted since the trial started. Refused and refunded calls are not counted. */
|
|
1213
|
+
callsUsed: number;
|
|
1214
|
+
/** `callsLimit` − `callsUsed`, never negative. */
|
|
1215
|
+
callsRemaining: number;
|
|
1216
|
+
/** Asynchronous engine `max` jobs allowed in the trial. Failed jobs are not counted. */
|
|
1217
|
+
maxJobsLimit: number;
|
|
1218
|
+
/** Engine `max` jobs submitted since the trial started (queued, running or succeeded). */
|
|
1219
|
+
maxJobsUsed: number;
|
|
1220
|
+
/** `maxJobsLimit` − `maxJobsUsed`, never negative. At 0 a new `max` job answers 402 `quota_exceeded`; engine `lbf` keeps working. */
|
|
1221
|
+
maxJobsRemaining: number;
|
|
1187
1222
|
}
|
|
1188
1223
|
export interface HealthResponse {
|
|
1189
1224
|
/** Always `"healthy"` when the process answers. */
|
package/dist/types.gen.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
// GENERATED by scripts/gen-sdks.ts from the CutOptim Engine API OpenAPI document — DO NOT EDIT.
|
|
2
|
-
// contract 1 · spec sha256
|
|
2
|
+
// contract 1 · spec sha256 3ee9cdfbd131610871eac13aacdd1739434688a0e4743ab71c9373d089ea232c · @cutoptim/engine 1.8.0
|
|
3
3
|
export {};
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.8.0";
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// The package version — rewritten by scripts/gen-sdks.ts together with package.json (sent as the User-Agent).
|
|
2
|
-
export const VERSION = '1.
|
|
2
|
+
export const VERSION = '1.8.0';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cutoptim/engine",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.8.0",
|
|
4
4
|
"description": "Official client for the CutOptim Engine API — cutting optimization (2D panels, 1D linear, timber, true-shape nesting) over HTTPS.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "CutOptim <support@cutoptim.com>",
|