{"openapi":"3.1.0","info":{"version":"1.13.0","title":"Logic API | Neobits","contact":{"email":"hello@neobits.no","url":"https://neobits.ai"},"description":"# Logic\n\nOpenAPI document for this API: https://docs.neobits.ai/openapi/logic.json\n\nLogic runs your decision models against JSON input. Use its API to evaluate a version, manage environments and deployments, and execute a deployed decision from your application.\n\n## Core concepts\n\n-   **Decision:** a model that transforms input facts into a result. Author it in the Logic app.\n-   **Version:** a saved snapshot, shown as v1, v2, and so on. API requests use the numeric version. Version 0 is the editable working copy; use a saved version for reproducible runs.\n-   **Environment:** a workspace resource such as Test or Production. These names are yours to choose and are separate from the Neobits test and production API hosts.\n-   **Deployment:** connects a decision version to an environment. Creating one through REST also creates immediate 100% traffic routing.\n-   **Evaluation:** runs the requested version without deployment routing and returns its result and available trace.\n-   **Execution:** runs the version selected by an environment's deployment routing and records the outcome.\n\n## Authentication and workspace access\n\nObtain an access token through [Core authentication](https://docs.neobits.ai/api-reference/operation/createToken/method/post.md). Configure your API client for Logic and grant the scopes needed for its operations. Send `Authorization: Bearer <access_token>` and `X-Workspace-Id` on every request. The token must be valid for the target API and tenant, and its principal must have access to the workspace. End-user tokens are authorized through workspace policies.\n\n| Operation | Service-token scope |\n| --- | --- |\n| List environments / get environment | `environments:read` / `environment:read` |\n| Create / update / delete environment | `environment:write` / `environment:update` / `environment:delete` |\n| List deployments / get deployment | `deployments:read` / `deployment:read` |\n| Create / update / delete deployment | `deployment:write` / `deployment:update` / `deployment:delete` |\n| Execute / evaluate | `execution:write` / `evaluation:write` |\n\nTokens live for at most the client's `max_session_duration` (8 hours by default); see [access tokens](https://docs.neobits.ai/api-reference/tag/core-authz.md#access-tokens) for lifetime and scope rules.\n\nThe test API base URL is `https://api.test.neobits.ai`; production uses `https://api.prod.neobits.ai`. Logic paths start with `/logic`. JSON field names are camelCase.\n\nA missing or malformed workspace header returns 400. Authentication failures return 401; insufficient access returns 403. Environment and deployment reads are limited to the active workspace.\n\n## Evaluate, deploy, and execute\n\nStart with a standalone decision and a saved version in the Logic app. Copy its decision ID from the decision details and use the numeric saved version from its version history. Use your active workspace ID for `WORKSPACE_ID`. The following example assumes a decision that accepts an `age` fact and returns an `eligible` result; use the input required by your own decision.\n\n```bash\nAPI_URL='https://api.test.neobits.ai'\nACCESS_TOKEN='<your-access-token>'\nWORKSPACE_ID='<your-workspace-uuid>'\nDECISION_ID='<your-decision-uuid>'\nVERSION=1\n```\n\n### 1\\. Create an environment\n\nOnly the name is required. Omitting the color selects a random supported theme color. Copy the returned `id` into `ENVIRONMENT_ID`.\n\n```bash\ncurl --request POST \"$API_URL/logic/v1/environments\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data '{\"name\":\"Test\",\"description\":\"Integration testing\",\"color\":\"#2563eb\"}'\n```\n\nExample 201 response:\n\n```json\n{\n  \"id\": \"019991b1-0000-7000-8000-000000000002\",\n  \"workspaceId\": \"019991b1-0000-7000-8000-000000000001\",\n  \"name\": \"Test\",\n  \"description\": \"Integration testing\",\n  \"color\": \"#2563eb\",\n  \"createdAt\": \"2026-09-30T10:00:00.000Z\",\n  \"updatedAt\": \"2026-09-30T10:00:00.000Z\"\n}\n```\n\n```bash\nENVIRONMENT_ID='<id-from-the-create-environment-response>'\n```\n\n### 2\\. Evaluate the saved version\n\nEvaluation requires no deployment. The REST endpoint has no environment parameter, so it does not resolve environment configuration variables. Evaluations run the decision's logic and can call external integrations; they are not side-effect-free dry runs.\n\n```bash\ncurl --request POST \"$API_URL/logic/v1/decisions/$DECISION_ID/evaluations\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data \"{\\\"version\\\":$VERSION,\\\"fact\\\":{\\\"age\\\":25}}\"\n```\n\nThe 201 response includes `id`, `status`, `result`, `performance`, and `trace`. A successful result might be `{\"eligible\":true}`. Trace entries depend on the model's nodes; configuration secrets are redacted.\n\n### 3\\. Deploy the version\n\nCreating a deployment immediately directs 100% of traffic for this decision/environment pair to the selected version. Supply the caller attribution in `deployedBy`; it is not inferred from the token. Copy the returned `id` into `DEPLOYMENT_ID`.\n\n```bash\ncurl --request POST \"$API_URL/logic/v1/deployments\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data \"{\\\"decisionId\\\":\\\"$DECISION_ID\\\",\\\"version\\\":$VERSION,\\\"environmentId\\\":\\\"$ENVIRONMENT_ID\\\",\\\"name\\\":\\\"Eligibility v1\\\",\\\"message\\\":\\\"Initial deployment\\\",\\\"deployedBy\\\":\\\"Integration service\\\"}\"\n```\n\nBoth the environment and decision snapshot must exist in the active workspace. Deploy sub-decisions through their parent. A deployment version of `null` or `0` selects the working copy; the response normalizes `null` to `0`. The REST API does not accept rollout percentages or scheduling settings.\n\n```bash\nDEPLOYMENT_ID='<id-from-the-create-deployment-response>'\n```\n\n### 4\\. Execute the deployed decision\n\nExecution resolves configuration variables for the environment and follows its deployment routing.\n\n```bash\ncurl --request POST \"$API_URL/logic/v1/$ENVIRONMENT_ID/decisions/$DECISION_ID/executions\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data '{\"fact\":{\"age\":25}}'\n```\n\nExample 201 response:\n\n```json\n{\n  \"id\": \"019991b1-0000-7000-8000-000000000005\",\n  \"decisionId\": \"019991b1-0000-7000-8000-000000000003\",\n  \"status\": \"COMPLETED\",\n  \"result\": {\"eligible\": true},\n  \"performance\": \"1.2ms\",\n  \"createdAt\": \"2026-09-30T10:00:00.000Z\",\n  \"updatedAt\": \"2026-09-30T10:00:00.000Z\"\n}\n```\n\n## List and paginate resources\n\nEnvironment and deployment lists accept `size` (default 50, maximum 5,000) and either `before` or `after`. Results are ordered by ascending ID. The cursors are exclusive; use `page.after` for the next page and `page.before` for the preceding page. Responses use `{ data, page }`, with `page.size` equal to the returned count and `page.total` equal to the workspace total.\n\n```bash\ncurl \"$API_URL/logic/v1/deployments?size=50\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\"\n\nAFTER='<page.after-from-the-previous-response>'\ncurl \"$API_URL/logic/v1/deployments?size=50&after=$AFTER\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\"\n```\n\nA non-null cursor does not guarantee another page exists. An empty page contains `data: []`, `size: 0`, and null cursors, while `total` still reports the workspace total. These lists do not accept decision/environment filters or custom sorting. Use `GET /logic/v1/environments/{id}` or `GET /logic/v1/deployments/{id}` to retrieve an individual resource.\n\n## Update and delete resources\n\nPATCH requests require at least one supported field. Omitted fields stay unchanged. Use `null` or an empty string to clear an environment description or a deployment message. Unknown fields are rejected.\n\n```bash\ncurl --request PATCH \"$API_URL/logic/v1/environments/$ENVIRONMENT_ID\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data '{\"description\":\"Shared integration environment\"}'\n\ncurl --request PATCH \"$API_URL/logic/v1/deployments/$DEPLOYMENT_ID\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header 'Content-Type: application/json' \\\n  --data '{\"message\":\"Verified by integration tests\"}'\n```\n\nDeployment PATCH also accepts `decisionId`, `version`, `environmentId`, `name`, and `deployedBy`. It validates the resulting references, but updates only the deployment record; existing routing is not recreated or changed. Create a new deployment when you want to activate another version with immediate full-traffic routing.\n\nDeleting an environment also deletes its deployments and routings. Deleting a deployment removes its routings and can change the version that receives future traffic. Both deletions return **409 Conflict** when linked execution history prevents removal. The deployment executed in this walkthrough therefore cannot be deleted through these calls while that history remains.\n\nFor a disposable resource without execution history:\n\n```bash\ncurl --request DELETE \"$API_URL/logic/v1/deployments/$DEPLOYMENT_ID\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\"\n\ncurl --request DELETE \"$API_URL/logic/v1/environments/$ENVIRONMENT_ID\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\"\n```\n\nSuccessful deletion returns 204 with no body. Repeating the deletion for an absent resource in the active workspace also returns 204.\n\n## Handle HTTP and decision failures\n\nCheck both the HTTP status and the result's `status`. A 201 response can contain `status: \"FAILED\"` and a `result.error` message when a node fails. An execution may include a diagnostic trace for that failure; successful executions normally omit it. Evaluations return their available trace in the `trace` field.\n\nFor example, a failed evaluation can return:\n\n```json\n{\n  \"id\": \"019991b1-0000-7000-8000-000000000006\",\n  \"status\": \"FAILED\",\n  \"result\": {\"error\": \"The external integration failed.\"},\n  \"performance\": \"4.2ms\",\n  \"trace\": null\n}\n```\n\nA retried execution or evaluation runs the decision again, including any external integration calls, unless you send an `Idempotency-Key` header. Choose a unique key of up to 128 characters per request, for example a UUID, and send the same key on every retry:\n\n```bash\ncurl --request POST \"$API_URL/logic/$ENVIRONMENT_ID/decisions/$DECISION_ID/executions\" \\\n  --header \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  --header \"X-Workspace-Id: $WORKSPACE_ID\" \\\n  --header \"Idempotency-Key: $REQUEST_KEY\" \\\n  --header 'Content-Type: application/json' \\\n  --data '{\"fact\":{\"amount\":5}}'\n```\n\n-   A repeated key in the same workspace returns the stored 201 response, including a `FAILED` result, without running the decision again.\n-   Reusing a key for a different decision, environment, version, or `fact` returns **409 Conflict**.\n-   A non-2xx response does not store the key, so a retry with the same key runs the decision.\n-   If a retry arrives while the first request is still running, both can run the decision. Only the first stored result is kept, and both return it.\n\nA hard engine failure can instead produce a non-2xx response. Do not assume every failed evaluation was persisted. Missing deployments, routing, or decision versions can return 404. For HTTP errors, use the shared [error response format](https://docs.neobits.ai/api-reference/errors.md) and the status codes listed on each operation.\n\n## Endpoints\n\n- [List environments](https://docs.neobits.ai/api-reference/operation/logic-environments-list/method/get.md): `GET /logic/v1/environments`\n- [Create an environment](https://docs.neobits.ai/api-reference/operation/logic-environments-create/method/post.md): `POST /logic/v1/environments`\n- [Get an environment](https://docs.neobits.ai/api-reference/operation/logic-environments-get/method/get.md): `GET /logic/v1/environments/{id}`\n- [Update an environment](https://docs.neobits.ai/api-reference/operation/logic-environments-update/method/patch.md): `PATCH /logic/v1/environments/{id}`\n- [Delete an environment](https://docs.neobits.ai/api-reference/operation/logic-environments-delete/method/delete.md): `DELETE /logic/v1/environments/{id}`\n- [List deployments](https://docs.neobits.ai/api-reference/operation/logic-deployments-list/method/get.md): `GET /logic/v1/deployments`\n- [Create a deployment](https://docs.neobits.ai/api-reference/operation/logic-deployments-create/method/post.md): `POST /logic/v1/deployments`\n- [Get a deployment](https://docs.neobits.ai/api-reference/operation/logic-deployments-get/method/get.md): `GET /logic/v1/deployments/{id}`\n- [Update a deployment](https://docs.neobits.ai/api-reference/operation/logic-deployments-update/method/patch.md): `PATCH /logic/v1/deployments/{id}`\n- [Delete a deployment](https://docs.neobits.ai/api-reference/operation/logic-deployments-delete/method/delete.md): `DELETE /logic/v1/deployments/{id}`\n- [Execute a decision](https://docs.neobits.ai/api-reference/operation/logic-executions-create/method/post.md): `POST /logic/v1/{environmentId}/decisions/{decisionId}/executions`\n- [Evaluate a decision](https://docs.neobits.ai/api-reference/operation/logic-evaluations-create/method/post.md): `POST /logic/v1/decisions/{decisionId}/evaluations`"},"servers":[{"url":"https://api.test.neobits.ai"},{"url":"https://api.prod.neobits.ai"}],"tags":[{"name":"Logic"}],"paths":{"/logic/v1/environments":{"get":{"operationId":"logic-environments-list","tags":["Logic"],"summary":"List environments","description":"Returns resources in the active workspace in ascending ID order. Use `size` and either `before` or `after` for pagination. `page.size` is the returned count; `page.total` is the workspace total. Cursors are exclusive and are null for an empty page. There are no additional filters or sort parameters.\n\nRequired service-token scope: `environments:read`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"size","in":"query","required":false,"description":"Maximum resources to return (1–5,000). Defaults to 50.","schema":{"type":"integer","minimum":1,"maximum":5000,"default":50},"example":50},{"name":"before","in":"query","required":false,"description":"Exclusive resource ID cursor. Use page.before from a previous response. Cannot be combined with after.","schema":{"type":"string","format":"uuid"}},{"name":"after","in":"query","required":false,"description":"Exclusive resource ID cursor. Use page.after from a previous response. Cannot be combined with before.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Environment page.","content":{"application/json":{"schema":{"title":"LogicEnvironmentPage","type":"object","required":["data","page"],"properties":{"data":{"type":"array","items":{"title":"LogicEnvironment","type":"object","required":["id","workspaceId","name","description","color","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Environment identifier.","example":"019991b1-0000-7000-8000-000000000002"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000002","workspaceId":"019991b1-0000-7000-8000-000000000001","name":"Test","description":"Integration testing","color":"#2563eb","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}},"page":{"title":"LogicPage","type":"object","required":["size","total","before","after"],"properties":{"size":{"type":"integer","minimum":0,"description":"Number of resources returned in this response.","example":1},"total":{"type":"integer","minimum":0,"description":"Total resources in the active workspace, independent of the cursor.","example":1},"before":{"type":["string","null"],"format":"uuid","description":"First returned ID. Use as before to request the preceding page. Null for an empty page.","example":"019991b1-0000-7000-8000-000000000002"},"after":{"type":["string","null"],"format":"uuid","description":"Last returned ID. Use as after to request the following page. Null for an empty page. A non-null cursor does not guarantee another page exists.","example":"019991b1-0000-7000-8000-000000000002"}}}},"example":{"data":[{"id":"019991b1-0000-7000-8000-000000000002","workspaceId":"019991b1-0000-7000-8000-000000000001","name":"Test","description":"Integration testing","color":"#2563eb","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}],"page":{"size":1,"total":1,"before":"019991b1-0000-7000-8000-000000000002","after":"019991b1-0000-7000-8000-000000000002"}}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"post":{"operationId":"logic-environments-create","tags":["Logic"],"summary":"Create an environment","description":"Creates an environment in the active workspace. Only `name` is required. Omitting `color` selects a random supported theme color. Unknown fields are rejected.\n\nRequired service-token scope: `environment:write`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"CreateLogicEnvironment","type":"object","additionalProperties":false,"required":["name"],"properties":{"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"}},"example":{"name":"Test","description":"Integration testing","color":"#2563eb"}}}}},"responses":{"201":{"description":"Environment created.","content":{"application/json":{"schema":{"title":"LogicEnvironment","type":"object","required":["id","workspaceId","name","description","color","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Environment identifier.","example":"019991b1-0000-7000-8000-000000000002"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000002","workspaceId":"019991b1-0000-7000-8000-000000000001","name":"Test","description":"Integration testing","color":"#2563eb","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}},"/logic/v1/environments/{id}":{"get":{"operationId":"logic-environments-get","tags":["Logic"],"summary":"Get an environment","description":"Retrieves one environment in the active workspace. Returns 404 when it is not found in that workspace.\n\nRequired service-token scope: `environment:read`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Environment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000002"}],"responses":{"200":{"description":"Environment details.","content":{"application/json":{"schema":{"title":"LogicEnvironment","type":"object","required":["id","workspaceId","name","description","color","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Environment identifier.","example":"019991b1-0000-7000-8000-000000000002"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000002","workspaceId":"019991b1-0000-7000-8000-000000000001","name":"Test","description":"Integration testing","color":"#2563eb","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"patch":{"operationId":"logic-environments-update","tags":["Logic"],"summary":"Update an environment","description":"Partially updates an environment in the active workspace. Supply at least one of `name`, `description`, or `color`; omitted fields remain unchanged. Clear the description with null or an empty string. Unknown fields are rejected.\n\nRequired service-token scope: `environment:update`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Environment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000002"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"UpdateLogicEnvironment","type":"object","additionalProperties":false,"minProperties":1,"properties":{"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"}},"example":{"description":"Shared integration environment"}}}}},"responses":{"200":{"description":"Environment updated.","content":{"application/json":{"schema":{"title":"LogicEnvironment","type":"object","required":["id","workspaceId","name","description","color","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Environment identifier.","example":"019991b1-0000-7000-8000-000000000002"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"name":{"type":"string","description":"Nonempty name without leading or trailing whitespace.","example":"Test","minLength":1},"description":{"type":["string","null"],"description":"Description. Use null or an empty string to clear it.","example":"Integration testing"},"color":{"type":"string","description":"A six-digit hex color or one of the supported theme colors. If omitted on creation, a random theme color is persisted.","pattern":"^(#[0-9a-fA-F]{6}|var\\(--color-(blue|purple|pink|yellow|aqua|cyan)-500\\))$","example":"#2563eb"},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000002","workspaceId":"019991b1-0000-7000-8000-000000000001","name":"Test","description":"Integration testing","color":"#2563eb","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"delete":{"operationId":"logic-environments-delete","tags":["Logic"],"summary":"Delete an environment","description":"Deletes the environment and cascades to its deployments and routings. Returns 409 if linked execution history prevents deletion; nothing is deleted in that case. Deletion is idempotent: an absent ID in the active workspace also returns 204 with no response body.\n\nRequired service-token scope: `environment:delete`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Environment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000002"}],"responses":{"204":{"description":"Deleted or already absent. No response body."},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"409":{"description":"Conflict","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ConflictResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Conflict"],"example":"Conflict"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["409-000","409-001","409-002"],"example":"409-000"},"message":{"type":"string","example":"A resource with this identifier already exists"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}},"/logic/v1/deployments":{"get":{"operationId":"logic-deployments-list","tags":["Logic"],"summary":"List deployments","description":"Returns resources in the active workspace in ascending ID order. Use `size` and either `before` or `after` for pagination. `page.size` is the returned count; `page.total` is the workspace total. Cursors are exclusive and are null for an empty page. There are no additional filters or sort parameters.\n\nRequired service-token scope: `deployments:read`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"size","in":"query","required":false,"description":"Maximum resources to return (1–5,000). Defaults to 50.","schema":{"type":"integer","minimum":1,"maximum":5000,"default":50},"example":50},{"name":"before","in":"query","required":false,"description":"Exclusive resource ID cursor. Use page.before from a previous response. Cannot be combined with after.","schema":{"type":"string","format":"uuid"}},{"name":"after","in":"query","required":false,"description":"Exclusive resource ID cursor. Use page.after from a previous response. Cannot be combined with before.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Deployment page.","content":{"application/json":{"schema":{"title":"LogicDeploymentPage","type":"object","required":["data","page"],"properties":{"data":{"type":"array","items":{"title":"LogicDeployment","type":"object","required":["id","workspaceId","decisionId","version","environmentId","name","message","deployedBy","milestone","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Deployment identifier.","example":"019991b1-0000-7000-8000-000000000004"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1},"milestone":{"type":"integer","const":0,"description":"Snapshot milestone; always 0 for a deployment.","example":0},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000004","workspaceId":"019991b1-0000-7000-8000-000000000001","decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"milestone":0,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}},"page":{"title":"LogicPage","type":"object","required":["size","total","before","after"],"properties":{"size":{"type":"integer","minimum":0,"description":"Number of resources returned in this response.","example":1},"total":{"type":"integer","minimum":0,"description":"Total resources in the active workspace, independent of the cursor.","example":1},"before":{"type":["string","null"],"format":"uuid","description":"First returned ID. Use as before to request the preceding page. Null for an empty page.","example":"019991b1-0000-7000-8000-000000000002"},"after":{"type":["string","null"],"format":"uuid","description":"Last returned ID. Use as after to request the following page. Null for an empty page. A non-null cursor does not guarantee another page exists.","example":"019991b1-0000-7000-8000-000000000002"}}}},"example":{"data":[{"id":"019991b1-0000-7000-8000-000000000004","workspaceId":"019991b1-0000-7000-8000-000000000001","decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"milestone":0,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}],"page":{"size":1,"total":1,"before":"019991b1-0000-7000-8000-000000000004","after":"019991b1-0000-7000-8000-000000000004"}}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"post":{"operationId":"logic-deployments-create","tags":["Logic"],"summary":"Create a deployment","description":"Creates a deployment and its routing atomically. It immediately routes 100% of traffic to this version for the decision/environment pair. The environment and decision snapshot must exist in the active workspace; sub-decisions cannot be deployed directly. Supply `deployedBy` explicitly. `version: null` is normalized to 0 (the working copy). Routing percentage and scheduling fields are not accepted.\n\nRequired service-token scope: `deployment:write`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"CreateLogicDeployment","type":"object","additionalProperties":false,"required":["decisionId","version","environmentId","name","deployedBy"],"properties":{"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1}},"example":{"decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service"}}}}},"responses":{"201":{"description":"Deployment created.","content":{"application/json":{"schema":{"title":"LogicDeployment","type":"object","required":["id","workspaceId","decisionId","version","environmentId","name","message","deployedBy","milestone","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Deployment identifier.","example":"019991b1-0000-7000-8000-000000000004"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1},"milestone":{"type":"integer","const":0,"description":"Snapshot milestone; always 0 for a deployment.","example":0},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000004","workspaceId":"019991b1-0000-7000-8000-000000000001","decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"milestone":0,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}},"/logic/v1/deployments/{id}":{"get":{"operationId":"logic-deployments-get","tags":["Logic"],"summary":"Get a deployment","description":"Retrieves one deployment in the active workspace. Returns 404 when it is not found in that workspace.\n\nRequired service-token scope: `deployment:read`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Deployment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000004"}],"responses":{"200":{"description":"Deployment details.","content":{"application/json":{"schema":{"title":"LogicDeployment","type":"object","required":["id","workspaceId","decisionId","version","environmentId","name","message","deployedBy","milestone","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Deployment identifier.","example":"019991b1-0000-7000-8000-000000000004"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1},"milestone":{"type":"integer","const":0,"description":"Snapshot milestone; always 0 for a deployment.","example":0},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000004","workspaceId":"019991b1-0000-7000-8000-000000000001","decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"milestone":0,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"patch":{"operationId":"logic-deployments-update","tags":["Logic"],"summary":"Update a deployment","description":"Partially updates a deployment in the active workspace. Supply at least one of `decisionId`, `version`, `environmentId`, `name`, `message`, or `deployedBy`. Omitted fields remain unchanged; null clears `message` or selects the working copy for `version`. Resulting environment and decision references are validated. This updates the deployment record only; it does not recreate or change its routing. Create a new deployment to activate another version with immediate full-traffic routing.\n\nRequired service-token scope: `deployment:update`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Deployment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000004"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"UpdateLogicDeployment","type":"object","additionalProperties":false,"minProperties":1,"properties":{"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1}},"example":{"message":"Verified by integration tests"}}}}},"responses":{"200":{"description":"Deployment updated.","content":{"application/json":{"schema":{"title":"LogicDeployment","type":"object","required":["id","workspaceId","decisionId","version","environmentId","name","message","deployedBy","milestone","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Deployment identifier.","example":"019991b1-0000-7000-8000-000000000004"},"workspaceId":{"type":"string","format":"uuid","description":"Workspace containing this resource.","example":"019991b1-0000-7000-8000-000000000001"},"decisionId":{"type":"string","format":"uuid","description":"Standalone decision to deploy. Sub-decisions are deployed with their parent.","example":"019991b1-0000-7000-8000-000000000003"},"version":{"type":["integer","null"],"minimum":0,"maximum":2147483647,"description":"Saved version number, or 0/null for the working copy. Null is normalized to 0 in the response. Use a saved version for a reproducible deployment.","example":1},"environmentId":{"type":"string","format":"uuid","description":"Environment in the active workspace.","example":"019991b1-0000-7000-8000-000000000002"},"name":{"type":"string","description":"Nonempty deployment name without leading or trailing whitespace.","example":"Eligibility v1","minLength":1},"message":{"type":["string","null"],"description":"Release notes. Use null or an empty string to clear them.","example":"Initial deployment"},"deployedBy":{"type":"string","description":"Caller-supplied attribution; required and not inferred from the access token.","example":"Integration service","minLength":1},"milestone":{"type":"integer","const":0,"description":"Snapshot milestone; always 0 for a deployment.","example":0},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000004","workspaceId":"019991b1-0000-7000-8000-000000000001","decisionId":"019991b1-0000-7000-8000-000000000003","version":1,"milestone":0,"environmentId":"019991b1-0000-7000-8000-000000000002","name":"Eligibility v1","message":"Initial deployment","deployedBy":"Integration service","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}},"delete":{"operationId":"logic-deployments-delete","tags":["Logic"],"summary":"Delete a deployment","description":"Deletes the deployment and its routings. Returns 409 if linked execution history prevents deletion. Removing a deployment can change which remaining deployment handles future executions, or leave the decision without a deployment in that environment. Deletion is idempotent: an absent ID in the active workspace also returns 204 with no response body.\n\nRequired service-token scope: `deployment:delete`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"id","in":"path","required":true,"description":"Deployment identifier.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000004"}],"responses":{"204":{"description":"Deleted or already absent. No response body."},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"409":{"description":"Conflict","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ConflictResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Conflict"],"example":"Conflict"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["409-000","409-001","409-002"],"example":"409-000"},"message":{"type":"string","example":"A resource with this identifier already exists"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}},"/logic/v1/{environmentId}/decisions/{decisionId}/executions":{"post":{"operationId":"logic-executions-create","tags":["Logic"],"summary":"Execute a decision","description":"Runs the decision using the deployment routing configured for the selected environment. Environment configuration variables are resolved for the run. A deployment and routing must exist; sub-decisions cannot be executed directly. The call is synchronous and persists an execution. Check `status` even on HTTP 201: a node failure can return `FAILED` with `result.error` and a trace. Hard engine failures can instead return a non-2xx error. Successful runs normally omit `trace`. Send an `Idempotency-Key` header to retry safely: a repeated key returns the stored execution without running the decision again.\n\nRequired service-token scope: `execution:write`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"Idempotency-Key","in":"header","required":false,"description":"Client-chosen key, such as a UUID, that makes a retry safe. A repeated key returns the stored 201 response without running the request again. Reusing a key with a different request returns 409. A non-2xx response does not store the key.","schema":{"type":"string","minLength":1,"maxLength":128},"example":"7f9c2ba4-e88f-4f2e-9b1d-1f3c6a0e5d21"},{"name":"environmentId","in":"path","required":true,"description":"Environment containing the deployment.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000002"},{"name":"decisionId","in":"path","required":true,"description":"Standalone decision to execute.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000003"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"CreateLogicExecution","type":"object","required":["fact"],"properties":{"fact":{"type":"object","additionalProperties":true,"description":"Input facts expected by your decision. The example assumes a decision accepting age and returning eligible; replace it with your own input.","example":{"age":25}}},"example":{"fact":{"age":25}}}}}},"responses":{"201":{"description":"Execution recorded; inspect status for COMPLETED or FAILED.","content":{"application/json":{"schema":{"title":"LogicExecution","type":"object","required":["id","decisionId","status","result","createdAt","updatedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Persisted execution identifier.","example":"019991b1-0000-7000-8000-000000000005"},"decisionId":{"type":"string","format":"uuid","description":"Executed decision.","example":"019991b1-0000-7000-8000-000000000003"},"status":{"type":"string","enum":["COMPLETED","FAILED"],"description":"Check this field even when the HTTP status is 201.","example":"COMPLETED"},"result":{"description":"Decision-specific output. When status is FAILED, contains an error property describing the failure.","example":{"eligible":true},"type":"object","additionalProperties":true},"performance":{"type":"string","description":"Engine-reported duration.","example":"1.2ms"},"trace":{"type":"object","additionalProperties":true,"description":"Diagnostic trace for a failed execution, when available. Omitted for successful executions.","example":{}},"createdAt":{"type":"string","format":"date-time","description":"Creation time.","example":"2026-09-30T10:00:00.000Z"},"updatedAt":{"type":"string","format":"date-time","description":"Last update time.","example":"2026-09-30T10:00:00.000Z"}},"example":{"id":"019991b1-0000-7000-8000-000000000005","decisionId":"019991b1-0000-7000-8000-000000000003","status":"COMPLETED","result":{"eligible":true},"performance":"1.2ms","createdAt":"2026-09-30T10:00:00.000Z","updatedAt":"2026-09-30T10:00:00.000Z"}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"409":{"description":"Conflict","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ConflictResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Conflict"],"example":"Conflict"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["409-000","409-001","409-002"],"example":"409-000"},"message":{"type":"string","example":"A resource with this identifier already exists"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}},"/logic/v1/decisions/{decisionId}/evaluations":{"post":{"operationId":"logic-evaluations-create","tags":["Logic"],"summary":"Evaluate a decision","description":"Evaluates the supplied decision version synchronously without deployment routing. Versions 1 and above select saved versions; 0 selects the working copy. The REST request has no environment parameter and does not resolve environment configuration variables. Evaluation runs the decision logic and can call external integrations; it is not a side-effect-free dry run. Check `status` even on HTTP 201: node failures can return `FAILED` with `result.error`. Hard engine failures can instead return a non-2xx error. The response includes the available redacted per-node trace. Send an `Idempotency-Key` header to retry safely: a repeated key returns the stored evaluation without running the decision again.\n\nRequired service-token scope: `evaluation:write`. End-user access is checked against workspace policies. Send a Bearer token and the `X-Workspace-Id` header.","security":[{"bearer":[]}],"parameters":[{"name":"X-Workspace-Id","in":"header","required":true,"description":"Active workspace UUID. The authenticated principal must have access to this workspace.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000001"},{"name":"Idempotency-Key","in":"header","required":false,"description":"Client-chosen key, such as a UUID, that makes a retry safe. A repeated key returns the stored 201 response without running the request again. Reusing a key with a different request returns 409. A non-2xx response does not store the key.","schema":{"type":"string","minLength":1,"maxLength":128},"example":"7f9c2ba4-e88f-4f2e-9b1d-1f3c6a0e5d21"},{"name":"decisionId","in":"path","required":true,"description":"Decision whose version will be evaluated.","schema":{"type":"string","format":"uuid"},"example":"019991b1-0000-7000-8000-000000000003"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"title":"CreateLogicEvaluation","type":"object","required":["version","fact"],"properties":{"version":{"type":"integer","minimum":0,"maximum":2147483647,"description":"Decision version: 1 and above select saved versions; 0 selects the editable working copy.","example":1},"fact":{"type":"object","additionalProperties":true,"description":"Input facts expected by your decision. The example assumes a decision accepting age and returning eligible; replace it with your own input.","example":{"age":25}}},"example":{"version":1,"fact":{"age":25}}}}}},"responses":{"201":{"description":"Evaluation recorded; inspect status for COMPLETED or FAILED.","content":{"application/json":{"schema":{"title":"LogicEvaluation","type":"object","required":["id","status","result","performance","trace"],"properties":{"id":{"type":["string","null"],"format":"uuid","description":"Persisted evaluation identifier; nullable in the shared evaluation contract.","example":"019991b1-0000-7000-8000-000000000006"},"status":{"type":"string","enum":["PENDING","COMPLETED","FAILED"],"description":"The synchronous REST call returns COMPLETED or FAILED. PENDING is part of the shared evaluation model.","example":"COMPLETED"},"result":{"description":"Decision-specific output. When status is FAILED, contains an error property describing the failure.","example":{"eligible":true}},"performance":{"type":["string","null"],"description":"Engine-reported duration, or null when unavailable.","example":"1.2ms"},"trace":{"type":["object","null"],"additionalProperties":true,"description":"Engine trace keyed by node ID. Contains per-node diagnostic data; sensitive configuration values are redacted. Null when unavailable.","example":null}},"example":{"id":"019991b1-0000-7000-8000-000000000006","status":"COMPLETED","result":{"eligible":true},"performance":"1.2ms","trace":{}}}}}},"400":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"BadRequestResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["BadRequest"],"example":"BadRequest"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["400-000","400-001","400-002","400-003","400-004","400-005","400-006","400-007","400-008","400-100","400-101","400-102","400-103","400-104","400-105","400-106","400-107","400-108","400-109","400-110","400-111","400-112"],"example":"400-001"},"message":{"type":"string","example":"Field 'ssn' is required"}}}}}}}}},"401":{"description":"Unauthorized","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"UnauthorizedResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Unauthorized"],"example":"Unauthorized"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["401-000","401-001","401-002","401-003","401-004","401-005","401-006","401-007"],"example":"401-000"},"message":{"type":"string","example":"Client is not authenticated"}}}}}}}}},"403":{"description":"Bad Request","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ForbiddenResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Forbidden"],"example":"Forbidden"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["403-000","403-001"],"example":"403-000"},"message":{"type":"string","example":"Client does not have access to this resource"}}}}}}}}},"404":{"description":"Not Found","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"NotFoundResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["NotFound"],"example":"NotFound"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["404-000","404-001","404-002"],"example":"404-000"},"message":{"type":"string","example":"The requested resource was not found"}}}}}}}}},"409":{"description":"Conflict","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ConflictResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["Conflict"],"example":"Conflict"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["409-000","409-001","409-002"],"example":"409-000"},"message":{"type":"string","example":"A resource with this identifier already exists"}}}}}}}}},"429":{"description":"Too Many Requests. When the rate limit rejects a request, the response carries `Retry-After` and only the `errors` field: no `timestamp`, `moreInfo` or `X-Request-ID`, as the request never reached the API.","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"Retry-After":{"description":"Seconds to wait before retrying. Sent when the rate limit rejects a request.","schema":{"type":"integer","example":60}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TooManyRequestsResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["TooManyRequests"],"example":"TooManyRequests"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["429-000"],"example":"429-000"},"message":{"type":"string","example":"Too many requests. Please try again later."}}}}}}}}},"500":{"description":"Internal Server Error","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"InternalServerErrorResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["InternalServerError"],"example":"InternalServerError"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["500-000","500-001"],"example":"500-000"},"message":{"type":"string","example":"An unexpected internal error occurred"}}}}}}}}},"503":{"description":"Service Unavailable","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"ServiceUnavailableResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["ServiceUnavailable"],"example":"ServiceUnavailable"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["503-000"],"example":"503-000"},"message":{"type":"string","example":"An error occurred while interacting with a third party service"}}}}}}}}},"504":{"description":"Gateway Timeout","headers":{"Content-Type":{"description":"The content type of the response.","example":"application/json; charset=utf-8","schema":{"type":"string","enum":["application/json; charset=utf-8"]}},"X-Request-ID":{"description":"UUID generated on each request. Provide this id to customer support if an error occurs.","schema":{"type":"string","format":"uuid","example":"0679c533-5061-496e-8dc5-df786f04a209"}}},"content":{"application/json":{"schema":{"title":"TimeoutResponse","type":"object","properties":{"timestamp":{"type":"string","format":"date-time","example":"2019-09-16T22:14:45.624Z"},"moreInfo":{"type":"string","format":"url","example":"https://docs.neobits.ai/"},"errors":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","enum":["GatewayTimeout"],"example":"GatewayTimeout"},"code":{"type":"string","description":"Unique error code in format HTTP_STATUS-SEQUENCE","enum":["504-000"],"example":"504-000"},"message":{"type":"string","example":"The request timed out"}}}}}}}}}}}}},"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token authentication using OAuth 2.0 client credentials flow."},"basic":{"type":"http","scheme":"basic","description":"Basic authentication, base64 encoded username:password."}}}}