Web API Questions

Hi, I'm having trouble with some of the Repetier Server Websocket commands, I'm automating the assembly of several printed parts with a robotic arm, and need to be able to start, monitor and view the print jobs.

Using
{
    "action": "stateList",
    "data": {},
    "callback_id": 545
}

I can get the running data about the printer, which I need for the digital twin of the platform, but I'm not able to get something like:

{
    "action": "listModels",
    "data": {},
    "callback_id": 101
}

working. I'm wanting to be able to see the models in each printer, and then start the prints, and get the robotic arm to assemble it once I get the print complete event. How do I specify which printer I would like to get the data from?

I'm also trying to use "listJobs" but it just returns an empty list, I think I need to specify the printer again as well?

Many thanks! Repetier Server has been great so far and the API documentation very useful



Comments

  • I tried something like this:
    {
        "action": "listJobs",
        "slug": "Creality_Ender_3_Pro_2",
        "data": {},
        "callback_id": 101
    }

    But I feel like that's not the correct way to do it.

  • listModels and listJobs require slug as well. ListJobs show queued non running jobs so is normally empty.

    Little trick is open debug tools in chrome, reload and in network search the socket connection. There you see all queries and answers. Then go to printer and you see how it queries for the models with group filter.
  • Repetier said:
    Little trick is open debug tools in chrome, reload and in network search the socket connection. There you see all queries and answers. Then go to printer and you see how it queries for the models with group filter.
    Thanks, that works perfectly! I'm now able to use node-red to view models, start prints, monitor and log the data. Thanks for the quick reply


Sign In or Register to comment.