-
Notifications
You must be signed in to change notification settings - Fork 2
/
sflight-requests.http
58 lines (41 loc) · 1.27 KB
/
sflight-requests.http
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
GET http://localhost:52056/health HTTP/1.1
content-type: application/json
### Check assigned geode. Configure in the appsettings.json file. If not configured, it will return the default geode.
GET http://localhost:52056/api/geode HTTP/1.1
content-type: application/json
###
GET http://localhost:52056/api/odata/$metadata HTTP/1.1
content-type: application/json
### Create new flight with id 006
POST http://localhost:52056/api/odata/Sflight HTTP/1.1
content-type: application/json
{
"id": "006",
"carrid": "AA",
"connid": "64",
"fldate": "2016-06-17",
"planetype": "A310-300",
"seatsmax": 280,
"seatsocc": 10
}
### Get flight info by id 006
GET http://localhost:52056/api/odata/Sflight('006') HTTP/1.1
content-type: application/json
### Update whole flight with id 006 defaulting the rest
PUT http://localhost:52056/api/odata/Sflight('006') HTTP/1.1
content-type: application/json
{
"id": "006",
"carrid": "LH",
"connid": "11"
}
### Patch flight with id 006 to antoher carrier keeping rest as is
PATCH http://localhost:52056/api/odata/Sflight('006') HTTP/1.1
content-type: application/json
{
"id": "006",
"carrid": "LH"
}
### Delete flight with id 006
DELETE http://localhost:52056/api/odata/Sflight('006') HTTP/1.1
content-type: application/json