Liquid-IoT Runtime Environemnt (LIoTRE) API Specifiction
Liquid IoT Runtime Environemnt (LIoTRE) is a Node.js HTTP server which turns an IoT device into an application server so that it can host and run IoT applications. LIoTRE offers a set of RESTFul APIs that can be used to deploy the IoT applications and manage their operations remotely. More information can be found in https://github.com/farshadahmadi/liquidiot-server.
Version: 1.0
Copyright (c) TUT Tampere University of Technology 2015-2016, all rights reserved
http://apache.org/licenses/LICENSE-2.0.html
Access
[ Jump to Models ]
Table of Contents
delete /app/{appId}
get /app/{appId}
get /app/{appId}/log
post /app/{appId}
put /app/{appId}
delete /app
get /app
post /app
Deletes an applications by ID. (appAppIdDelete)
Deletes a specific applications on the target device.
Path parameters
appId (required)
Path Parameter — ID of the application
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
Application was deleted successfully.
404
No application with given id.
500
Unexpected error
String
Returns an application by ID. (appAppIdGet)
Get the information of a specific application.
Path parameters
appId (required)
Path Parameter — ID of the application
Return type
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
The description of the application
Application
404
No application with given id.
Returns application log by ID. (appAppIdLogGet)
Returns the log of an specific application.
Path parameters
appId (required)
Path Parameter — ID of the application
Return type
String
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
Application log
String
404
No application with given id.
500
Unexpected error
String
Updates an application by ID. (appAppIdPost)
Updates a previously deplyed application specified by its ID.
Path parameters
appId (required)
Path Parameter — ID of the application
Consumes
This API call consumes the following media types via the
Content-Type request header:
Form parameters
filekey (required)
Form Parameter — The application package in .tgz format. For more information about the content of application package see section 4 (File structure of the liquid-IoT application) of the Liquid-IoT RE API specification document (https://github.com/farshadahmadi/liquidiot-server/blob/master/Documents/API%20Documentation%2025-05-2016.pdf)
Return type
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
Returns updated desciption of the application
Application
500
Error in updating the application.
String
Starts or stops an application by ID and the target status. (appAppIdPut)
Starts or stops a specific application based on the provided target status in the body of the request.
Path parameters
appId (required)
Path Parameter — ID of the application
Request body
status (required)
Body Parameter — Target status of the application
Return type
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
Application went to target status successfully.
Application
404
No application with given id.
500
Unexpected error
String
Deletes all applications (appDelete)
This endpoint deletes all applications deployed to the device.
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
All apps were deleted successfully
500
Unexpected error
String
Gets the list of deployed applications (appGet)
This endpoint returns the list of all IoT appplications deployed to the device.
Return type
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
An array of applications
500
Unexpected error
String
Deploys an application (appPost)
Deploys an application to the device.
Consumes
This API call consumes the following media types via the
Content-Type request header:
Form parameters
filekey (required)
Form Parameter — The application package in .tgz format. For more information about the content of application package see section 4 (File structure of the liquid-IoT application) of the Liquid-IoT RE API specification document (https://github.com/farshadahmadi/liquidiot-server/blob/master/Documents/API%20Documentation%2025-05-2016.pdf)
Return type
Produces
This API call produces the following media types according to the request header;
the media type will be conveyed by the
Content-Type response header.
Responses
200
Returns desciption (including app ID and status) of the newly added application
Application
500
Error in deploying the application
String
[ Jump to Methods ]
Table of Contents
Application
Status
name (optional)
version (optional)
description (optional)
main
String Name of the main file (entry point) of the application.
scripts (optional)
id
BigDecimal Uniqie indentifier assigned to every application for further references.
status
String Each application can be in three main status crashes, running, or paused.
initializing
crashed
running
paused
applicationInterfaces
array[String] The list of application interfaces implemented by the application.
status (optional)
running
paused