Fix specs

This commit is contained in:
Jake Barnby
2024-10-08 14:17:34 +13:00
parent 507f8c6955
commit be1cada848
7 changed files with 166 additions and 184 deletions
+1 -1
View File
@@ -5084,7 +5084,7 @@
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"x-example": null
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
@@ -11054,7 +11054,7 @@
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"x-example": null
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
+1 -1
View File
@@ -9941,7 +9941,7 @@
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"x-example": null
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
+54 -60
View File
@@ -5167,7 +5167,7 @@
"summary": "Create execution",
"operationId": "functionsCreateExecution",
"consumes": [
"multipart\/form-data"
"application\/json"
],
"produces": [
"multipart\/form-data"
@@ -5226,65 +5226,59 @@
"in": "path"
},
{
"name": "body",
"description": "HTTP body of execution. Default value is empty string.",
"required": false,
"type": "payload",
"default": "",
"in": "formData"
},
{
"name": "async",
"description": "Execute code in the background. Default value is false.",
"required": false,
"type": "boolean",
"x-example": false,
"default": false,
"in": "formData"
},
{
"name": "path",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"required": false,
"type": "string",
"x-example": "<PATH>",
"default": "\/",
"in": "formData"
},
{
"name": "method",
"description": "HTTP method of execution. Default value is GET.",
"required": false,
"type": "string",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": [],
"default": "POST",
"in": "formData"
},
{
"name": "headers",
"description": "HTTP headers of execution. Defaults to empty.",
"required": false,
"type": "object",
"default": [],
"x-example": "{}",
"in": "formData"
},
{
"name": "scheduledAt",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"required": false,
"type": "string",
"in": "formData"
"name": "payload",
"in": "body",
"schema": {
"type": "object",
"properties": {
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"default": "",
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
"description": "Execute code in the background. Default value is false.",
"default": false,
"x-example": false
},
"path": {
"type": "string",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"default": "\/",
"x-example": "<PATH>"
},
"method": {
"type": "string",
"description": "HTTP method of execution. Default value is GET.",
"default": "POST",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": []
},
"headers": {
"type": "object",
"description": "HTTP headers of execution. Defaults to empty.",
"default": [],
"x-example": "{}"
},
"scheduledAt": {
"type": "string",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"default": null,
"x-example": null
}
}
}
}
]
}
+54 -60
View File
@@ -11131,7 +11131,7 @@
"summary": "Create execution",
"operationId": "functionsCreateExecution",
"consumes": [
"multipart\/form-data"
"application\/json"
],
"produces": [
"multipart\/form-data"
@@ -11190,65 +11190,59 @@
"in": "path"
},
{
"name": "body",
"description": "HTTP body of execution. Default value is empty string.",
"required": false,
"type": "payload",
"default": "",
"in": "formData"
},
{
"name": "async",
"description": "Execute code in the background. Default value is false.",
"required": false,
"type": "boolean",
"x-example": false,
"default": false,
"in": "formData"
},
{
"name": "path",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"required": false,
"type": "string",
"x-example": "<PATH>",
"default": "\/",
"in": "formData"
},
{
"name": "method",
"description": "HTTP method of execution. Default value is GET.",
"required": false,
"type": "string",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": [],
"default": "POST",
"in": "formData"
},
{
"name": "headers",
"description": "HTTP headers of execution. Defaults to empty.",
"required": false,
"type": "object",
"default": [],
"x-example": "{}",
"in": "formData"
},
{
"name": "scheduledAt",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"required": false,
"type": "string",
"in": "formData"
"name": "payload",
"in": "body",
"schema": {
"type": "object",
"properties": {
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"default": "",
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
"description": "Execute code in the background. Default value is false.",
"default": false,
"x-example": false
},
"path": {
"type": "string",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"default": "\/",
"x-example": "<PATH>"
},
"method": {
"type": "string",
"description": "HTTP method of execution. Default value is GET.",
"default": "POST",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": []
},
"headers": {
"type": "object",
"description": "HTTP headers of execution. Defaults to empty.",
"default": [],
"x-example": "{}"
},
"scheduledAt": {
"type": "string",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"default": null,
"x-example": null
}
}
}
}
]
}
+54 -60
View File
@@ -10022,7 +10022,7 @@
"summary": "Create execution",
"operationId": "functionsCreateExecution",
"consumes": [
"multipart\/form-data"
"application\/json"
],
"produces": [
"multipart\/form-data"
@@ -10083,65 +10083,59 @@
"in": "path"
},
{
"name": "body",
"description": "HTTP body of execution. Default value is empty string.",
"required": false,
"type": "payload",
"default": "",
"in": "formData"
},
{
"name": "async",
"description": "Execute code in the background. Default value is false.",
"required": false,
"type": "boolean",
"x-example": false,
"default": false,
"in": "formData"
},
{
"name": "path",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"required": false,
"type": "string",
"x-example": "<PATH>",
"default": "\/",
"in": "formData"
},
{
"name": "method",
"description": "HTTP method of execution. Default value is GET.",
"required": false,
"type": "string",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": [],
"default": "POST",
"in": "formData"
},
{
"name": "headers",
"description": "HTTP headers of execution. Defaults to empty.",
"required": false,
"type": "object",
"default": [],
"x-example": "{}",
"in": "formData"
},
{
"name": "scheduledAt",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"required": false,
"type": "string",
"in": "formData"
"name": "payload",
"in": "body",
"schema": {
"type": "object",
"properties": {
"body": {
"type": "string",
"description": "HTTP body of execution. Default value is empty string.",
"default": "",
"x-example": "<BODY>"
},
"async": {
"type": "boolean",
"description": "Execute code in the background. Default value is false.",
"default": false,
"x-example": false
},
"path": {
"type": "string",
"description": "HTTP path of execution. Path can include query params. Default value is \/",
"default": "\/",
"x-example": "<PATH>"
},
"method": {
"type": "string",
"description": "HTTP method of execution. Default value is GET.",
"default": "POST",
"x-example": "GET",
"enum": [
"GET",
"POST",
"PUT",
"PATCH",
"DELETE",
"OPTIONS"
],
"x-enum-name": "ExecutionMethod",
"x-enum-keys": []
},
"headers": {
"type": "object",
"description": "HTTP headers of execution. Defaults to empty.",
"default": [],
"x-example": "{}"
},
"scheduledAt": {
"type": "string",
"description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.",
"default": null,
"x-example": null
}
}
}
}
]
}
+1 -1
View File
@@ -1717,7 +1717,7 @@ App::post('/v1/functions/:functionId/executions')
->label('sdk.response.model', Response::MODEL_EXECUTION)
->label('sdk.request.type', Response::CONTENT_TYPE_JSON)
->param('functionId', '', new UID(), 'Function ID.')
->param('body', '', new Payload(10485760, 0), 'HTTP body of execution. Default value is empty string.', true)
->param('body', '', new Text(10485760, 0), 'HTTP body of execution. Default value is empty string.', true)
->param('async', false, new Boolean(), 'Execute code in the background. Default value is false.', true)
->param('path', '/', new Text(2048), 'HTTP path of execution. Path can include query params. Default value is /', true)
->param('method', 'POST', new Whitelist(['GET', 'POST', 'PUT', 'PATCH', 'DELETE', 'OPTIONS'], true), 'HTTP method of execution. Default value is GET.', true)