-
Notifications
You must be signed in to change notification settings - Fork 716
Expand file tree
/
Copy pathExamples.http
More file actions
74 lines (50 loc) · 2.02 KB
/
Examples.http
File metadata and controls
74 lines (50 loc) · 2.02 KB
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# For more info on HTTP files go to https://aka.ms/vs/httpfile
@baseUrl = http://localhost:9006
### VERSION 1.0
### People - Get All (OData)
# Note: assumes the version when AssumeDefaultVersionWhenUnspecified = true,
# which is meant for existing, unversioned apis
GET {{baseUrl}}/api/people
### People - Get All (OData)
GET {{baseUrl}}/api/people?api-version=1.0
### People - Get All with $select (OData)
GET {{baseUrl}}/api/people?api-version=1.0&$select=firstName,lastName
### People - Get by Key (OData)
GET {{baseUrl}}/api/people/1?api-version=1.0
### Orders - Get All (Standard)
# Note: assumes the version when AssumeDefaultVersionWhenUnspecified = true,
# which is meant for existing, unversioned apis
GET {{baseUrl}}/api/orders
### Orders - Get All (Standard)
GET {{baseUrl}}/api/orders?api-version=1.0
### Orders - Get by Key (Standard)
GET {{baseUrl}}/api/orders/1?api-version=1.0
### VERSION 2.0
### People - Get All (OData)
GET {{baseUrl}}/api/people?api-version=2.0
### People - Get All with $select (OData)
GET {{baseUrl}}/api/people?api-version=2.0&$select=firstName,lastName,email
### People - Get by Key (OData)
GET {{baseUrl}}/api/people/1?api-version=2.0
### People - Partial Update (OData)
PATCH {{baseUrl}}/api/people/1?api-version=2.0
content-type: application/json
prefer: return=representation
{"firstName":"John","lastName":"Doe"}
### Orders - Get All (OData)
GET {{baseUrl}}/api/orders?api-version=2.0
### Orders - Get All with $select (OData)
GET {{baseUrl}}/api/orders?api-version=2.0&$select=id,customer
### Orders - Get by Key (OData)
GET {{baseUrl}}/api/orders/1?api-version=2.0
### VERSION 3.0
### People - Get All (OData)
GET {{baseUrl}}/api/people?api-version=3.0
### People - Get All with $select (OData)
GET {{baseUrl}}/api/people?api-version=3.0&$select=firstName,lastName,email
### People - Get by Key (OData)
GET {{baseUrl}}/api/people/1?api-version=3.0
### Orders - Get All (Standard)
GET {{baseUrl}}/api/orders?api-version=3.0
### Orders - Get by Key (Standard)
GET {{baseUrl}}/api/orders/1?api-version=3.0