-
Notifications
You must be signed in to change notification settings - Fork 665
/
swagger.yaml
59 lines (57 loc) · 1.39 KB
/
swagger.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
swagger: "2.0"
info:
description: "API de conversão de temperatura"
version: "1.0.0"
title: "Conversão de temperatura"
contact:
email: "[email protected]"
paths:
/fahrenheit/{valor}/celsius:
get:
description: "Converte de Fahrenheit para Celsius"
produces:
- "application/json"
parameters:
- name: "valor"
in: "path"
description: "Valor que será convertido"
required: true
type: "number"
responses:
"200":
description: "Resultado da conversão"
schema:
type: "array"
items:
$ref: "#/definitions/Temperatura"
"400":
description: "Bad Input Parameter"
/celsius/{valor}/fahrenheit:
get:
description: "Converte de Celsius para Fahrenheit"
produces:
- "application/json"
parameters:
- name: "valor"
in: "path"
description: "Valor que será convertido"
required: true
type: "number"
responses:
"200":
description: "Resultado da conversão"
schema:
type: "array"
items:
$ref: "#/definitions/Temperatura"
"400":
description: "Bad Input Parameter"
definitions:
Temperatura:
type: "object"
required:
- "valor"
properties:
valor:
type: "number"
example: 500.0