Get workflow run
Viewing v1— superseded by v2
curl --request GET \ --url https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id \ --header 'Authorization: Bearer <token>'import requests
url = "https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.json())const url = 'https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}package main
import ( "fmt" "net/http" "io")
func main() {
url := "https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close() body, _ := io.ReadAll(res.Body)
fmt.Println(res) fmt.Println(string(body))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [ CURLOPT_URL => "https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", CURLOPT_HTTPHEADER => [ "Authorization: Bearer <token>" ],]);
$response = curl_exec($curl);$err = curl_error($curl);
curl_close($curl);
if ($err) { echo "cURL Error #:" . $err;} else { echo $response;}OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder() .url("https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id") .get() .addHeader("Authorization", "Bearer <token>") .build();
Response response = client.newCall(request).execute();require 'uri'require 'net/http'
url = URI("https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id")
http = Net::HTTP.new(url.host, url.port)http.use_ssl = true
request = Net::HTTP::Get.new(url)request["Authorization"] = 'Bearer <token>'
response = http.request(request)puts response.read_bodyvar client = new RestClient("https://api.app.layer.ai/api/v1/workspaces/:workspace_id/workflows/:workflow_id/runs/:run_id");var request = new RestRequest("", Method.Get);request.AddHeader("Authorization", "Bearer <token>");var response = client.Execute(request);v1 is superseded. v1 was superseded by v2 on 2026-08-26. A sunset date has not been announced yet; v1 will be deprecated as a whole before removal. Migrate with the v2 migration guide.
Get the status and results of a workflow run.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Id of the workspace that owns the resource.
Id of the workspace that owns the resource.
Id of the workflow.
Id of the workflow.
Id of the workflow run.
Id of the workflow run.
Responses
Section titled “Responses”Successful Response
object
Unique identifier for this workflow run.
Current status: pending, running, success, failure, or cancelled.
Suggested polling interval in seconds. Present while PENDING or RUNNING.
Status of each step composing the workflow run.
object
The name of the workflow step
The execution status of the step: pending, running, success, failure, or cancelled.
The error details if any
Machine-readable error code if the step failed.
Estimated Creative Units price. Present when available.
Completion timestamp. Present only on SUCCESS.
Actual Creative Units price charged. Present only on SUCCESS.
Generated assets. Present only on SUCCESS.
object
Unique identifier of the generated object.
Type of generated object: file or asset.
File ID — pass directly as input to forge or workflow runs without re-uploading.
Download URL for the asset.
MIME type, e.g. image/png or video/mp4.
Image preview URL.
Width in pixels.
Height in pixels.
Duration in seconds for video assets.
File size in bytes.
What an engine needs beyond the image to build a resource from a file. Each kind is null when absent.
object
Where a game tile’s sprite sits on its grid, in the sprite’s own pixels from its top-left corner.
object
The outline of one grid cell seen from straight above.
How the cell is turned to the camera: DIAMOND or ALIGNED for a square, POINTY_TOP or FLAT_TOP for a hexagon.
Camera tilt in degrees above the ground plane; 90 is straight down.
Quarter turn of the camera around the tile, in degrees clockwise seen from above: 0, 90, 180, or 270. A hexagon is only drawn facing 0.
Cells the footprint covers across (the base’s right-hand edge) at facing 0.
Cells the footprint covers deep (the base’s left-hand edge) at facing 0.
Wall height in cell sides: 0 is a flat ground tile, 1 a cube on a square.
Width in pixels of one cell’s base outline in the sprite.
Height in pixels of one cell’s base outline in the sprite.
The point the tile is placed by: the bottom centre of the cell it stands on (the front cell of a footprint wider than one).
object
Pixels right of the sprite’s left edge.
Pixels down from the sprite’s top edge.
The centre of the anchor’s cell. Godot and Unity pin a tile here rather than at the anchor.
object
Pixels right of the sprite’s left edge.
Pixels down from the sprite’s top edge.
The footprint’s whole base outline, clockwise on screen from the anchor’s vertex or edge.
object
Pixels right of the sprite’s left edge.
Pixels down from the sprite’s top edge.
What the tile shows. Every facing of one subject shares it, so a tileset can group them.
The insets a 9-slice draws a UI element by, in the image’s own pixels in from each edge.
The corners are drawn at their own size, the edges stretch along their length, and the centre stretches both ways.
object
Pixels in from the left edge.
Pixels in from the top edge.
Pixels in from the right edge.
Pixels in from the bottom edge.
DETECTED when measured off the pixels, USER when a person set the insets.
The frame grid a sprite sheet was packed on, in the sheet’s own pixels from its top-left corner.
Cells start margin pixels in from the sheet’s edges with spacing pixels between them.
object
Cells across.
Cells down.
Width of one cell in pixels.
Height of one cell in pixels.
Pixels between the sheet’s edges and the outer cells.
Pixels between neighbouring cells.
The frames, in play order: left to right, then top to bottom, unless the list orders them otherwise.
One frame’s rect on the sheet, in the sheet’s own pixels from its top-left corner.
object
The frame’s cell in reading order over the whole grid (left to right, then top to bottom). Cells that hold no frame are left out, so indexes can skip.
The frame’s left edge on the sheet, in pixels.
The frame’s top edge on the sheet, in pixels.
The frame’s width in pixels.
The frame’s height in pixels.
object
Pixels right of the sprite’s left edge.
Pixels down from the sprite’s top edge.
Named animations over the frames. When empty, play the sheet as one animation named default over every frame in frames order, at 12 fps, looping.
object
The animation’s name.
Frame indexes (frames[].index), in play order.
Frames per second.
Whether the animation restarts after its last frame.
Error message. Present only on FAILURE.
Machine-readable error code. Present only on FAILURE. Balance-related values: BlueprintInsufficientBalanceError (the workspace ran out of Creative Units — top up and resubmit), BlueprintBalanceUnavailableError (the balance could not be verified, retry later) and BlueprintUsageLimitExceededError (the member who started the run is past their usage limit: ask a workspace admin for more, or wait for it to reset).
What a job’s GET reports about the callback attached to it.
The URL is echoed so a caller can tell which of its endpoints a run was aimed at; the rest is how the delivery went, which is the only place a failed delivery is visible.
object
The callback URL this run was submitted with.
Pending until a delivery settles, then delivered or failed.
How many delivery attempts have been made.
When the last attempt was made.
HTTP status the receiver returned on the last attempt, if it responded.
Why the last attempt did not succeed. Null once delivered.
Example
{ "status": "pending", "steps": [], "outputs": [ { "object_type": "directory", "metadata": { "tile": { "shape": "SQUARE", "orientation": "DIAMOND" }, "nine_slice": { "source": "DETECTED" } } } ], "webhook": { "status": "pending" }}Unauthenticated — missing or invalid Bearer token.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Forbidden — insufficient permissions, or the access token lacks the scope the operation requires.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Resource not found.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}The outcome of the request with this Idempotency-Key is not known yet: it is still running, or it failed without a stored response. Retry after the number of seconds in Retry-After.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Invalid input parameters, or an Idempotency-Key reused for a different request.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Rate limited — retry after the number of seconds in Retry-After.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}Internal server error.
object
Example
{ "type": "https://api.layer.ai/errors/ERROR_CODE", "title": "Error Title", "status": 400, "detail": "Human-readable description."}