aboutsummaryrefslogtreecommitdiff
path: root/examples/http/test.http
blob: d4e68b34d3c29f03691cea1fe1cfa097c6f9b830 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
POST http://localhost:8000/
Content-Type: application/json

{
  "jsonrpc": "2.0",
  "method": "multiply",
  "params": {
    "a": 2,
    "b": 3
  },
  "id": 1
}

###

POST http://localhost:8000/
Content-Type: application/json

{
  "jsonrpc": "2.0",
  "method": "divide",
  "params": {
    "a": 10,
    "b": 3
  },
  "id": 2
}

###

POST http://localhost:8000/
Content-Type: application/json

[
  { "jsonrpc": "2.0", "method": "multiply", "params": { "a": 2, "b": 3 }, "id": 10 },
  {"jsonrpc": "2.0", "method": "sum", "params": [1,2,4], "id": "1"},
  {"jsonrpc": "2.0", "method": "notify_hello", "params": [7]},
  {"jsonrpc": "2.0", "method": "subtract", "params": [42,23], "id": "2"},
  {"foo": "boo"},
  {"jsonrpc": "2.0", "method": "foo.get", "params": {"name": "myself"}, "id": "5"},
  {"jsonrpc": "2.0", "method": "get_data", "id": "9"}
]