Skip to content

Commit d4f8310

Browse files
1 parent bee6f38 commit d4f8310

File tree

1 file changed

+213
-6
lines changed

1 file changed

+213
-6
lines changed

openapi/swagger.json

Lines changed: 213 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,14 @@
1010
"type": "array",
1111
"items": {
1212
"type": "object",
13-
"additionalProperties": {}
13+
"additionalProperties": {},
14+
"description": "A row object conforming to the schema of the table, where keys are the column IDs and values are the column values:\n\n```json\n{\n\t\"fullName\": \"Alex Bard\",\n\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\"totalAmount\": 34.50,\n\t\"amountPaid\": 0\n}\n```",
15+
"example": {
16+
"fullName": "Alex Bard",
17+
"invoiceDate": "2024-07-29T14:04:15.561Z",
18+
"totalAmount": 34.5,
19+
"amountPaid": 0
20+
}
1421
},
1522
"description": "A collection of row objects conforming to the schema of the table where keys are the column IDs and values are the column values:\n\n```json\n[\n\t{\n\t\t\"fullName\": \"Alex Bard\",\n\t\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\t\"totalAmount\": 34.50,\n\t\t\"amountPaid\": 0\n\t},\n\t{\n\t\t\"fullName\": \"Alicia Hines\",\n\t\t\"invoiceDate\": \"2023-06-15T10:30:00.000Z\",\n\t\t\"totalAmount\": 50.75,\n\t\t\"amountPaid\": 20\n\t}\n]\n```",
1623
"example": [
@@ -143,7 +150,9 @@
143150
"rowIDs": {
144151
"type": "array",
145152
"items": {
146-
"type": "string"
153+
"type": "string",
154+
"description": "ID of the row, e.g., `2a1bad8b-cf7c-44437-b8c1-e3782df6`",
155+
"example": "2a1bad8b-cf7c-44437-b8c1-e3782df6"
147156
},
148157
"description": "Row IDs of added rows, e.g., \n\n```json\n[\n\t\"2a1bad8b-cf7c-44437-b8c1-e3782df6\",\n\t\"93a19-cf7c-44437-b8c1-e9acbbb\"\n]\n```",
149158
"example": [
@@ -507,7 +516,9 @@
507516
"rowIDs": {
508517
"type": "array",
509518
"items": {
510-
"type": "string"
519+
"type": "string",
520+
"description": "ID of the row, e.g., `2a1bad8b-cf7c-44437-b8c1-e3782df6`",
521+
"example": "2a1bad8b-cf7c-44437-b8c1-e3782df6"
511522
},
512523
"description": "Row IDs of added rows, e.g., \n\n```json\n[\n\t\"2a1bad8b-cf7c-44437-b8c1-e3782df6\",\n\t\"93a19-cf7c-44437-b8c1-e9acbbb\"\n]\n```",
513524
"example": [
@@ -900,7 +911,9 @@
900911
"rowIDs": {
901912
"type": "array",
902913
"items": {
903-
"type": "string"
914+
"type": "string",
915+
"description": "ID of the row, e.g., `2a1bad8b-cf7c-44437-b8c1-e3782df6`",
916+
"example": "2a1bad8b-cf7c-44437-b8c1-e3782df6"
904917
},
905918
"description": "Row IDs of added rows, e.g., \n\n```json\n[\n\t\"2a1bad8b-cf7c-44437-b8c1-e3782df6\",\n\t\"93a19-cf7c-44437-b8c1-e9acbbb\"\n]\n```",
906919
"example": [
@@ -1065,7 +1078,14 @@
10651078
"type": "array",
10661079
"items": {
10671080
"type": "object",
1068-
"additionalProperties": {}
1081+
"additionalProperties": {},
1082+
"description": "A row object conforming to the schema of the table, where keys are the column IDs and values are the column values:\n\n```json\n{\n\t\"fullName\": \"Alex Bard\",\n\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\"totalAmount\": 34.50,\n\t\"amountPaid\": 0\n}\n```",
1083+
"example": {
1084+
"fullName": "Alex Bard",
1085+
"invoiceDate": "2024-07-29T14:04:15.561Z",
1086+
"totalAmount": 34.5,
1087+
"amountPaid": 0
1088+
}
10691089
},
10701090
"description": "A collection of row objects conforming to the schema of the table where keys are the column IDs and values are the column values:\n\n```json\n[\n\t{\n\t\t\"fullName\": \"Alex Bard\",\n\t\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\t\"totalAmount\": 34.50,\n\t\t\"amountPaid\": 0\n\t},\n\t{\n\t\t\"fullName\": \"Alicia Hines\",\n\t\t\"invoiceDate\": \"2023-06-15T10:30:00.000Z\",\n\t\t\"totalAmount\": 50.75,\n\t\t\"amountPaid\": 20\n\t}\n]\n```",
10711091
"example": [
@@ -1121,6 +1141,186 @@
11211141
"description": "Adds rows to a Big Table"
11221142
}
11231143
},
1144+
"/tables/{tableID}/rows/{rowID}": {
1145+
"patch": {
1146+
"responses": {
1147+
"200": {
1148+
"description": "",
1149+
"content": {
1150+
"application/json": {
1151+
"schema": {
1152+
"type": "object",
1153+
"properties": {},
1154+
"additionalProperties": false,
1155+
"description": "A 200 HTTP response code indicates that the row was successfully updated."
1156+
}
1157+
}
1158+
}
1159+
},
1160+
"400": {
1161+
"description": "",
1162+
"content": {
1163+
"application/json": {
1164+
"schema": {
1165+
"type": "object",
1166+
"properties": {
1167+
"error": {
1168+
"type": "object",
1169+
"properties": {
1170+
"type": {
1171+
"type": "string"
1172+
},
1173+
"message": {
1174+
"type": "string"
1175+
}
1176+
},
1177+
"required": [
1178+
"type",
1179+
"message"
1180+
],
1181+
"additionalProperties": false
1182+
}
1183+
},
1184+
"required": [
1185+
"error"
1186+
],
1187+
"additionalProperties": false
1188+
}
1189+
}
1190+
}
1191+
},
1192+
"404": {
1193+
"description": "",
1194+
"content": {
1195+
"application/json": {
1196+
"schema": {
1197+
"type": "object",
1198+
"properties": {
1199+
"error": {
1200+
"type": "object",
1201+
"properties": {
1202+
"type": {
1203+
"type": "string",
1204+
"enum": [
1205+
"row_not_found",
1206+
"table_not_found",
1207+
"table_not_big_table"
1208+
]
1209+
},
1210+
"message": {
1211+
"type": "string"
1212+
}
1213+
},
1214+
"required": [
1215+
"type",
1216+
"message"
1217+
],
1218+
"additionalProperties": false
1219+
}
1220+
},
1221+
"required": [
1222+
"error"
1223+
],
1224+
"additionalProperties": false
1225+
}
1226+
}
1227+
}
1228+
},
1229+
"422": {
1230+
"description": "",
1231+
"content": {
1232+
"application/json": {
1233+
"schema": {
1234+
"type": "object",
1235+
"properties": {
1236+
"error": {
1237+
"type": "object",
1238+
"properties": {
1239+
"type": {
1240+
"type": "string",
1241+
"enum": [
1242+
"column_has_invalid_value",
1243+
"column_id_reserved",
1244+
"column_id_not_found"
1245+
]
1246+
},
1247+
"message": {
1248+
"type": "string"
1249+
}
1250+
},
1251+
"required": [
1252+
"type",
1253+
"message"
1254+
],
1255+
"additionalProperties": false
1256+
}
1257+
},
1258+
"required": [
1259+
"error"
1260+
],
1261+
"additionalProperties": false
1262+
}
1263+
}
1264+
}
1265+
}
1266+
},
1267+
"parameters": [
1268+
{
1269+
"name": "tableID",
1270+
"in": "path",
1271+
"schema": {
1272+
"type": "string",
1273+
"description": "ID of the table, e.g., `2a1bad8b-cf7c-44437-b8c1-e3782df6`",
1274+
"example": "2a1bad8b-cf7c-44437-b8c1-e3782df6"
1275+
},
1276+
"required": true
1277+
},
1278+
{
1279+
"name": "rowID",
1280+
"in": "path",
1281+
"schema": {
1282+
"type": "string",
1283+
"description": "ID of the row, e.g., `2a1bad8b-cf7c-44437-b8c1-e3782df6`",
1284+
"example": "2a1bad8b-cf7c-44437-b8c1-e3782df6"
1285+
},
1286+
"required": true
1287+
},
1288+
{
1289+
"name": "onSchemaError",
1290+
"in": "query",
1291+
"schema": {
1292+
"type": "string",
1293+
"enum": [
1294+
"abort",
1295+
"dropColumns",
1296+
"updateSchema"
1297+
],
1298+
"description": "The action to take when the passed data does not match the table schema:\n\n- `abort`: Abort the entire operation and return an error.\n- `dropColumns`: Ignore the data that caused the error, and do not import those columns in the affected rows.\n- `updateSchema`: Update the schema as needed to add any missing columns or widen the data types of existing columns, and then import the data from them.",
1299+
"example": "updateSchema"
1300+
},
1301+
"required": false
1302+
}
1303+
],
1304+
"requestBody": {
1305+
"content": {
1306+
"application/json": {
1307+
"schema": {
1308+
"type": "object",
1309+
"additionalProperties": {},
1310+
"description": "A row object conforming to the schema of the table, where keys are the column IDs and values are the column values:\n\n```json\n{\n\t\"fullName\": \"Alex Bard\",\n\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\"totalAmount\": 34.50,\n\t\"amountPaid\": 0\n}\n```",
1311+
"example": {
1312+
"fullName": "Alex Bard",
1313+
"invoiceDate": "2024-07-29T14:04:15.561Z",
1314+
"totalAmount": 34.5,
1315+
"amountPaid": 0
1316+
}
1317+
}
1318+
}
1319+
}
1320+
},
1321+
"description": "Updates a row in a Big Table"
1322+
}
1323+
},
11241324
"/stashes/{stashID}/{serial}": {
11251325
"put": {
11261326
"responses": {
@@ -1201,7 +1401,14 @@
12011401
"type": "array",
12021402
"items": {
12031403
"type": "object",
1204-
"additionalProperties": {}
1404+
"additionalProperties": {},
1405+
"description": "A row object conforming to the schema of the table, where keys are the column IDs and values are the column values:\n\n```json\n{\n\t\"fullName\": \"Alex Bard\",\n\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\"totalAmount\": 34.50,\n\t\"amountPaid\": 0\n}\n```",
1406+
"example": {
1407+
"fullName": "Alex Bard",
1408+
"invoiceDate": "2024-07-29T14:04:15.561Z",
1409+
"totalAmount": 34.5,
1410+
"amountPaid": 0
1411+
}
12051412
},
12061413
"description": "A collection of row objects conforming to the schema of the table where keys are the column IDs and values are the column values:\n\n```json\n[\n\t{\n\t\t\"fullName\": \"Alex Bard\",\n\t\t\"invoiceDate\": \"2024-07-29T14:04:15.561Z\",\n\t\t\"totalAmount\": 34.50,\n\t\t\"amountPaid\": 0\n\t},\n\t{\n\t\t\"fullName\": \"Alicia Hines\",\n\t\t\"invoiceDate\": \"2023-06-15T10:30:00.000Z\",\n\t\t\"totalAmount\": 50.75,\n\t\t\"amountPaid\": 20\n\t}\n]\n```",
12071414
"example": [

0 commit comments

Comments
 (0)