---
search:
  tags:
    - pipeline
    - POST
seo:
  description: >-
    Create stage config. Reference for the POST
    /workspaces/{organizationId}/stage-configs endpoint in the Pile API.
sidebar:
  label: Create stage config
  badge: POST
title: Create stage config
type: openapi-operation
---
`POST /workspaces/{organizationId}/stage-configs`

**Request body** (`application/json`)

- `entityType` (string)
- `status` (string, required)
- `ownerAgent` (string | null)
- `instructions` (string | null)
- `advancePolicy` (string)
- `enabled` (boolean)

Request body example:

```json
{
  "entityType": "issue",
  "status": "string",
  "ownerAgent": "string",
  "instructions": "string",
  "advancePolicy": "none",
  "enabled": true
}
```

**Responses**

- `200` — Stage config upserted (keyed on entityType + status)

Response example, 200:

```json
{
  "id": "string",
  "organizationId": "string",
  "entityType": "issue",
  "status": "string",
  "ownerAgent": "string",
  "instructions": "string",
  "advancePolicy": "none",
  "enabled": 0,
  "createdBy": "string",
  "createdAt": "string",
  "updatedAt": "string"
}
```
