Skip to main content

Runtimes

Runtime images (the OS/application payload devices run) and their artifact uploads.

Endpoints

MethodPathDescription
GET/api/orgs/{org_id}/projects/{project_id}/runtimesList runtimes
POST/api/orgs/{org_id}/projects/{project_id}/runtimesCreate a runtime
GET/api/orgs/{org_id}/projects/{project_id}/runtimes/cohort-summaryRuntime cohort summary
GET/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}Get a runtime
PUT/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}Update a runtime
DELETE/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}Delete a runtime
POST/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/completeComplete a runtime artifact upload
GET/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/artifacts/{image_id}/upload-urlsGet artifact upload URLs

List runtimes

GET /api/orgs/{org_id}/projects/{project_id}/runtimes

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.

Query parameters:

NameTypeRequiredDescription
searchstringNo
statusstringNo
cursorstringNoOpaque pagination cursor from a prior response's meta.after/meta.before.
limitintegerNoMax items per page (clamped 1–100). Defaults to 20. Range 1–100.
directionstringNoPage direction relative to the cursor. One of: after, before. Defaults to "after".

Responses:

StatusBodyDescription
200data: array of RuntimeSummary, meta: PaginationMetaRuntimes (summary shape).

Example request:

curl "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes" \
-H "Authorization: Bearer $AVOCADO_TOKEN"

Example response (200):

{
"data": [
{
"id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"version": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"display_version": "string",
"description": "string",
"manifest": {},
"manifest_written_at": "2026-08-14T12:00:00Z",
"status": "string",
"project_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"created_by_user_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"content_key_hex": "string",
"content_keyid": "string",
"inserted_at": "2026-08-14T12:00:00Z",
"updated_at": "2026-08-14T12:00:00Z"
}
],
"meta": {
"after": "string",
"before": "string",
"has_next": true,
"has_previous": true,
"total": 0
}
}

Create a runtime

POST /api/orgs/{org_id}/projects/{project_id}/runtimes

Admin only. Returns the runtime plus presigned artifact upload URLs.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.

Request body:

FieldTypeRequiredDescription
runtimeobjectYes
runtime.versionstringYes1–100 characters.
runtime.descriptionstringNoMax 2000 characters.
runtime.build_idstringNoMax 64 characters.
runtime.configobjectNo
runtime.manifestobjectNo
runtime.lockfileobjectNo
runtime.content_key_hexstringNo
runtime.content_keyidstringNo

Responses:

StatusBodyDescription
201data: RuntimeCreated.
422ValidationErrorRequest body failed validation.

Example request:

curl -X POST "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes" \
-H "Authorization: Bearer $AVOCADO_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"runtime": {
"version": "string",
"description": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"config": {},
"manifest": {},
"lockfile": {},
"content_key_hex": "string",
"content_keyid": "string"
}
}'

Example response (201):

{
"data": {
"id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"version": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"display_version": "string",
"description": "string",
"manifest": {},
"manifest_written_at": "2026-08-14T12:00:00Z",
"status": "string",
"project_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"created_by_user_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"content_key_hex": "string",
"content_keyid": "string",
"inserted_at": "2026-08-14T12:00:00Z",
"updated_at": "2026-08-14T12:00:00Z",
"config": {},
"lockfile": {},
"artifacts": [
{
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"upload_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"upload_url": "string"
}
]
}
]
}
}

Runtime cohort summary

GET /api/orgs/{org_id}/projects/{project_id}/runtimes/cohort-summary

Returns per-cohort device counts for the given runtimes, used to preview deployment impact.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.

Query parameters:

NameTypeRequiredDescription
runtime_idsstringNoComma-separated runtime UUIDs.

Responses:

StatusBodyDescription
200data: objectCohort summary.

Example request:

curl "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/cohort-summary" \
-H "Authorization: Bearer $AVOCADO_TOKEN"

Example response (200):

{
"data": {}
}

Get a runtime

GET /api/orgs/{org_id}/projects/{project_id}/runtimes/{id}

Returns runtime detail including config and lockfile.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.
idstring

Responses:

StatusBodyDescription
200data: RuntimeRuntime.
404ErrorResource not found.

Example request:

curl "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}" \
-H "Authorization: Bearer $AVOCADO_TOKEN"

Example response (200):

{
"data": {
"id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"version": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"display_version": "string",
"description": "string",
"manifest": {},
"manifest_written_at": "2026-08-14T12:00:00Z",
"status": "string",
"project_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"created_by_user_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"content_key_hex": "string",
"content_keyid": "string",
"inserted_at": "2026-08-14T12:00:00Z",
"updated_at": "2026-08-14T12:00:00Z",
"config": {},
"lockfile": {},
"artifacts": [
{
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"upload_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"upload_url": "string"
}
]
}
]
}
}

Update a runtime

PUT /api/orgs/{org_id}/projects/{project_id}/runtimes/{id}

Admin only.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.
idstring

Request body:

FieldTypeRequiredDescription
runtimeobjectYes
runtime.descriptionstringNoMax 2000 characters.
runtime.build_idstringNoMax 64 characters.
runtime.configobjectNo
runtime.manifestobjectNo
runtime.lockfileobjectNo
runtime.content_key_hexstringNo
runtime.content_keyidstringNo

Responses:

StatusBodyDescription
200data: RuntimeUpdated.
404ErrorResource not found.
422ValidationErrorRequest body failed validation.

