-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopenapi.yaml
37 lines (37 loc) · 1.2 KB
/
openapi.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
openapi: 3.0.0
info:
title: Sample API
description: Optional multiline or single-line description in [CommonMark](http://commonmark.org/help/) or HTML.
version: 0.1.9
servers:
- url: http://api.example.com/v1
description: Optional server description, e.g. Main (production) server
- url: http://staging-api.example.com
description: Optional server description, e.g. Internal staging server for testing
paths:
/user:
get:
summary: Returns user name.
description: Optional extended description in CommonMark or HTML.
responses:
'200': # status code
description: A String of user names
content:
application/json:
schema:
type: string
example: "hoge taro"
/users:
get:
summary: Returns a list of users.
description: Optional extended description in CommonMark or HTML.
responses:
'200': # status code
description: A JSON array of user names
content:
application/json:
schema:
type: array
items:
type: string
example: ["hoge taro", "huga jiro", "piyo saburo"]