lamp-life-line

command module
v0.0.0-...-cf79e49 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 30, 2018 License: MIT Imports: 5 Imported by: 0

README

lamp-life-line

Under Construction

Support REST Calls

Register New Cluster

Creates a new cluster with the given CLUSTER_NAME.

Endpoint: /cluster

Method: POST

Request JSON: 

{
    "name": "CLUSTER_NAME",
    "color": 32_bit_color_int
}

Response JSON:

{
    "name": "CLUSTER_NAME",
    "color": 32_bit_color_int
}
Get Cluster

Returns a list of clusters.

Endpoint: /cluster

Method: GET

Response JSON:
[
    {
        "name": "CLUSTER_NAME",
        "color": 32_bit_color_int
    }
]
Get Cluster

Returns a clusters with the given CLUSTER_NAME.

Endpoint: /cluster/{{CLUSTER_NAME}}

Method: GET

Response JSON:

{
    "name": "CLUSTER_NAME",
    "color": 32_bit_color_int
}
Unregister Cluster

Removes a cluster with the given CLUSTER_NAME.

Endpoint: /cluster/{{CLUSTER_NAME}}

Method: DELETE
Change Color

Changes the color for a cluster with a given CLUSTER_NAME.

Endpoint: /cluster/{{CLUSTER_NAME}}/color

Method: PUT

Request JSON:

{
    "color": 32_bit_color_int
}

Response JSON:

{
    "color": 32_bit_color_int
}
Get Color

Retrieves the color for a cluster with a given CLUSTER_NAME.

Endpoint: /cluster/{{CLUSTER_NAME}}/color

Method: GET

Response JSON:

{
    "color": 32_bit_color_int
}

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package database handles connection to the database
Package database handles connection to the database
common
Package common contains common functions across all api version
Package common contains common functions across all api version
v1
Package v1 handles version 1 API endpoints
Package v1 handles version 1 API endpoints

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL