API → Unit → Convert mass units
Parameters
Name
Type
Req.
Possible values
g
: Grams <https://en.wikipedia.org/wiki/Gram>kg
: Kilograms <https://en.wikipedia.org/wiki/Kilogram>lb
: Pounds <https://en.wikipedia.org/wiki/Pound_(mass)>
Possible values
g
: Grams <https://en.wikipedia.org/wiki/Gram>kg
: Kilograms <https://en.wikipedia.org/wiki/Kilogram>lb
: Pounds <https://en.wikipedia.org/wiki/Pound_(mass)>
Returns
- 200 OK
successful operation
Name
Type
Req.
body
objectoptionalObject Properties
Possible values
g
: Grams <https://en.wikipedia.org/wiki/Gram>kg
: Kilograms <https://en.wikipedia.org/wiki/Kilogram>lb
: Pounds <https://en.wikipedia.org/wiki/Pound_(mass)>
Possible values
g
: Grams <https://en.wikipedia.org/wiki/Gram>kg
: Kilograms <https://en.wikipedia.org/wiki/Kilogram>lb
: Pounds <https://en.wikipedia.org/wiki/Pound_(mass)>
Possible values
queued
: The async API call is queued.uploaded
: The async API call was uploaded to be converted.in_progress
: The async API call is in progress.completed
: The async API call has completed.failed
: The async API call has failed.
get
/unit/conversion/mass/{input_unit}/{output_unit}$ curl "https://api.zoo.dev/unit/conversion/mass/{input_unit}/{output_unit}" \
--header "Authorization: Bearer $TOKEN"
200 OK
Response{
"completed_at": "2024-11-22T17:04:25.217Z",
"created_at": "2024-11-22T17:04:25.217Z",
"error": "eYTQcM2X0PieyjUkfSpOurCAJ",
"id": "2b757d62-11fb-4801-8566-2e405f92aae4",
"input": 26,
"input_unit": "g",
"output": 9,
"output_unit": "kg",
"started_at": "2024-11-22T17:04:25.217Z",
"status": "failed",
"updated_at": "2024-11-22T17:04:25.217Z",
"user_id": "c48e70a6-3ad9-4d17-84ff-4727e44645e7"
}