forked from pmcelhaney/counterfact
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopenapi-example.yaml
64 lines (64 loc) · 1.7 KB
/
openapi-example.yaml
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
openapi: 3.0.3
info:
version: 1.0.0
title: Sample API
description: A sample API to illustrate OpenAPI concepts
paths:
/count:
get:
description: outputs the number of time each URL was visited
responses:
default:
description: Successful response
content:
application/json:
schema:
type:
string
examples:
no visits:
value: You have not visited anyone yet
/hello/kitty:
get:
description: HTML with a hello kitty image
responses:
default:
description: Successful response
content:
application/json:
schema:
type:
string
examples:
hello kitty:
value: >-
<img
src="https://upload.wikimedia.org/wikipedia/en/0/05/Hello_kitty_character_portrait.png">
/hello/{name}:
get:
parameters:
- in: path
name: name
required: true
schema:
type: string
description: says hello to the name
description: says hello to someone
responses:
default:
description: Successful response
headers:
x-test:
schema:
type: string
content:
application/json:
schema:
type:
string
example: an example string
examples:
hello-example1:
value: Hello, example1
hello-example2:
value: Hello, example2