@budibase/server 1.0.81 → 1.0.84-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/builder/assets/{index.f89561ac.js → index.0297e6da.js} +140 -139
- package/builder/assets/{index.dd19c61c.css → index.7c8961b4.css} +2 -2
- package/builder/index.html +2 -2
- package/coverage/clover.xml +10 -5
- package/coverage/coverage-final.json +2 -2
- package/coverage/lcov-report/api/controllers/analytics.js.html +1 -1
- package/coverage/lcov-report/api/controllers/apikeys.js.html +1 -1
- package/coverage/lcov-report/api/controllers/application.js.html +1 -1
- package/coverage/lcov-report/api/controllers/auth.js.html +1 -1
- package/coverage/lcov-report/api/controllers/automation.js.html +1 -1
- package/coverage/lcov-report/api/controllers/backup.js.html +1 -1
- package/coverage/lcov-report/api/controllers/cloud.js.html +1 -1
- package/coverage/lcov-report/api/controllers/component.js.html +1 -1
- package/coverage/lcov-report/api/controllers/datasource.js.html +1 -1
- package/coverage/lcov-report/api/controllers/dev.js.html +1 -1
- package/coverage/lcov-report/api/controllers/index.html +1 -1
- package/coverage/lcov-report/api/controllers/integration.js.html +1 -1
- package/coverage/lcov-report/api/controllers/layout.js.html +1 -1
- package/coverage/lcov-report/api/controllers/metadata.js.html +1 -1
- package/coverage/lcov-report/api/controllers/migrations.js.html +1 -1
- package/coverage/lcov-report/api/controllers/permission.js.html +1 -1
- package/coverage/lcov-report/api/controllers/query/index.html +1 -1
- package/coverage/lcov-report/api/controllers/query/index.js.html +1 -1
- package/coverage/lcov-report/api/controllers/query/validation.js.html +1 -1
- package/coverage/lcov-report/api/controllers/role.js.html +1 -1
- package/coverage/lcov-report/api/controllers/routing.js.html +1 -1
- package/coverage/lcov-report/api/controllers/row/external.js.html +5 -5
- package/coverage/lcov-report/api/controllers/row/index.html +1 -1
- package/coverage/lcov-report/api/controllers/row/index.js.html +1 -1
- package/coverage/lcov-report/api/controllers/row/internal.js.html +1 -1
- package/coverage/lcov-report/api/controllers/row/internalSearch.js.html +1 -1
- package/coverage/lcov-report/api/controllers/row/staticFormula.js.html +1 -1
- package/coverage/lcov-report/api/controllers/row/utils.js.html +1 -1
- package/coverage/lcov-report/api/controllers/screen.js.html +1 -1
- package/coverage/lcov-report/api/controllers/script.js.html +1 -1
- package/coverage/lcov-report/api/controllers/table/bulkFormula.js.html +1 -1
- package/coverage/lcov-report/api/controllers/table/external.js.html +1 -1
- package/coverage/lcov-report/api/controllers/table/index.html +1 -1
- package/coverage/lcov-report/api/controllers/table/index.js.html +1 -1
- package/coverage/lcov-report/api/controllers/table/internal.js.html +1 -1
- package/coverage/lcov-report/api/controllers/table/utils.js.html +1 -1
- package/coverage/lcov-report/api/controllers/templates.js.html +1 -1
- package/coverage/lcov-report/api/controllers/user.js.html +1 -1
- package/coverage/lcov-report/api/controllers/view/exporters.js.html +1 -1
- package/coverage/lcov-report/api/controllers/view/index.html +1 -1
- package/coverage/lcov-report/api/controllers/view/index.js.html +1 -1
- package/coverage/lcov-report/api/controllers/view/utils.js.html +1 -1
- package/coverage/lcov-report/api/controllers/view/viewBuilder.js.html +1 -1
- package/coverage/lcov-report/api/controllers/webhook.js.html +1 -1
- package/coverage/lcov-report/api/index.html +1 -1
- package/coverage/lcov-report/api/index.js.html +1 -1
- package/coverage/lcov-report/api/routes/analytics.js.html +1 -1
- package/coverage/lcov-report/api/routes/apikeys.js.html +1 -1
- package/coverage/lcov-report/api/routes/application.js.html +1 -1
- package/coverage/lcov-report/api/routes/auth.js.html +1 -1
- package/coverage/lcov-report/api/routes/automation.js.html +1 -1
- package/coverage/lcov-report/api/routes/backup.js.html +1 -1
- package/coverage/lcov-report/api/routes/cloud.js.html +1 -1
- package/coverage/lcov-report/api/routes/component.js.html +1 -1
- package/coverage/lcov-report/api/routes/datasource.js.html +1 -1
- package/coverage/lcov-report/api/routes/deploy.js.html +1 -1
- package/coverage/lcov-report/api/routes/dev.js.html +1 -1
- package/coverage/lcov-report/api/routes/index.html +1 -1
- package/coverage/lcov-report/api/routes/index.js.html +1 -1
- package/coverage/lcov-report/api/routes/integration.js.html +1 -1
- package/coverage/lcov-report/api/routes/layout.js.html +1 -1
- package/coverage/lcov-report/api/routes/metadata.js.html +1 -1
- package/coverage/lcov-report/api/routes/migrations.js.html +1 -1
- package/coverage/lcov-report/api/routes/permission.js.html +1 -1
- package/coverage/lcov-report/api/routes/query.js.html +1 -1
- package/coverage/lcov-report/api/routes/role.js.html +1 -1
- package/coverage/lcov-report/api/routes/routing.js.html +1 -1
- package/coverage/lcov-report/api/routes/row.js.html +1 -1
- package/coverage/lcov-report/api/routes/screen.js.html +1 -1
- package/coverage/lcov-report/api/routes/script.js.html +1 -1
- package/coverage/lcov-report/api/routes/static.js.html +1 -1
- package/coverage/lcov-report/api/routes/table.js.html +1 -1
- package/coverage/lcov-report/api/routes/templates.js.html +1 -1
- package/coverage/lcov-report/api/routes/user.js.html +1 -1
- package/coverage/lcov-report/api/routes/utils/index.html +1 -1
- package/coverage/lcov-report/api/routes/utils/validators.js.html +1 -1
- package/coverage/lcov-report/api/routes/view.js.html +1 -1
- package/coverage/lcov-report/api/routes/webhook.js.html +1 -1
- package/coverage/lcov-report/automations/actions.js.html +1 -1
- package/coverage/lcov-report/automations/automationUtils.js.html +1 -1
- package/coverage/lcov-report/automations/bullboard.js.html +1 -1
- package/coverage/lcov-report/automations/index.html +1 -1
- package/coverage/lcov-report/automations/index.js.html +1 -1
- package/coverage/lcov-report/automations/steps/bash.js.html +1 -1
- package/coverage/lcov-report/automations/steps/createRow.js.html +1 -1
- package/coverage/lcov-report/automations/steps/delay.js.html +1 -1
- package/coverage/lcov-report/automations/steps/deleteRow.js.html +1 -1
- package/coverage/lcov-report/automations/steps/discord.js.html +1 -1
- package/coverage/lcov-report/automations/steps/executeQuery.js.html +1 -1
- package/coverage/lcov-report/automations/steps/executeScript.js.html +1 -1
- package/coverage/lcov-report/automations/steps/filter.js.html +1 -1
- package/coverage/lcov-report/automations/steps/index.html +1 -1
- package/coverage/lcov-report/automations/steps/integromat.js.html +1 -1
- package/coverage/lcov-report/automations/steps/outgoingWebhook.js.html +1 -1
- package/coverage/lcov-report/automations/steps/queryRows.js.html +1 -1
- package/coverage/lcov-report/automations/steps/sendSmtpEmail.js.html +1 -1
- package/coverage/lcov-report/automations/steps/serverLog.js.html +1 -1
- package/coverage/lcov-report/automations/steps/slack.js.html +1 -1
- package/coverage/lcov-report/automations/steps/updateRow.js.html +1 -1
- package/coverage/lcov-report/automations/steps/utils.js.html +1 -1
- package/coverage/lcov-report/automations/steps/zapier.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/app.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/cron.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/index.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/index.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/rowDeleted.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/rowSaved.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/rowUpdated.js.html +1 -1
- package/coverage/lcov-report/automations/triggerInfo/webhook.js.html +1 -1
- package/coverage/lcov-report/automations/triggers.js.html +1 -1
- package/coverage/lcov-report/automations/utils.js.html +1 -1
- package/coverage/lcov-report/constants/index.html +1 -1
- package/coverage/lcov-report/constants/index.js.html +1 -1
- package/coverage/lcov-report/constants/layouts.js.html +1 -1
- package/coverage/lcov-report/constants/screens.js.html +1 -1
- package/coverage/lcov-report/db/client.js.html +1 -1
- package/coverage/lcov-report/db/inMemoryView.js.html +1 -1
- package/coverage/lcov-report/db/index.html +1 -1
- package/coverage/lcov-report/db/index.js.html +1 -1
- package/coverage/lcov-report/db/linkedRows/LinkController.js.html +1 -1
- package/coverage/lcov-report/db/linkedRows/index.html +1 -1
- package/coverage/lcov-report/db/linkedRows/index.js.html +1 -1
- package/coverage/lcov-report/db/linkedRows/linkUtils.js.html +1 -1
- package/coverage/lcov-report/db/newid.js.html +1 -1
- package/coverage/lcov-report/db/utils.js.html +1 -1
- package/coverage/lcov-report/events/AutomationEmitter.js.html +1 -1
- package/coverage/lcov-report/events/index.html +1 -1
- package/coverage/lcov-report/events/index.js.html +1 -1
- package/coverage/lcov-report/events/utils.js.html +1 -1
- package/coverage/lcov-report/index.html +18 -18
- package/coverage/lcov-report/integrations/tests/TestConfiguration.js.html +1 -1
- package/coverage/lcov-report/integrations/tests/index.html +1 -1
- package/coverage/lcov-report/middleware/appInfo.js.html +1 -1
- package/coverage/lcov-report/middleware/authorized.js.html +1 -1
- package/coverage/lcov-report/middleware/builder.js.html +1 -1
- package/coverage/lcov-report/middleware/currentapp.js.html +1 -1
- package/coverage/lcov-report/middleware/index.html +1 -1
- package/coverage/lcov-report/middleware/joi-validator.js.html +1 -1
- package/coverage/lcov-report/middleware/resourceId.js.html +1 -1
- package/coverage/lcov-report/middleware/selfhost.js.html +1 -1
- package/coverage/lcov-report/middleware/usageQuota.js.html +1 -1
- package/coverage/lcov-report/middleware/utils.js.html +1 -1
- package/coverage/lcov-report/threads/automation.js.html +1 -1
- package/coverage/lcov-report/threads/index.html +1 -1
- package/coverage/lcov-report/threads/index.js.html +1 -1
- package/coverage/lcov-report/threads/query.js.html +1 -1
- package/coverage/lcov-report/threads/utils.js.html +1 -1
- package/coverage/lcov-report/utilities/bcrypt.js.html +1 -1
- package/coverage/lcov-report/utilities/budibaseDir.js.html +1 -1
- package/coverage/lcov-report/utilities/centralPath.js.html +1 -1
- package/coverage/lcov-report/utilities/csvParser.js.html +1 -1
- package/coverage/lcov-report/utilities/global.js.html +1 -1
- package/coverage/lcov-report/utilities/index.html +18 -18
- package/coverage/lcov-report/utilities/index.js.html +34 -10
- package/coverage/lcov-report/utilities/queue/inMemoryQueue.js.html +1 -1
- package/coverage/lcov-report/utilities/queue/index.html +1 -1
- package/coverage/lcov-report/utilities/routing/index.html +1 -1
- package/coverage/lcov-report/utilities/routing/index.js.html +1 -1
- package/coverage/lcov-report/utilities/rowProcessor/index.html +1 -1
- package/coverage/lcov-report/utilities/rowProcessor/index.js.html +1 -1
- package/coverage/lcov-report/utilities/rowProcessor/utils.js.html +1 -1
- package/coverage/lcov-report/utilities/scriptRunner.js.html +1 -1
- package/coverage/lcov-report/utilities/security.js.html +1 -1
- package/coverage/lcov-report/utilities/statusCodes.js.html +1 -1
- package/coverage/lcov-report/utilities/usageQuota/index.html +1 -1
- package/coverage/lcov-report/utilities/usageQuota/index.js.html +1 -1
- package/coverage/lcov-report/utilities/usageQuota/rows.js.html +1 -1
- package/coverage/lcov-report/utilities/usageQuota/usageQuoteReset.js.html +1 -1
- package/coverage/lcov-report/utilities/users.js.html +1 -1
- package/coverage/lcov-report/utilities/workerRequests.js.html +1 -1
- package/coverage/lcov.info +17 -6
- package/dist/api/controllers/public/rows.js +2 -1
- package/dist/api/controllers/row/external.js +4 -4
- package/dist/api/routes/public/applications.js +1 -10
- package/dist/api/routes/public/queries.js +1 -8
- package/dist/api/routes/public/tables.js +1 -8
- package/dist/api/routes/public/users.js +1 -8
- package/dist/package.json +4 -4
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/utilities/index.js +7 -0
- package/package.json +5 -5
- package/scripts/docs/toSwagger.js +1 -1
- package/specs/openapi.json +430 -55
- package/specs/openapi.yaml +337 -35
- package/specs/resources/application.js +7 -1
- package/specs/resources/query.js +6 -0
- package/specs/resources/table.js +6 -0
- package/specs/resources/user.js +6 -0
- package/src/api/controllers/public/rows.ts +2 -1
- package/src/api/controllers/row/external.js +4 -4
- package/src/api/routes/public/applications.ts +1 -10
- package/src/api/routes/public/queries.ts +1 -8
- package/src/api/routes/public/tables.ts +1 -8
- package/src/api/routes/public/users.ts +1 -8
- package/src/definitions/openapi.ts +591 -415
- package/src/utilities/index.js +8 -0
package/dist/utilities/index.js
CHANGED
|
@@ -142,3 +142,10 @@ exports.formatBytes = bytes => {
|
|
|
142
142
|
}
|
|
143
143
|
return `${size.toFixed(size < 10 && unit > 0 ? 1 : 0)}${units[unit]}`;
|
|
144
144
|
};
|
|
145
|
+
exports.convertBookmark = bookmark => {
|
|
146
|
+
const IS_NUMBER = /^\d+\.?\d*$/;
|
|
147
|
+
if (typeof bookmark === "string" && bookmark.match(IS_NUMBER)) {
|
|
148
|
+
return parseFloat(bookmark);
|
|
149
|
+
}
|
|
150
|
+
return bookmark;
|
|
151
|
+
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@budibase/server",
|
|
3
3
|
"email": "hi@budibase.com",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.84-alpha.0",
|
|
5
5
|
"description": "Budibase Web Server",
|
|
6
6
|
"main": "src/index.ts",
|
|
7
7
|
"repository": {
|
|
@@ -71,9 +71,9 @@
|
|
|
71
71
|
"license": "GPL-3.0",
|
|
72
72
|
"dependencies": {
|
|
73
73
|
"@apidevtools/swagger-parser": "^10.0.3",
|
|
74
|
-
"@budibase/backend-core": "^1.0.
|
|
75
|
-
"@budibase/client": "^1.0.
|
|
76
|
-
"@budibase/string-templates": "^1.0.
|
|
74
|
+
"@budibase/backend-core": "^1.0.84-alpha.0",
|
|
75
|
+
"@budibase/client": "^1.0.84-alpha.0",
|
|
76
|
+
"@budibase/string-templates": "^1.0.84-alpha.0",
|
|
77
77
|
"@bull-board/api": "^3.7.0",
|
|
78
78
|
"@bull-board/koa": "^3.7.0",
|
|
79
79
|
"@elastic/elasticsearch": "7.10.0",
|
|
@@ -175,5 +175,5 @@
|
|
|
175
175
|
"optionalDependencies": {
|
|
176
176
|
"oracledb": "^5.3.0"
|
|
177
177
|
},
|
|
178
|
-
"gitHead": "
|
|
178
|
+
"gitHead": "5749e88ed2cf6f9a29c10461163ea65ba03553ef"
|
|
179
179
|
}
|
|
@@ -51,7 +51,7 @@ function extractPaths(apidocJson) {
|
|
|
51
51
|
// Surrounds URL parameters with curly brackets -> :email with {email}
|
|
52
52
|
let pathKeys = []
|
|
53
53
|
for (let j = 1; j < matches.length; j++) {
|
|
54
|
-
let key = matches[j].
|
|
54
|
+
let key = matches[j].slice(1)
|
|
55
55
|
url = url.replace(matches[j], "{" + key + "}")
|
|
56
56
|
pathKeys.push(key)
|
|
57
57
|
}
|
package/specs/openapi.json
CHANGED
|
@@ -437,8 +437,7 @@
|
|
|
437
437
|
}
|
|
438
438
|
},
|
|
439
439
|
"required": [
|
|
440
|
-
"name"
|
|
441
|
-
"url"
|
|
440
|
+
"name"
|
|
442
441
|
]
|
|
443
442
|
},
|
|
444
443
|
"applicationOutput": {
|
|
@@ -503,6 +502,71 @@
|
|
|
503
502
|
"data"
|
|
504
503
|
]
|
|
505
504
|
},
|
|
505
|
+
"applicationSearch": {
|
|
506
|
+
"type": "object",
|
|
507
|
+
"properties": {
|
|
508
|
+
"data": {
|
|
509
|
+
"type": "array",
|
|
510
|
+
"items": {
|
|
511
|
+
"type": "object",
|
|
512
|
+
"properties": {
|
|
513
|
+
"name": {
|
|
514
|
+
"description": "The name of the app.",
|
|
515
|
+
"type": "string"
|
|
516
|
+
},
|
|
517
|
+
"url": {
|
|
518
|
+
"description": "The URL by which the app is accessed, this must be URL encoded.",
|
|
519
|
+
"type": "string"
|
|
520
|
+
},
|
|
521
|
+
"_id": {
|
|
522
|
+
"description": "The ID of the app.",
|
|
523
|
+
"type": "string"
|
|
524
|
+
},
|
|
525
|
+
"status": {
|
|
526
|
+
"description": "The status of the app, stating it if is the development or published version.",
|
|
527
|
+
"type": "string",
|
|
528
|
+
"enum": [
|
|
529
|
+
"development",
|
|
530
|
+
"published"
|
|
531
|
+
]
|
|
532
|
+
},
|
|
533
|
+
"createdAt": {
|
|
534
|
+
"description": "States when the app was created, will be constant. Stored in ISO format.",
|
|
535
|
+
"type": "string"
|
|
536
|
+
},
|
|
537
|
+
"updatedAt": {
|
|
538
|
+
"description": "States the last time the app was updated - stored in ISO format.",
|
|
539
|
+
"type": "string"
|
|
540
|
+
},
|
|
541
|
+
"version": {
|
|
542
|
+
"description": "States the version of the Budibase client this app is currently based on.",
|
|
543
|
+
"type": "string"
|
|
544
|
+
},
|
|
545
|
+
"tenantId": {
|
|
546
|
+
"description": "In a multi-tenant environment this will state the tenant this app is within.",
|
|
547
|
+
"type": "string"
|
|
548
|
+
},
|
|
549
|
+
"lockedBy": {
|
|
550
|
+
"description": "The user this app is currently being built by.",
|
|
551
|
+
"type": "object"
|
|
552
|
+
}
|
|
553
|
+
},
|
|
554
|
+
"required": [
|
|
555
|
+
"_id",
|
|
556
|
+
"name",
|
|
557
|
+
"url",
|
|
558
|
+
"status",
|
|
559
|
+
"createdAt",
|
|
560
|
+
"updatedAt",
|
|
561
|
+
"version"
|
|
562
|
+
]
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
},
|
|
566
|
+
"required": [
|
|
567
|
+
"data"
|
|
568
|
+
]
|
|
569
|
+
},
|
|
506
570
|
"row": {
|
|
507
571
|
"description": "The row to be created/updated, based on the table schema.",
|
|
508
572
|
"type": "object",
|
|
@@ -980,6 +1044,221 @@
|
|
|
980
1044
|
"data"
|
|
981
1045
|
]
|
|
982
1046
|
},
|
|
1047
|
+
"tableSearch": {
|
|
1048
|
+
"type": "object",
|
|
1049
|
+
"properties": {
|
|
1050
|
+
"data": {
|
|
1051
|
+
"type": "array",
|
|
1052
|
+
"items": {
|
|
1053
|
+
"description": "The table to be created/updated.",
|
|
1054
|
+
"type": "object",
|
|
1055
|
+
"required": [
|
|
1056
|
+
"name",
|
|
1057
|
+
"schema",
|
|
1058
|
+
"_id"
|
|
1059
|
+
],
|
|
1060
|
+
"properties": {
|
|
1061
|
+
"name": {
|
|
1062
|
+
"description": "The name of the table.",
|
|
1063
|
+
"type": "string"
|
|
1064
|
+
},
|
|
1065
|
+
"primaryDisplay": {
|
|
1066
|
+
"type": "string",
|
|
1067
|
+
"description": "The name of the column which should be used in relationship tags when relating to this table."
|
|
1068
|
+
},
|
|
1069
|
+
"schema": {
|
|
1070
|
+
"type": "object",
|
|
1071
|
+
"additionalProperties": {
|
|
1072
|
+
"oneOf": [
|
|
1073
|
+
{
|
|
1074
|
+
"type": "object",
|
|
1075
|
+
"properties": {
|
|
1076
|
+
"type": {
|
|
1077
|
+
"type": "string",
|
|
1078
|
+
"enum": [
|
|
1079
|
+
"link"
|
|
1080
|
+
],
|
|
1081
|
+
"description": "A relationship column."
|
|
1082
|
+
},
|
|
1083
|
+
"constraints": {
|
|
1084
|
+
"type": "object",
|
|
1085
|
+
"description": "A constraint can be applied to the column which will be validated against when a row is saved.",
|
|
1086
|
+
"properties": {
|
|
1087
|
+
"type": {
|
|
1088
|
+
"type": "string",
|
|
1089
|
+
"enum": [
|
|
1090
|
+
"string",
|
|
1091
|
+
"number",
|
|
1092
|
+
"object",
|
|
1093
|
+
"boolean"
|
|
1094
|
+
]
|
|
1095
|
+
},
|
|
1096
|
+
"presence": {
|
|
1097
|
+
"type": "boolean",
|
|
1098
|
+
"description": "Defines whether the column is required or not."
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
},
|
|
1102
|
+
"name": {
|
|
1103
|
+
"type": "string",
|
|
1104
|
+
"description": "The name of the column."
|
|
1105
|
+
},
|
|
1106
|
+
"autocolumn": {
|
|
1107
|
+
"type": "boolean",
|
|
1108
|
+
"description": "Defines whether the column is automatically generated."
|
|
1109
|
+
},
|
|
1110
|
+
"fieldName": {
|
|
1111
|
+
"type": "string",
|
|
1112
|
+
"description": "The name of the column which a relationship column is related to in another table."
|
|
1113
|
+
},
|
|
1114
|
+
"tableId": {
|
|
1115
|
+
"type": "string",
|
|
1116
|
+
"description": "The ID of the table which a relationship column is related to."
|
|
1117
|
+
},
|
|
1118
|
+
"relationshipType": {
|
|
1119
|
+
"type": "string",
|
|
1120
|
+
"enum": [
|
|
1121
|
+
"one-to-many",
|
|
1122
|
+
"many-to-one",
|
|
1123
|
+
"many-to-many"
|
|
1124
|
+
],
|
|
1125
|
+
"description": "Defines the type of relationship that this column will be used for."
|
|
1126
|
+
},
|
|
1127
|
+
"through": {
|
|
1128
|
+
"type": "string",
|
|
1129
|
+
"description": "When using a SQL table that contains many to many relationships this defines the table the relationships are linked through."
|
|
1130
|
+
},
|
|
1131
|
+
"foreignKey": {
|
|
1132
|
+
"type": "string",
|
|
1133
|
+
"description": "When using a SQL table that contains a one to many relationship this defines the foreign key."
|
|
1134
|
+
},
|
|
1135
|
+
"throughFrom": {
|
|
1136
|
+
"type": "string",
|
|
1137
|
+
"description": "When using a SQL table that utilises a through table, this defines the primary key in the through table for this table."
|
|
1138
|
+
},
|
|
1139
|
+
"throughTo": {
|
|
1140
|
+
"type": "string",
|
|
1141
|
+
"description": "When using a SQL table that utilises a through table, this defines the primary key in the through table for the related table."
|
|
1142
|
+
}
|
|
1143
|
+
}
|
|
1144
|
+
},
|
|
1145
|
+
{
|
|
1146
|
+
"type": "object",
|
|
1147
|
+
"properties": {
|
|
1148
|
+
"type": {
|
|
1149
|
+
"type": "string",
|
|
1150
|
+
"enum": [
|
|
1151
|
+
"formula"
|
|
1152
|
+
],
|
|
1153
|
+
"description": "A formula column."
|
|
1154
|
+
},
|
|
1155
|
+
"constraints": {
|
|
1156
|
+
"type": "object",
|
|
1157
|
+
"description": "A constraint can be applied to the column which will be validated against when a row is saved.",
|
|
1158
|
+
"properties": {
|
|
1159
|
+
"type": {
|
|
1160
|
+
"type": "string",
|
|
1161
|
+
"enum": [
|
|
1162
|
+
"string",
|
|
1163
|
+
"number",
|
|
1164
|
+
"object",
|
|
1165
|
+
"boolean"
|
|
1166
|
+
]
|
|
1167
|
+
},
|
|
1168
|
+
"presence": {
|
|
1169
|
+
"type": "boolean",
|
|
1170
|
+
"description": "Defines whether the column is required or not."
|
|
1171
|
+
}
|
|
1172
|
+
}
|
|
1173
|
+
},
|
|
1174
|
+
"name": {
|
|
1175
|
+
"type": "string",
|
|
1176
|
+
"description": "The name of the column."
|
|
1177
|
+
},
|
|
1178
|
+
"autocolumn": {
|
|
1179
|
+
"type": "boolean",
|
|
1180
|
+
"description": "Defines whether the column is automatically generated."
|
|
1181
|
+
},
|
|
1182
|
+
"formula": {
|
|
1183
|
+
"type": "string",
|
|
1184
|
+
"description": "Defines a Handlebars or JavaScript formula to use, note that Javascript formulas are expected to be provided in the base64 format."
|
|
1185
|
+
},
|
|
1186
|
+
"formulaType": {
|
|
1187
|
+
"type": "string",
|
|
1188
|
+
"enum": [
|
|
1189
|
+
"static",
|
|
1190
|
+
"dynamic"
|
|
1191
|
+
],
|
|
1192
|
+
"description": "Defines whether this is a static or dynamic formula."
|
|
1193
|
+
}
|
|
1194
|
+
}
|
|
1195
|
+
},
|
|
1196
|
+
{
|
|
1197
|
+
"type": "object",
|
|
1198
|
+
"properties": {
|
|
1199
|
+
"type": {
|
|
1200
|
+
"type": "string",
|
|
1201
|
+
"enum": [
|
|
1202
|
+
"string",
|
|
1203
|
+
"longform",
|
|
1204
|
+
"options",
|
|
1205
|
+
"number",
|
|
1206
|
+
"boolean",
|
|
1207
|
+
"array",
|
|
1208
|
+
"datetime",
|
|
1209
|
+
"attachment",
|
|
1210
|
+
"link",
|
|
1211
|
+
"formula",
|
|
1212
|
+
"auto",
|
|
1213
|
+
"json",
|
|
1214
|
+
"internal"
|
|
1215
|
+
],
|
|
1216
|
+
"description": "Defines the type of the column, most explain themselves, a link column is a relationship."
|
|
1217
|
+
},
|
|
1218
|
+
"constraints": {
|
|
1219
|
+
"type": "object",
|
|
1220
|
+
"description": "A constraint can be applied to the column which will be validated against when a row is saved.",
|
|
1221
|
+
"properties": {
|
|
1222
|
+
"type": {
|
|
1223
|
+
"type": "string",
|
|
1224
|
+
"enum": [
|
|
1225
|
+
"string",
|
|
1226
|
+
"number",
|
|
1227
|
+
"object",
|
|
1228
|
+
"boolean"
|
|
1229
|
+
]
|
|
1230
|
+
},
|
|
1231
|
+
"presence": {
|
|
1232
|
+
"type": "boolean",
|
|
1233
|
+
"description": "Defines whether the column is required or not."
|
|
1234
|
+
}
|
|
1235
|
+
}
|
|
1236
|
+
},
|
|
1237
|
+
"name": {
|
|
1238
|
+
"type": "string",
|
|
1239
|
+
"description": "The name of the column."
|
|
1240
|
+
},
|
|
1241
|
+
"autocolumn": {
|
|
1242
|
+
"type": "boolean",
|
|
1243
|
+
"description": "Defines whether the column is automatically generated."
|
|
1244
|
+
}
|
|
1245
|
+
}
|
|
1246
|
+
}
|
|
1247
|
+
]
|
|
1248
|
+
}
|
|
1249
|
+
},
|
|
1250
|
+
"_id": {
|
|
1251
|
+
"description": "The ID of the table.",
|
|
1252
|
+
"type": "string"
|
|
1253
|
+
}
|
|
1254
|
+
}
|
|
1255
|
+
}
|
|
1256
|
+
}
|
|
1257
|
+
},
|
|
1258
|
+
"required": [
|
|
1259
|
+
"data"
|
|
1260
|
+
]
|
|
1261
|
+
},
|
|
983
1262
|
"executeQuery": {
|
|
984
1263
|
"description": "The query body must contain the required parameters for the query, this depends on query type, setup and bindings.",
|
|
985
1264
|
"type": "object",
|
|
@@ -1074,6 +1353,71 @@
|
|
|
1074
1353
|
"_id"
|
|
1075
1354
|
]
|
|
1076
1355
|
},
|
|
1356
|
+
"querySearch": {
|
|
1357
|
+
"type": "object",
|
|
1358
|
+
"properties": {
|
|
1359
|
+
"data": {
|
|
1360
|
+
"type": "array",
|
|
1361
|
+
"items": {
|
|
1362
|
+
"type": "object",
|
|
1363
|
+
"properties": {
|
|
1364
|
+
"_id": {
|
|
1365
|
+
"description": "The ID of the query.",
|
|
1366
|
+
"type": "string"
|
|
1367
|
+
},
|
|
1368
|
+
"datasourceId": {
|
|
1369
|
+
"description": "The ID of the data source the query belongs to.",
|
|
1370
|
+
"type": "string"
|
|
1371
|
+
},
|
|
1372
|
+
"parameters": {
|
|
1373
|
+
"description": "The bindings which are required to perform this query.",
|
|
1374
|
+
"type": "array",
|
|
1375
|
+
"items": {
|
|
1376
|
+
"type": "string"
|
|
1377
|
+
}
|
|
1378
|
+
},
|
|
1379
|
+
"fields": {
|
|
1380
|
+
"description": "The fields that are used to perform this query, e.g. the sql statement",
|
|
1381
|
+
"type": "object"
|
|
1382
|
+
},
|
|
1383
|
+
"queryVerb": {
|
|
1384
|
+
"description": "The verb that describes this query.",
|
|
1385
|
+
"enum": [
|
|
1386
|
+
"create",
|
|
1387
|
+
"read",
|
|
1388
|
+
"update",
|
|
1389
|
+
"delete"
|
|
1390
|
+
]
|
|
1391
|
+
},
|
|
1392
|
+
"name": {
|
|
1393
|
+
"description": "The name of the query.",
|
|
1394
|
+
"type": "string"
|
|
1395
|
+
},
|
|
1396
|
+
"schema": {
|
|
1397
|
+
"description": "The schema of the data returned when the query is executed.",
|
|
1398
|
+
"type": "object"
|
|
1399
|
+
},
|
|
1400
|
+
"transformer": {
|
|
1401
|
+
"description": "The JavaScript transformer function, applied after the query responds with data.",
|
|
1402
|
+
"type": "string"
|
|
1403
|
+
},
|
|
1404
|
+
"readable": {
|
|
1405
|
+
"description": "Whether the query has readable data.",
|
|
1406
|
+
"type": "boolean"
|
|
1407
|
+
}
|
|
1408
|
+
},
|
|
1409
|
+
"required": [
|
|
1410
|
+
"name",
|
|
1411
|
+
"schema",
|
|
1412
|
+
"_id"
|
|
1413
|
+
]
|
|
1414
|
+
}
|
|
1415
|
+
}
|
|
1416
|
+
},
|
|
1417
|
+
"required": [
|
|
1418
|
+
"data"
|
|
1419
|
+
]
|
|
1420
|
+
},
|
|
1077
1421
|
"user": {
|
|
1078
1422
|
"type": "object",
|
|
1079
1423
|
"properties": {
|
|
@@ -1215,6 +1559,86 @@
|
|
|
1215
1559
|
"data"
|
|
1216
1560
|
]
|
|
1217
1561
|
},
|
|
1562
|
+
"userSearch": {
|
|
1563
|
+
"type": "object",
|
|
1564
|
+
"properties": {
|
|
1565
|
+
"data": {
|
|
1566
|
+
"type": "array",
|
|
1567
|
+
"items": {
|
|
1568
|
+
"type": "object",
|
|
1569
|
+
"properties": {
|
|
1570
|
+
"email": {
|
|
1571
|
+
"description": "The email address of the user, this must be unique.",
|
|
1572
|
+
"type": "string"
|
|
1573
|
+
},
|
|
1574
|
+
"password": {
|
|
1575
|
+
"description": "The password of the user if using password based login - this will never be returned. This can be left out of subsequent requests (updates) and will be enriched back into the user structure.",
|
|
1576
|
+
"type": "string"
|
|
1577
|
+
},
|
|
1578
|
+
"status": {
|
|
1579
|
+
"description": "The status of the user, if they are active.",
|
|
1580
|
+
"type": "string",
|
|
1581
|
+
"enum": [
|
|
1582
|
+
"active"
|
|
1583
|
+
]
|
|
1584
|
+
},
|
|
1585
|
+
"firstName": {
|
|
1586
|
+
"description": "The first name of the user",
|
|
1587
|
+
"type": "string"
|
|
1588
|
+
},
|
|
1589
|
+
"lastName": {
|
|
1590
|
+
"description": "The last name of the user",
|
|
1591
|
+
"type": "string"
|
|
1592
|
+
},
|
|
1593
|
+
"forceResetPassword": {
|
|
1594
|
+
"description": "If set to true forces the user to reset their password on first login.",
|
|
1595
|
+
"type": "boolean"
|
|
1596
|
+
},
|
|
1597
|
+
"builder": {
|
|
1598
|
+
"description": "Describes if the user is a builder user or not.",
|
|
1599
|
+
"type": "object",
|
|
1600
|
+
"properties": {
|
|
1601
|
+
"global": {
|
|
1602
|
+
"description": "If set to true the user will be able to build any app in the system.",
|
|
1603
|
+
"type": "boolean"
|
|
1604
|
+
}
|
|
1605
|
+
}
|
|
1606
|
+
},
|
|
1607
|
+
"admin": {
|
|
1608
|
+
"description": "Describes if the user is an admin user or not.",
|
|
1609
|
+
"type": "object",
|
|
1610
|
+
"properties": {
|
|
1611
|
+
"global": {
|
|
1612
|
+
"description": "If set to true the user will be able to administrate the system.",
|
|
1613
|
+
"type": "boolean"
|
|
1614
|
+
}
|
|
1615
|
+
}
|
|
1616
|
+
},
|
|
1617
|
+
"roles": {
|
|
1618
|
+
"description": "Contains the roles of the user per app (assuming they are not a builder user).",
|
|
1619
|
+
"type": "object",
|
|
1620
|
+
"additionalProperties": {
|
|
1621
|
+
"type": "string",
|
|
1622
|
+
"description": "A map of app ID (production app ID, minus the _dev component) to a role ID, e.g. ADMIN."
|
|
1623
|
+
}
|
|
1624
|
+
},
|
|
1625
|
+
"_id": {
|
|
1626
|
+
"description": "The ID of the user.",
|
|
1627
|
+
"type": "string"
|
|
1628
|
+
}
|
|
1629
|
+
},
|
|
1630
|
+
"required": [
|
|
1631
|
+
"email",
|
|
1632
|
+
"roles",
|
|
1633
|
+
"_id"
|
|
1634
|
+
]
|
|
1635
|
+
}
|
|
1636
|
+
}
|
|
1637
|
+
},
|
|
1638
|
+
"required": [
|
|
1639
|
+
"data"
|
|
1640
|
+
]
|
|
1641
|
+
},
|
|
1218
1642
|
"nameSearch": {
|
|
1219
1643
|
"type": "object",
|
|
1220
1644
|
"properties": {
|
|
@@ -1378,11 +1802,6 @@
|
|
|
1378
1802
|
"tags": [
|
|
1379
1803
|
"applications"
|
|
1380
1804
|
],
|
|
1381
|
-
"parameters": [
|
|
1382
|
-
{
|
|
1383
|
-
"$ref": "#/components/parameters/appId"
|
|
1384
|
-
}
|
|
1385
|
-
],
|
|
1386
1805
|
"requestBody": {
|
|
1387
1806
|
"required": true,
|
|
1388
1807
|
"content": {
|
|
@@ -1399,18 +1818,7 @@
|
|
|
1399
1818
|
"content": {
|
|
1400
1819
|
"application/json": {
|
|
1401
1820
|
"schema": {
|
|
1402
|
-
"
|
|
1403
|
-
"required": [
|
|
1404
|
-
"data"
|
|
1405
|
-
],
|
|
1406
|
-
"properties": {
|
|
1407
|
-
"data": {
|
|
1408
|
-
"type": "array",
|
|
1409
|
-
"items": {
|
|
1410
|
-
"$ref": "#/components/schemas/application"
|
|
1411
|
-
}
|
|
1412
|
-
}
|
|
1413
|
-
}
|
|
1821
|
+
"$ref": "#/components/schemas/applicationSearch"
|
|
1414
1822
|
},
|
|
1415
1823
|
"examples": {
|
|
1416
1824
|
"applications": {
|
|
@@ -1498,18 +1906,7 @@
|
|
|
1498
1906
|
"content": {
|
|
1499
1907
|
"application/json": {
|
|
1500
1908
|
"schema": {
|
|
1501
|
-
"
|
|
1502
|
-
"required": [
|
|
1503
|
-
"data"
|
|
1504
|
-
],
|
|
1505
|
-
"properties": {
|
|
1506
|
-
"data": {
|
|
1507
|
-
"type": "array",
|
|
1508
|
-
"items": {
|
|
1509
|
-
"$ref": "#/components/schemas/query"
|
|
1510
|
-
}
|
|
1511
|
-
}
|
|
1512
|
-
}
|
|
1909
|
+
"$ref": "#/components/schemas/querySearch"
|
|
1513
1910
|
},
|
|
1514
1911
|
"examples": {
|
|
1515
1912
|
"queries": {
|
|
@@ -2025,18 +2422,7 @@
|
|
|
2025
2422
|
"content": {
|
|
2026
2423
|
"application/json": {
|
|
2027
2424
|
"schema": {
|
|
2028
|
-
"
|
|
2029
|
-
"required": [
|
|
2030
|
-
"data"
|
|
2031
|
-
],
|
|
2032
|
-
"properties": {
|
|
2033
|
-
"data": {
|
|
2034
|
-
"type": "array",
|
|
2035
|
-
"items": {
|
|
2036
|
-
"$ref": "#/components/schemas/table"
|
|
2037
|
-
}
|
|
2038
|
-
}
|
|
2039
|
-
}
|
|
2425
|
+
"$ref": "#/components/schemas/tableSearch"
|
|
2040
2426
|
},
|
|
2041
2427
|
"examples": {
|
|
2042
2428
|
"tables": {
|
|
@@ -2203,18 +2589,7 @@
|
|
|
2203
2589
|
"content": {
|
|
2204
2590
|
"application/json": {
|
|
2205
2591
|
"schema": {
|
|
2206
|
-
"
|
|
2207
|
-
"required": [
|
|
2208
|
-
"data"
|
|
2209
|
-
],
|
|
2210
|
-
"properties": {
|
|
2211
|
-
"data": {
|
|
2212
|
-
"type": "array",
|
|
2213
|
-
"items": {
|
|
2214
|
-
"$ref": "#/components/schemas/user"
|
|
2215
|
-
}
|
|
2216
|
-
}
|
|
2217
|
-
}
|
|
2592
|
+
"$ref": "#/components/schemas/userSearch"
|
|
2218
2593
|
},
|
|
2219
2594
|
"examples": {
|
|
2220
2595
|
"users": {
|