-
Notifications
You must be signed in to change notification settings - Fork 0
/
father-ted.yaml
151 lines (151 loc) · 3.62 KB
/
father-ted.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
---
swagger: "2.0"
info:
description: REST API for hand-curated Father Ted Quotes
version: 1.0.0
title: Father Ted API
contact:
email: [email protected]
license:
name: Apache 2.0
url: http://www.apache.org/licenses/LICENSE-2.0.html
host: api.fatherted.irish
tags:
- name: Quotes
description: Retrieve a random quote.
- name: Series
description: Retrieve the Father Ted available series.
- name: Episodes
description: Retrieve the Father Ted available episodes.
- name: Characters
description: Retrieve the Father Ted available characters.
schemes:
- https
paths:
/quotes:
get:
tags:
- Quotes
summary: Retrieve Quotes
description: Retrieve quotes
produces:
- application/json
parameters:
- name: series
in: query
description: Retrieve all quotes for a given series.
required: false
type: string
- name: episode
in: query
description: Retrieve all quotes for a given episode title.
required: false
type: string
- name: character
in: query
description: Retrieve all quotes for a given character.
required: false
type: string
responses:
"200":
description: Quotes for a given search.
schema:
type: array
items:
$ref: '#/definitions/Quote'
/quotes/random:
get:
tags:
- Quotes
summary: Retrieve a Random Quote
description: Retrieves a single quote from the given parameters.
produces:
- application/json
parameters:
- name: series
in: query
description: Retrieve all quotes for a given series.
required: false
type: string
- name: episode
in: query
description: Retrieve all quotes for a given episode title.
required: false
type: string
- name: character
in: query
description: Retrieve all quotes for a given character.
required: false
type: string
responses:
"200":
description: A random quote.
schema:
$ref: '#/definitions/Quote'
/series:
get:
tags:
- Series
summary: List available series.
produces:
- application/json
parameters: []
responses:
"200":
description: Available series.
schema:
type: array
items:
type: string
/episodes:
get:
tags:
- Episodes
summary: List available episodes.
produces:
- application/json
parameters: []
responses:
"200":
description: Available episodes.
schema:
type: array
items:
type: string
/characters:
get:
tags:
- Characters
summary: List available characters.
produces:
- application/json
parameters: []
responses:
"200":
description: Available characters.
schema:
type: array
items:
type: string
definitions:
Quote:
type: object
required:
- characters
- episode
- quote
- series
properties:
series:
type: string
example: Series 2
episode:
type: string
example: Hell
characters:
type: array
items:
type: string
quote:
type: string
example: 'Father Dougal: God Ted, he''s probably very cold now that his towel has blown away!'