forked from BrasilAPI/BrasilAPI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathendpoint.json.example
More file actions
85 lines (84 loc) · 3 KB
/
Copy pathendpoint.json.example
File metadata and controls
85 lines (84 loc) · 3 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
75
76
77
78
79
80
81
82
83
84
85
{
"tags": [
{
"name": "CEP",
"description": "Informações referentes a CEPs"
}
],
"paths": {
"/cep/v1/{cep}": {
"get": {
"tags": ["CEP"],
"summary": "Busca por CEP com múltiplos providers de fallback.",
"description": "",
"parameters": [
{
"name": "cep",
"description": "O CEP (Código de Endereçamento Postal) é um sistema de códigos que visa racionalizar o processo de encaminhamento e entrega de correspondências através da divisão do país em regiões postais. ... Atualmente, o CEP é composto por oito dígitos, cinco de um lado e três de outro. Cada algarismo do CEP possui um significado.\n",
"in": "path",
"required": true,
"schema": {
"type": "integer",
"format": "int64"
}
}
],
"responses": {
"200": {
"description": "Success",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Address"
}
}
}
},
"404": {
"description": "Todos os serviços de CEP retornaram erro.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorMessage"
}
}
}
}
}
}
}
},
"components": {
"schemas": {
"Address": {
"title": "Address",
"required": ["cep", "state", "city", "neighborhood", "street"],
"type": "object",
"properties": {
"cep": {
"type": "string"
},
"state": {
"type": "string"
},
"city": {
"type": "string"
},
"neighborhood": {
"type": "string"
},
"street": {
"type": "string"
}
},
"example": {
"cep": "89010025",
"state": "SC",
"city": "Blumenau",
"neighborhood": "Centro",
"street": "Rua Doutor Luiz de Freitas Melro"
}
},
}
}
}