Set Units
PUT
/api/construct-models/:model_id/unitsSet Units
Request
Parameters
| Name | Location | Type | Required |
|---|---|---|---|
model_id | path | string | yes |
Bodyrequired
application/json
ViewerUnitsobject
| Property | Type | Required |
|---|---|---|
current | string | null | no |
force | string | null | no |
length | string | null | no |
temperature | string | null | no |
Raw schema
{
"properties": {
"current": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current"
},
"force": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Force"
},
"length": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Length"
},
"temperature": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Temperature"
}
},
"title": "ViewerUnits",
"type": "object"
}Responses
200Successful Response
application/json
ViewerUnitsobject
| Property | Type | Required |
|---|---|---|
current | string | null | no |
force | string | null | no |
length | string | null | no |
temperature | string | null | no |
Raw schema
{
"properties": {
"current": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current"
},
"force": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Force"
},
"length": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Length"
},
"temperature": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Temperature"
}
},
"title": "ViewerUnits",
"type": "object"
}422Validation Error
application/json
HTTPValidationErrorobject
| Property | Type | Required |
|---|---|---|
detail | object[] | no |
Raw schema
{
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"title": "Location",
"type": "array"
},
"msg": {
"title": "Message",
"type": "string"
},
"type": {
"title": "Error Type",
"type": "string"
}
},
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError",
"type": "object"
},
"title": "Detail",
"type": "array"
}
},
"title": "HTTPValidationError",
"type": "object"
}