Update machine-api spec (#4201)
* YOYO NEW API SPEC! * New machine-api types * empt --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
committed by
GitHub
parent
7218efc489
commit
057ee479c3
@ -125,67 +125,144 @@
|
|||||||
"oneOf": [
|
"oneOf": [
|
||||||
{
|
{
|
||||||
"description": "polylactic acid based plastics",
|
"description": "polylactic acid based plastics",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Pla"
|
"pla"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "acrylonitrile butadiene styrene based plastics",
|
"description": "acrylonitrile butadiene styrene based plastics",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Abs"
|
"abs"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "polyethylene terephthalate glycol based plastics",
|
"description": "polyethylene terephthalate glycol based plastics",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Petg"
|
"petg"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "unsuprisingly, nylon based",
|
"description": "unsuprisingly, nylon based",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Nylon"
|
"nylon"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "thermoplastic polyurethane based urethane material",
|
"description": "thermoplastic polyurethane based urethane material",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Tpu"
|
"tpu"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "polyvinyl alcohol based material",
|
"description": "polyvinyl alcohol based material",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Pva"
|
"pva"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "high impact polystyrene based material",
|
"description": "high impact polystyrene based material",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Hips"
|
"hips"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "composite material with stuff in other stuff, something like PLA mixed with carbon fiber, kevlar, or fiberglass",
|
"description": "composite material with stuff in other stuff, something like PLA mixed with carbon fiber, kevlar, or fiberglass",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Composite"
|
"composite"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "none of the above, buyer beware",
|
"description": "None of the above, likely a custom material that we get directly from the printer.",
|
||||||
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name of the material.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"Other"
|
"other"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"name",
|
||||||
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"HardwareConfiguration": {
|
"HardwareConfiguration": {
|
||||||
@ -193,21 +270,40 @@
|
|||||||
"oneOf": [
|
"oneOf": [
|
||||||
{
|
{
|
||||||
"description": "No configuration is possible. This isn't the same conceptually as an `Option<HardwareConfiguration>`, because this indicates we positively know there is no possible configuration changes that are possible with this method of manufcture.",
|
"description": "No configuration is possible. This isn't the same conceptually as an `Option<HardwareConfiguration>`, because this indicates we positively know there is no possible configuration changes that are possible with this method of manufcture.",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
"enum": [
|
"enum": [
|
||||||
"None"
|
"none"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
|
||||||
{
|
|
||||||
"additionalProperties": false,
|
|
||||||
"description": "Hardware configuration specific to FDM based printers",
|
|
||||||
"properties": {
|
|
||||||
"Fdm": {
|
|
||||||
"$ref": "#/components/schemas/FdmHardwareConfiguration"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": [
|
"required": [
|
||||||
"Fdm"
|
"type"
|
||||||
|
],
|
||||||
|
"type": "object"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Hardware configuration specific to FDM based printers",
|
||||||
|
"properties": {
|
||||||
|
"config": {
|
||||||
|
"allOf": [
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/FdmHardwareConfiguration"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "The configuration for the FDM printer."
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"enum": [
|
||||||
|
"fdm"
|
||||||
|
],
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"config",
|
||||||
|
"type"
|
||||||
],
|
],
|
||||||
"type": "object"
|
"type": "object"
|
||||||
}
|
}
|
||||||
@ -422,21 +518,21 @@
|
|||||||
{
|
{
|
||||||
"description": "Use light to cure a resin to build up layers.",
|
"description": "Use light to cure a resin to build up layers.",
|
||||||
"enum": [
|
"enum": [
|
||||||
"Stereolithography"
|
"stereolithography"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "Fused Deposition Modeling, layers of melted plastic.",
|
"description": "Fused Deposition Modeling, layers of melted plastic.",
|
||||||
"enum": [
|
"enum": [
|
||||||
"FusedDeposition"
|
"fused_deposition"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"description": "\"Computer numerical control\" - machine that grinds away material from a hunk of material to construct a part.",
|
"description": "\"Computer numerical control\" - machine that grinds away material from a hunk of material to construct a part.",
|
||||||
"enum": [
|
"enum": [
|
||||||
"Cnc"
|
"cnc"
|
||||||
],
|
],
|
||||||
"type": "string"
|
"type": "string"
|
||||||
}
|
}
|
||||||
|
59
src/lib/machine-api.d.ts
vendored
59
src/lib/machine-api.d.ts
vendored
@ -146,20 +146,55 @@ export interface components {
|
|||||||
}
|
}
|
||||||
/** @description The material that the filament is made of. */
|
/** @description The material that the filament is made of. */
|
||||||
FilamentMaterial:
|
FilamentMaterial:
|
||||||
| 'Pla'
|
| {
|
||||||
| 'Abs'
|
/** @enum {string} */
|
||||||
| 'Petg'
|
type: 'pla'
|
||||||
| 'Nylon'
|
}
|
||||||
| 'Tpu'
|
| {
|
||||||
| 'Pva'
|
/** @enum {string} */
|
||||||
| 'Hips'
|
type: 'abs'
|
||||||
| 'Composite'
|
}
|
||||||
| 'Other'
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'petg'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'nylon'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'tpu'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'pva'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'hips'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'composite'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @description The name of the material. */
|
||||||
|
name: string
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'other'
|
||||||
|
}
|
||||||
/** @description The hardware configuration of a machine. */
|
/** @description The hardware configuration of a machine. */
|
||||||
HardwareConfiguration:
|
HardwareConfiguration:
|
||||||
| 'None'
|
|
||||||
| {
|
| {
|
||||||
Fdm: components['schemas']['FdmHardwareConfiguration']
|
/** @enum {string} */
|
||||||
|
type: 'none'
|
||||||
|
}
|
||||||
|
| {
|
||||||
|
/** @description The configuration for the FDM printer. */
|
||||||
|
config: components['schemas']['FdmHardwareConfiguration']
|
||||||
|
/** @enum {string} */
|
||||||
|
type: 'fdm'
|
||||||
}
|
}
|
||||||
/** @description Information regarding a connected machine. */
|
/** @description Information regarding a connected machine. */
|
||||||
MachineInfoResponse: {
|
MachineInfoResponse: {
|
||||||
@ -224,7 +259,7 @@ export interface components {
|
|||||||
state: 'failed'
|
state: 'failed'
|
||||||
}
|
}
|
||||||
/** @description Specific technique by which this Machine takes a design, and produces a real-world 3D object. */
|
/** @description Specific technique by which this Machine takes a design, and produces a real-world 3D object. */
|
||||||
MachineType: 'Stereolithography' | 'FusedDeposition' | 'Cnc'
|
MachineType: 'stereolithography' | 'fused_deposition' | 'cnc'
|
||||||
/** @description A nozzle diameter. */
|
/** @description A nozzle diameter. */
|
||||||
NozzleDiameter: '0.2' | '0.4' | '0.6' | '0.8'
|
NozzleDiameter: '0.2' | '0.4' | '0.6' | '0.8'
|
||||||
/** @description The response from the `/ping` endpoint. */
|
/** @description The response from the `/ping` endpoint. */
|
||||||
|
Reference in New Issue
Block a user