How do i get started with REST API

Hai guys..i'm interested to know about REST API i saw in documation here . But how do i get started ? is there any simple example like Hello world or any simple python script ?

@jithupg I am not sure in what kind of direction do you want to go: Consume current existing APIs, creating a new Plugin which provides REST-APIs, ….?

If you want to create a new Plugin which provides REST-APIs you can take a look into my „Knowledge-Base (https://github.com/OllisGit/OctoPrint-KnowledgeBase/wiki/RestAPI)“ or take a look into a simple Plugin like this: https://github.com/OllisGit/OctoPrint-DisplayLayerProgress-API

Hope that helps
Olli

If you're into Node JS then you might try out my octo-client module. I find it easy to use myself.

For example:

var OctoPrint = require('octo-client');

OctoPrint.printerState(function(ptr){
  if (ptr.state.flags.operational) {
    var targetHotend1 = ptr.temperature.tool0.target;
    console.log(targetHotend1);
  }
});