Skip to content
This repository has been archived by the owner on Sep 13, 2022. It is now read-only.

REST API

Frank Steiler edited this page Apr 28, 2017 · 3 revisions

When the Raspberry Pi boots into NOOBS4IoT mode (runinstaller specified in recovery.cmdline and/or no OS installed) with webserver (no no-webserver specified in recovery.cmdline), then the following REST API will be available at port 80.

Note: The IP address of the Pi will be shown, as soon as the webserver is ready. The information is printed to screen, as well as a QR code containing the address.

OS Installation

  • Method: POST
  • URI: \os
  • Payload: The format is based on the NOOBS layout. The with + marked entries are mandatory:
  {
      "description": "LibreELEC is a fast and user-friendly Kodi Entertainment Center distribution.",
      "nominal_size": 1024,
+     "os_info": "http://releases.libreelec.tv/noobs/LibreELEC_RPi/os.json",
+     "os_name": "LibreELEC_RPi",
      "partition_setup": "http://releases.libreelec.tv/noobs/LibreELEC_RPi/partition_setup.sh",
+     "partitions_info": "http://releases.libreelec.tv/noobs/LibreELEC_RPi/partitions.json",
      "release_date": "2016-05-17",
      "supported_hex_revisions": "2,3,4,5,6,7,8,9,d,e,f,10,11,12,14,19,0092",
      "supported_models": [
          "Pi Model",
          "Pi Compute Module",
          "Pi Zero"
      ],
+     "tarballs": [
+         "http://releases.libreelec.tv/noobs/LibreELEC_RPi/LibreELEC_RPi_System.tar.xz",
+         "http://releases.libreelec.tv/noobs/LibreELEC_RPi/LibreELEC_RPi_Storage.tar.xz"
      ]
  }

Change default boot partition_setup

  • Method: POST
  • URI: /bootPartition
  • Payload: The device string, e.g. /dev/mmcblk0p6

Reboot device

  • Method: POST
  • URI: /reboot

Exit to recovery shell of NOOBS4IoT

  • Method: POST
  • URI: /exit