-
Notifications
You must be signed in to change notification settings - Fork 717
Expand file tree
/
Copy pathExamples.http
More file actions
53 lines (35 loc) · 1.53 KB
/
Examples.http
File metadata and controls
53 lines (35 loc) · 1.53 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
# For more info on HTTP files go to https://aka.ms/vs/httpfile
@baseUrl = http://localhost:5000
### VERSION 1.0
### Values - Get All
GET {{baseUrl}}/api/values?api-version=1.0
### Hello World - Get
GET {{baseUrl}}/api/v1/helloworld
### Hello World - Get by ID
GET {{baseUrl}}/api/v1/helloworld/42
### Hello World - Create
POST {{baseUrl}}/api/v1/helloworld
### Multi-Versioned - Get
# note: this controller has a single, version interleaved implementation
GET {{baseUrl}}/api/v1/multiversioned
### Multi-Versioned - Legacy v2-only (returns 400 — exact-match on v2.0)
GET {{baseUrl}}/api/v1/multiversioned/legacy
### Multi-Versioned - Modern (returns 404 — introduced in v2.0)
GET {{baseUrl}}/api/v1/multiversioned/modern
### VERSION 2.0
### Values - Get All
GET {{baseUrl}}/api/values?api-version=2.0
### Multi-Versioned - Get
# note: this controller has a single, version interleaved implementation
GET {{baseUrl}}/api/v2/multiversioned
### Multi-Versioned - Legacy v2-only (200 — exact match)
GET {{baseUrl}}/api/v2/multiversioned/legacy
### Multi-Versioned - Modern (200 — introduced in v2.0, reachable from v2.0 onward)
GET {{baseUrl}}/api/v2/multiversioned/modern
### VERSION 3.0
### Multi-Versioned - Get
GET {{baseUrl}}/api/v3/multiversioned
### Multi-Versioned - Legacy v2-only (returns 400 — [MapToApiVersion(2.0)] is exact-match, NOT v3)
GET {{baseUrl}}/api/v3/multiversioned/legacy
### Multi-Versioned - Modern (200 — [IntroducedInApiVersion(2.0)] is "from v2 onward", auto-reaches v3)
GET {{baseUrl}}/api/v3/multiversioned/modern