---
title: "Add Workflow Edge"
method: POST
path: "/v1/agents/{agent_id}/workflow/edges"
tags: ["Agent Workflow"]
---

# Add Workflow Edge

`POST /v1/agents/{agent_id}/workflow/edges`

Add a directed edge between two existing nodes. Returns ``{edge_id}``.

## Path parameters

- `agent_id` string, required

## Headers

- `X-API-Key` string, required

## Request body

- EdgeCreate — Universal edge-creation spec. ``condition`` is the human-readable transition trigger.
  - `source_node_id` string, required
  - `target_node_id` string, required
  - `condition` string, nullable

## Response `200`

Successful Response

- object

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/getbluejay/apis/bluejay-api.md) · [All operations](https://skmtc.net/getbluejay/apis/bluejay-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/getbluejay/bluejay-api/versions/f48cef80963f/schema)
