Add fourth work package for REST API implementation
[anna.git] / example / diameter / launcher / resources / HELP.md
index fec3b72..40f1a5e 100644 (file)
@@ -960,7 +960,7 @@ Updates diameter server sessions to be accepted.
 
 ```
 {
-    "sessions":<integer value>
+    "sessions":<sessions (integer)>
 }
 ```
 
@@ -1004,7 +1004,7 @@ Updates ADML working directory.
 {
     "action":"<hide|show|hidden|shown>"
     [, "addressPort":"<address:port>"]
-    [, "socket":<socket>]
+    [, "socket":<socket id (integer)>]
 }
 ```
 
@@ -1036,13 +1036,13 @@ Reset statistics and counters.
 
 #### POST /context
 
-Dump ADML context at file path provided. If empty, default path is selected. Context information is not retrieved in the response, so, file is related to ADML execution context.
+Dump ADML context at file path provided. If empty (or field missing), default path is selected. Context information is not retrieved in the response, so, file is related to ADML execution context.
 
 **Request body**:
 
 ```
 {
-    "targetFile":"[file path]"
+    ["targetFile":"[file path]"]
 }
 ```
 
@@ -1078,7 +1078,7 @@ Set the statistics concepts to be logged. To know the concept indentifiers regis
 
 ```
 {
-    "list":"<comma-separated list|all|none>"
+    ["list":"<comma-separated list|[all]|none>"]
 }
 ```
 
@@ -1153,7 +1153,7 @@ or
 
 ```
 {
-    "action":"<action: list|dump|clear|exhaust|rotate>"
+    "action":"[action: <[list]|dump|clear|exhaust|rotate>]"
 }
 ```
 
@@ -1184,7 +1184,7 @@ or
 
 ```
 {
-    "action":"<action: list|dump|clear|exhaust|rotate>"
+    "action":"[action: <[list]|dump|clear|exhaust|rotate>]"
 }
 ```
 
@@ -1243,21 +1243,665 @@ Sends diameter expressed in hexadecimal string (no spaces, no colons, i.e.: `010
 
 ADML implements a bulting *Finite State Machine* to plan testing flows with a great flexibility.
 
-#### POST /xxxxxxxx
+#### POST /testid-description
 
