Add first work package for REST API implementation
[anna.git] / example / diameter / launcher / resources / rest_api / README.md
1 # ADML REST API
2
3 ## References
4
5 Read  [deployment instructions](../../../../../INSTALL_ADML_HTTP.md) document to **create** *ADML HTTP* image and **run** it.
6
7 Read  [REST API](../../../../../example/diameter/launcher/resources/HELP.md) implementation to learn how to control *ADML HTTP* execution.
8
9 ## Helpers
10
11 Located at directory [helpers](./helpers).
12
13 These helpers eases *pcaps* translation into *REST API* input artifacts:
14
15 ### tsharkDecoder.sh
16
17 This utility disects a  *pcap* file and gets metadata and hexadecimal encoding for diameter messages found in the capture. Those files are named as `<frame number>.hex` and `<frame number>.metadata`. Also, a list of detected *Origin-Host AVPs* is dump in the file `origin-hosts`.
18
19 For example:
20
21 > ./tsharkDecoder.sh example.pcap
22 >
23
24 ### decodeHex.sh
25
26 Use this to decode *hex* files. For example:
27
28 > ./decodeHex.sh 8.hex
29
30 This will create the corresponding diameter message representation in two formats:
31
32 - **xml**
33 - **json** (through diameterJsonHelper resources)
34
35
36
37 ## Component Test
38
39 Go to [ct](./ct) directory and execute:
40
41 1. pip3 install -r requirements.txt
42 2. pytest *-or-* pytest -n <num|auto> (parallel execution)