---
title: "Get current workflow code"
method: GET
path: "/workflows/{workflow_id}/code"
tags: ["Workflows"]
---

# Get current workflow code

`GET /workflows/{workflow_id}/code`

Returns the source code of the workflow's current revision, scoped to the caller's org.

## Path parameters

- `workflow_id` string, uuid, required — workflow identifier

## Response `200`

OK

- WorkflowGetCodeResponse — Returned from GET /workflows/:id/code.
  - `revision` integer, required — Current revision number, or 0 when no revisions exist.
  - `revision_id` string, nullable, required — Current revision's id, or null when no revisions exist.
  - `source` string, required — Current revision's Python source.
  - `updated_at` string, date-time, required — Created_at of the current revision, or the workflow's update_date when no revisions exist.

## Other responses

- `default` — Error

---

[API](https://skmtc.dev/axilioai/apis/axilio-api-2.md) · [All operations](https://skmtc.dev/axilioai/apis/axilio-api-2/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/axilioai/axilio-api-2/revisions/261c340a3f6d/schema)
