-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Which documentation needs improvement?
API_DEVICES_API.md -> Printing operations -> Get print jobs
What's the issue?
When I call one of the 3 endpoints listed here, I get a totally different reply from the api.
What I get:
REQUEST URL: https://api.bambulab.com/v1/iot-service/api/user/print
{
"message": "success",
"code": 0,
"error": null,
"devices": [
{
"dev_id": "0309DA472600323",
"dev_name": "C3DP0",
"dev_model_name": "N1",
"dev_product_name": "A1 mini",
"dev_online": true,
"dev_access_code": "35193682"
}
]
}
Documented:
GET /v1/iot-service/api/user/print
GET /v1/iot-service/api/user/print?device_id<device_id>
GET /v1/iot-service/api/user/print?statusprinting|completed|failed
Response:
{
"code": 0,
"data": {
"jobs": [
{
"job_id": "12345",
"file_name": "model.3mf",
"status": "printing",
"progress": 45,
"time_remaining": 3600,
"started_at": "2024-10-18T10:00:00Z"
}
]
}
}
So instead of info on a running print, it gives me a list of devices.
I have only one printer attached in my account, it's an A1 mini.
This is the call I am doing:
def get_status(self):
"""Get list of bound devices"""
response = None
url = (f"{self.base_url}/v1/iot-service/api/user/print")
print(f"REQUEST URL: {url}")
response = requests.get(url, headers=self.get_headers())
response.raise_for_status()
return response.json()
So I'm not sure if the documentation is wrong or the api may return different info depending on the printer.
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation