Rensei docs

The effective stage set of a project or one of its workflows, with provenance and the rows at that scope.

The effective stage set of a project or one of its workflows, with provenance and the rows at that scope. - Rensei REST API operation reference.

GET
/api/projects/{projectId}/stages

Authorization

headerAuthorizationBearer <WorkOS user access token>

WorkOS user access token created by the Rensei CLI. The authenticated organization is resolved from membership and may be narrowed with X-Rensei-Org.

Path Parameters

projectId*string

The project id.

Query Parameters

workflowId?string

Read (or write) the workflow scope of this workflow.

Length1 <= length

Response Body

The effective stages, any rows the chain ignores, and the live rows written at the requested (project or workflow) scope.

application/json
  1. response
stages*array<>
warnings*array<>
scopeRows*array<>

The live rows written at the requested scope (org, project or workflow), by key; inherited stages with no row here are absent.

Example Request
curl -X GET 'https://app.rensei.ai/api/projects/string/stages'
Example Response
{  "stages": [    {      "key": "string",      "role": "hold",      "name": "string",      "description": "string",      "disabled": true,      "modelSelection": {        "mode": "inherit",        "effort": "low"      },      "outcomes": {        "start": {          "target": "string"        },        "success": {          "target": "stay"        },        "failure": {          "target": "stay"        },        "blocked": {          "target": "stay"        },        "close": {          "target": "stay"        }      },      "retry": {        "retries": 0,        "backoffSeconds": 0      },      "policies": {        "version": 1      },      "cards": [        {          "agentCardId": "string",          "isDefault": true,          "mentionKeywords": [            "string"          ],          "modelSelection": {            "mode": "inherit",            "effort": "low"          },          "skills": [            {              "skillId": "97d3165d-e1dd-4955-972c-95ebf04dd091",              "version": "string"            }          ],          "repoSkillPolicy": {            "policy": "all",            "allow": [              "string"            ]          },          "position": -9007199254740991,          "condition": {            "hasChildren": true          },          "provenance": {            "row": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "mentionKeywords": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "skills": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "repoSkillPolicy": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "position": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "modelSelection": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "effort": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            },            "condition": {              "scope": "system",              "rowId": "string",              "cardRowId": "string"            }          }        }      ],      "defaultCardId": "string",      "provenance": {        "define": {          "scope": "system",          "rowId": "string"        },        "name": {          "scope": "system",          "rowId": "string"        },        "description": {          "scope": "system",          "rowId": "string"        },        "disabled": {          "scope": "system",          "rowId": "string"        },        "modelSelection": {          "scope": "system",          "rowId": "string"        },        "effort": {          "scope": "system",          "rowId": "string"        },        "outcomes": {          "property1": {            "scope": "system",            "rowId": "string"          },          "property2": {            "scope": "system",            "rowId": "string"          }        },        "retry": {          "scope": "system",          "rowId": "string"        },        "policies": {          "scope": "system",          "rowId": "string"        },        "defaultCard": {          "scope": "system",          "rowId": "string"        }      }    }  ],  "warnings": [    {      "code": "invalid_row",      "rowId": "string",      "key": "string",      "scope": "system",      "field": "string",      "cardId": "string",      "definedAt": {        "scope": "system",        "rowId": "string"      }    }  ],  "scopeRows": [    {      "stage": {        "id": "string",        "scope": "system",        "scopeId": "string",        "key": "string",        "kind": "define",        "role": "hold",        "name": "string",        "description": "string",        "disabled": true,        "modelSelection": {          "mode": "inherit",          "effort": "low"        },        "outcomes": {          "start": {            "target": "string"          },          "success": {            "target": "stay"          },          "failure": {            "target": "stay"          },          "blocked": {            "target": "stay"          },          "close": {            "target": "stay"          }        },        "retry": {          "retries": 0,          "backoffSeconds": 0        },        "policies": {          "version": 1        },        "createdAt": "string",        "updatedAt": "string"      },      "cards": [        {          "id": "string",          "agentCardId": "string",          "isDefault": true,          "excluded": true,          "mentionKeywords": [            "string"          ],          "modelSelection": {            "mode": "inherit",            "effort": "low"          },          "skills": [            {              "skillId": "97d3165d-e1dd-4955-972c-95ebf04dd091",              "version": "string"            }          ],          "repoSkillPolicy": {            "policy": "all",            "allow": [              "string"            ]          },          "position": -9007199254740991,          "condition": {            "hasChildren": true          }        }      ]    }  ]}