Skip to content

Create a resource revision

POST
/api/v1/resources/{id}/revisions
curl --request POST \
--url 'https://example.com/api/v1/resources/example/revisions?projectId=00000000-0000-0000-0000-000000000000' \
--header 'Content-Type: application/json' \
--data '{ "setup": { "sh": "example" }, "teardown": { "sh": "example" }, "exports": [ "example" ], "parameters": [ { "name": "example", "description": "example", "required": false, "default": "example", "example": "example" } ], "creator": "example" }'
id
required
string
projectId
required

Project scope. Required on scoped list and root-create operations; requests without a resolvable project are rejected with 400. There is no default project.

string
>= 1 characters
Example
00000000-0000-0000-0000-000000000000

Project scope. Required on scoped list and root-create operations; requests without a resolvable project are rejected with 400. There is no default project.

Media type application/json
object
setup
required
object
sh
string
>= 1 characters
teardown
object
sh
string
>= 1 characters
exports
Array<string>
parameters
Array<object>
object
name
required
string
/^[A-Za-z_][A-Za-z0-9_]*$/
description
string
required
boolean
default
string
example
string
creator
string

Success

Resource not found

Resource revision ref already exists in this project