-Referred files (*dictionaries, cer, cea, etc.*) shall be accesible for ADML and are not provided in this operation.
+**Request body**:
+
+```
+{
+    "description":"<description (string)>"
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-ip-limit
+
+In-Progress limit is the maximum number of tests which can be executed in parallel.
+This operation allows a specific test to set this global pool behaviour.
+
+Zero-value is equivalent to stop the clock (no tests will be executed).
+
+Value '-1' means 'no limit' (full parallel). Be careful with resources consumption.
+
+**Request body**:
+
+```
+{
+    "amount":[amount (integer, 1 by default: execution in sequence)]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-timeout
+
+**Request body**:
+
+```
+{
+    "msecs":<milliseconds (integer)>
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-sendmsg2e
+
+**Request body**:
+
+```
+{
+    "diameterJson":<diameter message json object>
+    [,"stepNumber":[amount (integer, -1 no step associated)]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-sendmsg2c
+
+**Request body**:
+
+```
+{
+    "diameterJson":<diameter message json object>
+    [,"stepNumber":[amount (integer, -1 no step associated)]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-delay
+
+**Request body**:
+
+```
+{
+    "msecs":<milliseconds (integer)>
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-sh-command
+
+**Request body**:
+
+```
+{
+    "script":"<script>"
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfe-hex
+
+**Request body**:
+
+```
+{
+    "hex":"<hex string>"
+    [,"strict":"[<true|[false]>]"]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfc-hex
+
+**Request body**:
+
+```
+{
+    "hex":"<hex string>"
+    [,"strict":"[<true|[false]>]"]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfe-msg
+
+**Request body**:
+
+```
+{
+    "diameterJson":<diameter message json object>
+    [,"strict":"[<true|[false]>]"]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfc-msg
+
+**Request body**:
+
+```
+{
+    "diameterJson":<diameter message json object>
+    [,"strict":"[<true|[false]>]"]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfe
+
+**Request body**:
+
+```
+{
+    "condition": {
+      "code":"[(integer)]",
+      "bitR":"[(1|0)]",
+      "hopByHop":"[(integer)]",
+      "applicationId":"[(integer)]",
+      "sessionId":"[session id]",
+      "resultCode":"[(integer)]",
+      "msisdn":"[msisdn]",
+      "imsi":"[imsi]",
+      "serviceContextId":"[service context id]"
+    }
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /testid-waitfc
+
+**Request body**:
+
+```
+{
+    "condition": {
+      "code":"[(integer)]",
+      "bitR":"[(1|0)]",
+      "hopByHop":"[(integer)]",
+      "applicationId":"[(integer)]",
+      "sessionId":"[session id]",
+      "resultCode":"[(integer)]",
+      "msisdn":"[msisdn]",
+      "imsi":"[imsi]",
+      "serviceContextId":"[service context id]"
+    }
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+### EXECUTION ACTIONS
+
+#### POST /test-ttps
+
+**Request body**:
+
+```
+{
+    "amount":<amount (integer)>
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-next
+
+**Request body**:
+
+```
+{
+    ["syncAmount":[amount (integer: 1 by default)]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-ip-limit
+
+Global operation (also at test identifier level is accessible).
+
+Zero-value is equivalent to stop the clock (no tests will be executed).
+
+Value '-1' means 'no limit' (full parallel). Be careful with resources consumption.
+
+Defaults to '-2' (no '-1' which is default for *testid-ip-limit* version), which wil show the current pool *ip-limit* and also the number of test cases which are *in progress*.
+
+**Request body**:
+
+```
+{
+    ["amount":[amount (integer, shows current ip-limit and in-progress test cases amount, by default (-2))]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-goto
+
+**Request body**:
+
+```
+{
+    "id":<test identifier>
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-run
 
-**Request body**: { "servicesJson":<services json object>}
+**Request body**:
 
-**Response body**: { "result":"<true or false>", "response":"<response>"}
+```
+{
+    "id":<test identifier>
+}
+```
 
-#### POST /xxxxxxxx
+**Response body**:
 
-Referred files (*dictionaries, cer, cea, etc.*) shall be accesible for ADML and are not provided in this operation.
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-look
+
+**Request body**:
+
+```
+{
+     ["id":[test identifier (integer: current by default (-1))]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<base64-encoded output>"
+}
+```
+
+#### POST /test-state
+
+**Request body**:
+
+```
+{
+     ["id":[test identifier (integer: current by default (-1))]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true: if state is 'Success' or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-interact
+
+Makes interactive a specific test case id. The amount of 0, implies no execution steps margin, which could be useful to 'freeze' a test in the middle of its execution. Value -1 makes it non-interactive resuming it from the current step.
+
+**Request body**:
+
+```
+{
+     "amount":<amount (integer)>
+     [,"id":[test identifier (integer: current by default (-1))]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-reset
+
+**Request body**:
+
+```
+{
+     ["type":"<[soft]|hard>"]
+     [,"id":[test identifier (integer: apply to all the tests (-1))]]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-repeats
+
+**Request body**:
+
+```
+{
+     "amount":<amount (integer)>
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-auto-reset
+
+**Request body**:
+
+```
+{
+     "type":"<soft|hard>"
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-initialized
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-finished
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-clear
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-junit
+
+As it could be very large, it will be dumped on provided target directory, '*/tmp/junit.xml*' by default.
+
+**Request body**:
+
+```
+{
+    ["targetFile":"<file path>"]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-summary-counts
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<base64-encoded output>"
+}
+```
+
+#### POST /test-summary-states
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<base64-encoded output>"
+}
+```
+
+#### POST /test-summary
+
+**Request body**: none
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<base64-encoded output>"
+}
+```
+
+#### POST /test-report
+
+**Request body**:
+
+```
+{
+    ["state":"[<initialized|in-progress|failed|success|[all]|none>]"]
+    [,"action":"[<[enable]|disable>]"]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
 
-**Request body**: { "servicesJson":<services json object>}
+#### POST /test-report-hex
 
-**Response body**: { "result":"<true or false>", "response":"<response>"}
+**Request body**:
+
+```
+{
+    ["action":"[<[enable]|disable>]"]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```
+
+#### POST /test-dump_stdout
+
+**Request body**:
+
+```
+{
+    ["action":"[<[enable]|disable>]"]
+}
+```
+
+**Response body**:
+
+```
+{
+    "result":"<true or false>",
+    "response":"<response>"
+}
+```