Skip to the page

Build a service from its branch head or a commit

POST/v1/organisations/{id}/environments/{envId}/resources/{rid}/builds

Operation services.build · since 2026-11-05 · stable

Needs a session withwritescopeAnswers201 Created

The build. When it succeeds it is deployed.

Path parameters

idstring (uuid)required
The organisation id.
envIdstring (uuid)required
The environment id.
ridstringrequired
The service's id.

Body (JSON)

Fields not listed here are refused.

commitstring, 40 hex charactersoptional
The full commit to build (default the branch head).

Errors

Every error is { "error", "message", "detail"? } (Errors and references). Besides the codes any route can answer.

POST/v1/organisations/{id}/environments/{envId}/resources/{rid}/builds
curl -X POST "https://api.rykloud.com/v1/organisations/$ORG_ID/environments/$ENV_ID/resources/$RESOURCE_ID/builds" \
  -H "Authorization: Bearer $RYKLOUD_TOKEN"
With the rykloud CLI
rykloud services deploy SERVICE [flags]

Command reference: rykloud services deploy