@kittycad/lib
Advanced tools
@@ -12,10 +12,14 @@ import { File } from '../../models.js'; | ||
| * | ||
| * The request is `multipart/form-data`: - one JSON part named `body` (`FactoryIntakeForm`) whose `fields` object holds free-form intake data (material, quantity, finish, notes, …). It is stored verbatim, so fields can be added or renamed without an API change. - one or more file parts (any part name). At least one file is required. | ||
| * The request is `multipart/form-data`: - one JSON part named `body` (`FactoryIntakeForm`) whose `fields` object holds free-form intake data (material, finish, quantity, notes, …). It is stored verbatim, so fields can be added or renamed without an API change. - one or more file parts (any part name). At least one file is required. | ||
| * | ||
| * The submitter's identity (email, name, user id) comes from the authenticated account, not the form. | ||
| * | ||
| * Example `body` part: ```json { "fields": { "material": "aluminum-6061", "quantity": 10, "finish": "anodized", "notes": "deburr all edges" } } ``` | ||
| * `fields` is free-form and the server does not validate it, but the Factory operator dashboard renders `material` and `finish` as dropdowns with a known set of values. Send these exact strings so a submission maps onto a first-class option instead of showing up as a one-off custom entry: - `finish`: `"As machined"`, `"Bead blast"`, `"Anodized"`, or `"Other (see notes)"` — describe the real finish in `notes` when choosing `"Other (see notes)"`. - `material`: `"Aluminum 6061"`, or `"Other (see notes)"` (real material in `notes`). - `quantity`: a positive integer. | ||
| * | ||
| * Example request (curl): ``` curl -X POST https://api.zoo.dev/user/factory/jobs \ -H "Authorization: Bearer $ZOO_API_TOKEN" \ -F 'body={"fields":{"material":"aluminum-6061","quantity":10}};type=application/json' \ -F 'file=@bracket.step' ``` | ||
| * Any other value is still accepted and stored verbatim; it just appears in the dashboard as a custom entry rather than a recognized option. | ||
| * | ||
| * Example `body` part: ```json { "fields": { "material": "Aluminum 6061", "finish": "Anodized", "quantity": 10, "notes": "deburr all edges" } } ``` | ||
| * | ||
| * Example request (curl): ``` curl -X POST https://api.zoo.dev/user/factory/jobs \ -H "Authorization: Bearer $ZOO_API_TOKEN" \ -F 'body={"fields":{"material":"Aluminum 6061","finish":"Anodized","quantity":10}};type=application/json' \ -F 'file=@bracket.step' ``` | ||
| * | ||
| * Returns `201` with the created job (`FactoryJobResponse`). | ||
@@ -22,0 +26,0 @@ * |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"create_user_factory_job.d.ts","sourceRoot":"","sources":["../../../../../src/api/factory/create_user_factory_job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AACtC,OAAO,EAAE,MAAM,EAAc,MAAM,iBAAiB,CAAA;AAGpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AAEpD,UAAU,yBAAyB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,EAAE,IAAI,EAAE,CAAA;CACd;AAED,KAAK,0BAA0B,GAAG,kBAAkB,CAAA;AAEpD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAA8B,uBAAuB,CAAC,EACpD,MAAM,EACN,KAAK,GACN,EAAE,yBAAyB,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAgCjE"} | ||
| {"version":3,"file":"create_user_factory_job.d.ts","sourceRoot":"","sources":["../../../../../src/api/factory/create_user_factory_job.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AACtC,OAAO,EAAE,MAAM,EAAc,MAAM,iBAAiB,CAAA;AAGpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAA;AAEpD,UAAU,yBAAyB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,KAAK,EAAE,IAAI,EAAE,CAAA;CACd;AAED,KAAK,0BAA0B,GAAG,kBAAkB,CAAA;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,wBAA8B,uBAAuB,CAAC,EACpD,MAAM,EACN,KAAK,GACN,EAAE,yBAAyB,GAAG,OAAO,CAAC,0BAA0B,CAAC,CAgCjE"} |
+1
-1
| { | ||
| "name": "@kittycad/lib", | ||
| "version": "4.3.11", | ||
| "version": "4.3.12", | ||
| "description": "Javascript library for KittyCAD API", | ||
@@ -5,0 +5,0 @@ "type": "module", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
AI-detected potential malware
Supply chain riskAI has identified this package as malware. This is a strong signal that the package may be malicious.
AI-detected potential malware
Supply chain riskAI has identified this package as malware. This is a strong signal that the package may be malicious.
1577649
0.11%19764
0.08%