B. Remote Control Protocol
• method—a String with the name of the method to be invoked.
• params—an Object or Array of values to be passed as parameters to the defined method.
• id—a value of any type used to match the response with the request to which it is replying.
The receiver of the request must reply with a valid response to all received requests. A response must contain the properties men-
tioned below.
• result—the data returned by the invoked method.
If an error occurred while invoking the method, this value m ust be null.
• error —a sp e c ified error code if there was an error invoking the m ethod, otherwise null.
• id—the id of the request to which it is responding.
For exa mple: {"params":{}, "method":"powerStatus", "id":"1234", "jsonrpc":"2.0"}
Image B-2
powerStatus A PI – example
Here, p owerS tatus is the JSON A PI to be sent.
JSON APIs
Here are s ome of the JSON AP Is defined for controlling the Event Master processor. If you hav e a master / slave Event Master
setup, JSO N m ust be sent to the m aster unit. For all the requ ests, this sec tion explains the param eter passed or used in the RP C
calls. If the params object is blank that means that API doesn’t require a para
meter.
Requests are case sensitive.
allTrans
•Definition
- It executes the “allTrans” c omm and.
• Request:
- params: {} - It doesn’t require any parameter.
• Response:
- response: null
- succ e ss : (0 = su cc e ss, an yth in g else is a n error)
• Example:
- {"params":{}, "method":"allTrans", "id":"1234", "jsonrpc":"2.0"}
cut
•Definition
- It executes the “Cu t” c omm and.
• Request:
- params: {} - It doesn’t require any parameter.
• Response:
- response: null
- succ e ss : (0 = su cc e ss, an yth in g else is a n error)
• Example:
- {"params":{}, "method":"cut", "id":"1234", "jsonrpc":"2.0"}
512
R5905948 EVENT MASTER DEVICES 17/07/2017