Example request:

curl -X PUT "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}" \
-H "Authorization: Bearer $AVOCADO_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"runtime": {
"description": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"config": {},
"manifest": {},
"lockfile": {},
"content_key_hex": "string",
"content_keyid": "string"
}
}'

Example response (200):

{
"data": {
"id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"version": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"display_version": "string",
"description": "string",
"manifest": {},
"manifest_written_at": "2026-08-14T12:00:00Z",
"status": "string",
"project_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"created_by_user_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"content_key_hex": "string",
"content_keyid": "string",
"inserted_at": "2026-08-14T12:00:00Z",
"updated_at": "2026-08-14T12:00:00Z",
"config": {},
"lockfile": {},
"artifacts": [
{
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"upload_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"upload_url": "string"
}
]
}
]
}
}

Delete a runtime

DELETE /api/orgs/{org_id}/projects/{project_id}/runtimes/{id}

Admin only.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.
idstring

Responses:

StatusBodyDescription
200OkDeleted.
404ErrorResource not found.

Example request:

curl -X DELETE "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}" \
-H "Authorization: Bearer $AVOCADO_TOKEN"

Example response (200):

{
"ok": true
}

Complete a runtime artifact upload

POST /api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/complete

Finalizes a multipart artifact upload by submitting the per-part ETags/checksums returned by S3.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.
idstring

Request body:

FieldTypeRequiredDescription
partsobject[]Yes
parts[].image_idstringYes
parts[].partsobject[]Yes
parts[].parts[].part_numberintegerYes
parts[].parts[].etagstringYes
parts[].parts[].checksum_sha256stringNo

Responses:

StatusBodyDescription
200data: RuntimeCompleted.
422ValidationErrorRequest body failed validation.

Example request:

curl -X POST "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/complete" \
-H "Authorization: Bearer $AVOCADO_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"parts": [
{
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"etag": "string",
"checksum_sha256": "string"
}
]
}
]
}'

Example response (200):

{
"data": {
"id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"version": "string",
"build_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"display_version": "string",
"description": "string",
"manifest": {},
"manifest_written_at": "2026-08-14T12:00:00Z",
"status": "string",
"project_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"created_by_user_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"content_key_hex": "string",
"content_keyid": "string",
"inserted_at": "2026-08-14T12:00:00Z",
"updated_at": "2026-08-14T12:00:00Z",
"config": {},
"lockfile": {},
"artifacts": [
{
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"upload_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"upload_url": "string"
}
]
}
]
}
}

Get artifact upload URLs

GET /api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/artifacts/{image_id}/upload-urls

Returns presigned multipart upload URLs for an artifact image.

Path parameters:

NameTypeDescription
org_idstring (uuid)Organization UUID.
project_idstring (uuid)Project UUID.
idstring
image_idstring

Responses:

StatusBodyDescription
200data: objectUpload URLs.
404ErrorResource not found.

Example request:

curl "https://connect.peridio.com/api/orgs/{org_id}/projects/{project_id}/runtimes/{id}/artifacts/{image_id}/upload-urls" \
-H "Authorization: Bearer $AVOCADO_TOKEN"

Example response (200):

{
"data": {
"image_id": "0198a2e6-6f24-7cc3-b456-663cd21c4b12",
"parts": [
{
"part_number": 0,
"upload_url": "string"
}
]
}
}

Object reference

RuntimeSummary

Runtime as returned by list endpoints (omits config and lockfile, which can be large).

FieldTypeDescription
idstring
versionstring
build_idstringNullable.
display_versionstring
descriptionstringNullable.
manifestobjectNullable.
manifest_written_atstring (date-time)Nullable.
statusstring
project_idstring
created_by_user_idstringNullable.
content_key_hexstringNullable.
content_keyidstringNullable.
inserted_atstring (date-time)
updated_atstring (date-time)

PaginationMeta

Cursor pagination metadata. Present only when the request supplied a pagination param (cursor, limit, or direction); otherwise the full list is returned unpaginated with no meta.

FieldTypeDescription
afterstringOpaque cursor for the next page. Pass back as ?cursor=. Nullable.
beforestringOpaque cursor for the previous page. Nullable.
has_nextboolean
has_previousboolean
totalintegerNullable.

Runtime

Runtime detail (adds config and lockfile; artifacts present on create/complete).

FieldTypeDescription
idstring
versionstring
build_idstringNullable.
display_versionstring
descriptionstringNullable.
manifestobjectNullable.
manifest_written_atstring (date-time)Nullable.
statusstring
project_idstring
created_by_user_idstringNullable.
content_key_hexstringNullable.
content_keyidstringNullable.
inserted_atstring (date-time)
updated_atstring (date-time)
configobjectNullable.
lockfileobjectNullable.
artifactsarray of UploadSpec

UploadSpec

Presigned multipart upload URLs for a runtime artifact image.

FieldTypeDescription
image_idstring
upload_idstring
partsobject[]
parts[].part_numberinteger
parts[].upload_urlstring

ValidationError

Changeset validation error. Keys are field names; values are lists of messages.

FieldTypeDescription
errorsobject

Error

Standard error envelope.

FieldTypeDescription
errorstringMachine-readable error code.
messagestringHuman-readable explanation.

Ok

Simple acknowledgement.

FieldTypeDescription
okboolean