-
Notifications
You must be signed in to change notification settings - Fork 0
/
airtable.yaml
179 lines (178 loc) · 5.78 KB
/
airtable.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
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
info:
# Copyright 2018, 2019 Transposit Corporation. All Rights Reserved.
title: Airtable
version: "1.0.4"
license:
name: Apache 2.0
url: http://www.apache.org/licenses/LICENSE-2.0.html
openapi: 3.0.0
externalDocs:
url: https://airtable.com/api
paths:
/{baseId}/{table}:
parameters:
- $ref: "#/components/parameters/baseId"
- $ref: "#/components/parameters/table"
get:
operationId: get_records
parameters:
- name: maxRecords
in: query
description: The maximum total number of records that will be returned in your requests. If this value is larger than pageSize (which is 100 by default), you may have to load multiple pages to reach this total.
schema:
format: int32
type: integer
- name: filterByFormula
in: query
schema:
type: string
- description: The offset parameter, if available
in: query
name: offset
required: false
schema:
type: string
- name: sort
explode: true
in: query
required: false
schema:
type: array
items:
type: object
properties:
field:
type: string
direction:
type: string
enum:
- asc
- desc
style: deepObject
- name: field # this parameter does not work as OpenAPI thinks it should
explode: true
in: query
required: false
schema:
type: array
items:
type: string
- name: pageSize
in: query
description: The number of records returned in each request. Must be less than or equal to 100. Default is 100.
required: false
schema:
type: integer
- name: view
in: query
required: false
description: The name or ID of a view in the endpoints table. If set, only the records in that view will be returned. The records will be sorted according to the order of the view.
schema:
type: string
- name: cellFormat
in: query
required: false
description: 'The format that should be used for cell values. Supported values are: "json": cells will be formatted as JSON, depending on the field type. "string": cells will be formatted as user-facing strings, regardless of the field type. Note: You should not rely on the format of these strings, as it is subject to change. The default is "json".'
schema:
type: string
- name: timeZone
in: query
required: false
description: 'The time zone that should be used to format dates when using "string" as the cellFormat. This parameter is required when using "string" as the cellFormat.'
schema:
type: string
- name: userLocale
in: query
required: false
description: 'The user locale that should be used to format dates when using "string" as the cellFormat. This parameter is required when using "string" as the cellFormat.'
schema:
type: string
responses:
200:
description: ""
post:
operationId: create_record
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/record"
description: New record to add
required: true
responses:
200:
description: ""
/{baseId}/{table}/{recordId}:
parameters:
- $ref: "#/components/parameters/baseId"
- $ref: "#/components/parameters/table"
- $ref: "#/components/parameters/recordId"
get:
operationId: get_record
responses:
200:
description: ""
delete:
operationId: delete_record
responses:
200:
description: ""
patch:
operationId: update_record
description: To update some (but not all) fields of a endpoints record. Any fields that are not included will not be updated.
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/record"
description: Record to update
required: true
responses:
200:
description: ""
put:
operationId: update_all_fields_of_record
description: To update all fields of a endpoints record. Any fields that are not included will be cleared.
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/record"
description: Record to update
required: true
responses:
200:
description: ""
components:
parameters:
baseId:
description: "The Airtable base ID. This can be found as part of the API documentation URL. Go to https://airtable.com/api and select the base you're interested in, then find the base ID in the resulting URL: https://airtable.com/[baseId]/api/docs."
in: path
name: baseId
required: true
schema:
type: string
table:
description: "The name of the table being referenced within the base. This table must already exist."
in: path
name: table
required: true
schema:
type: string
recordId:
description: "The record being referenced. Find the record through a get_records call, then find its recordId there."
in: path
name: recordId
required: true
schema:
type: string
schemas:
record:
type: object
required:
- fields
properties:
fields:
type: object
servers:
- url: https://api.airtable.com/v0