{
 "openapi": "3.1.0",
 "info": {
  "title": "Steps (Agentic AI)",
  "version": "20261030b",
  "description": "Every node execution across every run. The trace on a run is the way to read these; this is for searching across runs."
 },
 "servers": [
  {
   "url": "https://{tenant}.tranxact.ai",
   "variables": {
    "tenant": {
     "default": "demo"
    }
   }
  }
 ],
 "components": {
  "securitySchemes": {
   "bearer": {
    "type": "http",
    "scheme": "bearer"
   }
  },
  "schemas": {
   "run-steps": {
    "type": "object",
    "required": [],
    "properties": {
     "id": {
      "type": "string",
      "format": "uuid",
      "description": "Id",
      "readOnly": true
     },
     "org_id": {
      "type": "string",
      "format": "uuid",
      "description": "Org id",
      "readOnly": true
     },
     "org_unit_id": {
      "type": "string",
      "format": "uuid",
      "description": "Org unit id",
      "readOnly": true
     },
     "run_id": {
      "type": "string",
      "format": "uuid",
      "description": "Run id",
      "readOnly": true
     },
     "step_no": {
      "type": "integer",
      "description": "Step no",
      "readOnly": true
     },
     "node_key": {
      "type": "string",
      "description": "Node key",
      "readOnly": true
     },
     "node_kind": {
      "type": "string",
      "description": "Node kind",
      "readOnly": true
     },
     "label": {
      "type": "string",
      "description": "Label",
      "readOnly": true
     },
     "agent_id": {
      "type": "string",
      "format": "uuid",
      "description": "Agent id",
      "readOnly": true
     },
     "tool_id": {
      "type": "string",
      "format": "uuid",
      "description": "Tool id",
      "readOnly": true
     },
     "reasoning": {
      "type": "string",
      "description": "Reasoning",
      "readOnly": true
     },
     "input": {
      "type": "object",
      "description": "Input",
      "readOnly": true
     },
     "output": {
      "type": "object",
      "description": "Output",
      "readOnly": true
     },
     "status": {
      "type": "string",
      "description": "Status",
      "readOnly": true
     },
     "attempt": {
      "type": "integer",
      "description": "Attempt",
      "readOnly": true
     },
     "input_tokens": {
      "type": "integer",
      "description": "Input tokens",
      "readOnly": true
     },
     "output_tokens": {
      "type": "integer",
      "description": "Output tokens",
      "readOnly": true
     },
     "cost": {
      "type": "string",
      "format": "decimal",
      "description": "Cost",
      "readOnly": true
     },
     "started_at": {
      "type": "string",
      "format": "date-time",
      "description": "Started at",
      "readOnly": true
     },
     "finished_at": {
      "type": "string",
      "format": "date-time",
      "description": "Finished at",
      "readOnly": true
     },
     "duration_ms": {
      "type": "integer",
      "description": "Duration ms",
      "readOnly": true
     },
     "error_message": {
      "type": "string",
      "description": "Error message",
      "readOnly": true
     }
    }
   }
  }
 },
 "security": [
  {
   "bearer": []
  }
 ],
 "paths": {
  "/api/agentic/run-steps": {
   "get": {
    "summary": "list run-steps",
    "operationId": "list_run_steps_0_4",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "post": {
    "summary": "Post steps",
    "operationId": "action_run_steps_1_4",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/agentic/run-steps/{id}": {
   "get": {
    "summary": "get run-steps",
    "operationId": "get_run_steps_0_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "put": {
    "summary": "Put steps",
    "operationId": "action_run_steps_1_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "delete": {
    "summary": "Delete steps",
    "operationId": "action_run_steps_2_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/agentic/run-steps/{id}/copy": {
   "post": {
    "summary": "Copy",
    "operationId": "action_run_steps_0_6",
    "description": "Body keys: overrides, preview, withLines",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  }
 }
}