-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathopenapi.yaml
More file actions
207 lines (203 loc) · 5.63 KB
/
openapi.yaml
File metadata and controls
207 lines (203 loc) · 5.63 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
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
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
openapi: 3.0.1
info:
title: Website Scraping Plugin
description: A plugin that allows the user to find hotels that meet search criteria using ChatGPT. If you do not know the user's username, ask them first before making queries to the plugin. Otherwise, use the username "global".
version: 'v1'
paths:
# /todos/{username}:
# get:
# operationId: getTodos
# summary: Get the list of todos
# parameters:
# - in: path
# name: username
# schema:
# type: string
# required: true
# description: The name of the user.
# responses:
# "200":
# description: OK
# content:
# application/json:
# schema:
# $ref: '#/components/schemas/getTodosResponse'
# post:
# operationId: addTodo
# summary: Add a todo to the list
# parameters:
# - in: path
# name: username
# schema:
# type: string
# required: true
# description: The name of the user.
# requestBody:
# required: true
# content:
# application/json:
# schema:
# $ref: '#/components/schemas/addTodoRequest'
# responses:
# "200":
# description: OK
# delete:
# operationId: deleteTodo
# summary: Delete a todo from the list
# parameters:
# - in: path
# name: username
# schema:
# type: string
# required: true
# description: The name of the user.
# requestBody:
# required: true
# content:
# application/json:
# schema:
# $ref: '#/components/schemas/deleteTodoRequest'
# responses:
# "200":
# description: OK
/website/{username}:
post:
operationId: getWebsite
summary: Fetch the website content at a url
parameters:
- in: path
name: username
schema:
type: string
required: true
description: The name of the user.
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/getWebsiteRequest'
responses:
"200":
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/getWebsiteResponse'
/hotel/{username}:
post:
operationId: getHotelAvailability
summary: Get hotel availability
parameters:
- in: path
name: username
schema:
type: string
required: true
description: The name of the user.
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/getHotelRequest'
responses:
"200":
description: OK
content:
application/json:
schema:
$ref: '#/components/schemas/getHotelResponse'
components:
schemas:
# getTodosResponse:
# type: object
# properties:
# todos:
# type: array
# items:
# type: string
# description: The list of todos.
# addTodoRequest:
# type: object
# required:
# - todo
# properties:
# todo:
# type: string
# description: The todo to add to the list.
# required: true
# deleteTodoRequest:
# type: object
# required:
# - todo_idx
# properties:
# todo_idx:
# type: integer
# description: The index of the todo to delete.
# required: true
getWebsiteRequest:
type: object
required:
- url
properties:
url:
type: string
description: The url of the website to fetch
required: true
getWebsiteResponse:
type: object
properties:
summarized_html:
type: string
description: The summarized website content at a url
required: true
actions:
type: array
items:
type: object
properties:
url:
type: string
description: the url of the available action
action_description:
type: string
description: The action available at that URL
getHotelRequest:
type: object
required:
- name
- startDate
- endDate
properties:
name:
type: string
description: The name of the hotel
required: true
startDate:
type: string
description: The starting date of the reservation in the format MM/DD/YYYY
required: true
endDate:
type: string
description: The ending date of the reservation in the format MM/DD/YYYY
required: true
numRooms:
type: string
description: The number of rooms to book. Assume 1 if not specified.
required: false
numAdults:
type: string
description: The number of adults in the booking. Assume 2 if not specified.
required: false
numChildren:
type: string
description: The number of children in the booking. Assume 0 if not specified.
required: false
getHotelResponse:
type: object
properties:
availability:
type: string
description: "The javascript code used to make the reservation on the website"
required: true