diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 684c284..4185877 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,6 +58,9 @@ jobs: working-directory: dist/ run: sha256sum convctl-* > checksums.txt + - name: Generate discovery files + run: python3 scripts/generate-discovery.py + - name: Attest binary provenance uses: actions/attest-build-provenance@v2 with: @@ -90,3 +93,5 @@ jobs: files: | dist/convctl-* dist/checksums.txt + public/llms.txt + public/.well-known/skills/index.json diff --git a/CLAUDE.md b/CLAUDE.md index 9c99961..613ceba 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -35,23 +35,27 @@ cd plugins/corezoid/mcp-server && npx @modelcontextprotocol/inspector go run . m plugins/corezoid/ mcp-server/ — Go MCP server source (starts automatically via .mcp.json) skills/ - corezoid/ — Main skill: platform overview, MCP tools, routing - SKILL.md - references/ — Lookup documents (variables guide, env setup) - corezoid-init/ — Sub-skill: environment setup and workspace pull - SKILL.md - corezoid-create/ — Sub-skill: create a new process from scratch - SKILL.md - corezoid-edit/ — Sub-skill: modify an existing process - SKILL.md - corezoid-review/ — Sub-skill: audit and analyze a process + corezoid/ — Main skill: platform overview, MCP tools, routing SKILL.md + references/ — Lookup documents (variables guide, env setup) + corezoid-init/ — Sub-skill: environment setup and workspace pull + corezoid-create/ — Sub-skill: create a new process from scratch + corezoid-edit/ — Sub-skill: modify an existing process + corezoid-state-diagram-create/ — Sub-skill: create a new state diagram (conv_type "state") from scratch + corezoid-state-diagram-edit/ — Sub-skill: modify an existing state diagram + corezoid-review/ — Sub-skill: audit and analyze a single process + corezoid-project-review/ — Sub-skill: audit a whole project / multiple processes + corezoid-dashboard-manager/ — Sub-skill: create and edit Corezoid dashboards + corezoid-process-tech-writer/ — Sub-skill: generate technical documentation for processes + corezoid-access/ — Sub-skill: share processes/folders, manage groups/API keys + marketplace-publish-validation/ — Sub-skill: validation checklist for marketplace publishing docs/ nodes/ — Per-node-type documentation (24 node types) process/ — Process structure, validation rules, error handling + state-diagrams/ — State diagram concepts, node structures, process interaction tasks/ — Task metadata and examples node-structures.md — JSON schemas for all node types (canonical reference) - samples/ — Example .conv.json processes + samples/ — Example .conv.json processes (state-diagrams/ holds state-diagram samples) ``` ### How skills work diff --git a/README.md b/README.md index bac334d..0abada6 100644 --- a/README.md +++ b/README.md @@ -199,6 +199,7 @@ validation errors, and summarize what each process does. | `delete-task` | Remove a task from a node | | `modify-task` | Update task parameters | | `create-process` | Create a new empty process in a folder | +| `create-state-diagram` | Create a new empty state diagram (conv_type "state") in a folder | | `create-folder` | Create a new subfolder | | `create-alias` | Create a short alias for a process | | `create-variable` | Create a Corezoid environment variable | @@ -208,6 +209,21 @@ validation errors, and summarize what each process does. | `modify-chart` | Modify an existing chart (full series replace) | | `get-chart` | Get a single chart with its series data | | `set-dashboard-layout` | Save chart positions on a dashboard grid | +| `share-object` | Grant or revoke access on a process/folder/stage/project for a user, API key or group (use privs="none" to revoke) | +| `list-shares` | List principals with access to a shared object | +| `create-group` | Create a new user group (optional description) | +| `modify-group` | Rename a group or update its description | +| `list-group-objects`| List processes currently shared with a group | +| `delete-group` | Delete a user group (refuses by default if shares active; force=true to override) | +| `add-to-group` | Add a user or API key to a group | +| `remove-from-group` | Remove a user or API key from a group | +| `list-groups` | List user groups in the workspace | +| `create-api-key` | Create a new API key (secret written to ~/.corezoid/api-keys/, never printed in chat) | +| `modify-api-key` | Rename or re-describe an API key | +| `delete-api-key` | Delete an API key (invalidates secret immediately) | +| `list-api-keys` | List API keys in the workspace | +| `find-principal` | Resolve user / group / API-key name to obj_id | +| `invite-user` | Invite an external email and share an object in one call | ## Architecture @@ -220,8 +236,13 @@ Claude Code / Codex │ create-process, create-folder, create-alias, create-variable ├── Tasks run-task, list-node-tasks, list-task-history │ modify-task, delete-task - └── Dashboards create-dashboard, get-dashboard, add-chart, - modify-chart, get-chart, set-dashboard-layout + ├── Dashboards create-dashboard, get-dashboard, add-chart, + │ modify-chart, get-chart, set-dashboard-layout + └── Access share-object, list-shares, + create-group, modify-group, delete-group, list-group-objects, + add-to-group, remove-from-group, list-groups, + create-api-key, modify-api-key, delete-api-key, list-api-keys, + find-principal, invite-user ``` ## Project structure diff --git a/docs/corezoid-swagger.json b/docs/corezoid-swagger.json new file mode 100644 index 0000000..8282459 --- /dev/null +++ b/docs/corezoid-swagger.json @@ -0,0 +1,57588 @@ +{ + "openapi": "3.0.1", + "info": { + "title": "Corezoid API", + "description": "# Introduction\nWelcome to the Corezoid API documentation. \nHere you can learn everything you need to know about our API and how to interact with Corezoid.\n\n# Authentication\n\n", + "x-logo": { + "url": "https://account.corezoid.com/static/corezoid.svg", + "altText": "Corezoid" + }, + "contact": { + "email": "support@corezoid.com" + }, + "version": "2.0" + }, + "externalDocs": { + "description": "User Guide", + "url": "https://doc.corezoid.com/docs" + }, + "servers": [ + { + "url": "https://api.corezoid.com/" + } + ], + "x-tagGroups": [ + { + "name": "json", + "tags": [ + "alias", + "aliases", + "api_code", + "api_key", + "bot_wizzard", + "callback_hash", + "channel", + "chart", + "commit", + "commits", + "company_users", + "company", + "conf", + "conv_auth", + "conv_params", + "conv", + "convs", + "dashboard", + "dashboards", + "env_var", + "folder_branch", + "folder", + "git_call", + "global_counters", + "group", + "history", + "instance", + "invite", + "node", + "nodes", + "obj_scheme", + "object", + "objs", + "owner", + "path_to_folder", + "project", + "projects", + "stage", + "stat", + "statistics", + "sys_stat", + "task_history", + "task", + "upload", + "used_traff", + "user_status", + "user", + "version", + "versions" + ] + }, + { + "name": "upload", + "tags": [ + "obj_scheme(upload)", + "version(upload)", + "task(upload)", + "upload_info" + ] + }, + { + "name": "download", + "tags": [ + "obj_scheme(download)", + "node(download)" + ] + }, + { + "name": "compare", + "tags": [ + "obj_scheme(compare)" + ] + }, + { + "name": "merge", + "tags": [ + "obj_scheme(merge)" + ] + }, + { + "name": "copy", + "tags": [ + "obj_copy" + ] + } + ], + "paths": { + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_1}/{SIGNATURE}": { + "post": { + "tags": [ + "alias" + ], + "summary": "json", + "operationId": "alias", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating an alias - an object that replaces a numeric identifier with a character identifier. You need to perform the Link Alias operation after performing the Create Alias operation for creating an alias and linking it to an object (Process / State Diagram / Dashboard).

Modify

Method for updating alias params.

Show

Method for getting alias information.

Delete

Method for moving an alias to Trash (switch the alias status to Deleted).

Favorite

Method for adding an alias to the Favorites list or deleting it from the Favorites list.

Link

Method for linking an alias to a Process or unlinking it from a Process (delete the link).

Upsert

Method for creating and updating an alias (if it already exists).

Destroy

Method for deleting an alias (full deletion from the Trash).
Note: Front-end does not use this method.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/alias-create-request" + }, + { + "$ref": "#/components/schemas/alias-modify-request" + }, + { + "$ref": "#/components/schemas/alias-show-request" + }, + { + "$ref": "#/components/schemas/alias-delete-request" + }, + { + "$ref": "#/components/schemas/alias-favorite-request" + }, + { + "$ref": "#/components/schemas/alias-link-request" + }, + { + "$ref": "#/components/schemas/alias-upsert-request" + }, + { + "$ref": "#/components/schemas/alias-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-10", + "modify": "#/components/schemas/modify-request-9", + "show": "#/components/schemas/show-request-8", + "delete": "#/components/schemas/delete-request-9", + "favorite": "#/components/schemas/favorite-request-4", + "link": "#/components/schemas/link-request-5", + "upsert": "#/components/schemas/upsert-request", + "destroy": "#/components/schemas/destroy-request-5" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "obj": "alias", + "title": "test1", + "short_name": "test1", + "description": "test alias", + "company_id": "i848211059", + "stage_id": 371951, + "project_id": 371949, + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "obj": "alias", + "title": "test1", + "short_name": "test1", + "description": "test alias.", + "company_id": "i848211059", + "type": "modify", + "obj_id": 52678 + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "alias", + "obj_id": 52678, + "company_id": "i848211059" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "alias", + "obj_id": 53403, + "company_id": "i848211059" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "alias", + "company_id": "i848211059", + "obj_id": 52703, + "favorite": true + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "link": true, + "obj_id": 52678, + "obj_to_id": 1000853, + "obj_to_type": "conv", + "type": "link", + "obj": "alias", + "company_id": "i848211059" + } + ] + } + }, + "upsert": { + "summary": "upsert", + "value": { + "ops": [ + { + "type": "upsert", + "obj": "alias", + "obj_id": 29517, + "title": "First Alias", + "description": "First Alias", + "short_name": "alias-1", + "company_id": "i493107423" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "alias", + "obj_id": 53547, + "company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/alias-create-response" + }, + { + "$ref": "#/components/schemas/alias-modify-response" + }, + { + "$ref": "#/components/schemas/alias-show-response" + }, + { + "$ref": "#/components/schemas/alias-delete-response" + }, + { + "$ref": "#/components/schemas/alias-favorite-response" + }, + { + "$ref": "#/components/schemas/alias-link-response" + }, + { + "$ref": "#/components/schemas/alias-upsert-response" + }, + { + "$ref": "#/components/schemas/alias-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-10", + "ok (modify)": "#/components/schemas/modify-response-9", + "ok (show)": "#/components/schemas/show-response-9", + "ok (delete)": "#/components/schemas/delete-response-9", + "ok (favorite)": "#/components/schemas/favorite-response-4", + "ok (link)": "#/components/schemas/link-response-5", + "ok (upsert)": "#/components/schemas/upsert-response", + "ok (destroy)": "#/components/schemas/destroy-response-5", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj_id": 52678, + "proc": "ok", + "obj": "alias" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 52678 + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "is_favorite": false, + "obj_to_title": "test01", + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner_email@corezoid.com", + "obj_id": 52678, + "obj_type": "alias", + "title": "test1", + "description": "test alias.", + "short_name": "test1", + "company_id": "i848211059", + "project_id": 371949, + "stage_id": 371951, + "project_title": "test", + "project_short_name": "test", + "stage_title": "develop", + "stage_short_name": "tedevelopst", + "obj_to_id": 1000853, + "obj_to_type": "conv", + "create_time": 1666598950, + "change_time": 1667262485, + "uuid": "d6cb5bfb-d97b-4d34-940a-13adfa02069a", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 53403 + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 52703, + "obj": "alias" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 52678 + } + ] + } + }, + "upsert": { + "summary": "upsert", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 29517 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 53547 + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource." + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_2}/{SIGNATURE}": { + "post": { + "tags": [ + "aliases" + ], + "summary": "json", + "operationId": "aliases", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting information about aliases.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/aliases-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-12" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "sort": "date", + "order": "asc", + "company_id": "i848211059", + "project_id": 371949, + "stage_id": 371951, + "obj": "aliases", + "type": "list", + "location": "stage", + "id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/aliases-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-12", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "i848211059", + "proc": "ok", + "list": [ + { + "is_favorite": false, + "obj_to_title": "test1", + "is_owner": true, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner_email@corezoid.com", + "obj_id": 52678, + "obj_type": "alias", + "title": "test1", + "description": "test alias", + "short_name": "test1", + "company_id": "i848211059", + "project_id": 371949, + "project_short_name": "Proj_1", + "project_title": "Project_1", + "stage_id": 371951, + "stage_short_name": "develop", + "stage_title": "develop", + "obj_to_id": 1000853, + "obj_to_type": "conv", + "create_time": 1666598950, + "change_time": 1666598950, + "uuid": "d6cb5bfb-d97b-4d34-940a-13adfa02069a", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource." + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Timeout" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_4}/{SIGNATURE}": { + "post": { + "tags": [ + "api_code" + ], + "summary": "json", + "operationId": "apicode", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Compile
Method for compiling basic settings of a Code node

Get
Method for showing basic settings of a Code node

load
Method for loading code to a server

", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/api_code-compile-request" + }, + { + "$ref": "#/components/schemas/api_code-get-request" + }, + { + "$ref": "#/components/schemas/api_code-load-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "compile": "#/components/schemas/compile-request-2", + "get": "#/components/schemas/get-request-8", + "load": "#/components/schemas/load-request-2" + } + } + } + } + } + }, + "examples": { + "compile": { + "summary": "compile", + "value": { + "ops": [ + { + "obj": "api_code", + "type": "compile", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "lang": "js", + "src": "var one = 1;\nvar two = 2;" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "api_code", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "env": "production" + } + ] + } + }, + "load": { + "summary": "load", + "value": { + "ops": [ + { + "type": "load", + "obj": "api_code", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "lang": "js", + "src": "var one = 1;\nvar two = 2;", + "env": "sandbox" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/api_code-compile-response" + }, + { + "$ref": "#/components/schemas/api_code-get-response" + }, + { + "$ref": "#/components/schemas/api_code-load-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (compile)": "#/components/schemas/compile-response-2", + "ok (get)": "#/components/schemas/get-response-8", + "ok (load)": "#/components/schemas/load-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "compile": { + "summary": "compile", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "description": "" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "lang": "js", + "src": "var one = 1;" + } + ] + } + }, + "load": { + "summary": "load", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "description": "" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_5}/{SIGNATURE}": { + "post": { + "tags": [ + "api_key" + ], + "summary": "json", + "operationId": "apiKey", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing which API Keys have access to a process", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/api_key-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-16" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "obj": "api_key", + "type": "show", + "obj_id": 1020531 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/api_key-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-17", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "title": "first_2", + "login": 29595, + "key": "wB12nFmNBI0oOSMU3HklYOyZw9mYigezFfDnz1xCDfKwqwFN", + "obj_id": 28288 + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_6}/{SIGNATURE}": { + "post": { + "tags": [ + "bot_wizzard" + ], + "summary": "json", + "operationId": "bot_wizzard", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a new bot via Communications Orchestrator

Modify

Method for updating a bot via Communications Orchestrator

Check

Method for checking a bot via Communications Orchestrator", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/bot_wizzard-create-request" + }, + { + "$ref": "#/components/schemas/bot_wizzard-modify-request" + }, + { + "$ref": "#/components/schemas/bot_wizzard-check-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-21", + "modify": "#/components/schemas/modify-request-17", + "check": "#/components/schemas/check-request-3" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "messengers": [ + { + "channel": "telegram", + "key": "test" + } + ], + "company_id": "i702619617", + "project_id": 372753, + "stage_id": 372755, + "lang": "en", + "version": 2, + "type": "create", + "obj": "bot_wizzard", + "async": true + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "bot_wizzard", + "obj_id": "658a87c056167c03140034c8", + "company_id": "20c4e4a1-0f0c-4c32-a6f2-ee12b5fa5d80" + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "ops": [ + { + "obj_id": "63add73c094bab791f001b44", + "obj": "bot_wizzard", + "type": "check" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/bot_wizzard-create-response" + }, + { + "$ref": "#/components/schemas/bot_wizzard-modify-response" + }, + { + "$ref": "#/components/schemas/bot_wizzard-check-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-21", + "ok (modify)": "#/components/schemas/modify-response-17", + "ok (check)": "#/components/schemas/check-response-3", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create-async": { + "summary": "create (async:true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "result": "queued", + "obj_id": "66c6e9e1ae906a59ac002889" + } + ] + } + }, + "create": { + "summary": "create (async:false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "dashboard_url": "", + "folder_url": "https://admin-pre.corezoid.com/folder/606644", + "webhooks_url": [ + { + "channel": "fbmessenger", + "url": "" + }, + { + "channel": "skype", + "url": "" + } + ], + "result": "ok", + "description": "undefined" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard" + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "dashboard_url": "", + "folder_url": "https://admin-pre.corezoid.com/folder/795598", + "webhooks_url": [ + { + "channel": "fbmessenger", + "url": "" + }, + { + "channel": "skype", + "url": "" + } + ], + "result": "ok", + "description": "undefined" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_7}/{SIGNATURE}": { + "post": { + "tags": [ + "callback_hash" + ], + "summary": "json", + "operationId": "callback_hash", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Create
Method for creating a Direct URL for task upload to procesess and state diagrams via an alias

Modify
Method for re-enabling a Direct URL for task upload to procesess and state diagrams

Get
Method for showing a Direct URL for task upload to procesess or state diagrams.

Delete
Method for disabling a Direct URL for task upload to procesess and state diagrams

", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/callback_hash-create-request" + }, + { + "$ref": "#/components/schemas/callback_hash-modify-request" + }, + { + "$ref": "#/components/schemas/callback_hash-get-request" + }, + { + "$ref": "#/components/schemas/callback_hash-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-18", + "modify": "#/components/schemas/modify-request-15", + "get": "#/components/schemas/get-request-3", + "delete": "#/components/schemas/delete-request-15" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "callback_hash", + "alias_id": 53788, + "company_id": "i702619617" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "callback_hash", + "conv_id": 1004237 + } + ] + } + }, + "modifyAlias": { + "summary": "modify (alias)", + "value": { + "ops": [ + { + "type": "modify", + "obj": "callback_hash", + "alias_id": 53546, + "obj_type": "alias", + "company_id": "i702619617" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "ops": [ + { + "conv_id": 1004237, + "type": "get", + "obj": "callback_hash", + "company_id": "i702619617" + } + ] + } + }, + "getAlias": { + "summary": "get (alias)", + "value": { + "ops": [ + { + "alias_id": 53789, + "obj_type": "alias", + "type": "get", + "obj": "callback_hash", + "company_id": "i702619617" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "callback_hash", + "conv_id": 1004237 + } + ] + } + }, + "deleteAlias": { + "summary": "delete (alias)", + "value": { + "ops": [ + { + "type": "delete", + "obj": "callback_hash", + "alias_id": 53546, + "obj_type": "alias", + "company_id": "i702619617" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/callback_hash-create-response" + }, + { + "$ref": "#/components/schemas/callback_hash-modify-response" + }, + { + "$ref": "#/components/schemas/callback_hash-get-response" + }, + { + "$ref": "#/components/schemas/callback_hash-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-18", + "ok (modify)": "#/components/schemas/modify-response-15", + "ok (get)": "#/components/schemas/get-response-3", + "ok (delete)": "#/components/schemas/delete-response-15", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "callback_hash": "08df834bbebc682c30df165967af119606fb6a90" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 1004237, + "callback_hash": "813b6127ab22584d28e9032612e75f09a2dd71e9" + } + ] + } + }, + "modifyAlias": { + "summary": "modify (alias)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "callback_hash": "6336acee43c1dad05ae91a1e84f33b68e83972f2" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "callback_hash": "0cf3c1e9eee96859dbd68bd7fcc22ed66bee7531" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 1004237 + } + ] + } + }, + "deleteAlias": { + "summary": "delete (alias)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "type": "delete", + "obj": "alias_callback_hash", + "proc": "ok" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_8}/{SIGNATURE}": { + "post": { + "tags": [ + "channel" + ], + "summary": "json", + "operationId": "channel", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a new token to connect a webhook to a process

Modify

Method for updating a token for connecting the webhook to the process
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/channel-create-request" + }, + { + "$ref": "#/components/schemas/channel-modify-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-22", + "modify": "#/components/schemas/modify-request-18" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "obj_type": "viber", + "env": "front", + "conv_id": 1324888, + "folder_id": 520385, + "company_id": "i178661175", + "token": "test", + "type": "create", + "obj": "channel" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "obj_type": "telegram", + "env": "front", + "token": "1041341718:AAHDE55An5dXWNbXpOhzSfHgczRS7UlUbCg", + "obj_id": "63bc1cd7094bab0422001d6b", + "callback_hash": "bcbc26389384009c920f0cf9ecaadf7ba2427694", + "type": "modify", + "obj": "channel", + "result": "error", + "description": "test" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/channel-create-response" + }, + { + "$ref": "#/components/schemas/channel-modify-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-22", + "ok (modify)": "#/components/schemas/modify-response-18", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "channel", + "obj_type": "viber" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "channel" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_9}/{SIGNATURE}": { + "post": { + "tags": [ + "chart" + ], + "summary": "json", + "operationId": "chart", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Create
Method for creating a Chart

Modify
Method for adding and changing Charts on Dashboards

Get
Method for getting Chart settings for a Dashboard

Delete
Method for deleting a chart

", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/chart-create-request" + }, + { + "$ref": "#/components/schemas/chart-modify-request" + }, + { + "$ref": "#/components/schemas/chart-get-request" + }, + { + "$ref": "#/components/schemas/chart-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-19", + "modify": "#/components/schemas/modify-request-16", + "get": "#/components/schemas/get-request-4", + "delete": "#/components/schemas/delete-request-16" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "company_id": "i702619617", + "name": "New Chart", + "description": "Chart description", + "dashboard_id": 78155, + "type": "create", + "obj": "chart", + "sort": true, + "series": [], + "obj_type": "table" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d", + "name": "New Chart", + "description": "", + "obj_type": "table", + "series": [ + { + "conv_id": 1004237, + "node_id": "635febcb56167c5cce007e42", + "title": "Start", + "type_icon": "start", + "type_title": "Start node", + "type": "node" + } + ], + "company_id": "i702619617" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "chart", + "company_id": "i702619617", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d", + "company_id": "i702619617" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/chart-create-response" + }, + { + "$ref": "#/components/schemas/chart-modify-response" + }, + { + "$ref": "#/components/schemas/chart-get-response" + }, + { + "$ref": "#/components/schemas/chart-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-19", + "ok (modify)": "#/components/schemas/modify-response-16", + "ok (get)": "#/components/schemas/get-response-4", + "ok (delete)": "#/components/schemas/delete-response-16", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a32fd9094bab5de700595c" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "chart", + "chart_id": "63a4142b094bab5de7006c4d", + "obj_id": 78155 + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "name": "New Chart", + "description": "", + "obj_type": "table", + "series": [], + "obj_id": "63a4142b094bab5de7006c4d", + "dashboard_id": 78155, + "company_id": "i702619617", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_10}/{SIGNATURE}": { + "post": { + "tags": [ + "charts_list" + ], + "summary": "json", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": null, + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "get" + } + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "get" + }, + { + "$ref": "#/components/schemas/company-create-response-error" + } + ] + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_11}/{SIGNATURE}": { + "post": { + "tags": [ + "commit" + ], + "summary": "json", + "operationId": "commit", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Confirm

Method for Process/State diagram deployment

Show

Method for getting commit info

Delete

Method for commit deletion", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/commit-confirm-request" + }, + { + "$ref": "#/components/schemas/commit-show-request" + }, + { + "$ref": "#/components/schemas/commit-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "confirm": "#/components/schemas/confirm-request", + "show": "#/components/schemas/show-request-15", + "delete": "#/components/schemas/delete-request-14" + } + } + } + } + } + }, + "examples": { + "confirm": { + "summary": "confirm", + "value": { + "ops": [ + { + "type": "confirm", + "obj": "commit", + "conv_id": 973630, + "company_id": "i702619617", + "version": 1667230068 + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "obj": "commit", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068, + "type": "delete" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "commit", + "obj_id": 1004849, + "obj_type": "conv", + "company_id": "i702619617", + "version": 1667294065 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/commit-confirm-response" + }, + { + "$ref": "#/components/schemas/commit-show-response" + }, + { + "$ref": "#/components/schemas/commit-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (confirm)": "#/components/schemas/confirm-response", + "ok (show)": "#/components/schemas/show-response-16", + "ok (delete)": "#/components/schemas/delete-response-14", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "confirm": { + "summary": "confirm", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068 + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "commit", + "list": [ + { + "obj_id": "6360dec1094bab1444009ae1", + "obj_type": 0, + "title": "", + "description": "", + "logics": [ + { + "type": "api_queue", + "data": {}, + "data_type": {} + }, + { + "type": "go", + "to_node_id": "6360deb756167c5cce009747" + } + ], + "semaphors": [], + "position": [ + 352, + 220 + ], + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "status": 1, + "conv_id": 1004849, + "user_id": 25130, + "create_time": 1667294602 + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068 + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_12}/{SIGNATURE}": { + "post": { + "tags": [ + "commits" + ], + "summary": "json", + "operationId": "commits", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

list

Method for getting a list of commits for a specified object
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/commits-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-21" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj": "commits", + "conv_id": 1004227, + "type": "list" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/commits-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-21", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "commits", + "list": [ + { + "conv_id": 1004227, + "version": 1667220502, + "create_time": 1667220556, + "user_id": 25130 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_13}/{SIGNATURE}": { + "post": { + "tags": [ + "company_keys" + ], + "summary": "json", + "operationId": "companyKeys", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "List of Api keys available to user.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company_keys-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-6" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "company_keys", + "company_id": "i659829000" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company_keys-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-7", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": { + "id": "", + "proc": "ok", + "obj": "company_keys", + "type": "show", + "list": [ + { + "obj": "user", + "obj_id": 82253, + "title": "My first API key for simple process", + "api_login": 120180, + "api_key": "JOg9D6Dru1V02jG1eDWbgfmNPpgGPCNCS0Dgoks2x5a57Ytga" + } + ] + } + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_14}/{SIGNATURE}": { + "post": { + "tags": [ + "company_users" + ], + "summary": "json", + "operationId": "companyUsers", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "List of company's groups, shared groups, Api keys, users
Setting capi_share_api_keys_in_company=true allows all company users access to all company keys.
In \"My Corezoid\" allows to access only the keys created by the user.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company_users-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-11" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "company_users", + "sort": "title", + "order": "asc", + "filter": "group", + "name": "string", + "company_id": "i659829000" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company_users-list-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-11", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "ok-api_key": { + "summary": "proc=ok (filter=api_key)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 25630, + "title": "first", + "owner_id": 25130, + "status": "actived", + "logins": [ + { + "key": "KwiSaA9aJNVw87KTc9F4g1PpEYicCPDcqh5anbkIcdBm1Ubzy2", + "obj_id": 26325, + "type": "api", + "login": "61e7c256094bab148b0011df" + } + ] + } + ] + } + ] + } + }, + "ok-group": { + "summary": "proc=ok (filter=group)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 59757, + "size": 0, + "title": "garlic", + "type": "admins", + "create_time": 1649950814, + "owner_id": 25130, + "owner_name": "Daria Grek", + "is_owner": true + } + ] + } + ] + } + }, + "ok-shared": { + "summary": "proc=ok (filter=shared)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 13, + "size": 53, + "title": "SuperAdmins", + "type": "supers", + "create_time": 1470756420, + "owner_id": 6, + "owner_name": "Лаверов Денис", + "is_owner": false + } + ] + } + ] + } + }, + "ok-user": { + "summary": "proc=ok (filter=user)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 45377, + "title": "John Doe", + "logins": [ + { + "key": "", + "obj_id": 76230, + "type": "google", + "login": "example@gmail.com" + } + ], + "status": "blocked", + "is_login_locked": false, + "is_superadmin": false, + "groups": [ + { + "id": 136830, + "name": "Group one" + } + ] + } + ] + } + ] + } + }, + "ok-user-superadmin": { + "summary": "proc=ok (filter=user; include unaccepted invitations (for superadmin only))", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 45377, + "title": "John Doe", + "logins": [ + { + "key": "47058ccf7bd36228a1b701cfca33cc8c765d3b347f232d6a6f378z6bec834295", + "obj_id": 76230, + "type": "google", + "login": "example@gmail.com" + } + ], + "status": "blocked", + "is_login_locked": false, + "is_superadmin": false, + "groups": [ + { + "id": 136830, + "name": "Group one" + } + ] + }, + { + "obj": "user", + "title": "aria.stark@corezoid.com", + "privs": [], + "is_invite": true, + "invite_hash": "5538044124054c5cc012ae720b1416621675d496" + } + ] + } + ] + } + }, + "error": { + "summary": "proc=error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_15}/{SIGNATURE}": { + "post": { + "tags": [ + "company" + ], + "summary": "json", + "operationId": "company", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Company

List

The method returns a list of companies available to user", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company-create-request" + }, + { + "$ref": "#/components/schemas/company-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-8", + "list": "#/components/schemas/list-request-10" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "company", + "site": "www.thewall.com", + "name": "The Wall", + "description": "Corezoid company" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "company" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "x-summary": "Array of operations", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/company-create-response" + }, + { + "$ref": "#/components/schemas/company-list-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-8", + "ok (list)": "#/components/schemas/list-response-10", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "648d1d34-4360-4fce-abce-3e67afde427f" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "id": "", + "proc": "ok", + "obj": "company", + "list": [ + { + "company_id": "i702619617", + "title": "The Wall", + "description": "string", + "status": "actived", + "owner_user_id": 1083, + "create_time": 1486043068, + "childs": 1, + "is_owner": true, + "is_admin": true, + "auth_providers": [ + { + "id": "google_saml_1", + "name": "Google SAML", + "active": true + } + ], + "user_status": "active" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_16}/{SIGNATURE}": { + "post": { + "tags": [ + "company" + ], + "summary": "json (multitenant)", + "operationId": "companyMultitenant", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Company in the multi-tenant architecture, is available only for super administrators.

Modify

Method for changing a company name, description or state. There are two reversible statuses available: Blocked and Active. After blocking a company, all company processes will be stopped and users will not be able to login to the company anymore. The method is available only to super administrators in the multi-tenant architecture.

List

The method returns a list of all companies

Delete

Method for delete company in multitenant architecture", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/multitenant-company-create-request" + }, + { + "$ref": "#/components/schemas/multitenant-company-modify-request" + }, + { + "$ref": "#/components/schemas/company-list-request" + }, + { + "$ref": "#/components/schemas/multitenant-company-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/multitenant-create-request", + "modify": "#/components/schemas/multitenant-modify-request", + "list": "#/components/schemas/list-request-10", + "delete": "#/components/schemas/multitenant-delete-request" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "company", + "login": "jane.doe@email.com", + "login_type": "corezoid", + "name": "Example", + "description": "test descr", + "auth_providers": [ + "google_saml_1" + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "company", + "company_id": "i702619617", + "status": "blocked", + "blocked_reason": "The Wall", + "name": "The Wall", + "description": "string", + "migrate_users": true, + "auth_providers": [ + "google_saml_1" + ] + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "company" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "company", + "obj_id": "i702619617" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "x-summary": "Array of operations", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/multitenant-company-create-response" + }, + { + "$ref": "#/components/schemas/multitenant-company-modify-response" + }, + { + "$ref": "#/components/schemas/company-list-response" + }, + { + "$ref": "#/components/schemas/multitenant-company-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/multitenant-create-response", + "ok (modify)": "#/components/schemas/multitenant-modify-response", + "ok (list)": "#/components/schemas/list-response-10", + "ok (delete)": "#/components/schemas/multitenant-delete-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "i702619617", + "url": "https://admin.corezoid.com/set_password/637f5248020bf6913ce1a1bb80ba4069d10a22d?redirect_url=https://admin-pre.corezoid.com/api/2/plugins/invite/637f52488025f6913ce1a1bb80ba4069d10a22d" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "company_id": "i702619617", + "name": "The wall", + "description": "string", + "status": "blocked", + "new_status": "blocked", + "old_status": "actived", + "migrated_count": 2, + "auth_providers": [ + "google_saml_1" + ] + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "id": "", + "proc": "ok", + "obj": "company", + "list": [ + { + "company_id": "i702619617", + "title": "The Wall", + "description": "string", + "status": "actived", + "owner_user_id": 1083, + "create_time": 1486043068, + "childs": 1, + "is_owner": true, + "is_admin": true, + "auth_providers": [ + { + "id": "google_saml_1", + "name": "Google SAML", + "active": true + } + ], + "user_status": "active" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "i702619617" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_17}/{SIGNATURE}": { + "post": { + "tags": [ + "conf" + ], + "summary": "node conf", + "operationId": "NodeConf", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing node settings", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conf-show(json)-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show(json)-request" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "conv_id": 1243014, + "type": "show", + "obj": "conf", + "obj_type": "timer" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conf-show(json)-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show(json)-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show (obj_type = timer)": { + "summary": "(obj_type = timer)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conf", + "obj_type": "timer", + "min_value": 30 + } + ] + } + }, + "(obj_type = ui)": { + "summary": "(obj_type = ui)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conf", + "obj_type": "ui", + "box_solution": false, + "type_logins": [ + "corezoid", + "google" + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_18}/{SIGNATURE}": { + "post": { + "tags": [ + "conv_auth" + ], + "summary": "json", + "operationId": "convAuth", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Show

Method for showing Process authorization parameters.

Modify

Method for changing Process authorization parameters.

Delete

Method for deleting Process authorization parameters.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv_auth-show-request" + }, + { + "$ref": "#/components/schemas/conv_auth-modify-request" + }, + { + "$ref": "#/components/schemas/conv_auth-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-22", + "modify": "#/components/schemas/modify-request-21", + "delete": "#/components/schemas/delete-request-21" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "conv_auth", + "conv_id": 1457936 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "conv_auth", + "conv_id": 1457936, + "obj_type": "basic", + "data": { + "user": "login", + "pass": "password" + } + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "conv_auth", + "conv_id": 1457936 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv_auth-show-response" + }, + { + "$ref": "#/components/schemas/conv_auth-modify-response" + }, + { + "$ref": "#/components/schemas/conv_auth-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-23", + "ok (modify)": "#/components/schemas/modify-response-21", + "ok (delete)": "#/components/schemas/delete-response-21", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth", + "obj_type": "basic", + "data": { + "user": "login", + "pass": "password" + } + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_19}/{SIGNATURE}": { + "post": { + "tags": [ + "conv_params" + ], + "summary": "json", + "operationId": "convParams", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

list

Method for getting parameters of the current Task.

Modify

Method for changing Task parameters. Allows you to add/change/delete Task params.
There is no way to add or remove specific Task param, you can only modify current array of Task params.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv_params-list-request" + }, + { + "$ref": "#/components/schemas/conv_params-modify-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-19", + "modify": "#/components/schemas/modify-request-14" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "conv_params", + "obj_id": 926490, + "company_id": "i702619617" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "conv_params", + "obj_id": 926490, + "params": [ + { + "name": "one", + "type": "string", + "descr": "", + "flags": [ + "required", + "output" + ], + "regex": "", + "regex_error_text": "" + } + ], + "company_id": "i702619617" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv_params-list-response" + }, + { + "$ref": "#/components/schemas/conv_params-modify-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-19", + "ok (modify)": "#/components/schemas/modify-response-14", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_params", + "obj_id": 926490, + "params": [ + { + "name": "one", + "type": "string", + "descr": "", + "flags": [ + "required", + "input" + ], + "regex": "", + "regex_error_text": "" + } + ], + "ref_mask": true + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_params", + "conv_id": 926490 + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_21}/{SIGNATURE}": { + "post": { + "tags": [ + "conv" + ], + "summary": "json", + "operationId": "conv", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a new Process / State diagram.

Modify

Method for updating a Process / State diagram.

List

Method for getting a Process's / State diagram's nodes list and shared access privileges list.

Show

Method for getting Process / State diagram information.

Link

Method for linking a Process / State diagram to an API Key, User or Group (share access - or remove previously shared access).

Favorite

Method for adding a Process / State diagram to the favorite list - or deleting from the favorite list (Add star - Starred).

Delete

Method for moving a Process / State diagram to Trash (switch Process' / State diagram's status to deleted).

Restore

Method for recovering a Process / State diagram from Trash (switch a Process' / State diagram's status from Deleted to Paused).

Destroy

Method for deleting a Process / State diagram (deleting from Trash).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv-create-request" + }, + { + "$ref": "#/components/schemas/conv-modify-request" + }, + { + "$ref": "#/components/schemas/conv-list-request" + }, + { + "$ref": "#/components/schemas/conv-show-request" + }, + { + "$ref": "#/components/schemas/conv-link-request" + }, + { + "$ref": "#/components/schemas/conv-favorite-request" + }, + { + "$ref": "#/components/schemas/conv-delete-request" + }, + { + "$ref": "#/components/schemas/conv-restore-request" + }, + { + "$ref": "#/components/schemas/conv-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-11", + "modify": "#/components/schemas/modify-request-10", + "list": "#/components/schemas/list-request-13", + "show": "#/components/schemas/show-request-9", + "link": "#/components/schemas/link-request-6", + "favorite": "#/components/schemas/favorite-request-5", + "delete": "#/components/schemas/delete-request-10", + "restore": "#/components/schemas/restore-request-6", + "destroy": "#/components/schemas/destroy-request-6" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "New object", + "description": "", + "folder_id": 303629, + "company_id": "i848211059", + "obj": "conv", + "create_mode": "without_nodes", + "conv_type": "process", + "type": "create", + "obj_type": 0, + "status": "active" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "title": "New object 2", + "description": "test description", + "type": "modify", + "obj": "conv", + "obj_id": 899874, + "company_id": "i848211059" + } + ] + } + }, + "list": { + "summary": "list (list_obj != group)", + "value": { + "ops": [ + { + "obj": "conv", + "type": "list", + "obj_id": 790828 + } + ] + } + }, + "listGroup": { + "summary": "list (list_obj == group)", + "value": { + "ops": [ + { + "obj": "conv", + "type": "list", + "obj_id": 790828, + "list_obj": "group" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "obj": "conv", + "type": "show", + "obj_id": 790828 + } + ] + } + }, + "link": { + "summary": "link (process to key, all privileges)", + "value": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 789868, + "obj_to": "user", + "obj_to_id": 31913, + "is_need_to_notify": true, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "link2key_one_privilege": { + "summary": "link (process to key, one privilege)", + "value": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834936, + "obj_to": "user", + "obj_to_id": 32510, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "link2group_two_privileges": { + "summary": "link (process to group, two privileges)", + "value": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834936, + "obj_to": "group", + "obj_to_id": 32510, + "company_id": "i848211059", + "privs": [ + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "linkUnlink_key": { + "summary": "link (unlink key - delete access)", + "value": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834825, + "obj_to": "user", + "obj_to_id": 31913, + "privs": [] + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "conv", + "obj_id": 773375, + "favorite": true + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "conv", + "obj_id": 834087 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "conv", + "obj_id": 834087 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "conv", + "obj_id": 834087 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/conv-create-response" + }, + { + "$ref": "#/components/schemas/conv-modify-response" + }, + { + "$ref": "#/components/schemas/conv-list-response" + }, + { + "$ref": "#/components/schemas/conv-show-response" + }, + { + "$ref": "#/components/schemas/conv-link-response" + }, + { + "$ref": "#/components/schemas/conv-favorite-response" + }, + { + "$ref": "#/components/schemas/conv-delete-response" + }, + { + "$ref": "#/components/schemas/conv-restore-response" + }, + { + "$ref": "#/components/schemas/conv-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-11", + "ok (modify)": "#/components/schemas/modify-response-10", + "ok (list)": "#/components/schemas/list-response-13", + "ok (show)": "#/components/schemas/show-response-10", + "ok (link)": "#/components/schemas/link-response-6", + "ok (favorite)": "#/components/schemas/favorite-response-5", + "ok (delete)": "#/components/schemas/delete-response-10", + "ok (restore)": "#/components/schemas/restore-response-6", + "ok (destroy)": "#/components/schemas/destroy-response-6", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 899874, + "folder_id": 303629, + "hash": "dc2f75b7aeb59bce5bb3b5f9e2a43fa812902ffa" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 899874, + "new_status": 1, + "old_status": 1, + "is_changed": false + } + ] + } + }, + "list": { + "summary": "list (list_obj != group)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 790828, + "project_id": 0, + "stage_id": 0, + "immutable": false, + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "status": "active", + "title": "22", + "description": "", + "conv_type": "process", + "is_owner": false, + "owner_name": "First_Name Last_Name", + "owner_id": 27074, + "owner_login": "owner.email@corezoid.com", + "proc": "ok", + "list": [ + { + "obj": "node", + "obj_id": "62b599ba094bab2fe4000308", + "title": "Final", + "description": "", + "logics": [], + "semaphors": [], + "count": 0, + "obj_type": 2, + "position": [ + 560, + 400 + ], + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"success\"}", + "options": "{\"save_task\":true}" + } + ], + "escalation_conv": "undefined", + "shared": true, + "folder_id": 210032, + "folder_name": "test", + "change_time": 1656068537, + "create_time": 1656068537, + "tacts": 0, + "favorite": false, + "company_id": null, + "commits": { + "version": 1656068657, + "list": [ + { + "obj_id": "62c4090d094bab689e0022e8", + "condition": "{\"logics\":[{\"type\":\"api_code\",\"err_node_id\":\"62c4090d094bab689e0022eb\",\"code_error\":true},{\"type\":\"go\",\"to_node_id\":\"62c4094c094bab689e0022ec\"}],\"semaphors\":[]}", + "name": "", + "description": "", + "position": [ + 436, + 500 + ], + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "status": "actived", + "user_id": 27074, + "nick": "First_Name Last_Name", + "change_time": 1657014604, + "type": 0 + } + ], + "size": 2, + "last_confirmed_version": 1656068538 + } + } + ] + } + }, + "listGroup": { + "summary": "list (list_obj == group)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 790828, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 27201, + "login_id": 27201, + "title": "test key", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "" + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 790828, + "title": "test22", + "status": "active", + "size": 2, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "create_time": 1656068537, + "change_time": 1656068537, + "company_id": "i738314881", + "project_id": 0, + "stage_id": 0, + "immutable": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "parent_obj_id": 509924, + "parent_obj_type": "folder" + } + ] + } + }, + "link": { + "summary": "link (process to key, all privileges)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 789868, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "link" + } + ] + } + }, + "linkUnlink_key": { + "summary": "link (unlink key - delete access)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 834825, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "unlink" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 773375, + "obj": "conv" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 834087, + "proc": "ok" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834087, + "obj": "conv", + "parent_folder_id": 210032 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834087, + "obj_type": "conv" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_22}/{SIGNATURE}": { + "post": { + "tags": [ + "convs" + ], + "summary": "json", + "operationId": "convs", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for listing Processes and State diagrams by search with pattern.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/convs-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-14" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "pattern": "test", + "obj_type": "process", + "obj": "convs", + "owner_id": 27074, + "company_id": "i848211059", + "project_id": 375501, + "location": "stage", + "type": "list" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/convs-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-14", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "convs", + "list": [ + { + "obj_id": 1007000, + "obj_type": "conv", + "create_time": 1667522490, + "change_time": 1667522490, + "status": "active", + "is_owner": true, + "owner_name": "First_Name Last_Name", + "owner_id": 27074, + "title": "test process", + "description": "", + "escalation_conv": "undefined", + "conv_type": "process", + "project_id": 375501, + "project_title": "test2", + "stage_id": 375502, + "stage_title": "production" + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_23}/{SIGNATURE}": { + "post": { + "tags": [ + "dashboard" + ], + "summary": "json", + "operationId": "dashboard", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Dashboard.

Modify

Method for updating Dashboard params.

List

Method for getting a list of users which have the Dashboard rights.

Show

Method for getting current Dashboard Charts.

Link

Method for linking a Dashboard to an to an API Key, User or Group (share access).

Favorite

Method for adding a Dashboard to the favorites list - or deleting from the favorites list.

Delete

Method for moving a Dashboard to Trash (set Dashboard's status to deleted).

Restore

Method for recovering a Dashboard from Trash (switch a Dashboard's status from deleted to paused).

Destroy

Method for deleting a Dashboard (deleting from Trash).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/dashboard-create-request" + }, + { + "$ref": "#/components/schemas/dashboard-modify-request" + }, + { + "$ref": "#/components/schemas/dashboard-list-request" + }, + { + "$ref": "#/components/schemas/dashboard-show-request" + }, + { + "$ref": "#/components/schemas/dashboard-link-request" + }, + { + "$ref": "#/components/schemas/dashboard-favorite-request" + }, + { + "$ref": "#/components/schemas/dashboard-delete-request" + }, + { + "$ref": "#/components/schemas/dashboard-restore-request" + }, + { + "$ref": "#/components/schemas/dashboard-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request", + "modify": "#/components/schemas/modify-request", + "list": "#/components/schemas/list-request", + "show": "#/components/schemas/show-request", + "link": "#/components/schemas/link-request", + "favorite": "#/components/schemas/favorite-request", + "delete": "#/components/schemas/delete-request", + "restore": "#/components/schemas/restore-request", + "destroy": "#/components/schemas/destroy-request" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "New object", + "description": "", + "folder_id": 0, + "company_id": "i260811111", + "obj": "dashboard", + "time_range": { + "select": "online", + "start": 1656075346, + "stop": 1656075346, + "timezone_offset": -180 + }, + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "dashboard", + "obj_id": 65292, + "title": "", + "description": "", + "time_range": { + "timezone_offset": -180, + "select": "online" + }, + "grid": [ + { + "obj_id": "631b4659094bab65a0012d4b", + "x": 3, + "y": 0, + "width": 4, + "height": 4 + }, + { + "obj_id": "631b46de094bab65a0012d4d", + "x": 7, + "y": 0, + "width": 4, + "height": 4 + } + ] + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 61440, + "obj": "dashboard", + "type": "list", + "list_obj": "group" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "obj_id": 12345, + "type": "show", + "obj": "dashboard" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "type": "link", + "obj": "dashboard", + "obj_id": 12345, + "obj_to": "user", + "obj_to_id": 44444, + "company_id": "i260836082", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "dashboard", + "obj_id": 12345, + "favorite": true + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "dashboard", + "obj_id": 62091 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "dashboard", + "obj_id": 62084 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "dashboard", + "obj_id": 12345 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/dashboard-create-response" + }, + { + "$ref": "#/components/schemas/dashboard-modify-response" + }, + { + "$ref": "#/components/schemas/dashboard-list-response" + }, + { + "$ref": "#/components/schemas/dashboard-show-response" + }, + { + "$ref": "#/components/schemas/dashboard-link-response" + }, + { + "$ref": "#/components/schemas/dashboard-favorite-response" + }, + { + "$ref": "#/components/schemas/dashboard-delete-response" + }, + { + "$ref": "#/components/schemas/dashboard-restore-response" + }, + { + "$ref": "#/components/schemas/dashboard-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response", + "ok (modify)": "#/components/schemas/modify-response", + "ok (list)": "#/components/schemas/list-response", + "ok (show)": "#/components/schemas/show-response-2", + "ok (link)": "#/components/schemas/link-response", + "ok (favorite)": "#/components/schemas/favorite-response", + "ok (delete)": "#/components/schemas/delete-response", + "ok (restore)": "#/components/schemas/restore-response", + "ok (destroy)": "#/components/schemas/destroy-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 12345 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 65292 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "dashboard", + "obj_id": 12345, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 77777, + "login_id": 77777, + "title": "User", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "example_@gmail.com" + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 11111, + "title": "New object", + "description": "", + "create_time": 1659601245, + "change_time": 1659601245, + "time_range": { + "timezone_offset": -180, + "select": "online" + }, + "favorite": false, + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "company_id": "i260111182", + "chart_list": [ + { + "name": "New Chart", + "obj_id": "62e927fd094bab164d003aba", + "type": "table" + } + ], + "folder_id": 123456, + "folder_name": "New object", + "owner_id": 12345, + "owner_login": "owner.email@corezoid.com", + "owner_name": "Owner Name", + "immutable": false, + "grid": [ + { + "obj_id": "62e90d7f56167c0913003a30", + "x": 0, + "y": 0, + "width": 4, + "height": 4 + } + ], + "parent_obj_id": 0, + "parent_obj_type": "folder" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "dashboard", + "obj_id": 12345, + "obj_to_type": "user", + "obj_to_id": 44444, + "obj_to_title": "User Test", + "action_type": "link" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 12345, + "obj": "dashboard" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "dashboard", + "obj_id": 62091, + "proc": "ok" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 62084, + "obj": "dashboard", + "parent_folder_id": 0 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 12345, + "obj_type": "dashboard" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_24}/{SIGNATURE}": { + "post": { + "tags": [ + "dashboards" + ], + "summary": "json", + "operationId": "dashboards", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting a list of dashboards.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/dashboards-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-2" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "dashboards", + "company_id": "i246198512", + "project_id": 169886, + "stage_id": 169887, + "limit": 10, + "pattern": "test1" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/dashboards-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboards", + "list": [ + { + "obj_id": 43384, + "obj_type": "dashboard", + "company_id": "i246198512", + "title": "test1", + "create_time": 1681128587, + "change_time": 1681128587, + "owner_id": 56657 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_25}/{SIGNATURE}": { + "post": { + "tags": [ + "env_var" + ], + "summary": "json", + "operationId": "variable", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a variable, which is a named static value that is stored within a Stage.
A variable can be accessed from processes.

Modify

Method for updating variable title or short_name

Delete

Method for deleting a variable

List

Method for getting a variables list", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/env_var-create-request" + }, + { + "$ref": "#/components/schemas/env_var-modify-request" + }, + { + "$ref": "#/components/schemas/env_var-delete-request" + }, + { + "$ref": "#/components/schemas/env_var-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-23", + "modify": "#/components/schemas/modify-request-20", + "delete": "#/components/schemas/delete-request-17", + "list": "#/components/schemas/list-request-24" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "env_var", + "env_var_type": "secret", + "title": "My first variable", + "short_name": "firstvar", + "project_id": 372753, + "stage_id": 372755, + "value": "test", + "data_type": "raw", + "company_id": "i702619617", + "scopes": [ + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "env_var", + "obj_id": "608", + "title": "My first variable45", + "short_name": "firstvar3", + "project_id": 372753, + "stage_id": 372755, + "env_var_type": "secret", + "scopes": [ + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ] + } + ] + } + }, + "check": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "env_var", + "obj_id": 611, + "project_id": 372753, + "stage_id": 372755 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "env_var", + "company_id": "i702619617", + "project_id": 372753, + "stage_id": 372755 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/env_var-create-response" + }, + { + "$ref": "#/components/schemas/env_var-modify-response" + }, + { + "$ref": "#/components/schemas/env_var-delete-response" + }, + { + "$ref": "#/components/schemas/env_var-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-23", + "ok (modify)": "#/components/schemas/modify-response-20", + "ok (delete)": "#/components/schemas/delete-response-17", + "ok (list)": "#/components/schemas/list-response-24", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj_id": 8, + "proc": "ok", + "obj": "env_var", + "fingerprints": [ + { + "algo": "md5", + "value": "09:8F:6B:27:B4:F6" + }, + { + "algo": "sha256", + "value": "9F:86:F0:0A:08" + } + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "env_var", + "obj_id": 608, + "fingerprints": [ + { + "algo": "md5", + "value": "09:8F:6B:27:B4:F6" + }, + { + "algo": "sha256", + "value": "9F:86:F0:0A:08" + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "env_var", + "obj_id": 611 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "is_favorite": false, + "is_owner": true, + "owner_id": 79344, + "owner_name": "user5", + "owner_login": "6672e1af96fc3b1807006a27", + "obj_id": 8576, + "obj_type": "env_var", + "env_var_type": "visible", + "data_type": "json", + "title": "Var", + "description": "test", + "short_name": "envjson", + "company_id": "i738314881", + "project_id": 810414, + "project_title": "Project_1725888915983", + "project_short_name": "project-1725888915645", + "stage_id": 810415, + "stage_title": "Stage_1725888916276", + "stage_short_name": "stage-1725888915645", + "create_time": 1725888935, + "change_time": 1725888935, + "uuid": "496256b1-9c66-4cc0-8b39-4d89b2b7ca00", + "scopes": [ + { + "type": "set_param", + "fields": [ + "extra" + ] + }, + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ], + "value": "{\"key\":\"NGKNt9e5Uo2pzPyBoYTtPYFSW8e5l9lzVyRSTI5RhDX1sD.test\"}", + "fingerprints": [ + { + "algo": "md5", + "value": "E3:6F:63:21:9D:6B:B7:DD:9F:6D:80:69:A0:41:C5:56" + }, + { + "algo": "sha256", + "value": "3B:E8:FD:74:BE:33:1D:5D:6E:60:2B:FE:B2:CB:6B:EE:24:E4:F3:7D:08:E3:6F:41:97:F9:6D:A3:E7:47:48:EF" + } + ], + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + }, + { + "is_favorite": false, + "is_owner": true, + "owner_id": 79344, + "owner_name": "user5", + "owner_login": "6672e1af96fc3b1807006a27", + "obj_id": 8574, + "obj_type": "env_var", + "env_var_type": "secret", + "data_type": "raw", + "title": "Var", + "description": "test", + "short_name": "envraw", + "company_id": "i738314881", + "project_id": 810414, + "project_title": "Project_1725888915983", + "project_short_name": "project-1725888915645", + "stage_id": 810415, + "stage_title": "Stage_1725888916276", + "stage_short_name": "stage-1725888915645", + "create_time": 1725888918, + "change_time": 1725888918, + "uuid": "76c5bc88-4827-4904-966a-a6f64e2f3f93", + "scopes": [ + { + "type": "set_param", + "fields": [ + "extra" + ] + } + ], + "value": null, + "fingerprints": [ + { + "algo": "md5", + "value": "9C:53:5D:F5:D3:8D:6E:2E:5C:9C:ED:13:70:6D:5E:FA" + }, + { + "algo": "sha256", + "value": "65:F4:03:29:4D:0A:9C:8B:30:87:35:23:BD:BB:27:A7:EC:31:D2:E8:4C:57:6F:10:EC:A0:D9:11:16:0A:16:FC" + } + ], + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_26}/{SIGNATURE}": { + "post": { + "tags": [ + "folder_branch" + ], + "summary": "json", + "operationId": "folder_branch", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for get Folder nesting structure
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/folder_branch-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-17" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 210032, + "owner_id": 27074, + "type": "list", + "obj": "folder_branch" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/folder_branch-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-17", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder_branch", + "obj_id": 210032, + "list": [ + { + "parent_id": 0, + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 9, + "is_owner": false, + "owner_id": 5381, + "owner_name": "First_Name Last_Name", + "owner_login": "380991234567", + "obj_id": 218835, + "obj_type": "folder", + "create_time": 1649940895, + "change_time": 1649940895, + "title": "COR-6332-filter/map", + "description": "", + "company_id": null, + "project_id": 0, + "stage_id": 0, + "owner_group_id": 14537, + "version": null + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_27}/{SIGNATURE}": { + "post": { + "tags": [ + "folder" + ], + "summary": "json", + "operationId": "folder", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Folder.

Modify

Method for updating Folder's name and description.

Link

Method for linking a Folder to an API Key, User or Group (share access - or remove previously shared access);
also including the \"Move to\" operation (moving a Process / State diagram, Dashboard, Database instance or a Folder to another Folder).
Note that sharing access with a user not in the company is done using another method — obj = invite, type = create (you can see an example there).

List

Method for getting a list of Folder objects;
also for getting a list of Users and Groups that have access to the Folder (when the request parameter 'list_obj' = \"group\").

Show

Method for getting Folder information.

Favorite

Method for adding a Folder to the favorites list - or deleting it from the favorites list.

Delete

Method for moving a Folder to Trash (switch Folder status to deleted).

Destroy

Method for deleting a Folder (completely deleting it in Trash - Delete forever).

Restore

Method for restoring a Folder from Trash (switch Folder status from deleted to active).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/folder-create-request" + }, + { + "$ref": "#/components/schemas/folder-modify-request" + }, + { + "$ref": "#/components/schemas/folder-link-request" + }, + { + "$ref": "#/components/schemas/folder-list-request" + }, + { + "$ref": "#/components/schemas/folder-show-request" + }, + { + "$ref": "#/components/schemas/folder-favorite-request" + }, + { + "$ref": "#/components/schemas/folder-delete-request" + }, + { + "$ref": "#/components/schemas/folder-destroy-request" + }, + { + "$ref": "#/components/schemas/folder-restore-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-12", + "modify": "#/components/schemas/modify-request-11", + "link": "#/components/schemas/link-request-7", + "list": "#/components/schemas/list-request-15", + "show": "#/components/schemas/show-request-10", + "favorite": "#/components/schemas/favorite-request-6", + "delete": "#/components/schemas/delete-request-11", + "destroy": "#/components/schemas/destroy-request-7", + "restore": "#/components/schemas/restore-request-7" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "test3", + "description": "", + "folder_id": 0, + "obj": "folder", + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "title": "test4", + "description": null, + "type": "modify", + "obj": "folder", + "obj_id": 296136 + } + ] + } + }, + "link": { + "summary": "link (access)", + "value": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_id": 296137, + "obj_to": "user", + "obj_to_id": 31913, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "moving": { + "summary": "link (moving)", + "value": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_type": "conv", + "obj_id": 789868, + "folder_id": 287391, + "parent_id": 210032 + } + ] + } + }, + "unlink": { + "summary": "link (delete access)", + "value": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_id": 296137, + "obj_to": "user", + "obj_to_id": 27201, + "privs": [] + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 210032, + "sort": "date", + "order": "asc", + "type": "list", + "obj": "folder", + "list_obj": "group" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "obj_id": 51952, + "type": "show", + "obj": "folder" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "folder", + "obj_id": 296137, + "favorite": true, + "company_id": "i848211059" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/folder-create-response" + }, + { + "$ref": "#/components/schemas/folder-modify-response" + }, + { + "$ref": "#/components/schemas/folder-link-response" + }, + { + "$ref": "#/components/schemas/folder-list-response" + }, + { + "$ref": "#/components/schemas/folder-list-response-group" + }, + { + "$ref": "#/components/schemas/folder-show-response" + }, + { + "$ref": "#/components/schemas/folder-favorite-response" + }, + { + "$ref": "#/components/schemas/folder-delete-response" + }, + { + "$ref": "#/components/schemas/folder-destroy-response" + }, + { + "$ref": "#/components/schemas/folder-restore-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-12", + "ok (modify)": "#/components/schemas/modify-response-11", + "ok (link)": "#/components/schemas/link-response-7", + "ok (list objects)": "#/components/schemas/list-response-15", + "ok (list group)": "#/components/schemas/list-response-group", + "ok (show)": "#/components/schemas/show-response-11", + "ok (favorite)": "#/components/schemas/favorite-response-6", + "ok (delete)": "#/components/schemas/delete-response-11", + "ok (destroy)": "#/components/schemas/destroy-response-7", + "ok (restore)": "#/components/schemas/restore-response-7", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 296136 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 296136 + } + ] + } + }, + "link": { + "summary": "link (access)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "folder", + "obj_id": 296137, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "link" + } + ] + } + }, + "moving": { + "summary": "link (moving)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 789868, + "obj_to_type": "folder", + "obj_to_id": 287391, + "obj_to_title": "test789", + "action_type": "move", + "from_folder": 210032, + "to_folder": 287391, + "from_folder_name": "test", + "to_folder_name": "test789", + "user_id": 27074, + "user_name": "First_Name Last_Name" + } + ] + } + }, + "unlink": { + "summary": "link (delete access)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "folder", + "obj_id": 296137, + "obj_to_type": "user", + "obj_to_id": 27201, + "obj_to_title": "test", + "action_type": "unlink" + } + ] + } + }, + "list": { + "summary": "list (objects)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 210032, + "proc": "ok", + "parent_folder_id": 0, + "parent_folder_title": "Root folder", + "list": [ + { + "is_shared": false, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 0, + "is_owner": true, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 303624, + "obj_type": "folder", + "create_time": 1660300990, + "change_time": 1660300990, + "title": "test23", + "description": "", + "company_id": null, + "project_id": 0, + "stage_id": 0, + "owner_group_id": 56079, + "version": null, + "parent_id": 487763 + } + ] + } + ] + } + }, + "list_group": { + "summary": "list (group)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 210032, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 30978, + "login_id": 30978, + "title": "Aria Stark", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "aria.stark@corezoid.com" + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 51952, + "title": "ПИН", + "obj_type": 0, + "parent_obj_id": 51948, + "parent_obj_type": "folder" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 296137, + "obj": "folder" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 313726, + "proc": "ok" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 313726, + "obj_type": "folder" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 313726, + "obj": "folder", + "parent_folder_id": 313725 + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_28}/{SIGNATURE}": { + "post": { + "tags": [ + "git_call" + ], + "summary": "json", + "operationId": "git_call", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Create
Method for creating basic settings of a Git Call node

Compile
Method for compiling basic settings of a Git Call node

Get
Method for showing basic settings of a Git Call node

load
Method for loading code to a server

Clone
Method for cloning Git Call basic settings from one node to another

Reset
Method for SSH key resetting", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/git_call-create-request" + }, + { + "$ref": "#/components/schemas/git_call-compile-request" + }, + { + "$ref": "#/components/schemas/git_call-get-request" + }, + { + "$ref": "#/components/schemas/git_call-load-request" + }, + { + "$ref": "#/components/schemas/git_call-clone-request" + }, + { + "$ref": "#/components/schemas/git_call-reset-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-20", + "compile": "#/components/schemas/compile-request", + "get": "#/components/schemas/get-request-5", + "load": "#/components/schemas/load-request", + "clone": "#/components/schemas/clone-request", + "reset": "#/components/schemas/reset-request-2" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "git_call", + "obj_type": "function_build", + "version": 2, + "conv_id": 1049340, + "node_id": "63a470de094bab6439004a92", + "obj_id": "ry78ws22w469s3", + "lang": "js", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "repo": "https://github.com/test/test.git", + "commit": "main", + "script": "" + } + ] + } + }, + "compile": { + "summary": "compile", + "value": { + "ops": [ + { + "node_id": "63a470de094bab6439004a92", + "conv_id": 1049340, + "lang": "js", + "repo": "https://github.com/test/test.git", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "script": "", + "commit": "main", + "type": "compile", + "version": 2, + "obj": "git_call", + "obj_type": "function" + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "git_call", + "obj_type": "function", + "conv_id": 1049340, + "node_id": "63a470de094bab6439004a92", + "version": 2 + } + ] + } + }, + "load": { + "summary": "load", + "value": { + "ops": [ + { + "type": "load", + "obj": "git_call", + "conv_id": 1049341, + "version": 2, + "obj_type": "function", + "node_id": "63a474c6094bab6439004a9b", + "lang": "js", + "repo": "", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "script": "", + "commit": "" + } + ] + } + }, + "clone": { + "summary": "clone", + "value": { + "ops": [ + { + "type": "clone", + "obj": "git_call", + "conv_id": 1049340, + "from_node_id": "63a470de094bab6439004a92", + "to_node_id": "63a4709756167c68f4004a9f", + "version": 2 + } + ] + } + }, + "reset": { + "summary": "reset", + "value": { + "ops": [ + { + "type": "reset", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "node_id": "63a470de094bab6439004a92", + "conv_id": 1049340 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/git_call-create-response" + }, + { + "$ref": "#/components/schemas/git_call-compile-response" + }, + { + "$ref": "#/components/schemas/git_call-get-response" + }, + { + "$ref": "#/components/schemas/git_call-load-response" + }, + { + "$ref": "#/components/schemas/git_call-clone-response" + }, + { + "$ref": "#/components/schemas/git_call-reset-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-20", + "ok (compile)": "#/components/schemas/compile-response", + "ok (get)": "#/components/schemas/get-response-5", + "ok (load)": "#/components/schemas/load-response", + "ok (clone)": "#/components/schemas/clone-response", + "ok (reset)": "#/components/schemas/reset-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "git_call", + "obj_type": "function_build", + "obj_id": "ry78ws22w469s3", + "version": 2, + "proc": "ok" + } + ] + } + }, + "compile": { + "summary": "compile", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2 + } + ] + } + }, + "getFunction": { + "summary": "get (function)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2, + "lang": "js", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "repo": "https://github.com/fresco117/test.git", + "commit": "main", + "script": "" + } + ] + } + }, + "getFunction_build": { + "summary": "get (function_build)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function_build", + "obj_id": "ry78ws22w4d69s3", + "version": 2, + "build_status": "done" + } + ] + } + }, + "getSsh_key": { + "summary": "get (ssh_key)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDNowYVpf0dceT3mOyFySheHUw3CcOFKKKRDDMSrF6s42WV0pp0v4y+J65LYzxlVskQ934CzU8DOpQG6PzXnmDM4tm05p4iSkvQWib+Im3P69oDSE2VJNXh2eqto8GYa3sgx15RbRAV3BrW4mi0hnhSnTKNsCq5ODvTRP/AN/S1nIVWJL2CBpXFij/Fkk93L5Eqi1AzrDdUuYmiqXzyDqD5WqCv5SYyfM7cHzfVNFUheStMkubL+O9CIg7+EbJGKAASPE3EUBvS57NIPrcQ6ecsK9+QmMwGGBbqsGRjmKKMnobEMFZzR9uhwrUkA8K+YG59+VU59nFkKN6dGS63ACVD\n" + } + ] + } + }, + "load": { + "summary": "load", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2 + } + ] + } + }, + "clone": { + "summary": "clone", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + } + }, + "reset": { + "summary": "reset", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDxKPyqHLSfNQ6Uj3t9vcdQ2onV+HFMD6tMI60Cb99N+RyATj1LodjcJLRHJhpapqYCbndHidkF7prs+7wHW396jmE+U5/PCRfkgGHYRlpDCcmc6Cw6UWl/7lLjCCpJG+tyD87lkXCpjyephSNjYPyVP3iw+h2iOtdzvRH6SmkVqmC78yKZVp00qkNQG52TWUI7MYuwjaosjjYRKLU1Pd2anL7C9GUaUaInAabCqHV7zVay+60wbGOw/pm0+CuWl4ixAcpDMH1iNxMcRLIwiuIV9O+YEJ94dnM7Cfcl4P3gLMUb1wWR6EKFBvL28JfVsOlPlrHwBbi3UpIDzcVvOqdP\n" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_29}/{SIGNATURE}": { + "post": { + "tags": [ + "global_counters" + ], + "summary": "json", + "operationId": "globalCounters", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Counters of instance parameters: users, conveyors, operations, state changes", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/global_counters-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-17" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "obj": "global_counters", + "type": "show" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/global_counters-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-18", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "request_proc": "ok", + "ops": [ + { + "type": "monitor_show", + "obj": "main", + "obj_id": 0, + "proc": "ok", + "list": [ + { + "obj": "users", + "count": 222 + }, + { + "obj": "conveyors", + "count": 196004 + }, + { + "obj": "operations", + "count": 2849826848 + }, + { + "obj": "tacts", + "count": 8696682558 + } + ] + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_30}/{SIGNATURE}": { + "post": { + "tags": [ + "group" + ], + "summary": "json", + "operationId": "group", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a new User Group.

Modify

Method for modifying a User Group.

List

if \"list_obj\" = \"user\"
\n Method shows all users in a User Group;
\n
if \"list_obj\" = \"conv\"
\n Method shows all processes attached to a User Group.
\n

Delete

Method for deleting a User Group.

Restore

Method for restoring a User Group.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/group-create-request" + }, + { + "ref": "#/components/schemas/group-modify-request" + }, + { + "ref": "#/components/schemas/group-list-request" + }, + { + "ref": "#/components/schemas/group-delete-request" + }, + { + "ref": "#/components/schemas/group-restore-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-5", + "modify": "#/components/schemas/modify-request-5", + "list": "#/components/schemas/list-request-7", + "delete": "#/components/schemas/delete-request-5", + "restore": "#/components/schemas/restore-request-3" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "test-group", + "type": "create", + "obj": "group", + "obj_type": "admins" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "title": "test-group1", + "type": "modify", + "obj": "group", + "obj_id": 70800, + "obj_type": "admins", + "status": "actived" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "group", + "obj_id": 70800, + "list_obj": "user" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "group", + "obj_id": 70800 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "group", + "obj_id": 70800 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/group-create-response" + }, + { + "ref": "#/components/schemas/group-modify-response" + }, + { + "ref": "#/components/schemas/group-list-response-list" + }, + { + "ref": "#/components/schemas/group-list-response-list_obj-conv" + }, + { + "ref": "#/components/schemas/group-delete-response" + }, + { + "ref": "#/components/schemas/group-restore-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-5", + "ok (modify)": "#/components/schemas/modify-response-5", + "ok (list(\"list_obj\" = \"user\"))": "#/components/schemas/list-response-7", + "ok (list(\"list_obj\" = \"conv\"))": "#/components/schemas/list-response-list_obj-conv", + "ok (delete)": "#/components/schemas/delete-response-5", + "ok (restore)": "#/components/schemas/restore-response-3", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + } + }, + "list(\"list_obj\" = \"user\")": { + "summary": "list(\"list_obj\" = \"user\")", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "group", + "obj_id": 70800, + "owner_id": 19766, + "owner_name": "Owner", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 25399, + "title": "User", + "logins": [ + { + "type": "google", + "login": "user@gmail.com" + } + ] + } + ] + } + ] + } + }, + "list(\"list_obj\" = \"conv\")": { + "summary": "list(\"list_obj\" = \"conv\")", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "group", + "obj_id": 56930, + "proc": "ok", + "list": [ + { + "obj_id": 347700, + "title": "New object", + "description": "", + "status": "active" + }, + { + "obj_id": 347357, + "title": "New object1", + "description": "", + "status": "active" + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "restore", + "obj": "group", + "obj_id": 70800 + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_32}/{SIGNATURE}": { + "post": { + "tags": [ + "history" + ], + "summary": "json", + "operationId": "history", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Using this method, you can get: \n - `objects history` (changes of a specific object)\n - `operations history` (user or company log, available only for the admin/superadmin role)", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/history-list-request-objects" + }, + { + "$ref": "#/components/schemas/history-list-request-operations" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list (objects)": "#/components/schemas/list-request-objects", + "list (operations)": "#/components/schemas/list-request-operations" + } + } + } + } + } + }, + "examples": { + "objects_history": { + "summary": "objects history", + "value": { + "ops": [ + { + "type": "list", + "obj": "history", + "obj_id": 1069599, + "obj_type": "conv", + "limit": 10, + "offset": 0 + } + ] + } + }, + "operations_history": { + "summary": "operations history", + "value": { + "ops": [ + { + "type": "list", + "obj": "history", + "company_id": "i702619617", + "user_id": 25130, + "list_type": "create", + "list_obj": "folder", + "start": 1666773971, + "end": 1666906264, + "limit": 10, + "offset": 0 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/history-list-response-objects" + }, + { + "$ref": "#/components/schemas/history-list-response-operations" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (objects)": "#/components/schemas/list-response-objects", + "ok (operations)": "#/components/schemas/list-response-operations", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "objects_history": { + "summary": "objects history", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "history", + "obj_id": 1169599, + "obj_type": "conv", + "list": [ + { + "id": 47202572, + "create_time": 1666855109, + "user_id": 80089, + "user_name": "Jane Doe", + "company_id": "i790933068", + "obj": "node", + "type": "delete", + "request": {}, + "response": {}, + "severity": "INFO" + } + ] + } + ] + } + }, + "operations_history": { + "summary": "operations history", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "history", + "list": [ + { + "id": 35107234, + "create_time": 1666787733, + "user_id": 25130, + "user_name": "Jane Doe", + "login": "email@email.com", + "company_id": "i702619617", + "obj": "folder", + "type": "create", + "obj_type": "folder", + "obj_id": 372757, + "obj_name": "folderinka", + "obj_to": null, + "obj_to_id": null, + "obj_to_name": null, + "request": {}, + "response": {} + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_33}/{SIGNATURE}": { + "post": { + "tags": [ + "instance" + ], + "summary": "json", + "operationId": "instance", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a connection to a Database.

Modify

Method for editing Database connection settings.

List

Method for getting a list of users/groups/api-keys that have access to an Instance.

Show

Method for getting instance information.

Link

Method for linking an Instance to an Api-Key/Group/User (share access).

Favorite

Method for adding an Instance to the favorite list - or removing from the favorite list.

Check

Method for testing a Database connection.

Delete

Method for moving an Instance to Trash (switch Instance status to deleted).

Restore

Method for restoring an Instance from Trash (switch Instance status to active).

Destroy

Method for deleting (irreversibly deleting) an Instance in the recycle bin (Trash).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/instance-create-request" + }, + { + "ref": "#/components/schemas/instance-modify-request" + }, + { + "ref": "#/components/schemas/instance-list-request" + }, + { + "ref": "#/components/schemas/instance-show-request" + }, + { + "ref": "#/components/schemas/instance-link-request" + }, + { + "$ref": "#/components/schemas/instance-favorite-request" + }, + { + "$ref": "#/components/schemas/instance-check-request" + }, + { + "$ref": "#/components/schemas/instance-delete-request" + }, + { + "$ref": "#/components/schemas/instance-restore-request" + }, + { + "$ref": "#/components/schemas/instance-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-6", + "modify": "#/components/schemas/modify-request-6", + "list": "#/components/schemas/list-request-8", + "show": "#/components/schemas/show-request-5", + "link": "#/components/schemas/link-request-3", + "favorite": "#/components/schemas/favorite-request-3", + "check": "#/components/schemas/check-request", + "delete": "#/components/schemas/delete-request-6", + "restore": "#/components/schemas/restore-request-4", + "destroy": "#/components/schemas/destroy-request-3" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "test_db", + "description": "", + "folder_id": 0, + "obj": "instance", + "instance_type": "db_call", + "data": { + "driver": "postgres", + "database": "database", + "host": "https://example.com", + "port": "5432", + "username": "username", + "password": "123456789", + "ssl": false, + "timeoutMs": "3000" + }, + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "obj": "instance", + "type": "modify", + "obj_id": 39171, + "instance_type": "db_call", + "data": { + "driver": "postgres", + "database": "database", + "host": "https://example.com", + "port": "5432", + "username": "username", + "password": "12345678", + "ssl": false, + "timeoutMs": "5000" + } + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 39171, + "obj": "instance", + "type": "list", + "list_obj": "group" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "instance", + "obj_id": 39171 + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "type": "link", + "obj": "instance", + "obj_id": 39171, + "obj_to": "user", + "obj_to_id": 25399, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "instance", + "obj_id": 39171, + "favorite": true + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "ops": [ + { + "title": "test_db", + "description": "", + "type": "check", + "obj": "instance", + "instance_type": "db_call", + "data": { + "driver": "postgres", + "host": "https;//example.com", + "port": "5432", + "username": "username", + "password": "12345678", + "ssl": false, + "database": "database", + "timeoutMs": "5000" + } + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "instance", + "obj_id": 39171 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "instance", + "obj_id": 39171 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "instance", + "obj_id": 39171 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/instance-create-response" + }, + { + "$ref": "#/components/schemas/instance-modify-response" + }, + { + "$ref": "#/components/schemas/instance-list-response" + }, + { + "$ref": "#/components/schemas/instance-show-response" + }, + { + "$ref": "#/components/schemas/instance-link-response" + }, + { + "$ref": "#/components/schemas/instance-favorite-response" + }, + { + "$ref": "#/components/schemas/instance-check-response" + }, + { + "$ref": "#/components/schemas/instance-delete-response" + }, + { + "$ref": "#/components/schemas/instance-restore-response" + }, + { + "$ref": "#/components/schemas/instance-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-6", + "ok (modify)": "#/components/schemas/modify-response-6", + "ok (list)": "#/components/schemas/list-response-8", + "ok (show)": "#/components/schemas/show-response-6", + "ok (link)": "#/components/schemas/link-response-3", + "ok (favorite)": "#/components/schemas/favorite-response-3", + "ok (check)": "#/components/schemas/check-response", + "ok (delete)": "#/components/schemas/delete-response-6", + "ok (restore)": "#/components/schemas/restore-response-4", + "ok (destroy)": "#/components/schemas/destroy-response-3", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "instance_type": "db_call", + "obj_id": 39171 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "instance_type": "db_call", + "obj_id": 39171 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "obj_id": 64467, + "favorite": true, + "list_obj": "group", + "list": [ + { + "obj_id": 150159, + "obj": "group", + "title": "2354", + "obj_type": "admins", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "obj_status": "actived" + }, + { + "obj": "user", + "obj_id": 15, + "title": "gottabad", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "obj_id": 39171, + "title": "test_db", + "description": "", + "create_time": 1663833372, + "change_time": 1663840200, + "instance_type": "db_call", + "status": "active", + "company_id": null, + "data": { + "driver": "postgres", + "host": "https://example.com", + "port": 5432, + "username": "username", + "password": "12345678", + "database": "database", + "timeoutMs": 5000, + "ssl": false + }, + "folder_id": 0, + "owner_name": "owner_name", + "owner_login": "ownerlogin@gmail.com", + "parent_obj_id": 0, + "parent_obj_type": "folder" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "instance", + "obj_id": 39171, + "obj_to_type": "user", + "obj_to_id": 12345, + "obj_to_title": "Title", + "action_type": "link" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj": "instance" + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "instance", + "obj_id": 39171, + "proc": "ok" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj": "instance", + "parent_folder_id": 0 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj_type": "instance" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_35}/{SIGNATURE}": { + "post": { + "tags": [ + "invite" + ], + "summary": "json", + "operationId": "invite", + "description": "Create
Method for inviting a new user to a company and sharing an object with that user.
Method is not allowed with the box_solution = true parameter setting.

\nConfirm
Method for confirming/accepting a new user invitation to a company. [Available for another endpoint](#tag/confirm_invite).

\nDelete
Method for deleting an unaccepted invitation.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/invite-create-request" + }, + { + "$ref": "#/components/schemas/invite-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-14", + "delete": "#/components/schemas/delete-request-13" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "invite", + "login": "user.email@corezoid.com", + "login_type": "google", + "company_id": "i848211059", + "link_to_obj": "stage", + "link_to_obj_id": 316139, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "invite", + "hash": "fbd2d5365a124a77fe38f1673d0829196502b3df", + "company_id": "i702619617" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/invite-create-response" + }, + { + "$ref": "#/components/schemas/invite-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-14", + "ok (delete)": "#/components/schemas/delete-response-13", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "createAPI": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "invite", + "url": "https://admin-pre.corezoid.com/api/2/plugins/invite/e2368c32ddf73eecef8e17ece32f1c6dda2fff5", + "proc": "ok" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_37}/{SIGNATURE}": { + "post": { + "tags": [ + "node" + ], + "summary": "json", + "operationId": "node", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Node.

Modify

Method for updating Node parameters.

List

Method for getting a list of tasks for a Node.

Show

Method for getting information on a Node.

Delete

Method for deleting a Node.

Reset

Method for resetting a Final Node counter.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/node-create-request" + }, + { + "ref": "#/components/schemas/node-modify-request" + }, + { + "ref": "#/components/schemas/node-list-request" + }, + { + "ref": "#/components/schemas/node-show-request" + }, + { + "ref": "#/components/schemas/node-delete-request" + }, + { + "ref": "#/components/schemas/node-reset-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-4", + "modify": "#/components/schemas/modify-request-4", + "list": "#/components/schemas/list-request-5", + "show": "#/components/schemas/show-request-4", + "delete": "#/components/schemas/delete-request-4", + "reset": "#/components/schemas/reset-request" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "id": "3403c54d-3b17-f75f-deea-f5c6fee4c38e", + "type": "create", + "obj": "node", + "conv_id": 789846, + "title": "Name", + "description": "Description", + "obj_type": 0, + "version": 1662369848 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "node", + "obj_id": "6315c04e094bab6d1300d57e", + "conv_id": 789846, + "title": "test", + "description": "test description", + "obj_type": 0, + "logics": [ + { + "to_node_id": "6316f5c5094bab1707005ac9", + "type": "go_if_const", + "conditions": [ + { + "param": "foo", + "const": "bar", + "fun": "eq", + "cast": "string" + } + ] + }, + { + "type": "go", + "to_node_id": "62b41bdd56167c23af018057" + } + ], + "semaphors": [], + "position": [ + 520, + 204 + ], + "extra": { + "modeForm": "expand", + "icon": "" + }, + "version": 1662369848 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "limit": 10, + "offset": 0, + "type": "list", + "obj": "node", + "company_id": "i260836082", + "conv_id": 880416, + "obj_id": "6304cd2356167c626500036c", + "work_user_id": 19766, + "sort": "ASC", + "filters": [ + { + "name": "ref", + "value": "1", + "fun": "eq" + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "node", + "obj_id": "63199a0b56167c0148001712", + "conv_id": 881581, + "company_id": "i260836082" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "node", + "company_id": "i260836082", + "obj_id": "62de4889094bab69e6001c53", + "conv_id": 826283, + "version": 1658734725 + } + ] + } + }, + "reset": { + "summary": "reset", + "value": { + "ops": [ + { + "type": "reset", + "conv_id": 881581, + "obj": "node", + "obj_id": "63060854094bab7c46001dab", + "company_id": "i260836082" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/node-create-response" + }, + { + "ref": "#/components/schemas/node-modify-response" + }, + { + "ref": "#/components/schemas/node-list-response" + }, + { + "ref": "#/components/schemas/node-show-response" + }, + { + "ref": "#/components/schemas/node-delete-response" + }, + { + "ref": "#/components/schemas/node-reset-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-4", + "ok (modify)": "#/components/schemas/modify-response-4", + "ok (list)": "#/components/schemas/list-response-5", + "ok (show)": "#/components/schemas/show-response-5", + "ok (delete)": "#/components/schemas/delete-response-4", + "ok (reset)": "#/components/schemas/reset-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "3403c54d-3b17-f75f-deea-f5c6fee4c38e", + "proc": "ok", + "obj": "node", + "obj_id": "6315c04e094bab6d1300d57e", + "version": 1662369848 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 789846, + "obj_id": "6315c04e094bab6d1300d57e" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "node", + "obj_id": "6304cd2356167c626500036c", + "count": 12, + "count_created": 12, + "count_processing": 0, + "count_delayed": 0, + "proc": "ok", + "list": [ + { + "data": { + "__source_origin__": { + "filename": "1144692_conv_64217c26094bab6fa00052d2_1679916520.csv", + "ip": "127.0.0.1" + }, + "__user_id__": 25130, + "param1": 1, + "param2": 2 + }, + "obj": "task", + "obj_id": "6346b6f856167c13a1001941", + "ref": "1", + "status": "processed", + "user_id": 19766, + "create_time": 1665578744, + "change_time": 1665578744, + "node_prev_id": "6304cd2356167c626500036b" + } + ] + } + ] + } + }, + "show": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "node", + "obj_id": "63199a0b56167c0148001712", + "title": "", + "description": "", + "logics": [], + "semaphors": [ + { + "type": "time", + "value": 1800, + "dimension": "min", + "to_node_id": "63060854094bab7c46001dab" + } + ], + "count": 0, + "obj_type": 0 + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": "62de4889094bab69e6001c53", + "proc": "ok" + } + ] + } + }, + "reset": { + "summary": "reset", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "node", + "obj_id": "63060854094bab7c46001dab" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_38}/{SIGNATURE}": { + "post": { + "tags": [ + "nodes" + ], + "summary": "json", + "operationId": "nodes", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting List of Nodes by pattern.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/nodes-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-6" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "nodes", + "pattern": "Test", + "conv_id": 909237 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/nodes-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-6", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "conv_id": "909237", + "description": "", + "id": "631eea6f56167c0148014b74", + "title": "Test", + "type": 0, + "status": 1 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_39}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_scheme" + ], + "summary": "json", + "operationId": "obj_scheme", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Get
Method for getting an object scheme.

Check
Method for checking an object scheme in Corezoid. The method is used for detecting the processes in a folder which have undeployed changes before exporting the folder. After detecting the processes, users can deploy these processes and retain the unsaved changes otherwise lost after the export.

", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via the Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme-get-request" + }, + { + "$ref": "#/components/schemas/obj_scheme-check-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "get": "#/components/schemas/get-request-6", + "check": "#/components/schemas/check-request-2" + } + } + } + } + } + }, + "examples": { + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "obj_scheme", + "obj_id": 1004237, + "obj_type": "conv" + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "ops": [ + { + "type": "check", + "obj": "obj_scheme", + "obj_id": 263144, + "obj_type": "folder" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme-get-response" + }, + { + "$ref": "#/components/schemas/obj_scheme-check-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (get)": "#/components/schemas/get-response-6", + "ok (check)": "#/components/schemas/check-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "obj_scheme", + "proc": "ok", + "scheme": [ + { + "obj_type": 1, + "obj_id": 1004237, + "parent_id": 372755, + "title": "1", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [ + { + "id": "65f98fcc094bab7ab30000ee", + "obj_type": 1, + "condition": { + "logics": [ + { + "to_node_id": "65f98fcc094bab7ab30000ef", + "type": "go" + } + ], + "semaphors": [] + }, + "title": "start", + "description": "", + "x": 0, + "y": 0, + "uuid": "f831ef9d-5605-4b34-9516-38653b6a36cc", + "extra": null, + "options": null + }, + { + "id": "65f98fcc094bab7ab30000ef", + "obj_type": 0, + "condition": { + "logics": [], + "semaphors": [ + { + "type": "time", + "value": 30, + "dimension": "sec", + "to_node_id": "65f98fcc094bab7ab30000f0" + } + ] + }, + "title": "process", + "description": "", + "x": 0, + "y": 0, + "uuid": "8c8eb7fe-cfe4-4f51-9b17-4cc57fb30e42", + "extra": null, + "options": null + }, + { + "id": "65f98fcc094bab7ab30000f0", + "obj_type": 2, + "condition": { + "logics": [], + "semaphors": [] + }, + "title": "final", + "description": "", + "x": 0, + "y": 0, + "uuid": "d43cba48-9a54-4a42-80ce-6186c90596d2", + "extra": null, + "options": null + } + ], + "web_settings": [ + [], + [] + ] + }, + "uuid": "ffc58fa2-69c6-4e08-ba88-636d0783c622" + } + ] + } + ] + } + }, + "check": { + "summary": "check", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "obj_scheme", + "proc": "ok" + } + ] + } + }, + "checkError": { + "summary": "check (error)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "The process with ID 1049340 has an uncommitted version" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_40}/{SIGNATURE}": { + "post": { + "tags": [ + "object" + ], + "summary": "json", + "operationId": "object", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Get
Method for getting object information to generate the correct URL
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/object-get-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "get": "#/components/schemas/get-request-2" + } + } + } + } + } + }, + "examples": { + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "object", + "obj_type": "conv", + "obj_id": 1046408 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/object-get-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (get)": "#/components/schemas/get-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "object": { + "summary": "object", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "project_id": 328948, + "stage_id": 328950, + "company_id": "i702619617", + "owner_id": 25130, + "parent_id": 328950, + "owner_title": "Jane Doe", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_41}/{SIGNATURE}": { + "post": { + "tags": [ + "objs" + ], + "summary": "json", + "operationId": "objs", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Common search method", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/objs-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-22" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "pattern": "api", + "obj": "objs", + "filter": "conv", + "limit": 31, + "company_id": "i702619617", + "type": "list" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/objs-list-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-22", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list (conv)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "conv", + "obj_id": 1020531, + "folder_id": 0, + "create_time": 1669121177, + "change_time": 1669123882, + "status": 1, + "conv_type": "process", + "is_owner": true, + "owner_name": "Daria Grek 2", + "owner_login": "darja.grek@corezoid.com", + "owner_id": 25130, + "title": "api_gw", + "description": "", + "company_id": "i702619617" + } + ] + } + ] + } + }, + "listUser": { + "summary": "list (user)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "user", + "obj_id": 37924, + "create_time": "undefined", + "status": 1, + "type": "api", + "owner_id": 25130, + "logins": [ + { + "login": "635f98b7094bab1444007d1a", + "obj_id": 38660, + "type": "api" + } + ], + "companies": [ + "i702619617" + ], + "title": "seven" + } + ] + } + ] + } + }, + "listCompany": { + "summary": "list (company)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "company", + "obj_id": "i69339591195", + "create_time": 1477059927, + "status": 1, + "title": "Test_offline" + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_43}/{SIGNATURE}": { + "post": { + "tags": [ + "owner" + ], + "summary": "json", + "operationId": "owner", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for changing an object owner", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/owner-modify-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "modify": "#/components/schemas/modify-request-13" + } + } + } + } + } + }, + "examples": { + "modify_id": { + "summary": "modify (id)", + "value": { + "ops": [ + { + "type": "modify", + "obj": "owner", + "obj_type": "folder", + "obj_id": 370260, + "obj_to_id": 27608, + "save_src_privs": true + } + ] + } + }, + "modify_login": { + "summary": "modify (login)", + "value": { + "ops": [ + { + "type": "modify", + "obj": "owner", + "obj_type": "folder", + "obj_id": 370260, + "obj_to_type": "google", + "obj_to_login": "email@gmail.com", + "save_src_privs": true + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/owner-modify-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (modify)": "#/components/schemas/modify-response-13", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "owner_id": 27608, + "owner_login": "email@gmail.com", + "owner_name": "Jane Doe" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_44}/{SIGNATURE}": { + "post": { + "tags": [ + "path_to_folder" + ], + "summary": "json", + "operationId": "path_to_folder", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting Folder parameters for show breadcrumbs navigation
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/path_to_folder-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-16" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "path_to_folder", + "obj_id": 659209, + "company_id": "i738314881", + "project_id": 659206 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/path_to_folder-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-16", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "path_to_folder", + "list": [ + { + "obj_id": 0, + "title": "Test company", + "company_id": "i738314881", + "privs": [], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853" + }, + { + "obj_id": 659206, + "title": "Project_1709105873799", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "project", + "description": "new", + "short_name": "project1709105873799" + }, + { + "obj_id": 659207, + "title": "production", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "stage", + "description": "new", + "short_name": "production", + "immutable": false + }, + { + "obj_id": 659209, + "title": "path_to_folder_1709105874311", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "folder", + "description": "folder" + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_46}/{SIGNATURE}": { + "post": { + "tags": [ + "project" + ], + "summary": "json", + "operationId": "project", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Project.

Modify

Method for modifying Project settings (title, description, short_name).

List

Method for getting a list of Project stages.

Link

Method for sharing a Project with a user.

Favorite

Method allows you to add a Project to favorites.

Delete

Method for moving a Project to the recycle bin (Trash).

Restore

Method for restoring a Project from the recycle bin (Trash).

Destroy

Method for deleting (irreversibly deleting) a Project from the recycle bin (Trash).

Show

Method for showing stages available to a user in a Project.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/project-create-request" + }, + { + "$ref": "#/components/schemas/project-modify-request" + }, + { + "$ref": "#/components/schemas/project-list-request" + }, + { + "$ref": "#/components/schemas/project-link-request" + }, + { + "$ref": "#/components/schemas/project-favorite-request" + }, + { + "$ref": "#/components/schemas/project-delete-request" + }, + { + "$ref": "#/components/schemas/project-restore-request" + }, + { + "$ref": "#/components/schemas/project-destroy-request" + }, + { + "$ref": "#/components/schemas/project-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-3", + "modify": "#/components/schemas/modify-request-3", + "list": "#/components/schemas/list-request-3", + "link": "#/components/schemas/link-request-2", + "favorite": "#/components/schemas/favorite-request-2", + "delete": "#/components/schemas/delete-request-3", + "restore": "#/components/schemas/restore-request-2", + "destroy": "#/components/schemas/destroy-request-2", + "show": "#/components/schemas/show-request-3" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "Test", + "description": "", + "company_id": "i260836082", + "obj": "project", + "short_name": "test", + "stages": [ + { + "title": "production", + "immutable": true + }, + { + "title": "develop", + "immutable": false + } + ], + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "title": "Test-1", + "description": null, + "short_name": "test", + "type": "modify", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 316469, + "sort": "title", + "order": "desc", + "company_id": "i260836082", + "obj": "project", + "type": "list" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "type": "link", + "obj": "project", + "obj_id": 316469, + "obj_to": "user", + "obj_to_id": 54321, + "is_need_to_notify": true, + "company_id": "i260836082", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "ops": [ + { + "type": "favorite", + "obj": "project", + "obj_id": 777333, + "company_id": "i260836082", + "favorite": true + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/project-create-response" + }, + { + "$ref": "#/components/schemas/project-modify-response" + }, + { + "$ref": "#/components/schemas/project-list-response" + }, + { + "$ref": "#/components/schemas/project-link-response" + }, + { + "$ref": "#/components/schemas/project-favorite-response" + }, + { + "$ref": "#/components/schemas/project-delete-response" + }, + { + "$ref": "#/components/schemas/project-restore-response" + }, + { + "$ref": "#/components/schemas/project-destroy-response" + }, + { + "$ref": "#/components/schemas/project-show-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-3", + "ok (modify)": "#/components/schemas/modify-response-3", + "ok (list)": "#/components/schemas/list-response-3", + "ok (link)": "#/components/schemas/link-response-2", + "ok (favorite)": "#/components/schemas/favorite-response-2", + "ok (delete)": "#/components/schemas/delete-response-3", + "ok (restore)": "#/components/schemas/restore-response-2", + "ok (destroy)": "#/components/schemas/destroy-response-2", + "ok (show)": "#/components/schemas/show-response-4", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469, + "stages": [ + 316470, + 316471 + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469 + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "i260836082", + "obj": "project", + "obj_id": 316469, + "proc": "ok", + "list": [ + { + "uniq_undeployed_versions": 0, + "uniq_undeployed_versions_detail": [], + "is_shared": false, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 0, + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner.login@corezoid.com", + "obj_id": 316471, + "obj_type": "stage", + "create_time": 1661846259, + "change_time": 1661846259, + "title": "develop", + "short_name": "develop", + "description": "", + "company_id": "i260836082", + "immutable": false, + "project_id": 316469, + "owner_group_id": 41213 + } + ] + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "project", + "obj_id": 316469, + "obj_to_type": "user", + "obj_to_id": 54321, + "obj_to_title": "Default User", + "action_type": "link" + } + ] + } + }, + "favorite": { + "summary": "favorite", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 777333, + "obj": "project" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469, + "obj_short_name": "test", + "stages": [ + { + "title": "production", + "obj_id": 316470, + "obj_short_name": "production" + } + ], + "parent_obj_id": 51948, + "parent_obj_type": "folder" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_47}/{SIGNATURE}": { + "post": { + "tags": [ + "projects" + ], + "summary": "json", + "operationId": "projects", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting a list of Company Projects.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/projects-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-4" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "company_id": "i260836082", + "type": "list", + "obj": "projects", + "sort": "title" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/projects-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-4" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "i260836082", + "obj": "projects", + "proc": "ok", + "list": [ + { + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 1, + "size": 1, + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner.login@corezoid.com", + "obj_id": 316469, + "obj_type": "project", + "create_time": 1661846259, + "change_time": 1661934023, + "title": "Test-1", + "description": "", + "company_id": "i260836082", + "short_name": "test", + "project_id": 316469, + "owner_group_id": 41213 + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_48}/{SIGNATURE}": { + "post": { + "tags": [ + "reg" + ], + "summary": "json", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": null, + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "confirm" + } + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "confirm" + }, + { + "$ref": "#/components/schemas/company-create-response-error" + } + ] + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_50}/{SIGNATURE}": { + "post": { + "tags": [ + "stage" + ], + "summary": "json", + "operationId": "stage", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Create
Method for creating a Stage.

Modify
Method for updating Stage params (title, short name, description, immutable).

Link
Method for sharing/unsharing a Stage;
Note that sharing access with a user not in the company uses another method — obj = invite, type = create — [there you can see example](#tag/invite).

List
Method for getting a list of Groups that have access to a Stage (the request parameter 'list_obj' = \"group\");
also for getting a list of undeployed processes (the request parameter 'list_obj' = \"uncommited\").

Show
Method for getting Stage information (parameters).

Delete
Method for moving a Stage to Trash (switch Stage status to the deleted).

Destroy
Method for deleting a Stage (irreversibly deleting from Trash - Delete forever).

Restore
Method for restoring a Stage from Trash (switch Stage status to the active).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/stage-create-request" + }, + { + "$ref": "#/components/schemas/stage-modify-request" + }, + { + "$ref": "#/components/schemas/stage-list-request" + }, + { + "$ref": "#/components/schemas/stage-show-request" + }, + { + "$ref": "#/components/schemas/stage-link-request" + }, + { + "$ref": "#/components/schemas/stage-delete-request" + }, + { + "$ref": "#/components/schemas/stage-restore-request" + }, + { + "$ref": "#/components/schemas/stage-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-13", + "modify": "#/components/schemas/modify-request-12", + "list": "#/components/schemas/list-request-18", + "show": "#/components/schemas/show-request-11", + "link": "#/components/schemas/link-request-8", + "delete": "#/components/schemas/delete-request-12", + "restore": "#/components/schemas/restore-request-8", + "destroy": "#/components/schemas/destroy-request-8" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "title": "New Stage", + "description": "", + "company_id": "332c5987-6e70-4c3a-9a2c-b88ddc05920d", + "obj": "stage", + "short_name": "new-stage", + "project_id": 591827, + "immutable": false, + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "title": "develop", + "description": null, + "project_id": 268659, + "short_name": "develop-test", + "immutable": false, + "type": "modify", + "obj": "stage", + "obj_id": 268661, + "company_id": "i848211059" + } + ] + } + }, + "list": { + "summary": "list", + "value": { + "ops": [ + { + "obj_id": 316139, + "obj": "stage", + "company_id": "i848211059", + "type": "list", + "list_obj": "group" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "stage", + "obj_id": 375503, + "project_id": 375501, + "company_id": "i848211059" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "type": "link", + "obj": "stage", + "obj_id": 316139, + "obj_to": "user", + "obj_to_id": 32510, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059", + "project_id": 268659 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/stage-create-response" + }, + { + "$ref": "#/components/schemas/stage-modify-response" + }, + { + "$ref": "#/components/schemas/stage-list-response" + }, + { + "$ref": "#/components/schemas/stage-show-response" + }, + { + "$ref": "#/components/schemas/stage-link-response" + }, + { + "$ref": "#/components/schemas/stage-delete-response" + }, + { + "$ref": "#/components/schemas/stage-restore-response" + }, + { + "$ref": "#/components/schemas/stage-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-13", + "ok (modify)": "#/components/schemas/modify-response-12", + "ok (list uncommited)": "#/components/schemas/list-response-uncommited", + "ok (list group)": "#/components/schemas/list-response-group-2", + "ok (list)": "#/components/schemas/list-response-18", + "ok (show)": "#/components/schemas/show-response-12", + "ok (link)": "#/components/schemas/link-response-8", + "ok (delete)": "#/components/schemas/delete-response-12", + "ok (restore)": "#/components/schemas/restore-response-8", + "ok (destroy)": "#/components/schemas/destroy-response-8", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "obj_id": 316139 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "obj_id": 268661 + } + ] + } + }, + "listUncommited": { + "summary": "list (list_obj = uncommited)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 268661, + "list_obj": "uncommited", + "proc": "ok", + "list": [ + { + "is_owner": false, + "owner_id": 56079, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 1006997, + "obj_type": "conv", + "conv_type": "process", + "title": "test2", + "folder_id": 268661, + "change_time": 1667478333 + } + ] + } + ] + } + }, + "listGroup": { + "summary": "list (list_obj = group)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 316139, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 32510, + "login_id": 32510, + "title": "key_test2", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "", + "is_invite": true, + "invite_hash": "eab06fde509de5a03512f64116ce4598d055bda8" + } + ] + } + ] + } + }, + "list": { + "summary": "list (list_obj not send)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 268661, + "proc": "ok", + "list": [ + { + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 1, + "size": 2, + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 313725, + "obj_type": "folder", + "create_time": 1661440431, + "change_time": 1661440431, + "title": "test", + "description": "", + "company_id": "i848211059", + "project_id": 268659, + "stage_id": 268661, + "owner_group_id": 56079, + "version": null + } + ] + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "uniq_undeployed_versions": 1, + "uniq_undeployed_versions_detail": [ + { + "obj_id": 1007000, + "obj_type": "conv", + "version": 1667522497 + } + ], + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 1, + "childs": 0, + "size": 1, + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 375503, + "obj_type": "stage", + "create_time": 1667522468, + "change_time": 1667522468, + "title": "develop", + "short_name": "develop", + "description": "", + "company_id": "i848211059", + "immutable": false, + "project_id": 375501, + "owner_group_id": 56079, + "parent_obj_id": 375501, + "parent_obj_type": "project" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "stage", + "obj_id": 316139, + "obj_to_type": "user", + "obj_to_id": 32510, + "obj_to_title": "test_key", + "action_type": "link" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 318305, + "proc": "ok" + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 318305, + "proc": "ok" + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 318305, + "obj_type": "stage" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_51}/{SIGNATURE}": { + "post": { + "tags": [ + "stat" + ], + "summary": "json", + "operationId": "stat", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for getting counters for tasks movement through nodes", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/stat-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-14" + } + } + } + } + } + }, + "examples": { + "show_onenode": { + "summary": "one node", + "value": { + "ops": [ + { + "node_id": "633d595456167c2a190000f6", + "start": 1666904400, + "end": 1666990799, + "interval": "hour", + "type": "show", + "obj": "stat", + "group": "time", + "company_id": "i702619617", + "conv_id": 973630, + "timestamp": false, + "timezone_offset": -180 + } + ] + } + }, + "show_allnodes": { + "summary": "all nodes", + "value": { + "ops": [ + { + "type": "show", + "obj": "stat", + "start": 1666773971, + "end": 1666956330, + "group": "all", + "interval": "minute", + "conv_id": 973630, + "node_ids": [ + "633d595456167c2a190000f6" + ] + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/stat-show-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-15", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show_onenode": { + "summary": "one node", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stat", + "node_id": "633d595456167c2a190000f6", + "title": "Final", + "group": "time", + "conv_id": 973630, + "dashboard_id": "undefined", + "data": [ + { + "date": "2022-10-28 11:00:00", + "in": 3, + "out": 0 + } + ] + } + ] + } + }, + "show_allnodes": { + "summary": "all nodes", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stat", + "group": "all", + "conv_id": 973630, + "dashboard_id": "undefined", + "data": [ + { + "id": "633d595456167c2a190000f6", + "title": "Final", + "in": 4, + "out": 0 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_52}/{SIGNATURE}": { + "post": { + "tags": [ + "statistics" + ], + "summary": "json", + "operationId": "statistics", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing the state or progress of the Download, Upload, and Copy operations", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/statistics-get-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "get": "#/components/schemas/get-request-9" + } + } + } + } + } + }, + "examples": { + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "statistics", + "action": "upload", + "obj_type": "obj_scheme", + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/statistics-get-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (get)": "#/components/schemas/get-response-9", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj": "statistics", + "proc": "ok", + "data": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj_id": 1104082, + "company_id": "i317686751", + "obj": "csv_upload", + "obj_type": "conv", + "ok": 6, + "err": 11, + "all": 17, + "progress": 100 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_53}/{SIGNATURE}": { + "post": { + "tags": [ + "sum_stat" + ], + "summary": "json", + "operationId": "sumstat", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing state or progress performing \"download\", \"upload\", \"copy\" operation", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/sum_stat-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-19" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "get", + "obj": "statistics", + "action": "upload", + "obj_type": "obj_scheme", + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/sum_stat-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-20", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj": "statistics", + "proc": "ok", + "data": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj_id": 1104082, + "company_id": "i317686751", + "obj": "csv_upload", + "obj_type": "conv", + "ok": 6, + "err": 11, + "all": 17, + "progress": 100 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_54}/{SIGNATURE}": { + "post": { + "tags": [ + "sys_stat" + ], + "summary": "json", + "operationId": "sysStat", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing Processes usage statistics", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/sys_stat-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-13" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "start": 1669033536, + "end": 1669638336, + "company_id": "i702619617", + "order_field": "opers", + "owner_id": 25130, + "conv_id": 1006996, + "type": "show", + "obj": "sys_stat", + "order_by": "DESC", + "limit": 10 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/sys_stat-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-14", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "conv_id": "undefined", + "data": [ + { + "conv_id": 1006996, + "conv_name": "api gateway xml", + "owner_id": 25130, + "owner_name": "Daria Grek", + "date": "-", + "opers": 38, + "tacts": 144, + "company_id": "i702619617", + "folder_id": 334308, + "traff": 0.03 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_55}/{SIGNATURE}": { + "post": { + "tags": [ + "task_history" + ], + "summary": "json", + "operationId": "taskHistory", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for getting history of a task movement through process nodes", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations.", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task_history-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-20" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "type": "list", + "obj": "task_history", + "conv_id": "973630", + "obj_id": "635fbae9094bab1444007eac" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task_history-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-20", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": "635fbae9094bab1444007eac", + "ref": "166721815235789", + "list": [ + { + "history_id": 8212422009, + "conv_id": 973630, + "node_id": "633d595456167c2a190000f5", + "node_prev_id": null, + "user_id": 25130, + "user_name": "Jane Doe", + "create_time_ms": 1667218153555, + "status": "created", + "data": null + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_56}/{SIGNATURE}": { + "post": { + "tags": [ + "task" + ], + "summary": "json", + "operationId": "task", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a Task.

Modify

Method for updating Task params.

Show

Method for searching for a Task by identifier or reference.

Delete

Method for deleting a Task.

Debug_step_next

Method for moving a Task to a next node in the Debug mode.

Debug_step_prev

Method for moving a Task to a previous node in the Debug mode.

Debug_step_goto

Method for moving a Task between nodes in the Debug mode.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task-create-request" + }, + { + "$ref": "#/components/schemas/task-modify-request" + }, + { + "$ref": "#/components/schemas/task-show-request" + }, + { + "$ref": "#/components/schemas/task-delete-request" + }, + { + "$ref": "#/components/schemas/task-step_next-request" + }, + { + "$ref": "#/components/schemas/task-step_prev-request" + }, + { + "$ref": "#/components/schemas/task-step_goto-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-2", + "modify": "#/components/schemas/modify-request-2", + "show": "#/components/schemas/show-request-2", + "delete": "#/components/schemas/delete-request-2", + "step_next": "#/components/schemas/step_next-request", + "step_prev": "#/components/schemas/step_prev-request", + "step_goto": "#/components/schemas/step_goto-request" + } + } + } + } + } + }, + "examples": { + "create-by-convId": { + "summary": "create(by conv_id)", + "value": { + "ops": [ + { + "type": "create", + "conv_id": 123456, + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678" + } + ] + } + }, + "create-by-alias": { + "summary": "create(by alias)", + "value": { + "ops": [ + { + "type": "create", + "obj_alias": "test_alias", + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678" + } + ] + } + }, + "create-by-stage-alias": { + "summary": "create(by stage alias)", + "value": { + "ops": [ + { + "type": "create", + "obj_alias": "test_alias", + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678", + "stage_id": 543678, + "project_id": 543677 + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "conv_id": 123098, + "obj": "task", + "company_id": "i543378975", + "data": { + "foo": "bar" + }, + "ref": "15989649323554" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj": "task", + "ref": "15989649323554", + "conv_id": 789846, + "company_id": "i260999999" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "task", + "conv_id": 234234, + "company_id": "i260999999", + "node_id": "g4342ij44goer09409w0e0мd", + "obj_id": "6304dd15094bab211e00042c" + } + ] + } + }, + "step_next": { + "summary": "step_next", + "value": { + "ops": [ + { + "conv_id": 881581, + "type": "step_next", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "630777e056167c6ff4004124" + } + ] + } + }, + "step_prev": { + "summary": "step_prev", + "value": { + "ops": [ + { + "conv_id": 881581, + "type": "step_prev", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "6308beef094bab7823001f16" + } + ] + } + }, + "step_goto": { + "summary": "step_goto", + "value": { + "ops": [ + { + "conv_id": 881581, + "type": "step_goto", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "6308beef094bab7823001f16" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task-create-response" + }, + { + "$ref": "#/components/schemas/task-modify-response" + }, + { + "$ref": "#/components/schemas/task-show-response" + }, + { + "$ref": "#/components/schemas/task-delete-response" + }, + { + "$ref": "#/components/schemas/task-step_next-response" + }, + { + "$ref": "#/components/schemas/task-step_prev-response" + }, + { + "$ref": "#/components/schemas/task-step_goto-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-2", + "ok (modify)": "#/components/schemas/modify-response-2", + "ok (show)": "#/components/schemas/show-response-3", + "ok (delete)": "#/components/schemas/delete-response-2", + "ok (step_next)": "#/components/schemas/step_next-response", + "ok (step_prev)": "#/components/schemas/step_prev-response", + "ok (step_goto)": "#/components/schemas/step_goto-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "ref": "123498765678", + "obj_id": "1123xe556ger645t245cg" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "ref": "15989649323554", + "obj_id": "5f4e44c682ba9635bf66e1d7" + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6304dd15094bab211e00042c", + "task_id": "6304dd15094bab211e00042c", + "ref": "15989649323554", + "status": "processed", + "user_id": 12345, + "create_time": 1661339851, + "change_time": 1661339851, + "node_id": "63060854094bab7c46001dab", + "node_prev_id": "63060854094bab7c46001daa", + "data": { + "foo": "bar" + } + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6304dd15094bab211e00042c" + } + ] + } + }, + "step_next": { + "summary": "step_next", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "630777e056167c6ff4004124", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63060854094bab7c46001daa", + "prev_node_name": "Start", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63077313094bab7c460040d0", + "node_name": "", + "data": { + "foo": "bar" + }, + "prev_logic": [ + { + "proc": "ok", + "sys": { + "execute_time": 0.001 + }, + "type": "go", + "to_conv_id": "", + "to_node_id": "63077313094bab7c460040d0" + }, + { + "proc": "not_checked", + "sys": {}, + "type": "go", + "to_conv_id": "", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "prev_semaphor": [], + "branches": [ + "logic" + ], + "logic": [ + { + "type": "set_param", + "extra": { + "1": "1" + }, + "extra_type": { + "1": "string" + }, + "err_node_id": "63077313094bab7c460040d1" + }, + { + "type": "go", + "to_node_id": "63060854094bab7c46001dab" + } + ], + "history": [ + { + "time": 1661433824375, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + } + }, + "step_prev": { + "summary": "step_prev", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6308beef094bab7823001f16", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63077313094bab7c460040d0", + "prev_node_name": "", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63060854094bab7c46001daa", + "node_name": "Start", + "data": { + "foo": "bar" + }, + "branches": [ + "logic" + ], + "logic": [ + { + "type": "go", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "history": [ + { + "time": 1661517551985, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + } + }, + "step_goto": { + "summary": "step_goto", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6308beef094bab7823001f16", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63077313094bab7c460040d0", + "prev_node_name": "", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63060854094bab7c46001daa", + "node_name": "Start", + "data": { + "foo": "bar" + }, + "branches": [ + "logic" + ], + "logic": [ + { + "type": "go", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "history": [ + { + "time": 1661517551985, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_57}/{SIGNATURE}": { + "post": { + "tags": [ + "user_convs" + ], + "summary": "json", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": null, + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "list" + } + ] + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "anyOf": [ + { + "title": "list" + }, + { + "$ref": "#/components/schemas/company-create-response-error" + } + ] + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_58}/{SIGNATURE}": { + "post": { + "tags": [ + "user_stat" + ], + "summary": "json", + "operationId": "userStat", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing the overall usage statistics", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user_stat-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-12" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "start": 1650834000, + "end": 1650910485, + "company_id": "i92454874049", + "filter": "opers", + "interval": "hour", + "type": "show", + "obj": "used_traff" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user_stat-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/user_stat-show-response", + "error": "#/components/schemas/response-error-common" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "opers": 4, + "date": "2022-03-23" + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_59}/{SIGNATURE}": { + "post": { + "tags": [ + "user_status" + ], + "operationId": "user_status", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Modify

Method for blocking or unblocking a user
(available only for the superadmin role)", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The modify of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user_status-modify-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "modify": "#/components/schemas/modify-request-19" + } + } + } + } + } + }, + "examples": { + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "user_status", + "obj_id": 45165, + "blocked_reason": "test", + "company_id": "i767978912", + "status": "blocked", + "obj_type": "user" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user_status-modify-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (modify)": "#/components/schemas/modify-response-19", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user_status", + "obj_id": 37923, + "status": "blocked" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_62}/{SIGNATURE}": { + "post": { + "tags": [ + "user" + ], + "summary": "json", + "operationId": "user", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating an API key

Modify

Method for changing an API key title (only if the API key is placed in a group)

Link

Method for linking/unlinking an API key and User to/from a group

Show

User details: identifiers, logins, groups

Delete

Method for deleting a user. After a user is deleted, all the objects (groups, folders, processes, etc.) owned by the user will be linked to the company owner.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user-create-request" + }, + { + "$ref": "#/components/schemas/user-modify-request" + }, + { + "$ref": "#/components/schemas/user-link-request" + }, + { + "$ref": "#/components/schemas/user-show-request" + }, + { + "$ref": "#/components/schemas/user-delete-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-9", + "modify": "#/components/schemas/modify-request-8", + "link": "#/components/schemas/link-request-4", + "show": "#/components/schemas/show-request-7", + "delete": "#/components/schemas/delete-request-8" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "type": "create", + "obj": "user", + "title": "first api key", + "company_id": "i702619617", + "logins": [ + { + "type": "api" + } + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "user", + "obj_id": 29299, + "title": "five" + } + ] + } + }, + "link": { + "summary": "link", + "value": { + "ops": [ + { + "group_id": 136830, + "obj_id": 82363, + "obj": "user", + "type": "link", + "company_id": "i790533068", + "level": 1 + } + ] + } + }, + "show": { + "summary": "show", + "value": { + "ops": [ + { + "type": "show", + "obj_id": 27608, + "obj": "user", + "obj_type": "company", + "company_id": "i702619617" + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj_id": 29516, + "company_id": "i702619617", + "obj": "user" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/user-create-response" + }, + { + "$ref": "#/components/schemas/user-modify-response" + }, + { + "$ref": "#/components/schemas/user-list-response" + }, + { + "$ref": "#/components/schemas/user-delete-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-9", + "ok (modify)": "#/components/schemas/modify-response-8", + "ok (link)": "#/components/schemas/link-response-4", + "ok (show)": "#/components/schemas/show-response-8", + "ok (delete)": "#/components/schemas/delete-response-8", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "user", + "proc": "ok", + "users": [ + { + "obj_id": 29299, + "created": true, + "title": "fifth", + "logins": [ + { + "type": "api", + "key": "A5C2iRaxL3kjouu8KhqaPx7asZLjS4W8JaUC3yqDtpIdHN75c", + "obj_id": 30008 + } + ] + } + ] + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "obj_id": 29299, + "title": "five" + } + ] + } + }, + "linkApi": { + "summary": "link (type = api)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "logins": [ + { + "type": "api", + "login": "61e566e382ba963bcb25be3", + "key": "XEeapf5pPjzD6kRIWiLA0NscYDGOMwWAreTr1PAKrCKPUVRG", + "obj_id": 120180 + } + ], + "obj_id": 82363 + } + ] + } + }, + "link": { + "summary": "link (type != api)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "logins": [ + { + "type": "corezoid", + "login": "test00160@gmail.com" + } + ], + "obj_id": 82363 + } + ] + } + }, + "showAPI": { + "summary": "show (type = api)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "obj_id": 28888, + "title": "first", + "owner_id": 60184, + "owner_name": "forApiTest", + "logins": [ + { + "key": "wB12nFmNBI0oSgOSMU3HklYOZw9mYigezFfDnz1xCDfKwqwFN", + "obj_id": 29595, + "type": "api", + "login": "625096ae6167c134a0000e5" + } + ] + } + ] + } + }, + "show": { + "summary": "show (type != api)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "groups": [ + { + "id": 57107, + "name": "Admins", + "owner_id": 25130, + "owner_name": "John Snow", + "is_owner": false + } + ], + "proc": "ok", + "obj": "user", + "obj_id": 27608, + "title": "John Snow", + "logins": [ + { + "type": "google", + "login": "john.snow@thewall.com" + } + ] + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 29516, + "company_id": "i702619617" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_64}/{SIGNATURE}": { + "post": { + "tags": [ + "upload" + ], + "summary": "json", + "operationId": "stopUpload", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for interrupting an upload operation", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/upload-stop-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "stop": "#/components/schemas/stop-request" + } + } + } + } + } + }, + "examples": { + "stop": { + "summary": "stop", + "value": { + "ops": [ + { + "obj": "upload", + "type": "stop", + "hash": "83680364000C72...5896094BAB63B8000197", + "obj_type": "obj_scheme" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/upload-stop-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (stop)": "#/components/schemas/stop-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "stop": { + "summary": "stop", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "upload" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_65}/{SIGNATURE}": { + "post": { + "tags": [ + "version" + ], + "summary": "json", + "operationId": "version", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating a new Version.

Modify

Method for updating Version params.

Get

Method for getting Version information.

Delete

Method for moving a Version to the recycle bin (Trash).

Restore

Method for restoring a Version from the recycle bin (Trash).

Destroy

Method for deleting (irreversibly deleting) a Version from the recycle bin (Trash).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/version-create-request" + }, + { + "ref": "#/components/schemas/version-modify-request" + }, + { + "ref": "#/components/schemas/version-get-request" + }, + { + "ref": "#/components/schemas/version-delete-request" + }, + { + "ref": "#/components/schemas/version-restore-request" + }, + { + "ref": "#/components/schemas/version-destroy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-7", + "modify": "#/components/schemas/modify-request-7", + "get": "#/components/schemas/get-request", + "delete": "#/components/schemas/delete-request-7", + "restore": "#/components/schemas/restore-request-5", + "destroy": "#/components/schemas/destroy-request-4" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "ops": [ + { + "company_id": "i260836082", + "obj": "version", + "vsn": "1.0.0", + "changelog": "", + "project_id": 290551, + "stage_from_id": 290553, + "type": "create" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "ops": [ + { + "type": "modify", + "obj": "version", + "company_id": "i246198512", + "changelog": "test changelog", + "title": "test", + "obj_id": 3541, + "project_id": 169886 + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "ops": [ + { + "type": "get", + "obj": "version", + "company_id": "i246198512", + "obj_id": 3541, + "project_id": 169886 + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "ops": [ + { + "type": "delete", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "ops": [ + { + "type": "restore", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "ops": [ + { + "type": "destroy", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/version-create-response" + }, + { + "$ref": "#/components/schemas/version-modify-response" + }, + { + "$ref": "#/components/schemas/version-get-response" + }, + { + "$ref": "#/components/schemas/version-delete-response" + }, + { + "$ref": "#/components/schemas/version-restore-response" + }, + { + "$ref": "#/components/schemas/version-destroy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-7", + "ok (modify)": "#/components/schemas/modify-response-7", + "ok (get)": "#/components/schemas/get-response", + "ok (delete)": "#/components/schemas/delete-response-7", + "ok (restore)": "#/components/schemas/restore-response-5", + "ok (destroy)": "#/components/schemas/destroy-response-4", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "version", + "obj_id": 12200, + "link": "version_290553_1.0.0_1664267658720.zip" + } + ] + } + }, + "modify": { + "summary": "modify", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "version", + "obj_id": 3541 + } + ] + } + }, + "get": { + "summary": "get", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "is_owner": true, + "owner_id": 12345, + "owner_name": "owner_name", + "owner_login": "owner_login@corezoid.com", + "obj_id": 3541, + "obj_type": "version", + "project_id": 169886, + "project_title": "New Project", + "stage_id": 170200, + "stage_title": "New Stage", + "vsn": "1.0.0", + "title": "test", + "changelog": "test changelog", + "link": "version_170200_1.0.0_1673516833548.zip", + "create_time": 1673516834, + "change_time": 1673516834, + "user_id": 12345, + "status": 1, + "file_format_vsn": 1 + } + ] + } + }, + "delete": { + "summary": "delete", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + } + }, + "restore": { + "summary": "restore", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + } + }, + "destroy": { + "summary": "destroy", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_66}/{SIGNATURE}": { + "post": { + "tags": [ + "versions" + ], + "summary": "json", + "operationId": "versions", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

List

Method for getting a list of Versions.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/versions-list-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "list": "#/components/schemas/list-request-9" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "ops": [ + { + "sort": "vsn", + "order": "desc", + "company_id": "i260836082", + "obj": "versions", + "project_id": 290551, + "type": "list" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/versions-list-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (list)": "#/components/schemas/list-response-9", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "list": { + "summary": "list", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "versions", + "proc": "ok", + "list": [ + { + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner_login@corezoid.com", + "obj_id": 12202, + "obj_type": "version", + "project_id": 290551, + "project_title": "New Project", + "stage_id": 290553, + "stage_title": "develop", + "vsn": "1.1.0", + "title": null, + "changelog": "test", + "link": "version_290553_1.1.0_1664271169182.zip", + "create_time": 1664271169, + "change_time": 1664271169, + "user_id": 12345, + "status": 1, + "file_format_vsn": 1, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_68}/{SIGNATURE}": { + "post": { + "tags": [ + "used_traff" + ], + "summary": "json", + "operationId": "usedTraff", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing the overall usage statistics", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/used_traff-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/show-request-12" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "ops": [ + { + "start": 1650834000, + "end": 1650910485, + "company_id": "i92454874049", + "filter": "opers", + "interval": "hour", + "type": "show", + "obj": "used_traff" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/used_traff-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/show-response-13", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show": { + "summary": "show", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "opers": 4, + "date": "2022-03-23" + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/json/{API_LOGIN}/{GMT_UNIXTIME_69}/{SIGNATURE}": { + "post": { + "tags": [ + "sys_stat" + ], + "summary": "json (multitenant)", + "operationId": "sysStatMultitenant", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "Method for showing Processes usage statistics", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/multitenant-sys_stat-show-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "show": "#/components/schemas/multitenant-show-request" + } + } + } + } + } + }, + "examples": { + "show-company": { + "summary": "show (obj_type=company)", + "value": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "obj_type": "company", + "interval": "hour", + "start": 1651006800, + "end": 1651052154, + "company_id": "i57013995063" + } + ] + } + }, + "show-instance": { + "summary": "show (obj_type=instance)", + "value": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "obj_type": "instance" + } + ] + } + }, + "show-process": { + "summary": "show (obj_type=process)", + "value": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "company_id": "i57013995063", + "order_by": "DESC", + "limit": 10, + "start": 1646085601, + "end": 1648760400, + "offset": 15, + "order_field": "opers" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/multitenant-sys_stat-show-response" + }, + { + "$ref": "#/components/schemas/response-error-common" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (show)": "#/components/schemas/multitenant-show-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "show-company": { + "summary": "show (obj_type=company)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "company", + "data": [ + { + "company_id": "i57013995063", + "company_name": "test_my_owner", + "date": "2022-04-27 05:00:00", + "opers": 145, + "tacts": 468, + "traff": 0.05 + } + ] + } + ] + } + }, + "show-instance": { + "summary": "show (obj_type=instance)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "instance", + "data": { + "companies": 1506, + "users": 16369, + "processes": 300792 + } + } + ] + } + }, + "show-process": { + "summary": "show (obj_type=process)", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "process", + "data": [ + { + "conv_id": 581864, + "conv_name": "Logic_API_Copy_Create", + "owner_id": 6023, + "owner_name": "api_C", + "date": "-", + "opers": 9, + "tacts": 32, + "folder_id": 0, + "traff": 0 + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/plugins/invite/{hash}": { + "post": { + "tags": [ + "confirm_invite" + ], + "summary": "confirm invite", + "operationId": "ConfirmInvite", + "description": "Method for confirming/accepting a new users invitation to company.", + "parameters": [ + { + "name": "hash", + "in": "path", + "description": "Part of the invitation URL", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "redirect": { + "type": "string", + "example": "https://base_url/oauth2/authorize?state=https%253A%252F%252Fadmin-pre.corezoid.com%252Fapi%252F2%252Fplugins%252Finvite%252F65cebb94338f5feec630b6e961069b42d9e73f5c&scope=single_account%3Aaccount.read&response_type=code&redirect_uri=https%3A%2F%2Fbase_url%2Fauth2%2Fsingle_account%2Freturn%2F&client_id=5cb58faaae2a0002", + "description": "Redirect URL for authorization" + } + } + } + } + } + } + } + } + }, + "/api/2/upload/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_scheme(upload)" + ], + "summary": "upload", + "operationId": "obj_scheme(upload)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for uploading objects from file.

Validate

Method for the validation uploading objects.
", + "requestBody": { + "required": true, + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_upload-create-request" + }, + { + "$ref": "#/components/schemas/obj_scheme_upload-validate-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-15", + "validate": "#/components/schemas/validate-request" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create ('async' = true)", + "value": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'apply_mode=true' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false' \\\n--form 'async=true'\n" + }, + "createAsyncFalse": { + "summary": "create ('async' = false)", + "value": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'apply_mode=true' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false' \\\n--form 'async=false'\n" + }, + "validate": { + "summary": "validate", + "value": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=validate' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false'\n" + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_upload-create-response" + }, + { + "$ref": "#/components/schemas/obj_scheme_upload-validate-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-15", + "ok (validate)": "#/components/schemas/validate-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create ('async' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C6397317356167C75FC000808" + } + ] + } + }, + "createAsyncFalse": { + "summary": "create ('async' = false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "scheme": [ + { + "obj_id": 1043733, + "obj_type": "conv", + "title": "New object44", + "description": "", + "old_obj_id": 887890, + "old_parent_id": 268661 + } + ] + } + ] + } + }, + "validate": { + "summary": "validate", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/upload/{API_LOGIN}/{GMT_UNIXTIME_2}/{SIGNATURE}": { + "post": { + "tags": [ + "version(upload)" + ], + "summary": "upload", + "operationId": "version(upload)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Upload

Method for uploading a Version to Stage.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/version_upload-create-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "upload": "#/components/schemas/create-request-16" + } + } + } + } + } + }, + "examples": { + "upload": { + "summary": "upload", + "value": { + "type": "upload", + "obj": "version", + "version_id": 28624, + "stage_to_id": 686010, + "project_id": 686008, + "company_id": "i738314881" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/version_upload-create-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (upload)": "#/components/schemas/create-response-16", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "upload": { + "summary": "upload", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "version", + "proc": "ok", + "stage_to_id": 686010 + } + ] + } + }, + "upload (async)": { + "summary": "upload (async)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D000000216D756C742E6374726C2E6D772D7072652D637A2D312D6170692D6E325F6D756C746D0000000C66AB5FA496FC3B36F3000976" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/upload/{API_LOGIN}/{GMT_UNIXTIME_3}/{SIGNATURE}": { + "post": { + "tags": [ + "task(upload)" + ], + "summary": "upload", + "operationId": "task(upload)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Create

Method for creating (uploading) Tasks from a csv file.
", + "requestBody": { + "required": true, + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task_upload-create-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "create": "#/components/schemas/create-request-17" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create ('async' = true)", + "value": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=task' \\\n--form 'divider=|' \\\n--form 'encoding=utf-8' \\\n--form 'names_in_first_row=true' \\\n--form 'reference_col_name=' \\\n--form 'cols_convert_to=[\"array\", \"object\", \"string\", \"string\"]' \\\n--form 'conv_id=348472' \\\n--form 'company_id=i471132929' \\\n--form 'from_file=tasks.csv;type=text/csv' \\\n--form 'async=true'\n" + }, + "createAsyncFalse": { + "summary": "create ('async' = false)", + "value": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=task' \\\n--form 'divider=|' \\\n--form 'encoding=utf-8' \\\n--form 'names_in_first_row=true' \\\n--form 'reference_col_name=' \\\n--form 'cols_convert_to=[\"array\", \"object\", \"string\", \"string\"]' \\\n--form 'conv_id=348472' \\\n--form 'company_id=i471132929' \\\n--form 'from_file=tasks.csv;type=text/csv' \\\n--form 'async=false'\n" + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/task_upload-create-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (create)": "#/components/schemas/create-response-17", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "create": { + "summary": "create ('async' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "csv_upload", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D6465762D315F6D756C746D0000000C639C8E0B4B8FF93FA50000AE" + } + ] + } + }, + "createAsyncFalse": { + "summary": "create ('async' = false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "csv_upload", + "proc": "ok", + "ok_count": 2, + "err_count": 1, + "all_count": 3 + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/upload/info/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "get": { + "tags": [ + "upload_info" + ], + "summary": "upload", + "operationId": "uploadInfo", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "request time, a Unix timestamp (epoch time), or Greenwich time (GMT+0), integer", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "the signature", + "schema": { + "type": "string" + } + }, + { + "name": "hash", + "in": "query", + "description": "Uploaded file hash", + "schema": { + "type": "string" + } + } + ], + "description": "Method for check uploading operation status.
", + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/upload_info-success" + }, + { + "$ref": "#/components/schemas/upload_info-error_upload" + }, + { + "$ref": "#/components/schemas/upload_info-error" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (success)": "#/components/schemas/upload_info-success-response", + "ok (error during upload)": "#/components/schemas/upload_info-error_upload-response", + "ok (error)": "#/components/schemas/upload_info-error-response" + } + } + } + } + } + }, + "examples": { + "success": { + "summary": "ok (success)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "success", + "scheme": [ + { + "old_obj_id": 282883, + "obj_id": 1391432, + "obj_type": "conv", + "title": "New Object" + } + ] + } + ] + } + }, + "errorDuringUpload": { + "summary": "error (during upload)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "error", + "scheme": [ + { + "old_obj_id": 731204, + "obj_id": 1391431, + "obj_type": "conv", + "title": "New object" + }, + { + "old_obj_id": 540281, + "obj_id": 1391430, + "obj_type": "conv", + "title": "Parallel PCH (Copy)" + }, + { + "old_obj_id": 188920, + "obj_id": 547382, + "obj_type": "folder", + "title": "copy" + } + ], + "errors": [ + { + "obj_id": 547382, + "obj": "folder", + "title": "copy", + "count": 1, + "destinations": [ + { + "conv_type": "process", + "obj_id": 1391430, + "obj": "conv", + "title": "Parallel PCH (Copy)", + "count": 1, + "destinations": [ + { + "obj_id": "6528ed7f56167c28a50032e8", + "obj": "node", + "title": "hist", + "count": 1, + "errors": [ + "Only active process can be used" + ] + } + ] + } + ] + } + ] + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "error", + "scheme": [], + "errors": [ + { + "obj_id": 323435, + "obj": "folder", + "title": "New object", + "errors": [ + "Value is not valid. Value's byte_size is more than maximum allowed: 255" + ] + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/download/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_scheme(download)" + ], + "summary": "download", + "operationId": "obj_scheme(download)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Download

Method for downloading objects to a file.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_download-download-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "download": "#/components/schemas/download-request" + } + } + } + } + } + }, + "examples": { + "download": { + "summary": "download", + "value": { + "ops": [ + { + "obj": "obj_scheme", + "obj_id": 1045470, + "obj_type": "conv", + "company_id": "i848211059", + "with_alias": true, + "async": true, + "format": "zip" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_download-download-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (download)": "#/components/schemas/download-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "download": { + "summary": "download", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "download_url": "https://pre.corezoid.com/user_downloads/conv_1045470_1672282741904.zip", + "statistics_id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C63AD027556167C6644000001" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/download/{API_LOGIN}/{GMT_UNIXTIME_2}/{SIGNATURE}": { + "post": { + "$ref": "./paths/obj_engine.yaml" + } + }, + "/api/2/download/{API_LOGIN}/{GMT_UNIXTIME_3}/{SIGNATURE}": { + "post": { + "tags": [ + "node(download)" + ], + "summary": "json", + "operationId": "node(download)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Download

Method for downloading a Task Archive from a Node.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/node_download-download-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "download": "#/components/schemas/download-request-2" + } + } + } + } + } + }, + "examples": { + "download": { + "summary": "download", + "value": { + "ops": [ + { + "obj_id": "639f3ea7094bab788a0008a1", + "select": "custom", + "offset": 0, + "limit": 5, + "extra_columns": [ + "ref", + "task_id", + "status", + "user_id", + "create_time", + "change_time", + "node_prev_id" + ], + "format": "csv", + "obj": "node", + "conv_id": 1045470, + "company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "ref": "#/components/schemas/node_download-download-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (download)": "#/components/schemas/download-response-2", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "download": { + "summary": "download", + "value": { + "request_proc": "ok", + "ops": [ + { + "download_url": "https://pre.corezoid.com/user_downloads/1045470_conv_639f3ea7094bab788a0008a1_1672282649.csv", + "statistics_id": "1045470_conv_639f3ea7094bab788a0008a1_1672282649.csv", + "obj": "node", + "proc": "ok" + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/compare/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_scheme(compare)" + ], + "summary": "compare", + "operationId": "obj_scheme(compare)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Compare

Method for comparing source and target Stages.", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_compare-compare-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "compare": "#/components/schemas/compare-request" + } + } + } + } + } + }, + "examples": { + "compare_num_stat_true2": { + "summary": "compare ('diff_status' = true && 'num_stat' = true)", + "value": { + "ops": [ + { + "company_id": "i848211059", + "project_id": 375501, + "type": "compare", + "obj": "obj_scheme", + "obj_type": "stage", + "obj_id": 375502, + "obj_to_type": "stage", + "obj_to_id": 395929, + "diff_status": true, + "num_stat": true + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_compare-compare-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (compare)": "#/components/schemas/compare-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "compare": { + "summary": "compare ('diff_status' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1045470, + "title": "test01", + "obj_type": "conv", + "__status": "added" + }, + { + "parent_id": 375502, + "obj_id": 57419, + "title": "test1", + "obj_type": "alias", + "__status": "added" + } + ] + } + ] + } + }, + "compare_diff_status_false": { + "summary": "compare ('diff_status' = false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1065390, + "title": "test01 (Copy)", + "obj_type": "conv", + "__added": {}, + "__deleted": { + "obj_type": 1, + "obj_id": 1065390, + "parent_id": 375502, + "title": "test01 (Copy)", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [], + "web_settings": [] + }, + "uuid": "712824a9-826a-45ae-b1ed-d8ac6a81d5d1" + }, + "__changed": {}, + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [], + "web_settings": [] + }, + "uuid": "712824a9-826a-45ae-b1ed-d8ac6a81d5d1" + } + ] + } + ] + } + }, + "compare_num_stat_true": { + "summary": "compare ('diff_status' = false && 'num_stat' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 409621, + "obj_id": 1079612, + "title": "process01 (Copy)", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 0 + } + } + ] + } + ] + } + }, + "compare_num_stat_true2": { + "summary": "compare ('diff_status' = true && 'num_stat' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1065390, + "title": "test01 (Copy)", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 1 + }, + "__status": "deleted" + }, + { + "parent_id": 375502, + "obj_id": 1067111, + "title": "test002", + "obj_type": "conv", + "__num_stat": { + "added": 1, + "changed": 0, + "deleted": 0 + }, + "__status": "added" + }, + { + "parent_id": 375502, + "obj_id": 59681, + "title": "test1", + "obj_type": "alias", + "__num_stat": { + "added": 0, + "changed": 3, + "deleted": 0 + }, + "__status": "changed" + }, + { + "parent_id": 375502, + "obj_id": 1065392, + "title": "New object44", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 0 + }, + "__status": "" + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/merge/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_scheme(merge)" + ], + "summary": "merge", + "operationId": "obj_scheme(merge)", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Merge

The method for rolling objects between Stages.
", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_merge-merge-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "merge": "#/components/schemas/merge-request" + } + } + } + } + } + }, + "examples": { + "merge": { + "summary": "merge", + "value": { + "ops": [ + { + "type": "merge", + "obj": "obj_scheme", + "obj_id": 375502, + "obj_type": "stage", + "obj_to_id": 395929, + "obj_to_type": "stage", + "apply_mode": true, + "company_id": "i848211059" + } + ] + } + }, + "merge_async_false": { + "summary": "merge ('async' = false)", + "value": { + "ops": [ + { + "type": "merge", + "obj": "obj_scheme", + "obj_id": 409621, + "obj_type": "stage", + "obj_to_id": 409619, + "obj_to_type": "stage", + "apply_mode": true, + "async": false, + "company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_scheme_merge-merge-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (merge)": "#/components/schemas/merge-response", + "error": "#/components/schemas/response-error" + } + } + } + } + } + }, + "examples": { + "merge": { + "summary": "merge", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C63BBFB6E56167C0FD700071C" + } + ] + } + }, + "merge_async_false": { + "summary": "merge ('async' = false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "diff": { + "obj_id": 409621, + "obj_type": "stage" + } + } + ] + } + }, + "merge_apply_mode_false": { + "summary": "merge ('async' = false, 'apply_mode' = false)", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "diff": [ + { + "type": "modify", + "obj": "conv", + "conv_type": "process", + "description": "", + "obj_type": 1, + "params": [], + "ref_mask": true, + "status": "active", + "title": "New Process1", + "uuid": "8a0294be-ef0d-40f9-88fb-b8201ef5bdb0" + }, + { + "type": "create", + "obj": "folder", + "obj_id": 445723, + "title": "New Folder", + "description": "", + "uuid": "bdf0b170-a7e5-4a0b-9b11-7df6ee975a1b", + "folder_id": 445719 + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/copy/{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}": { + "post": { + "tags": [ + "obj_copy" + ], + "summary": "copy", + "operationId": "obj_copy", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "Authorization login of your API key", + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "Request time, Unix timestamp (epoch time), or Greenwich time (GMT+0)", + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "Signature", + "schema": { + "type": "string" + } + } + ], + "description": "

Copy

Method for objects copying (also allows to copy between companies).", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "ops": { + "type": "array", + "description": "The list of operations to perform via Corezoid API. This parameter stores JSON objects with operations", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_copy-copy-request" + } + ], + "discriminator": { + "propertyName": "type", + "mapping": { + "copy": "#/components/schemas/copy-request" + } + } + } + } + } + }, + "examples": { + "copy": { + "summary": "copy", + "value": { + "ops": [ + { + "obj": "obj_copy", + "obj_type": "conv", + "obj_id": 1045470, + "obj_to_id": 395929, + "obj_to_type": "stage", + "title": "test01 (Copy)", + "ignore_errors": true, + "async": false, + "from_company_id": "i848211059", + "to_company_id": "i848211059" + } + ] + } + }, + "copy_async_true": { + "summary": "copy ('async' = true)", + "value": { + "ops": [ + { + "obj": "obj_copy", + "obj_type": "conv", + "obj_id": 1073537, + "obj_to_id": 409619, + "obj_to_type": "stage", + "title": "process01 (Copy)", + "ignore_errors": true, + "async": true, + "from_company_id": "i848211059", + "to_company_id": "i848211059" + } + ] + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "anyOf": [ + { + "$ref": "#/components/schemas/obj_copy-copy-response" + } + ], + "discriminator": { + "propertyName": "proc", + "mapping": { + "ok (copy)": "#/components/schemas/copy-response", + "error": "#/components/schemas/copy-error_response" + } + } + } + } + } + }, + "examples": { + "copy": { + "summary": "copy", + "value": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_copy", + "proc": "ok", + "scheme": [ + { + "hash": "77508f7fdd7a5ee62c5630569245d3bc63ac486f", + "obj_id": 1065389, + "obj_type": "conv", + "title": "test01 (Copy)", + "description": "", + "old_obj_id": 1045470, + "old_parent_id": 395929 + } + ] + } + ] + } + }, + "copy_async_true": { + "summary": "copy ('async' = true)", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_copy", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63CA7B2F094BAB2F5000022A", + "statistics_id": "copy_conv_1073537_eWNeD3hRPo.zip" + } + ] + } + }, + "error": { + "summary": "error", + "value": { + "request_proc": "ok", + "ops": [ + { + "proc": "error", + "errors": [ + { + "conv_type": "process", + "obj_id": 1154601, + "obj": "conv", + "title": "New Process (Copy)", + "count": 1, + "destinations": [ + { + "obj_id": "642d0aa0094bab1b2d00188f", + "obj": "node", + "title": "", + "count": 1, + "errors": [ + "Key 'conv_id'. 'Task operations between companies is not allowed'" + ] + } + ] + } + ] + } + ] + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + }, + "/api/2/system/{API_LOGIN}/{GMT_UNIXTIME_1}/{SIGNATURE}": { + "post": { + "tags": [ + "accounts" + ], + "summary": "account's metric list", + "operationId": "accountsMetriclist", + "description": "Метод отримання метрик пользователей corezoid.com", + "parameters": [ + { + "name": "API_LOGIN", + "in": "path", + "description": "authorization login of your API key", + "required": true, + "schema": { + "type": "long" + } + }, + { + "name": "GMT_UNIXTIME", + "in": "path", + "description": "request time, a Unix timestamp (epoch time), by Greenwich (GMT+0), integer required parameter", + "required": true, + "schema": { + "type": "long" + } + }, + { + "name": "SIGNATURE", + "in": "path", + "description": "the signature", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "type": { + "type": "string", + "required": true, + "description": "The type of operation", + "default": "list" + }, + "obj": { + "type": "string", + "description": "The type of object on that the operation is performed", + "default": "accounts" + }, + "limit": { + "type": "integer", + "example": 500 + }, + "offset": { + "type": "integer", + "example": 20 + } + } + } + } + } + }, + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "title": "cloud", + "properties": { + "count": { + "type": "long", + "example": 500, + "description": "кількість аккаунтів у відповіді методу" + }, + "total": { + "type": "long", + "example": 58901, + "description": "кількість аккаунтів всього" + }, + "accounts": { + "type": "array", + "description": "массив аккаунтів", + "items": { + "type": "object", + "properties": { + "user_id": { + "type": "long", + "description": "ідентифікатор користувача", + "example": 3685 + }, + "user_name": { + "type": "string", + "example": "Дима Бондаренко", + "description": "ім'я/назва користувача" + }, + "logins": { + "type": "array", + "description": "логіни користувача", + "example": [ + 380675234160, + "bondarenko.dmitriy.mail@gmail.com" + ] + }, + "corezoid_process": { + "type": "integer", + "description": "кількість створених процесів", + "example": 105 + }, + "corezoid_diagram": { + "type": "integer", + "description": "кількість створених діаграм станів", + "example": 12 + }, + "corezoid_dashboard": { + "type": "integer", + "description": "кількість створених дашбордів", + "example": 2 + }, + "corezoid_sharing": { + "type": "integer", + "description": "кількість процесів, до яких надано доступ", + "example": 2 + }, + "corezoid_volume": { + "type": "integer", + "description": "кількість тактів за останні три місяці (від моменту виклику методу)", + "example": 5456098 + }, + "corezoid_used": { + "type": "integer", + "description": "кількість місяців, які минули з дати реєстрації", + "example": 34 + }, + "corezoid_alias": { + "type": "integer", + "description": "кількість створених аліасів", + "example": 14 + }, + "corezoid_process_with_databasecall": { + "type": "integer", + "description": "кількість створенних підключень к БД", + "example": 2 + }, + "corezoid_process_with_queue": { + "type": "integer", + "description": "кількість процесів, в яких є хоча б одна нода Queue або Get from Queue", + "example": 9 + }, + "corezoid_process_with_gitcall": { + "type": "integer", + "description": "кількість процесів, в яких є хоча б одна нода gitcall (v2)", + "example": 2 + }, + "corezoid_api_key": { + "type": "integer", + "description": "кількість створених api_key", + "example": 1 + }, + "corezoid_botplatform": { + "type": "integer", + "description": "кількість створених бот-платформ", + "example": 1 + }, + "corezoid_users_group": { + "type": "integer", + "description": "кількість створених груп", + "example": 4 + }, + "corezoid_project": { + "type": "integer", + "description": "кількість створених проектів", + "example": 6 + }, + "corezoid_company": { + "type": "integer", + "description": "кількість створених компаній", + "example": 2 + }, + "corezoid_user": { + "type": "integer", + "description": "кількість користувачів в створених компаніях", + "example": 18 + }, + "corezoid_payments": { + "type": "integer", + "description": "сума платежів за весь період користування (USD)", + "example": 345 + } + } + } + } + } + } + } + } + } + } + } + }, + "/system/conf": { + "get": { + "tags": [ + "conf" + ], + "summary": "system conf", + "operationId": "SystemConf", + "description": "Method for showing system settings", + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/show-response" + } + ] + }, + "examples": { + "show": { + "summary": "full", + "value": { + "result": "ok", + "box_solution": false, + "type_logins": [ + "api", + "saml", + "corezoid", + "google" + ], + "auth_providers": [], + "web_settings": { + "feedback_url": "https://admin-pre.corezoid.com/api/1/json/public/310717/ead74ebd947397307015644ae98c74773201aaf9", + "env": "pre", + "host": { + "site": "pre.corezoid.com", + "doc": "doc.corezoid.com", + "ws": "ws-pre.corezoid.com", + "webhook": "pre.corezoid.com", + "auth": "admin-pre.corezoid.com", + "single_account": "account.pre.corezoid.com" + }, + "path": { + "api": "/api/2/json", + "upload": "/api/2/upload", + "download": "/api/2/download", + "ws": "/api/1/sock_json", + "webhook": "/api/2/", + "auth": "/auth2/single_account", + "base_path": "/account", + "compare": "/api/2/compare", + "superadmin": "/superadmin", + "merge": "/api/2/merge", + "doc": { + "index": "/docs", + "introduction": "/introduction", + "bot_platform": "/bot-platform-20", + "task_export": "/tasks-export", + "mask_values": "/task-parameters#masking-values" + } + }, + "sender": { + "host": "builder.pre.sender.mobi", + "path": { + "embed": "/embed.js?", + "builder": "/builder.html" + } + }, + "captcha": { + "provider": "recaptcha", + "key": "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI", + "disabled": false + }, + "stripe": { + "key": "pk_test_xvUkvKX7lQSty7oV9OoSCDQZ", + "client_id": "ca_9jNyRtcRhl89JluE5MiaHolu49S5i6uM" + }, + "whitelist": [ + "corezoid.com", + "control.events" + ], + "ui": { + "company": true, + "bot_platform": true, + "old_editor": true, + "health": true, + "send_invite": true, + "search": true, + "billing": true, + "default_company": "My Corezoid", + "show_welcome_notify": true, + "tab_name": "Corezoid - cloud operating system", + "features": [ + "merge" + ], + "api_call": { + "send_sys": true, + "default_max_thread": 11 + }, + "save_archive_tasks": true + }, + "password_policy": { + "min_length": 10, + "max_length": 30, + "lowercase": true, + "uppercase": true, + "number": true, + "special": true + } + }, + "auth_single_account": true, + "first_day_of_week": "mon", + "multitenancy": false, + "components": [ + "git_call", + "db_call", + "es" + ], + "max_versions_per_projects": 10, + "max_login_attempts_strategy": "lock", + "user_downloads": { + "max_throughput": 100000 + }, + "database_active_list": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ], + "companies_manager": "single_space", + "billing_manager": "single_space" + } + } + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/error400" + } + } + } + }, + "405": { + "description": "Method Not Allowed", + "content": { + "text/html": { + "schema": { + "example": "The specified method is not allowed against this resource" + } + } + } + }, + "502": { + "description": "Bad Gateway", + "content": { + "text/html": { + "schema": { + "example": "502 Bad Gateway" + } + } + } + }, + "504": { + "description": "Gateway Timeout", + "content": { + "text/html": { + "schema": { + "example": "Gateway Time-out" + } + } + } + } + } + } + } + }, + "security": [ + { + "apiKey": [] + } + ], + "components": { + "securitySchemes": { + "apiKey": { + "type": "apiKey", + "in": "path", + "name": "{API_LOGIN}/{GMT_UNIXTIME}/{SIGNATURE}", + "description": "Before you can start using Corezoid API you need to create an API key and get an authorization login and secret key.
Path for their getting: Users & Groups > Create > API key > enter name > OK
Then you should copy authorization login {API_LOGIN} and secret key {API_SECRET} for creating pre-request script.
The {SIGNATURE} is a concatenated string generated from the following parts:
hex(sha1({GMT_UNIXTIME} + {API_SECRET} + {CONTENT} + {API_SECRET})), where
You can use this pre-request script for signing request:
var time = Math.floor(Date.now() / 1000);
var secret = pm.environment.get(\"SECRET\");
var content = request.data;
var signature = CryptoJS.enc.Hex.stringify(CryptoJS.SHA1(time + secret + content + secret));
pm.environment.set(\"TIMESTAMP\", time);
pm.environment.set(\"SIGNATURE\", signature);
The whole request is http-body, it also described earlier in the signature formula as the {CONTENT}.
All text is expected to be encoded as UTF-8.
" + } + }, + "schemas": { + "request_proc": { + "type": "string", + "enum": [ + "ok" + ], + "description": "The overall processing status of all the request transactions" + }, + "error400": { + "type": "object", + "properties": { + "request_proc": { + "type": "string", + "enum": [ + "ok", + "error" + ], + "description": "The overall processing status of all the request transactions" + }, + "ops": { + "type": "array", + "items": { + "type": "object", + "properties": { + "proc": { + "type": "string", + "example": "error", + "description": "The processing status of a specific operation" + }, + "description": { + "type": "string", + "example": "Incorrect body" + } + } + } + } + } + }, + "show-response": { + "type": "object", + "properties": { + "result": { + "type": "string", + "description": "The processing status" + }, + "box_solution": { + "type": "boolean", + "description": "The On-Premises delivery option flag activates and deactivates the following functionality:
if parameter equals true, then:
a) The elastic search is disabled, instead the search will be performed directly in the database.
b) Companies cannot be created.
c) Users cannot be invited.
d) Every user can see other users.
" + }, + "type_logins": { + "type": "array", + "description": "Available login types", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "oauth_pb", + "phone", + "corezoid", + "github", + "apple", + "keycloak", + "saml" + ] + }, + "auth_providers": { + "type": "array", + "description": "Available authentication providers", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Provider name" + }, + "icon": { + "type": "string", + "description": "Provider icon" + }, + "path": { + "type": "string", + "description": "Part of an authentication URL" + }, + "type": { + "type": "string", + "description": "Authentication type" + } + } + } + }, + "web_settings": { + "type": "object", + "description": "Settings for UI", + "properties": { + "feedback_url": { + "type": "string", + "description": "Feedback form URL" + }, + "env": { + "type": "string", + "description": "Environment name" + }, + "host": { + "type": "object", + "description": "URLs" + }, + "path": { + "type": "string", + "description": "Paths of endpoints" + }, + "sender": { + "type": "object", + "description": "Sender settings" + }, + "captcha": { + "type": "object", + "description": "Captcha settings" + }, + "stripe": { + "type": "object", + "description": "Payment processing platform settings" + }, + "whitelist": { + "type": "array", + "description": "Allowed URLs" + }, + "ui": { + "type": "object", + "description": "Main UI settings", + "properties": { + "company": { + "type": "boolean", + "description": "Permission flag to create a new company" + }, + "bot_platform": { + "type": "boolean", + "description": "Permission flag to create a Communications Orchestrator" + }, + "old_editor": { + "type": "boolean", + "description": "Enables/disables the old process editor" + }, + "health": { + "type": "boolean", + "description": "Enables/disables the system health check feature" + }, + "send_invite": { + "type": "boolean", + "description": "Permission flag to send invitations to new users" + }, + "search": { + "type": "boolean", + "description": "Аllow search" + }, + "billing": { + "type": "boolean", + "description": "Allow billing" + }, + "default_company": { + "type": "string", + "description": "Default company name" + }, + "show_welcome_notify": { + "type": "boolean", + "description": "Flag for showing a welcome message" + }, + "tab_name": { + "type": "string", + "description": "Browser tab name" + }, + "features": { + "type": "array", + "description": "Available additional features" + }, + "api_call": { + "type": "object", + "description": "Default API Call node settings" + }, + "save_archive_tasks": { + "type": "boolean", + "description": "The default checkbox value for saving an archive task in the End node" + } + } + }, + "password_policy": { + "type": "object", + "description": "Password policy settings" + } + } + }, + "auth_single_account": { + "type": "boolean", + "description": "Enables/disables Single Account authorization" + }, + "first_day_of_week": { + "type": "string", + "description": "The country-specific first day of the week used in time intervals on dashboard charts." + }, + "multitenancy": { + "type": "boolean", + "description": "An additional system setting that allows one application instance to serve the needs of multiple client enterprises." + }, + "components": { + "type": "array", + "description": "List of deployed optional components" + }, + "max_versions_per_projects": { + "type": "integer", + "description": "Max number of versions stored for a project This number refers to process (workspace/project) versions, and not to Corezoid instance versions." + }, + "max_login_attempts_strategy": { + "type": "string", + "description": "Type of protection from incorrect password entry: captcha display or lock login." + }, + "user_downloads": { + "type": "object", + "description": "Downloads settings", + "properties": { + "max_throughput": { + "type": "integer", + "description": "The maximum number of tasks that can be downloaded at once in a CSV file from a node." + } + } + }, + "database_active_list": { + "type": "array", + "description": "Available database types for the DB Call node" + }, + "companies_manager": { + "type": "string", + "description": "One of the algorithms for creating a company in Corezoid", + "enum": [ + "corezoid_internal", + "mapi", + "single_space" + ] + }, + "single_auth_provider_mode": { + "type": "string", + "description": "The ability to select and hide only one type of authorization" + }, + "is_ldap": { + "type": "boolean", + "description": "Enables/disables LDAP authorization" + }, + "billing_manager": { + "type": "string", + "description": "Billing", + "enum": [ + "corezoid_internal", + "single_space" + ] + }, + "email_confirm": { + "type": "boolean", + "description": "If false, then registration is allowed without user confirmation." + } + } + }, + "response-error": { + "type": "object", + "title": "error", + "properties": { + "id": { + "allOf": [ + { + "$ref": "../../props/id.yaml" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "../../props/proc.yaml" + } + ] + }, + "description": { + "type": "string", + "example": "The value is not valid. Value's byte_size is less than minimum allowed: 3", + "description": "Error description" + }, + "key": { + "type": "string", + "example": "phone", + "description": "Incorrect input parameter" + }, + "value": { + "type": "string", + "example": "dd", + "description": "Value of the parameter with an incorrect input" + } + } + }, + "example-response-error": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "Value is not valid. Value's byte_size is less than minimum allowed: 3", + "key": "phone", + "value": "dd" + } + ] + }, + "type": { + "type": "string", + "required": true, + "description": "Operation type:" + }, + "obj-request": { + "type": "string", + "required": true, + "description": "The type of an object on which the operation is performed." + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 36, + "nullable": true, + "description": "ID of an existing Company.
Required for all requests within a Company.
If the request is sent to \"My Corezoid\", the 'company_id' is not required or can be null.", + "example": "i791331829" + }, + "project_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
If 'stage_short_name' is sent in the request, either 'project_id' or 'project_short_name' must be sent too." + }, + "project_id": { + "type": "integer", + "default": 0, + "description": "Project ID
If the object is in a stage, then to perform an operation on this object, you must additionally send either 'project_id' or 'project_short_name'." + }, + "stage_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
If the object is in a stage, then to perform an operation on this object, you must additionally send either 'stage_id' or 'stage_short_name'." + }, + "stage_id": { + "type": "integer", + "default": 0, + "description": "Stage ID
If the object is in a stage, then to perform an operation on this object, you must additionally send either 'stage_id' or 'stage_short_name'." + }, + "create-request": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "dashboard" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Dashboard title (name)" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Dashboard description" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "folder_id": { + "type": "integer", + "description": "ID of a folder where a Dashboard will be created." + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "time_range": { + "type": "object", + "description": "Time range", + "required": [ + "timezone_offset" + ], + "properties": { + "timezone_offset": { + "type": "integer", + "description": "Timezone offset, the difference between UTC and local time in minutes" + }, + "start": { + "type": "integer", + "description": "The Dashboard start date, timestamp" + }, + "stop": { + "type": "integer", + "description": "The Dashboard end date, timestamp" + }, + "select": { + "type": "string", + "enum": [ + "fromTo", + "online", + "last10minute", + "today", + "lastHour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month" + ] + } + } + }, + "grid": { + "type": "array", + "deprecated": true, + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart ID" + }, + "x": { + "type": "integer", + "description": "Chart location on X-axis" + }, + "y": { + "type": "integer", + "description": "Chart location on Y-axis" + }, + "width": { + "type": "integer", + "description": "Chart width" + }, + "height": { + "type": "integer", + "description": "Chart height" + } + } + }, + "description": "An array of charts displaying the location" + } + } + }, + "id": { + "type": "string", + "description": "Unique operation identifier (if it was sent in the request, it will also be present in the response).", + "example": "G7GTFRD4JIIUJI" + }, + "proc": { + "type": "string", + "enum": [ + "ok", + "error" + ], + "description": "The processing status of a specific operation." + }, + "obj-response": { + "type": "string", + "required": true, + "description": "Request object" + }, + "create-response": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + } + } + }, + "delete-request": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Dashboard ID" + } + } + }, + "delete-response": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + } + } + }, + "restore-request": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Dashboard ID" + } + } + }, + "restore-response": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "parent_folder_id": { + "type": "integer", + "description": "Parent folder ID" + } + } + }, + "modify-request": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "ID of a Dashboard that will be modified.", + "minimum": 0 + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "nullable": true, + "description": "Description of the Dashboard that will be modified." + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Name of the Dashboard that will be modified." + }, + "time_range": { + "type": "object", + "description": "Time range", + "required": [ + "timezone_offset" + ], + "properties": { + "timezone_offset": { + "type": "integer", + "description": "Timezone offset, the difference in minutes between UTC and local time" + }, + "start": { + "type": "integer", + "description": "Dashboard start date, timestamp" + }, + "stop": { + "type": "integer", + "description": "Dashboard end date, timestamp" + }, + "select": { + "type": "string", + "enum": [ + "fromTo", + "online", + "last10minute", + "today", + "lastHour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month" + ] + } + } + }, + "grid": { + "type": "array", + "items": { + "type": "object", + "required": [ + "obj_id", + "x", + "y", + "width", + "heidth" + ], + "properties": { + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart ID" + }, + "x": { + "type": "integer", + "description": "Chart location on X-axis" + }, + "y": { + "type": "integer", + "description": "Chart location on Y-axis" + }, + "width": { + "type": "integer", + "description": "Chart width" + }, + "heidth": { + "type": "integer", + "description": "Chart height" + } + } + }, + "description": "An array of charts displaying the location" + } + } + }, + "modify-response": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + } + } + }, + "favorite": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "The favorite flag - for adding an object to the Favorites list (or removing from the Favorites list)." + }, + "favorite-request": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID", + "minimum": 0 + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "favorite-response": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + } + } + }, + "list-request": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id", + "list_obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Dashboard ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "The group of users that has access to the object." + } + } + }, + "privs_items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "create", + "view", + "modify", + "delete" + ], + "description": "Type of shared object user rights:
`create` — Allows a user to create a task in a Process and a State Diagram.
`view` — Allows a user to view Process and State Diagram nodes.
`modify` — Allows a user to edit Process and State Diagram nodes.
`delete` — Allows a user to delete an object." + }, + "list_obj": { + "type": "array", + "default": [ + "all" + ] + } + } + }, + "privs": { + "type": "array", + "uniqueItems": true, + "description": "The array with settings for linked object user rights.
The value can be `[]` empty array.", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "list-response": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "Type of a user that has access to the object." + }, + "list": { + "type": "array", + "description": "List of users and their requested object rights", + "items": { + "type": "object", + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "ID of a user, API key or a user group that has access to the object." + }, + "login_id": { + "type": "integer", + "description": "(Only for user or API key) ID of a user or an API key that has access to the object." + }, + "title": { + "type": "string", + "description": "User, API key login or a user's group name" + }, + "login": { + "type": "string", + "description": "(Only for user) Login of a user that has access to the object, user login." + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + } + } + } + }, + "show-request": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of a Dashboard which details will be shown." + } + } + }, + "show-response-2": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Dashboard name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Dashboard description" + }, + "create_time": { + "type": "integer", + "description": "Dashboard creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Dashboard change time in The Unixtime format" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "chart_list": { + "type": "array", + "description": "An array of charts on the Dashboard", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "minLength": 1, + "maxLength": 250, + "description": "Chart name" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart ID" + }, + "type": { + "type": "string", + "enum": [ + "table", + "column", + "funnel", + "pie" + ], + "description": "Chart type:
`table` — Table chart
`column` — Bar chart
`pie` — Pie chart
`funnel` — Funnel chart" + } + } + } + }, + "folder_id": { + "type": "integer", + "description": "ID of the folder where the Dashboard is stored." + }, + "folder_name": { + "type": "string", + "description": "Name of the folder where the Dashboard is stored." + }, + "parent_obj_id": { + "type": "integer", + "description": "ID of the object where the Dashboard is stored." + }, + "parent_obj_type": { + "type": "string", + "description": "Type of the object where the Dashboard is stored." + }, + "owner_name": { + "type": "string", + "description": "Dashboard owner name" + }, + "owner_id": { + "type": "integer", + "description": "Dashboard owner ID" + }, + "owner_login": { + "type": "string", + "example": "owner.email@corezoid.com", + "description": "Dashboard owner login" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Indicates whether the Dashboard is immutable." + }, + "time_range": { + "type": "object", + "description": "Time range", + "properties": { + "timezone_offset": { + "type": "integer", + "description": "Timezone offset, the difference in minutes between UTC and local time" + }, + "start": { + "type": "integer", + "description": "Dashboard start date, timestamp" + }, + "stop": { + "type": "integer", + "description": "Dashboard end date, timestamp" + }, + "select": { + "type": "string", + "enum": [ + "fromTo", + "online", + "last10minute", + "today", + "lastHour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month" + ], + "description": "Display date-time range:
`online` — Real-Time
`fromTo` — Custom Range
`last10minute` — Last 10 minutes
`today` — Today
`lastHour` — Last hour
`last24hour` — Last 24 hours
`lastWeek` — Last 7 days
`lastMonth` — Last 30 days
`previous_hour` — Previous hour
`previous_day` — Previous day
`previous_week` — Previous week
`previous_month` — Previous month" + } + } + }, + "grid": { + "type": "array", + "description": "An array of charts displaying the location", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart ID" + }, + "x": { + "type": "integer", + "description": "Chart location on X-axis" + }, + "y": { + "type": "integer", + "description": "Chart location on Y-axis" + }, + "width": { + "type": "integer", + "description": "Chart width" + }, + "height": { + "type": "integer", + "description": "Chart height" + } + } + } + } + } + }, + "is_need_to_notify": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "The flag for sending an email to notify a user of a shared access." + }, + "link-request": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "obj_to", + "obj_to_id", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of the Dashboard to which the object will be linked." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + }, + "obj_to": { + "type": "string", + "enum": [ + "group", + "user", + "all" + ], + "description": "Shared access type:
`user` — Sharing with an API key / user
`group` — Sharing with a group
`all` — Sharing with all - make visible for all users

`group`, `user` — Allowed only when the 'obj_to_id' request parameter exists.
" + }, + "obj_to_id": { + "type": "integer or string", + "description": "ID of the object (user / API key / group) which we share with. If \"obj_to\" = \"all\", then obj_to_id will be dispensable." + } + } + }, + "action_type": { + "type": "string", + "enum": [ + "link", + "unlink" + ], + "description": "Operation type:
`link` — Share access to a stage (when the 'privs' request parameter is present and is not the `[]` empty array).
`unlink` — Remove previously shared access to a stage (when the 'privs' request parameter is the `[]` empty array)." + }, + "link-response": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "user", + "new_user", + "folder", + "group", + "all" + ], + "description": "Access was granted to:
`group` — Group
`user` — User
`new_user` — New user
`all` — Shared with all - made visible for all users" + }, + "obj_to_id": { + "type": "integer or string", + "description": "User / API key / users group ID" + }, + "obj_to_title": { + "type": "string", + "description": "A login of a user or users group name" + }, + "action_type": { + "allOf": [ + { + "$ref": "#/components/schemas/action_type" + } + ] + } + } + }, + "destroy-request": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Dashboard ID" + } + } + }, + "destroy-response": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Dashboard that was destroyed." + } + } + }, + "example-create-request": { + "ops": [ + { + "title": "New object", + "description": "", + "folder_id": 0, + "company_id": "i260811111", + "obj": "dashboard", + "time_range": { + "select": "online", + "start": 1656075346, + "stop": 1656075346, + "timezone_offset": -180 + }, + "type": "create" + } + ] + }, + "example-create-response-api": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 12345 + } + ] + }, + "example-delete-request": { + "ops": [ + { + "type": "delete", + "obj": "dashboard", + "obj_id": 62091 + } + ] + }, + "example-delete-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "dashboard", + "obj_id": 62091, + "proc": "ok" + } + ] + }, + "example-restore-request": { + "ops": [ + { + "type": "restore", + "obj": "dashboard", + "obj_id": 62084 + } + ] + }, + "example-restore-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 62084, + "obj": "dashboard", + "parent_folder_id": 0 + } + ] + }, + "example-modify-request": { + "ops": [ + { + "type": "modify", + "obj": "dashboard", + "obj_id": 65292, + "title": "", + "description": "", + "time_range": { + "timezone_offset": -180, + "select": "online" + }, + "grid": [ + { + "obj_id": "631b4659094bab65a0012d4b", + "x": 3, + "y": 0, + "width": 4, + "height": 4 + }, + { + "obj_id": "631b46de094bab65a0012d4d", + "x": 7, + "y": 0, + "width": 4, + "height": 4 + } + ] + } + ] + }, + "example-modify-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 65292 + } + ] + }, + "example-favorite-request": { + "ops": [ + { + "type": "favorite", + "obj": "dashboard", + "obj_id": 12345, + "favorite": true + } + ] + }, + "example-favorite-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 12345, + "obj": "dashboard" + } + ] + }, + "example-list-request": { + "ops": [ + { + "obj_id": 61440, + "obj": "dashboard", + "type": "list", + "list_obj": "group" + } + ] + }, + "example-list-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "dashboard", + "obj_id": 12345, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 77777, + "login_id": 77777, + "title": "User", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "example_@gmail.com" + } + ] + } + ] + }, + "example-show-request": { + "ops": [ + { + "obj_id": 12345, + "type": "show", + "obj": "dashboard" + } + ] + }, + "example-show-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboard", + "obj_id": 11111, + "title": "New object", + "description": "", + "create_time": 1659601245, + "change_time": 1659601245, + "time_range": { + "timezone_offset": -180, + "select": "online" + }, + "favorite": false, + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "company_id": "i260111182", + "chart_list": [ + { + "name": "New Chart", + "obj_id": "62e927fd094bab164d003aba", + "type": "table" + } + ], + "folder_id": 123456, + "folder_name": "New object", + "owner_id": 12345, + "owner_login": "owner.email@corezoid.com", + "owner_name": "Owner Name", + "immutable": false, + "grid": [ + { + "obj_id": "62e90d7f56167c0913003a30", + "x": 0, + "y": 0, + "width": 4, + "height": 4 + } + ], + "parent_obj_id": 0, + "parent_obj_type": "folder" + } + ] + }, + "example-link-request": { + "ops": [ + { + "type": "link", + "obj": "dashboard", + "obj_id": 12345, + "obj_to": "user", + "obj_to_id": 44444, + "company_id": "i260836082", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "dashboard", + "obj_id": 12345, + "obj_to_type": "user", + "obj_to_id": 44444, + "obj_to_title": "User Test", + "action_type": "link" + } + ] + }, + "example-destroy-request": { + "ops": [ + { + "type": "destroy", + "obj": "dashboard", + "obj_id": 12345 + } + ] + }, + "example-destroy-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 12345, + "obj_type": "dashboard" + } + ] + }, + "list-request-2": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "Dashboards" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "pattern": { + "type": "string", + "minLength": 1, + "maxLength": 150, + "description": "Search parameter. Dashboard ID or Dashboard title can be used." + }, + "limit": { + "type": "integer", + "default": 20, + "description": "Defines the maximum number of objects in the response." + } + } + }, + "list-response-2": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "dashboards" + }, + "list": { + "type": "array", + "description": "List of Dashboards", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Dashboard name" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_type": { + "type": "string", + "default": "dashboards", + "description": "Object type" + }, + "create_time": { + "type": "integer", + "description": "Dashboard creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Dashboard change time in the Unixtime format" + }, + "owner_id": { + "type": "integer", + "description": "Dashboard owner ID" + } + } + } + } + } + }, + "example-list-request-2": { + "ops": [ + { + "type": "list", + "obj": "dashboards", + "company_id": "i246198512", + "project_id": 169886, + "stage_id": 169887, + "limit": 10, + "pattern": "test1" + } + ] + }, + "example-list-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "dashboards", + "list": [ + { + "obj_id": 43384, + "obj_type": "dashboard", + "company_id": "i246198512", + "title": "test1", + "create_time": 1681128587, + "change_time": 1681128587, + "owner_id": 56657 + } + ] + } + ] + }, + "create-request-2": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "conv_id", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process for that the Task is created" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "data": { + "type": "object", + "description": "An object with key-value pairs that describes necessary parameters. You can pass an empty array `[]` in this object" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "create-response-2": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task" + } + } + }, + "modify-request-2": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "conv_id", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process, for that the Task is created" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task.
You can use it instead of the 'obj_id'" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a Company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "work_status": { + "deprecated": true, + "type": "string", + "enum": [ + "created", + "processing", + "delayed", + "processed", + "canceled", + "deleted" + ], + "description": "Task current status" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs that describes necessary parameters. You can pass an empty array `[]` in this object" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "modify-response-2": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task" + } + } + }, + "show-request-2": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "conv_id", + "ref", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process for that the Task is created" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID. You can use it instead of the 'ref'" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task. You can use it instead of the 'obj_id'" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "show-response-3": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task internal ID" + }, + "task_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task internal ID" + }, + "ref": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "allowed": null, + "description": "An external identifier of the Task." + }, + "status": { + "type": "string", + "enum": [ + "created", + "processing", + "delayed", + "processed", + "canceled", + "deleted" + ], + "description": "Current task status" + }, + "user_id": { + "type": "integer", + "description": "ID of the User that created the Task" + }, + "create_time": { + "type": "integer", + "description": "Task creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Task change time in unixtime format" + }, + "node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "ID of the Node in that the Task is currently stored" + }, + "node_prev_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "ID of the previous Node the Task went through" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs that describes necessary parameters" + } + } + }, + "delete-request-2": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "conv_id", + "node_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24 + }, + "node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24 + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-2": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "description": "ID of the Task that was deleted" + } + } + }, + "step_next-request": { + "type": "object", + "title": "step_next", + "required": [ + "type", + "obj", + "conv_id", + "data", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "step_next" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process / State diagram in that the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step. You can pass an empty array `[]` in this object" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "branch": { + "type": "string", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "step_next-response": { + "type": "object", + "title": "step_next", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "prev_conv_id": { + "type": "integer or string", + "description": "Identifier of the Process or the State diagram in which the Task was previously located" + }, + "prev_conv_name": { + "type": "string", + "description": "Name of the Process or the State diagram in which the Task was previously located" + }, + "prev_node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of the Node in which the Task was previously located" + }, + "prev_node_name": { + "type": "string", + "description": "Name of the Node in that the Task was previously located" + }, + "conv_id": { + "type": "integer or string", + "description": "Identifier of a Process or a State diagram in which the Task is currently being processed" + }, + "conv_name": { + "type": "string", + "description": "Name of a Process or a State diagram in which the Task is currently being processed" + }, + "node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of a Node in which the Task is currently being processed" + }, + "node_name": { + "type": "string", + "description": "Name (title) of a Node in which the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step" + }, + "prev_logic": { + "type": "array", + "description": "An array with previous node settings" + }, + "prev_semaphor": { + "type": "array", + "description": "An array of previous node escalations settings" + }, + "branches": { + "type": "array", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer" + }, + "logic": { + "type": "array", + "description": "An array with node settings" + }, + "history": { + "type": "array", + "description": "An array of tracks of task steps", + "items": { + "type": "object", + "properties": { + "time": { + "type": "integer" + }, + "prev_conv_id": { + "type": "integer" + }, + "conv_id": { + "type": "integer or string" + }, + "prev_node_id": { + "type": "string" + }, + "node_id": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "data": { + "type": "object" + } + } + } + } + } + }, + "step_prev-request": { + "type": "object", + "title": "step_prev", + "required": [ + "type", + "obj", + "conv_id", + "data", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "step_prev" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of the Process / State diagram in that the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step. You can pass an empty array `[]` in this object" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "branch": { + "type": "string", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "step_prev-response": { + "type": "object", + "title": "step_prev", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "prev_conv_id": { + "type": "integer or string", + "description": "Identifier of the Process or the State diagram in which the Task was previously located" + }, + "prev_conv_name": { + "type": "string", + "description": "Name of the Process or the State diagram in which the Task was previously located" + }, + "prev_node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of the Node in which the Task was previously located" + }, + "prev_node_name": { + "type": "string", + "description": "Name of the Node in that the Task was previously located" + }, + "conv_id": { + "type": "integer or string", + "description": "Identifier of a Process or a State diagram in which the Task is currently being processed" + }, + "conv_name": { + "type": "string", + "description": "Name of a Process or a State diagram in which the Task is currently being processed" + }, + "node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of a Node in which the Task is currently being processed" + }, + "node_name": { + "type": "string", + "description": "Name (title) of a Node in which the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step" + }, + "branches": { + "type": "array", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer" + }, + "logic": { + "type": "array", + "description": "An array with node settings" + }, + "history": { + "type": "array", + "description": "An array of tracks of task steps", + "items": { + "type": "object", + "properties": { + "time": { + "type": "integer" + }, + "prev_conv_id": { + "type": "integer" + }, + "conv_id": { + "type": "integer or string" + }, + "prev_node_id": { + "type": "string" + }, + "node_id": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "data": { + "type": "object" + } + } + } + } + } + }, + "step_goto-request": { + "type": "object", + "title": "step_goto", + "required": [ + "type", + "obj", + "conv_id", + "data", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "step_goto" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process / State diagram in that the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step. You can pass an empty array `[]` in this object" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "branch": { + "type": "string", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "step_goto-response": { + "type": "object", + "title": "step_goto", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "prev_conv_id": { + "type": "integer or string", + "description": "Identifier of the Process or the State diagram in which the Task was previously located" + }, + "prev_conv_name": { + "type": "string", + "description": "Name of the Process or the State diagram in which the Task was previously located" + }, + "prev_node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of the Node in which the Task was previously located" + }, + "prev_node_name": { + "type": "string", + "description": "Name of the Node in that the Task was previously located" + }, + "conv_id": { + "type": "integer or string", + "description": "Identifier of a Process or a State diagram in which the Task is currently being processed" + }, + "conv_name": { + "type": "string", + "description": "Name of a Process or a State diagram in which the Task is currently being processed" + }, + "node_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Identifier of a Node in which the Task is currently being processed" + }, + "node_name": { + "type": "string", + "description": "Name (title) of a Node in which the Task is currently being processed" + }, + "data": { + "type": "object", + "description": "An object with key-value pairs of parameters passed at the current step" + }, + "branches": { + "type": "array", + "enum": [ + "timer", + "logic" + ], + "description": "Defines where the Task is to be moved to - a node of the specified type or a timer" + }, + "logic": { + "type": "array", + "description": "An array with node settings" + }, + "history": { + "type": "array", + "description": "An array of tracks of task steps", + "items": { + "type": "object", + "properties": { + "time": { + "type": "integer" + }, + "prev_conv_id": { + "type": "integer" + }, + "conv_id": { + "type": "integer or string" + }, + "prev_node_id": { + "type": "string" + }, + "node_id": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "data": { + "type": "object" + } + } + } + } + } + }, + "example-create-by-convId-request": { + "ops": [ + { + "type": "create", + "conv_id": 123456, + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678" + } + ] + }, + "example-create-by-alias-request": { + "ops": [ + { + "type": "create", + "obj_alias": "test_alias", + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678" + } + ] + }, + "example-create-by-stage-alias-request": { + "ops": [ + { + "type": "create", + "obj_alias": "test_alias", + "obj": "task", + "company_id": "i111111222", + "data": { + "foo": "bar" + }, + "ref": "123498765678", + "stage_id": 543678, + "project_id": 543677 + } + ] + }, + "example-create-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "ref": "123498765678", + "obj_id": "1123xe556ger645t245cg" + } + ] + }, + "example-modify-request-2": { + "ops": [ + { + "type": "modify", + "conv_id": 123098, + "obj": "task", + "company_id": "i543378975", + "data": { + "foo": "bar" + }, + "ref": "15989649323554" + } + ] + }, + "example-modify-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "ref": "15989649323554", + "obj_id": "5f4e44c682ba9635bf66e1d7" + } + ] + }, + "example-show-request-2": { + "ops": [ + { + "type": "show", + "obj": "task", + "ref": "15989649323554", + "conv_id": 789846, + "company_id": "i260999999" + } + ] + }, + "example-show-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6304dd15094bab211e00042c", + "task_id": "6304dd15094bab211e00042c", + "ref": "15989649323554", + "status": "processed", + "user_id": 12345, + "create_time": 1661339851, + "change_time": 1661339851, + "node_id": "63060854094bab7c46001dab", + "node_prev_id": "63060854094bab7c46001daa", + "data": { + "foo": "bar" + } + } + ] + }, + "example-delete-request-2": { + "ops": [ + { + "type": "delete", + "obj": "task", + "conv_id": 234234, + "company_id": "i260999999", + "node_id": "g4342ij44goer09409w0e0мd", + "obj_id": "6304dd15094bab211e00042c" + } + ] + }, + "example-delete-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6304dd15094bab211e00042c" + } + ] + }, + "example-step_next-request": { + "ops": [ + { + "conv_id": 881581, + "type": "step_next", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "630777e056167c6ff4004124" + } + ] + }, + "example-step_next-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "630777e056167c6ff4004124", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63060854094bab7c46001daa", + "prev_node_name": "Start", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63077313094bab7c460040d0", + "node_name": "", + "data": { + "foo": "bar" + }, + "prev_logic": [ + { + "proc": "ok", + "sys": { + "execute_time": 0.001 + }, + "type": "go", + "to_conv_id": "", + "to_node_id": "63077313094bab7c460040d0" + }, + { + "proc": "not_checked", + "sys": {}, + "type": "go", + "to_conv_id": "", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "prev_semaphor": [], + "branches": [ + "logic" + ], + "logic": [ + { + "type": "set_param", + "extra": { + "1": "1" + }, + "extra_type": { + "1": "string" + }, + "err_node_id": "63077313094bab7c460040d1" + }, + { + "type": "go", + "to_node_id": "63060854094bab7c46001dab" + } + ], + "history": [ + { + "time": 1661433824375, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + }, + "example-step_prev-request": { + "ops": [ + { + "conv_id": 881581, + "type": "step_prev", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "6308beef094bab7823001f16" + } + ] + }, + "example-step_prev-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6308beef094bab7823001f16", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63077313094bab7c460040d0", + "prev_node_name": "", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63060854094bab7c46001daa", + "node_name": "Start", + "data": { + "foo": "bar" + }, + "branches": [ + "logic" + ], + "logic": [ + { + "type": "go", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "history": [ + { + "time": 1661517551985, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + }, + "example-step_goto-request": { + "ops": [ + { + "conv_id": 881581, + "type": "step_goto", + "branch": "logic", + "company_id": "i260836082", + "obj": "task", + "data": { + "foo": "bar" + }, + "obj_id": "6308beef094bab7823001f16" + } + ] + }, + "example-step_goto-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "task", + "obj_id": "6308beef094bab7823001f16", + "prev_conv_id": 881581, + "prev_conv_name": "New object", + "prev_node_id": "63077313094bab7c460040d0", + "prev_node_name": "", + "conv_id": 881581, + "conv_name": "New object", + "node_id": "63060854094bab7c46001daa", + "node_name": "Start", + "data": { + "foo": "bar" + }, + "branches": [ + "logic" + ], + "logic": [ + { + "type": "go", + "to_node_id": "63077313094bab7c460040d0" + } + ], + "history": [ + { + "time": 1661517551985, + "prev_conv_id": 881581, + "conv_id": 881581, + "prev_node_id": null, + "node_id": "63060854094bab7c46001daa", + "status": 1, + "data": null + } + ] + } + ] + }, + "create-request-3": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "company_id", + "title", + "short_name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Project description" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Project name" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name" + }, + "stages": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage Name" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Indicates whether the stage is immutable" + } + } + } + }, + "update_not_uniq_short_name": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Indicates whether the 'project_short_name' is not unique" + }, + "extra": { + "type": "object", + "deprecated": true, + "description": "object of additional settings (app_id or type)" + } + } + }, + "create-response-3": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project ID" + }, + "stages": { + "type": "array", + "items": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity" + }, + "description": "Array of IDs of created Stages" + } + } + }, + "modify-request-3": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Project description" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Project name" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name" + } + } + }, + "modify-response-3": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project ID" + } + } + }, + "list-request-3": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "`group` — get a list of users and groups that have access to a project
\n don't send this parameter for getting a list of stages in a project" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of the Project for that the Stages will be listed" + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + }, + "sort": { + "type": "string", + "enum": [ + "name", + "title", + "owner", + "date", + "tacts" + ], + "default": "name", + "description": "Name of field to sort result" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc", + "description": "this parameter is used for sorting result data:
`asc` — in ascending order;
`desc` — in descending order." + } + } + }, + "is_favorite": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "The flag shows whether an object was added to the Favorites (Starred) list." + }, + "list-response-3": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project ID" + }, + "list": { + "type": "array", + "description": "List of Stages", + "items": { + "type": "object", + "properties": { + "uniq_undeployed_versions": { + "type": "integer", + "description": "count of unique undeployed versions" + }, + "uniq_undeployed_versions_detail": { + "type": "array", + "description": "list of undeployed versions details" + }, + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag shows was Project aceess shared" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "undeployed": { + "type": "integer", + "description": "Number of undeployed processes" + }, + "childs": { + "type": "integer", + "description": "Number of folders in root folder of a Stage" + }, + "size": { + "type": "integer", + "description": "Number of objects in root folder of a Stage" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as Stage owner ID" + }, + "owner_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Stage owner ID" + }, + "owner_name": { + "type": "string", + "description": "Stage owner name" + }, + "owner_login": { + "type": "string", + "description": "Stage owner login" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Stage ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "stage" + ], + "description": "Object type" + }, + "create_time": { + "type": "integer", + "description": "Stage creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Stage change time in unixtime format" + }, + "title": { + "type": "string", + "description": "Stage name" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Stage description" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Indicates whether the Dashboard is immutable" + }, + "project_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project ID" + }, + "owner_group_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Project owner's group's ID" + } + } + } + } + } + }, + "link-request-2": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "privs", + "obj_to", + "obj_to_id", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "obj_to": { + "type": "string", + "enum": [ + "user", + "group" + ], + "description": "Shared access type:
`user` — access shared with an API Key / User;
`group` — access shared with a Group" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of a User, API Key or a User Group", + "minimum": 0 + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + } + } + }, + "link-response-2": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_to_type": { + "type": "string", + "enum": [ + "user", + "group" + ], + "description": "Stage was shared with:
`user` — API Key / User;
`group` — Group" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of a User, API Key or a User Group", + "minimum": 0 + }, + "obj_to_title": { + "type": "string", + "description": "User login or User Group name" + }, + "action_type": { + "allOf": [ + { + "$ref": "#/components/schemas/action_type" + } + ] + } + } + }, + "favorite-request-2": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "favorite-response-2": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "delete-request-3": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + } + } + }, + "delete-response-3": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + } + } + }, + "restore-request-2": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of the Project that will be restored", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + } + } + }, + "restore-response-2": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + } + } + }, + "destroy-request-2": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + } + } + }, + "destroy-response-2": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + } + } + }, + "show-request-3": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "project" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
You can use it instead of the 'obj_id'" + } + } + }, + "show-response-4": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "project" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Project short name" + }, + "stages": { + "type": "array", + "description": "List of Stages available to the User", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "Stage name" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID", + "minimum": 0 + }, + "obj_short_name": { + "type": "string", + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name" + } + } + } + }, + "parent_obj_id": { + "type": "integer", + "description": "Parent Object ID" + }, + "parent_obj_type": { + "type": "string", + "description": "Parent Object Type" + } + } + }, + "example-create-request-2": { + "ops": [ + { + "title": "Test", + "description": "", + "company_id": "i260836082", + "obj": "project", + "short_name": "test", + "stages": [ + { + "title": "production", + "immutable": true + }, + { + "title": "develop", + "immutable": false + } + ], + "type": "create" + } + ] + }, + "example-create-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469, + "stages": [ + 316470, + 316471 + ] + } + ] + }, + "example-modify-request-3": { + "ops": [ + { + "title": "Test-1", + "description": null, + "short_name": "test", + "type": "modify", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + }, + "example-modify-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469 + } + ] + }, + "example-list-request-3": { + "ops": [ + { + "obj_id": 316469, + "sort": "title", + "order": "desc", + "company_id": "i260836082", + "obj": "project", + "type": "list" + } + ] + }, + "example-list-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "i260836082", + "obj": "project", + "obj_id": 316469, + "proc": "ok", + "list": [ + { + "uniq_undeployed_versions": 0, + "uniq_undeployed_versions_detail": [], + "is_shared": false, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 0, + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner.login@corezoid.com", + "obj_id": 316471, + "obj_type": "stage", + "create_time": 1661846259, + "change_time": 1661846259, + "title": "develop", + "short_name": "develop", + "description": "", + "company_id": "i260836082", + "immutable": false, + "project_id": 316469, + "owner_group_id": 41213 + } + ] + } + ] + }, + "example-link-request-2": { + "ops": [ + { + "type": "link", + "obj": "project", + "obj_id": 316469, + "obj_to": "user", + "obj_to_id": 54321, + "is_need_to_notify": true, + "company_id": "i260836082", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "project", + "obj_id": 316469, + "obj_to_type": "user", + "obj_to_id": 54321, + "obj_to_title": "Default User", + "action_type": "link" + } + ] + }, + "example-favorite-request-2": { + "ops": [ + { + "type": "favorite", + "obj": "project", + "obj_id": 777333, + "company_id": "i260836082", + "favorite": true + } + ] + }, + "example-favorite-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 777333, + "obj": "project" + } + ] + }, + "example-delete-request-3": { + "ops": [ + { + "type": "delete", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + }, + "example-delete-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + }, + "example-restore-request-2": { + "ops": [ + { + "type": "restore", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + }, + "example-restore-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + }, + "example-destroy-request-2": { + "ops": [ + { + "type": "destroy", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + }, + "example-destroy-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "project", + "obj_id": 316469, + "proc": "ok" + } + ] + }, + "example-show-request-3": { + "ops": [ + { + "type": "show", + "obj": "project", + "obj_id": 316469, + "company_id": "i260836082" + } + ] + }, + "example-show-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "project", + "obj_id": 316469, + "obj_short_name": "test", + "stages": [ + { + "title": "production", + "obj_id": 316470, + "obj_short_name": "production" + } + ], + "parent_obj_id": 51948, + "parent_obj_type": "folder" + } + ] + }, + "list-request-4": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "projects" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "sort": { + "type": "string", + "enum": [ + "name", + "title", + "owner", + "date" + ], + "default": "name", + "description": "Name of the field to sort the results by. The \"name\" and \"title\" parameters are the same." + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc", + "description": "this parameter is used for sorting the result data:
`asc` — in ascending order;
`desc` — in descending order." + } + } + }, + "list-response-4": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "projects" + }, + "list": { + "type": "array", + "description": "List of company Projects", + "items": { + "type": "object", + "properties": { + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag showing whether Project access was shared" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "undeployed": { + "type": "integer", + "description": "Shows the number of undeployed processes in a Stage" + }, + "childs": { + "type": "integer", + "description": "Number of Project Stages" + }, + "size": { + "type": "integer", + "description": "Number of Project Stages" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Flag of a Project ownership by the current User" + }, + "owner_id": { + "type": "integer", + "description": "Project owner ID", + "minimum": 0 + }, + "owner_name": { + "type": "string", + "description": "Project owner displayed name" + }, + "owner_login": { + "type": "string", + "description": "Project owner login" + }, + "obj_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "obj_type": { + "type": "string", + "enum": [ + "project" + ], + "description": "An object type" + }, + "create_time": { + "type": "integer", + "description": "Time of a Project creation, timestamp" + }, + "change_time": { + "type": "integer", + "description": "Time of a Project last change, timestamp" + }, + "title": { + "type": "string", + "description": "Project name" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Project description" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "type": "integer", + "description": "Project ID", + "minimum": 0 + }, + "owner_group_id": { + "type": "integer", + "description": "Project owner's group ID", + "minimum": 0 + } + } + } + } + } + }, + "example-list-request-4": { + "ops": [ + { + "company_id": "i260836082", + "type": "list", + "obj": "projects", + "sort": "title" + } + ] + }, + "example-list-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "i260836082", + "obj": "projects", + "proc": "ok", + "list": [ + { + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 1, + "size": 1, + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner.login@corezoid.com", + "obj_id": 316469, + "obj_type": "project", + "create_time": 1661846259, + "change_time": 1661934023, + "title": "Test-1", + "description": "", + "company_id": "i260836082", + "short_name": "test", + "project_id": 316469, + "owner_group_id": 41213 + } + ] + } + ] + }, + "create-request-4": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "conv_id", + "version", + "obj_type" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process in which the Node will be created" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000 + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255 + }, + "version": { + "type": "integer", + "description": "Node version" + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node
`2` — final node
`3` — escalation - special system node
this response parameter is present only if the request parameter 'list_obj' != \"group\"" + } + } + }, + "create-response-4": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "node" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "logics": { + "description": "logics value can be an `[]` empty array.
An array of node settings
", + "type": "array", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "go", + "go_if_const", + "set_param", + "api", + "api_callback", + "api_sum", + "api_code", + "api_copy", + "api_rpc", + "api_rpc_reply", + "api_queue", + "api_get_task", + "api_form", + "git_call", + "db_call" + ], + "description": "Node type:
`go` — Start node (when only this logic type object exists in a logics array)
`go_if_const` — Condition node or an optional part of the Set State node
`set_param` — Set Parameters node
`api` — API Call node
`api_callback` — (when 'conv_type' = \"state\") — Set State node (State Diagram), this node also can have the go_if_const logic (optional)
`api_callback` — (when 'conv_type' = \"process\") — Waiting for Callback node
`api_sum` — Sum node
`api_code` — Code node
`api_copy` — Copy Task node (when 'mode' = \"create\")
`api_copy` — Modify Task node (when 'mode' = \"modify\")
`api_rpc` — Call a Process node
`api_rpc_reply` — Reply to Process node
`api_queue` — Queue node
`api_get_task` — Get from Queue node
`git_call` — Git Call node
`db_call` — Database Call node
(also the Delay node has 'logics' = [], only 'semaphors' are non-empty)" + }, + "mode": { + "type": "string", + "enum": [ + "create", + "modify", + "key_value", + "keys" + ], + "description": "`create` — Copy Task node
`modify` — Modify Task node
`key_value` — Reply to Process node returns an object with key-value pairs
`keys` — Reply to Process node returns an array with keys only
This response parameter exists for the following nodes: Copy Task, Modify Task, and Reply to Process." + }, + "to_node_id": { + "type": "string", + "example": "62b599ba094bab2fe4000308", + "description": "ID of the next node which is connected to the current node.
This response parameter exists for every node, except for the Final node (both Success and Error)." + }, + "conditions": { + "type": "array", + "description": "An array with condition key-value pairs data
This response parameter exists only for Condition and Set State (option) nodes.", + "items": { + "type": "object", + "properties": { + "param": { + "type": "string", + "description": "The key from key-value pairs (variable)" + }, + "const": { + "type": "string", + "description": "The value from key-value pairs (this value is compared with variable's value or is used with a regular expression in case the parameter 'fun' = \"regexp\")" + }, + "fun": { + "type": "string", + "enum": [ + "more", + "less", + "eq", + "not_eq", + "regexp" + ], + "description": "Comparison in a condition:
`more` — (>) greater than
`less` — (<) less than
`eq` — (==) equal to
`not_eq` — (!=) not equal to
`regexp` — regular expression" + }, + "cast": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "description": "type of value from key-value pairs" + } + } + } + }, + "data": { + "type": "object", + "description": "Button \"+ Add key-value\" adds a new parameter to node settings:
Key - parameter name
Value can be specified with:
- Constant.
- {{parameter_name}} from a task which name will be pasted.
- Any system parameter of the current process. For example, {{root.ref}} or {{root.task_id}}.
If the Copy all parameters flag is checked, it is not required to add new parameters.
Otherwise be sure to add at least one parameter.

Parameters that we send to another node — object with keys-values (type string both).
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable.
This response parameter exists for the following nodes: Copy Task, Modify Task, and Queue node." + }, + "data_type": { + "type": "object", + "description": "Object with keys-values (string type both).
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable (value type from 'data' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for the following nodes: Copy Task, Modify Task, and Queue node." + }, + "res_data": { + "oneOf": [ + { + "type": "object", + "description": "An object with keys-values (string type both) when node logics parameter 'mode' = \"key_value\".
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable." + }, + { + "type": "array", + "items": { + "type": "string", + "description": "An array with keys only — when node logics parameter 'mode' = \"keys\".
\"key\" is a variable name (new or already existing)." + } + } + ], + "description": "Parameters that we send to another node.
This response parameter exists only for the Reply to Process node." + }, + "res_data_type": { + "type": "object", + "description": "An object with keys-values (type string both).
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable (value type from 'res_data' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists only for the Reply to Process node." + }, + "throw_exception": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "The flag shows a state that can be defined by the \"Throw exception\" option in node settings.
This response parameter exists only for the Reply to Process node." + }, + "exception_reason": { + "type": "string", + "description": "Error message - exception reason
This response parameter exists only for the Reply to Process node with the \"Throw exception\" option enabled and error message specified in node settings." + }, + "group": { + "type": "string", + "enum": [ + "", + "all" + ], + "description": "This response parameter is set to `all` when the \"Copy all task parameters to the new task\" option is enabled in node settings, and there are no specified additional key-value pairs.
This response parameter exists for the following nodes: Copy Task, Modify Task, and Call a Process." + }, + "ref": { + "type": "string", + "description": "Task reference can be specified with:
- Any system parameter of the current process. For example, {{root.ref}} or {{root.task_id}}.
- Any other parameter of the current task {{parameter_name}}.
- Constant - for example: config, ref, etc.
This response parameter exists only for Copy Task and Modify Task nodes." + }, + "send_parent_data": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "This response parameter exists only for Copy Task and Modify Task nodes." + }, + "is_sync": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "This response parameter equals \"true\" when the \"Synchronous callback\" option is enabled in node settings.
This response parameter exists only for the Modify Task node." + }, + "conv_id": { + "type": "integer", + "description": "ID of the Process / State Diagram to which we send our task (or a request in case of using the Get from Queue node).
This option value can be specified manually or by copying the process ID from \"tree of folders\" (in node settings).
Process / State Diagram can be found by name, ID, or using the {{conv_id}} (parameter of the task).
This response parameter exists for nodes: Copy Task, Modify Task, Call a Process, and Get from Queue." + }, + "user_id": { + "type": "integer", + "description": "ID of User - last node editor
This response parameter exists for nodes: Copy Task, Modify Task, and Call a Process." + }, + "extra": { + "type": "object", + "description": "Request parameters — object with keys-values (type string both).
\"key\" is a variable name - parameter name (new or already existing) and \"value\" is a value from a task or a new value of this variable (constant value) — or just key-value pairs in case with the API Call node.
In case with the Sum node, \"Key\" is the specified name of a parameter that will contain the sum of values.
\"Value\" - {{parameter_name}} from a task which will be summed up or a constant (constant value).
This response parameter exists for the following nodes: Sum, Call a Process, and API Call (optional)." + }, + "extra_type": { + "type": "object", + "description": "An object with keys-values (type string both)
\"key\" is a variable name (new or already exists) — or just a key in case with the API Call node, and the value is type of new value of this variable (type of value from 'extra' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for nodes: Call a Process and API Call (optional)." + }, + "err_node_id": { + "type": "string", + "description": "ID of the Error node (that will handle errors), connected with the current node.
This response parameter exists for Code, Call a Process node, Set Parameters, Modify Task, Copy Task, Get from Queue, Git Call v2 node, Database Call node, API Call nodes." + }, + "instance_id": { + "type": "integer", + "description": "Database instance ID
This response parameter exists only for the Database Call node." + }, + "query": { + "type": "string", + "description": "SQL query that will be executed.
This response parameter exists only for the Database Call node." + }, + "version": { + "type": "integer", + "description": "Node version
This response parameter exists only for the Git Call node." + }, + "lang": { + "type": "string", + "enum": [ + "js", + "erl", + "golang", + "python", + "php", + "java", + "lisp", + "clojure", + "prolog", + "dockerfile" + ], + "description": "This response parameter describes a programming language used used in code written in Code (js, erl) and Git Call nodes (js, golang, python, php, java, lisp, clojure, prolog, dockerfile):
`js` — JavaScript
`erl` — Erlang
`golang` — Go
`python` — Python
`php` — PHP
`java` — Java
`lisp` - Lisp
`clojure` - Clojure
`prolog` - Prolog
`dockerfile` - Dockerfile
This response parameter exists for the following nodes: Code and Git Call." + }, + "src": { + "type": "string", + "description": "This response parameter returns source code of Code node, Git Call node.
The value can be `\"\"` empty string when the Git Call node has defined Repo URL.
This response parameter exists for the following nodes: Code and Git Call." + }, + "repo": { + "type": "string", + "description": "Repo URL, can be `\"\"` empty string when web not define it in node settings.
This response parameter exists only for the Git Call node." + }, + "script": { + "type": "string", + "description": "Build command
This response parameter exists only for the Git Call node." + }, + "commit": { + "type": "string", + "description": "Tag, Branch or Commit
This response parameter exists only for the Git Call node." + }, + "path": { + "type": "string", + "description": "Project path
This response parameter exists only for the Git Call node." + }, + "handler": { + "type": "string", + "description": "The option \"Handler\" in node settings.
This response parameter exists when the parameter 'lang' = \"java\".
This response parameter exists only for the Git Call node." + }, + "log": { + "type": "object", + "description": "This response parameter exists only for the Git Call node." + }, + "code_error": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "This response parameter exists only for the Git Call node." + }, + "code": { + "type": "string", + "description": "This response parameter returns source code of the Git Call node.
The value can be `\"\"` empty string when the Git Call node has defined Repo URL.
This response parameter exists only for the Git Call node." + }, + "format": { + "type": "string", + "enum": [ + "", + "conveyor", + "raw" + ], + "description": "Request format:
`\"\"` (empty string) — Default — enables the selection of an HTTP method of a request to API.
`conveyor` — Corezoid — request to API in Corezoid format.
`raw` — Raw — get a raw result of an http request.
This response parameter exists for the API Call node." + }, + "method": { + "type": "string", + "enum": [ + "POST", + "GET", + "PUT", + "DELETE", + "HEAD", + "PATCH" + ], + "description": "[HTTP request method](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods)
This response parameter exists for the API Call node." + }, + "url": { + "type": "string", + "description": "API's request URL
This response parameter exists for the API Call node." + }, + "max_threads": { + "type": "integer", + "default": 11, + "description": "Limit the number of simultaneous requests to the API.
This response parameter exists for the API Call node." + }, + "debug_info": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "The flag for enable/disable return debug info.
The option \"Include debug info\" in the API Call node settings
This response parameter exists for the API Call node." + }, + "customize_response": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "The flag for enable/disable return customizing response.
The option \"Customize response parameters\" in the API Call node settings.
This response parameter exists for the API Call node." + }, + "response": { + "type": "object", + "description": "Response parameters from API
Can be customized by enabling the \"Customize response parameters\" option in the API Call node settings.
The 'response' and 'response_type' response parameters described with default key-value pairs here.
This response parameter exists for the API Call node.", + "properties": { + "header": { + "type": "string", + "description": "response header" + }, + "body": { + "type": "string", + "description": "response body" + } + } + }, + "response_type": { + "type": "object", + "description": "Type of data in response from API (in 'response' response parameter).
Keys and values are string type both.
Keys are same as in 'response' response parameter.
Values can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for the API Call node.", + "properties": { + "header": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "default": "object", + "description": "response header value type" + }, + "body": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "default": "object", + "description": "response body value type" + } + } + }, + "extra_headers": { + "type": "object", + "description": "Request headers, can be defined with the \"Header parameters\" parameter values in the API Call node settings.
Object with keys-values (string type both). `{}` empty object by default — when not a single header is defined.
This response parameter exists for the API Call node." + }, + "send_sys": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "The \"Add system parameters to the request\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "cert_pem": { + "type": "string", + "description": "Certificate, can be defined by enabling the \"Sign the request by certificate\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "api_secret_outer": { + "type": "string", + "description": "Secret key, can be defined by enabling the \"Sign the request with the secret key\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "content_type": { + "type": "string", + "enum": [ + "application/json", + "application/x-www-form-urlencoded", + "application/xml", + "text/xml", + "application/soap+xml" + ], + "default": "application/json", + "description": "Response format ([MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types), [Media type](https://www.iana.org/assignments/media-types/media-types.xhtml)), Can be changed by enabling the \"Customize response parameters\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "rfc_format": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "The \"RFC standard response\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "is_migrate": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "System parameter:
`true` — new format of logics
`false` — old format of logics
This response parameter exists for the API Call node." + }, + "order_by": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ], + "description": "`ASC` — Take from the queue start;
`DESC` — Take from the queue end
This response parameter exists for the Get from Queue node." + }, + "node_id": { + "type": "string", + "description": "Queue node ID
Example: \"6320a47356167c3e5500fee9\"
This response parameter exists for the Get from Queue node." + }, + "convTitle": { + "type": "string", + "description": "Title of process with the Queue node.
This response parameter exists for the Get from Queue node." + } + } + } + }, + "semaphors": { + "type": "array", + "description": "The array of node escalations settings — counter, timer.
", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "time", + "count" + ], + "description": "`time` — timeout in seconds,
This parameter value can exist in the following nodes: Delay, Git Call, Set State (State diagram), Waiting for Callback, API Call, Copy Task, Modify Task, and Sum (optional).

`count` — number of tasks in a node.
When the \"Alert if the number of tasks in the node queue reaches the following number\" option is enabled in node settings." + }, + "value": { + "oneOf": [ + { + "type": "integer", + "description": "This parameter value can be of the integer type when a number of seconds is stored - the parameter 'type' = \"time\".
(86400 seconds = 24 hours = 1 day)
Example: 86400

The parameter value also can be of the integer type when a number of tasks is stored - the parameter 'type' = \"count\".
Example: 30" + }, + { + "type": "string", + "description": "This parameter value can be of the string type when code is stored - the parameter 'type' = \"time\".
Example: \"$.unixtime(%y-%m-%d %h:%i:%s+1)\"
Example: \"$.unixtime(%y-%m-%d+1 09:00:00)\"" + } + ] + }, + "dimension": { + "type": "string", + "enum": [ + "sec", + "min", + "hour", + "day" + ], + "description": "value measuring unit" + }, + "to_node_id": { + "type": "string", + "description": "ID of the next node connected to the current node
Example: \"631f4366513aa068cbde4460\"" + }, + "esc_node_id": { + "type": "string", + "description": "ID of the next node (End: Error) connected to the current node.
This response parameter is active after enabling the \"Alert if the number of tasks in the node queue reaches the following number\" option in node settings.
Example: \"631f4366513aa068cbde4460\"
This response parameter is present when the response parameters 'type' = \"count\"." + } + } + } + }, + "stub": { + "description": "A set of stubs for the node. Each branch in `stub.logics` describes what response the node will return during \"mock\" execution.", + "properties": { + "logics": { + "type": "array", + "description": "An array of alternative branches. Each element is an array of one or two logic objects: either only `api_rpc_reply`, or `go_if_const` followed by `api_rpc_reply`.", + "items": { + "type": "array", + "minItems": 1, + "items": { + "oneOf": [ + { + "type": "object", + "additionalProperties": false, + "properties": { + "type": { + "type": "string", + "enum": [ + "go_if_const" + ] + }, + "conditions": { + "type": "array", + "description": "Conditions for the branch to run.", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "param": { + "type": "string", + "description": "Variable name" + }, + "const": { + "type": "string", + "description": "Constant value to compare with" + }, + "fun": { + "type": "string", + "enum": [ + "more", + "less", + "eq", + "not_eq", + "regexp" + ], + "description": "Comparison function" + }, + "cast": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "description": "Cast type for the variable" + } + }, + "required": [ + "param", + "const", + "fun" + ] + } + } + }, + "required": [ + "type", + "conditions" + ] + }, + { + "type": "object", + "additionalProperties": false, + "properties": { + "type": { + "type": "string", + "enum": [ + "api_rpc_reply" + ] + }, + "mode": { + "type": "string", + "enum": [ + "key_value", + "keys" + ], + "description": "Reply format: `key_value` — object with key-value pairs, `keys` — array of keys only." + }, + "res_data": { + "oneOf": [ + { + "type": "object", + "description": "Object with key-value pairs when `mode = key_value`." + }, + { + "type": "array", + "items": { + "type": "string" + }, + "description": "Array of keys when `mode = keys`." + } + ] + }, + "res_data_type": { + "type": "object", + "description": "Types of values for each key in `res_data`. Values can be: string | number | boolean | array | object." + }, + "throw_exception": { + "type": "boolean", + "default": false + }, + "exception_reason": { + "type": "string", + "description": "Exception reason when `throw_exception = true`." + } + }, + "required": [ + "type", + "mode", + "res_data" + ] + } + ] + } + } + } + }, + "required": [ + "logics" + ] + }, + "modify-request-4": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "conv_id", + "obj_type", + "obj_id", + "logics" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process in which a Node will be modified" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + }, + "stub": { + "allOf": [ + { + "$ref": "#/components/schemas/stub" + } + ] + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node (one process can have only one start node)
`2` — final node
`3` — escalation" + }, + "position": { + "type": "array", + "description": "An array of x and y coordinates" + }, + "extra": { + "type": "object", + "description": "A stringified object with additional node settings (expand or minimize, node icon)" + }, + "options": { + "type": "object", + "properties": { + "save_task": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Flag for saving tasks in a Final node. By default, it’s checked." + } + }, + "description": "A stringified object with additional node settings (save_task)" + } + } + }, + "modify-response-4": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process in which the Node will be created" + } + } + }, + "list-request-5": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "conv_id", + "obj_id", + "limit" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process which Nodes are listed" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "limit": { + "type": "integer", + "description": "Specify the number of history records to return" + }, + "offset": { + "type": "integer", + "description": "Specify the offset of the first history record to return" + }, + "work_user_id": { + "type": "integer", + "description": "ID of a user which created a task" + }, + "sort": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ], + "description": "this parameter is used for sorting result data:
`ASC` — in ascending order;
`DESC` — in descending order." + }, + "filters": { + "type": "array", + "description": "You can use this parameter for filtering tasks by reference in a node", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "enum": [ + "ref" + ], + "description": "The parameter by which tasks are acquired" + }, + "value": { + "type": "string", + "minLength": 1, + "maxLength": "infinity", + "description": "The reference of Task" + }, + "fun": { + "type": "string", + "enum": [ + "eq" + ] + } + } + } + } + } + }, + "list-response-5": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "node" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "count": { + "type": "integer", + "description": "number of received tasks" + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Task data", + "properties": { + "__source_origin__": { + "type": "object", + "description": "csv file source data
This response parameter is present only if task was created from a csv file", + "properties": { + "filename": { + "type": "string", + "description": "System parameter — source file name" + }, + "ip": { + "type": "string", + "description": "System parameter — IP from that file uploaded" + } + } + }, + "__user_id__": { + "type": "string", + "description": "System parameter — User ID who created a task" + } + } + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task ID" + }, + "ref": { + "type": "string", + "description": "Task reference" + }, + "status": { + "type": "string", + "enum": [ + "created", + "processing", + "delayed", + "processed", + "canceled", + "deleted" + ], + "description": "Task status" + }, + "user_id": { + "type": "integer", + "description": "ID of a User which created a Task" + }, + "create_time": { + "type": "integer", + "description": "Task creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Task change time in unixtime format" + }, + "node_prev_id": { + "type": "string", + "description": "ID of the previous node on the Task movement path" + } + } + } + } + } + }, + "show-request-4": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "conv_id", + "obj_id" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process for which Node details will be shown" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "show-response-5": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "node" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000 + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255 + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — custom
`1` — start (a process can have only one Start node)
`2` — final
`3` — escalation" + }, + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + }, + "count": { + "type": "integer", + "description": "A total number of tasks handled in a Node" + } + } + }, + "delete-request-4": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "conv_id", + "obj_id" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process in which the Node will be deleted" + }, + "obj_alias": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Short name of a company Alias linked to the Process.
You can use it instead of the 'conv_id'" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "delete-response-4": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "reset-request": { + "type": "object", + "title": "reset", + "required": [ + "type", + "obj", + "conv_id", + "obj_id" + ], + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "reset" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process in which Node counters will be reset" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "reset-response": { + "type": "object", + "title": "reset", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + } + } + }, + "example-create-request-3": { + "ops": [ + { + "id": "3403c54d-3b17-f75f-deea-f5c6fee4c38e", + "type": "create", + "obj": "node", + "conv_id": 789846, + "title": "Name", + "description": "Description", + "obj_type": 0, + "version": 1662369848 + } + ] + }, + "example-create-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "3403c54d-3b17-f75f-deea-f5c6fee4c38e", + "proc": "ok", + "obj": "node", + "obj_id": "6315c04e094bab6d1300d57e", + "version": 1662369848 + } + ] + }, + "example-modify-request-4": { + "ops": [ + { + "type": "modify", + "obj": "node", + "obj_id": "6315c04e094bab6d1300d57e", + "conv_id": 789846, + "title": "test", + "description": "test description", + "obj_type": 0, + "logics": [ + { + "to_node_id": "6316f5c5094bab1707005ac9", + "type": "go_if_const", + "conditions": [ + { + "param": "foo", + "const": "bar", + "fun": "eq", + "cast": "string" + } + ] + }, + { + "type": "go", + "to_node_id": "62b41bdd56167c23af018057" + } + ], + "semaphors": [], + "position": [ + 520, + 204 + ], + "extra": { + "modeForm": "expand", + "icon": "" + }, + "version": 1662369848 + } + ] + }, + "example-modify-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 789846, + "obj_id": "6315c04e094bab6d1300d57e" + } + ] + }, + "example-list-request-5": { + "ops": [ + { + "limit": 10, + "offset": 0, + "type": "list", + "obj": "node", + "company_id": "i260836082", + "conv_id": 880416, + "obj_id": "6304cd2356167c626500036c", + "work_user_id": 19766, + "sort": "ASC", + "filters": [ + { + "name": "ref", + "value": "1", + "fun": "eq" + } + ] + } + ] + }, + "example-list-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "node", + "obj_id": "6304cd2356167c626500036c", + "count": 12, + "count_created": 12, + "count_processing": 0, + "count_delayed": 0, + "proc": "ok", + "list": [ + { + "data": { + "__source_origin__": { + "filename": "1144692_conv_64217c26094bab6fa00052d2_1679916520.csv", + "ip": "127.0.0.1" + }, + "__user_id__": 25130, + "param1": 1, + "param2": 2 + }, + "obj": "task", + "obj_id": "6346b6f856167c13a1001941", + "ref": "1", + "status": "processed", + "user_id": 19766, + "create_time": 1665578744, + "change_time": 1665578744, + "node_prev_id": "6304cd2356167c626500036b" + } + ] + } + ] + }, + "example-show-request-4": { + "ops": [ + { + "type": "show", + "obj": "node", + "obj_id": "63199a0b56167c0148001712", + "conv_id": 881581, + "company_id": "i260836082" + } + ] + }, + "example-show-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "node", + "obj_id": "63199a0b56167c0148001712", + "title": "", + "description": "", + "logics": [], + "semaphors": [ + { + "type": "time", + "value": 1800, + "dimension": "min", + "to_node_id": "63060854094bab7c46001dab" + } + ], + "count": 0, + "obj_type": 0 + } + ] + }, + "example-delete-request-4": { + "ops": [ + { + "type": "delete", + "obj": "node", + "company_id": "i260836082", + "obj_id": "62de4889094bab69e6001c53", + "conv_id": 826283, + "version": 1658734725 + } + ] + }, + "example-delete-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": "62de4889094bab69e6001c53", + "proc": "ok" + } + ] + }, + "example-reset-request": { + "ops": [ + { + "type": "reset", + "conv_id": 881581, + "obj": "node", + "obj_id": "63060854094bab7c46001dab", + "company_id": "i260836082" + } + ] + }, + "example-reset-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "node", + "obj_id": "63060854094bab7c46001dab" + } + ] + }, + "list-request-6": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "pattern" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "nodes" + }, + "pattern": { + "type": "string", + "minLength": 1, + "maxLength": 150, + "description": "The parameter by which Nodes are searched. Can be a title, ID." + }, + "conv_id": { + "type": "integer or string", + "description": "ID of a Process which Nodes will be listed" + } + } + }, + "list-response-6": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer or string", + "description": "ID of a Process for which Nodes are listed" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000 + }, + "id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node ID" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255 + }, + "type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node
`2` — final node
`3` — escalation - special system node
this response parameter is present only if the request parameter 'list_obj' != \"group\"" + }, + "status": { + "type": "integer", + "enum": [ + 1 + ], + "description": "Node status:
`1` — active" + } + } + } + } + } + }, + "example-list-request-6": { + "ops": [ + { + "type": "list", + "obj": "nodes", + "pattern": "Test", + "conv_id": 909237 + } + ] + }, + "example-list-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "conv_id": "909237", + "description": "", + "id": "631eea6f56167c0148014b74", + "title": "Test", + "type": 0, + "status": 1 + } + ] + } + ] + }, + "create-request-5": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "obj_type", + "title" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "group" + }, + "obj_type": { + "type": "string", + "emum": [ + "admins" + ], + "description": "User Group type:
`admins` — admins group type." + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Name of a User Group being created" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "create-response-5": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group being created" + } + } + }, + "modify-request-5": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id", + "obj_type", + "status" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that will be modified" + }, + "obj_type": { + "type": "string", + "emum": [ + "admins" + ], + "description": "User Group type:
`admins` — admins group type." + }, + "status": { + "type": "string", + "enum": [ + "actived", + "not_actived", + "deleted" + ], + "description": "Current Group status" + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "User Group Name" + } + } + }, + "modify-response-5": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that was modified" + } + } + }, + "list-request-7": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id", + "list_obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of a User Group that will be listed" + }, + "list_obj": { + "type": "string", + "emum": [ + "user", + "conv" + ], + "description": "list object:
`user` - show all users in a group;
`conv` - show all processes attached to a group." + } + } + }, + "list-response-7": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Users Group ID" + }, + "owner_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Group owner ID" + }, + "owner_name": { + "type": "string", + "description": "Group owner name" + }, + "list": { + "type": "array", + "description": "List of users who are members of a User Group", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "enum": [ + "user", + "conv" + ], + "description": "list object" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "User ID" + }, + "title": { + "type": "string", + "description": "User name" + }, + "logins": { + "type": "array", + "descriotion": "list of user logins", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "ldap", + "goole", + "facebook", + "api", + "phone", + "corezoid", + "github" + ], + "description": "allowed login types" + }, + "login": { + "type": "string", + "description": "User login" + } + } + } + } + } + } + } + } + }, + "list-response-list_obj-conv": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "User Group ID" + }, + "list": { + "type": "array", + "description": "List of processes that are attached to the User Group", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Process ID" + }, + "title": { + "type": "string", + "description": "Process name" + }, + "description": { + "type": "string", + "description": "Process description" + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug", + "active_debug", + "transient" + ], + "description": "Process status" + } + } + } + } + } + }, + "delete-request-5": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that will be deleted" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-5": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that was deleted" + } + } + }, + "restore-request-3": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "group" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that will be restored" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "restore-response-3": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj" + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "ID of a User Group that was restored" + } + } + }, + "example-create-request-4": { + "ops": [ + { + "title": "test-group", + "type": "create", + "obj": "group", + "obj_type": "admins" + } + ] + }, + "example-create-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "example-modify-request-5": { + "ops": [ + { + "title": "test-group1", + "type": "modify", + "obj": "group", + "obj_id": 70800, + "obj_type": "admins", + "status": "actived" + } + ] + }, + "example-modify-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "example-list-request-7": { + "ops": [ + { + "type": "list", + "obj": "group", + "obj_id": 70800, + "list_obj": "user" + } + ] + }, + "example-list-response-list_obj-user": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "group", + "obj_id": 70800, + "owner_id": 19766, + "owner_name": "Owner", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 25399, + "title": "User", + "logins": [ + { + "type": "google", + "login": "user@gmail.com" + } + ] + } + ] + } + ] + }, + "example-list-response-list_obj-conv": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "group", + "obj_id": 56930, + "proc": "ok", + "list": [ + { + "obj_id": 347700, + "title": "New object", + "description": "", + "status": "active" + }, + { + "obj_id": 347357, + "title": "New object1", + "description": "", + "status": "active" + } + ] + } + ] + }, + "example-delete-request-5": { + "ops": [ + { + "type": "delete", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "example-delete-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "example-restore-request-3": { + "ops": [ + { + "type": "restore", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "example-restore-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "restore", + "obj": "group", + "obj_id": 70800 + } + ] + }, + "create-request-6": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "instance_type", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Instance title (name)" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Instance description" + }, + "folder_id": { + "type": "integer", + "description": "ID of a folder in which a DB connection is stored" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "data": { + "type": "object", + "description": "An object with connection settings", + "required": [ + "driver", + "database", + "host", + "port", + "username", + "password", + "ssl", + "timeoutMs" + ], + "properties": { + "driver": { + "type": "string", + "description": "DB instance type", + "enum": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ] + }, + "database": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB name" + }, + "host": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB instance host" + }, + "port": { + "type": "string or integer", + "description": "DB instance port" + }, + "username": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User login for accessing a DB" + }, + "password": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User password for accessing a DB" + }, + "ssl": { + "type": "boolean", + "enum": [ + false, + true + ], + "description": "SSL use for a connection" + }, + "timeoutMs": { + "type": "string", + "description": "Maximum period of time to wait for a response from an instance, milliseconds" + } + } + } + } + }, + "create-response-6": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + } + } + }, + "check-request": { + "type": "object", + "title": "check", + "required": [ + "type", + "obj", + "instance_type", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "check" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Instance title (name)" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Instance description" + }, + "folder_id": { + "type": "integer", + "description": "ID of a folder in which a DB connection is stored" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "data": { + "type": "object", + "description": "An object with connection settings", + "required": [ + "driver", + "database", + "host", + "port", + "username", + "password", + "ssl", + "timeoutMs" + ], + "properties": { + "driver": { + "type": "string", + "description": "DB instance type", + "enum": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ] + }, + "database": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB name" + }, + "host": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB instance host" + }, + "port": { + "type": "string or integer", + "description": "DB instance port" + }, + "username": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User login for accessing a DB" + }, + "password": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User password for accessing a DB" + }, + "ssl": { + "type": "boolean", + "enum": [ + false, + true + ], + "description": "SSL use for a connection" + }, + "timeoutMs": { + "type": "string", + "description": "Maximum period of time to wait for a response from an instance, milliseconds" + } + } + } + } + }, + "check-response": { + "type": "object", + "title": "check", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + } + } + }, + "modify-request-6": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id", + "instance_type", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "Instance ID" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Instance title (name)" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Instance description" + }, + "data": { + "type": "object", + "description": "Object with connection settings", + "required": [ + "driver", + "database", + "host", + "port", + "username", + "password", + "ssl", + "timeoutMs" + ], + "properties": { + "driver": { + "type": "string", + "description": "DB instance type", + "enum": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ] + }, + "database": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB name" + }, + "host": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB instance host" + }, + "port": { + "type": "string or integer", + "description": "DB instance port" + }, + "username": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User login for accessing a DB" + }, + "password": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User password for accessing a DB" + }, + "ssl": { + "type": "boolean", + "enum": [ + false, + true + ], + "description": "SSL use for a connection" + }, + "timeoutMs": { + "type": "string", + "description": "Maximum time interval to wait for a response from an instance, milliseconds" + } + } + } + } + }, + "modify-response-6": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + } + } + }, + "list-request-8": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id", + "list_obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "Instance ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "a list object, only the \"group\" parameter is allowed" + } + } + }, + "list-response-8": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "a list object, only the \"group\" parameter is allowed" + }, + "list": { + "type": "array", + "description": "A list of users/groups/api-keys that have access to an instance.", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "enum": [ + "user", + "gruop" + ], + "description": "list object" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Object ID" + }, + "title": { + "type": "string", + "description": "Object name" + }, + "obj_type": { + "type": "string", + "description": "(ONLY FOR User Group) Type of User Group", + "enum": [ + "admins" + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "obj_status": { + "type": "string", + "description": "Object status", + "enum": [ + "actived", + "not actived", + "deleted" + ] + } + } + } + } + } + }, + "show-request-5": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "Instance ID" + } + } + }, + "show-response-6": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "title": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Instance name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Instance description" + }, + "create_time": { + "type": "integer", + "description": "Time of a Database instance creation in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Time of a Database instance change in unixtime format" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "folder_id": { + "type": "integer", + "description": "ID of a Folder in which a DB connection is stored" + }, + "status": { + "type": "string", + "enum": [ + "active", + "deleted", + "transient" + ], + "description": "Object status" + }, + "owner_name": { + "type": "string", + "description": "Name of a Database instance owner" + }, + "owner_login": { + "type": "string", + "description": "Login of a Database instance owner" + }, + "parent_obj_id": { + "type": "integer", + "description": "Parent Object ID" + }, + "parent_obj_type": { + "type": "string", + "default": "project", + "description": "Parent Object Type" + }, + "data": { + "type": "object", + "description": "Object with connection settings", + "required": [ + "driver", + "database", + "host", + "port", + "username", + "password", + "ssl", + "timeoutMs" + ], + "properties": { + "driver": { + "type": "string", + "description": "DB instance type", + "enum": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ] + }, + "database": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB name" + }, + "host": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "DB instance host" + }, + "port": { + "type": "string or integer", + "description": "DB instance port" + }, + "username": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User login for accessing a DB" + }, + "password": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "User password for accessing a DB" + }, + "ssl": { + "type": "boolean", + "enum": [ + false, + true + ], + "description": "SSL use for a connection" + }, + "timeoutMs": { + "type": "string", + "description": "Maximum period of time to wait for a response from an instance, milliseconds" + } + } + } + } + }, + "link-request-3": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "obj_to", + "obj_to_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "Instance ID" + }, + "obj_to": { + "type": "string", + "enum": [ + "user", + "group" + ], + "description": "Shared access type:
`user` — sharing access with an API Key / User;
`group` — sharing access with a Group." + }, + "obj_to_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "ID of a User, API Key or a User Group" + }, + "login": { + "type": "string", + "description": "User login" + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + }, + "link-response-3": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "user", + "group" + ], + "description": "Shared access type:
`user` — sharing access with an API Key / User;
`group` — sharing access with a Group." + }, + "obj_to_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "ID of a User, API Key or a User Group" + }, + "obj_to_title": { + "type": "string", + "description": "User Name" + }, + "action_type": { + "allOf": [ + { + "$ref": "#/components/schemas/action_type" + } + ] + } + } + }, + "favorite-request-3": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instanse" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Instance ID", + "minimum": 0 + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "favorite-response-3": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + } + } + }, + "delete-request-6": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instanse" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Instance ID", + "minimum": 0 + } + } + }, + "delete-response-6": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + } + } + }, + "restore-request-4": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instanse" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Instance ID", + "minimum": 0 + } + } + }, + "restore-response-4": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + }, + "parent_folder_id": { + "type": "integer", + "description": "ID of a Folder in which a DB connection was restored" + } + } + }, + "destroy-request-3": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "instanse" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "Instance ID", + "minimum": 0 + } + } + }, + "destroy-response-3": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "instance" + }, + "obj_id": { + "type": "integer", + "description": "Instance ID" + } + } + }, + "example-create-request-5": { + "ops": [ + { + "title": "test_db", + "description": "", + "folder_id": 0, + "obj": "instance", + "instance_type": "db_call", + "data": { + "driver": "postgres", + "database": "database", + "host": "https://example.com", + "port": "5432", + "username": "username", + "password": "123456789", + "ssl": false, + "timeoutMs": "3000" + }, + "type": "create" + } + ] + }, + "example-create-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "instance_type": "db_call", + "obj_id": 39171 + } + ] + }, + "example-check-request": { + "ops": [ + { + "title": "test_db", + "description": "", + "type": "check", + "obj": "instance", + "instance_type": "db_call", + "data": { + "driver": "postgres", + "host": "https;//example.com", + "port": "5432", + "username": "username", + "password": "12345678", + "ssl": false, + "database": "database", + "timeoutMs": "5000" + } + } + ] + }, + "example-check-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + }, + "example-modify-request-6": { + "ops": [ + { + "obj": "instance", + "type": "modify", + "obj_id": 39171, + "instance_type": "db_call", + "data": { + "driver": "postgres", + "database": "database", + "host": "https://example.com", + "port": "5432", + "username": "username", + "password": "12345678", + "ssl": false, + "timeoutMs": "5000" + } + } + ] + }, + "example-modify-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "instance_type": "db_call", + "obj_id": 39171 + } + ] + }, + "example-list-request-8": { + "ops": [ + { + "obj_id": 39171, + "obj": "instance", + "type": "list", + "list_obj": "group" + } + ] + }, + "example-list-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "obj_id": 64467, + "favorite": true, + "list_obj": "group", + "list": [ + { + "obj_id": 150159, + "obj": "group", + "title": "2354", + "obj_type": "admins", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "obj_status": "actived" + }, + { + "obj": "user", + "obj_id": 15, + "title": "gottabad", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + }, + "example-show-request-5": { + "ops": [ + { + "type": "show", + "obj": "instance", + "obj_id": 39171 + } + ] + }, + "example-show-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "instance", + "obj_id": 39171, + "title": "test_db", + "description": "", + "create_time": 1663833372, + "change_time": 1663840200, + "instance_type": "db_call", + "status": "active", + "company_id": null, + "data": { + "driver": "postgres", + "host": "https://example.com", + "port": 5432, + "username": "username", + "password": "12345678", + "database": "database", + "timeoutMs": 5000, + "ssl": false + }, + "folder_id": 0, + "owner_name": "owner_name", + "owner_login": "ownerlogin@gmail.com", + "parent_obj_id": 0, + "parent_obj_type": "folder" + } + ] + }, + "example-link-request-3": { + "ops": [ + { + "type": "link", + "obj": "instance", + "obj_id": 39171, + "obj_to": "user", + "obj_to_id": 25399, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "instance", + "obj_id": 39171, + "obj_to_type": "user", + "obj_to_id": 12345, + "obj_to_title": "Title", + "action_type": "link" + } + ] + }, + "example-favorite-request-3": { + "ops": [ + { + "type": "favorite", + "obj": "instance", + "obj_id": 39171, + "favorite": true + } + ] + }, + "example-favorite-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj": "instance" + } + ] + }, + "example-delete-request-6": { + "ops": [ + { + "type": "delete", + "obj": "instance", + "obj_id": 39171 + } + ] + }, + "example-delete-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "instance", + "obj_id": 39171, + "proc": "ok" + } + ] + }, + "example-restore-request-4": { + "ops": [ + { + "type": "restore", + "obj": "instance", + "obj_id": 39171 + } + ] + }, + "example-restore-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj": "instance", + "parent_folder_id": 0 + } + ] + }, + "example-destroy-request-3": { + "ops": [ + { + "type": "destroy", + "obj": "instance", + "obj_id": 39171 + } + ] + }, + "example-destroy-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 39171, + "obj_type": "instance" + } + ] + }, + "create-request-7": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "company_id", + "vsn", + "stage_from_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "vsn": { + "type": "string", + "minLength": 1, + "maxLength": 127, + "pattern": "^[0-9.]*$", + "description": "Version number" + }, + "changelog": { + "type": "string", + "minLength": 0, + "maxLength": 5000, + "allowed": null, + "description": "Version Changelog" + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 256, + "description": "Version name" + }, + "stage_from_id": { + "type": "integer", + "minLength": 1, + "maxLength": "infinity", + "description": "ID of the Stage, from that you want to create Version" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + } + } + }, + "create-response-7": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity" + }, + "link": { + "type": "string", + "description": "Part of URL to downloading Version" + } + } + }, + "modify-request-7": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Version ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "changelog": { + "type": "string", + "minLength": 0, + "maxLength": 5000, + "allowed": null, + "description": "Version Changelog" + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 256, + "description": "Version name" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + } + } + }, + "modify-response-7": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Version ID" + } + } + }, + "get-request": { + "type": "object", + "title": "get", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Version ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + } + } + }, + "get-response": { + "type": "object", + "title": "get", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Version ID" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when an ID of the user that sends a request is the same as the Version owner ID" + }, + "owner_id": { + "type": "integer", + "minLength": 0, + "maxLength": "infinity", + "description": "Version owner ID" + }, + "owner_name": { + "type": "string", + "description": "Version owner displayed name" + }, + "owner_login": { + "type": "string", + "description": "Version owner login" + }, + "obj_type": { + "type": "string", + "enum": [ + "version" + ], + "description": "An Object type" + }, + "project_title": { + "type": "string", + "description": "Project title" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_title": { + "type": "string", + "description": "Stage title" + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "vsn": { + "type": "string", + "minLength": 1, + "maxLength": 127, + "pattern": "^[0-9.]*$", + "description": "Version number" + }, + "changelog": { + "type": "string", + "minLength": 0, + "maxLength": 5000, + "allowed": null, + "description": "Version Changelog" + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 259, + "description": "Version name" + }, + "link": { + "type": "string", + "description": "Part of Version download URL" + }, + "create_time": { + "type": "integer", + "description": "Version creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Version change time in unixtime format" + }, + "user_id": { + "type": "integer", + "description": "User identifier" + }, + "status": { + "type": "integer", + "enum": [ + 1, + 3 + ], + "description": "Version status:
`1` — active
`3` — deleted" + }, + "file_format_vsn": { + "type": "integer", + "description": "Version of scheme version, for backward compatibility" + } + } + }, + "delete-request-7": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id", + "company_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Version ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + } + } + }, + "delete-response-7": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "description": "Version ID" + } + } + }, + "restore-request-5": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id", + "company_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Version ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + } + } + }, + "restore-response-5": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "description": "Version ID" + } + } + }, + "destroy-request-4": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id", + "company_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Version ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + } + } + }, + "destroy-response-4": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "obj_id": { + "type": "integer", + "description": "Version ID" + } + } + }, + "example-create-request-6": { + "ops": [ + { + "company_id": "i260836082", + "obj": "version", + "vsn": "1.0.0", + "changelog": "", + "project_id": 290551, + "stage_from_id": 290553, + "type": "create" + } + ] + }, + "example-create-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "version", + "obj_id": 12200, + "link": "version_290553_1.0.0_1664267658720.zip" + } + ] + }, + "example-modify-request-7": { + "ops": [ + { + "type": "modify", + "obj": "version", + "company_id": "i246198512", + "changelog": "test changelog", + "title": "test", + "obj_id": 3541, + "project_id": 169886 + } + ] + }, + "example-modify-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "version", + "obj_id": 3541 + } + ] + }, + "example-get-request": { + "ops": [ + { + "type": "get", + "obj": "version", + "company_id": "i246198512", + "obj_id": 3541, + "project_id": 169886 + } + ] + }, + "example-get-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "is_owner": true, + "owner_id": 12345, + "owner_name": "owner_name", + "owner_login": "owner_login@corezoid.com", + "obj_id": 3541, + "obj_type": "version", + "project_id": 169886, + "project_title": "New Project", + "stage_id": 170200, + "stage_title": "New Stage", + "vsn": "1.0.0", + "title": "test", + "changelog": "test changelog", + "link": "version_170200_1.0.0_1673516833548.zip", + "create_time": 1673516834, + "change_time": 1673516834, + "user_id": 12345, + "status": 1, + "file_format_vsn": 1 + } + ] + }, + "example-delete-request-7": { + "ops": [ + { + "type": "delete", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + }, + "example-delete-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + }, + "example-restore-request-5": { + "ops": [ + { + "type": "restore", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + }, + "example-restore-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + }, + "example-destroy-request-4": { + "ops": [ + { + "type": "destroy", + "obj": "version", + "obj_id": 12202, + "company_id": "i260836082", + "project_id": 290551 + } + ] + }, + "example-destroy-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "version", + "proc": "ok", + "obj_id": 12202 + } + ] + }, + "list-request-9": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "company_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "versions" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "sort": { + "type": "string", + "enum": [ + "title", + "vsn", + "date", + "status" + ], + "default": "vsn", + "description": "Name of field to sort result" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc", + "description": "this parameter is used for sorting result data:
`asc` — in ascending order;
`desc` — in descending order." + }, + "filter": { + "type": "string", + "enum": [ + "all", + "deleted", + "active" + ], + "description": "A filtering criterion" + } + } + }, + "list-response-9": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "versions" + }, + "list": { + "type": "array", + "description": "The list of Versions", + "items": { + "type": "object", + "properties": { + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as Version owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Version owner's ID" + }, + "owner_name": { + "type": "string", + "description": "Version owner name" + }, + "owner_login": { + "type": "string", + "description": "Version owner login" + }, + "obj_id": { + "type": "integer", + "description": "Version ID" + }, + "obj_type": { + "type": "string", + "description": "Object type" + }, + "project_title": { + "type": "string", + "description": "Project title" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_title": { + "type": "string", + "description": "Stage title" + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "vsn": { + "type": "string", + "description": "Version number" + }, + "title": { + "type": "string", + "description": "Version title" + }, + "changelog": { + "type": "string", + "description": "Version changelog" + }, + "link": { + "type": "string", + "description": "Part of URL for Version downloading" + }, + "create_time": { + "type": "string", + "description": "Version creation time, timestamp" + }, + "change_time": { + "type": "string", + "description": "Version change time in unixtime format" + }, + "user_id": { + "type": "integer", + "description": "ID of a user who created the Version" + }, + "status": { + "type": "integer", + "description": "Version status:
`1` — Active
`3` — Deleted" + }, + "file_format_vsn": { + "type": "integer", + "description": "Version of scheme version, for backward compatibility" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + } + } + } + }, + "example-list-request-9": { + "ops": [ + { + "sort": "vsn", + "order": "desc", + "company_id": "i260836082", + "obj": "versions", + "project_id": 290551, + "type": "list" + } + ] + }, + "example-list-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "versions", + "proc": "ok", + "list": [ + { + "is_owner": true, + "owner_id": 12345, + "owner_name": "Owner Name", + "owner_login": "owner_login@corezoid.com", + "obj_id": 12202, + "obj_type": "version", + "project_id": 290551, + "project_title": "New Project", + "stage_id": 290553, + "stage_title": "develop", + "vsn": "1.1.0", + "title": null, + "changelog": "test", + "link": "version_290553_1.1.0_1664271169182.zip", + "create_time": 1664271169, + "change_time": 1664271169, + "user_id": 12345, + "status": 1, + "file_format_vsn": 1, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + }, + "create-request-8": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "site", + "name", + "description" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company" + }, + "site": { + "type": "string", + "required": true, + "minLength": 3, + "maxLength": 510, + "example": "www.thewall.com", + "description": "Company site" + }, + "name": { + "type": "string", + "required": true, + "minLength": 3, + "maxLength": 510, + "example": "The Wall", + "description": "Company name" + }, + "description": { + "type": "string", + "required": true, + "minLength": 3, + "maxLength": 510, + "description": "Company description" + } + } + }, + "create-response-8": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company" + }, + "obj_id": { + "type": "string", + "description": "Company ID" + } + } + }, + "list-request-10": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company" + } + } + }, + "list-response-10": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company" + }, + "list": { + "type": "array", + "description": "List of companies", + "items": { + "type": "object", + "properties": { + "company_id": { + "type": "string", + "example": "i702619617", + "description": "Company ID" + }, + "title": { + "type": "string", + "example": "The Wall", + "description": "Company name" + }, + "description": { + "type": "string", + "description": "Company description" + }, + "status": { + "type": "string", + "description": "Company state", + "enum": [ + "actived", + "blocked", + "deleted" + ] + }, + "owner_user_id": { + "type": "integer", + "example": 1083, + "description": "Company owner ID" + }, + "create_time": { + "type": "integer", + "example": 1486043068, + "description": "Company creation time in the Unixtime format" + }, + "childs": { + "type": "integer", + "default": 1, + "description": "Quantity of subordinate companies" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as Company owner ID" + }, + "is_admin": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when the user that sends a request is the Company admin." + }, + "auth_providers": { + "type": "array", + "description": "Authentication providers available for this tenant", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "Provider ID from config file" + }, + "name": { + "type": "string", + "example": "The Wall", + "description": "Provider name from config file" + }, + "active": { + "type": "boolean", + "description": "Provider status" + } + } + } + }, + "user_status": { + "type": "string", + "enum": [ + "active", + "blocked" + ], + "description": "User status with this company" + } + } + } + } + } + }, + "example-create-request-7": { + "ops": [ + { + "type": "create", + "obj": "company", + "site": "www.thewall.com", + "name": "The Wall", + "description": "Corezoid company" + } + ] + }, + "example-create-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "648d1d34-4360-4fce-abce-3e67afde427f" + } + ] + }, + "example-list-request-10": { + "ops": [ + { + "type": "list", + "obj": "company" + } + ] + }, + "example-list-response-9": { + "id": "", + "proc": "ok", + "obj": "company", + "list": [ + { + "company_id": "i702619617", + "title": "The Wall", + "description": "string", + "status": "actived", + "owner_user_id": 1083, + "create_time": 1486043068, + "childs": 1, + "is_owner": true, + "is_admin": true, + "auth_providers": [ + { + "id": "google_saml_1", + "name": "Google SAML", + "active": true + } + ], + "user_status": "active" + } + ] + }, + "multitenant-create-request": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "login", + "login_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company" + }, + "login": { + "type": "string", + "required": true, + "example": "jon.snow@thewall.com", + "description": "Email address of the administrator of the created company." + }, + "login_type": { + "type": "string", + "required": true, + "example": "corezoid", + "enum": [ + "corezoid", + "google" + ], + "description": "Login type" + }, + "name": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "example": "The Wall", + "description": "Company name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "nullable": true, + "description": "Company description" + }, + "auth_providers": { + "type": "array", + "required": true, + "description": "Authentication providers available for this tenant" + } + } + }, + "multitenant-create-response": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company" + }, + "obj_id": { + "type": "string", + "description": "Company ID", + "example": "i702619617" + }, + "url": { + "type": "string", + "example": "https://admin.corezoid.com/set_password/637f5248020bf6913ce1a1bb80ba4069d10a22d?redirect_url=https://admin-pre.corezoid.com/api/2/plugins/invite/637f52488025f6913ce1a1bb80ba4069d10a22d", + "description": "Invite link for an administrator of the created company. Can be sent to the email address, that was specified in the input login parameter." + } + } + }, + "multitenant-modify-request": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "company_id", + "auth_providers" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company" + }, + "company_id": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "example": "i702619617", + "description": "Company ID" + }, + "status": { + "type": "string", + "enum": [ + "blocked", + "actived" + ], + "example": "blocked", + "description": "Status to be set" + }, + "blocked_reason": { + "type": "string", + "minLength": 3, + "maxLength": 2000, + "nullable": true, + "example": "The Wall", + "description": "For approve blocking company the name of the Company have to be set in this field." + }, + "name": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "example": "The Wall", + "description": "New name of the Company" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "nullable": true, + "description": "New description of the Company" + }, + "migrate_users": { + "type": "boolean", + "description": "Flag indicating the need for login type migration based on the authentication type in a specific company." + }, + "auth_providers": { + "type": "array", + "description": "Authentication providers available for this tenant" + } + } + }, + "multitenant-modify-response": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company" + }, + "company_id": { + "type": "string", + "description": "Company ID", + "example": "i702619617" + }, + "name": { + "type": "string", + "example": "The wall", + "description": "New name of the Company" + }, + "description": { + "type": "string", + "description": "New description of the Company" + }, + "status": { + "type": "string", + "enum": [ + "blocked", + "actived" + ], + "example": "blocked", + "description": "Status that has been set." + }, + "new_status": { + "type": "string", + "enum": [ + "blocked", + "actived" + ], + "example": "blocked", + "description": "New status" + }, + "old_status": { + "type": "string", + "enum": [ + "blocked", + "actived" + ], + "example": "actived", + "description": "Old status" + }, + "migrated_count": { + "type": "integer", + "description": "Count of migrated users
This response parameter is present when the request parameter 'migrate_users' = \"true\"." + }, + "auth_providers": { + "type": "array", + "description": "Authentication providers available for this tenant" + } + } + }, + "multitenant-delete-request": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company" + }, + "obj_id": { + "type": "string", + "minLength": 1, + "maxLength": 250, + "example": "i702619617", + "description": "Company ID" + } + } + }, + "multitenant-delete-response": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company" + }, + "obj_id": { + "type": "string", + "description": "Company ID", + "example": "i702619617" + } + } + }, + "example-multitenant-create-request": { + "ops": [ + { + "type": "create", + "obj": "company", + "login": "jane.doe@email.com", + "login_type": "corezoid", + "name": "Example", + "description": "test descr", + "auth_providers": [ + "google_saml_1" + ] + } + ] + }, + "example-multitenant-create-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "i702619617", + "url": "https://admin.corezoid.com/set_password/637f5248020bf6913ce1a1bb80ba4069d10a22d?redirect_url=https://admin-pre.corezoid.com/api/2/plugins/invite/637f52488025f6913ce1a1bb80ba4069d10a22d" + } + ] + }, + "example-multitenant-modify-request": { + "ops": [ + { + "type": "modify", + "obj": "company", + "company_id": "i702619617", + "status": "blocked", + "blocked_reason": "The Wall", + "name": "The Wall", + "description": "string", + "migrate_users": true, + "auth_providers": [ + "google_saml_1" + ] + } + ] + }, + "example-multitenant-modify-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "company_id": "i702619617", + "name": "The wall", + "description": "string", + "status": "blocked", + "new_status": "blocked", + "old_status": "actived", + "migrated_count": 2, + "auth_providers": [ + "google_saml_1" + ] + } + ] + }, + "example-multitenant-delete-request": { + "ops": [ + { + "type": "delete", + "obj": "company", + "obj_id": "i702619617" + } + ] + }, + "example-multitenant-delete-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company", + "obj_id": "i702619617" + } + ] + }, + "show-request-6": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company_keys" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "proc-response": { + "type": "string", + "enum": [ + "ok", + "error" + ], + "description": "The processing status of a specific operation." + }, + "show-response-7": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company_keys" + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "list": { + "type": "array", + "description": "list of corezoid-objects", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "default": "user", + "description": "Object. In this case, user is a user-component and not a user-human." + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "title": { + "type": "string", + "description": "API key name" + }, + "api_login": { + "type": "integer" + }, + "api_key": { + "type": "string" + } + } + } + } + } + }, + "example-show-request-6": { + "ops": [ + { + "type": "show", + "obj": "company_keys", + "company_id": "i659829000" + } + ] + }, + "example-show-response-6": { + "request_proc": "ok", + "ops": { + "id": "", + "proc": "ok", + "obj": "company_keys", + "type": "show", + "list": [ + { + "obj": "user", + "obj_id": 82253, + "title": "My first API key for simple process", + "api_login": 120180, + "api_key": "JOg9D6Dru1V02jG1eDWbgfmNPpgGPCNCS0Dgoks2x5a57Ytga" + } + ] + } + }, + "list-request-11": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "company_users" + }, + "sort": { + "type": "string", + "enum": [ + "title" + ], + "description": "Sorting parameter" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc", + "description": "this parameter is used for sorting result data:
`asc` — In ascending order
`desc` — In descending order" + }, + "filter": { + "type": "string", + "enum": [ + "user", + "api_key", + "group", + "shared" + ], + "example": "group", + "description": "Sort list by parameter:
`user` - List of users added to the company with their logins and groups they belong to.
`api_key` - List of api_keys available to user.
`group` - List of groups that include the user.
`shared` - List of groups that the user was granted access to.
" + }, + "name": { + "type": "string", + "minLength": 3, + "maxLength": 100, + "description": "Filter - search for users" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "list-response-11": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "company_users" + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "list": { + "type": "array", + "description": "list of corezoid-objects", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Object ID
(object is one of the following: User, API key, Group, shared)" + }, + "size": { + "type": "integer", + "description": "Number of users in the group
this response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\"" + }, + "title": { + "type": "string", + "description": "Group / User / API key title" + }, + "type": { + "type": "string", + "enum": [ + "all", + "supers", + "admins", + "company", + "company_supers" + ], + "description": "Group type
This response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\"." + }, + "create_time": { + "type": "integer", + "description": "Group creation time in the Unixtime format
This response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\"." + }, + "owner_id": { + "type": "integer", + "description": "Company owner ID
This response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\" | \"api_key\"." + }, + "owner_name": { + "type": "string", + "description": "A name of company owner
This response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\"." + }, + "is_owner": { + "type": "bool", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends the request is the same as the group owner ID.
This response parameter is present only if the request parameter 'filter' = \"group\" | \"shared\"." + }, + "status": { + "type": "string", + "enum": [ + "actived", + "blocked" + ], + "description": "User or API key state
This response parameter is present only if the request parameter 'filter' = \"user\" | \"api_key\"." + }, + "is_login_locked": { + "type": "bool", + "enum": [ + true, + false + ], + "description": "An indication that the login of user was locked.
This response parameter is present only if the request parameter 'filter' = \"user\"." + }, + "is_superadmin": { + "type": "bool", + "enum": [ + true, + false + ], + "description": "An indication that the user is superadmin.
This response parameter is present only if the request parameter 'filter' = \"user\"." + }, + "logins": { + "type": "array", + "description": "List of logins
This response parameter is present only if the request parameter 'filter' = \"user\" | \"api_key\".", + "items": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "API key
This response parameter is present only if the request parameter 'filter' = \"api_key\"." + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "type": { + "type": "string", + "enum": [ + "ldap", + "google", + "facebook", + "api", + "phone", + "corezoid", + "github" + ], + "description": "Type of login" + }, + "login": { + "type": "string", + "description": "Login value" + } + } + } + }, + "groups": { + "type": "array", + "description": "A list of groups that include the user.
This response parameter is present only if the request parameter 'filter' = \"user\".", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Group ID" + }, + "name": { + "type": "string", + "description": "Group title" + } + } + } + }, + "obj": { + "type": "string", + "description": "Type of object
This response parameter is present only in multitenant architecture for superadmins. This applies to unaccepted invitations.", + "default": "user" + }, + "privs": { + "type": "array", + "description": "An array of user rights settings over linked object
This response parameter is present only in multitenant architecture for superadmins. This applies to unaccepted invitations.", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "is_invite": { + "type": "boolean", + "description": "Indicator of invating user
This response parameter is present only in multitenant architecture for superadmins. This applies to unaccepted invitations.", + "default": true + }, + "invite_hash": { + "type": "string", + "description": "Hash for url that user should use to confirm invitation
This response parameter is present only in multitenant architecture for superadmins. This applies to unaccepted invitations." + } + } + } + } + } + }, + "example-list-request-11": { + "ops": [ + { + "type": "list", + "obj": "company_users", + "sort": "title", + "order": "asc", + "filter": "group", + "name": "string", + "company_id": "i659829000" + } + ] + }, + "example-list-response-user": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 45377, + "title": "John Doe", + "logins": [ + { + "key": "", + "obj_id": 76230, + "type": "google", + "login": "example@gmail.com" + } + ], + "status": "blocked", + "is_login_locked": false, + "is_superadmin": false, + "groups": [ + { + "id": 136830, + "name": "Group one" + } + ] + } + ] + } + ] + }, + "example-list-response-user-superadmin": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 45377, + "title": "John Doe", + "logins": [ + { + "key": "47058ccf7bd36228a1b701cfca33cc8c765d3b347f232d6a6f378z6bec834295", + "obj_id": 76230, + "type": "google", + "login": "example@gmail.com" + } + ], + "status": "blocked", + "is_login_locked": false, + "is_superadmin": false, + "groups": [ + { + "id": 136830, + "name": "Group one" + } + ] + }, + { + "obj": "user", + "title": "aria.stark@corezoid.com", + "privs": [], + "is_invite": true, + "invite_hash": "5538044124054c5cc012ae720b1416621675d496" + } + ] + } + ] + }, + "example-list-response-group": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 59757, + "size": 0, + "title": "garlic", + "type": "admins", + "create_time": 1649950814, + "owner_id": 25130, + "owner_name": "Daria Grek", + "is_owner": true + } + ] + } + ] + }, + "example-list-response-shared": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 13, + "size": 53, + "title": "SuperAdmins", + "type": "supers", + "create_time": 1470756420, + "owner_id": 6, + "owner_name": "Лаверов Денис", + "is_owner": false + } + ] + } + ] + }, + "example-list-response-api_key": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "company_users", + "list": [ + { + "obj_id": 25630, + "title": "first", + "owner_id": 25130, + "status": "actived", + "logins": [ + { + "key": "KwiSaA9aJNVw87KTc9F4g1PpEYicCPDcqh5anbkIcdBm1Ubzy2", + "obj_id": 26325, + "type": "api", + "login": "61e7c256094bab148b0011df" + } + ] + } + ] + } + ] + }, + "create-request-9": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "title", + "logins" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "title": { + "type": "string", + "description": "Api key title", + "maxLength": 255 + }, + "logins": { + "type": "array", + "description": "logins array", + "items": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "type": "string", + "description": "Login type", + "enum": [ + "api" + ] + } + } + } + }, + "group_id": { + "type": "integer", + "description": "For linking user to group" + }, + "role": { + "type": "string", + "deprecated": true, + "enum": [ + "user", + "owner" + ], + "description": "User role" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "send_invite_if_user_not_exists": { + "type": "boolean", + "description": "If this parameter is true and saml auth is disable - system will send invite. If the user already exists, no invitation is sent. The parameter only applies to the creation of a user." + } + } + }, + "create-response-9": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "users": { + "type": "array", + "description": null, + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "created": { + "type": "boolean", + "description": "Flag indicating whether the user has been created or already exists" + }, + "nick": { + "type": "string", + "description": "Pre-saved user name
This response parameter is present when the request parameter 'send_invite_if_user_not_exists' = \"true\"" + }, + "url": { + "type": "string", + "description": "An invitation URL that a user needs to use to accept the invitation
This response parameter is present when the request parameter 'send_invite_if_user_not_exists' = \"true\"" + }, + "title": { + "type": "string", + "description": "User name" + }, + "logins": { + "type": "array", + "description": "User's logins", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Login type", + "enum": [ + "api" + ] + }, + "key": { + "type": "string", + "description": "API Key" + }, + "obj_id": { + "type": "integer", + "description": "API Key identifier" + } + } + } + } + } + } + } + } + }, + "create-request-private": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "title", + "logins" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "title": { + "type": "string", + "description": "User title (name)" + }, + "logins": { + "type": "array", + "description": "User's logins", + "items": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "login": { + "type": "string", + "description": "User login" + }, + "type": { + "type": "string", + "description": "Login type. For conditions below available only \"api\" option:
multitenant architecture and SAML auth disabled or
SAML auth enabled, but user is not a superadminisrator or adminisrator
", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "phone", + "corezoid", + "github" + ] + } + } + } + }, + "group_id": { + "type": "integer", + "description": "For linking user to group" + }, + "role": { + "type": "string", + "deprecated": true, + "enum": [ + "user", + "owner" + ], + "description": "User role" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "send_invite_if_user_not_exists": { + "type": "boolean", + "description": "If this parameter is true and saml auth is disable - system will send invite. If the user already exists, no invitation is sent." + } + } + }, + "create-response-private": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "users": { + "type": "array", + "description": null, + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "title": { + "type": "string", + "description": "User name" + }, + "created": { + "type": "boolean" + }, + "nick": { + "type": "string", + "description": "Pre-saved user name
This response parameter is present when the request parameter 'send_invite_if_user_not_exists' = \"true\"" + }, + "url": { + "type": "string", + "description": "An invitation URL that a user needs to use to accept the invitation
This response parameter is present when the request parameter 'send_invite_if_user_not_exists' = \"true\" description: Flag indicating whether the user has been created or already exists" + }, + "logins": { + "type": "array", + "description": "User's logins", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Login type" + }, + "key": { + "type": "string", + "description": "API Key
this response parameter is present only if the request parameter 'type' = \"api\"" + }, + "obj_id": { + "type": "integer", + "description": "Login ID
this response parameter is present only if the request parameter 'type' != \"api\"" + }, + "login": { + "type": "string", + "description": "User login" + } + } + } + } + } + } + } + } + }, + "modify-request-8": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "title", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "maxLength": 10, + "description": "API Key ID" + }, + "title": { + "type": "string", + "maxLength": 255, + "description": "API Key name" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "modify-response-8": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "API Key ID" + }, + "title": { + "type": "string", + "description": "API Key name" + } + } + }, + "link-request-4": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "group_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "group_id": { + "type": "integer", + "description": "Group ID (into that you want to put the API Key)" + }, + "obj_id": { + "type": "integer", + "description": "API Key ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "level": { + "type": "integer", + "enum": [ + 1, + null + ], + "nullable": true, + "description": "Send `1` for linking API Key with group
Do not send this parameter or send `null` or any other number to unlink the API key from the group" + } + } + }, + "link-response-4": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "logins": { + "type": "array", + "description": "list of linking/unlinking user's logins", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "ldap", + "google", + "facebook", + "api", + "phone", + "corezoid", + "github" + ], + "description": "Type of login" + }, + "login": { + "type": "string", + "description": "Login value" + }, + "key": { + "type": "string", + "description": "API Key
this response parameter is present only if user is API Key" + }, + "obj_id": { + "type": "integer", + "description": "API Key ID
this response parameter is present only if user is API Key" + } + } + } + } + } + }, + "show-request-7": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "company" + ], + "description": "if declare this parameter you can get all the groups that include the user (available only for the role of super-administrator or service desk)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "show-response-8": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "title": { + "type": "string", + "description": "User name" + }, + "owner_id": { + "type": "integer", + "description": "Owner id" + }, + "owner_name": { + "type": "string", + "description": "Owner name" + }, + "groups": { + "type": "array", + "description": "A list of groups that include the user", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Group ID" + }, + "name": { + "type": "string", + "description": "Group title" + }, + "owner_id": { + "type": "integer", + "description": "Group owner's ID" + }, + "owner_name": { + "type": "string", + "description": "Group owner's name" + }, + "is_owner": { + "type": "bool", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as Group owner ID" + } + } + } + }, + "logins": { + "type": "array", + "description": "list of user's logins", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "ldap", + "google", + "facebook", + "api", + "phone", + "corezoid", + "github" + ], + "description": "Type of login" + }, + "login": { + "type": "string", + "description": "Login value" + }, + "key": { + "type": "string", + "description": "API Key
this response parameter is present only if user is API Key" + }, + "obj_id": { + "type": "integer", + "description": "API Key ID
this response parameter is present only if user is API Key" + } + } + } + } + } + }, + "delete-request-8": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user" + }, + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-8": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "deleted User ID" + }, + "company_id": { + "type": "string", + "description": "Company ID" + } + } + }, + "example-create-request-8": { + "ops": [ + { + "type": "create", + "obj": "user", + "title": "first api key", + "company_id": "i702619617", + "logins": [ + { + "type": "api" + } + ] + } + ] + }, + "example-create-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "user", + "proc": "ok", + "users": [ + { + "obj_id": 29299, + "created": true, + "title": "fifth", + "logins": [ + { + "type": "api", + "key": "A5C2iRaxL3kjouu8KhqaPx7asZLjS4W8JaUC3yqDtpIdHN75c", + "obj_id": 30008 + } + ] + } + ] + } + ] + }, + "example-modify-request-8": { + "ops": [ + { + "type": "modify", + "obj": "user", + "obj_id": 29299, + "title": "five" + } + ] + }, + "example-modify-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "obj_id": 29299, + "title": "five" + } + ] + }, + "example-link-request-4": { + "ops": [ + { + "group_id": 136830, + "obj_id": 82363, + "obj": "user", + "type": "link", + "company_id": "i790533068", + "level": 1 + } + ] + }, + "example-link-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "logins": [ + { + "type": "api", + "login": "61e566e382ba963bcb25be3", + "key": "XEeapf5pPjzD6kRIWiLA0NscYDGOMwWAreTr1PAKrCKPUVRG", + "obj_id": 120180 + } + ], + "obj_id": 82363 + } + ] + }, + "example-link-response-not_api": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "logins": [ + { + "type": "corezoid", + "login": "test00160@gmail.com" + } + ], + "obj_id": 82363 + } + ] + }, + "example-show-request-7": { + "ops": [ + { + "type": "show", + "obj_id": 27608, + "obj": "user", + "obj_type": "company", + "company_id": "i702619617" + } + ] + }, + "example-show-response-api": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user", + "obj_id": 28888, + "title": "first", + "owner_id": 60184, + "owner_name": "forApiTest", + "logins": [ + { + "key": "wB12nFmNBI0oSgOSMU3HklYOZw9mYigezFfDnz1xCDfKwqwFN", + "obj_id": 29595, + "type": "api", + "login": "625096ae6167c134a0000e5" + } + ] + } + ] + }, + "example-show-response-not_api": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "groups": [ + { + "id": 57107, + "name": "Admins", + "owner_id": 25130, + "owner_name": "John Snow", + "is_owner": false + } + ], + "proc": "ok", + "obj": "user", + "obj_id": 27608, + "title": "John Snow", + "logins": [ + { + "type": "google", + "login": "john.snow@thewall.com" + } + ] + } + ] + }, + "example-delete-request-8": { + "ops": [ + { + "type": "delete", + "obj_id": 29516, + "company_id": "i702619617", + "obj": "user" + } + ] + }, + "example-delete-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 29516, + "company_id": "i702619617" + } + ] + }, + "create-request-10": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "title", + "short_name", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": " New alias name (that will be created)" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "New alias description" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Alias short name
This value must be unique for a stage (when an alias is created in a stage) or for a company (when an alias is created in a company and not in a stage)" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 36, + "nullable": true, + "description": "ID of an existing Company" + }, + "stage_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
If the object is in a stage, then to perform an operation on the object, you must additionally send either 'stage_id' or 'stage_short_name', otherwise you must send the 'folder_id'." + }, + "stage_id": { + "type": "integer", + "default": 0, + "description": "Stage ID
If an abject is in a stage, then to perform an operation on the object, you must additionally send either 'stage_id' or 'stage_short_name', otherwise you must send 'folder_id'." + }, + "obj_to_id": { + "type": "integer", + "description": "An object (Process / State Diagram) ID, for that we are creating an alias." + }, + "obj_to_type": { + "type": "string", + "enum": [ + "conv" + ], + "description": "Type of object for that we are creating (and linking) an alias:
`conv` — Process / State Diagram
" + } + } + }, + "create-response-10": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that was created." + } + } + }, + "modify-request-9": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id", + "short_name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that will be modified." + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Alias name" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Alias short name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Alias description" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "modify-response-9": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that was modified." + } + } + }, + "show-request-8": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias which details will be shown." + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 36, + "nullable": true, + "description": "ID of an existing Company" + } + } + }, + "show-response-9": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "is_favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "obj_to_title": { + "type": "string", + "description": "A name of linked object
This response parameter is present only if an alias is linked to an object and a user that makes the request has access to the object with the View permission." + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of a user that sends the request is the same as the alias owner ID." + }, + "owner_id": { + "type": "integer", + "description": "Alias owner ID" + }, + "owner_name": { + "type": "string", + "description": "Alias owner name" + }, + "owner_login": { + "type": "string", + "description": "Alias owner login" + }, + "obj_id": { + "type": "integer", + "description": "Alias ID" + }, + "obj_type": { + "type": "string", + "default": "alias", + "description": "Object type" + }, + "title": { + "type": "string", + "description": "Alias name" + }, + "description": { + "type": "string", + "description": "Alias description" + }, + "short_name": { + "type": "string", + "description": "Alias short name" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "description": "Project ID;
`0` for an alias created in Folders (not in a Project)" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_title": { + "type": "string", + "description": "Project name" + }, + "stage_id": { + "type": "integer", + "description": "Stage ID;
`0` for an Alias created in Folders (neither in a Stage, nor in a Project)" + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_title": { + "type": "string", + "description": "Stage name;
This response parameter is present only if the response parameter 'stage_id' != 0" + }, + "obj_to_id": { + "type": "integer", + "nullable": true, + "description": "ID of a Process / State Diagram linked to an alias
`null` if the alias is not linked." + }, + "obj_to_type": { + "type": "string", + "nullable": true, + "enum": [ + "conv" + ], + "description": "Type of linked to an alias object:
`conv` — Process / State Diagram
`null` — Alias is not linked" + }, + "create_time": { + "type": "integer", + "description": "Alias creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Alias change time in the Unixtime format" + }, + "uuid": { + "type": "string", + "example": "964c3ed9-83b2-45f5-afc8-3c19e5bcaed1", + "description": "Universally Unique Identifier of an object" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + }, + "delete-request-9": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Alias that will be deleted" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-9": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that was deleted." + } + } + }, + "favorite-request-4": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that will be add to/deleted from the Favorites list." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "favorite-response-4": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that was add to/deleted from the Favorites list." + } + } + }, + "link-request-5": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "obj_to_id", + "obj_to_type", + "link", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Alias that will be linked to an object." + }, + "obj_to_id": { + "type": "integer", + "description": "ID of a Process / State Diagram that will be linked to/unlinked from the alias." + }, + "obj_to_type": { + "type": "string", + "enum": [ + "conv" + ], + "description": "Type of linked to Alias object:
`conv` — Process or State Diagram;
" + }, + "link": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag of operation type:
`true` — link
`false` — unlink" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "link-response-5": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that will be linked to an object." + } + } + }, + "upsert-request": { + "type": "object", + "title": "upsert", + "required": [ + "type", + "obj", + "short_name", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "upsert" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that will be created/updated." + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Name of the alias that will be created/updated." + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Description of the alias that will be created/updated." + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Alias short name" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_to_id": { + "type": "integer", + "description": "ID of an object (Process / State Diagram / Dashboard) that will be linked to/unlinked from an alias." + }, + "obj_to_type": { + "type": "string", + "enum": [ + "conv", + "dashboard" + ], + "description": "Type of an object linked to Alias:
`conv` — Process / State Diagram
`dashboard` — Dashboard" + } + } + }, + "upsert-response": { + "type": "object", + "title": "upsert", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "Alias ID" + } + } + }, + "destroy-request-5": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that will be destroyed." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "destroy-response-5": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "alias" + }, + "obj_id": { + "type": "integer", + "description": "ID of the alias that was destroyed." + } + } + }, + "example-create-request-9": { + "ops": [ + { + "obj": "alias", + "title": "test1", + "short_name": "test1", + "description": "test alias", + "company_id": "i848211059", + "stage_id": 371951, + "project_id": 371949, + "type": "create" + } + ] + }, + "example-create-response-9": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj_id": 52678, + "proc": "ok", + "obj": "alias" + } + ] + }, + "example-modify-request-9": { + "ops": [ + { + "obj": "alias", + "title": "test1", + "short_name": "test1", + "description": "test alias.", + "company_id": "i848211059", + "type": "modify", + "obj_id": 52678 + } + ] + }, + "example-modify-response-9": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 52678 + } + ] + }, + "example-show-request-8": { + "ops": [ + { + "type": "show", + "obj": "alias", + "obj_id": 52678, + "company_id": "i848211059" + } + ] + }, + "example-show-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "is_favorite": false, + "obj_to_title": "test01", + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner_email@corezoid.com", + "obj_id": 52678, + "obj_type": "alias", + "title": "test1", + "description": "test alias.", + "short_name": "test1", + "company_id": "i848211059", + "project_id": 371949, + "stage_id": 371951, + "project_title": "test", + "project_short_name": "test", + "stage_title": "develop", + "stage_short_name": "tedevelopst", + "obj_to_id": 1000853, + "obj_to_type": "conv", + "create_time": 1666598950, + "change_time": 1667262485, + "uuid": "d6cb5bfb-d97b-4d34-940a-13adfa02069a", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-delete-request-9": { + "ops": [ + { + "type": "delete", + "obj": "alias", + "obj_id": 53403, + "company_id": "i848211059" + } + ] + }, + "example-delete-response-9": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 53403 + } + ] + }, + "example-favorite-request-4": { + "ops": [ + { + "type": "favorite", + "obj": "alias", + "company_id": "i848211059", + "obj_id": 52703, + "favorite": true + } + ] + }, + "example-favorite-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 52703, + "obj": "alias" + } + ] + }, + "example-link-request-5": { + "ops": [ + { + "link": true, + "obj_id": 52678, + "obj_to_id": 1000853, + "obj_to_type": "conv", + "type": "link", + "obj": "alias", + "company_id": "i848211059" + } + ] + }, + "example-link-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 52678 + } + ] + }, + "example-upsert-request": { + "ops": [ + { + "type": "upsert", + "obj": "alias", + "obj_id": 29517, + "title": "First Alias", + "description": "First Alias", + "short_name": "alias-1", + "company_id": "i493107423" + } + ] + }, + "example-upsert-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 29517 + } + ] + }, + "example-destroy-request-5": { + "ops": [ + { + "type": "destroy", + "obj": "alias", + "obj_id": 53547, + "company_id": "i848211059" + } + ] + }, + "example-destroy-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "alias", + "obj_id": 53547 + } + ] + }, + "list-request-12": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "aliases" + }, + "company_id": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "ID of an existing Company
" + }, + "project_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "deprecated": true, + "description": "Project short name
'project_id' or 'project_short_name' must be sent in the request." + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "deprecated": true, + "description": "Stage short name
'stage_id' or 'stage_short_name' must be sent in the request." + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "conv_id": { + "type": "integer", + "description": "Process / State Diagram ID, this request parameter is used for get aliases linked with it." + }, + "sort": { + "type": "string", + "enum": [ + "title", + "name", + "short_name", + "owner", + "date", + "obj_to_id" + ], + "default": "date", + "description": "sort response list by parameter:
`title` — Alias title
`name` — Alias title
`short_name` — Alias short name
`owner` — Alias owner
`date` — Alias last change datetime
`obj_to_id` — By Process / State Diagram ID, with that alias linked
" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc", + "description": "This parameter is used for sorting result data:
`asc` — In ascending order
`desc` — In descending order" + }, + "filter": { + "type": "string", + "enum": [ + "favorites", + "deleted" + ], + "description": "This parameter is used for filtering result data:
`favorites` — Aliases that were add to the Favorites list (Starred).
`deleted` — Aliases that were deleted." + }, + "pattern": { + "type": "string", + "minLength": 3, + "maxLength": 150, + "pattern": "^[a-z0-9-]*$", + "description": "This parameter is used for filtering result data by alias short name pattern (prefix)." + }, + "owner_id": { + "type": "integer", + "description": "Alias owner ID" + }, + "location": { + "type": "string", + "enum": [ + "folder", + "stage", + "project" + ], + "description": "This parameter is used for filtering result data:
`folder` — The search will be performed in the company's root folder.
`stage` — The search will be performed in all of the company's projects.
`project` — The search will be performed within the chosen project." + } + } + }, + "list-response-12": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "is_favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends the request is the same as the alias owner ID." + }, + "owner_id": { + "type": "integer", + "description": "Alias owner ID" + }, + "owner_name": { + "type": "string", + "description": "Alias owner name" + }, + "owner_login": { + "type": "string", + "description": "Alias owner login" + }, + "obj_id": { + "type": "integer", + "description": "Alias ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "alias" + ], + "description": "An object type" + }, + "title": { + "type": "string", + "description": "Alias name" + }, + "description": { + "type": "string", + "nullable": true, + "description": "Alias description" + }, + "short_name": { + "type": "string", + "description": "Alias short name" + }, + "company_id": { + "type": "string", + "example": "i232593215", + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "example": 0, + "description": "Not used for company aliases" + }, + "project_short_name": { + "type": "string", + "nullable": true, + "description": "Project short name" + }, + "project_title": { + "type": "string", + "nullable": true, + "description": "Project name" + }, + "stage_id": { + "type": "integer", + "example": 0, + "description": "Not used for company aliases" + }, + "stage_title": { + "type": "string", + "nullable": true, + "description": "Name of a stage where the object that linked to an alias is stored." + }, + "stage_short_name": { + "type": "string", + "nullable": true, + "description": "Stage short name" + }, + "obj_to_id": { + "type": "integer", + "nullable": true, + "description": "ID of the object (Process / State Diagram) that linked to an alias.
`null` if the alias is not linked, otherwise ID of the Process / State Diagram." + }, + "obj_to_type": { + "type": "string", + "nullable": true, + "description": "Type of linked to the Alias object.
`null` if the alias is not linked, otherwise `conv`." + }, + "create_time": { + "type": "integer", + "example": 1632237194, + "description": "Alias creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "example": 1632237194, + "description": "Alias change time in the Unixtime format" + }, + "obj_to_title": { + "type": "string", + "description": "A name of linked object
This response parameter is present only if the alias is linked to the object and user that makes request has access to object with the View permission." + }, + "uuid": { + "type": "string", + "example": "964c3ed9-83b2-45f5-afc8-3c19e5bcaed1", + "description": "Universally Unique Identifier of the object" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + } + } + } + }, + "example-list-request-12": { + "ops": [ + { + "sort": "date", + "order": "asc", + "company_id": "i848211059", + "project_id": 371949, + "stage_id": 371951, + "obj": "aliases", + "type": "list", + "location": "stage", + "id": "i848211059" + } + ] + }, + "example-list-response-10": { + "request_proc": "ok", + "ops": [ + { + "id": "i848211059", + "proc": "ok", + "list": [ + { + "is_favorite": false, + "obj_to_title": "test1", + "is_owner": true, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner_email@corezoid.com", + "obj_id": 52678, + "obj_type": "alias", + "title": "test1", + "description": "test alias", + "short_name": "test1", + "company_id": "i848211059", + "project_id": 371949, + "project_short_name": "Proj_1", + "project_title": "Project_1", + "stage_id": 371951, + "stage_short_name": "develop", + "stage_title": "develop", + "obj_to_id": 1000853, + "obj_to_type": "conv", + "create_time": 1666598950, + "change_time": 1666598950, + "uuid": "d6cb5bfb-d97b-4d34-940a-13adfa02069a", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + }, + "create-request-11": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "description": { + "type": "string", + "nullable": true, + "minLength": 0, + "maxLength": 2000, + "description": "New Process / State Diagram description" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "New Process / State Diagram name" + }, + "folder_id": { + "type": "integer", + "description": "Parent Folder ID (Folder where the new Process / State Diagram will be stored)" + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "debug", + "blocked" + ], + "description": "The new Process / State Diagram will be created with this status." + }, + "create_mode": { + "type": "string", + "enum": [ + "without_nodes" + ] + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state", + "escalation" + ], + "description": "Type of an object to be created:
`process` — Process
`state` — State Diagram
`escalation` — Deprecated option (special system process designed to handle Process / State Diagram errors)" + }, + "escalation_conv": { + "type": "integer", + "deprecated": true + } + } + }, + "create-response-11": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Process / State Diagram that was created" + }, + "folder_id": { + "type": "integer", + "description": "Parent Folder ID (Folder where the Process / State Diagram is stored)" + }, + "hash": { + "type": "string", + "description": "callback hash" + } + } + }, + "modify-request-10": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of a Process / State Diagram that will be modified.", + "minimum": 0 + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Description of a Process / State Diagram that will be modified." + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Name of a Process / State Diagram that will be modified." + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "debug", + "blocked" + ], + "description": "Parameter for applying 'change' to a Process / State Diagram operation status" + }, + "blocked_reason": { + "type": "string", + "minLength": 3, + "maxLength": 2000, + "description": "Blocked reason description
This request parameter is allowed when the request parameter 'status' = \"blocked\"." + } + } + }, + "modify-response-10": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "Process / State Diagram ID" + }, + "new_status": { + "type": "integer", + "enum": [ + 1, + 2, + 4, + 5, + 6 + ], + "description": "New status of a Process / State Diagram:
`1` — active
`2` — paused
`4` — blocked
`5` — debug
`6` — active_debug" + }, + "old_status": { + "type": "integer", + "enum": [ + 1, + 2, + 4, + 5, + 6 + ], + "description": "Old status of a Process / State Diagram:
`1` — active
`2` — paused
`4` — blocked
`5` — debug
`6` — active_debug" + }, + "is_changed": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when the status was changed." + } + } + }, + "list-request-13": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Process / State Diagram ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group", + "all" + ], + "description": "Object filter
`group` — Get a list of users and groups that have access to a process. Object filter
`all` — Get a list of nodes. `all` by default, if nothing is specified." + }, + "group_id": { + "type": "integer", + "deprecated": true + } + } + }, + "list-response-13": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "Process / State Diagram ID" + }, + "project_id": { + "type": "integer", + "default": 0, + "description": "Project ID
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "stage_id": { + "type": "integer", + "default": 0, + "description": "Stage ID
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is Process / State Diagram editable - Identifies whether the stage is immutable.
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "privs": { + "type": "array", + "description": "An array of user rights settings for a shared object - Process / State Diagram
This response parameter is present only if the request parameter 'list_obj' != \"group\".", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug" + ], + "description": "Current state of an object — Process / State Diagram
`transient` — system status for merge
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "title": { + "type": "string", + "description": "Process / State Diagram name
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "description": { + "type": "string", + "description": "Process / State Diagram description
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state", + "escalation" + ], + "description": "Type of object:
`process` — Process
`state` — State Diagram
`escalation` — Deprecated option (special system process designed to handle Process / State Diagram errors)
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is true when ID of a user that sends a request is the same as an object (Process / State Diagram) owner ID.
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "owner_name": { + "type": "string", + "example": "First_Name Last_Name", + "description": "Process / State Diagram owner name —
Process's / State Diagram's parent folder's owner name
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "owner_id": { + "type": "integer", + "example": 27074, + "description": "Process / State Diagram owner ID —
Process's / State Diagram's parent folder's owner ID
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "owner_login": { + "type": "string", + "example": "owner.email@corezoid.com", + "description": "Process / State Diagram owner's login —
Process's / State Diagram's parent folder's owner's login (email or phone number)
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "list": { + "type": "array", + "description": "The list of object - Process / State Diagram - components (nodes).", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "enum": [ + "node", + "user", + "group" + ], + "description": "`node` — When the request parameter 'list_obj' != \"group\".
`user` — When the request parameter 'list_obj' = \"group\".
`group` — When the request parameter 'list_obj' = \"group\"." + }, + "obj_id": { + "oneOf": [ + { + "type": "string", + "description": "Node ID
This response parameter has the string type when the request parameter 'list_obj' != \"group\".
example = \"62b599ba094bab2fe4000308\"" + }, + { + "type": "integer", + "description": "API key ID;
This response parameter has the integer type when the request parameter 'list_obj' = \"group\"
example = 27201" + } + ] + }, + "login_id": { + "type": "integer", + "example": 27201, + "description": "Login ID
This response parameter is present only if the request parameter 'list_obj' = \"group\"." + }, + "title": { + "type": "string", + "description": "Node name when the request parameter 'list_obj' != \"group\".
API key/User/Group name when the request parameter 'list_obj' = \"group\"." + }, + "description": { + "type": "string", + "description": "Node description
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + }, + "count": { + "type": "integer", + "description": "Number of tasks in the node
This response parameter is present only if the request parameters 'list_obj' != \"group\"." + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — Normal - logic node
`1` — Start node
`2` — Final node
`3` — Escalation - special system node
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "position": { + "type": "array", + "description": "[ position_X, position_Y ] — Coordinates of the node upper-left corner along the X / Y axis with respect to the 0:0 reference point in the process field coordinates.
position_X, position_Y — Integer values.
example: [ 560, 100 ]
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "extra": { + "type": "string with JSON", + "description": "A stringify object of additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view)
icon — Icon of the final success (green) / error (red) node
For all the other nodes the \"icon\":\"\" is used.
example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "options": { + "type": "string with JSON", + "nullable": true, + "description": "A stringify object of the save_task additional node setting
example: \"{\\\\\"save_task\\\\\":true}\"
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "privs": { + "type": "array", + "description": "An array of user rights settings for a shared object - Process / State Diagram
This response parameter is present only if the request parameter 'list_obj' = \"group\".", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "stub": { + "type": "object", + "description": "Optional mock behavior for the node. Each branch in `stub.logics` defines which reply the node should return during stubbed execution.", + "properties": { + "logics": { + "type": "array", + "description": "Array of alternative branches. Each branch is an array with one or two logic objects: either only `api_rpc_reply`, or `go_if_const` followed by `api_rpc_reply`.", + "items": { + "type": "array", + "minItems": 1, + "items": { + "oneOf": [ + { + "type": "object", + "additionalProperties": false, + "properties": { + "type": { + "type": "string", + "enum": [ + "go_if_const" + ] + }, + "conditions": { + "type": "array", + "description": "Conditions for this branch.", + "items": { + "type": "object", + "additionalProperties": false, + "properties": { + "param": { + "type": "string", + "description": "Variable name" + }, + "const": { + "type": "string", + "description": "Constant to compare with / for regexp" + }, + "fun": { + "type": "string", + "enum": [ + "more", + "less", + "eq", + "not_eq", + "regexp" + ], + "description": "Comparison function" + }, + "cast": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "description": "Cast type for variable" + } + }, + "required": [ + "param", + "const", + "fun" + ] + } + } + }, + "required": [ + "type", + "conditions" + ] + }, + { + "type": "object", + "additionalProperties": false, + "properties": { + "type": { + "type": "string", + "enum": [ + "api_rpc_reply" + ] + }, + "mode": { + "type": "string", + "enum": [ + "key_value", + "keys" + ], + "description": "`key_value` — return key-value object; `keys` — return array of keys." + }, + "res_data": { + "oneOf": [ + { + "type": "object", + "description": "Object of key-value pairs when `mode=key_value`." + }, + { + "type": "array", + "items": { + "type": "string" + }, + "description": "Array of keys when `mode=keys`." + } + ] + }, + "res_data_type": { + "type": "object", + "description": "Value types for each key in `res_data`: string | number | boolean | array | object." + }, + "throw_exception": { + "type": "boolean", + "default": false + }, + "exception_reason": { + "type": "string", + "description": "Reason when `throw_exception=true`." + } + }, + "required": [ + "type", + "mode", + "res_data" + ] + } + ] + } + } + } + }, + "required": [ + "logics" + ] + } + } + } + }, + "escalation_conv": { + "type": "string", + "example": "undefined", + "deprecated": true + }, + "shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Process / State Diagram access was shared
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "folder_id": { + "type": "integer", + "description": "Parent Folder ID (Folder where a Process / State Diagram is stored)
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "folder_name": { + "type": "string", + "description": "Parent Folder Name (Folder where a Process / State Diagram is stored)
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "change_time": { + "type": "integer", + "example": 1656068537, + "description": "Process / State Diagram change time in the Unixtime format
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "create_time": { + "type": "integer", + "example": 1656068537, + "description": "Process / State Diagram creation time in the Unixtime format
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "tacts": { + "type": "integer", + "description": "A number of state changes used by Process / State Diagram over all time
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "favorite": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag showing whether a Process / State Diagram was added to the Favorites (Starred)list.
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "company_id": { + "type": "integer", + "nullable": true, + "description": "ID of a Company where a Process / State Diagram is stored.
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "commits": { + "type": "object", + "description": "A list of saved but not deployed changes in a Process / State Diagram.
This response parameter is present only if the request parameter 'list_obj' != \"group\".", + "properties": { + "version": { + "type": "integer", + "description": "Changes version (identifier);
example: 1656068657" + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "example": "62c4090d094bab689e0022e8", + "description": "Node ID" + }, + "condition": { + "type": "string with JSON", + "description": "A stringify object with node settings" + }, + "name": { + "type": "string", + "description": "Node name" + }, + "description": { + "type": "string", + "description": "Node description" + }, + "position": { + "type": "array", + "description": "[ position_X, position_Y ] — Coordinates of the node upper-left corner along the X / Y axis with respect to the 0:0 reference point in the process field coordinates
position_X, position_Y — integer values
example: [ 436, 500 ]" + }, + "extra": { + "type": "string with JSON", + "description": "A stringify object with additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view)
icon — Icon of the final success (green) / error (red) node.
For all the other nodes - \"icon\":\"\".
example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"" + }, + "status": { + "type": "string", + "enum": [ + "actived", + "deleted" + ], + "description": "A current state of Node" + }, + "user_id": { + "type": "integer", + "example": 27074, + "description": "ID of a user that was node's last editor." + }, + "nick": { + "type": "string", + "example": "First_Name Last_Name", + "description": "Name of a user that was node's last editor." + }, + "change_time": { + "type": "integer", + "example": 1657014604, + "description": "Node change time in the Unixtime format" + }, + "type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — Normal - any logic node
`1` — Start node
`2` — Final node
`3` — Escalation - special system node" + } + } + } + } + } + }, + "size": { + "type": "integer", + "description": "Number of Nodes in Process / State Diagram
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + }, + "last_confirmed_version": { + "type": "integer", + "description": "Last changes version (ID)
example: 1656068538
This response parameter is present only if the request parameter 'list_obj' != \"group\"." + } + } + }, + "show-request-9": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of the Process / State Diagram which details will be shown." + } + } + }, + "show-response-10": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "example": 790828, + "description": "Process / State diagram ID" + }, + "title": { + "type": "string", + "example": "test22", + "description": "Process / State Diagram name" + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug" + ], + "description": "Process / State Diagram status" + }, + "size": { + "type": "integer", + "description": "Count of nodes in the Process / State Diagram" + }, + "owner_name": { + "type": "string", + "example": "First_Name Last_Name", + "description": "Process's / State Diagram's owner's name" + }, + "owner_login": { + "type": "string", + "example": "owner.email@corezoid.com", + "description": "Process's / State Diagram's owner's login" + }, + "create_time": { + "type": "integer", + "example": 1656068537, + "description": "Process / State Diagram creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "example": 1656068537, + "description": "Process / State Diagram change time in the Unixtime format" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "example": 0, + "description": "Project ID" + }, + "stage_id": { + "type": "integer", + "example": 0, + "description": "Stage ID" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "The flag of stage state - is `true` when immutable." + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "parent_obj_id": { + "type": "integer", + "description": "Parent Object ID" + }, + "parent_obj_type": { + "type": "string", + "description": "Parent Object Type" + } + } + }, + "link-request-6": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "obj_to", + "privs" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of a Process / State Diagram that will be linked (access to which will be shared)." + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + }, + "obj_to": { + "type": "string", + "enum": [ + "group", + "user", + "new_user", + "all" + ], + "description": "Sharing access type:
`user` — Sharing access with an API key / user.
`new_user` — Sharing access with a new user.
`group` — Sharing access with a group.
`all` — Deprecated sharing with all - make visible for all users.

`group`, `user` — Allowed only when the 'obj_to_id' request parameter exists.
`new_user` — Allowed only when the 'login' request parameter exists." + }, + "obj_to_id": { + "type": "integer", + "minimum": 0, + "description": "ID of an object (User / API key / group) to which access is shared. This request parameter is required when the request parameter 'obj_to' = \"group\"/\"user\"." + }, + "login": { + "type": "string", + "description": "Login of new user
This request parameter is required when the request parameter 'obj_to' = \"new_user\"." + } + } + }, + "link-response-6": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "Process / State Diagram ID" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "user", + "new_user", + "group", + "all" + ], + "description": "Access was shared with:
`group` — Group
`user` — User
`new_user` — new user
`all` — Deprecated Shared with all - made visible for all users" + }, + "obj_to_id": { + "type": "integer", + "minimum": 0, + "description": "ID of an object (API Key, user, group) access to which is shared.
This response parameter is present only if the request parameter 'obj_to' != \"all\"." + }, + "obj_to_title": { + "type": "string", + "description": "Name of the API Key (when we share access to API Key) / Group (when we share access to Group) This response parameter is present only if the request parameter 'obj_to' != \"all\"." + }, + "action_type": { + "type": "string", + "enum": [ + "link", + "unlink" + ], + "description": "Operation type:
`link` — Share access to a Process / State Diagram (when the 'privs' request parameter exists and is not an `[]` empty array)
`unlink` — Remove previously shared access to a Process / State Diagram (when the 'privs' request parameter is an `[]` empty array)" + } + } + }, + "favorite-request-5": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of the Process / State Diagram" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + } + } + }, + "favorite-response-5": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Process / State Diagram that was added to/removed from the Favorites list." + } + } + }, + "delete-request-10": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Process / State Diagram ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-10": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Process / State Diagram that was deleted." + } + } + }, + "restore-request-6": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Process / State Diagram ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "restore-response-6": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Process / State Diagram that was restored." + }, + "parent_folder_id": { + "type": "integer", + "description": "ID of the Folder in which a Process / State Diagram was restored." + } + } + }, + "destroy-request-6": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Process / State Diagram ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "destroy-response-6": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Process / State diagram that was destroyed." + } + } + }, + "example-create-request-10": { + "ops": [ + { + "title": "New object", + "description": "", + "folder_id": 303629, + "company_id": "i848211059", + "obj": "conv", + "create_mode": "without_nodes", + "conv_type": "process", + "type": "create", + "obj_type": 0, + "status": "active" + } + ] + }, + "example-create-response-10": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 899874, + "folder_id": 303629, + "hash": "dc2f75b7aeb59bce5bb3b5f9e2a43fa812902ffa" + } + ] + }, + "example-modify-request-10": { + "ops": [ + { + "title": "New object 2", + "description": "test description", + "type": "modify", + "obj": "conv", + "obj_id": 899874, + "company_id": "i848211059" + } + ] + }, + "example-modify-response-10": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 899874, + "new_status": 1, + "old_status": 1, + "is_changed": false + } + ] + }, + "example-list-request-13": { + "ops": [ + { + "obj": "conv", + "type": "list", + "obj_id": 790828 + } + ] + }, + "example-list-response-11": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 790828, + "project_id": 0, + "stage_id": 0, + "immutable": false, + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "status": "active", + "title": "22", + "description": "", + "conv_type": "process", + "is_owner": false, + "owner_name": "First_Name Last_Name", + "owner_id": 27074, + "owner_login": "owner.email@corezoid.com", + "proc": "ok", + "list": [ + { + "obj": "node", + "obj_id": "62b599ba094bab2fe4000308", + "title": "Final", + "description": "", + "logics": [], + "semaphors": [], + "count": 0, + "obj_type": 2, + "position": [ + 560, + 400 + ], + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"success\"}", + "options": "{\"save_task\":true}" + } + ], + "escalation_conv": "undefined", + "shared": true, + "folder_id": 210032, + "folder_name": "test", + "change_time": 1656068537, + "create_time": 1656068537, + "tacts": 0, + "favorite": false, + "company_id": null, + "commits": { + "version": 1656068657, + "list": [ + { + "obj_id": "62c4090d094bab689e0022e8", + "condition": "{\"logics\":[{\"type\":\"api_code\",\"err_node_id\":\"62c4090d094bab689e0022eb\",\"code_error\":true},{\"type\":\"go\",\"to_node_id\":\"62c4094c094bab689e0022ec\"}],\"semaphors\":[]}", + "name": "", + "description": "", + "position": [ + 436, + 500 + ], + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "status": "actived", + "user_id": 27074, + "nick": "First_Name Last_Name", + "change_time": 1657014604, + "type": 0 + } + ], + "size": 2, + "last_confirmed_version": 1656068538 + } + } + ] + }, + "example-list-request-group": { + "ops": [ + { + "obj": "conv", + "type": "list", + "obj_id": 790828, + "list_obj": "group" + } + ] + }, + "example-list-response-group-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 790828, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 27201, + "login_id": 27201, + "title": "test key", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "" + } + ] + } + ] + }, + "example-show-request-9": { + "ops": [ + { + "obj": "conv", + "type": "show", + "obj_id": 790828 + } + ] + }, + "example-show-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv", + "obj_id": 790828, + "title": "test22", + "status": "active", + "size": 2, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "create_time": 1656068537, + "change_time": 1656068537, + "company_id": "i738314881", + "project_id": 0, + "stage_id": 0, + "immutable": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "parent_obj_id": 509924, + "parent_obj_type": "folder" + } + ] + }, + "example-link-request-6": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 789868, + "obj_to": "user", + "obj_to_id": 31913, + "is_need_to_notify": true, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 789868, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "link" + } + ] + }, + "example-link2key_one_privilege-request": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834936, + "obj_to": "user", + "obj_to_id": 32510, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link2key_one_privilege-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 834936, + "obj_to_type": "user", + "obj_to_id": 32510, + "obj_to_title": "key_test2", + "action_type": "link" + } + ] + }, + "example-link2group_two_privileges-request": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834936, + "obj_to": "group", + "obj_to_id": 32510, + "company_id": "i848211059", + "privs": [ + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link2group_two_privileges-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 1316383, + "obj_to_type": "group", + "obj_to_id": 127995, + "obj_to_title": "Group", + "action_type": "link" + } + ] + }, + "example-link2user_not_in_company-request": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 816108, + "obj_to": "user", + "obj_to_id": 32510, + "company_id": "i848211059", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link2user_not_in_company-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 816108, + "obj_to_type": "user", + "obj_to_id": 32510, + "obj_to_title": "key_test2", + "action_type": "link" + } + ] + }, + "example-link-unlink_key-request": { + "ops": [ + { + "type": "link", + "obj": "conv", + "obj_id": 834825, + "obj_to": "user", + "obj_to_id": 31913, + "privs": [] + } + ] + }, + "example-link-unlink_key-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 834825, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "unlink" + } + ] + }, + "example-favorite-request-5": { + "ops": [ + { + "type": "favorite", + "obj": "conv", + "obj_id": 773375, + "favorite": true + } + ] + }, + "example-favorite-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 773375, + "obj": "conv" + } + ] + }, + "example-favorite-request-stage": { + "ops": [ + { + "type": "favorite", + "obj": "conv", + "obj_id": 833241, + "company_id": "i848211059", + "favorite": true + } + ] + }, + "example-favorite-response-stage": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 833241, + "obj": "conv" + } + ] + }, + "example-delete-request-10": { + "ops": [ + { + "type": "delete", + "obj": "conv", + "obj_id": 834087 + } + ] + }, + "example-delete-response-10": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 834087, + "proc": "ok" + } + ] + }, + "example-delete-request-stage": { + "ops": [ + { + "type": "delete", + "obj": "conv", + "obj_id": 834088, + "company_id": "i848211059" + } + ] + }, + "example-delete-response-stage": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "conv", + "obj_id": 834088, + "proc": "ok" + } + ] + }, + "example-restore-request-6": { + "ops": [ + { + "type": "restore", + "obj": "conv", + "obj_id": 834087 + } + ] + }, + "example-restore-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834087, + "obj": "conv", + "parent_folder_id": 210032 + } + ] + }, + "example-restore-request-stage": { + "ops": [ + { + "type": "restore", + "obj": "conv", + "obj_id": 834088, + "company_id": "i848211059" + } + ] + }, + "example-restore-response-stage": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834088, + "obj": "conv", + "parent_folder_id": 268661 + } + ] + }, + "example-destroy-request-6": { + "ops": [ + { + "type": "destroy", + "obj": "conv", + "obj_id": 834087 + } + ] + }, + "example-destroy-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834087, + "obj_type": "conv" + } + ] + }, + "example-destroy-request-stage": { + "ops": [ + { + "type": "destroy", + "obj": "conv", + "obj_id": 834088, + "company_id": "i848211059" + } + ] + }, + "example-destroy-response-stage": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 834088, + "obj_type": "conv" + } + ] + }, + "list-request-14": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "convs" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "pattern": { + "type": "string", + "minLength": 1, + "maxLength": 150, + "description": "Pattern for searching in name, description, ID, and URL parameters of API Call nodes of Processes / State Diagrams" + }, + "obj_type": { + "type": "string", + "enum": [ + "process", + "state" + ], + "description": "Type of object:
`process` — Process
`state` — State Diagram" + }, + "limit": { + "type": "integer", + "minimum": 1, + "maximum": 100, + "default": 20, + "description": "Defines the maximum number of objects in the response." + }, + "owner_id": { + "type": "integer", + "minimum": 0, + "description": "Object owner ID" + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "location": { + "type": "integer", + "enum": [ + "folder", + "stage", + "project" + ], + "description": "This parameter is used for filtering result data:
`folder` — The search will be performed in the company's root folder.
`stage` — The search will be performed within the chosen project.
`project` — The search will be performed in all of the company's projects. " + } + } + }, + "list-response-14": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "type": "string", + "default": "convs" + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Process / State diagram ID" + }, + "obj_type": { + "type": "string", + "default": "conv", + "description": "Object type:
`conv` — Process / State diagram" + }, + "create_time": { + "type": "integer", + "description": "Process / State diagram creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Process / State diagram change time in unixtime format" + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug", + "active_debug", + "transient" + ], + "description": "`transient` — system status for merge" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when an ID of a user that sends the request is the same as Process / State diagram owner ID" + }, + "owner_name": { + "type": "string", + "description": "Process / State diagram owner name" + }, + "owner_id": { + "type": "integer", + "description": "Process / State diagram owner ID" + }, + "title": { + "type": "string", + "description": "Process / State diagram name" + }, + "description": { + "type": "string", + "description": "Process / State diagram description" + }, + "escalation_conv": { + "type": "string", + "deprecated": true + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state", + "escalation" + ], + "description": "Type of object we are listing:
`process` — Process
`state` — State diagram
`escalation` — deprecated (special system process, designed to handle Process / State diagram errors)" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "stage_id": { + "type": "integer", + "description": "Stage ID" + }, + "project_title": { + "type": "string", + "description": "Project title" + }, + "stage_title": { + "type": "string", + "description": "Stage title" + } + } + } + } + } + }, + "example-list-request-14": { + "ops": [ + { + "pattern": "test", + "obj_type": "process", + "obj": "convs", + "owner_id": 27074, + "company_id": "i848211059", + "project_id": 375501, + "location": "stage", + "type": "list" + } + ] + }, + "example-list-response-12": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "convs", + "list": [ + { + "obj_id": 1007000, + "obj_type": "conv", + "create_time": 1667522490, + "change_time": 1667522490, + "status": "active", + "is_owner": true, + "owner_name": "First_Name Last_Name", + "owner_id": 27074, + "title": "test process", + "description": "", + "escalation_conv": "undefined", + "conv_type": "process", + "project_id": 375501, + "project_title": "test2", + "stage_id": 375502, + "stage_title": "production" + } + ] + } + ] + }, + "create-request-12": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "New Folder (the one that will be created) name" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "New Folder description" + }, + "folder_id": { + "type": "integer", + "description": "Parent folder ID" + }, + "obj_type": { + "type": "integer", + "description": "Type folder", + "default": 0, + "deprecated": true + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "create-response-12": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Folder that was created" + } + } + }, + "modify-request-11": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of a Folder that will be modified" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Name of a Folder that will be updated" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "nullable": true, + "description": "Folder description" + } + } + }, + "modify-response-11": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of a Folder that was modified" + } + } + }, + "link-request-7": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "obj_id", + "obj_to", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of the object that we move (Process | State diagram | Dashboard | Folder | Database instance) or share access to (Folder)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + }, + "obj_type": { + "type": "string", + "enum": [ + "conv", + "folder", + "dashboard", + "instance" + ], + "description": "Type of an object that we move to another folder:
`conv` — Process / State diagram;
`folder` — Folder;
`dashboard` — Dashboard;
`instance` — Database instance
this request parameter is required when the 'obj_to' request parameter is not present" + }, + "parent_id": { + "type": "integer", + "description": "Parent Folder ID (we move object from this folder)
(ID of an object is contained in the 'obj_id' request parameter);
object can be a Process / State diagram, Dashboard, Folder, Database instance
this request parameter is allowed when the 'obj_type' request parameter is present" + }, + "folder_id": { + "type": "integer", + "description": "Destination Folder ID (we move object to this folder)
(ID of an object is contained in the 'obj_id' request parameter);
object can be a Process / State diagram, Dashboard, Folder, Database instance
this request parameter is required when the 'obj_type' request parameter is present" + }, + "obj_to": { + "type": "string", + "enum": [ + "group", + "user", + "all" + ], + "description": "There are three values that relate to the \"Move to\" operation:
`user` — sharing access with an API Key / User;
`group` — sharing access with a Group;
`all` — sharing access with all - make object visible for all users
this request parameter is required when the 'obj_type' request parameter is not present" + }, + "obj_to_id": { + "type": "integer", + "minimum": 0, + "description": "ID of an API Key / User / Group with which we are sharing access to an object
(or changing settings of user rights over the shared object, or removing previously shared access to the object)
this request parameter is required when the request parameter 'obj_to' != \"all\"" + }, + "privs": { + "type": "array", + "uniqueItems": true, + "description": "empty array `[]` allowed
\n this request parameter is required when the 'obj_to' request parameter is present", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + } + } + }, + "link-response-7": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "enum": [ + "folder", + "conv", + "dashboard", + "instance" + ], + "description": "Type of an object, that we move or share access to:
`folder` — Folder;
`conv` — Process / State diagram;
`dashboard` — Dashboard;
`instance` — Database instance" + }, + "obj_id": { + "type": "integer", + "description": "ID of an object that we move (Process | State diagram | Dashboard | Folder | Database instance) or share access to (Folder)" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "folder", + "user", + "group", + "all" + ], + "description": "`folder` — when we move an object to another folder;

other allowed values when we share access:
`user` — sharing access with an API Key / User;
`group` — sharing access with a Group;
`all` — sharing with all - make visible for all users;
this response parameter value equals \"all\" | \"user\" | \"group\" when the request parameter 'obj_to' = \"all\" | \"user\" | \"group\" and the 'obj_type' request parameter is not present;
this response parameter value equals \"folder\" when the request parameter 'obj_type' = \"folder\"" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of an API Key / User / Group with which we are sharing access to an object
(or changing settings of user rights over the shared object, or denying access to the object),
`0` in this case means that we share access with all;

Destination Folder ID (we move an object to this folder),
`0` in this case means the Root folder
this response parameter value equals the value of the 'obj_to_id' request parameter when the request parameter 'obj_to' = \"user\" | \"group\" and the 'obj_type' request parameter is not present;
this response parameter value equals the value of the 'folder_id' value request parameter when the request parameter 'obj_type' = \"folder\" | \"conv\" | \"dashboard\" | \"instance\"" + }, + "obj_to_title": { + "type": "string", + "description": "this value can be:
- API Key / User Name — when we share access with an API Key / User;
- Group Name — when we share access with a Group;
- Destination Folder Name — when we move a Folder to another folder;
- Name of object - Process / State diagram / Dashboard / Database instance — when we move an object to another folder
this response parameter is present when the request parameter 'obj_type' = \"folder\", and the request parameter 'obj_to_type' = \"user\"" + }, + "action_type": { + "type": "string", + "enum": [ + "link", + "unlink", + "move" + ], + "description": "Operation type:
`link` — sharing access to an object;
`unlink` — remove previously shared access to an object;
`move` — move object to another folder
this response parameter is present when the request parameter 'obj_type' = \"folder\" and the request parameter 'obj_to_type' = \"user\"" + }, + "from_folder": { + "type": "integer", + "description": "Parent Folder ID (we move object from this folder)
this response parameter is present (for the move operation only - not for sharing access) when the 'parent_id' request parameter is present" + }, + "to_folder": { + "type": "integer", + "description": "Destination Folder ID (we move object to this folder)
this response parameter is present (for the move operation only and not for sharing access) when the 'folder_id' request parameter is present" + }, + "from_folder_name": { + "type": "string", + "description": "Parent Folder Name (we move object from this folder)
this response parameter is present (for the move operation only and not for sharing access) when there is the 'parent_id' request parameter" + }, + "to_folder_name": { + "type": "string", + "description": "Destination Folder Name (we move an object to this folder)
this response parameter is present (for the move operation only and not for sharing access) when there is the 'folder_id' request parameter" + }, + "user_id": { + "type": "integer", + "description": "ID of a User which makes the request
this response parameter is present (for the move operation only and not for sharing access) when there is the 'folder_id' request parameter" + }, + "user_name": { + "type": "string", + "description": "First and last names of a User which makes the request
this response parameter is present (for the move operation only and not for sharing access) when there is the 'folder_id' request parameter" + } + } + }, + "list-request-15": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Folder ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "`group` — get a list of users and groups that have access to a folder
\n don't send this parameter for getting a list of objects in a folder" + }, + "filter": { + "type": "string", + "enum": [ + "folder", + "conv", + "conveyor", + "dashboard", + "instance", + "my", + "shared", + "favorites", + "recent", + "deleted" + ], + "description": "this parameter is used for filtering result data:
`folder` — only Folders
`conv` — Process / State diagram, folders
`conveyor` — only Process
`dashboard` — Dashboard
`instance` — Database instance
`my` — I am Owner (User that makes the request)
`shared` — Object is shared with a User that makes the request
`favorites` — Object is starred (add to the favorites list)
`recent` — Recently created/edited Objects
`deleted` — Deleted Objects" + }, + "sort": { + "type": "string", + "enum": [ + "name", + "title", + "owner", + "date" + ], + "description": "this parameter is used for sorting result data:
`name` — by Title
`title` — by Title
`owner` — by Owner Name
`date` — by last editing time" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "description": "this parameter is used for result data sorting. Use it together with the sort parameter:
`asc` — in ascending order;
`desc` — in descending order." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "owner_id": { + "type": "integer", + "minimum": 0, + "description": "Folder owner ID, needs to be included in a request sent by a superadmin" + } + } + }, + "list-response-15": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "Folder ID" + }, + "parent_folder_id": { + "type": "integer", + "description": "Parent Folder ID" + }, + "parent_folder_title": { + "type": "string", + "description": "Parent Folder name" + }, + "list": { + "type": "array", + "description": "List of objects in the Folder", + "items": { + "type": "object", + "properties": { + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Flag that shows whether Folder access was shared" + }, + "favorite": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Flag that shows whether the Folder was added to the favorites list (Starred)
" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "undeployed": { + "type": "integer", + "description": "Number of undeployed objects" + }, + "childs": { + "type": "integer", + "description": "Number of subfolders" + }, + "size": { + "type": "integer", + "description": "Number of objects in the Folder" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as of the Folder owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Object owner ID" + }, + "owner_name": { + "type": "string", + "description": "Object owner name" + }, + "owner_login": { + "type": "string", + "description": "Object owner login" + }, + "owner_group_id": { + "type": "integer", + "description": "Folder owner Group's ID" + }, + "obj_id": { + "type": "integer", + "description": "ID of an object" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard", + "instance" + ], + "description": "Type of an object:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "`db_call` — Database instance for DB_Call node
this response parameter is present when the response parameter 'obj_type' = \"instance\"" + }, + "title": { + "type": "string", + "description": "Object name" + }, + "description": { + "type": "string", + "description": "Object description" + }, + "create_time": { + "type": "integer", + "description": "Object creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Object change time in unixtime format" + }, + "company_id": { + "type": "string", + "nullable": true, + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "stage_id": { + "type": "integer", + "description": "Stage ID" + }, + "version": { + "type": "integer", + "nullable": true, + "description": "Folder version" + }, + "parent_id": { + "type": "integer", + "description": "Folder ID where the object is stored" + } + } + } + } + } + }, + "list-response-group": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "Folder ID" + }, + "list_obj": { + "type": "string", + "default": "group", + "description": "this response parameter is the same as the one in the request parameter" + }, + "list": { + "type": "array", + "description": "List of subjects that have access to the Folder", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "description": "Type of an object that has access to the Folder", + "enum": [ + "user", + "group" + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of an object that has access to the Folder" + }, + "login_id": { + "type": "integer", + "description": "User login's ID" + }, + "login": { + "type": "string", + "description": "User login (empty for an API Key)
" + }, + "title": { + "type": "string", + "description": "Name of an object that has access to the Folder" + } + } + } + } + } + }, + "show-request-10": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Folder ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "show-response-11": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "Folder ID" + }, + "title": { + "type": "string", + "description": "Folder title" + }, + "obj_type": { + "type": "integer", + "description": "Folder type
`0` - regular folder
`1` - root user folder
`2` - project folder
`3` - stage folder", + "enum": [ + 0, + 1, + 2, + 3 + ] + }, + "parent_obj_id": { + "type": "integer", + "description": "ID of the folder parent object" + }, + "parent_obj_type": { + "type": "string", + "description": "Type of the folder parent object" + } + } + }, + "favorite-request-6": { + "type": "object", + "title": "favorite", + "required": [ + "type", + "obj", + "obj_id", + "favorite" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "favorite" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of the Folder that will be added to/deleted from the favorites list" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/favorite" + } + ] + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "favorite-response-6": { + "type": "object", + "title": "favorite", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Folder that was added to/deleted from the favorites list" + } + } + }, + "delete-request-11": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 1, + "description": "ID of the Folder that will be deleted" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "delete-response-11": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Folder that was deleted" + } + } + }, + "destroy-request-7": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 1, + "description": "ID of the Folder that will be destroyed (irreversibly deleted)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "destroy-response-7": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Folder that was destroyed (irreversibly deleted)" + } + } + }, + "restore-request-7": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "minimum": 1, + "description": "ID of a Folder that will be restored" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + } + } + }, + "restore-response-7": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder" + }, + "obj_id": { + "type": "integer", + "description": "ID of a Folder that was restored" + }, + "parent_folder_id": { + "type": "integer", + "description": "Parent Folder ID (inside which the Folder was restored)" + } + } + }, + "example-create-request-11": { + "ops": [ + { + "title": "test3", + "description": "", + "folder_id": 0, + "obj": "folder", + "type": "create" + } + ] + }, + "example-create-response-11": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 296136 + } + ] + }, + "example-modify-request-11": { + "ops": [ + { + "title": "test4", + "description": null, + "type": "modify", + "obj": "folder", + "obj_id": 296136 + } + ] + }, + "example-modify-response-11": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 296136 + } + ] + }, + "example-link-request-7": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_id": 296137, + "obj_to": "user", + "obj_to_id": 31913, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "folder", + "obj_id": 296137, + "obj_to_type": "user", + "obj_to_id": 31913, + "obj_to_title": "test", + "action_type": "link" + } + ] + }, + "example-link-request-moving": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_type": "conv", + "obj_id": 789868, + "folder_id": 287391, + "parent_id": 210032 + } + ] + }, + "example-link-response-moving": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "conv", + "obj_id": 789868, + "obj_to_type": "folder", + "obj_to_id": 287391, + "obj_to_title": "test789", + "action_type": "move", + "from_folder": 210032, + "to_folder": 287391, + "from_folder_name": "test", + "to_folder_name": "test789", + "user_id": 27074, + "user_name": "First_Name Last_Name" + } + ] + }, + "example-link-request-unlink": { + "ops": [ + { + "type": "link", + "obj": "folder", + "obj_id": 296137, + "obj_to": "user", + "obj_to_id": 27201, + "privs": [] + } + ] + }, + "example-link-response-unlink": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "folder", + "obj_id": 296137, + "obj_to_type": "user", + "obj_to_id": 27201, + "obj_to_title": "test", + "action_type": "unlink" + } + ] + }, + "example-list-request-15": { + "ops": [ + { + "obj_id": 210032, + "sort": "date", + "order": "asc", + "type": "list", + "obj": "folder", + "list_obj": "group" + } + ] + }, + "example-list-response-13": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 210032, + "proc": "ok", + "parent_folder_id": 0, + "parent_folder_title": "Root folder", + "list": [ + { + "is_shared": false, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 0, + "is_owner": true, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 303624, + "obj_type": "folder", + "create_time": 1660300990, + "change_time": 1660300990, + "title": "test23", + "description": "", + "company_id": null, + "project_id": 0, + "stage_id": 0, + "owner_group_id": 56079, + "version": null, + "parent_id": 487763 + } + ] + } + ] + }, + "example-list-response-group-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 210032, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 30978, + "login_id": 30978, + "title": "Aria Stark", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "aria.stark@corezoid.com" + } + ] + } + ] + }, + "example-show-request-10": { + "ops": [ + { + "obj_id": 51952, + "type": "show", + "obj": "folder" + } + ] + }, + "example-show-response-9": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder", + "obj_id": 51952, + "title": "ПИН", + "obj_type": 0, + "parent_obj_id": 51948, + "parent_obj_type": "folder" + } + ] + }, + "example-favorite-request-6": { + "ops": [ + { + "type": "favorite", + "obj": "folder", + "obj_id": 296137, + "favorite": true, + "company_id": "i848211059" + } + ] + }, + "example-favorite-response-6": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 296137, + "obj": "folder" + } + ] + }, + "example-delete-request-11": { + "ops": [ + { + "type": "delete", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + }, + "example-delete-response-11": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "folder", + "obj_id": 313726, + "proc": "ok" + } + ] + }, + "example-destroy-request-7": { + "ops": [ + { + "type": "destroy", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + }, + "example-destroy-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 313726, + "obj_type": "folder" + } + ] + }, + "example-restore-request-7": { + "ops": [ + { + "type": "restore", + "obj": "folder", + "obj_id": 313726, + "company_id": "i848211059" + } + ] + }, + "example-restore-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 313726, + "obj": "folder", + "parent_folder_id": 313725 + } + ] + }, + "list-request-16": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "path_to_folder" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Object ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + } + } + }, + "list-response-16": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "path_to_folder" + }, + "list": { + "type": "array", + "description": "List of objects", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Object ID" + }, + "title": { + "type": "string", + "description": "Object name" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "owner_id": { + "type": "integer", + "description": "Object owner's ID" + }, + "owner_name": { + "type": "string", + "description": "Object owner's name" + }, + "owner_login": { + "type": "string", + "description": "Object owner's login" + }, + "type": { + "type": "string", + "enum": [ + "folder", + "stage", + "project" + ], + "description": "An object type:
`folder` — Folder
`stage` — Stage
`project` — Project
this response parameter not exists for root folder - when the parameter 'obj_id' = 0
" + }, + "description": { + "type": "string", + "description": "Object description
this response parameter not exists for root folder - when the parameter 'obj_id' = 0
" + }, + "short_name": { + "type": "string", + "description": "Project / Stage short name
this response parameter exists when the request parameter \"project_id\" exists (in project and in stage only), when the response parameter 'type' = \"project\" | \"stage\"" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag of Stage state - is `true` when immutable
this response parameter exists when the request parameter \"project_id\" exists (in stage only), when the response parameter 'type' = \"stage\"" + } + } + } + } + } + }, + "example-list-request-16": { + "ops": [ + { + "type": "list", + "obj": "path_to_folder", + "obj_id": 659209, + "company_id": "i738314881", + "project_id": 659206 + } + ] + }, + "example-list-response-14": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "path_to_folder", + "list": [ + { + "obj_id": 0, + "title": "Test company", + "company_id": "i738314881", + "privs": [], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853" + }, + { + "obj_id": 659206, + "title": "Project_1709105873799", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "project", + "description": "new", + "short_name": "project1709105873799" + }, + { + "obj_id": 659207, + "title": "production", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "stage", + "description": "new", + "short_name": "production", + "immutable": false + }, + { + "obj_id": 659209, + "title": "path_to_folder_1709105874311", + "company_id": "i738314881", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + } + ], + "favorite": false, + "owner_id": 60184, + "owner_name": "forApiTest", + "owner_login": "655cbcae56167c312501b853", + "type": "folder", + "description": "folder" + } + ] + } + ] + }, + "list-request-17": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "folder_branch" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Folder ID" + }, + "owner_id": { + "type": "integer", + "minimum": 0 + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "list-response-17": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "folder_branch" + }, + "obj_id": { + "type": "integer", + "description": "Folder ID" + }, + "list": { + "type": "array", + "description": "List of all folders", + "items": { + "type": "object", + "properties": { + "parent_id": { + "type": "integer", + "description": "Parent folder id" + }, + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag shows was Folder access shared" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "undeployed": { + "type": "integer", + "description": "Number of undeployed objects" + }, + "childs": { + "type": "integer", + "description": "Number of subfolders" + }, + "size": { + "type": "integer", + "description": "Number of objects in folder" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as Folder owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Folder owner ID" + }, + "owner_name": { + "type": "string", + "description": "Folder owner name" + }, + "owner_login": { + "type": "string", + "description": "Folder owner login" + }, + "obj_id": { + "type": "integer", + "description": "Folder ID" + }, + "obj_type": { + "type": "string", + "default": "folder", + "description": "Object type" + }, + "create_time": { + "type": "integer", + "description": "Folder creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Folder change time in unixtime format" + }, + "title": { + "type": "string", + "description": "Folder title" + }, + "description": { + "type": "string", + "description": "Folder description" + }, + "company_id": { + "type": "string", + "nullable": true, + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "stage_id": { + "type": "integer", + "description": "Stage ID" + }, + "owner_group_id": { + "type": "integer", + "description": "Folder owner's Group's ID" + }, + "version": { + "type": "integer", + "nullable": true, + "description": "Folder version" + } + } + } + } + } + }, + "example-list-request-17": { + "ops": [ + { + "obj_id": 210032, + "owner_id": 27074, + "type": "list", + "obj": "folder_branch" + } + ] + }, + "example-list-response-15": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "folder_branch", + "obj_id": 210032, + "list": [ + { + "parent_id": 0, + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 0, + "size": 9, + "is_owner": false, + "owner_id": 5381, + "owner_name": "First_Name Last_Name", + "owner_login": "380991234567", + "obj_id": 218835, + "obj_type": "folder", + "create_time": 1649940895, + "change_time": 1649940895, + "title": "COR-6332-filter/map", + "description": "", + "company_id": null, + "project_id": 0, + "stage_id": 0, + "owner_group_id": 14537, + "version": null + } + ] + } + ] + }, + "create-request-13": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "project_id", + "project_short_name", + "short_name", + "title" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "folder_id": { + "type": "integer", + "description": "Parent Folder ID
this request parameter is required when there is no 'project_id' or 'project_short_name' request parameter (at least one of them must be defined)." + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "description": { + "type": "string", + "nullable": true, + "minLength": 0, + "maxLength": 2000, + "description": "Stage description" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Name of the new Stage that will be created" + }, + "update_not_uniq_short_name": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "update the non-unique 'short_name' parameter" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Stage state flag - is `true` when a Stage is immutable" + } + } + }, + "create-response-13": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Stage that was created" + } + } + }, + "modify-request-12": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id", + "obj_short_name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "ID of a Stage that will be modified
to modify a Stage you need to send the 'obj_id'. You can also send 'obj_short_name' instead of 'obj_id', but in this case you'll need to add one of the following parameters: 'project_id' or 'project_short_name';
this request parameter is required when there is no 'obj_short_name' request parameter" + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is required when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id' or 'project_short_name'" + }, + "description": { + "type": "string", + "nullable": true, + "minLength": 0, + "maxLength": 2000, + "description": "Description of a Stage that will be modified" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Name of a Stage that will be modified" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Stage state flag - is `true` when a Stage is immutable" + } + } + }, + "modify-response-12": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Stage that was modified" + } + } + }, + "list-request-18": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id", + "obj_short_name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID
to get a Stage shared access list, you need to send the 'obj_id'. You can also send 'obj_short_name' instead of 'obj_id', but in this case you'll need to add one of the following parameters: 'project_id' or 'project_short_name';
this request parameter is present when there is no 'obj_short_name' request parameter." + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is present when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id', or 'project_short_name'." + }, + "filter": { + "type": "string", + "enum": [ + "folder", + "conveyor", + "dashboard", + "instance", + "config", + "my", + "shared", + "favorites", + "recent" + ], + "description": "this parameter is used for filtering the results:
`folder` — Folders in Stage
`conveyor` — Processes and State diagrams in a Stage
`dashboard` — Dashboards in a Stage
`instance` — Database instances in a Stage
`config` — Configuration files in a Stage
`my` — Objects in a Stage which you are an owner of
`shared` — Objects in a Stage which are shared with you
`favorites` — Objects in a Stage which were added to the favorites list (Starred)
`recent` — Objects in a Stage which were recently updated
this request parameter is applied only when there is no 'list_obj' request parameter" + }, + "sort": { + "type": "string", + "enum": [ + "name", + "title", + "owner", + "date" + ], + "default": "name", + "description": "sort response list by parameter:
`title` — Stage title
`name` — Stage title
`owner` — Stage owner
`date` — Stage last change date and time
this request parameter is applied only when there is no 'list_obj' request parameter" + }, + "order": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc", + "description": "this parameter is used for sorting the results:
`asc` — in ascending order
`desc` — in descending order
this request parameter is applied only when there is no 'list_obj' request parameter" + }, + "list_obj": { + "type": "string", + "enum": [ + "group", + "user", + "uncommited" + ], + "description": "`group` — get a list of Groups that have access to a Stage
`user` — get a list of Users that have access to a Stage
`uncommited` — get a list of undeployed Processes in Stage" + } + } + }, + "list-response-18": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID" + }, + "list": { + "type": "array", + "description": "API Keys and Users to which Stage access was granted;
list value can be the `[]` empty array", + "items": { + "type": "object", + "properties": { + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag that shows whether access to an Object in a Stage was shared" + }, + "favorite": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag showing whether an Object in Stage was added to the favorites list (Starred)" + }, + "privs": { + "type": "array", + "description": "An array of user rights settings for a shared object
", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "undeployed": { + "type": "integer", + "description": "Number of undeployed objects
this response parameter is present when the response parameter 'obj_type' = \"folder\"" + }, + "childs": { + "type": "integer", + "description": "Number of subfolders
this response parameter is present when the response parameter 'obj_type' = \"folder\"" + }, + "size": { + "type": "integer", + "description": "Number of objects in folder
this response parameter is present when the response parameter 'obj_type' = \"folder\"" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of a user that sends the request is the same as an Object owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Object owner ID" + }, + "owner_name": { + "type": "string", + "description": "Object owner name" + }, + "owner_login": { + "type": "string", + "description": "Object owner login" + }, + "obj_id": { + "type": "integer", + "description": "Folder / Process / State diagram / Dashboard / Database instance ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard", + "instance" + ], + "description": "Type of an Object in a Stage (when the request parameter 'list_obj' is not present):
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "`db_call` — Database instance for the DB Call node
this response parameter is present when the response parameter 'obj_type' = \"instance\"" + }, + "create_time": { + "type": "integer", + "description": "Object creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "description": "Object change time in unixtime format" + }, + "title": { + "type": "string", + "description": "Object name" + }, + "description": { + "type": "string", + "description": "Object description" + }, + "company_id": { + "type": "string", + "nullable": true, + "description": "Company ID" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "stage_id": { + "type": "integer", + "description": "Stage ID" + }, + "owner_group_id": { + "type": "integer", + "description": "Object owner's Group ID" + }, + "version": { + "type": "integer", + "nullable": true, + "description": "Object version" + } + } + } + } + } + }, + "list-response-uncommited": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "uncommited" + ], + "description": "this response parameter is present (with the same value) when there is the 'list_obj' request parameter" + }, + "list": { + "type": "array", + "description": "API Keys and Users to which Stage access was granted;
list value can be the `[]` empty array", + "items": { + "type": "object", + "properties": { + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of a user that sends the request is the same as a Process / State diagram owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Process / State diagram owner ID" + }, + "owner_name": { + "type": "string", + "description": "Process / State diagram owner name" + }, + "owner_login": { + "type": "string", + "description": "Process / State diagram owner login" + }, + "obj_id": { + "type": "integer", + "description": "Process / State diagram ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard", + "instance" + ], + "description": "Type of undeployed object:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "`db_call` — Database instance for the DB Call node
this response parameter is present when the response parameter 'obj_type' = \"instance\"" + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state" + ], + "description": "Type of undeployed object:
`process` — Process
`state` — State diagram
this response parameter is present when the response parameter 'obj_type' = \"conv\"" + }, + "title": { + "type": "string", + "description": "Process / State diagram name" + }, + "folder_id": { + "type": "integer", + "description": "ID of a parent folder in which an undeployed object (Process / State diagram) is stored" + }, + "change_time": { + "type": "integer", + "description": "Process / State diagram change time in unixtime format" + } + } + } + } + } + }, + "list-response-group-2": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID" + }, + "list_obj": { + "type": "string", + "enum": [ + "group" + ], + "description": "this response parameter is present (with the same value) when there is the 'list_obj' request parameter" + }, + "list": { + "type": "array", + "description": "API Keys and Users to which Stage access was granted;
list value can be the `[]` empty array", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "enum": [ + "user" + ] + }, + "obj_id": { + "type": "integer", + "description": "API Key ID/User ID
this response parameter is present when a Stage was shared with an API Key" + }, + "login_id": { + "type": "integer", + "description": "API Key ID
this response parameter is present when a Stage was shared with an API Key" + }, + "title": { + "type": "string", + "description": "API Key Name/User's email" + }, + "privs": { + "type": "array", + "description": "An array of user rights settings for a shared object - Process/State diagram", + "items": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + }, + "login": { + "type": "string", + "description": "login value can be `\"\"` empty string for an API Key" + }, + "is_invite": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "indicator of a user invitation
this response parameter is present when a Stage was shared with a User not in the company" + }, + "invite_hash": { + "type": "string", + "description": "hash for URL that user should use to confirm an invitation
this response parameter is present when a Stage was shared with a User not in the company" + } + } + } + } + } + }, + "show-request-11": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "project_id", + "project_short_name", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "type": "integer", + "default": 0, + "description": "Project ID
'project_id' or 'project_short_name' must be sent in the request" + }, + "project_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project short name
'project_id' or 'project_short_name' must be sent in the request" + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID" + } + } + }, + "show-response-12": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "uniq_undeployed_versions": { + "type": "integer", + "description": "count of unique undeployed versions" + }, + "uniq_undeployed_versions_detail": { + "type": "array", + "description": "undeployed objects (Processes / State diagrams) list", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "ID of an undeployed Process / State diagram" + }, + "obj_type": { + "type": "string", + "enum": [ + "conv" + ], + "description": "Type of an undeployed object:
`conv` — Process / State diagram" + }, + "version": { + "type": "integer", + "description": "version - change time in unixtime format

example:
1667399615" + } + } + } + }, + "is_shared": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "A flag showing whether a Stage was shared" + }, + "favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "undeployed": { + "type": "integer", + "description": "count of undeployed objects (Processes / State diagrams)" + }, + "childs": { + "type": "integer", + "description": "count of folders inside a Stage (excluding nesting - in the root only)" + }, + "size": { + "type": "integer", + "description": "count of all objects (all types) inside a Stage - folders and processes, state diagrams and dashboards (located in the root only, no nesting)" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of a user that sends the request is the same as a Stage owner ID" + }, + "owner_id": { + "type": "integer", + "description": "Stage owner ID" + }, + "owner_name": { + "type": "string", + "description": "Stage owner name" + }, + "owner_login": { + "type": "string", + "description": "Stage owner login" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID" + }, + "obj_type": { + "type": "string", + "default": "stage", + "description": "Stage type" + }, + "create_time": { + "type": "integer", + "example": 1655977588, + "description": "Stage creation time in unixtime format" + }, + "change_time": { + "type": "integer", + "example": 1655977588, + "description": "Stage change time in unixtime format" + }, + "title": { + "type": "string", + "description": "Stage name" + }, + "short_name": { + "type": "string", + "description": "Stage short name" + }, + "description": { + "type": "string", + "description": "Stage description" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "immutable": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Flag that shows whether a Stage is immutable" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "owner_group_id": { + "type": "integer", + "description": "Group owner ID" + }, + "parent_obj_id": { + "type": "integer", + "description": "Parent Object (Project) ID" + }, + "parent_obj_type": { + "type": "string", + "default": "project", + "description": "Parent Object Type" + } + } + }, + "link-request-8": { + "type": "object", + "title": "link", + "required": [ + "type", + "obj", + "company_id", + "obj_id", + "obj_short_name", + "obj_to", + "obj_to_id", + "privs" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "link" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID
to share Stage access, you need to send 'obj_id' or 'obj_short_name' (with one of the 'project_id' or 'project_short_name' parameters defined)" + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is required when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id' or 'project_short_name'" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "obj_to": { + "type": "string", + "enum": [ + "group", + "user" + ], + "description": "Sharing access type:
`user` — sharing access to an API Key / User;
`group` — sharing access to a Group" + }, + "obj_to_id": { + "type": "integer", + "minimum": 1, + "description": "ID of an API Key, User or a Group with which we are sharing access to a Stage" + }, + "is_need_to_notify": { + "allOf": [ + { + "$ref": "#/components/schemas/is_need_to_notify" + } + ] + } + } + }, + "link-response-8": { + "type": "object", + "title": "link", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "Stage ID" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "user", + "group" + ], + "description": "Stage was shared with:
`user` — API Key / User;
`group` — Group" + }, + "obj_to_id": { + "type": "integer", + "description": "User / API Key / Group ID" + }, + "obj_to_title": { + "type": "string", + "description": "User / API Key / Group Name" + }, + "action_type": { + "allOf": [ + { + "$ref": "#/components/schemas/action_type" + } + ] + } + } + }, + "delete-request-12": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID
to delete a Stage, you need to send the 'obj_id', you can also send 'obj_short_name' instead of 'obj_id', but in this case you'll need to add one of the following parameters: 'project_id', or 'project_short_name';
this request parameter is present when there is no 'obj_short_name' request parameter." + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is required when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id', or 'project_short_name'." + } + } + }, + "delete-response-12": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Stage that was deleted" + } + } + }, + "restore-request-8": { + "type": "object", + "title": "restore", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "restore" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID
to restore a Stage, you need to send the 'obj_id'. You can also send the 'obj_short_name' instead of 'obj_id', but in this case you'll need to add one of the following parameters: 'project_id' or 'project_short_name';
this request parameter is required when there is no 'obj_short_name' request parameter" + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is required when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id' or 'project_short_name'" + } + } + }, + "restore-response-8": { + "type": "object", + "title": "restore", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Stage that was restored" + } + } + }, + "destroy-request-8": { + "type": "object", + "title": "destroy", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "destroy" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stage" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "obj_id": { + "type": "integer", + "minimum": 0, + "description": "Stage ID
to delete a Stage forever you need to send the 'obj_id', or send the 'obj_short_name' instead, but in this case you need'll to add one of the following parameters: 'project_id', or 'project_short_name';
this request parameter is required when there is no 'obj_short_name' request parameter." + }, + "obj_short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Stage short name
this request parameter is required when there is no 'obj_id' request parameter;
this request parameter also requires another request parameter: 'project_id', or 'project_short_name'." + } + } + }, + "destroy-response-8": { + "type": "object", + "title": "destroy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_type": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stage" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Stage that was destroyed" + } + } + }, + "example-create-request-12": { + "ops": [ + { + "title": "New Stage", + "description": "", + "company_id": "332c5987-6e70-4c3a-9a2c-b88ddc05920d", + "obj": "stage", + "short_name": "new-stage", + "project_id": 591827, + "immutable": false, + "type": "create" + } + ] + }, + "example-create-response-12": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "obj_id": 316139 + } + ] + }, + "example-modify-request-12": { + "ops": [ + { + "title": "develop", + "description": null, + "project_id": 268659, + "short_name": "develop-test", + "immutable": false, + "type": "modify", + "obj": "stage", + "obj_id": 268661, + "company_id": "i848211059" + } + ] + }, + "example-modify-response-12": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "obj_id": 268661 + } + ] + }, + "example-list-request-18": { + "ops": [ + { + "obj_id": 316139, + "obj": "stage", + "company_id": "i848211059", + "type": "list", + "list_obj": "group" + } + ] + }, + "example-list-response-16": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 268661, + "proc": "ok", + "list": [ + { + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 0, + "childs": 1, + "size": 2, + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 313725, + "obj_type": "folder", + "create_time": 1661440431, + "change_time": 1661440431, + "title": "test", + "description": "", + "company_id": "i848211059", + "project_id": 268659, + "stage_id": 268661, + "owner_group_id": 56079, + "version": null + } + ] + } + ] + }, + "example-list-group-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 316139, + "list_obj": "group", + "proc": "ok", + "list": [ + { + "obj": "user", + "obj_id": 32510, + "login_id": 32510, + "title": "key_test2", + "privs": [ + { + "type": "view", + "list_obj": [ + "all" + ] + } + ], + "login": "", + "is_invite": true, + "invite_hash": "eab06fde509de5a03512f64116ce4598d055bda8" + } + ] + } + ] + }, + "example-list-uncommited-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 268661, + "list_obj": "uncommited", + "proc": "ok", + "list": [ + { + "is_owner": false, + "owner_id": 56079, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 1006997, + "obj_type": "conv", + "conv_type": "process", + "title": "test2", + "folder_id": 268661, + "change_time": 1667478333 + } + ] + } + ] + }, + "example-show-request-11": { + "ops": [ + { + "type": "show", + "obj": "stage", + "obj_id": 375503, + "project_id": 375501, + "company_id": "i848211059" + } + ] + }, + "example-show-response-10": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stage", + "uniq_undeployed_versions": 1, + "uniq_undeployed_versions_detail": [ + { + "obj_id": 1007000, + "obj_type": "conv", + "version": 1667522497 + } + ], + "is_shared": true, + "favorite": false, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ], + "undeployed": 1, + "childs": 0, + "size": 1, + "is_owner": false, + "owner_id": 27074, + "owner_name": "First_Name Last_Name", + "owner_login": "owner.email@corezoid.com", + "obj_id": 375503, + "obj_type": "stage", + "create_time": 1667522468, + "change_time": 1667522468, + "title": "develop", + "short_name": "develop", + "description": "", + "company_id": "i848211059", + "immutable": false, + "project_id": 375501, + "owner_group_id": 56079, + "parent_obj_id": 375501, + "parent_obj_type": "project" + } + ] + }, + "example-link-request-8": { + "ops": [ + { + "type": "link", + "obj": "stage", + "obj_id": 316139, + "obj_to": "user", + "obj_to_id": 32510, + "is_need_to_notify": true, + "company_id": "i848211059", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-link-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_type": "stage", + "obj_id": 316139, + "obj_to_type": "user", + "obj_to_id": 32510, + "obj_to_title": "test_key", + "action_type": "link" + } + ] + }, + "example-delete-request-12": { + "ops": [ + { + "type": "delete", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059", + "project_id": 268659 + } + ] + }, + "example-delete-response-12": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 318305, + "proc": "ok" + } + ] + }, + "example-restore-request-8": { + "ops": [ + { + "type": "restore", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059" + } + ] + }, + "example-restore-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "stage", + "obj_id": 318305, + "proc": "ok" + } + ] + }, + "example-destroy-request-8": { + "ops": [ + { + "type": "destroy", + "obj": "stage", + "obj_id": 318305, + "company_id": "i848211059" + } + ] + }, + "example-destroy-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 318305, + "obj_type": "stage" + } + ] + }, + "show-request-12": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "start", + "end", + "filter", + "interval" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "used_traff" + }, + "start": { + "type": "integer", + "description": "The start date of the report (timestamp)" + }, + "end": { + "type": "integer", + "description": "The end date of the report (timestamp)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "filter": { + "type": "string", + "enum": [ + "tacts", + "opers", + "traff" + ], + "description": "A metric type to get statistics:
`tacts` — A number of state changes (maximum number of transitions between the nodes)
`opers` — A number of tasks processed by Process or State diagram
`traff` — A value of traffic (in MB) processed by Process or State diagram" + }, + "interval": { + "type": "string", + "enum": [ + "minute", + "hour", + "day", + "month" + ], + "description": "An interval type (dimension) to group statistics" + } + } + }, + "show-response-13": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "list": { + "type": "array", + "description": "The list of report data", + "items": { + "type": "object", + "properties": { + "opers": { + "type": "integer", + "description": "A value for requested metric" + }, + "date": { + "type": "string", + "description": "The value of the requested dimension (timestamp) is converted to a date in string format", + "pattern": "YYYY-MM-DD HH:MM:SS" + } + } + } + } + } + }, + "example-show-request-12": { + "ops": [ + { + "start": 1650834000, + "end": 1650910485, + "company_id": "i92454874049", + "filter": "opers", + "interval": "hour", + "type": "show", + "obj": "used_traff" + } + ] + }, + "example-show-response-11": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "opers": 4, + "date": "2022-03-23" + } + ] + } + ] + }, + "show-request-13": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "start", + "end", + "order_by", + "order_field" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "sys_stat" + }, + "start": { + "type": "integer", + "description": "The start date of the report (timestamp)" + }, + "end": { + "type": "integer", + "description": "The end date of the report (timestamp)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "order_field": { + "type": "string", + "enum": [ + "tacts", + "opers", + "traff" + ], + "description": "A metric to order the report results:
`tacts` — A number of state changes (maximum number of transitions between the nodes)
`opers` — A number of tasks processed by Process or State diagram
`traff` — A value of traffic (in MB) processed by Process or State diagram" + }, + "owner_id": { + "type": "integer", + "description": "Process owner ID" + }, + "conv_id": { + "type": "integer", + "description": "Process ID" + }, + "order_by": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ], + "description": "this parameter is used for sorting result data:
`ASC` — in ascending order;
`DESC` — in descending order." + }, + "limit": { + "type": "integer", + "minLength": 1, + "maxLength": 15, + "description": "A number of max results in report" + } + } + }, + "show-response-14": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "sys_stat" + }, + "conv_id": { + "type": "integer", + "description": "Process / State diagram ID" + }, + "data": { + "type": "array", + "description": "The list of report data", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "Process / State diagram ID" + }, + "conv_name": { + "type": "string", + "description": "Process / State diagram Name" + }, + "owner_id": { + "type": "integer", + "description": "Process / State diagram owner's ID" + }, + "owner_name": { + "type": "string", + "description": "Process / State diagram owner's name" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "date": { + "type": "string", + "description": "The value of the requested dimension (timestamp) is converted to a date in string format", + "pattern": "YYYY-MM-DD HH:MM:SS" + }, + "folder_id": { + "type": "integer", + "description": "ID of the Folder where Process / State diagram is stored" + }, + "opers": { + "type": "integer", + "description": "Number of Tasks processed in Process / State diagram" + }, + "tacts": { + "type": "integer", + "description": "Number of state changes (maximum number of transitions between the nodes)" + }, + "traff": { + "type": "integer", + "description": "A value of traffic (in MB) processed by Process / State diagram" + } + } + } + } + } + }, + "example-show-request-13": { + "ops": [ + { + "start": 1669033536, + "end": 1669638336, + "company_id": "i702619617", + "order_field": "opers", + "owner_id": 25130, + "conv_id": 1006996, + "type": "show", + "obj": "sys_stat", + "order_by": "DESC", + "limit": 10 + } + ] + }, + "example-show-response-12": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "conv_id": "undefined", + "data": [ + { + "conv_id": 1006996, + "conv_name": "api gateway xml", + "owner_id": 25130, + "owner_name": "Daria Grek", + "date": "-", + "opers": 38, + "tacts": 144, + "company_id": "i702619617", + "folder_id": 334308, + "traff": 0.03 + } + ] + } + ] + }, + "multitenant-show-request": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "sys_stat" + }, + "obj_type": { + "type": "string", + "enum": [ + "instance", + "company" + ], + "description": "Statistics type:
`instance` — counter of users, companies, processes for all tenant companies
`company` — counter of operations, tacts, traffic for one of tenant companies
if parameter not send, method returns statistics of processes for one of the tenant companies" + }, + "start": { + "type": "integer", + "description": "The start date of the report (timestamp)" + }, + "end": { + "type": "integer", + "description": "The end date of the report (timestamp)" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "order_field": { + "type": "string", + "enum": [ + "tacts", + "opers", + "traff" + ], + "description": "A metric to order the report results:
`tacts` — A number of state changes (maximum number of transitions between the nodes)
`opers` — A number of tasks processed by Process or State diagram
`traff` — A value of traffic (in MB) processed by Process or State diagram" + }, + "order_by": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ], + "description": "this parameter is used for sorting result data:
`ASC` — in ascending order;
`DESC` — in descending order." + }, + "limit": { + "type": "integer", + "minLength": 1, + "maxLength": 100, + "description": "A number of max results in report" + }, + "offset": { + "type": "integer", + "minLength": 0, + "maxLength": 20000, + "description": "Specifies an number of elements to skip in the query results." + }, + "interval": { + "type": "string", + "enum": [ + "minute", + "hour", + "day", + "month" + ], + "description": "An interval type (dimension) to group statistics." + } + } + }, + "multitenant-show-response": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "sys_stat" + }, + "obj_type": { + "type": "string", + "enum": [ + "instance", + "company", + "process" + ], + "description": "Statistics type" + }, + "data": { + "type": "array", + "description": "The list of report data", + "items": { + "type": "object", + "properties": { + "companies": { + "type": "integer", + "description": "Total counter of companies for all tenant companies
this response parameter is present only if the request parameter 'obj_type' = \"instance\"" + }, + "users": { + "type": "integer", + "description": "Total counter of users for all tenant companies
this response parameter is present only if the request parameter 'obj_type' = \"instance\"" + }, + "processes": { + "type": "integer", + "description": "Total counter of processes for all tenant companies
this response parameter is present only if the request parameter 'obj_type' = \"instance\"" + }, + "owner_id": { + "type": "integer", + "description": "Process owner ID
this response parameter is present only if the request parameter 'obj_type' = \"process\"" + }, + "owner_name": { + "type": "string", + "description": "Process owner name
this response parameter is present only if the request parameter 'obj_type' = \"process\"" + }, + "conv_id": { + "type": "integer", + "description": "Process ID
this response parameter is present only if the request parameter 'obj_type' = \"process\"" + }, + "conv_name": { + "type": "string", + "description": "Process name
this response parameter is present only if the request parameter 'obj_type' = \"process\"" + }, + "folder_id": { + "type": "integer", + "description": "ID of the Folder where Process / State diagram is stored
this response parameter is present only if the request parameter 'obj_type' = \"process\"" + }, + "company_id": { + "type": "string", + "description": "Company ID
this response parameter is present only if the request parameter 'obj_type' = \"process\" | \"company\"" + }, + "company_name": { + "type": "string", + "description": "Company name
this response parameter is present only if the request parameter 'obj_type' = \"company\"" + }, + "date": { + "type": "string", + "description": "The value of the requested dimension (timestamp) is converted to a date in string format
this response parameter is present only if the request parameter 'obj_type' = \"process\" | \"company\"", + "pattern": "YYYY-MM-DD HH:MM:SS" + }, + "opers": { + "type": "integer", + "description": "A number of tasks processed by Process or State diagram
this response parameter is present only if the request parameter 'obj_type' = \"process\" | \"company\"" + }, + "tacts": { + "type": "integer", + "description": "A number of state changes (maximum number of transitions between the nodes)
this response parameter is present only if the request parameter 'obj_type' = \"process\" | \"company\"" + }, + "traff": { + "type": "integer", + "description": "A value of traffic (in MB) processed by Process or State diagram
this response parameter is present only if the request parameter 'obj_type' = \"process\" | \"company\"" + } + } + } + } + } + }, + "example-multitenant-show-request-company": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "obj_type": "company", + "interval": "hour", + "start": 1651006800, + "end": 1651052154, + "company_id": "i57013995063" + } + ] + }, + "example-multitenant-show-request-instance": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "obj_type": "instance" + } + ] + }, + "example-multitenant-show-request-process": { + "ops": [ + { + "type": "show", + "obj": "sys_stat", + "company_id": "i57013995063", + "order_by": "DESC", + "limit": 10, + "start": 1646085601, + "end": 1648760400, + "offset": 15, + "order_field": "opers" + } + ] + }, + "example-multitenant-show-response-company": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "company", + "data": [ + { + "company_id": "i57013995063", + "company_name": "test_my_owner", + "date": "2022-04-27 05:00:00", + "opers": 145, + "tacts": 468, + "traff": 0.05 + } + ] + } + ] + }, + "example-multitenant-show-response-instance": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "instance", + "data": { + "companies": 1506, + "users": 16369, + "processes": 300792 + } + } + ] + }, + "example-multitenant-show-response-process": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "sys_stat", + "obj_type": "process", + "data": [ + { + "conv_id": 581864, + "conv_name": "Logic_API_Copy_Create", + "owner_id": 6023, + "owner_name": "api_C", + "date": "-", + "opers": 9, + "tacts": 32, + "folder_id": 0, + "traff": 0 + } + ] + } + ] + }, + "create-request-14": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "login" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "invite" + }, + "login": { + "type": "string", + "maxLength": 100, + "minLength": 3, + "description": "An Email address of a User which you want to add to the Company" + }, + "login_type": { + "type": "string", + "description": "Login type. ", + "enum": [ + "corezoid", + "google" + ] + }, + "link_to_obj": { + "type": "string", + "description": "Type of an object shared with a created user", + "enum": [ + "group", + "project", + "stage", + "conv", + "folder", + "dashboard", + "instance" + ] + }, + "link_to_obj_id": { + "type": "integer", + "description": "Shared object ID" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "create-response-14": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "invite" + }, + "url": { + "type": "string", + "description": "An invitation URL that a user needs to use to accept the invitation. The parameter will be present in the response if there is no notification process in superadmin in the capi_user_notify_conv parameter." + } + } + }, + "delete-request-13": { + "type": "object", + "title": "delete", + "required": [ + "type", + "obj", + "obj_id", + "hash" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "invite" + }, + "hash": { + "type": "string", + "minLength": 40, + "maxLength": 128, + "description": "Part of the invitation URL" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "delete-response-13": { + "type": "object", + "title": "delete", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + } + } + }, + "example-create-request-13": { + "ops": [ + { + "type": "create", + "obj": "invite", + "login": "user.email@corezoid.com", + "login_type": "google", + "company_id": "i848211059", + "link_to_obj": "stage", + "link_to_obj_id": 316139, + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-create-response-13": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "invite", + "url": "https://admin-pre.corezoid.com/api/2/plugins/invite/e2368c32ddf73eecef8e17ece32f1c6dda2fff5", + "proc": "ok" + } + ] + }, + "example-delete-request-13": { + "ops": [ + { + "type": "delete", + "obj": "invite", + "hash": "fbd2d5365a124a77fe38f1673d0829196502b3df", + "company_id": "i702619617" + } + ] + }, + "example-delete-response-13": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + }, + "modify-request-13": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "obj_type", + "obj_id", + "obj_to_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "owner" + }, + "obj_type": { + "type": "string", + "description": "Type of an object ownership of which you want to change", + "enum": [ + "folder", + "conv", + "dashboard", + "instance", + "alias", + "config", + "project", + "stage", + "group" + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of an object ownership of which you want to change" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of a user that you want to make the owner of an object
Instead obj_to_id you can use obj_to_type + obj_to_login" + }, + "obj_to_type": { + "type": "string", + "description": "Login type of a user that you want to make the owner of an object
Instead obj_to_type + obj_to_login you can use obj_to_id" + }, + "obj_to_login": { + "type": "string", + "description": "Login of a user that you want to make the owner of an object
Instead obj_to_type + obj_to_login you can use obj_to_id", + "enum": [ + "ldap", + "google", + "facebook", + "api", + "oauth_pb", + "phone", + "corezoid", + "github" + ] + }, + "save_src_privs": { + "type": "boolean", + "description": "A flag that allows you to keep the current owner sharing settings for an object" + } + } + }, + "modify-response-13": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "owner" + }, + "owner_id": { + "type": "string", + "description": "ID of an object new owner user" + }, + "owner_login": { + "type": "string", + "description": "User login of a new owner of an object" + }, + "owner_name": { + "type": "string", + "description": "User name of a new owner of an object" + } + } + }, + "example-modify-request-id": { + "ops": [ + { + "type": "modify", + "obj": "owner", + "obj_type": "folder", + "obj_id": 370260, + "obj_to_id": 27608, + "save_src_privs": true + } + ] + }, + "example-modify-request-login": { + "ops": [ + { + "type": "modify", + "obj": "owner", + "obj_type": "folder", + "obj_id": 370260, + "obj_to_type": "google", + "obj_to_login": "email@gmail.com", + "save_src_privs": true + } + ] + }, + "example-modify-response-13": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "owner_id": 27608, + "owner_login": "email@gmail.com", + "owner_name": "Jane Doe" + } + ] + }, + "link-request-9": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "company_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user_to_company" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "integer", + "description": "ID of a user which you want to add to a company" + } + } + }, + "link-response-9": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user_to_company" + }, + "obj_id": { + "type": "string", + "description": "An ID of a user which was added to a company" + } + } + }, + "example-link-request-9": { + "ops": [ + { + "type": "link", + "obj": "user_to_company", + "obj_id": 11451, + "company_id": "i702619617" + } + ] + }, + "example-link-response-9": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "user_to_company", + "obj_id": 11451, + "proc": "ok" + } + ] + }, + "list-request-19": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv_params" + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "list-response-19": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv_params" + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "params": { + "type": "array", + "description": "An array with all task params, described as JSON", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Task parameter name" + }, + "type": { + "type": "string", + "description": "Task parameter type" + }, + "descr": { + "type": "string", + "description": "Task parameter description" + }, + "flags": { + "type": "array", + "description": "An array of task parameter settings. Possible values that mean the following:
`input` - This parameter is expected in the process Start node.
`output` - This parameter is expected as a process result.
`auto-clear` - The value of this parameter must be masked in a task archive.
`required` - The value of this parameter is mandatory (only for Input and Output parameters).
If the parameter has neither input nor output value in the flags array, then this task parameter is `local`." + }, + "regex": { + "type": "string", + "description": "A regular expression for a task parameter validation" + }, + "regex_error_text": { + "type": "string", + "description": "A response error text in case of regexp validation fail" + } + } + } + }, + "ref_mask": { + "type": "boolean", + "description": "Enable or disable task references masking" + } + } + }, + "modify-request-14": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id", + "params" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv_params" + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "params": { + "type": "array", + "description": "An array with all task params described as JSON", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "required": true, + "description": "Task parameter name" + }, + "type": { + "type": "string", + "required": true, + "description": "Task parameter type" + }, + "descr": { + "type": "string", + "required": true, + "description": "Task parameter description" + }, + "flags": { + "type": "array", + "required": true, + "description": "An array of task parameter settings. Possible values that mean the following:
`input` - This parameter is expected in the process Start node.
`output` - Tthis parameter is expected as a process result.
`auto-clear` - This parameter value must be masked in a task archive.
`required` - The value of this parameter is mandatory (only for Input and Output parameters).
To set the `local` type for a task parameter, pass neither input nor output value to the parameter flags array." + }, + "regex": { + "type": "string", + "required": true, + "description": "A regular expression for a task parameter validation" + }, + "regex_error_text": { + "type": "string", + "required": true, + "description": "A response error text in case of regexp validation fail" + } + } + } + }, + "ref_mask": { + "type": "boolean", + "description": "Enable or disable tasks reference masking" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "modify-response-14": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv_params" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + } + } + }, + "example-list-request-19": { + "ops": [ + { + "type": "list", + "obj": "conv_params", + "obj_id": 926490, + "company_id": "i702619617" + } + ] + }, + "example-list-response-17": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_params", + "obj_id": 926490, + "params": [ + { + "name": "one", + "type": "string", + "descr": "", + "flags": [ + "required", + "input" + ], + "regex": "", + "regex_error_text": "" + } + ], + "ref_mask": true + } + ] + }, + "example-modify-request-13": { + "ops": [ + { + "type": "modify", + "obj": "conv_params", + "obj_id": 926490, + "params": [ + { + "name": "one", + "type": "string", + "descr": "", + "flags": [ + "required", + "output" + ], + "regex": "", + "regex_error_text": "" + } + ], + "company_id": "i702619617" + } + ] + }, + "example-modify-response-14": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_params", + "conv_id": 926490 + } + ] + }, + "list-request-objects": { + "type": "object", + "required": [ + "type", + "obj", + "limit", + "offset", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "history" + }, + "limit": { + "type": "integer", + "minLength": 1, + "maxLength": 100, + "description": "Specifies the number of history records to return" + }, + "offset": { + "type": "string", + "minLength": 0, + "maxLength": 20000, + "description": "Specifies the number of elements to skip in the query results." + }, + "obj_id": { + "type": "integer", + "description": "Object identifier
required for objects history" + }, + "obj_type": { + "type": "string", + "description": "Type of object
required for objects history", + "enum": [ + "conv", + "folder", + "alias", + "dashboard", + "stage", + "project", + "instance", + "version" + ] + } + } + }, + "list-response-objects": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "history" + }, + "obj_id": { + "type": "integer", + "description": "Object identifier" + }, + "obj_type": { + "type": "integer", + "description": "Object type" + }, + "list": { + "type": "array", + "description": "List of history records (operations on an object)", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "History record identifier" + }, + "create_time": { + "type": "timestamp", + "description": "Timestamp of a history record creation" + }, + "user_id": { + "type": "integer", + "description": "Identifier of a user which performed the action" + }, + "user_name": { + "type": "string", + "description": "Name of a user which performed the action" + }, + "company_id": { + "type": "string", + "description": "Company identifier. If the request is sent for \"My Corezoid\", the 'company_id' can be null." + }, + "obj": { + "type": "string", + "description": "The \"obj\" field value in an API request" + }, + "type": { + "type": "string", + "description": "The \"type\" field value in an API request" + }, + "request": { + "type": "object", + "description": "API request" + }, + "response": { + "type": "object", + "description": "API response" + }, + "severity": { + "type": "string", + "description": "Logging type", + "enum": [ + "INFO", + "WARN", + "ERROR" + ] + } + } + } + } + } + }, + "list-request-operations": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "history" + }, + "limit": { + "type": "string", + "minLength": 1, + "maxLength": 100, + "description": "Specifies the number of history records to return" + }, + "offset": { + "type": "string", + "minLength": 0, + "maxLength": 20000, + "description": "Specifies the number of elements to skip in the query results." + }, + "start": { + "type": "timestamp", + "description": "The start date of the operations history " + }, + "end": { + "type": "timestamp", + "description": "The end date of the operations history " + }, + "list_type": { + "type": "string", + "description": "Action filter in operations history", + "enum": [ + "create", + "delete", + "link" + ] + }, + "list_obj": { + "type": "string", + "description": "Object filter in operations history", + "enum": [ + "conv", + "folder", + "dashboard", + "stage", + "project", + "instance", + "version", + "user", + "group" + ] + }, + "user_id": { + "type": "string", + "description": "Filter by user ID
works only with the company_id parameter" + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Filter by company ID
works for operations history" + } + } + }, + "list-response-operations": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "history" + }, + "list": { + "type": "array", + "description": "List of history records (operations on objects)", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "History record identifier" + }, + "create_time": { + "type": "timestamp", + "description": "Timestamp of a history record creation" + }, + "user_id": { + "type": "integer", + "description": "Identifier of a user which performed the action" + }, + "user_name": { + "type": "string", + "description": "Name of a user which performed the action" + }, + "login": { + "type": "string", + "description": "Login of a user which performed the action" + }, + "company_id": { + "type": "string", + "description": "Company identifier. If the request is sent for \"My Corezoid\", the 'company_id' can be null." + }, + "obj": { + "type": "string", + "description": "The \"obj\" field value in an API request" + }, + "type": { + "type": "string", + "description": "The \"type\" field value in an API request" + }, + "obj_type": { + "type": "string", + "description": "Converted value of the obj_type field in an API request" + }, + "obj_id": { + "type": "integer", + "description": "Object identifier" + }, + "obj_name": { + "type": "string", + "description": "Object name" + }, + "obj_to": { + "type": "string", + "description": "Linked object type" + }, + "obj_to_id": { + "type": "integer", + "description": "Linked object identifier" + }, + "obj_to_name": { + "type": "string", + "description": "Linked object name" + }, + "request": { + "type": "object", + "description": "API request" + }, + "response": { + "type": "object", + "description": "API response" + } + } + } + } + } + }, + "example-list-request-objects": { + "ops": [ + { + "type": "list", + "obj": "history", + "obj_id": 1069599, + "obj_type": "conv", + "limit": 10, + "offset": 0 + } + ] + }, + "example-list-request-operations": { + "ops": [ + { + "type": "list", + "obj": "history", + "company_id": "i702619617", + "user_id": 25130, + "list_type": "create", + "list_obj": "folder", + "start": 1666773971, + "end": 1666906264, + "limit": 10, + "offset": 0 + } + ] + }, + "example-list-response-objects": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "history", + "obj_id": 1169599, + "obj_type": "conv", + "list": [ + { + "id": 47202572, + "create_time": 1666855109, + "user_id": 80089, + "user_name": "Jane Doe", + "company_id": "i790933068", + "obj": "node", + "type": "delete", + "request": {}, + "response": {}, + "severity": "INFO" + } + ] + } + ] + }, + "example-list-response-operations": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "history", + "list": [ + { + "id": 35107234, + "create_time": 1666787733, + "user_id": 25130, + "user_name": "Jane Doe", + "login": "email@email.com", + "company_id": "i702619617", + "obj": "folder", + "type": "create", + "obj_type": "folder", + "obj_id": 372757, + "obj_name": "folderinka", + "obj_to": null, + "obj_to_id": null, + "obj_to_name": null, + "request": {}, + "response": {} + } + ] + } + ] + }, + "show-request-14": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "conv_id", + "start", + "end", + "group", + "interval" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "stat" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID (if a node is used in any dashboard)" + }, + "node_id": { + "type": "integer", + "minLength": 24, + "maxLength": 24, + "description": "Node ID - for getting one node statistics" + }, + "node_ids": { + "type": "array", + "description": "Filter specific nodes for a group = all" + }, + "group": { + "type": "string", + "description": "Statistic type
`all` - for getting statistics for all process nodes without the date parameter, you can use the additional node_ids optional parameter and filter specific nodes
`time` - for getting statistics for one node with the date parameter, the node_id parameter becomes required", + "enum": [ + "all", + "time" + ] + }, + "interval": { + "type": "string", + "description": "An interval type (dimension) to group statistics.", + "enum": [ + "minute", + "hour", + "day" + ] + }, + "start": { + "type": "timestamp", + "description": "The start date of a report (timestamp)" + }, + "end": { + "type": "timestamp", + "description": "The end date of a report (timestamp)" + }, + "timezone_offset": { + "type": "integer", + "description": "Statistical report offset considering a time zone" + }, + "timestamp": { + "type": "boolean", + "default": false, + "description": "flag to display a date in timestamp format
`true` - timestamp format
`false` - date format" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "show-response-15": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "stat" + }, + "group": { + "type": "string", + "description": "Statistics type" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "dashboard_id": { + "type": "string", + "description": "Dashboard ID" + }, + "data": { + "type": "array", + "description": "Array of counters for tasks movement through nodes", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "Node ID
the parameter will only be shown for group = all" + }, + "title": { + "type": "string", + "description": "Node title
the parameter will only be shown for group = all" + }, + "date": { + "type": "string", + "description": "Date or timestamp value
the parameter will only be shown for group = time" + }, + "in": { + "type": "integer", + "description": "The number of tasks received by a node" + }, + "out": { + "type": "integer", + "description": "The number of tasks that left a node" + } + } + } + } + } + }, + "example-show-request-onenode": { + "ops": [ + { + "node_id": "633d595456167c2a190000f6", + "start": 1666904400, + "end": 1666990799, + "interval": "hour", + "type": "show", + "obj": "stat", + "group": "time", + "company_id": "i702619617", + "conv_id": 973630, + "timestamp": false, + "timezone_offset": -180 + } + ] + }, + "example-show-response-onenode": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stat", + "node_id": "633d595456167c2a190000f6", + "title": "Final", + "group": "time", + "conv_id": 973630, + "dashboard_id": "undefined", + "data": [ + { + "date": "2022-10-28 11:00:00", + "in": 3, + "out": 0 + } + ] + } + ] + }, + "example-show-request-allnodes": { + "ops": [ + { + "type": "show", + "obj": "stat", + "start": 1666773971, + "end": 1666956330, + "group": "all", + "interval": "minute", + "conv_id": 973630, + "node_ids": [ + "633d595456167c2a190000f6" + ] + } + ] + }, + "example-show-response-allnodes": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "stat", + "group": "all", + "conv_id": 973630, + "dashboard_id": "undefined", + "data": [ + { + "id": "633d595456167c2a190000f6", + "title": "Final", + "in": 4, + "out": 0 + } + ] + } + ] + }, + "list-request-20": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "conv_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task_history" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_id": { + "type": "integer", + "description": "Task identifier" + }, + "limit": { + "type": "string", + "minLength": 1, + "maxLength": 100, + "description": "Specifies the number of history records to return" + }, + "offset": { + "type": "string", + "minLength": 0, + "maxLength": 100, + "description": "Specifies the number of elements to skip in the query results." + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "list-response-20": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "task_history" + }, + "obj_id": { + "type": "string", + "description": "Task identifier" + }, + "ref": { + "type": "string", + "description": "Task external identifier" + }, + "list": { + "type": "array", + "description": "Array of history of a task movement through process nodes", + "items": { + "type": "object", + "properties": { + "history_id": { + "type": "integer", + "description": "Identifier of a history record" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "node_id": { + "type": "string", + "description": "Node ID" + }, + "node_prev_id": { + "type": "string", + "description": "ID of a Node which the Task passed previously" + }, + "user_id": { + "type": "integer", + "description": "Identifier of a user which created the Task" + }, + "user_name": { + "type": "string", + "description": "Name of a user which created the Task" + }, + "create_time_ms": { + "type": "integer", + "description": "Timestamp of a moment the Task gone to a node" + }, + "status": { + "type": "string", + "description": "Task status", + "enum": [ + "created", + "processing", + "delayed", + "processed", + "canceled", + "deleted" + ] + }, + "data": { + "type": "object", + "description": "Task data" + } + } + } + } + } + }, + "example-list-request-20": { + "ops": [ + { + "type": "list", + "obj": "task_history", + "conv_id": "973630", + "obj_id": "635fbae9094bab1444007eac" + } + ] + }, + "example-list-response-18": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": "635fbae9094bab1444007eac", + "ref": "166721815235789", + "list": [ + { + "history_id": 8212422009, + "conv_id": 973630, + "node_id": "633d595456167c2a190000f5", + "node_prev_id": null, + "user_id": 25130, + "user_name": "Jane Doe", + "create_time_ms": 1667218153555, + "status": "created", + "data": null + } + ] + } + ] + }, + "confirm-request": { + "type": "object", + "title": "confirm", + "required": [ + "type", + "obj", + "version", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "commit" + }, + "version": { + "type": "integer", + "description": "Process/State Diagram version" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID Instead conv_id, you can use obj_id + obj_type." + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID
Instead obj_id + obj_type, you can use conv_id." + }, + "obj_type": { + "type": "string", + "description": "Process/State Diagram type
Instead obj_id + obj_type, you can use conv_id.", + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "confirm-response": { + "type": "object", + "title": "confirm", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "commit" + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_type": { + "type": "string", + "description": "Process/State Diagram type", + "default": "conv" + }, + "version": { + "type": "integer", + "description": "Process/State Diagram version" + } + } + }, + "show-request-15": { + "type": "object", + "title": "confirm", + "required": [ + "type", + "obj", + "version", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "commit" + }, + "version": { + "type": "integer", + "description": "Process/State Diagram version" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID Instead of the conv_id, you can use the obj_id + obj_type." + }, + "obj_id": { + "type": "integer", + "description": "Process/State Diagram ID
Instead of obj_id + obj_type you can use the conv_id" + }, + "obj_type": { + "type": "string", + "description": "Process/State Diagram type
Instead of obj_id + obj_type, you can use the conv_id.", + "default": "conv" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + } + } + }, + "show-response-16": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "commit" + }, + "list": { + "type": "array", + "description": "List of process changes which included in the commit.", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "description": "Node ID" + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — Normal - logic node
`1` — Start node
`2` — Final node
`3` — Escalation - special system node
" + }, + "title": { + "type": "string", + "description": "Node title" + }, + "description": { + "type": "string", + "description": "Node description" + }, + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + }, + "position": { + "type": "array", + "description": "[ position_X, position_Y ] — Coordinates of a node's upper-left corner along the X / Y axis with respect to the 0:0 reference point in the process field coordinates
position_X, position_Y — integer values
example: [ 560, 100 ]
" + }, + "extra": { + "type": "object", + "description": "A stringify object of additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view)
icon — Icon for the final node success (green) / error (red)
For all the other nodes - \"icon\":\"\"
example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"" + }, + "status": { + "type": "integer", + "enum": [ + 1, + 3 + ], + "description": "Node status:
`1` — Active
`3` — Deleted" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "user_id": { + "type": "integer", + "description": "User identifier" + }, + "create_time": { + "type": "timestamp", + "description": "Timestamp of version creation" + } + } + } + } + } + }, + "delete-request-14": { + "type": "object", + "title": "confirm", + "required": [ + "type", + "obj", + "version", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "commit" + }, + "version": { + "type": "integer", + "description": "Process/State Diagram version" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID
Instead of conv_id, you can use the obj_id + obj_type." + }, + "obj_id": { + "type": "integer", + "description": "Object ID
For deleting processes commits in an object, use the method with the obj_type parameter." + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "project", + "stage" + ] + } + } + }, + "delete-response-14": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "commit" + }, + "obj_id": { + "type": "integer", + "description": "Identifier of an object, in which process commits were deleted." + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "project", + "stage" + ] + }, + "version": { + "type": "integer", + "description": "Deleted Process/State Diagram version" + } + } + }, + "example-confirm-request": { + "ops": [ + { + "type": "confirm", + "obj": "commit", + "conv_id": 973630, + "company_id": "i702619617", + "version": 1667230068 + } + ] + }, + "example-confirm-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068 + } + ] + }, + "example-show-request-14": { + "ops": [ + { + "type": "show", + "obj": "commit", + "obj_id": 1004849, + "obj_type": "conv", + "company_id": "i702619617", + "version": 1667294065 + } + ] + }, + "example-show-response-13": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "commit", + "list": [ + { + "obj_id": "6360dec1094bab1444009ae1", + "obj_type": 0, + "title": "", + "description": "", + "logics": [ + { + "type": "api_queue", + "data": {}, + "data_type": {} + }, + { + "type": "go", + "to_node_id": "6360deb756167c5cce009747" + } + ], + "semaphors": [], + "position": [ + 352, + 220 + ], + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "status": 1, + "conv_id": 1004849, + "user_id": 25130, + "create_time": 1667294602 + } + ] + } + ] + }, + "example-delete-request-14": { + "ops": [ + { + "obj": "commit", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068, + "type": "delete" + } + ] + }, + "example-delete-response-14": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj_id": 973630, + "obj_type": "conv", + "version": 1667230068 + } + ] + }, + "list-request-21": { + "type": "object", + "title": "confirm", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "commits" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID
For getting a list of process commits" + }, + "obj_id": { + "type": "integer", + "description": "Object ID
For getting a list of processes commits for an object, use the method with the obj_type parameter." + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "project", + "stage" + ] + } + } + }, + "list-response-21": { + "type": "object", + "title": "confirm", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "commits" + }, + "list": { + "type": "array", + "description": "List of commits", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "version": { + "type": "integer", + "description": "Process/State Diagram version" + }, + "create_time": { + "type": "integer", + "description": "Commit timestamp", + "default": "conv" + }, + "user_id": { + "type": "integer", + "description": "User identifier" + } + } + } + } + } + }, + "example-list-request-21": { + "ops": [ + { + "obj": "commits", + "conv_id": 1004227, + "type": "list" + } + ] + }, + "example-list-response-19": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "commits", + "list": [ + { + "conv_id": 1004227, + "version": 1667220502, + "create_time": 1667220556, + "user_id": 25130 + } + ] + } + ] + }, + "create-request-15": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "obj_to_id", + "obj_to_type", + "folder_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Asynchronous request execution method" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Project | Stage | Alias short name" + }, + "scheme": { + "type": "string", + "format": "binary", + "description": "File containing the scheme of objects that will be uploaded
this request parameter is required when the 'scheme_id' request parameter is not present (one of them must be defined)" + }, + "scheme_id": { + "type": "string", + "description": "Scheme ID
this request parameter is required when the 'scheme' request parameter is not present (one of them must be defined)" + }, + "skip_root": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "If obj_to_type = stage or project, skip_root have to be = true - upload will complete without root folder" + }, + "with_alias": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "Defines whether an object is uploaded with its available Aliases.
Used for 'obj_type' = \"conv\" | \"folder\".
When not specified, the object is uploaded without its Aliases." + }, + "rewrite_alias": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Defines whether an existing alias is to be rewritten during the import" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "apply_mode": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "deprecated": true, + "description": "Mode:
`true` — upload file to system;
`false` — get file hash" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of an Object to which a file will be uploaded:
`0` for a root folder or ID of an existing Project, Stage or Folder
If the 'obj_to_id' is sent in the request, the 'obj_to_type' must be sent too;
this request parameter is required when the 'folder_id' request parameter is not present (one of them must be defined)" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "project", + "stage", + "folder" + ], + "description": "Type of an object to which the file will be uploaded
this request parameter is required when the 'obj_to_id' request parameter is present" + }, + "folder_id": { + "type": "integer", + "default": 0, + "description": "Folder ID to which the file will be uploaded
this request parameter is required when the 'obj_to_id' request parameter is not present (one of them must be defined)" + } + } + }, + "create-response-15": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_scheme" + }, + "hash": { + "type": "string", + "description": "File hash, can be used to get the [progress status](#tag/upload_info) of the upload
this response parameter is present when the request parameter 'async' = \"true\"" + }, + "scheme": { + "type": "array", + "description": "this response parameter is present when the request parameter 'async' = \"false\"", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "New (uploaded) Object ID" + }, + "obj_type": { + "type": "string", + "description": "New (uploaded) Object type:
`project` — Project
`stage` — Stage
`version` — Version
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance" + }, + "title": { + "type": "string", + "description": "New (uploaded) Object title" + }, + "description": { + "type": "string", + "description": "New (uploaded) Object description" + }, + "old_obj_id": { + "type": "integer", + "description": "Old (downloaded) Object ID" + }, + "old_parent_id": { + "type": "integer", + "description": "Old (downloaded) Object's Parent Folder ID / Stage ID" + } + } + } + } + } + }, + "validate-request": { + "type": "object", + "title": "validate", + "required": [ + "type", + "obj", + "obj_to_id", + "obj_to_type", + "folder_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "validate" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "scheme": { + "type": "string", + "description": "Name of a file that contains a scheme of objects that will be uploaded" + }, + "with_alias": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "Defines whether the object is uploaded with its available Aliases.
Used for 'obj_type' = \"conv\" | \"folder\".
When not specified, the object is uploaded without its Aliases." + }, + "rewrite_alias": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Defines whether an existing alias is to be rewritten during the import" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "apply_mode": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "deprecated": true, + "description": "Mode:
`true` — upload file to system;
`false` — get file hash" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of the Object to which the file will be uploaded:
`0` for a root folder or an ID of an existing Project, Stage or Folder
If the 'obj_to_id' is sent in the request, 'obj_to_type' must be sent too;
this request parameter is required when the 'folder_id' request parameter is not present (one of them must be defined)" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "project", + "stage", + "folder" + ], + "description": "Type of an object to which the file will be uploaded
this request parameter is required when the 'obj_to_id' request parameter is present" + }, + "folder_id": { + "type": "integer", + "default": 0, + "description": "Folder ID to which the file will be uploaded
this request parameter is required when the 'obj_to_id' request parameter is not present (one of them must be defined)" + } + } + }, + "validate-response": { + "type": "object", + "title": "validate", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_scheme" + } + } + }, + "example-create-request-14": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'apply_mode=true' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false' \\\n--form 'async=true'\n", + "example-create-response-14": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C6397317356167C75FC000808" + } + ] + }, + "example-create_async_false-request": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'apply_mode=true' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false' \\\n--form 'async=false'\n", + "example-create_async_false-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "scheme": [ + { + "obj_id": 1043733, + "obj_type": "conv", + "title": "New object44", + "description": "", + "old_obj_id": 887890, + "old_parent_id": 268661 + } + ] + } + ] + }, + "example-validate-request": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=validate' \\\n--form 'obj=obj_scheme' \\\n--form 'scheme=conv_887890_1670603649031.zip' \\\n--form 'company_id=i848211059' \\\n--form 'obj_to_id=371951' \\\n--form 'obj_to_type=stage' \\\n--form 'with_alias=true' \\\n--form 'rewrite_alias=false'\n", + "example-validate-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok" + } + ] + }, + "download-request": { + "type": "object", + "title": "download", + "required": [ + "obj", + "obj_id", + "obj_type", + "async" + ], + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "obj_id": { + "type": "integer", + "description": "ID of the Object that we download to a zip file (obj_scheme)" + }, + "obj_type": { + "type": "string", + "enum": [ + "project", + "stage", + "version", + "folder", + "conv", + "dashboard", + "instance" + ], + "description": "Type of the object that we download to a zip file (obj_scheme):
`project` — Project
`stage` — Stage
`version` — Version
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance" + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Asynchronous request execution method" + }, + "company_id": { + "type": "string", + "description": "ID of an existing Company.
Required for all requests within a Company.
If the request is sent for \"My Corezoid\", the 'company_id' is not required or can be null." + }, + "with_alias": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "Defines whether the object is to be downloaded with its available Aliases.
When not specified, the object is downloaded with its Aliases." + }, + "format": { + "type": "string", + "default": "zip", + "enum": [ + "zip", + "json" + ], + "description": "Download file format;
json format is not allowed when the request parameter 'obj_type' = \"project\" | \"stage\" | \"version\"" + }, + "with_api_gateway": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "not implemented in API yet
this request parameter is allowed when the request parameter 'obj_type' = \"project\" | \"stage\" | \"version\"" + } + } + }, + "download-response": { + "type": "object", + "title": "download", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_scheme" + }, + "download_url": { + "type": "string", + "description": "URL for the file download" + }, + "statistics_id": { + "type": "string", + "description": "Statistics ID, can be used to get the progress status of the download" + } + } + }, + "example-download-request": { + "ops": [ + { + "obj": "obj_scheme", + "obj_id": 1045470, + "obj_type": "conv", + "company_id": "i848211059", + "with_alias": true, + "async": true, + "format": "zip" + } + ] + }, + "example-download-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "download_url": "https://pre.corezoid.com/user_downloads/conv_1045470_1672282741904.zip", + "statistics_id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C63AD027556167C6644000001" + } + ] + }, + "compare-request": { + "type": "object", + "title": "compare", + "required": [ + "obj", + "obj_id", + "obj_type", + "obj_to_id", + "obj_to_type", + "company_id" + ], + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "obj_id": { + "type": [ + "integer", + "string" + ], + "description": "ID of the target Object — type integer
(when the request parameter 'obj_type' != \"scheme\")

Target Object — type string
(when the request parameter 'obj_type' = \"scheme\")" + }, + "obj_type": { + "type": "string", + "enum": [ + "stage", + "version", + "scheme" + ], + "description": "Type of the target object:
`stage` — Stage
`version` — saved Version of a Stage
`scheme` — for uploading a Stage from a zip file" + }, + "obj_to_id": { + "type": [ + "integer", + "string" + ], + "description": "ID of the source Object — type integer
(when the request parameter 'obj_to_type' != \"scheme\")

Source Object — type string
(when the request parameter 'obj_to_type' = \"scheme\")" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "stage", + "version", + "scheme" + ], + "description": "Type of the source object:
`stage` — Stage
`version` — saved Version of a Stage
`scheme` — for uploading a Stage from a zip file" + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "nullable": true, + "description": "ID of an existing Company.
", + "example": "i791331829" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "num_stat": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Get a count of Objects that were added, changed, or deleted" + }, + "diff_status": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Get a compare status of an Object" + } + } + }, + "part": { + "properties": { + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 8, + 9 + ], + "description": "Object type:
`0` — Folder
`1` — Process / State diagram
`2` — Dashboard
`8` — Database instance
`9` — Alias" + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "parent_id": { + "type": "integer", + "description": "Parent Folder ID / Stage ID" + }, + "title": { + "type": "string", + "description": "Object title" + }, + "description": { + "type": "string", + "description": "Object description" + }, + "lists": { + "type": "array", + "description": "Dashboard nodes
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\"" + }, + "charts_order": { + "type": "array", + "description": "Dashboard charts order
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\"" + }, + "grid": { + "type": "array", + "description": "Dashboard nodes position
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\"", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node Identifier" + }, + "x": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the X axis with respect to the 0:0 reference point in the process field coordinates" + }, + "y": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the Y axis with respect to the 0:0 reference point in the process field coordinates" + }, + "width": { + "type": "integer", + "description": "node width" + }, + "height": { + "type": "integer", + "description": "node height" + } + } + } + }, + "time_range": { + "type": "object", + "description": "Dashboard time range
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\"", + "properties": { + "timezone_offset": { + "type": "integer", + "description": "Timezone Offset, the difference in minutes between UTC and local time" + }, + "select": { + "type": "string", + "enum": [ + "online", + "fromTo", + "last10minute", + "today", + "lastHour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month" + ], + "description": "Display date-time range:
`online` — Real-Time
`fromTo` — Custom Range
`last10minute` — Last 10 minutes
`today` — Today
`lastHour` — Last hour
`last24hour` — Last 24 hours
`lastWeek` — Last 7 days
`lastMonth` — Last 30 days
`previous_hour` — Previous hour
`previous_day` — Previous day
`previous_week` — Previous week
`previous_month` — Previous month" + } + } + }, + "charts_list": { + "type": "array", + "description": "An array of Charts on the Dashboard
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\"", + "items": { + "type": "object", + "properties": { + "chart_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart Identifier" + }, + "series": { + "type": "array", + "description": "An array of Nodes which statistics you want to display", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "ID of a Process or a State diagram where the Node is stored" + }, + "node_id": { + "type": "string", + "description": "ID of a Node used for the Dashboard metric" + }, + "title": { + "type": "integer", + "description": "Title of a Node which is described in the Chart legend" + }, + "type_icon": { + "type": "string", + "description": "Node icon type" + }, + "type_title": { + "type": "integer", + "description": "Node type title" + }, + "type": { + "type": "string", + "description": "Node type" + } + } + } + }, + "name": { + "type": "string", + "description": "Chart Name" + }, + "settings": { + "nullable": true, + "description": "Chart settings" + }, + "description": { + "type": "string", + "description": "Chart description" + }, + "obj_type": { + "type": "string", + "enum": [ + "table", + "column", + "pie", + "funnel" + ], + "description": "Chart type:
`table` — Table chart
`column` — Bar chart
`pie` — Pie chart
`funnel` — Funnel chart" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: 2a4c797e-5e24-42e9-b950-163c9ca0fd82" + } + } + } + }, + "obj_to_type": { + "type": "string", + "nullable": true, + "enum": [ + "conv", + "dashboard" + ], + "description": "Type of an object for which an Alias was created/changed/deleted
this response parameter is present when the response parameter 'obj_type' = \"alias\"" + }, + "obj_to_title": { + "type": "string", + "description": "Title of an object for which we created/changed/deleted an Alias
this response parameter is present when the response parameter 'obj_type' = \"alias\"" + }, + "obj_to_id": { + "type": "integer", + "nullable": true, + "description": "An object (Process / State diagram / Dashboard) ID, for that we are created/changed/deleted Alias
this response parameter is present when the response parameter 'obj_type' = \"alias\"" + }, + "instance_type": { + "type": "string", + "enum": [ + "db_call" + ], + "description": "Instance type
this response parameter is present when the response parameter 'obj_type' = \"instance\"" + }, + "status": { + "type": [ + "string", + "integer" + ], + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug", + "active_debug", + "transient", + 1 + ], + "description": "Object status:
string type — when the response parameter 'obj_type' = \"conv\"
integer type — when the response parameter 'obj_type' = \"instance\" or 'conv_type' = \"state\"" + }, + "data": { + "type": "object", + "description": "Database instance parameters
this response parameter is present when the response parameter 'obj_type' = \"instance\"", + "properties": { + "driver": { + "type": "string", + "enum": [ + "postgres", + "oracle", + "mongo", + "mysql", + "mssql" + ], + "description": "Database type:
`postgres` — Postgresql
`oracle` — Oracle
`mongo` — MongoDB
`mysql` — MySQL
`mssql` — MSSQL" + }, + "host": { + "type": "string", + "description": "Database Host" + }, + "port": { + "type": "integer", + "description": "Database port, default:
Postgresql — 5432
Oracle — 1521
MongoDB — 27017
MySQL — 3306
MSSQL — 1433" + }, + "username": { + "type": "string", + "description": "Database username" + }, + "password": { + "type": "string", + "description": "Database Password" + }, + "database": { + "type": "string", + "description": "Database Name" + }, + "timeoutMs": { + "type": "integer", + "description": "Timeout, ms" + }, + "ssl": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Enable SSL" + } + } + }, + "params": { + "type": "array", + "description": "can be `[]` empty array
this response parameter is present when the response parameter 'obj_type' = \"conv\"" + }, + "ref_mask": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Enables and disables the masking (displayed as \"***\") of values of parameters and task references which consist of a set of digits and have the format similar to the format of:
bank account / card number or CVV code
this response parameter is present when the response parameter 'obj_type' = \"conv\"" + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state" + ], + "description": "Type of an Object:
`process` — Process
`state` — State diagram
this response parameter is present when the response parameter 'obj_type' = \"conv\"" + }, + "scheme": { + "type": "object", + "properties": { + "nodes": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node Identifier" + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node
`2` — final node
`3` — escalation - special system node" + }, + "conditions": { + "type": "object", + "properties": { + "logics": { + "allOf": [ + { + "$ref": "../props/logics.yaml" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "../props/semaphors.yaml" + } + ] + } + } + }, + "title": { + "type": "string", + "description": "Node Title" + }, + "description": { + "type": "string", + "description": "Node description" + }, + "x": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the X axis with respect to the 0:0 reference point in the process field coordinates" + }, + "y": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the Y axis with respect to the 0:0 reference point in the process field coordinates" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: 32bac6d3-625e-4001-8aa5-8525b94df55a" + }, + "extra": { + "type": "string with JSON", + "description": "A stringify object of additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view);
icon — Icon for the success (green) / error (red) final node. For all the other nodes - \"icon\":\"\".

example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"" + }, + "options": { + "type": "string with JSON", + "description": "A stringify object of the save_task additional node setting;

example: \"{\\\\\"save_task\\\\\":true}\"" + } + } + } + }, + "web_settings": { + "type": "array", + "deprecated": true + } + } + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: 32bac6d3-625e-4001-8aa5-8525b94df55a" + } + } + }, + "logics-obj_scheme_compare": { + "description": "logics value can be an `[]` empty array;
An array of node settings
", + "type": "array", + "items": { + "type": "object", + "properties": { + "__added": { + "type": "object", + "description": "Node logics parameters/properties that were added." + }, + "__deleted": { + "type": "object", + "description": "Node logics parameters/properties that were deleted." + }, + "__changed": { + "type": "object", + "description": "Node logics parameters/properties that were changed." + }, + "type": { + "type": "string", + "enum": [ + "go", + "go_if_const", + "set_param", + "api", + "api_callback", + "api_sum", + "api_code", + "api_copy", + "api_rpc", + "api_rpc_reply", + "api_queue", + "api_get_task", + "api_form", + "git_call", + "db_call" + ], + "description": "Node type:
`go` — Start node (when only this logic type object exists in a logics array)
`go_if_const` — Condition node or an optional part of the Set State node
`set_param` — Set Parameters node
`api` — API Call node
`api_callback` — (when 'conv_type' = \"state\") — Set State node (State Diagram); this node also can have the go_if_const logic (optional)
`api_callback` — (when 'conv_type' = \"process\") — Waiting for Callback node
`api_sum` — Sum node
`api_code` — Code node
`api_copy` — Copy Task node (when 'mode' = \"create\")
`api_copy` — Modify Task node (when 'mode' = \"modify\")
`api_rpc` — Call a Process node
`api_rpc_reply` — Reply to Process node
`api_queue` — Queue node
`api_get_task` — Get from Queue node;
`git_call` — Git Call node
`db_call` — Database Call node
(also the Delay node has 'logics' = [], only 'semaphors' are non-empty)" + }, + "mode": { + "type": "string", + "enum": [ + "create", + "modify", + "key_value", + "keys" + ], + "description": "`create` — Copy Task node
`modify` — Modify Task node
`key_value` — Reply to Process node returns an object with key-value pairs
`keys` — Reply to Process node returns an array with keys only
This response parameter exists for the following nodes: Copy Task, Modify Task, Reply to Process." + }, + "to_node_id": { + "type": "string", + "example": "62b599ba094bab2fe4000308", + "description": "ID of the next node which is connected to the current node.
This response parameter exists for every node, except for the Final node (both Success and Error)." + }, + "conditions": { + "type": "array", + "description": "An array with condition key-value pairs data
This response parameter exists only for Condition and Set State (option) nodes.", + "items": { + "type": "object", + "properties": { + "param": { + "type": "string", + "description": "A key from key-value pairs (variable)" + }, + "const": { + "type": "string", + "description": "A value from key-value pairs (this value is compared with variable's value or is used with a regular expression in case the parameter 'fun' = \"regexp\")" + }, + "fun": { + "type": "string", + "enum": [ + "more", + "less", + "eq", + "not_eq", + "regexp" + ], + "description": "Comparison in a condition:
`more` — (>) greater than
`less` — (<) less than
`eq` — (==) equal to
`not_eq` — (!=) not equal to
`regexp` — regular expression" + }, + "cast": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "description": "type of value from key-value pairs" + } + } + } + }, + "data": { + "type": "object", + "description": "Button + Add key-value adds a new parameter to node settings:
Key - parameter name
Value can be specified with:
- Constant.
- {{parameter_name}} from a task which name will be pasted.
- Any system parameter of the current process. For example, {{root.ref}} or {{root.task_id}}.
If the Copy all parameters flag is checked, it is not required to add new parameters.
Otherwise be sure to add at least one parameter.

Parameters that we send to another node — object with keys-values (type string both),
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable.
This response parameter exists for the following nodes: Copy Task, Modify Task, Queue node." + }, + "data_type": { + "type": "object", + "description": "object with keys-values (string type both),
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable (value type from 'data' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for the following nodes: Copy Task, Modify Task, Queue node." + }, + "res_data": { + "oneOf": [ + { + "type": "object", + "description": "An object with keys-values (string type both) when node logics parameter 'mode' = \"key_value\".
\"key\" is a variable name (new or already existing) and the \"value\" is a new value of this variable." + }, + { + "type": "array", + "items": { + "type": "string", + "description": "An array with keys only — when node logics parameter 'mode' = \"keys\".
Key is a variable name (new or already existing)." + } + } + ], + "description": "Parameters that we send to another node.
This response parameter exists only for the Reply to Process node." + }, + "res_data_type": { + "type": "object", + "description": "An object with keys-values (type string both)
\"key\" is variable name (new or already existing) and the \"value\" is a new value of this variable (value type from 'res_data' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists only for the Reply to Process node." + }, + "throw_exception": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "The flag shows a state that can be defined by the \"Throw exception\" option in node settings.
This response parameter exists only for the Reply to Process node." + }, + "exception_reason": { + "type": "string", + "description": "Error message - exception reason
This response parameter exists only for the Reply to Process node with the \"Throw exception\" option enabled and error message specified in node settings." + }, + "group": { + "type": "string", + "enum": [ + "", + "all" + ], + "description": "This response parameter is set to `all` when the \"Copy all task parameters to the new task\" option is enabled in node settings, and there are no specified additional key-value pairs.
This response parameter exists for the following nodes: Copy Task, Modify Task, Call a Process." + }, + "ref": { + "type": "string", + "description": "Task reference can be specified with:
- Any system parameter of the current process. For example, {{root.ref}} or {{root.task_id}}.
- Any other parameter of the current task {{parameter_name}}.
- Constant - for example: config, ref, etc.
This response parameter exists only for Copy Task node and Modify Task nodes." + }, + "send_parent_data": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "This response parameter exists only for Copy Task node and Modify Task nodes." + }, + "is_sync": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "This response parameter equals \"true\" when the \"Synchronous callback\" option is enabled in node settings.
This response parameter exists only for the Modify Task node." + }, + "conv_id": { + "type": "integer", + "description": "ID of the Process / State Diagram to which we send our task (or a request in case of using the Get from Queue node).
This option value can be specified manually or by copying the process ID from \"tree of folders\" (in node settings).
Process / State Diagram can be found by name, ID, or using the {{conv_id}} (parameter of the task).
This response parameter exists for nodes: Copy Task, Modify Task, Call a Process, Get from Queue." + }, + "user_id": { + "type": "integer", + "description": "ID of User - last node editor
This response parameter exists for nodes: Copy Task, Modify Task, Call a Process." + }, + "extra": { + "type": "object", + "description": "Request parameters — object with keys-values (type string both).
\"key\" is variable name - parameter name (new or already existing) and \"value\" is a value from a task or a new value of this variable (constant value) — or just key-value pairs in case with the API Call node.
In case with the Sum node, \"Key\" is the specified name of a parameter that will contain the sum of values.
\"Value\" - {{parameter_name}} from a task which will be summed up or a constant (constant value).
This response parameter exists for the following nodes: Sum, Call a Process, API Call (optional)." + }, + "extra_type": { + "type": "object", + "description": "An object with keys-values (type string both).
\"key\" is a variable name (new or already exists) — or just a key in case with the API Call node, and value is a type of new value of this variable (type of value from 'extra' object for this key).
The value can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for nodes: Call a Process, API Call (optional)." + }, + "err_node_id": { + "type": "string", + "description": "ID of the Error Node (that will handle errors), connected with current node.
This response parameter exists for Code, Call a Process, Set Parameters, Modify Task, Copy Task, Get from Queue, Git Call v2, Database Call, and API Call nodes." + }, + "instance_id": { + "type": "integer", + "description": "Database instance ID
This response parameter exists only for the Database Call node." + }, + "query": { + "type": "string", + "description": "SQL query that will be executed.
This response parameter exists only for the Database Call node." + }, + "version": { + "type": "integer", + "description": "Node version
This response parameter exists only for the Git Call node." + }, + "lang": { + "type": "string", + "enum": [ + "js", + "erl", + "golang", + "python", + "php", + "java" + ], + "description": "This response parameter describes a programming language used used in code written in Code (js, erl) and Git Call nodes (js, golang, python, php, java):
`js` — JavaScript
`erl` — Erlang
`golang` — Go
`python` — Python
`php` — PHP
`java` — Java
This response parameter exists for the following nodes: Code and Git Call." + }, + "src": { + "type": "string", + "description": "This response parameter returns source code of the Code and Git Call nodes.
The value can be `\"\"` empty string when the Git Call node has defined Repo URL.
This response parameter exists for the following nodes: Code and Git Call." + }, + "repo": { + "type": "string", + "description": "Repo URL, can be `\"\"` empty string when web not define it in node settings.
This response parameter exists only for the Git Call node." + }, + "script": { + "type": "string", + "description": "Build command
This response parameter exists only for the Git Call node." + }, + "commit": { + "type": "string", + "description": "Tag Branch Commit
This response parameter exists only for the Git Call node." + }, + "handler": { + "type": "string", + "description": "The \"Handler\" option in node settings
This response parameter exists when the parameter 'lang' = \"java\".
This response parameter exists only for the Git Call node." + }, + "log": { + "type": "object", + "description": "This response parameter exists only for the Git Call node." + }, + "code_error": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "This response parameter exists only for the Git Call node." + }, + "code": { + "type": "string", + "description": "This response parameter returns source code of the Git Call node.
The value can be `\"\"` empty string when the Git Call node has defined Repo URL.
This response parameter exists only for the Git Call node." + }, + "format": { + "type": "string", + "enum": [ + "", + "conveyor", + "raw" + ], + "description": "Request format:
`\"\"` (empty string) — Default — enables the selection of an HTTP method of a request to API.
`conveyor` — Corezoid — request to API in Corezoid format.
`raw` — Raw — get a raw result of an http request.
This response parameter exists for the API Call node." + }, + "method": { + "type": "string", + "enum": [ + "POST", + "GET", + "PUT", + "DELETE", + "HEAD", + "PATCH" + ], + "description": "[HTTP request method](https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods)
This response parameter exists for the API Call node." + }, + "url": { + "type": "string", + "description": "API's request URL
This response parameter exists for the API Call node." + }, + "max_threads": { + "type": "integer", + "default": 11, + "description": "Limit the number of simultaneous requests to the API.
This response parameter exists for the API Call node." + }, + "debug_info": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Flag for enable/disable return debug info.
The \"Include debug info\" option in the API Call node settings
This response parameter exists for the API Call node." + }, + "customize_response": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Flag for enable/disable return customizing response.
Option \"Customize response parameters\" in the API Call node settings
This response parameter exists for the API Call node." + }, + "response": { + "type": "object", + "description": "Response parameters from API.
Can be customized by enabling the \"Customize response parameters\" option in the API Call node settings.
The 'response' and 'response_type' response parameters are described with default key-value pairs here.
This response parameter exists for the API Call node.", + "properties": { + "header": { + "type": "string", + "description": "response header" + }, + "body": { + "type": "string", + "description": "response body" + } + } + }, + "response_type": { + "type": "object", + "description": "Type of data in response from API (in 'response' response parameter).
Keys and values are string type both.
Keys are the same as in 'response' response parameter.
Values can be one of: \"string\", \"number\", \"boolean\", \"array\", or \"object\".
This response parameter exists for the API Call node.", + "properties": { + "header": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "default": "object", + "description": "response header value type" + }, + "body": { + "type": "string", + "enum": [ + "string", + "number", + "boolean", + "array", + "object" + ], + "default": "object", + "description": "response body value type" + } + } + }, + "extra_headers": { + "type": "object", + "description": "Request headers, can be defined with the \"Header parameters\" parameter values in the API Call node settings.
Object with keys-values (string type both). `{}` empty object by default — when not a single header is defined.
This response parameter exists for the API Call node." + }, + "send_sys": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "The \"Add system parameters to the request\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "cert_pem": { + "type": "string", + "description": "Certificate, can be defined by enabling the \"Sign the request by certificate\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "api_secret_outer": { + "type": "string", + "description": "Secret key, can be defined by enabling the \"Sign the request with the secret key\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "content_type": { + "type": "string", + "enum": [ + "application/json", + "application/x-www-form-urlencoded", + "application/xml", + "text/xml", + "application/soap+xml" + ], + "default": "application/json", + "description": "Response format ([MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types), [Media type](https://www.iana.org/assignments/media-types/media-types.xhtml)), Can be changed by enabling the \"Customize response parameters\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "rfc_format": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "The \"RFC standard response\" option in the API Call node settings.
This response parameter exists for the API Call node." + }, + "is_migrate": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "System parameter:
`true` — new format of logics
`false` — old format of logics
This response parameter exists for the API Call node." + }, + "order_by": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ], + "description": "`ASC` — Take from the queue start
`DESC` — Take from the queue end
This response parameter exists for the Get from Queue node." + }, + "node_id": { + "type": "string", + "description": "Queue node ID
Example: \"6320a47356167c3e5500fee9\"
This response parameter exists for the Get from Queue node." + }, + "convTitle": { + "type": "string", + "description": "Title of process with the Queue node.
This response parameter exists for the Get from Queue node." + } + } + } + }, + "compare-response": { + "type": "object", + "title": "compare", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_scheme" + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "parent_id": { + "type": "integer", + "description": "Parent Folder ID, where Object is stored" + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "title": { + "type": "string", + "description": "Object Title" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard", + "alias", + "instance" + ], + "description": "Object type:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`alias` — Alias
`instance` — Database instance" + }, + "__status": { + "type": "string", + "enum": [ + "deleted", + "added", + "changed", + "" + ], + "description": "Diff Status:
`deleted` — Object was deleted
`added` — Object was added
`changed` — Object was changed
`\"\"` — Object is not modified
this response parameter is present when the request parameter 'diff_status' = \"true\"" + }, + "__added": { + "type": "object", + "description": "information about Object/Object's parameters or properties that was/were add
can be `{}` empty object
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "allOf": [ + { + "$ref": "#/components/schemas/part" + } + ] + }, + "__changed": { + "type": "object", + "description": "information on Object/Object's parameters or properties that was/were changed
can be `{}` empty object
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "allOf": [ + { + "$ref": "#/components/schemas/part" + } + ] + }, + "__deleted": { + "type": "object", + "description": "information on Object/Object's parameters or properties that was/were deleted
can be `{}` empty object
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "allOf": [ + { + "$ref": "#/components/schemas/part" + } + ] + }, + "obj_to_title": { + "type": "string", + "description": "Title of an Object to which an Alias is linked
this response parameter is present when the response parameter 'obj_type' = \"alias\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "description": { + "type": "string", + "description": "Object description
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "lists": { + "type": "array", + "description": "Dashboard nodes
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "charts_order": { + "type": "array", + "description": "Dashboard charts order
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "grid": { + "type": "array", + "description": "Dashboard nodes position
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node Identifier" + }, + "x": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the X axis with respect to the 0:0 reference point in the process field coordinates" + }, + "y": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the Y axis with respect to the 0:0 reference point in the process field coordinates" + }, + "width": { + "type": "integer", + "description": "node width" + }, + "height": { + "type": "integer", + "description": "node height" + } + } + } + }, + "time_range": { + "type": "object", + "description": "Dashboard time range
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "properties": { + "timezone_offset": { + "type": "integer", + "description": "Timezone Offset, the difference in minutes between UTC and local time" + }, + "select": { + "type": "string", + "enum": [ + "online", + "fromTo", + "last10minute", + "today", + "lastHour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month" + ], + "description": "Display date-time range:
`online` — Real-Time
`fromTo` — Custom Range
`last10minute` — Last 10 minutes
`today` — Today
`lastHour` — Last hour
`last24hour` — Last 24 hours
`lastWeek` — Last 7 days
`lastMonth` — Last 30 days
`previous_hour` — Previous hour
`previous_day` — Previous day
`previous_week` — Previous week
`previous_month` — Previous month" + } + } + }, + "charts_list": { + "type": "array", + "description": "An array of Charts on the Dashboard
this response parameter is present when the response parameter 'obj_type' = \"dashboard\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "items": { + "type": "object", + "properties": { + "chart_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Chart Identifier" + }, + "series": { + "type": "array", + "description": "An array of Nodes which statistics you want to display", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "ID of a Process or a State diagram where the Node is stored" + }, + "node_id": { + "type": "string", + "description": "ID of a Node used for the Dashboard metric" + }, + "title": { + "type": "integer", + "description": "Title of a Node which is described in the Chart legend" + }, + "type_icon": { + "type": "string", + "description": "Node icon type" + }, + "type_title": { + "type": "integer", + "description": "Node type title" + }, + "type": { + "type": "string", + "description": "Node type" + } + } + } + }, + "name": { + "type": "string", + "description": "Chart Name" + }, + "settings": { + "nullable": true, + "description": "Chart settings" + }, + "description": { + "type": "string", + "description": "Chart description" + }, + "obj_type": { + "type": "string", + "enum": [ + "table", + "column", + "pie", + "funnel" + ], + "description": "Chart type:
`table` — Table chart
`column` — Bar chart
`pie` — Pie chart
`funnel` — Funnel chart" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: 2a4c797e-5e24-42e9-b950-163c9ca0fd82" + } + } + } + }, + "short_name": { + "type": "string", + "description": "Alias short name
this response parameter is present when the response parameter 'obj_type' = \"alias\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of Object linked to Alias
this response parameter is present when the response parameter 'obj_type' = \"alias\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "obj_to_type": { + "type": "string", + "description": "Type of Object linked to Alias:
`conv` — Process / State diagram
this response parameter is present when the response parameter 'obj_type' = \"alias\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "status": { + "type": "string", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug" + ], + "description": "Object state
this response parameter is present when the response parameter 'obj_type' = \"conv\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "param": { + "type": "array", + "description": "An array with all Task Params, described as JSON
this response parameter is present when the response parameter 'obj_type' = \"conv\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "ref_mask": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Enables and disables the masking (displayed as \"***\") of values of parameters and task references which consist of a set of digits and have the format similar to the format of:
bank account / card number or CVV code
this response parameter is present when the response parameter 'obj_type' = \"conv\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state" + ], + "description": "Type of an Object:
`process` — Process
`state` — State diagram
this response parameter is present when the response parameter 'obj_type' = \"conv\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "scheme": { + "type": "object", + "description": "this response parameter is present when the response parameter 'obj_type' = \"conv\"
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false", + "properties": { + "nodes": { + "type": "array", + "items": { + "type": "object", + "properties": { + "__added": { + "type": "object", + "description": "Node parameters/properties that were added" + }, + "__deleted": { + "type": "object", + "description": "Node parameters/properties that were deleted" + }, + "__changed": { + "type": "object", + "description": "Node parameters/properties that were changed" + }, + "id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Node Identifier" + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node
`2` — final node
`3` — escalation - special system node" + }, + "conditions": { + "type": "object", + "properties": { + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics-obj_scheme_compare" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + } + } + }, + "title": { + "type": "string", + "description": "Node Title" + }, + "description": { + "type": "string", + "description": "Node description" + }, + "x": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the X axis with respect to the 0:0 reference point in the process field coordinates" + }, + "y": { + "type": "integer", + "description": "Coordinates of a node's left upper corner along the Y axis with respect to the 0:0 reference point in the process field coordinates" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: 32bac6d3-625e-4001-8aa5-8525b94df55a" + }, + "extra": { + "type": "string with JSON", + "description": "A stringify object of additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view);
icon — Icon for the success (green) / error (red) final node. For all the other nodes - \"icon\":\"\".
example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"" + }, + "options": { + "type": "string with JSON", + "nullable": true, + "description": "A stringify object of the save_task additional node setting;
example: \"{\\\\\"save_task\\\\\":true}\"" + } + } + } + }, + "web_settings": { + "type": "array", + "deprecated": true + } + } + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object
example: 32bac6d3-625e-4001-8aa5-8525b94df55a
this response parameter is present when the request parameter 'diff_status' = \"false\" and \"num_stat\" = false" + }, + "__num_stat": { + "type": "object", + "description": "this response parameter is present when the request parameter 'num_stat' = \"true\"", + "properties": { + "added": { + "type": "integer", + "description": "count of Objects that were added" + }, + "changed": { + "type": "integer", + "default": 0, + "description": "count of Objects that were changed" + }, + "deleted": { + "type": "integer", + "description": "count of Objects that were deleted" + } + } + } + } + } + } + } + }, + "example-compare-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1045470, + "title": "test01", + "obj_type": "conv", + "__status": "added" + }, + { + "parent_id": 375502, + "obj_id": 57419, + "title": "test1", + "obj_type": "alias", + "__status": "added" + } + ] + } + ] + }, + "example-compare_diff_status_false-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1065390, + "title": "test01 (Copy)", + "obj_type": "conv", + "__added": {}, + "__deleted": { + "obj_type": 1, + "obj_id": 1065390, + "parent_id": 375502, + "title": "test01 (Copy)", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [], + "web_settings": [] + }, + "uuid": "712824a9-826a-45ae-b1ed-d8ac6a81d5d1" + }, + "__changed": {}, + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [], + "web_settings": [] + }, + "uuid": "712824a9-826a-45ae-b1ed-d8ac6a81d5d1" + } + ] + } + ] + }, + "example-compare_diff_status_false_num_stat_true-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 409621, + "obj_id": 1079612, + "title": "process01 (Copy)", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 0 + } + } + ] + } + ] + }, + "example-compare_num_stat_true-request": { + "ops": [ + { + "company_id": "i848211059", + "project_id": 375501, + "type": "compare", + "obj": "obj_scheme", + "obj_type": "stage", + "obj_id": 375502, + "obj_to_type": "stage", + "obj_to_id": 395929, + "diff_status": true, + "num_stat": true + } + ] + }, + "example-compare_num_stat_true-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_scheme", + "list": [ + { + "parent_id": 375502, + "obj_id": 1065390, + "title": "test01 (Copy)", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 1 + }, + "__status": "deleted" + }, + { + "parent_id": 375502, + "obj_id": 1067111, + "title": "test002", + "obj_type": "conv", + "__num_stat": { + "added": 1, + "changed": 0, + "deleted": 0 + }, + "__status": "added" + }, + { + "parent_id": 375502, + "obj_id": 59681, + "title": "test1", + "obj_type": "alias", + "__num_stat": { + "added": 0, + "changed": 3, + "deleted": 0 + }, + "__status": "changed" + }, + { + "parent_id": 375502, + "obj_id": 1065392, + "title": "New object44", + "obj_type": "conv", + "__num_stat": { + "added": 0, + "changed": 0, + "deleted": 0 + }, + "__status": "" + } + ] + } + ] + }, + "merge-request": { + "type": "object", + "title": "merge", + "required": [ + "obj", + "obj_id", + "obj_type", + "obj_to_id", + "obj_to_type", + "company_id" + ], + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "obj_id": { + "type": [ + "integer", + "string" + ], + "description": "ID of the target Object — type integer
(when the request parameter 'obj_type' != \"scheme\")

Target Object — type string
(when the request parameter 'obj_type' = \"scheme\")" + }, + "obj_type": { + "type": "string", + "enum": [ + "stage" + ], + "description": "Type of the target object:
`stage` — Stage" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "stage", + "version", + "scheme" + ], + "description": "Type of the source object:
`stage` — Stage
`version` — saved Version of a Stage
`scheme` — for uploading a Stage from a zip file" + }, + "obj_to_id": { + "type": [ + "integer", + "string" + ], + "description": "ID of the source Object — type integer
(when the request parameter 'obj_to_type' != \"scheme\")

Source Object — type string
(when the request parameter 'obj_to_type' = \"scheme\")" + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "nullable": true, + "description": "ID of an existing Company.
", + "example": "i791331829" + }, + "project_id": { + "type": "integer", + "description": "Project ID" + }, + "apply_mode": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "`true` — make a merge operation
`false` — do not make a merge operation, return Diff" + }, + "exclude": { + "type": "array", + "deprecated": true, + "description": "do not merge specified objects", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard" + ], + "description": "Object type:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard" + } + } + } + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "Asynchronous request execution method" + } + } + }, + "example-merge-request": { + "ops": [ + { + "type": "merge", + "obj": "obj_scheme", + "obj_id": 375502, + "obj_type": "stage", + "obj_to_id": 395929, + "obj_to_type": "stage", + "apply_mode": true, + "company_id": "i848211059" + } + ] + }, + "example-merge_async_false-request": { + "ops": [ + { + "type": "merge", + "obj": "obj_scheme", + "obj_id": 409621, + "obj_type": "stage", + "obj_to_id": 409619, + "obj_to_type": "stage", + "apply_mode": true, + "async": false, + "company_id": "i848211059" + } + ] + }, + "merge-response": { + "type": "object", + "title": "merge", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_scheme" + }, + "hash": { + "type": "string", + "description": "file hash
this response parameter is present when the request parameter 'async' = \"true\"" + }, + "diff": { + "type": "array", + "description": "this response parameter is present when the request parameter 'async' = \"false\"", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Parent Folder ID / Stage ID
this response parameter is present when the request parameter 'apply_mode' = \"true\"" + }, + "obj_type": { + "type": "string", + "enum": [ + "stage" + ], + "description": "Object type:
`stage` — Stage
this response parameter is present when the request parameter 'apply_mode' = \"true\"" + }, + "type": { + "type": "string", + "enum": [ + "create", + "delete", + "modify" + ], + "description": "Diff type:
`create` — an Object was added
`delete` — an Object was deleted
`modify` — an Object was edited
this response parameter is present when the request parameter 'apply_mode' = \"false\"" + }, + "obj": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard", + "alias", + "instance" + ], + "description": "Object type:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`alias` — Alias
`instance` — Database instance
this response parameter is present when the request parameter 'apply_mode' = \"false\"" + } + } + } + } + } + }, + "example-merge-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D315F6D756C746D0000000C63BBFB6E56167C0FD700071C" + } + ] + }, + "example-merge_async_false-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "diff": { + "obj_id": 409621, + "obj_type": "stage" + } + } + ] + }, + "example-merge_apply_mode_false-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "diff": [ + { + "type": "modify", + "obj": "conv", + "conv_type": "process", + "description": "", + "obj_type": 1, + "params": [], + "ref_mask": true, + "status": "active", + "title": "New Process1", + "uuid": "8a0294be-ef0d-40f9-88fb-b8201ef5bdb0" + }, + { + "type": "create", + "obj": "folder", + "obj_id": 445723, + "title": "New Folder", + "description": "", + "uuid": "bdf0b170-a7e5-4a0b-9b11-7df6ee975a1b", + "folder_id": 445719 + } + ] + } + ] + }, + "copy-request": { + "type": "object", + "title": "copy", + "required": [ + "obj", + "obj_to_id", + "obj_to_type", + "obj_id", + "obj_type", + "title" + ], + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_copy" + }, + "obj_to_id": { + "type": "integer", + "description": "ID of a target Project/Stage/Folder where the Object copy will be stored
this request parameter is required when the 'folder_id' request parameter is not present (one of them must be defined)" + }, + "obj_to_type": { + "type": "string", + "enum": [ + "project", + "stage", + "folder" + ], + "description": "Type of a target where the Object copy will be stored:
`project` — Project, if the target = project then copied object (obj_type) can only be = Stage
`stage` — Stage
`folder` — Folder
this request parameter is required when the 'obj_to_id' request parameter is present" + }, + "folder_id": { + "type": "integer", + "description": "ID of a target Folder where the Object copy will be stored
this request parameter is required when the 'obj_to_id' request parameter is not present (must be defined one of them)" + }, + "obj_id": { + "type": "integer", + "description": "ID of the copied Object" + }, + "obj_type": { + "type": "string", + "enum": [ + "conv", + "dashboard", + "instance", + "folder", + "stage", + "project" + ], + "description": "Type of the copied Object:
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance
`folder` — Folder
`stage` — Stage
`project` — Project" + }, + "title": { + "type": "string", + "minLength": 0, + "maxLength": 255, + "description": "Object title" + }, + "company_id": { + "deprecated": true, + "type": "string", + "description": "Company ID" + }, + "from_company_id": { + "type": "string", + "description": "ID of a source Company where the copied Object is stored" + }, + "to_company_id": { + "type": "string", + "description": "ID of a target Company where the copied Object will be stored" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Object short name" + }, + "ignore_errors": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Ignore errors:
if a parameter is not sent and there are errors when copying, the method will return an error,
if a parameter is sent and there are errors when copying, the method will return the response without errors" + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "Asynchronous request execution method" + }, + "with_aliases": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Defines whether the object is to be copied with its available Aliases. When not specified, the object is copied without its Aliases." + } + } + }, + "copy-response": { + "type": "object", + "title": "copy", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_copy" + }, + "hash": { + "type": "string", + "description": "file hash, with length:
40 symbols — when the request parameter 'async' = \"false\"
142 symbols — when the request parameter 'async' = \"true\"" + }, + "statistics_id": { + "type": "string", + "description": "Statistics ID, can be used to get the progress status of the copy
this response parameter is present when the request parameter 'async' = \"true\"" + }, + "scheme": { + "type": "array", + "description": "this response parameter is present when the request parameter 'async' = \"false\"", + "items": { + "type": "object", + "properties": { + "hash": { + "type": "string", + "description": "file hash" + }, + "obj_id": { + "type": "integer", + "description": "New Object ID (we got this Object after performing the copy operation)" + }, + "obj_type": { + "type": "string", + "enum": [ + "conv", + "dashboard", + "instance", + "folder", + "stage", + "project" + ], + "description": "Type of an object that we make copy of
(the same as the request parameter 'obj_type'):
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance
`folder` — Folder
`stage` — Stage
`project` — Project" + }, + "title": { + "type": "string", + "description": "Title of an Object that we make copy of" + }, + "description": { + "type": "string", + "description": "Description of an Object that we make copy of" + }, + "old_obj_id": { + "type": "integer", + "description": "Old Object ID (we create a new object from this one when performing the copy operation)" + }, + "old_parent_id": { + "type": "integer", + "description": "Parent Folder ID / Stage ID of Old Object" + } + } + } + } + } + }, + "copy-error_response": { + "type": "object", + "title": "copy", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "obj_copy" + }, + "errors": { + "type": "array", + "description": "Errors array", + "items": { + "type": "object", + "properties": { + "conv_type": { + "type": "string", + "description": "Type of the copied process:
`process` — Process
`state` — State diagram
`escalation` — deprecated (special system process, designed to handle Process / State diagram errors)" + }, + "obj_id": { + "type": "integer", + "description": "ID of the copied Object" + }, + "obj": { + "type": "string", + "description": "Type of an object that we make copy of
" + }, + "title": { + "type": "string", + "description": "Title of an Object that we make copy of" + }, + "count": { + "type": "string", + "description": "Number of errors" + }, + "destinations": { + "type": "array", + "description": "Errors details", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "string", + "description": "ID of the copied Object with error" + }, + "obj": { + "type": "integer", + "description": "Type of the copied Object with error" + }, + "title": { + "type": "string", + "description": "Title of the copied Object with error" + }, + "count": { + "type": "integer", + "description": "Number of errors" + }, + "errors": { + "type": "array", + "description": "Errors array" + } + } + } + } + } + } + } + } + }, + "example-copy-request": { + "ops": [ + { + "obj": "obj_copy", + "obj_type": "conv", + "obj_id": 1045470, + "obj_to_id": 395929, + "obj_to_type": "stage", + "title": "test01 (Copy)", + "ignore_errors": true, + "async": false, + "from_company_id": "i848211059", + "to_company_id": "i848211059" + } + ] + }, + "example-copy-response": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_copy", + "proc": "ok", + "scheme": [ + { + "hash": "77508f7fdd7a5ee62c5630569245d3bc63ac486f", + "obj_id": 1065389, + "obj_type": "conv", + "title": "test01 (Copy)", + "description": "", + "old_obj_id": 1045470, + "old_parent_id": 395929 + } + ] + } + ] + }, + "example-copy-error_response": { + "request_proc": "ok", + "ops": [ + { + "proc": "error", + "errors": [ + { + "conv_type": "process", + "obj_id": 1154601, + "obj": "conv", + "title": "New Process (Copy)", + "count": 1, + "destinations": [ + { + "obj_id": "642d0aa0094bab1b2d00188f", + "obj": "node", + "title": "", + "count": 1, + "errors": [ + "Key 'conv_id'. 'Task operations between companies is not allowed'" + ] + } + ] + } + ] + } + ] + }, + "example-copy_async_true-request": { + "ops": [ + { + "obj": "obj_copy", + "obj_type": "conv", + "obj_id": 1073537, + "obj_to_id": 409619, + "obj_to_type": "stage", + "title": "process01 (Copy)", + "ignore_errors": true, + "async": true, + "from_company_id": "i848211059", + "to_company_id": "i848211059" + } + ] + }, + "example-copy_async_true-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "obj": "obj_copy", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63CA7B2F094BAB2F5000022A", + "statistics_id": "copy_conv_1073537_eWNeD3hRPo.zip" + } + ] + }, + "download-request-2": { + "type": "object", + "title": "download", + "required": [ + "obj", + "obj_id", + "format", + "conv_id", + "limit", + "async" + ], + "properties": { + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "node" + }, + "timezone_offset": { + "type": "integer", + "default": 0, + "description": "difference from Coordinated Universal Time (UTC) timezone" + }, + "select": { + "type": "string", + "enum": [ + "last10minute", + "lastHour", + "last6hour", + "last12hour", + "last24hour", + "lastWeek", + "lastMonth", + "previous_hour", + "previous_day", + "previous_week", + "previous_month", + "custom", + "fromTo" + ], + "description": "Task selection period:
`last10minute` — last 10 minutes
`lastHour` — last 1 hour
`last6hour` — last 6 hours
`last12hour` — last 12 hours
`last24hour` — last 24 hours
`lastWeek` — last week
`lastMonth` — last month
`previous_hour` — previous hour
`previous_day` — previous day
`previous_week` — previous week
`previous_month` — previous month
`custom` — Tasks custom range (offset with count)
`fromTo` — custom time interval" + }, + "start": { + "type": "integer", + "minimum": 0, + "description": "The start time (timestamp) of the selection, in unixtime format
this request parameter is allowed when the request parameter 'select' = \"fromTo\"" + }, + "end": { + "type": "integer", + "minimum": 0, + "description": "The end time (timestamp) of the selection, in unixtime format
this request parameter is allowed when the request parameter 'select' = \"fromTo\"" + }, + "offset": { + "type": "integer", + "minimum": 0, + "default": 0, + "description": "A number of Tasks that need to be skipped when getting the selection" + }, + "limit": { + "type": "integer", + "minimum": 1, + "maximum": "System_Limit", + "default": "System_Limit", + "description": "A number of max results in report;
We don't recommend setting this parameter higher than 50000" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Existing Node ID" + }, + "format": { + "type": "string", + "enum": [ + "csv" + ], + "description": "Download file format" + }, + "conv_id": { + "type": "integer", + "minimum": 1, + "description": "Existing Process or State diagram ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "extra_columns": { + "description": "Set of system parameters that you want to export;
can be `[]` empty array
`ref` — task reference (a unique value in the current process)
`task_id` — task ID (a unique value across the system)
`status` — task status (created or processed)
`user_id` — user ID (which created the task)
`create_time` — date and time of the task creation, in unixtime format
`change_time` — date and time of the task change, in unixtime format
`node_prev_id` — previous node ID", + "type": "array", + "items": { + "type": "string", + "enum": [ + "ref", + "task_id", + "status", + "user_id", + "create_time", + "change_time", + "node_prev_id" + ] + } + } + } + }, + "download-response-2": { + "type": "object", + "title": "download", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "node" + }, + "download_url": { + "type": "string", + "description": "URL for the file download" + }, + "statistics_id": { + "type": "string", + "description": "Statistics ID, can be used to get the progress status of the download" + } + } + }, + "example-download-request-2": { + "ops": [ + { + "obj_id": "639f3ea7094bab788a0008a1", + "select": "custom", + "offset": 0, + "limit": 5, + "extra_columns": [ + "ref", + "task_id", + "status", + "user_id", + "create_time", + "change_time", + "node_prev_id" + ], + "format": "csv", + "obj": "node", + "conv_id": 1045470, + "company_id": "i848211059" + } + ] + }, + "example-download-response-2": { + "request_proc": "ok", + "ops": [ + { + "download_url": "https://pre.corezoid.com/user_downloads/1045470_conv_639f3ea7094bab788a0008a1_1672282649.csv", + "statistics_id": "1045470_conv_639f3ea7094bab788a0008a1_1672282649.csv", + "obj": "node", + "proc": "ok" + } + ] + }, + "create-request-16": { + "type": "object", + "title": "upload", + "required": [ + "type", + "obj", + "version_id", + "project_id", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "upload" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "version" + }, + "version_id": { + "type": "integer", + "minimum": 1, + "description": "Version ID" + }, + "stage_to_id": { + "type": "integer", + "description": "Stage ID to which a Version will be uploaded" + }, + "project_id": { + "type": "integer", + "default": 0, + "description": "Project ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Asynchronous request execution method" + } + } + }, + "create-response-16": { + "type": "object", + "title": "upload", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "version" + }, + "stage_to_id": { + "type": "integer", + "description": "Stage ID to which a Version uploaded" + } + } + }, + "example-create-request-15": { + "type": "upload", + "obj": "version", + "version_id": 28624, + "stage_to_id": 686010, + "project_id": 686008, + "company_id": "i738314881" + }, + "example-create-response-15": { + "request_proc": "ok", + "ops": [ + { + "obj": "version", + "proc": "ok", + "stage_to_id": 686010 + } + ] + }, + "example-create-response-async": { + "request_proc": "ok", + "ops": [ + { + "obj": "obj_scheme", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D000000216D756C742E6374726C2E6D772D7072652D637A2D312D6170692D6E325F6D756C746D0000000C66AB5FA496FC3B36F3000976" + } + ] + }, + "create-request-17": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "divider", + "encoding", + "names_in_first_row", + "conv_id", + "from_file", + "reference_col_name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "task" + }, + "divider": { + "type": "string", + "enum": [ + ",", + ";", + "|" + ], + "description": "Divider between values in a csv file" + }, + "encoding": { + "type": "string", + "enum": [ + "windows-1251", + "utf-8" + ], + "description": "csv file encoding" + }, + "names_in_first_row": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Column names (keys) placed in the first row of the csv file" + }, + "reference_col_name": { + "type": "string", + "default": "", + "description": "Name of a column with a task reference (task external identifier)" + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": false, + "description": "Asynchronous request execution method" + }, + "conv_id": { + "type": "integer", + "description": "Process ID, tasks from the csv file are uploaded to this Process" + }, + "file_name": { + "type": "string", + "description": "csv file name" + }, + "from_file": { + "type": "string", + "format": "binary", + "description": "A csv file containing the Tasks that will be uploaded
" + }, + "cols_convert_to": { + "type": "array of strings", + "enum": [ + "string", + "integer", + "float", + "number", + "boolean", + "array", + "object" + ], + "description": "The type to which values from each string of the csv file will be converted" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "extra_sys_ip": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "System parameter — IP from that file uploaded" + }, + "extra_sys_filename": { + "type": "boolean", + "enum": [ + true, + false + ], + "default": true, + "description": "System parameter — source file name" + } + } + }, + "create-response-17": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "csv_upload" + }, + "ok_count": { + "type": "integer", + "description": "Count of successfully uploaded tasks
this response parameter is present when the request parameter 'async' = \"false\"" + }, + "err_count": { + "type": "integer", + "description": "Count of tasks that failed to upload (error)
this response parameter is present when the request parameter 'async' = \"false\"" + }, + "all_count": { + "type": "integer", + "description": "Count of all tasks (successfully uploaded + not uploaded (error))
this response parameter is present when the request parameter 'async' = \"false\"" + }, + "hash": { + "type": "string", + "description": "Hash can be used to get the [progress status](#tag/upload_info) of the upload
this response parameter is present when the request parameter 'async' = \"true\"" + } + } + }, + "example-create-request-16": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=task' \\\n--form 'divider=|' \\\n--form 'encoding=utf-8' \\\n--form 'names_in_first_row=true' \\\n--form 'reference_col_name=' \\\n--form 'cols_convert_to=[\"array\", \"object\", \"string\", \"string\"]' \\\n--form 'conv_id=348472' \\\n--form 'company_id=i471132929' \\\n--form 'from_file=tasks.csv;type=text/csv' \\\n--form 'async=true'\n", + "example-create-response-16": { + "request_proc": "ok", + "ops": [ + { + "obj": "csv_upload", + "proc": "ok", + "hash": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D6465762D315F6D756C746D0000000C639C8E0B4B8FF93FA50000AE" + } + ] + }, + "example-create_async_false-request-2": "curl --location --request POST 'https://admin.corezoid.com/api/2/upload/777/123/aa4r4r0f43d4cdff3f13cacb5b2730198f' \\\n--header 'Content-Type: application/x-www-form-urlencoded' \\\n--form 'type=create' \\\n--form 'obj=task' \\\n--form 'divider=|' \\\n--form 'encoding=utf-8' \\\n--form 'names_in_first_row=true' \\\n--form 'reference_col_name=' \\\n--form 'cols_convert_to=[\"array\", \"object\", \"string\", \"string\"]' \\\n--form 'conv_id=348472' \\\n--form 'company_id=i471132929' \\\n--form 'from_file=tasks.csv;type=text/csv' \\\n--form 'async=false'\n", + "example-create_async_false-response-2": { + "request_proc": "ok", + "ops": [ + { + "obj": "csv_upload", + "proc": "ok", + "ok_count": 2, + "err_count": 1, + "all_count": 3 + } + ] + }, + "get-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "obj_type", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "object" + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "dashboard", + "instance", + "alias", + "version", + "config", + "stage", + "project", + "group" + ] + }, + "obj_id": { + "type": "string", + "description": "Object ID" + }, + "is_deleted": { + "type": "string", + "deprecated": true + } + } + }, + "get-response-2": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "project_id": { + "type": "number", + "description": "Project ID" + }, + "stage_id": { + "type": "number", + "description": "Stage ID" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "owner_id": { + "type": "number", + "description": "Owner ID" + }, + "owner_title": { + "type": "string", + "description": "Owner name" + }, + "parent_id": { + "type": "number", + "description": "Parent object ID" + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + }, + "example-get-request-2": { + "ops": [ + { + "type": "get", + "obj": "object", + "obj_type": "conv", + "obj_id": 1046408 + } + ] + }, + "example-get-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "project_id": 328948, + "stage_id": 328950, + "company_id": "i702619617", + "owner_id": 25130, + "parent_id": 328950, + "owner_title": "Jane Doe", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "create-request-18": { + "type": "object", + "required": [ + "type", + "obj", + "company_id", + "alias_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "callback_hash" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "alias_id": { + "type": "integer", + "description": "Alias ID" + } + } + }, + "create-response-18": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "callback_hash": { + "type": "string", + "description": "Callback hash" + } + } + }, + "modify-request-15": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "callback_hash" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_type": { + "type": "integer", + "description": "Object type
To re-enable a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
", + "enum": [ + "alias" + ] + }, + "alias_id": { + "type": "integer", + "description": "Alias ID
To re-enable a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
" + } + } + }, + "modify-response-15": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "callback_hash": { + "type": "string", + "description": "Callback hash" + } + } + }, + "get-request-3": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "callback_hash" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_type": { + "type": "integer", + "description": "Object type
To get a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
", + "enum": [ + "alias" + ] + }, + "alias_id": { + "type": "integer", + "description": "Alias ID
To get a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
" + } + } + }, + "get-response-3": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "callback_hash": { + "type": "string", + "description": "Callback hash" + } + } + }, + "delete-request-15": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "callback_hash" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_type": { + "type": "integer", + "description": "Object type
To disable a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
", + "enum": [ + "alias" + ] + }, + "alias_id": { + "type": "integer", + "description": "Alias ID
To disable a direct URL for aliases, you need to send 'obj_type' and 'alias_id' instead of 'conv_id'.
" + } + } + }, + "delete-response-15": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "enum": [ + "alias_callback_hash" + ] + } + } + }, + "example-create-request-17": { + "ops": [ + { + "type": "create", + "obj": "callback_hash", + "alias_id": 53788, + "company_id": "i702619617" + } + ] + }, + "example-create-response-17": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "callback_hash": "08df834bbebc682c30df165967af119606fb6a90" + } + ] + }, + "example-modify-request-14": { + "ops": [ + { + "type": "modify", + "obj": "callback_hash", + "conv_id": 1004237 + } + ] + }, + "example-modify-response-15": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 1004237, + "callback_hash": "813b6127ab22584d28e9032612e75f09a2dd71e9" + } + ] + }, + "example-modify-request-alias": { + "ops": [ + { + "type": "modify", + "obj": "callback_hash", + "alias_id": 53546, + "obj_type": "alias", + "company_id": "i702619617" + } + ] + }, + "example-modify-response-alias": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "callback_hash": "6336acee43c1dad05ae91a1e84f33b68e83972f2" + } + ] + }, + "example-get-request-3": { + "ops": [ + { + "conv_id": 1004237, + "type": "get", + "obj": "callback_hash", + "company_id": "i702619617" + } + ] + }, + "example-get-request-alias": { + "ops": [ + { + "alias_id": 53789, + "obj_type": "alias", + "type": "get", + "obj": "callback_hash", + "company_id": "i702619617" + } + ] + }, + "example-get-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "callback_hash": "0cf3c1e9eee96859dbd68bd7fcc22ed66bee7531" + } + ] + }, + "example-delete-request-15": { + "ops": [ + { + "type": "delete", + "obj": "callback_hash", + "conv_id": 1004237 + } + ] + }, + "example-delete-response-15": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "conv_id": 1004237 + } + ] + }, + "example-delete-request-alias": { + "ops": [ + { + "type": "delete", + "obj": "callback_hash", + "alias_id": 53546, + "obj_type": "alias", + "company_id": "i702619617" + } + ] + }, + "example-delete-response-alias": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "type": "delete", + "obj": "alias_callback_hash", + "proc": "ok" + } + ] + }, + "create-request-19": { + "type": "object", + "required": [ + "type", + "obj", + "company_id", + "dashboard_id", + "obj_type", + "name", + "series" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "name": { + "type": "string", + "minLength": 1, + "maxLength": 250, + "description": "Chart name" + }, + "description": { + "type": "string", + "description": "Chart description" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_type": { + "type": "string", + "description": "Chart type", + "enum": [ + "table", + "funnel", + "column", + "pie" + ] + }, + "series": { + "type": "array", + "description": "An array of nodes, which statistics you want to display.", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "ID of a Process or a State Diagram where the node is stored." + }, + "node_id": { + "type": "string", + "description": "ID of a node used for the Dashboard metric." + }, + "title": { + "type": "integer", + "description": "Title of a node, which is described in the Chart legend." + }, + "type_icon": { + "type": "string", + "description": "Type of node icon" + }, + "type_title": { + "type": "integer", + "description": "Node type title" + }, + "type": { + "type": "string", + "description": "Node type" + } + } + } + }, + "sort": { + "type": "boolean", + "description": "Identifier of the need for data sorting" + }, + "version": { + "type": "string", + "description": "Dashboard version" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of the chart" + } + } + }, + "create-response-19": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + } + } + }, + "modify-request-16": { + "type": "object", + "required": [ + "type", + "obj", + "dashboard_id", + "obj_id", + "name", + "series", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "name": { + "type": "string", + "minLength": 1, + "maxLength": 250, + "description": "Chart name" + }, + "description": { + "type": "string", + "description": "Chart description" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_type": { + "type": "string", + "description": "Chart type", + "enum": [ + "table", + "funnel", + "column", + "pie" + ] + }, + "series": { + "type": "array", + "description": "An array of nodes, which statistics you want to display.", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "ID of a Process or a State Diagram where the node is stored." + }, + "node_id": { + "type": "string", + "description": "ID of a node used for the Dashboard metric." + }, + "title": { + "type": "integer", + "description": "Title of a node, which is described in the Chart legend." + }, + "type_icon": { + "type": "string", + "description": "Type of node icon" + }, + "type_title": { + "type": "integer", + "description": "Node type title" + }, + "type": { + "type": "string", + "description": "Node type" + } + } + } + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + }, + "sort": { + "type": "boolean", + "description": "Identifier of the need for data sorting" + }, + "version": { + "type": "string", + "description": "Dashboard version" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of the chart" + } + } + }, + "modify-response-16": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "obj_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "chart_id": { + "type": "string", + "description": "Chart ID" + } + } + }, + "get-request-4": { + "type": "object", + "required": [ + "type", + "obj", + "dashboard_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + } + } + }, + "get-response-4": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "name": { + "type": "string", + "description": "Chart name" + }, + "description": { + "type": "string", + "description": "Chart description" + }, + "obj_type": { + "type": "string", + "description": "Chart type", + "enum": [ + "table", + "funnel", + "column", + "pie" + ] + }, + "series": { + "type": "array", + "description": "An array of nodes, which statistics you want to display.", + "items": { + "type": "object", + "properties": { + "conv_id": { + "type": "integer", + "description": "ID of a Process or a State Diagram where the node is stored." + }, + "node_id": { + "type": "string", + "description": "ID of a node used for the Dashboard metric." + }, + "title": { + "type": "integer", + "description": "Title of a node which is described in the Chart legend." + }, + "type_icon": { + "type": "string", + "description": "Node icon type" + }, + "type_title": { + "type": "integer", + "description": "Title of a node type" + }, + "type": { + "type": "string", + "description": "Node type" + } + } + } + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + }, + "delete-request-16": { + "type": "object", + "required": [ + "type", + "obj", + "dashboard_id", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "version": { + "type": "string", + "description": "Dashboard version" + } + } + }, + "delete-response-16": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "chart" + }, + "obj_id": { + "type": "string", + "description": "Chart ID" + }, + "dashboard_id": { + "type": "integer", + "description": "Dashboard ID" + } + } + }, + "example-create-request-18": { + "ops": [ + { + "company_id": "i702619617", + "name": "New Chart", + "description": "Chart description", + "dashboard_id": 78155, + "type": "create", + "obj": "chart", + "sort": true, + "series": [], + "obj_type": "table" + } + ] + }, + "example-create-response-18": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "type": "create", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a32fd9094bab5de700595c" + } + ] + }, + "example-modify-request-15": { + "ops": [ + { + "type": "modify", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d", + "name": "New Chart", + "description": "", + "obj_type": "table", + "series": [ + { + "conv_id": 1004237, + "node_id": "635febcb56167c5cce007e42", + "title": "Start", + "type_icon": "start", + "type_title": "Start node", + "type": "node" + } + ], + "company_id": "i702619617" + } + ] + }, + "example-modify-response-16": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "chart", + "chart_id": "63a4142b094bab5de7006c4d", + "obj_id": 78155 + } + ] + }, + "example-get-request-4": { + "ops": [ + { + "type": "get", + "obj": "chart", + "company_id": "i702619617", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d" + } + ] + }, + "example-get-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "name": "New Chart", + "description": "", + "obj_type": "table", + "series": [], + "obj_id": "63a4142b094bab5de7006c4d", + "dashboard_id": 78155, + "company_id": "i702619617", + "privs": [ + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-delete-request-16": { + "ops": [ + { + "type": "delete", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d", + "company_id": "i702619617" + } + ] + }, + "example-delete-response-16": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "chart", + "dashboard_id": 78155, + "obj_id": "63a4142b094bab5de7006c4d" + } + ] + }, + "create-request-20": { + "type": "object", + "required": [ + "type", + "obj", + "version", + "conv_id", + "node_id", + "obj_id", + "obj_type", + "lang", + "code", + "repo", + "commit", + "script" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function_build" + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "node_id": { + "type": "string", + "description": "Git Call node ID" + }, + "obj_id": { + "type": "string", + "description": "Build ID" + }, + "lang": { + "type": "string", + "description": "Code programming language" + }, + "code": { + "type": "string", + "description": "Executable code" + }, + "repo": { + "type": "string", + "description": "A path to the repository, which code will be used in business logic" + }, + "commit": { + "type": "string", + "description": "Git tag, branch, or commit to check out before building" + }, + "script": { + "type": "string", + "description": "Command to build a deployable entity" + }, + "handler": { + "type": "string", + "description": "(Java only) - name of the class that implements the UsercodeHandler interface" + }, + "path": { + "type": "string", + "description": "A path to the file in repository" + } + } + }, + "create-response-20": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function_build" + ] + }, + "obj_id": { + "type": "string", + "description": "Build ID" + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + } + } + }, + "compile-request": { + "type": "object", + "required": [ + "type", + "obj", + "version", + "conv_id", + "node_id", + "obj_id", + "obj_type", + "lang", + "code", + "repo", + "commit", + "script" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "compile" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function" + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "node_id": { + "type": "string", + "description": "Git Call node ID" + }, + "lang": { + "type": "string", + "description": "Code programming language" + }, + "code": { + "type": "string", + "description": "Executable code" + }, + "repo": { + "type": "string", + "description": "A path to the repository, which code will be used in business logic" + }, + "commit": { + "type": "string", + "description": "Git tag, branch, or commit to check out before building" + }, + "script": { + "type": "string", + "description": "Command to build a deployable entity" + }, + "handler": { + "type": "string", + "description": "(Java only) - name of the class that implements UsercodeHandler interface" + }, + "path": { + "type": "string", + "description": "A path to the file in repository" + } + } + }, + "compile-response": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function" + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + } + } + }, + "get-request-5": { + "type": "object", + "required": [ + "type", + "obj", + "obj_type", + "conv_id", + "node_id", + "version" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function", + "function_build", + "ssh_key" + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "node_id": { + "type": "string", + "description": "Git Call node ID" + }, + "obj_id": { + "type": "string", + "description": "Build ID (for function_build)" + } + } + }, + "get-response-5": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function", + "function_build", + "ssh_key" + ] + }, + "version": { + "type": "integer", + "description": "Git call version", + "enum": [ + 2 + ] + }, + "lang": { + "type": "string", + "description": "Code programming language" + }, + "code": { + "type": "string", + "description": "Executable code" + }, + "repo": { + "type": "string", + "description": "A path to the repository, which code will be used in business logic" + }, + "commit": { + "type": "string", + "description": "Git tag, branch, or commit to check out before building" + }, + "script": { + "type": "string", + "description": "Command to build a deployable entity" + }, + "obj_id": { + "type": "string", + "description": "Build ID" + }, + "build_status": { + "type": "string", + "description": "Build status
this response parameter is present only if obj_type = function_build", + "enum": [ + "done", + "not_found" + ] + }, + "public_key": { + "type": "string", + "description": "SSH key
this response parameter is present only if obj_type = ssh_key" + } + } + }, + "load-request": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "node_id", + "version", + "obj_type", + "lang", + "code", + "repo", + "commit", + "script" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "load" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function" + ] + }, + "version": { + "type": "integer", + "description": "Git call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "node_id": { + "type": "string", + "description": "Git Call node ID" + }, + "lang": { + "type": "string", + "description": "Code programming language" + }, + "code": { + "type": "string", + "description": "Executable code" + }, + "repo": { + "type": "string", + "description": "A path to the repository, which code will be used in business logic" + }, + "commit": { + "type": "string", + "description": "Git tag, branch, or commit to check out before building" + }, + "script": { + "type": "string", + "description": "Command to build a deployable entity" + }, + "handler": { + "type": "string", + "description": "(Java only) - name of the class that implements the UsercodeHandler interface" + }, + "path": { + "type": "string", + "description": "A path to the file in repository" + } + } + }, + "load-response": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "function" + ] + }, + "version": { + "type": "integer", + "description": "Git call version", + "enum": [ + 2 + ] + } + } + }, + "clone-request": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "from_node_id", + "to_node_id", + "version" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "clone" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "from_node_id": { + "type": "string", + "description": "Node from which Git Call basic settings need to be cloned" + }, + "to_node_id": { + "type": "string", + "description": "Node to which Git Call basic settings need to be cloned" + } + } + }, + "clone-response": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + } + } + }, + "reset-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "version", + "obj_type", + "node_id", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "reset" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "ssh_key" + ] + }, + "version": { + "type": "integer", + "description": "Git call version", + "enum": [ + 2 + ] + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Git Call node" + }, + "node_id": { + "type": "string", + "description": "Git Call node ID" + } + } + }, + "reset-response-2": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "git_call" + }, + "obj_type": { + "type": "string", + "description": "Command type", + "enum": [ + "ssh_key" + ] + }, + "version": { + "type": "integer", + "description": "Git Call version", + "enum": [ + 2 + ] + }, + "public_key": { + "type": "string", + "description": "SSH key" + } + } + }, + "example-create-request-19": { + "ops": [ + { + "type": "create", + "obj": "git_call", + "obj_type": "function_build", + "version": 2, + "conv_id": 1049340, + "node_id": "63a470de094bab6439004a92", + "obj_id": "ry78ws22w469s3", + "lang": "js", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "repo": "https://github.com/test/test.git", + "commit": "main", + "script": "" + } + ] + }, + "example-create-response-19": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "git_call", + "obj_type": "function_build", + "obj_id": "ry78ws22w469s3", + "version": 2, + "proc": "ok" + } + ] + }, + "example-compile-request": { + "ops": [ + { + "node_id": "63a470de094bab6439004a92", + "conv_id": 1049340, + "lang": "js", + "repo": "https://github.com/test/test.git", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "script": "", + "commit": "main", + "type": "compile", + "version": 2, + "obj": "git_call", + "obj_type": "function" + } + ] + }, + "example-compile-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2 + } + ] + }, + "example-get-request-5": { + "ops": [ + { + "type": "get", + "obj": "git_call", + "obj_type": "function", + "conv_id": 1049340, + "node_id": "63a470de094bab6439004a92", + "version": 2 + } + ] + }, + "example-get-response-function": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2, + "lang": "js", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "repo": "https://github.com/fresco117/test.git", + "commit": "main", + "script": "" + } + ] + }, + "example-get-response-function_build": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function_build", + "obj_id": "ry78ws22w4d69s3", + "version": 2, + "build_status": "done" + } + ] + }, + "example-get-response-ssh_key": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDNowYVpf0dceT3mOyFySheHUw3CcOFKKKRDDMSrF6s42WV0pp0v4y+J65LYzxlVskQ934CzU8DOpQG6PzXnmDM4tm05p4iSkvQWib+Im3P69oDSE2VJNXh2eqto8GYa3sgx15RbRAV3BrW4mi0hnhSnTKNsCq5ODvTRP/AN/S1nIVWJL2CBpXFij/Fkk93L5Eqi1AzrDdUuYmiqXzyDqD5WqCv5SYyfM7cHzfVNFUheStMkubL+O9CIg7+EbJGKAASPE3EUBvS57NIPrcQ6ecsK9+QmMwGGBbqsGRjmKKMnobEMFZzR9uhwrUkA8K+YG59+VU59nFkKN6dGS63ACVD\n" + } + ] + }, + "example-load-request": { + "ops": [ + { + "type": "load", + "obj": "git_call", + "conv_id": 1049341, + "version": 2, + "obj_type": "function", + "node_id": "63a474c6094bab6439004a9b", + "lang": "js", + "repo": "", + "code": "module.exports = (data) => {data.a = 1234; return data;};", + "script": "", + "commit": "" + } + ] + }, + "example-load-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "function", + "version": 2 + } + ] + }, + "example-clone-request": { + "ops": [ + { + "type": "clone", + "obj": "git_call", + "conv_id": 1049340, + "from_node_id": "63a470de094bab6439004a92", + "to_node_id": "63a4709756167c68f4004a9f", + "version": 2 + } + ] + }, + "example-clone-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok" + } + ] + }, + "example-reset-request-2": { + "ops": [ + { + "type": "reset", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "node_id": "63a470de094bab6439004a92", + "conv_id": 1049340 + } + ] + }, + "example-reset-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "git_call", + "obj_type": "ssh_key", + "version": 2, + "public_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDxKPyqHLSfNQ6Uj3t9vcdQ2onV+HFMD6tMI60Cb99N+RyATj1LodjcJLRHJhpapqYCbndHidkF7prs+7wHW396jmE+U5/PCRfkgGHYRlpDCcmc6Cw6UWl/7lLjCCpJG+tyD87lkXCpjyephSNjYPyVP3iw+h2iOtdzvRH6SmkVqmC78yKZVp00qkNQG52TWUI7MYuwjaosjjYRKLU1Pd2anL7C9GUaUaInAabCqHV7zVay+60wbGOw/pm0+CuWl4ixAcpDMH1iNxMcRLIwiuIV9O+YEJ94dnM7Cfcl4P3gLMUb1wWR6EKFBvL28JfVsOlPlrHwBbi3UpIDzcVvOqdP\n" + } + ] + }, + "get-request-6": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard" + ], + "description": "Object type:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard" + } + } + }, + "get-response-6": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "scheme": { + "type": "array", + "description": "An array of object schemes", + "items": { + "type": "object", + "properties": { + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2 + ], + "description": "Object type:
`0` — Folder
`1` — Process / State diagram
`2` — Dashboard" + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "parent_id": { + "type": "integer", + "description": "Parent Folder ID" + }, + "title": { + "type": "string", + "description": "Object title" + }, + "description": { + "type": "string", + "description": "Object description" + }, + "status": { + "type": "string", + "description": "Object state", + "enum": [ + "active", + "paused", + "deleted", + "blocked", + "debug" + ] + }, + "params": { + "type": "array", + "description": "An array with all Task params described as JSON" + }, + "ref_mask": { + "type": "boolean", + "description": "Task references masking enabled or disabled" + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state", + "escalation" + ], + "description": "Type of an Object:
`process` — Process
`state` — State diagram
this response parameter exists when the response parameter 'obj_type' = \"conv\"" + }, + "scheme": { + "type": "object", + "description": "Process scheme", + "properties": { + "nodes": { + "type": "array", + "description": "An array of nodes", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Node ID" + }, + "obj_type": { + "type": "integer", + "enum": [ + 0, + 1, + 2, + 3 + ], + "description": "Node type:
`0` — normal - logic node
`1` — start node
`2` — final node
`3` — escalation - special system node
" + }, + "condition": { + "type": "object", + "properties": { + "logics": { + "allOf": [ + { + "$ref": "#/components/schemas/logics" + } + ] + }, + "semaphors": { + "allOf": [ + { + "$ref": "#/components/schemas/semaphors" + } + ] + } + } + }, + "title": { + "type": "string", + "description": "Node title" + }, + "description": { + "type": "string", + "description": "Node description" + }, + "x": { + "type": "integer", + "description": "Coordinates of the node left upper corner along the X axis with respect to the 0:0 reference point in the process field coordinates" + }, + "y": { + "type": "integer", + "description": "Coordinates of the node left upper corner along the Y axis with respect to the 0:0 reference point in the process field coordinates" + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object

example: \"1c228d39-1d16-4b98-980e-cd784738ee90\"" + }, + "extra": { + "type": "object", + "nullable": true, + "description": "A stringify object of additional node settings (expand or minimize, node icon) — modeForm, icon:
modeForm — Node view mode: collapse (collapsed view) / expand (expanded view);
icon — Icon for the final node success (green) / error (red). For all the other nodes - \"icon\":\"\".
example: \"{\\\\\"modeForm\\\\\":\\\\\"collapse\\\\\",\\\\\"icon\\\\\":\\\\\"success\\\\\"}\"" + }, + "options": { + "type": "string with JSON", + "nullable": true, + "description": "A stringify object of the save_task additional node setting;
example: \"{\\\\\"save_task\\\\\":true}\"" + } + } + } + }, + "web_settings": { + "type": "array", + "deprecated": true + } + } + }, + "uuid": { + "type": "string", + "description": "Universally Unique Identifier of an object" + } + } + } + } + } + }, + "check-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "check" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + }, + "obj_id": { + "type": "integer", + "description": "Object ID" + }, + "obj_type": { + "type": "string", + "enum": [ + "folder", + "conv", + "dashboard" + ], + "description": "Object type:
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard" + } + } + }, + "check-response-2": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "obj_scheme" + } + } + }, + "example-get-request-6": { + "ops": [ + { + "type": "get", + "obj": "obj_scheme", + "obj_id": 1004237, + "obj_type": "conv" + } + ] + }, + "example-get-response-5": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "obj_scheme", + "proc": "ok", + "scheme": [ + { + "obj_type": 1, + "obj_id": 1004237, + "parent_id": 372755, + "title": "1", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "process", + "scheme": { + "nodes": [ + { + "id": "65f98fcc094bab7ab30000ee", + "obj_type": 1, + "condition": { + "logics": [ + { + "to_node_id": "65f98fcc094bab7ab30000ef", + "type": "go" + } + ], + "semaphors": [] + }, + "title": "start", + "description": "", + "x": 0, + "y": 0, + "uuid": "f831ef9d-5605-4b34-9516-38653b6a36cc", + "extra": null, + "options": null + }, + { + "id": "65f98fcc094bab7ab30000ef", + "obj_type": 0, + "condition": { + "logics": [], + "semaphors": [ + { + "type": "time", + "value": 30, + "dimension": "sec", + "to_node_id": "65f98fcc094bab7ab30000f0" + } + ] + }, + "title": "process", + "description": "", + "x": 0, + "y": 0, + "uuid": "8c8eb7fe-cfe4-4f51-9b17-4cc57fb30e42", + "extra": null, + "options": null + }, + { + "id": "65f98fcc094bab7ab30000f0", + "obj_type": 2, + "condition": { + "logics": [], + "semaphors": [] + }, + "title": "final", + "description": "", + "x": 0, + "y": 0, + "uuid": "d43cba48-9a54-4a42-80ce-6186c90596d2", + "extra": null, + "options": null + } + ], + "web_settings": [ + [], + [] + ] + }, + "uuid": "ffc58fa2-69c6-4e08-ba88-636d0783c622" + } + ] + } + ] + }, + "example-check-request-2": { + "ops": [ + { + "type": "check", + "obj": "obj_scheme", + "obj_id": 263144, + "obj_type": "folder" + } + ] + }, + "example-check-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "obj_scheme", + "proc": "ok" + } + ] + }, + "example-check-response-error": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "error", + "description": "The process with ID 1049340 has an uncommitted version" + } + ] + }, + "show-request-16": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_key" + }, + "obj_id": { + "type": "integer", + "description": "Process / State Diagram ID" + } + } + }, + "show-response-17": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "api_key" + }, + "title": { + "type": "string", + "description": "API key title" + }, + "login": { + "type": "integer", + "description": "API key" + }, + "key": { + "type": "string", + "description": "API key secret" + }, + "obj_id": { + "type": "integer", + "description": "API key ID" + } + } + }, + "example-show-request-15": { + "ops": [ + { + "obj": "api_key", + "type": "show", + "obj_id": 1020531 + } + ] + }, + "example-show-response-14": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "title": "first_2", + "login": 29595, + "key": "wB12nFmNBI0oOSMU3HklYOyZw9mYigezFfDnz1xCDfKwqwFN", + "obj_id": 28288 + } + ] + }, + "stop-request": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "hash", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "upload" + }, + "hash": { + "type": "string", + "description": "Hash", + "minLength": 1, + "maxLength": 1000 + }, + "obj_type": { + "type": "string", + "description": "Uploaded object type", + "enum": [ + "obj_scheme", + "task" + ] + } + } + }, + "stop-response": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "upload" + } + } + }, + "example-stop-request": { + "ops": [ + { + "obj": "upload", + "type": "stop", + "hash": "83680364000C72...5896094BAB63B8000197", + "obj_type": "obj_scheme" + } + ] + }, + "example-stop-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "upload" + } + ] + }, + "list-request-22": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "pattern" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "objs" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "pattern": { + "type": "string", + "minLength": 3, + "maxLength": 150, + "description": "Search expression" + }, + "filter": { + "type": "string", + "description": "Search area", + "enum": [ + "user", + "company", + "conv" + ] + }, + "limit": { + "type": "integer", + "minimum": 1, + "maximum": 1000, + "description": "Defines the maximum number of objects in the response" + }, + "user_type": { + "type": "string", + "description": "User type additional parameter if request parameter 'filter' = \"user\"", + "enum": [ + "user", + "api" + ] + }, + "only_owner": { + "type": "boolean", + "description": "H" + } + } + }, + "list-response-22": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "objs" + }, + "list": { + "type": "array", + "description": "Search results", + "items": { + "type": "object", + "properties": { + "obj_type": { + "type": "string", + "description": "The type of object found" + }, + "obj_id": { + "type": "integer", + "description": "ID of object found" + }, + "folder_id": { + "type": "string", + "description": "Parent Folder ID (Folder where a Process / State diagram is stored)" + }, + "create_time": { + "type": "timestamp", + "description": "Timestamp of object creation" + }, + "change_time": { + "type": "timestamp", + "description": "Timestamp of object last change" + }, + "status": { + "type": "string", + "description": "Object state:
\n `1` active
\n `2` paused
\n `3` deleted
\n `4` blocked
\n `5` debug
" + }, + "conv_type": { + "type": "string", + "enum": [ + "process", + "state", + "escalation" + ], + "description": "Type of an object we are listing:
`process` — Process
`state` — State diagram
`escalation` — deprecated (special system process, designed to handle Process / State diagram errors)" + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as object owner ID" + }, + "owner_id": { + "type": "с", + "description": "Object owner ID" + }, + "owner_name": { + "type": "string", + "description": "Object owner name" + }, + "owner_login": { + "type": "string", + "description": "Object owner login" + }, + "title": { + "type": "string", + "description": "Object title" + }, + "description": { + "type": "string", + "description": "Object description" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "logins": { + "type": "array", + "description": "Logins array", + "items": { + "type": "object", + "properties": { + "login": { + "type": "string", + "description": "Login" + }, + "obj_id": { + "type": "string", + "description": "ID of Login" + }, + "type": { + "type": "string", + "description": "Type of login", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "oauth_pb", + "phone", + "corezoid", + "github", + "apple", + "keycloak" + ] + } + } + } + }, + "companies": { + "type": "array", + "description": "Array of companies where users are found" + } + } + } + } + } + }, + "example-list-request-22": { + "ops": [ + { + "pattern": "api", + "obj": "objs", + "filter": "conv", + "limit": 31, + "company_id": "i702619617", + "type": "list" + } + ] + }, + "example-list-response-20": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "conv", + "obj_id": 1020531, + "folder_id": 0, + "create_time": 1669121177, + "change_time": 1669123882, + "status": 1, + "conv_type": "process", + "is_owner": true, + "owner_name": "Daria Grek 2", + "owner_login": "darja.grek@corezoid.com", + "owner_id": 25130, + "title": "api_gw", + "description": "", + "company_id": "i702619617" + } + ] + } + ] + }, + "example-list-response-user-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "user", + "obj_id": 37924, + "create_time": "undefined", + "status": 1, + "type": "api", + "owner_id": 25130, + "logins": [ + { + "login": "635f98b7094bab1444007d1a", + "obj_id": 38660, + "type": "api" + } + ], + "companies": [ + "i702619617" + ], + "title": "seven" + } + ] + } + ] + }, + "example-list-response-user-company": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj": "objs", + "proc": "ok", + "list": [ + { + "obj_type": "company", + "obj_id": "i69339591195", + "create_time": 1477059927, + "status": 1, + "title": "Test_offline" + } + ] + } + ] + }, + "show-request-17": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "global_counters" + } + } + }, + "show-response-18": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "ops": { + "type": "array", + "description": "The list of the request results", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Operation type", + "enum": [ + "monitor_show" + ] + }, + "obj": { + "type": "string", + "description": "The type of an object on which the operation is performed", + "enum": [ + "main" + ] + }, + "obj_id": { + "type": "integer", + "enum": [ + 0 + ] + }, + "proc": { + "type": "string", + "description": "The processing status of a specific operation" + }, + "list": { + "type": "array", + "items": { + "type": "object", + "properties": { + "obj": { + "type": "string", + "description": "Counter type", + "enum": [ + "users", + "conveyors", + "operations", + "tacts" + ] + }, + "count": { + "type": "integer", + "description": "Counter value" + } + } + } + } + } + } + } + } + }, + "example-show-request-16": { + "ops": [ + { + "obj": "global_counters", + "type": "show" + } + ] + }, + "example-show-response-15": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "request_proc": "ok", + "ops": [ + { + "type": "monitor_show", + "obj": "main", + "obj_id": 0, + "proc": "ok", + "list": [ + { + "obj": "users", + "count": 222 + }, + { + "obj": "conveyors", + "count": 196004 + }, + { + "obj": "operations", + "count": 2849826848 + }, + { + "obj": "tacts", + "count": 8696682558 + } + ] + } + ] + } + ] + }, + "example-show-response-16": { + "result": "ok", + "box_solution": false, + "type_logins": [ + "api", + "saml", + "corezoid", + "google" + ], + "auth_providers": [], + "web_settings": { + "feedback_url": "https://admin-pre.corezoid.com/api/1/json/public/310717/ead74ebd947397307015644ae98c74773201aaf9", + "env": "pre", + "host": { + "site": "pre.corezoid.com", + "doc": "doc.corezoid.com", + "ws": "ws-pre.corezoid.com", + "webhook": "pre.corezoid.com", + "auth": "admin-pre.corezoid.com", + "single_account": "account.pre.corezoid.com" + }, + "path": { + "api": "/api/2/json", + "upload": "/api/2/upload", + "download": "/api/2/download", + "ws": "/api/1/sock_json", + "webhook": "/api/2/", + "auth": "/auth2/single_account", + "base_path": "/account", + "compare": "/api/2/compare", + "superadmin": "/superadmin", + "merge": "/api/2/merge", + "doc": { + "index": "/docs", + "introduction": "/introduction", + "bot_platform": "/bot-platform-20", + "task_export": "/tasks-export", + "mask_values": "/task-parameters#masking-values" + } + }, + "sender": { + "host": "builder.pre.sender.mobi", + "path": { + "embed": "/embed.js?", + "builder": "/builder.html" + } + }, + "captcha": { + "provider": "recaptcha", + "key": "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI", + "disabled": false + }, + "stripe": { + "key": "pk_test_xvUkvKX7lQSty7oV9OoSCDQZ", + "client_id": "ca_9jNyRtcRhl89JluE5MiaHolu49S5i6uM" + }, + "whitelist": [ + "corezoid.com", + "control.events" + ], + "ui": { + "company": true, + "bot_platform": true, + "old_editor": true, + "health": true, + "send_invite": true, + "search": true, + "billing": true, + "default_company": "My Corezoid", + "show_welcome_notify": true, + "tab_name": "Corezoid - cloud operating system", + "features": [ + "merge" + ], + "api_call": { + "send_sys": true, + "default_max_thread": 11 + }, + "save_archive_tasks": true + }, + "password_policy": { + "min_length": 10, + "max_length": 30, + "lowercase": true, + "uppercase": true, + "number": true, + "special": true + } + }, + "auth_single_account": true, + "first_day_of_week": "mon", + "multitenancy": false, + "components": [ + "git_call", + "db_call", + "es" + ], + "max_versions_per_projects": 10, + "max_login_attempts_strategy": "lock", + "user_downloads": { + "max_throughput": 100000 + }, + "database_active_list": [ + "postgres", + "mysql", + "mssql", + "mongo", + "oracle" + ], + "companies_manager": "single_space", + "billing_manager": "single_space" + }, + "create-request-21": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "messengers" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "bot_wizzard" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "messengers": { + "type": "array", + "description": "connect messengers", + "items": { + "type": "object", + "properties": { + "channel": { + "type": "string", + "description": "Messenger name", + "enum": [ + "abc", + "viber", + "fbmessenger", + "telegram" + ] + }, + "key": { + "type": "string", + "description": "Access token" + } + } + } + }, + "lang": { + "type": "string", + "description": "Conversation language", + "enum": [ + "en" + ] + }, + "version": { + "type": "string", + "description": "Bot version", + "enum": [ + 2 + ] + }, + "async": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Asynchronous request execution method" + }, + "project_id": { + "type": "integer", + "description": "Project ID
If a new bot is being created in a stage, you must also send the 'stage_id' and 'project_id'." + }, + "stage_id": { + "type": "integer", + "description": "Stage ID
If a new bot is being created in a stage, you must also send the 'stage_id' and 'project_id'." + } + } + }, + "create-response-21": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "bot_wizzard" + }, + "obj_id": { + "type": "string", + "description": "ID for checking the result of creating a bot" + }, + "result": { + "type": "string", + "description": "Opertion result" + }, + "dashboard_url": { + "type": "string", + "description": "Operation result" + }, + "folder_url": { + "type": "string", + "description": "Bot folder URL" + }, + "webhooks_url": { + "type": "array", + "description": "Webhook URLs", + "items": { + "type": "object", + "properties": { + "channel": { + "type": "string", + "description": "Messenger name", + "enum": [ + "abc", + "viber", + "fbmessenger", + "telegram", + "slack" + ] + }, + "url": { + "type": "string", + "description": "Channel URL" + } + } + } + } + } + }, + "modify-request-17": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "bot_wizzard" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "ID for checking the result of creating a bot" + } + } + }, + "modify-response-17": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "bot_wizzard" + } + } + }, + "check-request-3": { + "type": "object", + "title": "check", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "check" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "bot_wizzard" + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "ID for checking the result of creating a bot" + } + } + }, + "check-response-3": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "bot_wizzard" + }, + "dashboard_url": { + "type": "string", + "description": "Result of operation" + }, + "folder_url": { + "type": "string", + "description": "Bot folder URL" + }, + "webhooks_url": { + "type": "array", + "description": "Webhook URLs", + "items": { + "type": "object", + "properties": { + "channel": { + "type": "string", + "description": "Messenger name", + "enum": [ + "abc", + "viber", + "fbmessenger", + "telegram", + "slack" + ] + }, + "url": { + "type": "string", + "description": "Channel URL" + } + } + } + }, + "result": { + "type": "string", + "description": "Operation result" + }, + "description": { + "type": "string", + "description": "Result description" + } + } + }, + "example-create-request-20": { + "ops": [ + { + "messengers": [ + { + "channel": "telegram", + "key": "test" + } + ], + "company_id": "i702619617", + "project_id": 372753, + "stage_id": 372755, + "lang": "en", + "version": 2, + "type": "create", + "obj": "bot_wizzard", + "async": true + } + ] + }, + "example-create-response-async-true": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "result": "queued", + "obj_id": "66c6e9e1ae906a59ac002889" + } + ] + }, + "example-create-response-async-false": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "dashboard_url": "", + "folder_url": "https://admin-pre.corezoid.com/folder/606644", + "webhooks_url": [ + { + "channel": "fbmessenger", + "url": "" + }, + { + "channel": "skype", + "url": "" + } + ], + "result": "ok", + "description": "undefined" + } + ] + }, + "example-modify-request-16": { + "ops": [ + { + "type": "modify", + "obj": "bot_wizzard", + "obj_id": "658a87c056167c03140034c8", + "company_id": "20c4e4a1-0f0c-4c32-a6f2-ee12b5fa5d80" + } + ] + }, + "example-modify-response-17": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard" + } + ] + }, + "example-check-request-3": { + "ops": [ + { + "obj_id": "63add73c094bab791f001b44", + "obj": "bot_wizzard", + "type": "check" + } + ] + }, + "example-check-response-3": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "bot_wizzard", + "dashboard_url": "", + "folder_url": "https://admin-pre.corezoid.com/folder/795598", + "webhooks_url": [ + { + "channel": "fbmessenger", + "url": "" + }, + { + "channel": "skype", + "url": "" + } + ], + "result": "ok", + "description": "undefined" + } + ] + }, + "create-request-22": { + "type": "object", + "title": "create", + "required": [ + "type", + "obj", + "obj_type", + "token" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "channel" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_type": { + "type": "string", + "description": "Messenger type", + "enum": [ + "viber", + "fbmessenger", + "telegram", + "slack" + ] + }, + "env": { + "type": "string", + "description": "Environment name" + }, + "token": { + "type": "string", + "description": "Access token" + }, + "callback_hash": { + "type": "string", + "description": "Callback hash", + "minLength": 40, + "maxLength": 40 + }, + "conv_id": { + "type": "integer", + "description": "ID conv" + }, + "folder_id": { + "type": "integer", + "description": "ID folder" + } + } + }, + "create-response-22": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "channel" + }, + "obj_type": { + "type": "string", + "description": "Messenger type", + "enum": [ + "viber", + "fbmessenger", + "telegram", + "slack" + ] + } + } + }, + "modify-request-18": { + "type": "object", + "title": "modify", + "required": [ + "type", + "obj", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "channel" + }, + "company_id": { + "allOf": [ + { + "$ref": "#/components/schemas/company_id" + } + ] + }, + "obj_type": { + "type": "string", + "description": "Messenger type", + "enum": [ + "viber", + "fbmessenger", + "telegram", + "slack" + ] + }, + "obj_id": { + "type": "string", + "minLength": 24, + "maxLength": 24, + "description": "Task internal ID" + }, + "description": { + "type": "string" + }, + "result": { + "type": "string", + "enum": [ + "ok", + "error" + ] + } + } + }, + "modify-response-18": { + "type": "object", + "title": "modify", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "channel" + } + } + }, + "example-create-request-21": { + "ops": [ + { + "obj_type": "viber", + "env": "front", + "conv_id": 1324888, + "folder_id": 520385, + "company_id": "i178661175", + "token": "test", + "type": "create", + "obj": "channel" + } + ] + }, + "example-create-response-20": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "channel", + "obj_type": "viber" + } + ] + }, + "example-modify-request-17": { + "ops": [ + { + "obj_type": "telegram", + "env": "front", + "token": "1041341718:AAHDE55An5dXWNbXpOhzSfHgczRS7UlUbCg", + "obj_id": "63bc1cd7094bab0422001d6b", + "callback_hash": "bcbc26389384009c920f0cf9ecaadf7ba2427694", + "type": "modify", + "obj": "channel", + "result": "error", + "description": "test" + } + ] + }, + "example-modify-response-18": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "channel" + } + ] + }, + "get-request-7": { + "type": "object", + "title": "get", + "required": [ + "type", + "obj", + "obj_id", + "obj_type", + "login", + "login_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "privs" + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "dashboard" + ] + }, + "obj_id": { + "type": "string", + "description": "Object ID" + }, + "login": { + "type": "string", + "description": "User login" + }, + "login_type": { + "type": "string", + "description": "Login type", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "phone", + "corezoid" + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + }, + "get-response-7": { + "type": "object", + "title": "get", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "privs" + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "dashboard" + ] + }, + "obj_id": { + "type": "string", + "description": "Object ID" + }, + "login": { + "type": "string", + "description": "User login" + }, + "login_type": { + "type": "string", + "description": "Login type", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "phone", + "corezoid" + ] + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs_items" + } + ] + } + } + }, + "show-request-18": { + "type": "object", + "title": "show", + "required": [ + "type", + "obj", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "privs" + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "dashboard", + "expert_system", + "instance", + "version", + "config", + "stage", + "project" + ] + }, + "obj_id": { + "type": "string", + "description": "Object ID" + } + } + }, + "show-response-19": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "result": { + "type": "string", + "description": "User access for object", + "enum": [ + "allow", + "disallow" + ] + } + } + }, + "check-request-4": { + "type": "object", + "title": "check", + "required": [ + "type", + "obj", + "obj_id", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "check" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "privs" + }, + "obj_type": { + "type": "string", + "description": "Object type", + "enum": [ + "conv", + "folder", + "dashboard", + "expert_system", + "instance", + "version", + "config", + "stage", + "project", + "company" + ] + }, + "obj_id": { + "type": "string", + "description": "Object ID" + } + } + }, + "check-response-4": { + "type": "object", + "title": "check", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "result": { + "type": "string", + "description": "User access to an object", + "enum": [ + "allow", + "disallow" + ] + } + } + }, + "example-get-request-7": { + "ops": [ + { + "type": "get", + "obj": "privs", + "obj_id": 847680, + "obj_type": "conv", + "login": "jane.doe@email.com", + "login_type": "corezoid", + "privs": [ + "create", + "view" + ] + } + ] + }, + "example-get-response-6": { + "ops": [ + { + "type": "get", + "obj": "privs", + "obj_id": 847680, + "obj_type": "conv", + "login": "jane.doe@email.com", + "login_type": "corezoid", + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + } + ] + } + ] + }, + "example-show-request-17": { + "ops": [ + { + "type": "show", + "obj": "privs", + "obj_id": 847680, + "obj_type": "conv" + } + ] + }, + "example-show-response-17": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "result": "allow" + } + ] + }, + "example-check-request-4": { + "ops": [ + { + "type": "check", + "obj": "privs", + "obj_id": 1123157, + "obj_type": "conv" + } + ] + }, + "example-check-response-4": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "result": "allow" + } + ] + }, + "list-request-23": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "name" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "users" + }, + "name": { + "type": "string", + "description": "Parameter for searching for a user by user name or login" + } + } + }, + "list-response-23": { + "type": "object", + "title": "list", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "users" + }, + "list": { + "type": "array", + "description": "List of searched for users", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "User ID" + }, + "title": { + "type": "string", + "description": "User name" + }, + "login": { + "type": "string", + "description": "User login" + } + } + } + } + } + }, + "example-list-request-23": { + "ops": [ + { + "type": "list", + "obj": "users", + "name": "Doe" + } + ] + }, + "example-list-response-21": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "users", + "list": [ + { + "obj_id": "21350", + "title": "Jane Doe", + "login": "jane.doe@email.com" + } + ] + } + ] + }, + "compile-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "version", + "conv_id", + "node_id", + "lang", + "src" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "compile" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Code node" + }, + "node_id": { + "type": "string", + "description": "Code node ID" + }, + "lang": { + "type": "string", + "description": "Code programming language", + "enum": [ + "js", + "erlang" + ] + }, + "src": { + "type": "string", + "minLength": 1, + "maxLength": 1000000000000, + "description": "Executable code" + } + } + }, + "compile-response-2": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "description": { + "type": "string", + "description": "Processing status details" + } + } + }, + "get-request-8": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "node_id", + "env" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Code node" + }, + "node_id": { + "type": "string", + "description": "Code node ID" + }, + "env": { + "type": "string", + "description": "Code node deployment state
`sandbox` - Code node with undeployed changes
`production` - Deployed Code node", + "enum": [ + "sandbox", + "production" + ] + } + } + }, + "get-response-8": { + "type": "object", + "title": "create", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "lang": { + "type": "string", + "description": "Code programming language", + "enum": [ + "js", + "erlang" + ] + }, + "src": { + "type": "string", + "description": "Executable code" + } + } + }, + "load-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "node_id", + "lang", + "src" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "load" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Code node" + }, + "node_id": { + "type": "string", + "description": "Code node ID" + }, + "lang": { + "type": "string", + "description": "Code programming language", + "enum": [ + "js", + "erlang" + ] + }, + "src": { + "type": "string", + "minLength": 1, + "maxLength": "infinity", + "description": "Executable code" + }, + "env": { + "type": "string", + "description": "Code node deployment state
`sandbox` - Code node with undeployed changes
`production` - Deployed Code node", + "enum": [ + "sandbox", + "production" + ] + } + } + }, + "load-response-2": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "description": { + "type": "string", + "description": "Processing status details" + } + } + }, + "clone-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "from_node_id", + "to_node_id", + "env" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "clone" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "api_code" + }, + "conv_id": { + "type": "integer", + "description": "ID of a Process containing the Code node" + }, + "from_node_id": { + "type": "string", + "description": "Node from which Code basic settings need to be cloned." + }, + "to_node_id": { + "type": "string", + "description": "Node to which Code basic settings need to be cloned." + }, + "env": { + "type": "string", + "description": "Code node deployment state
`sandbox` - Code node with undeployed changes
`production` - Deployed Code node", + "enum": [ + "sandbox", + "production" + ] + } + } + }, + "example-compile-request-2": { + "ops": [ + { + "obj": "api_code", + "type": "compile", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "lang": "js", + "src": "var one = 1;\nvar two = 2;" + } + ] + }, + "example-compile-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "description": "" + } + ] + }, + "example-get-request-8": { + "ops": [ + { + "type": "get", + "obj": "api_code", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "env": "production" + } + ] + }, + "example-get-response-7": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "lang": "js", + "src": "var one = 1;" + } + ] + }, + "example-load-request-2": { + "ops": [ + { + "type": "load", + "obj": "api_code", + "conv_id": 1123157, + "node_id": "6405a1eb56167c487b009654", + "lang": "js", + "src": "var one = 1;\nvar two = 2;", + "env": "sandbox" + } + ] + }, + "example-load-response-2": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "api_code", + "description": "" + } + ] + }, + "example-clone-request-2": { + "ops": [ + { + "obj": "api_code", + "type": "clone", + "conv_id": 1123157, + "from_node_id": "6405a1eb56167c487b009654", + "to_node_id": "642ae954094bab136c0075f1", + "env": "production" + } + ] + }, + "modify-request-19": { + "type": "object", + "title": "list", + "required": [ + "type", + "obj", + "obj_id", + "status", + "blocked_reason" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "user_status" + }, + "obj_id": { + "type": "integer", + "description": "User identifier" + }, + "obj_type": { + "type": "string", + "description": "Blocked/unblocked options
`user` — if you enable this option, only the user will be blocked/unblocked, but not the processes where they are the owner
`process` — If you enable this option, only the user's processes will be blocked/unblocked, but not the user themself
", + "enum": [ + "user", + "process" + ] + }, + "status": { + "type": "string", + "enum": [ + "actived", + "blocked" + ], + "description": "User status to be set" + }, + "blocked_reason": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Blocked reason description" + }, + "company_id": { + "type": "string", + "description": "ID of an existing Company.
If request send without parameter \"company_id\" user is block in instance
If request send with parameter \"company_id\" user is block only in this company/tenant" + } + } + }, + "modify-response-19": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "user_status" + }, + "obj_id": { + "type": "integer", + "description": "User identifier" + }, + "status": { + "type": "string", + "enum": [ + "actived", + "blocked" + ], + "description": "User status" + } + } + }, + "example-modify-request-18": { + "ops": [ + { + "type": "modify", + "obj": "user_status", + "obj_id": 45165, + "blocked_reason": "test", + "company_id": "i767978912", + "status": "blocked", + "obj_type": "user" + } + ] + }, + "example-modify-response-19": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "user_status", + "obj_id": 37923, + "status": "blocked" + } + ] + }, + "create-request-23": { + "type": "object", + "required": [ + "type", + "obj", + "title", + "short_name", + "value", + "env_var_type", + "company_id", + "stage_id", + "project_id", + "scopes" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "env_var_type": { + "type": "string", + "description": "Variable type
`secret` - Viewing the variable value is not available.
`visible` - Viewing the value of the variable is available to users who have access to the stage.
", + "enum": [ + "visible", + "secret" + ] + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Variable title" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "New variable description" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Variable key. Should be unique within the stage." + }, + "value": { + "type": "string", + "minLength": 3, + "maxLength": "SIZE_2MB", + "description": "Variable value" + }, + "data_type": { + "type": "string", + "description": "Type of variable data
`json` - json validation will be applied.
`raw` - The variable will be passed as a string.", + "enum": [ + "json", + "raw" + ], + "default": "raw" + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "nullable": true, + "description": "ID of an existing Company" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "scopes": { + "type": "array", + "description": "The list of nodes and their fields where env_var can be used.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Node type", + "enum": [ + "api_call", + "set_param" + ] + }, + "fields": { + "type": "array", + "description": "The list of node fields where env_var can be used.
`cert_pem, api_secret_outer` - for the apicall node.
`extra` - for the set parameters node.
`*` - all fields in a node.", + "enum": [ + "cert_pem", + "api_secret_outer", + "*", + "extra" + ] + } + } + } + } + } + }, + "create-response-23": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "number", + "description": "Variable ID" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "fingerprints": { + "type": "array", + "description": "list of cryptographic hash values", + "items": { + "type": "object", + "properties": { + "algo": { + "type": "string", + "description": "Mathematical algorithm", + "enum": [ + "md5", + "sha256" + ] + }, + "value": { + "type": "string", + "description": "Hash value" + } + } + } + } + } + }, + "modify-request-20": { + "type": "object", + "title": "get", + "required": [ + "type", + "obj", + "obj_id", + "short_name", + "env_var_type", + "stage_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "modify" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "obj_id": { + "type": "number", + "description": "Variable ID" + }, + "env_var_type": { + "type": "string", + "description": "Type of variable
`secret` - Viewing the variable value is not available.
`visible` - Viewing the value of the variable is available to users who have access to the stage.
", + "enum": [ + "visible", + "secret" + ] + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Variable title" + }, + "description": { + "type": "string", + "minLength": 0, + "maxLength": 2000, + "description": "Variable description" + }, + "short_name": { + "type": "string", + "minLength": 2, + "maxLength": 127, + "pattern": "^[a-z0-9-]*$", + "description": "Variable key. Should be unique within the stage." + }, + "value": { + "type": "string", + "minLength": 3, + "maxLength": "SIZE_2MB", + "description": "Variable value" + }, + "data_type": { + "type": "string", + "description": "Type of variable data
`json` - json validation will be applied.
`raw` - The variable will be passed as a string.", + "enum": [ + "json", + "raw" + ], + "default": "raw" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "scopes": { + "type": "array", + "description": "The list of nodes and their fields where env_var can be used.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Node type", + "enum": [ + "api_call", + "set_param" + ] + }, + "fields": { + "type": "array", + "description": "The list of node fields where env_var can be used.
`cert_pem, api_secret_outer` - for the apicall node.
`extra` - for the set parameters node.
`*` - all fields in a node.", + "enum": [ + "cert_pem", + "api_secret_outer", + "*", + "extra" + ] + } + } + } + } + } + }, + "modify-response-20": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "number", + "description": "Variable ID" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "fingerprints": { + "type": "array", + "description": "List of cryptographic hash values", + "items": { + "type": "object", + "properties": { + "algo": { + "type": "string", + "description": "Mathematical algorithm", + "enum": [ + "md5", + "sha256" + ] + }, + "value": { + "type": "string", + "description": "Hash value" + } + } + } + } + } + }, + "delete-request-17": { + "type": "object", + "title": "get", + "required": [ + "type", + "obj", + "obj_id", + "stage_id", + "project_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "obj_id": { + "type": "number", + "description": "Variable ID" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + } + } + }, + "delete-response-17": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "number", + "description": "Variable ID" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + } + } + }, + "list-request-24": { + "type": "object", + "title": "get", + "required": [ + "type", + "obj", + "stage_id", + "project_id", + "company_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "env_var" + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "nullable": true, + "description": "ID of an existing Company" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + } + } + }, + "list-response-24": { + "type": "object", + "title": "show", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "list": { + "type": "array", + "description": "list of variables", + "items": { + "type": "object", + "properties": { + "is_favorite": { + "allOf": [ + { + "$ref": "#/components/schemas/is_favorite" + } + ] + }, + "is_owner": { + "type": "boolean", + "enum": [ + true, + false + ], + "description": "Is `true` when ID of the user that sends a request is the same as the variable owner ID." + }, + "owner_id": { + "type": "integer", + "description": "Variable owner ID" + }, + "owner_name": { + "type": "string", + "description": "Variable owner name" + }, + "owner_login": { + "type": "string", + "description": "Variable owner login" + }, + "obj_id": { + "type": "string", + "description": "Variable ID" + }, + "obj_type": { + "type": "string", + "description": "An object type", + "enum": [ + "env_var" + ] + }, + "env_var_type": { + "type": "string", + "description": "Type of variable
`secret` - Viewing the variable value is not available.
`visible` - Viewing the value of the variable is available to users who have access to the stage.
", + "enum": [ + "visible", + "secret" + ] + }, + "data_type": { + "type": "string", + "description": "Type of variable data
`json` - json validation will be applied.
`raw` - The variable will be passed as a string.", + "enum": [ + "json", + "raw" + ] + }, + "title": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "description": "Variable title" + }, + "description": { + "type": "string", + "description": "Variable description" + }, + "short_name": { + "type": "string", + "description": "Variable key. Should be unique within the stage." + }, + "company_id": { + "type": "string", + "minLength": 3, + "maxLength": 255, + "nullable": true, + "description": "ID of an existing Company" + }, + "project_id": { + "allOf": [ + { + "$ref": "#/components/schemas/project_id" + } + ] + }, + "project_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/project_short_name" + } + ] + }, + "project_title": { + "type": "string", + "description": "Project name" + }, + "stage_id": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_id" + } + ] + }, + "stage_short_name": { + "allOf": [ + { + "$ref": "#/components/schemas/stage_short_name" + } + ] + }, + "stage_title": { + "type": "string", + "description": "Stage name" + }, + "create_time": { + "type": "integer", + "example": 1632237194, + "description": "Variable creation time in the Unixtime format" + }, + "change_time": { + "type": "integer", + "example": 1632237194, + "description": "Variable change time in the Unixtime format" + }, + "uuid": { + "type": "string", + "example": "964c3ed9-83b2-45f5-afc8-3c19e5bcaed1", + "description": "Universally Unique Identifier of the object" + }, + "scopes": { + "type": "array", + "description": "The list of nodes and their fields where env_var can be used.", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Node type", + "enum": [ + "api_call", + "set_param" + ] + }, + "fields": { + "type": "array", + "description": "The list of node fields where env_var can be used.
`cert_pem, api_secret_outer` - for the apicall node.
`extra` - for the set parameters node.
`*` - all fields in a node.", + "enum": [ + "cert_pem", + "api_secret_outer", + "*", + "extra" + ] + } + } + } + }, + "value": { + "type": "string", + "nullable": true, + "description": "variable value is available if type \"visible\" or null if type \"secret\"." + }, + "fingerprints": { + "type": "array", + "description": "The list of cryptographic hash values", + "items": { + "type": "object", + "properties": { + "algo": { + "type": "string", + "description": "Mathematical algorithm", + "enum": [ + "md5", + "sha256" + ] + }, + "value": { + "type": "string", + "description": "Hash value" + } + } + } + }, + "privs": { + "allOf": [ + { + "$ref": "#/components/schemas/privs" + } + ] + } + } + } + } + } + }, + "example-create-request-22": { + "ops": [ + { + "type": "create", + "obj": "env_var", + "env_var_type": "secret", + "title": "My first variable", + "short_name": "firstvar", + "project_id": 372753, + "stage_id": 372755, + "value": "test", + "data_type": "raw", + "company_id": "i702619617", + "scopes": [ + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ] + } + ] + }, + "example-create-response-21": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "obj_id": 8, + "proc": "ok", + "obj": "env_var", + "fingerprints": [ + { + "algo": "md5", + "value": "09:8F:6B:27:B4:F6" + }, + { + "algo": "sha256", + "value": "9F:86:F0:0A:08" + } + ] + } + ] + }, + "example-modify-request-19": { + "ops": [ + { + "type": "modify", + "obj": "env_var", + "obj_id": "608", + "title": "My first variable45", + "short_name": "firstvar3", + "project_id": 372753, + "stage_id": 372755, + "env_var_type": "secret", + "scopes": [ + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ] + } + ] + }, + "example-modify-response-20": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "env_var", + "obj_id": 608, + "fingerprints": [ + { + "algo": "md5", + "value": "09:8F:6B:27:B4:F6" + }, + { + "algo": "sha256", + "value": "9F:86:F0:0A:08" + } + ] + } + ] + }, + "example-delete-request-17": { + "ops": [ + { + "type": "delete", + "obj": "env_var", + "obj_id": 611, + "project_id": 372753, + "stage_id": 372755 + } + ] + }, + "example-delete-response-17": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "env_var", + "obj_id": 611 + } + ] + }, + "example-list-request-24": { + "ops": [ + { + "type": "list", + "obj": "env_var", + "company_id": "i702619617", + "project_id": 372753, + "stage_id": 372755 + } + ] + }, + "example-list-response-22": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "list": [ + { + "is_favorite": false, + "is_owner": true, + "owner_id": 79344, + "owner_name": "user5", + "owner_login": "6672e1af96fc3b1807006a27", + "obj_id": 8576, + "obj_type": "env_var", + "env_var_type": "visible", + "data_type": "json", + "title": "Var", + "description": "test", + "short_name": "envjson", + "company_id": "i738314881", + "project_id": 810414, + "project_title": "Project_1725888915983", + "project_short_name": "project-1725888915645", + "stage_id": 810415, + "stage_title": "Stage_1725888916276", + "stage_short_name": "stage-1725888915645", + "create_time": 1725888935, + "change_time": 1725888935, + "uuid": "496256b1-9c66-4cc0-8b39-4d89b2b7ca00", + "scopes": [ + { + "type": "set_param", + "fields": [ + "extra" + ] + }, + { + "type": "api_call", + "fields": [ + "cert_pem", + "api_secret_outer" + ] + } + ], + "value": "{\"key\":\"NGKNt9e5Uo2pzPyBoYTtPYFSW8e5l9lzVyRSTI5RhDX1sD.test\"}", + "fingerprints": [ + { + "algo": "md5", + "value": "E3:6F:63:21:9D:6B:B7:DD:9F:6D:80:69:A0:41:C5:56" + }, + { + "algo": "sha256", + "value": "3B:E8:FD:74:BE:33:1D:5D:6E:60:2B:FE:B2:CB:6B:EE:24:E4:F3:7D:08:E3:6F:41:97:F9:6D:A3:E7:47:48:EF" + } + ], + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + }, + { + "is_favorite": false, + "is_owner": true, + "owner_id": 79344, + "owner_name": "user5", + "owner_login": "6672e1af96fc3b1807006a27", + "obj_id": 8574, + "obj_type": "env_var", + "env_var_type": "secret", + "data_type": "raw", + "title": "Var", + "description": "test", + "short_name": "envraw", + "company_id": "i738314881", + "project_id": 810414, + "project_title": "Project_1725888915983", + "project_short_name": "project-1725888915645", + "stage_id": 810415, + "stage_title": "Stage_1725888916276", + "stage_short_name": "stage-1725888915645", + "create_time": 1725888918, + "change_time": 1725888918, + "uuid": "76c5bc88-4827-4904-966a-a6f64e2f3f93", + "scopes": [ + { + "type": "set_param", + "fields": [ + "extra" + ] + } + ], + "value": null, + "fingerprints": [ + { + "algo": "md5", + "value": "9C:53:5D:F5:D3:8D:6E:2E:5C:9C:ED:13:70:6D:5E:FA" + }, + { + "algo": "sha256", + "value": "65:F4:03:29:4D:0A:9C:8B:30:87:35:23:BD:BB:27:A7:EC:31:D2:E8:4C:57:6F:10:EC:A0:D9:11:16:0A:16:FC" + } + ], + "privs": [ + { + "type": "create", + "list_obj": [ + "all" + ] + }, + { + "type": "view", + "list_obj": [ + "all" + ] + }, + { + "type": "modify", + "list_obj": [ + "all" + ] + }, + { + "type": "delete", + "list_obj": [ + "all" + ] + } + ] + } + ] + } + ] + }, + "upload_info-success-response": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "status": { + "type": "string", + "description": "Status of upload operation", + "enum": [ + "success", + "in_progress" + ] + }, + "scheme": { + "type": "array", + "description": "Information about loading objects", + "items": { + "type": "object", + "properties": { + "old_obj_id": { + "type": "integer", + "description": "Identifier of the uploaded Object" + }, + "obj_id": { + "type": "integer", + "description": "Identifier of the Object after uploading" + }, + "obj_type": { + "type": "string", + "description": "Uploaded Object type" + }, + "title": { + "type": "string", + "description": "Uploaded Object title (name)" + } + } + } + } + } + }, + "upload_info-error_upload-response": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "status": { + "type": "string", + "description": "Status of upload operation", + "enum": [ + "error" + ] + }, + "scheme": { + "type": "array", + "description": "Information about loading objects", + "items": { + "type": "object", + "properties": { + "old_obj_id": { + "type": "integer", + "description": "Identifier of the uploaded Object" + }, + "obj_id": { + "type": "integer", + "description": "Identifier of the Object after uploading" + }, + "obj_type": { + "type": "string", + "description": "Uploaded Object type" + }, + "title": { + "type": "string", + "description": "Uploaded Object title (name)" + } + } + } + }, + "errors": { + "type": "array", + "description": "Information about uploading errors", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Identifier of the uploaded Object" + }, + "obj": { + "type": "string", + "description": "Object type" + }, + "title": { + "type": "string", + "description": "Object title (name)" + }, + "count": { + "type": "integer", + "description": "Count of errors" + }, + "destinations": { + "type": "array", + "description": "Information about uploading object with errors", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Identifier of the uploaded Object with errors" + }, + "obj": { + "type": "string", + "description": "Object with errors type" + }, + "title": { + "type": "string", + "description": "Object with errors title (name)" + }, + "count": { + "type": "integer", + "description": "Count of errors" + }, + "errors": { + "type": "array", + "description": "Error details" + } + } + } + } + } + } + } + } + }, + "upload_info-error-response": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "status": { + "type": "string", + "description": "Status of upload operation", + "enum": [ + "error" + ] + }, + "scheme": { + "type": "array", + "description": "Information about loading objects" + }, + "errors": { + "type": "array", + "description": "Information about uploading errors", + "items": { + "type": "object", + "properties": { + "obj_id": { + "type": "integer", + "description": "Identifier of the uploaded Object with errors" + }, + "obj": { + "type": "string", + "description": "Object with errors type" + }, + "title": { + "type": "string", + "description": "Object with errors title (name)" + }, + "errors": { + "type": "array", + "description": "Error details" + } + } + } + } + } + }, + "example-upload_info-success-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "success", + "scheme": [ + { + "old_obj_id": 282883, + "obj_id": 1391432, + "obj_type": "conv", + "title": "New Object" + } + ] + } + ] + }, + "example-upload_info-error_upload-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "error", + "scheme": [ + { + "old_obj_id": 731204, + "obj_id": 1391431, + "obj_type": "conv", + "title": "New object" + }, + { + "old_obj_id": 540281, + "obj_id": 1391430, + "obj_type": "conv", + "title": "Parallel PCH (Copy)" + }, + { + "old_obj_id": 188920, + "obj_id": 547382, + "obj_type": "folder", + "title": "copy" + } + ], + "errors": [ + { + "obj_id": 547382, + "obj": "folder", + "title": "copy", + "count": 1, + "destinations": [ + { + "conv_type": "process", + "obj_id": 1391430, + "obj": "conv", + "title": "Parallel PCH (Copy)", + "count": 1, + "destinations": [ + { + "obj_id": "6528ed7f56167c28a50032e8", + "obj": "node", + "title": "hist", + "count": 1, + "errors": [ + "Only active process can be used" + ] + } + ] + } + ] + } + ] + } + ] + }, + "example-upload_info-error-response": { + "request_proc": "ok", + "ops": [ + { + "proc": "ok", + "status": "error", + "scheme": [], + "errors": [ + { + "obj_id": 323435, + "obj": "folder", + "title": "New object", + "errors": [ + "Value is not valid. Value's byte_size is more than maximum allowed: 255" + ] + } + ] + } + ] + }, + "get-request-9": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "statistics" + }, + "action": { + "type": "string", + "description": "Operation type", + "enum": [ + "upload", + "download", + "copy" + ] + }, + "obj_type": { + "type": "string", + "description": "File type:
`obj_scheme` – file with objects
`csv_upload` - .csv file with tasks", + "enum": [ + "obj_scheme", + "csv_upload" + ] + }, + "id": { + "type": "string", + "minLength": 1, + "maxLength": 1000, + "description": "File hash" + } + } + }, + "get-response-9": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "statistics" + }, + "data": { + "type": "array", + "description": "Operations list. The data array will not be empty only for the user who initiated the operation.", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "File hash" + }, + "obj_id": { + "type": "integer", + "description": "Process / State diagram id" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "obj": { + "type": "string", + "description": "File type
`obj_scheme` - file with objects
`csv_upload` - csv file with tasks" + }, + "obj_type": { + "type": "string", + "description": "Object type
`project` — Project
`stage` — Stage
`version` — Version
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance
" + }, + "ok": { + "type": "integer", + "description": "The number of objects for which the operation was successfully performed" + }, + "err": { + "type": "integer", + "description": "The number of objects for which the operation was performed with errors" + }, + "all": { + "type": "integer", + "description": "The total number of objects for which the operation was performed" + }, + "progress": { + "type": "integer", + "description": "Operation progress
For \"download\" operation value always will be 0 or 100" + } + } + } + } + } + }, + "example-get-request-9": { + "ops": [ + { + "type": "get", + "obj": "statistics", + "action": "upload", + "obj_type": "obj_scheme", + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129" + } + ] + }, + "example-get-response-8": { + "request_proc": "ok", + "ops": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj": "statistics", + "proc": "ok", + "data": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj_id": 1104082, + "company_id": "i317686751", + "obj": "csv_upload", + "obj_type": "conv", + "ok": 6, + "err": 11, + "all": 17, + "progress": 100 + } + ] + } + ] + }, + "show-request-19": { + "type": "object", + "required": [ + "type", + "obj", + "action", + "obj_type", + "id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "statistics" + }, + "action": { + "type": "string", + "description": "Operation type", + "enum": [ + "upload", + "download", + "copy" + ] + }, + "obj_type": { + "type": "string", + "description": "File type
`obj_scheme` - file with objects
`csv_upload` - csv file with tasks", + "enum": [ + "obj_scheme", + "csv_upload" + ] + }, + "id": { + "type": "string", + "minLength": 1, + "maxLength": 1000, + "description": "File hash" + } + } + }, + "show-response-20": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "statistics" + }, + "data": { + "type": "array", + "description": "The list of operatons. The \"data\" array will not be empty only for the user who initiated the operation", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "File hash" + }, + "obj_id": { + "type": "string", + "description": "Process / State diagram Name" + }, + "company_id": { + "type": "string", + "description": "Company ID" + }, + "obj": { + "type": "string", + "description": "File type
`obj_scheme` - file with objects
`csv_upload` - csv file with tasks" + }, + "obj_type": { + "type": "string", + "description": "Object type
`project` — Project
`stage` — Stage
`version` — Version
`folder` — Folder
`conv` — Process / State diagram
`dashboard` — Dashboard
`instance` — Database instance
" + }, + "ok": { + "type": "integer", + "description": "The number of objects for which the operation was successfully performed" + }, + "err": { + "type": "integer", + "description": "The number of objects for which the operation was performed with errors" + }, + "all": { + "type": "integer", + "description": "The total number of objects for which the operation was performed" + }, + "progress": { + "type": "integer", + "description": "Operation progress
For \"download\" operation value always will be 0 or 100" + } + } + } + } + } + }, + "example-show-request-18": { + "ops": [ + { + "type": "get", + "obj": "statistics", + "action": "upload", + "obj_type": "obj_scheme", + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129" + } + ] + }, + "example-show-response-18": { + "request_proc": "ok", + "ops": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj": "statistics", + "proc": "ok", + "data": [ + { + "id": "83680364000C726F7574696E675F7061636B6D0000001F6D756C742E6374726C2E6170702D6D772D6170692D7072652D325F6D756C746D0000000C63F883EE094BAB52FF000129", + "obj_id": 1104082, + "company_id": "i317686751", + "obj": "csv_upload", + "obj_type": "conv", + "ok": 6, + "err": 11, + "all": 17, + "progress": 100 + } + ] + } + ] + }, + "show(json)-request": { + "type": "object", + "required": [ + "type", + "obj", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conf" + }, + "obj_type": { + "type": "string", + "description": "Object type:
`timer` - For information about the allowed timer value
`ui` - For information on the box_solution flag", + "enum": [ + "timer", + "ui" + ] + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + } + } + }, + "show(json)-response": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conf" + }, + "obj_type": { + "type": "string", + "description": "Object type ", + "enum": [ + "timer", + "ui" + ] + }, + "min_value": { + "type": "integer", + "description": "Minimum timer delay value" + }, + "box_solution": { + "type": "boolean", + "description": "The On-Premises delivery option flag activates and deactivates the following functionality:
if parameter equals true, then:
a) The elastic search is disabled, instead the search will be performed directly in the database.
b) Companies cannot be created.
c) Users cannot be invited.
d) Every user can see other users.
" + }, + "type_logins": { + "type": "array", + "description": "Available login types", + "enum": [ + "api", + "google", + "facebook", + "ldap", + "oauth_pb", + "phone", + "corezoid", + "github", + "apple", + "keycloak", + "saml" + ] + } + } + }, + "example-show(json)-request": { + "ops": [ + { + "conv_id": 1243014, + "type": "show", + "obj": "conf", + "obj_type": "timer" + } + ] + }, + "example-show(json)-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conf", + "obj_type": "timer", + "min_value": 30 + } + ] + }, + "example-show(json)ui-response": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conf", + "obj_type": "ui", + "box_solution": false, + "type_logins": [ + "corezoid", + "google" + ] + } + ] + }, + "get-request-10": { + "type": "object", + "required": [ + "type", + "obj", + "key" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "value" + }, + "key": { + "type": "string", + "description": "Setting key" + } + } + }, + "result": { + "type": "string", + "enum": [ + "ok", + "error" + ], + "description": "The processing status of a specific operation" + }, + "get-response-10": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "id": { + "type": "integer", + "description": "Setting identifier" + }, + "key": { + "type": "string", + "description": "Setting key" + }, + "value": { + "type": "integer", + "description": "Setting value" + }, + "description": { + "type": "string", + "description": "Setting description" + }, + "obj_type": { + "type": "string", + "description": "Setting data type", + "enum": [ + "binary", + "integer", + "atom", + "json", + "float", + "string", + "boolean" + ] + }, + "is_required": { + "type": "boolean", + "description": "Indicator of setting necessity" + }, + "vsn": { + "type": "integer", + "description": "Version of setting value" + }, + "tags": { + "type": "array", + "description": "Tags collection for setting", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Tag identifier" + }, + "tag": { + "type": "string", + "description": "Tag title" + } + } + } + }, + "allowed": { + "type": "array", + "description": "Valid setting values" + } + } + }, + "set-request": { + "type": "object", + "required": [ + "type", + "obj", + "key", + "value", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "set" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "value" + }, + "id": { + "type": "integer", + "description": "Setting Identifier" + }, + "key": { + "type": "string", + "description": "Setting key" + }, + "description": { + "type": "string", + "description": "Setting description" + }, + "obj_type": { + "type": "string", + "description": "Setting data type", + "enum": [ + "binary", + "integer", + "atom", + "json", + "float", + "string", + "boolean" + ] + }, + "is_required": { + "type": "boolean", + "description": "Indicator of setting necessity" + }, + "vsn": { + "type": "integer", + "description": "Version of setting value" + }, + "tags": { + "type": "array", + "description": "Tags collection for setting", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Tag identifier" + }, + "tag": { + "type": "string", + "description": "Tag title" + } + } + } + }, + "allowed": { + "type": "array", + "description": "`on clarification`" + } + } + }, + "set-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "id": { + "type": "integer", + "description": "Setting identifier" + }, + "key": { + "type": "string", + "description": "Setting key" + }, + "value": { + "type": "integer", + "description": "Setting value" + }, + "description": { + "type": "string", + "description": "Setting description" + }, + "obj_type": { + "type": "string", + "description": "Setting data type", + "enum": [ + "binary", + "integer", + "atom", + "json", + "float", + "string", + "boolean" + ] + }, + "is_required": { + "type": "boolean", + "description": "Indicator of setting necessity" + }, + "vsn": { + "type": "integer", + "description": "Version of setting value" + }, + "tags": { + "type": "array", + "description": "Tags collection for setting", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Tag identifier" + }, + "tag": { + "type": "string", + "description": "Tag title" + } + } + } + }, + "allowed": { + "type": "array", + "description": "Valid setting values" + } + } + }, + "delete-request-18": { + "type": "object", + "required": [ + "type", + "obj", + "key" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "value" + }, + "key": { + "type": "string", + "description": "Setting key" + } + } + }, + "delete-response-18": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + } + } + }, + "example-get-request-10": { + "type": "get", + "obj": "value", + "key": "api_call_default_max_threads" + }, + "example-get-response-9": { + "result": "ok", + "id": 131, + "key": "api_call_default_max_threads", + "value": 10, + "description": "API Default max threads value", + "obj_type": "integer", + "is_required": true, + "vsn": 30, + "tags": [ + { + "id": 2, + "tag": "ui" + }, + { + "id": 1, + "tag": "capi" + } + ], + "allowed": [] + }, + "example-set-request": { + "type": "set", + "obj": "value", + "id": 131, + "key": "api_call_default_max_threads", + "value": "11", + "description": "API Default max threads value", + "obj_type": "integer", + "is_required": true, + "vsn": 32, + "tags": [ + { + "id": 2, + "tag": "ui" + }, + { + "id": 1, + "tag": "capi" + } + ], + "allowed": [] + }, + "example-set-response": { + "result": "ok", + "id": 131, + "key": "api_call_default_max_threads", + "value": 11, + "description": "API Default max threads value", + "obj_type": "integer", + "is_required": true, + "vsn": 33, + "tags": [ + { + "id": 2, + "tag": "ui" + }, + { + "id": 1, + "tag": "capi" + } + ], + "allowed": [] + }, + "example-delete-request-18": { + "type": "delete", + "obj": "value", + "key": "api_call_default_max_threads" + }, + "list-request-25": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "values" + } + } + }, + "list-response-25": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "list": { + "type": "array", + "description": "Settings list", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Setting identifier" + }, + "key": { + "type": "string", + "description": "Setting key" + }, + "value": { + "oneOf": [ + { + "type": "integer" + }, + { + "type": "string" + }, + { + "type": "boolean" + } + ], + "type": "integer", + "description": "Setting value" + }, + "description": { + "type": "string", + "description": "Setting description" + }, + "obj_type": { + "type": "string", + "description": "Setting data type", + "enum": [ + "binary", + "integer", + "atom", + "json", + "float", + "string", + "boolean" + ] + }, + "is_required": { + "type": "boolean", + "description": "Indicator of setting necessity" + }, + "vsn": { + "type": "integer", + "description": "Version of setting value" + }, + "tags": { + "type": "array", + "description": "Tags collection for setting", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Tag identifier" + }, + "tag": { + "type": "string", + "description": "Tag title" + } + } + } + }, + "allowed": { + "type": "array", + "description": "Valid setting values" + } + } + } + } + } + }, + "example-list-request-25": { + "type": "list", + "obj": "values" + }, + "example-list-response-23": { + "result": "ok", + "list": [ + { + "id": 23, + "key": "capi_register_event_conv", + "value": 69767, + "description": "Conveyor for users registration", + "obj_type": "integer", + "is_required": false, + "vsn": 12, + "tags": [ + { + "id": 17, + "tag": "conveyor_id" + }, + { + "id": 31, + "tag": "single_account" + }, + { + "id": 1, + "tag": "capi" + } + ], + "allowed": [] + } + ] + }, + "show-request-20": { + "type": "object", + "required": [ + "type", + "obj", + "key" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "shared_session" + } + } + }, + "show-response-21": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "data": { + "type": "object", + "description": "User data session details", + "items": { + "type": "object", + "properties": { + "create_time": { + "type": "timestamp", + "description": "Timestamp of session creation" + }, + "user_id": { + "type": "integer", + "description": "User identifier" + }, + "nick": { + "type": "string", + "description": "Pre-saved user name
" + }, + "is_super_user": { + "type": "boolean", + "description": "Parameter denoting the user is the superuser" + }, + "user_photo": { + "type": "string", + "description": "A path to the repository where the user's photo are stored" + }, + "login": { + "type": "string", + "description": "User login" + }, + "logins": { + "type": "array", + "description": "list of user logins
", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "ldap", + "google", + "api", + "phone", + "corezoid" + ], + "description": "Type of login" + }, + "login": { + "type": "string", + "description": "Login value" + } + } + } + }, + "lang": { + "type": "string", + "description": "Conversation language", + "enum": [ + "en", + "ua" + ] + }, + "status": { + "type": "string", + "enum": [ + "actived", + "blocked" + ], + "description": "User or API Key state
" + } + } + } + } + } + }, + "set-request-2": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "shared_session" + }, + "obj_id": { + "type": "integer", + "description": "User Identifier" + } + } + }, + "set-response-2": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "data": { + "type": "array", + "description": "User data session details" + } + } + }, + "delete-request-19": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "shared_session" + } + } + }, + "delete-response-19": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "data": { + "type": "array", + "description": "User data session details" + } + } + }, + "example-show-request-19": { + "type": "show", + "obj": "shared_session" + }, + "example-show-response-19": { + "result": "ok", + "data": { + "create_time": 1700743824, + "user_id": 26789, + "nick": "John Doe", + "is_super_user": false, + "user_photo": "https://lh3.googleusercontent.com/a-/AOh14Gg7CeymmjYqZXDewOI9wM2sdkl4h7UvFA0AFA", + "login": "john@email.com", + "logins": [ + { + "login": "john@email.com", + "type": "corezoid" + }, + { + "login": "john@email.comm", + "type": "google" + } + ], + "lang": "en", + "status": "actived" + } + }, + "example-set-request-2": { + "type": "set", + "obj": "shared_session", + "obj_id": 2 + }, + "example-set-response-2": { + "result": "ok", + "data": [] + }, + "example-delete-request-19": { + "type": "delete", + "obj": "shared_session" + }, + "example-delete-response-18": { + "result": "ok", + "data": [] + }, + "show-request-21": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "show" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + } + } + }, + "show-response-22": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "data": { + "type": "object", + "description": "License attributes", + "properties": { + "pub_key": { + "type": "string", + "description": "License Public Key" + }, + "multi_tenancy": { + "type": "boolean", + "description": "Additional system setting, which enables one application instance to cater to the needs of multiple client enterprises." + }, + "company_id": { + "type": "string", + "description": "License holder identifier" + }, + "cluster_id": { + "type": "string", + "description": "Environment identifier" + }, + "is_allow": { + "type": "boolean", + "description": "Valid attribute values" + }, + "time_to_start": { + "type": "timestamp", + "description": "license start date" + }, + "max_task_size_state_diagram": { + "type": "string", + "description": "Maximum size of a state diagram task" + }, + "max_scpm": { + "type": "string", + "description": "Maximum number of state changes" + }, + "max_rpm": { + "type": "string", + "description": "Maximum number of requests per month" + }, + "max_storage_size": { + "type": "string", + "description": "Permitted storage size for usage" + }, + "created_time": { + "type": "string", + "description": "license creation date" + }, + "account_license_module": { + "type": "boolean", + "description": "System setting for enabling license module" + }, + "max_active_procs": { + "type": "string", + "description": "Maximum number of active processes" + }, + "max_task_size_process": { + "type": "string", + "description": "Maximum size of a process task" + }, + "max_users": { + "type": "string", + "description": "Number of authorized users according to the license" + }, + "time_to_expire": { + "type": "timestamp", + "description": "license expiration date" + }, + "max_rps": { + "type": "string", + "description": "Maximum number of requests per second" + }, + "min_timer": { + "type": "integer", + "description": "Minimal allowed timer period" + }, + "issuer": { + "type": "string", + "description": "License issuer" + } + } + }, + "meta": { + "type": "object", + "description": "Descripion custom license attributes", + "properties": { + "account_license_module": { + "type": "string", + "description": "System setting for enabling license module" + } + } + } + } + }, + "get-request-11": { + "type": "object", + "required": [ + "type", + "obj", + "obj_type" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "get" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + }, + "obj_type": { + "type": "string", + "description": "License source type
`server` - deprecated option", + "enum": [ + "file" + ] + } + } + }, + "get-response-11": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "data": { + "type": "object", + "description": "License attributes", + "properties": { + "pub_key": { + "type": "string", + "description": "License Public Key" + }, + "multi_tenancy": { + "type": "boolean", + "description": "Additional system setting, which enables one application instance to cater to the needs of multiple client enterprises." + }, + "company_id": { + "type": "string", + "description": "License holder identifier" + }, + "cluster_id": { + "type": "string", + "description": "Environment identifier" + }, + "is_allow": { + "type": "boolean", + "description": "Valid attribute values" + }, + "time_to_start": { + "type": "timestamp", + "description": "license start date" + }, + "max_task_size_state_diagram": { + "type": "string", + "description": "Maximum size of a state diagram task" + }, + "max_scpm": { + "type": "string", + "description": "Maximum number of state changes" + }, + "max_rpm": { + "type": "string", + "description": "Maximum number of requests per month" + }, + "max_storage_size": { + "type": "string", + "description": "Permitted storage size for usage" + }, + "created_time": { + "type": "string", + "description": "license creation date" + }, + "account_license_module": { + "type": "boolean", + "description": "System setting for enabling license module" + }, + "max_active_procs": { + "type": "string", + "description": "Maximum number of active processes" + }, + "max_task_size_process": { + "type": "string", + "description": "Maximum size of a process task" + }, + "max_users": { + "type": "string", + "description": "Number of authorized users according to the license" + }, + "time_to_expire": { + "type": "timestamp", + "description": "license expiration date" + }, + "max_rps": { + "type": "string", + "description": "Maximum number of requests per second" + }, + "min_timer": { + "type": "integer", + "description": "Minimal allowed timer period" + }, + "issuer": { + "type": "string", + "description": "License issuer" + } + } + }, + "meta": { + "type": "object", + "description": "Descripion custom license attributes", + "properties": { + "account_license_module": { + "type": "string", + "description": "System setting for enabling license module" + } + } + } + } + }, + "upload-request": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "upload" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + }, + "content": { + "type": "string", + "description": "license in base64 format" + } + } + }, + "upload-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + } + } + }, + "accept-request": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "accept" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + } + } + }, + "accept-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + } + } + }, + "invalidate-request": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "invalidate" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + } + } + }, + "invalidate-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "list": { + "type": "array", + "description": "Result of installation license to system components", + "items": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "reason": { + "type": "string", + "description": "Error reason" + }, + "component": { + "type": "string", + "description": "System component", + "enum": [ + "corezoid_limits", + "corezoid_actorizer", + "single_account", + "corezoid_api_sync", + "capi", + "conveyor_api_multipart", + "conf_agent_server", + "http_worker", + "worker", + "cce" + ] + }, + "ip": { + "type": "string", + "description": "Component IP adres" + }, + "vsn": { + "type": "string", + "description": "Component version" + }, + "start_time": { + "type": "timestamp", + "description": "Component instalation date" + } + } + } + } + } + }, + "decline-request": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "decline" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + } + } + }, + "decline-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + } + } + }, + "example-show-request-20": { + "type": "show", + "obj": "license" + }, + "example-show-response-20": { + "result": "ok", + "data": { + "account_license_module": true, + "issuer": "Middleware at pre.corezoid.com", + "created_time": "18-Sep-2024::10:10:09 UTC", + "company_id": "Middleware", + "cluster_id": "PRE", + "multi_tenancy": false, + "max_active_procs": "infinite", + "max_rps": "infinite", + "max_rpm": "infinite", + "max_scpm": "infinite", + "max_task_size_process": "infinite", + "max_task_size_state_diagram": 35840, + "min_timer": 2, + "max_users": "infinite", + "max_storage_size": "infinite", + "time_to_expire": 1757553209, + "time_to_start": 1726654209, + "is_allow": true, + "pub_key": "BJn0+AFouQIYxlddod6rLYb53y3NC/44f8EaJADxP9S+dEqcuh42JX5rPnjssmadNQBZGxYXFU/bxBctxGxaopM=" + }, + "meta": { + "account_license_module": "Enable License module in Account" + } + }, + "example-get-request-11": { + "type": "get", + "obj_type": "file", + "obj": "license" + }, + "example-get-response-10": { + "result": "ok", + "data": { + "pub_key": "BJn0+AFouQIYxlddod6rLYb53y3NC/44f8EaJADxP9S+dEqcuh42JX5rPnjssmadNQBZGxYXFU/bxBctxGxaopM=", + "multi_tenancy": false, + "company_id": "Middleware", + "cluster_id": "PRE", + "is_allow": true, + "time_to_start": 1726654209, + "max_task_size_state_diagram": 35840, + "max_scpm": "infinite", + "max_rpm": "infinite", + "max_storage_size": "infinite", + "created_time": "18-Sep-2024::10:10:09 UTC", + "account_license_module": true, + "max_active_procs": "infinite", + "max_task_size_process": "infinite", + "max_users": "infinite", + "time_to_expire": 1757553209, + "max_rps": "infinite", + "min_timer": 2, + "issuer": "Middleware at pre.corezoid.com" + }, + "meta": { + "account_license_module": "Enable License module in Account" + } + }, + "example-upload-request": { + "type": "upload", + "obj": "license", + "content": "..." + }, + "example-upload-response": { + "result": "ok" + }, + "example-accept-request": { + "type": "accept", + "obj": "license" + }, + "example-accept-response": { + "result": "ok" + }, + "example-invalidate-request": { + "type": "invalidate", + "obj": "license" + }, + "example-invalidate-response": { + "result": "ok", + "list": [ + { + "proc": "error", + "reason": "no_response", + "component": "corezoid_limits", + "ip": "10.50.8.137", + "vsn": "2.0.2-22-gb3aaa0d", + "start_time": 1721666283 + }, + { + "proc": "error", + "reason": "no_response", + "component": "corezoid_actorizer", + "ip": "10.50.8.137", + "vsn": "0.0.1-38-g743d5da", + "start_time": 1726474778 + }, + { + "proc": "error", + "reason": "no_response", + "component": "corezoid_limits", + "ip": "10.50.9.247", + "vsn": "2.0.2-22-gb3aaa0d", + "start_time": 1723029563 + }, + { + "proc": "error", + "reason": "no_response", + "component": "corezoid_api_sync", + "ip": "10.50.8.137", + "vsn": "test_centos8_erl24-32-g08f976b", + "start_time": 1721666105 + }, + { + "proc": "error", + "reason": "no_response", + "component": "corezoid_api_sync", + "ip": "10.50.9.247", + "vsn": "test_centos8_erl24-32-g08f976b", + "start_time": 1721666157 + }, + { + "proc": "ok", + "component": "cce", + "ip": "10.50.10.130" + }, + { + "proc": "ok", + "component": "conf_agent_server", + "ip": "10.50.9.247" + }, + { + "proc": "ok", + "component": "capi", + "ip": "10.50.8.137" + }, + { + "proc": "ok", + "component": "conveyor_api_multipart", + "ip": "10.50.9.247" + }, + { + "proc": "ok", + "component": "capi", + "ip": "10.50.9.247" + }, + { + "proc": "ok", + "component": "conveyor_api_multipart", + "ip": "10.50.8.137" + }, + { + "proc": "ok", + "component": "conf_agent_server", + "ip": "10.50.8.137" + }, + { + "proc": "ok", + "component": "worker", + "ip": "10.50.8.242" + }, + { + "proc": "ok", + "component": "http_worker", + "ip": "10.50.8.244" + } + ] + }, + "example-decline-request": { + "type": "decline", + "obj": "license" + }, + "example-decline-response": { + "result": "ok" + }, + "create-request-24": { + "type": "object", + "required": [ + "type", + "obj", + "company_name", + "cluster_id", + "start_time", + "expire_time" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + }, + "company_name": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "License holder identifier" + }, + "cluster_id": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Environment identifier" + }, + "start_time": { + "type": "timestamp", + "description": "license start date" + }, + "expire_time": { + "type": "timestamp", + "description": "license expiration date" + }, + "max_active_procs": { + "type": "integer", + "description": "Maximum number of active processes." + }, + "max_rps": { + "type": "integer", + "description": "Maximum number of requests per second" + }, + "max_rpm": { + "type": "integer", + "description": "Maximum number of requests per month" + }, + "max_scpm": { + "type": "integer", + "description": "Maximum number of state changes" + }, + "multi_tenancy": { + "type": "boolean", + "description": "Additional system setting, which enables one application instance to cater to the needs of multiple client enterprises" + }, + "min_timer": { + "type": "integer", + "description": "Minimal allowed timer period" + }, + "max_task_size_process": { + "type": "integer", + "minLength": 1024, + "maxLength": "infinity", + "description": "Maximum size of a process task" + }, + "max_task_size_state_diagram": { + "type": "integer", + "minLength": 1024, + "maxLength": "infinity", + "description": "Maximum size of a state diagram task" + }, + "max_users": { + "type": "integer", + "description": "Number of authorized users according to the license" + }, + "max_storage_size": { + "type": "integer", + "description": "Permitted storage size for usage" + }, + "extra_attributes": { + "type": "array", + "description": "Custom license attributes", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "minLength": 1, + "maxLength": 255, + "description": "Аttribute identifier" + }, + "value": { + "type": "any", + "description": "Аttribute value" + } + } + } + } + } + }, + "create-response-24": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj_id": { + "type": "string", + "description": "License identifier" + } + } + }, + "delete-request-20": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + }, + "obj_id": { + "type": "integer", + "description": "License identifier" + } + } + }, + "delete-response-20": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + } + } + }, + "download-request-3": { + "type": "object", + "required": [ + "type", + "obj", + "obj_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "download" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license" + }, + "obj_id": { + "type": "integer", + "description": "License identifier" + }, + "format": { + "type": "string", + "description": "License format:
`base64` - for getting license in base64 format
`binary` - for getting license as file
", + "enum": [ + "base64", + "binary" + ] + } + } + }, + "download-response-3": { + "type": "object", + "properties": { + "content": { + "type": "string", + "description": "License in base64 format" + } + } + }, + "list-request-26": { + "type": "object", + "required": [ + "type", + "obj", + "limit", + "offset" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "licenses" + }, + "limit": { + "type": "integer", + "minLength": 1, + "maxLength": 100, + "description": "Specifies the number of history records to return" + }, + "offset": { + "type": "integer", + "minLength": 0, + "maxLength": 100, + "description": "Specifies the number of elements to skip in the query results." + } + } + }, + "example-create-request-23": { + "type": "create", + "obj": "license", + "company_name": "Middleware", + "cluster_id": "PRE", + "start_time": 1726753009, + "expire_time": 1757652009, + "max_active_procs": 0, + "max_rps": 0, + "multi_tenancy": false, + "min_timer": 2, + "max_task_size_process": 0, + "max_users": "0", + "max_storage_size": "0", + "extra_attributes": [ + { + "name": "account_license_module", + "value": "true" + } + ], + "max_task_size_state_diagram": "35840" + }, + "example-create-response-22": { + "obj_id": 24, + "proc": "ok" + }, + "example-delete-request-20": { + "type": "delete", + "obj": "license", + "obj_id": 587789 + }, + "example-delete-response-19": { + "proc": "ok" + }, + "example-download-request-3": { + "type": "download", + "obj": "license", + "obj_id": 84778, + "format": "base64" + }, + "example-download-response-3": { + "content": "base64 object" + }, + "example-list-request-26": { + "type": "list", + "obj": "licenses", + "limit": 1, + "offset": 1 + }, + "example-list-response-24": [ + { + "obj_id": 1, + "create_time": 1600116698, + "status": "active", + "download_count": 1, + "pub_key": "BFMg5evlctH7rSs0BcaZuES8wGMxx1cdw0ZOeHgxHuG4WIm8LPVOa+u/QZg4mXU5QrTujShNwuqP+oAUciktrOw=", + "company_name": "Middleware", + "cluster_id": "Marketplace", + "start_time": 1590364800, + "expire_time": 1598313600, + "max_active_procs": 0, + "max_rps": 20, + "multi_tenancy": false + } + ], + "example-request": { + "obj_type": "user", + "obj_id": 45165 + }, + "example-response": { + "obj_type": "user", + "obj_id": 45165, + "type": "google", + "login": "jane.doe@mail.com", + "status": 1, + "corezoid_id": 45165, + "account_id": 87478 + }, + "show-request-22": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv_auth" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + } + } + }, + "show-response-23": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv_auth" + }, + "obj_type": { + "type": "string", + "description": "Authorization type", + "enum": [ + "basic" + ] + }, + "data": { + "type": "object", + "description": "Authorization parameters", + "properties": { + "user": { + "type": "string", + "description": "Username" + }, + "pass": { + "type": "string", + "description": "Password" + } + } + } + } + }, + "modify-request-21": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id", + "obj_type", + "data" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv_auth" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + }, + "obj_type": { + "type": "string", + "description": "Authorization type", + "enum": [ + "basic" + ] + }, + "data": { + "type": "object", + "description": "Authorization parameters", + "properties": { + "user": { + "type": "string", + "description": "Username" + }, + "pass": { + "type": "string", + "description": "Password" + } + } + } + } + }, + "modify-response-21": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv_auth" + } + } + }, + "delete-request-21": { + "type": "object", + "required": [ + "type", + "obj", + "conv_id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "conv_auth" + }, + "conv_id": { + "type": "integer", + "description": "Process/State Diagram ID" + } + } + }, + "delete-response-21": { + "type": "object", + "properties": { + "id": { + "allOf": [ + { + "$ref": "#/components/schemas/id" + } + ] + }, + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "conv_auth" + } + } + }, + "example-show-request-21": { + "ops": [ + { + "type": "show", + "obj": "conv_auth", + "conv_id": 1457936 + } + ] + }, + "example-show-response-21": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth", + "obj_type": "basic", + "data": { + "user": "login", + "pass": "password" + } + } + ] + }, + "example-modify-request-20": { + "ops": [ + { + "type": "modify", + "obj": "conv_auth", + "conv_id": 1457936, + "obj_type": "basic", + "data": { + "user": "login", + "pass": "password" + } + } + ] + }, + "example-modify-response-21": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth" + } + ] + }, + "example-delete-request-21": { + "ops": [ + { + "type": "delete", + "obj": "conv_auth", + "conv_id": 1457936 + } + ] + }, + "example-delete-response-20": { + "request_proc": "ok", + "ops": [ + { + "id": "", + "proc": "ok", + "obj": "conv_auth" + } + ] + }, + "create-request-25": { + "type": "object", + "required": [ + "type", + "obj", + "name", + "attr_type", + "description", + "default_value" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "create" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attr" + }, + "name": { + "type": "string", + "description": "Attribute name", + "pattern": "^[a-z][a-z_0-9]+$" + }, + "attr_type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description", + "pattern": "[a-zA-Z_0-9.]+$" + }, + "default_value": { + "type": "string", + "description": "Attribute default value", + "minLength": 1, + "maxLength": 255 + } + } + }, + "create-response-25": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "object", + "description": "Request results", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "license_attrs" + }, + "data": { + "type": "object", + "description": "Created attribute", + "properties": { + "user_id": { + "type": "integer", + "description": "User identifier that created the attribute" + }, + "user_name": { + "type": "string", + "description": "User name that created the attribute" + }, + "user_login": { + "type": "string", + "description": "User login that created the attribute" + }, + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "name": { + "type": "string", + "description": "Attribute name" + }, + "attr_type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description" + }, + "default_value": { + "type": "string", + "description": "Attribute default value" + }, + "change_time": { + "type": "timestamp", + "description": "Timestamp of the last attribute modification" + } + } + } + } + } + } + }, + "update-request": { + "type": "object", + "required": [ + "type", + "obj", + "id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "update" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attr" + }, + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "name": { + "type": "string", + "description": "Attribute name", + "pattern": "^[a-z][a-z_0-9]+$" + }, + "attr_type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description", + "pattern": "[a-zA-Z_0-9.]+$" + }, + "default_value": { + "type": "string", + "description": "Attribute default value" + }, + "user_id": { + "type": "integer", + "description": "User identifier that updated the attribute" + } + } + }, + "update-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "object", + "description": "Request results", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "license_attr" + }, + "data": { + "type": "object", + "description": "Updated attribute", + "properties": { + "user_id": { + "type": "integer", + "description": "User identifier that updated the attribute" + }, + "user_name": { + "type": "string", + "description": "User name that updated the attribute" + }, + "user_login": { + "type": "string", + "description": "User login that updated the attribute" + }, + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "name": { + "type": "string", + "description": "Attribute name" + }, + "attr_type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description" + }, + "default_value": { + "type": "string", + "description": "Attribute default value" + }, + "change_time": { + "type": "timestamp", + "description": "Timestamp of the last attribute modification" + } + } + } + } + } + } + }, + "restore-request-9": { + "type": "object", + "required": [ + "type", + "obj", + "id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "update" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attr" + }, + "id": { + "type": "integer", + "description": "Attribute ID" + } + } + }, + "delete-request-22": { + "type": "object", + "required": [ + "type", + "obj", + "id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "delete" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attr" + }, + "id": { + "type": "integer", + "description": "Attribute identifier" + } + } + }, + "delete-response-22": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "object", + "description": "Request results", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "license_attrs" + }, + "data": { + "type": "object", + "description": "Deleted attribute", + "properties": { + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "active": { + "type": "boolean", + "description": "Attribute active status flag" + }, + "user_id": { + "type": "integer", + "description": "User identifier that deleted the attribute" + }, + "user_name": { + "type": "string", + "description": "User name that deleted the attribute" + }, + "user_login": { + "type": "string", + "description": "User name that deleted the attribute" + } + } + } + } + } + } + }, + "view-request": { + "type": "object", + "required": [ + "type", + "obj", + "id" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "view" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attr" + }, + "id": { + "type": "integer", + "description": "Attribute identifier" + } + } + }, + "view-response": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "license_attr" + }, + "data": { + "type": "array", + "description": "List of attributes", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "name": { + "type": "string", + "description": "Attribute name" + }, + "type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description" + }, + "default_value": { + "type": "string", + "description": "Attribute default value" + }, + "active": { + "type": "boolean", + "description": "Attribute active status flag" + }, + "user_id": { + "type": "integer", + "description": "User identifier of the attribute modifier" + }, + "change_time": { + "type": "timestamp", + "description": "Timestamp of the last attribute modification" + }, + "user_name": { + "type": "string", + "description": "User name of the attribute modifier" + }, + "user_login": { + "type": "string", + "description": "User login of the attribute modifier" + } + } + } + } + } + } + } + }, + "list-request-27": { + "type": "object", + "required": [ + "type", + "obj" + ], + "properties": { + "type": { + "allOf": [ + { + "$ref": "#/components/schemas/type" + } + ], + "default": "list" + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-request" + } + ], + "default": "license_attrs" + }, + "filter": { + "type": "string", + "description": "For filtering only active licenses attributes", + "enum": [ + "actived" + ] + } + } + }, + "list-response-26": { + "type": "object", + "properties": { + "result": { + "allOf": [ + { + "$ref": "#/components/schemas/result" + } + ] + }, + "request_proc": { + "allOf": [ + { + "$ref": "#/components/schemas/request_proc" + } + ] + }, + "ops": { + "type": "object", + "properties": { + "proc": { + "allOf": [ + { + "$ref": "#/components/schemas/proc-response" + } + ] + }, + "obj": { + "allOf": [ + { + "$ref": "#/components/schemas/obj-response" + } + ], + "default": "license_attrs" + }, + "data": { + "type": "array", + "description": "List of attributes", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "description": "Attribute ID" + }, + "name": { + "type": "string", + "description": "Attribute name" + }, + "type": { + "type": "string", + "description": "Attribute type", + "enum": [ + "string", + "integer", + "boolean" + ] + }, + "description": { + "type": "string", + "description": "Attribute description" + }, + "default_value": { + "type": "string", + "description": "Attribute default value" + }, + "active": { + "type": "boolean", + "description": "Attribute active status flag" + }, + "user_id": { + "type": "integer", + "description": "User identifier of the attribute modifier" + }, + "change_time": { + "type": "timestamp", + "description": "Timestamp of the last attribute modification" + }, + "user_name": { + "type": "string", + "description": "User name of the attribute modifier" + }, + "user_login": { + "type": "string", + "description": "User login of the attribute modifier" + } + } + } + } + } + } + } + }, + "example-create-request-24": { + "obj": "license_attr", + "type": "create", + "name": "test", + "attr_type": "string", + "description": "test", + "default_value": "test" + }, + "example-create-response-23": { + "result": "ok", + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attr", + "data": { + "user_id": 25130, + "user_name": "Daria Grek 2", + "user_login": "darja.grek@corezoid.com", + "name": "test", + "attr_type": "string", + "default_value": "test", + "description": "test", + "id": 440, + "change_time": 1702304018 + } + } + }, + "example-update-request": { + "obj": "license_attr", + "type": "update", + "id": 443, + "name": "test", + "attr_type": "string", + "description": "test", + "default_value": "test2", + "user_id": 25130 + }, + "example-update-response": { + "result": "ok", + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attr", + "data": { + "user_id": 25130, + "user_name": "John Doe", + "user_login": "Jhon.Doe@corezoid.com", + "id": 443, + "name": "test", + "attr_type": "string", + "default_value": "test2", + "description": "test", + "change_time": 1702390971 + } + } + }, + "example-restore-request-9": { + "type": "restore", + "obj": "license_attr", + "id": 443 + }, + "example-restore-response-9": { + "result": "ok", + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attr", + "data": { + "user_id": 5381, + "user_name": "Test", + "user_login": "380501212356", + "id": 1355, + "active": true + } + } + }, + "example-delete-request-22": { + "obj": "license_attr", + "type": "delete", + "id": 440 + }, + "example-delete-response-21": { + "result": "ok", + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attr", + "data": { + "user_id": 25130, + "user_name": "Daria Grek 2", + "user_login": "darja.grek@corezoid.com", + "id": 440, + "active": false + } + } + }, + "example-view-request": { + "type": "view", + "obj": "license_attr", + "id": 443 + }, + "example-view-response": { + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attr", + "data": { + "id": 443, + "name": "test", + "type": "string", + "description": "test", + "default_value": "test2", + "active": false, + "user_id": 25130, + "change_time": 1702391075, + "user_name": "Daria Grek 2", + "user_login": "darja.grek@corezoid.com" + } + } + }, + "example-list-request-27": { + "obj": "license_attrs", + "filter": "actived", + "type": "list" + }, + "example-list-response-25": { + "result": "ok", + "request_proc": "ok", + "ops": { + "proc": "ok", + "obj": "license_attrs", + "data": [ + { + "id": 57, + "name": "account_license_module", + "type": "boolean", + "description": "Enable License module in Account", + "default_value": true, + "active": true, + "user_id": 46544, + "change_time": 1701955722, + "user_name": "John Doe", + "user_login": "john.doe@corezoid.com" + } + ] + } + }, + "response-error-common": { + "$ref": "#/components/schemas/response-error" + }, + "example-response-error-common": { + "$ref": "#/components/schemas/example-response-error" + }, + "dashboard-create-request": { + "$ref": "#/components/schemas/create-request" + }, + "dashboard-create-response": { + "$ref": "#/components/schemas/create-response" + }, + "dashboard-delete-request": { + "$ref": "#/components/schemas/delete-request" + }, + "dashboard-delete-response": { + "$ref": "#/components/schemas/delete-response" + }, + "dashboard-restore-request": { + "$ref": "#/components/schemas/restore-request" + }, + "dashboard-restore-response": { + "$ref": "#/components/schemas/restore-response" + }, + "dashboard-modify-request": { + "$ref": "#/components/schemas/modify-request" + }, + "dashboard-modify-response": { + "$ref": "#/components/schemas/modify-response" + }, + "dashboard-favorite-request": { + "$ref": "#/components/schemas/favorite-request" + }, + "dashboard-favorite-response": { + "$ref": "#/components/schemas/favorite-response" + }, + "dashboard-list-request": { + "$ref": "#/components/schemas/list-request" + }, + "dashboard-list-response": { + "$ref": "#/components/schemas/list-response" + }, + "dashboard-show-request": { + "$ref": "#/components/schemas/show-request" + }, + "dashboard-show-response": { + "$ref": "#/components/schemas/show-response-2" + }, + "dashboard-link-request": { + "$ref": "#/components/schemas/link-request" + }, + "dashboard-link-response": { + "$ref": "#/components/schemas/link-response" + }, + "dashboard-destroy-request": { + "$ref": "#/components/schemas/destroy-request" + }, + "dashboard-destroy-response": { + "$ref": "#/components/schemas/destroy-response" + }, + "example-dashboard-create-request": { + "$ref": "#/components/schemas/example-create-request" + }, + "example-dashboard-create-response": { + "$ref": "#/components/schemas/example-create-response-api" + }, + "example-dashboard-delete-request": { + "$ref": "#/components/schemas/example-delete-request" + }, + "example-dashboard-delete-response": { + "$ref": "#/components/schemas/example-delete-response" + }, + "example-dashboard-restore-request": { + "$ref": "#/components/schemas/example-restore-request" + }, + "example-dashboard-restore-response": { + "$ref": "#/components/schemas/example-restore-response" + }, + "example-dashboard-modify-request": { + "$ref": "#/components/schemas/example-modify-request" + }, + "example-dashboard-modify-response": { + "$ref": "#/components/schemas/example-modify-response" + }, + "example-dashboard-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request" + }, + "example-dashboard-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response" + }, + "example-dashboard-list-request": { + "$ref": "#/components/schemas/example-list-request" + }, + "example-dashboard-list-response": { + "$ref": "#/components/schemas/example-list-response" + }, + "example-dashboard-show-request": { + "$ref": "#/components/schemas/example-show-request" + }, + "example-dashboard-show-response": { + "$ref": "#/components/schemas/example-show-response" + }, + "example-dashboard-link-request": { + "$ref": "#/components/schemas/example-link-request" + }, + "example-dashboard-link-response": { + "$ref": "#/components/schemas/example-link-response" + }, + "example-dashboard-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request" + }, + "example-dashboard-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response" + }, + "dashboards-list-request": { + "$ref": "#/components/schemas/list-request-2" + }, + "dashboards-list-response": { + "$ref": "#/components/schemas/list-response-2" + }, + "example-dashboards-list-request": { + "$ref": "#/components/schemas/example-list-request-2" + }, + "example-dashboards-list-response": { + "$ref": "#/components/schemas/example-list-response-2" + }, + "task-create-request": { + "$ref": "#/components/schemas/create-request-2" + }, + "task-create-response": { + "$ref": "#/components/schemas/create-response-2" + }, + "task-modify-request": { + "$ref": "#/components/schemas/modify-request-2" + }, + "task-modify-response": { + "$ref": "#/components/schemas/modify-response-2" + }, + "task-show-request": { + "$ref": "#/components/schemas/show-request-2" + }, + "task-show-response": { + "$ref": "#/components/schemas/show-response-3" + }, + "task-delete-request": { + "$ref": "#/components/schemas/delete-request-2" + }, + "task-delete-response": { + "$ref": "#/components/schemas/delete-response-2" + }, + "task-step_next-request": { + "$ref": "#/components/schemas/step_next-request" + }, + "task-step_next-response": { + "$ref": "#/components/schemas/step_next-response" + }, + "task-step_prev-request": { + "$ref": "#/components/schemas/step_prev-request" + }, + "task-step_prev-response": { + "$ref": "#/components/schemas/step_prev-response" + }, + "task-step_goto-request": { + "$ref": "#/components/schemas/step_goto-request" + }, + "task-step_goto-response": { + "$ref": "#/components/schemas/step_goto-response" + }, + "example-task-create-by-convId-request": { + "$ref": "#/components/schemas/example-create-by-convId-request" + }, + "example-task-create-by-alias-request": { + "$ref": "#/components/schemas/example-create-by-alias-request" + }, + "example-task-create-by-stage-alias-request": { + "$ref": "#/components/schemas/example-create-by-stage-alias-request" + }, + "example-task-create-response": { + "$ref": "#/components/schemas/example-create-response" + }, + "example-task-modify-request": { + "$ref": "#/components/schemas/example-modify-request-2" + }, + "example-task-modify-response": { + "$ref": "#/components/schemas/example-modify-response-2" + }, + "example-task-show-request": { + "$ref": "#/components/schemas/example-show-request-2" + }, + "example-task-show-response": { + "$ref": "#/components/schemas/example-show-response-2" + }, + "example-task-delete-request": { + "$ref": "#/components/schemas/example-delete-request-2" + }, + "example-task-delete-response": { + "$ref": "#/components/schemas/example-delete-response-2" + }, + "example-task-step_next-request": { + "$ref": "#/components/schemas/example-step_next-request" + }, + "example-task-step_next-response": { + "$ref": "#/components/schemas/example-step_next-response" + }, + "example-task-step_prev-request": { + "$ref": "#/components/schemas/example-step_prev-request" + }, + "example-task-step_prev-response": { + "$ref": "#/components/schemas/example-step_prev-response" + }, + "example-task-step_goto-request": { + "$ref": "#/components/schemas/example-step_goto-request" + }, + "example-task-step_goto-response": { + "$ref": "#/components/schemas/example-step_goto-response" + }, + "project-create-request": { + "$ref": "#/components/schemas/create-request-3" + }, + "project-create-response": { + "$ref": "#/components/schemas/create-response-3" + }, + "project-modify-request": { + "$ref": "#/components/schemas/modify-request-3" + }, + "project-modify-response": { + "$ref": "#/components/schemas/modify-response-3" + }, + "project-list-request": { + "$ref": "#/components/schemas/list-request-3" + }, + "project-list-response": { + "$ref": "#/components/schemas/list-response-3" + }, + "project-link-request": { + "$ref": "#/components/schemas/link-request-2" + }, + "project-link-response": { + "$ref": "#/components/schemas/link-response-2" + }, + "project-favorite-request": { + "$ref": "#/components/schemas/favorite-request-2" + }, + "project-favorite-response": { + "$ref": "#/components/schemas/favorite-response-2" + }, + "project-delete-request": { + "$ref": "#/components/schemas/delete-request-3" + }, + "project-delete-response": { + "$ref": "#/components/schemas/delete-response-3" + }, + "project-restore-request": { + "$ref": "#/components/schemas/restore-request-2" + }, + "project-restore-response": { + "$ref": "#/components/schemas/restore-response-2" + }, + "project-destroy-request": { + "$ref": "#/components/schemas/destroy-request-2" + }, + "project-destroy-response": { + "$ref": "#/components/schemas/destroy-response-2" + }, + "project-show-request": { + "$ref": "#/components/schemas/show-request-3" + }, + "project-show-response": { + "$ref": "#/components/schemas/show-response-4" + }, + "example-project-create-request": { + "$ref": "#/components/schemas/example-create-request-2" + }, + "example-project-create-response": { + "$ref": "#/components/schemas/example-create-response-2" + }, + "example-project-modify-request": { + "$ref": "#/components/schemas/example-modify-request-3" + }, + "example-project-modify-response": { + "$ref": "#/components/schemas/example-modify-response-3" + }, + "example-project-list-request": { + "$ref": "#/components/schemas/example-list-request-3" + }, + "example-project-list-response": { + "$ref": "#/components/schemas/example-list-response-3" + }, + "example-project-link-request": { + "$ref": "#/components/schemas/example-link-request-2" + }, + "example-project-link-response": { + "$ref": "#/components/schemas/example-link-response-2" + }, + "example-project-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request-2" + }, + "example-project-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response-2" + }, + "example-project-delete-request": { + "$ref": "#/components/schemas/example-delete-request-3" + }, + "example-project-delete-response": { + "$ref": "#/components/schemas/example-delete-response-3" + }, + "example-project-restore-request": { + "$ref": "#/components/schemas/example-restore-request-2" + }, + "example-project-restore-response": { + "$ref": "#/components/schemas/example-restore-response-2" + }, + "example-project-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-2" + }, + "example-project-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-2" + }, + "example-project-show-request": { + "$ref": "#/components/schemas/example-show-request-3" + }, + "example-project-show-response": { + "$ref": "#/components/schemas/example-show-response-3" + }, + "projects-list-request": { + "$ref": "#/components/schemas/list-request-4" + }, + "projects-list-response": { + "$ref": "#/components/schemas/list-response-4" + }, + "example-projects-list-request": { + "$ref": "#/components/schemas/example-list-request-4" + }, + "example-projects-list-response": { + "$ref": "#/components/schemas/example-list-response-4" + }, + "node-create-request": { + "$ref": "#/components/schemas/create-request-4" + }, + "node-create-response": { + "$ref": "#/components/schemas/create-response-4" + }, + "node-modify-request": { + "$ref": "#/components/schemas/modify-request-4" + }, + "node-modify-response": { + "$ref": "#/components/schemas/modify-response-4" + }, + "node-list-request": { + "$ref": "#/components/schemas/list-request-5" + }, + "node-list-response": { + "$ref": "#/components/schemas/list-response-5" + }, + "node-show-request": { + "$ref": "#/components/schemas/show-request-4" + }, + "node-show-response": { + "$ref": "#/components/schemas/show-response-5" + }, + "node-delete-request": { + "$ref": "#/components/schemas/delete-request-4" + }, + "node-delete-response": { + "$ref": "#/components/schemas/delete-response-4" + }, + "node-reset-request": { + "$ref": "#/components/schemas/reset-request" + }, + "node-reset-response": { + "$ref": "#/components/schemas/reset-response" + }, + "example-node-create-request": { + "$ref": "#/components/schemas/example-create-request-3" + }, + "example-node-create-response": { + "$ref": "#/components/schemas/example-create-response-3" + }, + "example-node-modify-request": { + "$ref": "#/components/schemas/example-modify-request-4" + }, + "example-node-modify-response": { + "$ref": "#/components/schemas/example-modify-response-4" + }, + "example-node-list-request": { + "$ref": "#/components/schemas/example-list-request-5" + }, + "example-node-list-response": { + "$ref": "#/components/schemas/example-list-response-5" + }, + "example-node-show-request": { + "$ref": "#/components/schemas/example-show-request-4" + }, + "example-node-show-response": { + "$ref": "#/components/schemas/example-show-response-4" + }, + "example-node-delete-request": { + "$ref": "#/components/schemas/example-delete-request-4" + }, + "example-node-delete-response": { + "$ref": "#/components/schemas/example-delete-response-4" + }, + "example-node-reset-request": { + "$ref": "#/components/schemas/example-reset-request" + }, + "example-node-reset-response": { + "$ref": "#/components/schemas/example-reset-response" + }, + "nodes-list-request": { + "$ref": "#/components/schemas/list-request-6" + }, + "nodes-list-response": { + "$ref": "#/components/schemas/list-response-6" + }, + "example-nodes-list-request": { + "$ref": "#/components/schemas/example-list-request-6" + }, + "example-nodes-list-response": { + "$ref": "#/components/schemas/example-list-response-6" + }, + "group-create-request": { + "$ref": "#/components/schemas/create-request-5" + }, + "group-create-response": { + "$ref": "#/components/schemas/create-response-5" + }, + "group-modify-request": { + "$ref": "#/components/schemas/modify-request-5" + }, + "group-modify-response": { + "$ref": "#/components/schemas/modify-response-5" + }, + "group-list-request": { + "$ref": "#/components/schemas/list-request-7" + }, + "group-list-response-list_obj-user": { + "$ref": "#/components/schemas/list-response-7" + }, + "group-list-response-list_obj-conv": { + "$ref": "#/components/schemas/list-response-list_obj-conv" + }, + "group-delete-request": { + "$ref": "#/components/schemas/delete-request-5" + }, + "group-delete-response": { + "$ref": "#/components/schemas/delete-response-5" + }, + "group-restore-request": { + "$ref": "#/components/schemas/restore-request-3" + }, + "group-restore-response": { + "$ref": "#/components/schemas/restore-response-3" + }, + "example-group-create-request": { + "$ref": "#/components/schemas/example-create-request-4" + }, + "example-group-create-response": { + "$ref": "#/components/schemas/example-create-response-4" + }, + "example-group-modify-request": { + "$ref": "#/components/schemas/example-modify-request-5" + }, + "example-group-modify-response": { + "$ref": "#/components/schemas/example-modify-response-5" + }, + "example-group-list-request": { + "$ref": "#/components/schemas/example-list-request-7" + }, + "example-group-list-response-list_obj-user": { + "$ref": "#/components/schemas/example-list-response-list_obj-user" + }, + "example-group-list-response-list_obj-conv": { + "$ref": "#/components/schemas/example-list-response-list_obj-conv" + }, + "example-group-delete-request": { + "$ref": "#/components/schemas/example-delete-request-5" + }, + "example-group-delete-response": { + "$ref": "#/components/schemas/example-delete-response-5" + }, + "example-group-restore-request": { + "$ref": "#/components/schemas/example-restore-request-3" + }, + "example-group-restore-response": { + "$ref": "#/components/schemas/example-restore-response-3" + }, + "instance-create-request": { + "$ref": "#/components/schemas/create-request-6" + }, + "instance-create-response": { + "$ref": "#/components/schemas/create-response-6" + }, + "instance-check-request": { + "$ref": "#/components/schemas/check-request" + }, + "instance-check-response": { + "$ref": "#/components/schemas/check-response" + }, + "instance-modify-request": { + "$ref": "#/components/schemas/modify-request-6" + }, + "instance-modify-response": { + "$ref": "#/components/schemas/modify-response-6" + }, + "instance-list-request": { + "$ref": "#/components/schemas/list-request-8" + }, + "instance-list-response": { + "$ref": "#/components/schemas/list-response-8" + }, + "instance-show-request": { + "$ref": "#/components/schemas/show-request-5" + }, + "instance-show-response": { + "$ref": "#/components/schemas/show-response-6" + }, + "instance-link-request": { + "$ref": "#/components/schemas/link-request-3" + }, + "instance-link-response": { + "$ref": "#/components/schemas/link-response-3" + }, + "instance-favorite-request": { + "$ref": "#/components/schemas/favorite-request-3" + }, + "instance-favorite-response": { + "$ref": "#/components/schemas/favorite-response-3" + }, + "instance-delete-request": { + "$ref": "#/components/schemas/delete-request-6" + }, + "instance-delete-response": { + "$ref": "#/components/schemas/delete-response-6" + }, + "instance-restore-request": { + "$ref": "#/components/schemas/restore-request-4" + }, + "instance-restore-response": { + "$ref": "#/components/schemas/restore-response-4" + }, + "instance-destroy-request": { + "$ref": "#/components/schemas/destroy-request-3" + }, + "instance-destroy-response": { + "$ref": "#/components/schemas/destroy-response-3" + }, + "example-instance-create-request": { + "$ref": "#/components/schemas/example-create-request-5" + }, + "example-instance-create-response": { + "$ref": "#/components/schemas/example-create-response-5" + }, + "example-instance-check-request": { + "$ref": "#/components/schemas/example-check-request" + }, + "example-instance-check-response": { + "$ref": "#/components/schemas/example-check-response" + }, + "example-instance-modify-request": { + "$ref": "#/components/schemas/example-modify-request-6" + }, + "example-instance-modify-response": { + "$ref": "#/components/schemas/example-modify-response-6" + }, + "example-instance-list-request": { + "$ref": "#/components/schemas/example-list-request-8" + }, + "example-instance-list-response": { + "$ref": "#/components/schemas/example-list-response-7" + }, + "example-instance-show-request": { + "$ref": "#/components/schemas/example-show-request-5" + }, + "example-instance-show-response": { + "$ref": "#/components/schemas/example-show-response-5" + }, + "example-instance-link-request": { + "$ref": "#/components/schemas/example-link-request-3" + }, + "example-instance-link-response": { + "$ref": "#/components/schemas/example-link-response-3" + }, + "example-instance-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request-3" + }, + "example-instance-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response-3" + }, + "example-instance-delete-request": { + "$ref": "#/components/schemas/example-delete-request-6" + }, + "example-instance-delete-response": { + "$ref": "#/components/schemas/example-delete-response-6" + }, + "example-instance-restore-request": { + "$ref": "#/components/schemas/example-restore-request-4" + }, + "example-instance-restore-response": { + "$ref": "#/components/schemas/example-restore-response-4" + }, + "example-instance-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-3" + }, + "example-instance-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-3" + }, + "version-create-request": { + "$ref": "#/components/schemas/create-request-7" + }, + "version-create-response": { + "$ref": "#/components/schemas/create-response-7" + }, + "version-modify-request": { + "$ref": "#/components/schemas/modify-request-7" + }, + "version-modify-response": { + "$ref": "#/components/schemas/modify-response-7" + }, + "version-get-request": { + "$ref": "#/components/schemas/get-request" + }, + "version-get-response": { + "$ref": "#/components/schemas/get-response" + }, + "version-delete-request": { + "$ref": "#/components/schemas/delete-request-7" + }, + "version-delete-response": { + "$ref": "#/components/schemas/delete-response-7" + }, + "version-restore-request": { + "$ref": "#/components/schemas/restore-request-5" + }, + "version-restore-response": { + "$ref": "#/components/schemas/restore-response-5" + }, + "version-destroy-request": { + "$ref": "#/components/schemas/destroy-request-4" + }, + "version-destroy-response": { + "$ref": "#/components/schemas/destroy-response-4" + }, + "example-version-create-request": { + "$ref": "#/components/schemas/example-create-request-6" + }, + "example-version-create-response": { + "$ref": "#/components/schemas/example-create-response-6" + }, + "example-version-modify-request": { + "$ref": "#/components/schemas/example-modify-request-7" + }, + "example-version-modify-response": { + "$ref": "#/components/schemas/example-modify-response-7" + }, + "example-version-get-request": { + "$ref": "#/components/schemas/example-get-request" + }, + "example-version-get-response": { + "$ref": "#/components/schemas/example-get-response" + }, + "example-version-delete-request": { + "$ref": "#/components/schemas/example-delete-request-7" + }, + "example-version-delete-response": { + "$ref": "#/components/schemas/example-delete-response-7" + }, + "example-version-restore-request": { + "$ref": "#/components/schemas/example-restore-request-5" + }, + "example-version-restore-response": { + "$ref": "#/components/schemas/example-restore-response-5" + }, + "example-version-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-4" + }, + "example-version-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-4" + }, + "versions-list-request": { + "$ref": "#/components/schemas/list-request-9" + }, + "versions-list-response": { + "$ref": "#/components/schemas/list-response-9" + }, + "example-versions-list-request": { + "$ref": "#/components/schemas/example-list-request-9" + }, + "example-versions-list-response": { + "$ref": "#/components/schemas/example-list-response-8" + }, + "company-create-request": { + "$ref": "#/components/schemas/create-request-8" + }, + "company-create-response": { + "$ref": "#/components/schemas/create-response-8" + }, + "company-list-request": { + "$ref": "#/components/schemas/list-request-10" + }, + "company-list-response": { + "$ref": "#/components/schemas/list-response-10" + }, + "example-company-create-request": { + "$ref": "#/components/schemas/example-create-request-7" + }, + "example-company-create-response": { + "$ref": "#/components/schemas/example-create-response-7" + }, + "example-company-list-request": { + "$ref": "#/components/schemas/example-list-request-10" + }, + "example-company-list-response": { + "$ref": "#/components/schemas/example-list-response-9" + }, + "multitenant-company-create-request": { + "$ref": "#/components/schemas/multitenant-create-request" + }, + "multitenant-company-create-response": { + "$ref": "#/components/schemas/multitenant-create-response" + }, + "multitenant-company-modify-request": { + "$ref": "#/components/schemas/multitenant-modify-request" + }, + "multitenant-company-modify-response": { + "$ref": "#/components/schemas/multitenant-modify-response" + }, + "multitenant-company-delete-request": { + "$ref": "#/components/schemas/multitenant-delete-request" + }, + "multitenant-company-delete-response": { + "$ref": "#/components/schemas/multitenant-delete-response" + }, + "example-multitenant-company-create-request": { + "$ref": "#/components/schemas/example-multitenant-create-request" + }, + "example-multitenant-company-create-response": { + "$ref": "#/components/schemas/example-multitenant-create-response" + }, + "example-multitenant-company-modify-request": { + "$ref": "#/components/schemas/example-multitenant-modify-request" + }, + "example-multitenant-company-modify-response": { + "$ref": "#/components/schemas/example-multitenant-modify-response" + }, + "example-multitenant-company-list-request": { + "$ref": "#/components/schemas/example-list-request-10" + }, + "example-multitenant-company-list-response": { + "$ref": "#/components/schemas/example-list-response-9" + }, + "example-multitenant-company-delete-request": { + "$ref": "#/components/schemas/example-multitenant-delete-request" + }, + "example-multitenant-company-delete-response": { + "$ref": "#/components/schemas/example-multitenant-delete-response" + }, + "company_keys-show-request": { + "$ref": "#/components/schemas/show-request-6" + }, + "company_keys-show-response": { + "$ref": "#/components/schemas/show-response-7" + }, + "example-company_keys-show-request": { + "$ref": "#/components/schemas/example-show-request-6" + }, + "example-company_keys-show-response": { + "$ref": "#/components/schemas/example-show-response-6" + }, + "company_users-list-request": { + "$ref": "#/components/schemas/list-request-11" + }, + "company_users-list-response": { + "$ref": "#/components/schemas/list-response-11" + }, + "example-company_users-list-request": { + "$ref": "#/components/schemas/example-list-request-11" + }, + "example-company_users-list-response-user": { + "$ref": "#/components/schemas/example-list-response-user" + }, + "example-company_users-list-response-user-superadmin": { + "$ref": "#/components/schemas/example-list-response-user-superadmin" + }, + "example-company_users-list-response-group": { + "$ref": "#/components/schemas/example-list-response-group" + }, + "example-company_users-list-response-shared": { + "$ref": "#/components/schemas/example-list-response-shared" + }, + "example-company_users-list-response-api_key": { + "$ref": "#/components/schemas/example-list-response-api_key" + }, + "user-create-request": { + "$ref": "#/components/schemas/create-request-9" + }, + "user-create-response": { + "$ref": "#/components/schemas/create-response-9" + }, + "user-create-request-private": { + "$ref": "#/components/schemas/create-request-private" + }, + "user-create-response-private": { + "$ref": "#/components/schemas/create-response-private" + }, + "user-modify-request": { + "$ref": "#/components/schemas/modify-request-8" + }, + "user-modify-response": { + "$ref": "#/components/schemas/modify-response-8" + }, + "user-link-request": { + "$ref": "#/components/schemas/link-request-4" + }, + "user-link-response": { + "$ref": "#/components/schemas/link-response-4" + }, + "user-show-request": { + "$ref": "#/components/schemas/show-request-7" + }, + "user-show-response": { + "$ref": "#/components/schemas/show-response-8" + }, + "user-delete-request": { + "$ref": "#/components/schemas/delete-request-8" + }, + "user-delete-response": { + "$ref": "#/components/schemas/delete-response-8" + }, + "example-user-create-request": { + "$ref": "#/components/schemas/example-create-request-8" + }, + "example-user-create-response": { + "$ref": "#/components/schemas/example-create-response-8" + }, + "example-user-modify-request": { + "$ref": "#/components/schemas/example-modify-request-8" + }, + "example-user-modify-response": { + "$ref": "#/components/schemas/example-modify-response-8" + }, + "example-user-link-request": { + "$ref": "#/components/schemas/example-link-request-4" + }, + "example-user-link-response-api": { + "$ref": "#/components/schemas/example-link-response-4" + }, + "example-user-link-response-not-api": { + "$ref": "#/components/schemas/example-link-response-not_api" + }, + "example-user-show-request": { + "$ref": "#/components/schemas/example-show-request-7" + }, + "example-user-show-response-api": { + "$ref": "#/components/schemas/example-show-response-api" + }, + "example-user-show-response-api-not-api": { + "$ref": "#/components/schemas/example-show-response-not_api" + }, + "example-user-delete-request": { + "$ref": "#/components/schemas/example-delete-request-8" + }, + "example-user-delete-response": { + "$ref": "#/components/schemas/example-delete-response-8" + }, + "alias-create-request": { + "$ref": "#/components/schemas/create-request-10" + }, + "alias-create-response": { + "$ref": "#/components/schemas/create-response-10" + }, + "alias-modify-request": { + "$ref": "#/components/schemas/modify-request-9" + }, + "alias-modify-response": { + "$ref": "#/components/schemas/modify-response-9" + }, + "alias-show-request": { + "$ref": "#/components/schemas/show-request-8" + }, + "alias-show-response": { + "$ref": "#/components/schemas/show-response-9" + }, + "alias-delete-request": { + "$ref": "#/components/schemas/delete-request-9" + }, + "alias-delete-response": { + "$ref": "#/components/schemas/delete-response-9" + }, + "alias-favorite-request": { + "$ref": "#/components/schemas/favorite-request-4" + }, + "alias-favorite-response": { + "$ref": "#/components/schemas/favorite-response-4" + }, + "alias-link-request": { + "$ref": "#/components/schemas/link-request-5" + }, + "alias-link-response": { + "$ref": "#/components/schemas/link-response-5" + }, + "alias-upsert-request": { + "$ref": "#/components/schemas/upsert-request" + }, + "alias-upsert-response": { + "$ref": "#/components/schemas/upsert-response" + }, + "alias-destroy-request": { + "$ref": "#/components/schemas/destroy-request-5" + }, + "alias-destroy-response": { + "$ref": "#/components/schemas/destroy-response-5" + }, + "example-alias-create-request": { + "$ref": "#/components/schemas/example-create-request-9" + }, + "example-alias-create-response": { + "$ref": "#/components/schemas/example-create-response-9" + }, + "example-alias-modify-request": { + "$ref": "#/components/schemas/example-modify-request-9" + }, + "example-alias-modify-response": { + "$ref": "#/components/schemas/example-modify-response-9" + }, + "example-alias-show-request": { + "$ref": "#/components/schemas/example-show-request-8" + }, + "example-alias-show-response": { + "$ref": "#/components/schemas/example-show-response-7" + }, + "example-alias-delete-request": { + "$ref": "#/components/schemas/example-delete-request-9" + }, + "example-alias-delete-response": { + "$ref": "#/components/schemas/example-delete-response-9" + }, + "example-alias-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request-4" + }, + "example-alias-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response-4" + }, + "example-alias-link-request": { + "$ref": "#/components/schemas/example-link-request-5" + }, + "example-alias-link-response": { + "$ref": "#/components/schemas/example-link-response-5" + }, + "example-alias-upsert-request": { + "$ref": "#/components/schemas/example-upsert-request" + }, + "example-alias-upsert-response": { + "$ref": "#/components/schemas/example-upsert-response" + }, + "example-alias-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-5" + }, + "example-alias-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-5" + }, + "aliases-list-request": { + "$ref": "#/components/schemas/list-request-12" + }, + "aliases-list-response": { + "$ref": "#/components/schemas/list-response-12" + }, + "example-aliases-list-request": { + "$ref": "#/components/schemas/example-list-request-12" + }, + "example-aliases-list-response": { + "$ref": "#/components/schemas/example-list-response-10" + }, + "conv-create-request": { + "$ref": "#/components/schemas/create-request-11" + }, + "conv-create-response": { + "$ref": "#/components/schemas/create-response-11" + }, + "conv-modify-request": { + "$ref": "#/components/schemas/modify-request-10" + }, + "conv-modify-response": { + "$ref": "#/components/schemas/modify-response-10" + }, + "conv-list-request": { + "$ref": "#/components/schemas/list-request-13" + }, + "conv-list-response": { + "$ref": "#/components/schemas/list-response-13" + }, + "conv-show-request": { + "$ref": "#/components/schemas/show-request-9" + }, + "conv-show-response": { + "$ref": "#/components/schemas/show-response-10" + }, + "conv-link-request": { + "$ref": "#/components/schemas/link-request-6" + }, + "conv-link-response": { + "$ref": "#/components/schemas/link-response-6" + }, + "conv-favorite-request": { + "$ref": "#/components/schemas/favorite-request-5" + }, + "conv-favorite-response": { + "$ref": "#/components/schemas/favorite-response-5" + }, + "conv-delete-request": { + "$ref": "#/components/schemas/delete-request-10" + }, + "conv-delete-response": { + "$ref": "#/components/schemas/delete-response-10" + }, + "conv-restore-request": { + "$ref": "#/components/schemas/restore-request-6" + }, + "conv-restore-response": { + "$ref": "#/components/schemas/restore-response-6" + }, + "conv-destroy-request": { + "$ref": "#/components/schemas/destroy-request-6" + }, + "conv-destroy-response": { + "$ref": "#/components/schemas/destroy-response-6" + }, + "example-conv-create-request": { + "$ref": "#/components/schemas/example-create-request-10" + }, + "example-conv-create-response": { + "$ref": "#/components/schemas/example-create-response-10" + }, + "example-conv-modify-request": { + "$ref": "#/components/schemas/example-modify-request-10" + }, + "example-conv-modify-response": { + "$ref": "#/components/schemas/example-modify-response-10" + }, + "example-conv-list-request": { + "$ref": "#/components/schemas/example-list-request-13" + }, + "example-conv-list-response": { + "$ref": "#/components/schemas/example-list-response-11" + }, + "example-conv-list-request-group": { + "$ref": "#/components/schemas/example-list-request-group" + }, + "example-conv-list-response-group": { + "$ref": "#/components/schemas/example-list-response-group-2" + }, + "example-conv-show-request": { + "$ref": "#/components/schemas/example-show-request-9" + }, + "example-conv-show-response": { + "$ref": "#/components/schemas/example-show-response-8" + }, + "example-conv-link-request": { + "$ref": "#/components/schemas/example-link-request-6" + }, + "example-conv-link-response": { + "$ref": "#/components/schemas/example-link-response-6" + }, + "example-conv-link2key_one_privilege-request": { + "$ref": "#/components/schemas/example-link2key_one_privilege-request" + }, + "example-conv-link2key_one_privilege-response": { + "$ref": "#/components/schemas/example-link2key_one_privilege-response" + }, + "example-conv-link2group_two_privileges-request": { + "$ref": "#/components/schemas/example-link2group_two_privileges-request" + }, + "example-conv-link2group_two_privileges-response": { + "$ref": "#/components/schemas/example-link2group_two_privileges-response" + }, + "example-conv-link2user_not_in_company-request": { + "$ref": "#/components/schemas/example-link2user_not_in_company-request" + }, + "example-conv-link2user_not_in_company-response": { + "$ref": "#/components/schemas/example-link2user_not_in_company-response" + }, + "example-conv-link-unlink_key-request": { + "$ref": "#/components/schemas/example-link-unlink_key-request" + }, + "example-conv-link-unlink_key-response": { + "$ref": "#/components/schemas/example-link-unlink_key-response" + }, + "example-conv-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request-5" + }, + "example-conv-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response-5" + }, + "example-conv-favorite-request-stage": { + "$ref": "#/components/schemas/example-favorite-request-stage" + }, + "example-conv-favorite-response-stage": { + "$ref": "#/components/schemas/example-favorite-response-stage" + }, + "example-conv-delete-request": { + "$ref": "#/components/schemas/example-delete-request-10" + }, + "example-conv-delete-response": { + "$ref": "#/components/schemas/example-delete-response-10" + }, + "example-conv-delete-request-stage": { + "$ref": "#/components/schemas/example-delete-request-stage" + }, + "example-conv-delete-response-stage": { + "$ref": "#/components/schemas/example-delete-response-stage" + }, + "example-conv-restore-request": { + "$ref": "#/components/schemas/example-restore-request-6" + }, + "example-conv-restore-response": { + "$ref": "#/components/schemas/example-restore-response-6" + }, + "example-conv-restore-request-stage": { + "$ref": "#/components/schemas/example-restore-request-stage" + }, + "example-conv-restore-response-stage": { + "$ref": "#/components/schemas/example-restore-response-stage" + }, + "example-conv-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-6" + }, + "example-conv-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-6" + }, + "example-conv-destroy-request-stage": { + "$ref": "#/components/schemas/example-destroy-request-stage" + }, + "example-conv-destroy-response-stage": { + "$ref": "#/components/schemas/example-destroy-response-stage" + }, + "convs-list-request": { + "$ref": "#/components/schemas/list-request-14" + }, + "convs-list-response": { + "$ref": "#/components/schemas/list-response-14" + }, + "example-convs-list-request": { + "$ref": "#/components/schemas/example-list-request-14" + }, + "example-convs-list-response": { + "$ref": "#/components/schemas/example-list-response-12" + }, + "folder-create-request": { + "$ref": "#/components/schemas/create-request-12" + }, + "folder-create-response": { + "$ref": "#/components/schemas/create-response-12" + }, + "folder-modify-request": { + "$ref": "#/components/schemas/modify-request-11" + }, + "folder-modify-response": { + "$ref": "#/components/schemas/modify-response-11" + }, + "folder-link-request": { + "$ref": "#/components/schemas/link-request-7" + }, + "folder-link-response": { + "$ref": "#/components/schemas/link-response-7" + }, + "folder-list-request": { + "$ref": "#/components/schemas/list-request-15" + }, + "folder-list-response": { + "$ref": "#/components/schemas/list-response-15" + }, + "folder-list-response-group": { + "$ref": "#/components/schemas/list-response-group" + }, + "folder-show-request": { + "$ref": "#/components/schemas/show-request-10" + }, + "folder-show-response": { + "$ref": "#/components/schemas/show-response-11" + }, + "folder-favorite-request": { + "$ref": "#/components/schemas/favorite-request-6" + }, + "folder-favorite-response": { + "$ref": "#/components/schemas/favorite-response-6" + }, + "folder-delete-request": { + "$ref": "#/components/schemas/delete-request-11" + }, + "folder-delete-response": { + "$ref": "#/components/schemas/delete-response-11" + }, + "folder-destroy-request": { + "$ref": "#/components/schemas/destroy-request-7" + }, + "folder-destroy-response": { + "$ref": "#/components/schemas/destroy-response-7" + }, + "folder-restore-request": { + "$ref": "#/components/schemas/restore-request-7" + }, + "folder-restore-response": { + "$ref": "#/components/schemas/restore-response-7" + }, + "example-folder-create-request": { + "$ref": "#/components/schemas/example-create-request-11" + }, + "example-folder-create-response": { + "$ref": "#/components/schemas/example-create-response-11" + }, + "example-folder-modify-request": { + "$ref": "#/components/schemas/example-modify-request-11" + }, + "example-folder-modify-response": { + "$ref": "#/components/schemas/example-modify-response-11" + }, + "example-folder-link-request": { + "$ref": "#/components/schemas/example-link-request-7" + }, + "example-folder-link-response": { + "$ref": "#/components/schemas/example-link-response-7" + }, + "example-folder-link-request-moving": { + "$ref": "#/components/schemas/example-link-request-moving" + }, + "example-folder-link-response-moving": { + "$ref": "#/components/schemas/example-link-response-moving" + }, + "example-folder-link-request-unlink": { + "$ref": "#/components/schemas/example-link-request-unlink" + }, + "example-folder-link-response-unlink": { + "$ref": "#/components/schemas/example-link-response-unlink" + }, + "example-folder-list-request": { + "$ref": "#/components/schemas/example-list-request-15" + }, + "example-folder-list-response": { + "$ref": "#/components/schemas/example-list-response-13" + }, + "example-folder-list-response-group": { + "$ref": "#/components/schemas/example-list-response-group-3" + }, + "example-folder-show-request": { + "$ref": "#/components/schemas/example-show-request-10" + }, + "example-folder-show-response": { + "$ref": "#/components/schemas/example-show-response-9" + }, + "example-folder-favorite-request": { + "$ref": "#/components/schemas/example-favorite-request-6" + }, + "example-folder-favorite-response": { + "$ref": "#/components/schemas/example-favorite-response-6" + }, + "example-folder-delete-request": { + "$ref": "#/components/schemas/example-delete-request-11" + }, + "example-folder-delete-response": { + "$ref": "#/components/schemas/example-delete-response-11" + }, + "example-folder-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-7" + }, + "example-folder-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-7" + }, + "example-folder-restore-request": { + "$ref": "#/components/schemas/example-restore-request-7" + }, + "example-folder-restore-response": { + "$ref": "#/components/schemas/example-restore-response-7" + }, + "path_to_folder-list-request": { + "$ref": "#/components/schemas/list-request-16" + }, + "path_to_folder-list-response": { + "$ref": "#/components/schemas/list-response-16" + }, + "example-path_to_folder-list-request": { + "$ref": "#/components/schemas/example-list-request-16" + }, + "example-path_to_folder-list-response": { + "$ref": "#/components/schemas/example-list-response-14" + }, + "folder_branch-list-request": { + "$ref": "#/components/schemas/list-request-17" + }, + "folder_branch-list-response": { + "$ref": "#/components/schemas/list-response-17" + }, + "example-folder_branch-list-request": { + "$ref": "#/components/schemas/example-list-request-17" + }, + "example-folder_branch-list-response": { + "$ref": "#/components/schemas/example-list-response-15" + }, + "stage-create-request": { + "$ref": "#/components/schemas/create-request-13" + }, + "stage-create-response": { + "$ref": "#/components/schemas/create-response-13" + }, + "stage-modify-request": { + "$ref": "#/components/schemas/modify-request-12" + }, + "stage-modify-response": { + "$ref": "#/components/schemas/modify-response-12" + }, + "stage-list-request": { + "$ref": "#/components/schemas/list-request-18" + }, + "stage-list-response": { + "$ref": "#/components/schemas/list-response-18" + }, + "stage-list-response-uncommited": { + "$ref": "#/components/schemas/list-response-uncommited" + }, + "stage-list-response-group": { + "$ref": "#/components/schemas/list-response-group-2" + }, + "stage-show-request": { + "$ref": "#/components/schemas/show-request-11" + }, + "stage-show-response": { + "$ref": "#/components/schemas/show-response-12" + }, + "stage-link-request": { + "$ref": "#/components/schemas/link-request-8" + }, + "stage-link-response": { + "$ref": "#/components/schemas/link-response-8" + }, + "stage-delete-request": { + "$ref": "#/components/schemas/delete-request-12" + }, + "stage-delete-response": { + "$ref": "#/components/schemas/delete-response-12" + }, + "stage-restore-request": { + "$ref": "#/components/schemas/restore-request-8" + }, + "stage-restore-response": { + "$ref": "#/components/schemas/restore-response-8" + }, + "stage-destroy-request": { + "$ref": "#/components/schemas/destroy-request-8" + }, + "stage-destroy-response": { + "$ref": "#/components/schemas/destroy-response-8" + }, + "example-stage-create-request": { + "$ref": "#/components/schemas/example-create-request-12" + }, + "example-stage-create-response": { + "$ref": "#/components/schemas/example-create-response-12" + }, + "example-stage-modify-request": { + "$ref": "#/components/schemas/example-modify-request-12" + }, + "example-stage-modify-response": { + "$ref": "#/components/schemas/example-modify-response-12" + }, + "example-stage-list-request": { + "$ref": "#/components/schemas/example-list-request-18" + }, + "example-stage-list-response": { + "$ref": "#/components/schemas/example-list-response-16" + }, + "example-stage-list-group-response": { + "$ref": "#/components/schemas/example-list-group-response" + }, + "example-stage-list-uncommited-response": { + "$ref": "#/components/schemas/example-list-uncommited-response" + }, + "example-stage-show-request": { + "$ref": "#/components/schemas/example-show-request-11" + }, + "example-stage-show-response": { + "$ref": "#/components/schemas/example-show-response-10" + }, + "example-stage-link-request": { + "$ref": "#/components/schemas/example-link-request-8" + }, + "example-stage-link-response": { + "$ref": "#/components/schemas/example-link-response-8" + }, + "example-stage-delete-request": { + "$ref": "#/components/schemas/example-delete-request-12" + }, + "example-stage-delete-response": { + "$ref": "#/components/schemas/example-delete-response-12" + }, + "example-stage-restore-request": { + "$ref": "#/components/schemas/example-restore-request-8" + }, + "example-stage-restore-response": { + "$ref": "#/components/schemas/example-restore-response-8" + }, + "example-stage-destroy-request": { + "$ref": "#/components/schemas/example-destroy-request-8" + }, + "example-stage-destroy-response": { + "$ref": "#/components/schemas/example-destroy-response-8" + }, + "used_traff-show-request": { + "$ref": "#/components/schemas/show-request-12" + }, + "used_traff-show-response": { + "$ref": "#/components/schemas/show-response-13" + }, + "example-used_traff-show-request": { + "$ref": "#/components/schemas/example-show-request-12" + }, + "example-used_traff-show-response": { + "$ref": "#/components/schemas/example-show-response-11" + }, + "sys_stat-show-request": { + "$ref": "#/components/schemas/show-request-13" + }, + "sys_stat-show-response": { + "$ref": "#/components/schemas/show-response-14" + }, + "example-sys_stat-show-request": { + "$ref": "#/components/schemas/example-show-request-13" + }, + "example-sys_stat-show-response": { + "$ref": "#/components/schemas/example-show-response-12" + }, + "multitenant-sys_stat-show-request": { + "$ref": "#/components/schemas/multitenant-show-request" + }, + "multitenant-sys_stat-show-response": { + "$ref": "#/components/schemas/multitenant-show-response" + }, + "example-multitenant-sys_stat-show-request-company": { + "$ref": "#/components/schemas/example-multitenant-show-request-company" + }, + "example-multitenant-sys_stat-show-request-instance": { + "$ref": "#/components/schemas/example-multitenant-show-request-instance" + }, + "example-multitenant-sys_stat-show-request-process": { + "$ref": "#/components/schemas/example-multitenant-show-request-process" + }, + "example-multitenant-sys_stat-show-response-company": { + "$ref": "#/components/schemas/example-multitenant-show-response-company" + }, + "example-multitenant-sys_stat-show-response-instance": { + "$ref": "#/components/schemas/example-multitenant-show-response-instance" + }, + "example-multitenant-sys_stat-show-response-process": { + "$ref": "#/components/schemas/example-multitenant-show-response-process" + }, + "invite-create-request": { + "$ref": "#/components/schemas/create-request-14" + }, + "invite-create-response": { + "$ref": "#/components/schemas/create-response-14" + }, + "invite-delete-request": { + "$ref": "#/components/schemas/delete-request-13" + }, + "invite-delete-response": { + "$ref": "#/components/schemas/delete-response-13" + }, + "example-invite-create-request": { + "$ref": "#/components/schemas/example-create-request-13" + }, + "example-invite-create-response": { + "$ref": "#/components/schemas/example-create-response-13" + }, + "example-invite-delete-request": { + "$ref": "#/components/schemas/example-delete-request-13" + }, + "example-invite-delete-response": { + "$ref": "#/components/schemas/example-delete-response-13" + }, + "owner-modify-request": { + "$ref": "#/components/schemas/modify-request-13" + }, + "owner-modify-response": { + "$ref": "#/components/schemas/modify-response-13" + }, + "example-owner-modify-request-id": { + "$ref": "#/components/schemas/example-modify-request-id" + }, + "example-owner-modify-request-login": { + "$ref": "#/components/schemas/example-modify-request-login" + }, + "example-owner-modify-response": { + "$ref": "#/components/schemas/example-modify-response-13" + }, + "user_to_company-link-request": { + "$ref": "#/components/schemas/link-request-9" + }, + "user_to_company-link-response": { + "$ref": "#/components/schemas/link-response-9" + }, + "example-user_to_company-link-request": { + "$ref": "#/components/schemas/example-link-request-9" + }, + "example-user_to_company-link-response": { + "$ref": "#/components/schemas/example-link-response-9" + }, + "conv_params-list-request": { + "$ref": "#/components/schemas/list-request-19" + }, + "conv_params-list-response": { + "$ref": "#/components/schemas/list-response-19" + }, + "conv_params-modify-request": { + "$ref": "#/components/schemas/modify-request-14" + }, + "conv_params-modify-response": { + "$ref": "#/components/schemas/modify-response-14" + }, + "example-conv_params-list-request": { + "$ref": "#/components/schemas/example-list-request-19" + }, + "example-conv_params-list-response": { + "$ref": "#/components/schemas/example-list-response-17" + }, + "example-conv_params-modify-request": { + "$ref": "#/components/schemas/example-modify-request-13" + }, + "example-conv_params-modify-response": { + "$ref": "#/components/schemas/example-modify-response-14" + }, + "history-list-request-objects": { + "$ref": "#/components/schemas/list-request-objects" + }, + "history-list-response-objects": { + "$ref": "#/components/schemas/list-response-objects" + }, + "history-list-request-operations": { + "$ref": "#/components/schemas/list-request-operations" + }, + "history-list-response-operations": { + "$ref": "#/components/schemas/list-response-operations" + }, + "example-history-list-request-objects": { + "$ref": "#/components/schemas/example-list-request-objects" + }, + "example-history-list-request-operations": { + "$ref": "#/components/schemas/example-list-request-operations" + }, + "example-history-list-response-objects": { + "$ref": "#/components/schemas/example-list-response-objects" + }, + "example-history-list-response-operations": { + "$ref": "#/components/schemas/example-list-response-operations" + }, + "stat-show-request": { + "$ref": "#/components/schemas/show-request-14" + }, + "stat-show-response": { + "$ref": "#/components/schemas/show-response-15" + }, + "example-stat-show-request-onenode": { + "$ref": "#/components/schemas/example-show-request-onenode" + }, + "example-stat-show-response-onenode": { + "$ref": "#/components/schemas/example-show-response-onenode" + }, + "example-stat-show-request-allnodes": { + "$ref": "#/components/schemas/example-show-request-allnodes" + }, + "example-stat-show-response-allnodes": { + "$ref": "#/components/schemas/example-show-response-allnodes" + }, + "task_history-list-request": { + "$ref": "#/components/schemas/list-request-20" + }, + "task_history-list-response": { + "$ref": "#/components/schemas/list-response-20" + }, + "example-task_history-list-request": { + "$ref": "#/components/schemas/example-list-request-20" + }, + "example-task_history-list-response": { + "$ref": "#/components/schemas/example-list-response-18" + }, + "commit-confirm-request": { + "$ref": "#/components/schemas/confirm-request" + }, + "commit-confirm-response": { + "$ref": "#/components/schemas/confirm-response" + }, + "commit-show-request": { + "$ref": "#/components/schemas/show-request-15" + }, + "commit-show-response": { + "$ref": "#/components/schemas/show-response-16" + }, + "commit-delete-request": { + "$ref": "#/components/schemas/delete-request-14" + }, + "commit-delete-response": { + "$ref": "#/components/schemas/delete-response-14" + }, + "example-commit-confirm-request": { + "$ref": "#/components/schemas/example-confirm-request" + }, + "example-commit-confirm-response": { + "$ref": "#/components/schemas/example-confirm-response" + }, + "example-commit-show-request": { + "$ref": "#/components/schemas/example-show-request-14" + }, + "example-commit-show-response": { + "$ref": "#/components/schemas/example-show-response-13" + }, + "example-commit-delete-request": { + "$ref": "#/components/schemas/example-delete-request-14" + }, + "example-commit-delete-response": { + "$ref": "#/components/schemas/example-delete-response-14" + }, + "commits-list-request": { + "$ref": "#/components/schemas/list-request-21" + }, + "commits-list-response": { + "$ref": "#/components/schemas/list-response-21" + }, + "example-commits-list-request": { + "$ref": "#/components/schemas/example-list-request-21" + }, + "example-commits-list-response": { + "$ref": "#/components/schemas/example-list-response-19" + }, + "obj_scheme_upload-create-request": { + "$ref": "#/components/schemas/create-request-15" + }, + "obj_scheme_upload-create-response": { + "$ref": "#/components/schemas/create-response-15" + }, + "obj_scheme_upload-validate-request": { + "$ref": "#/components/schemas/validate-request" + }, + "obj_scheme_upload-validate-response": { + "$ref": "#/components/schemas/validate-response" + }, + "example-obj_scheme_upload-create-request": { + "$ref": "#/components/schemas/example-create-request-14" + }, + "example-obj_scheme_upload-create-response": { + "$ref": "#/components/schemas/example-create-response-14" + }, + "example-obj_scheme_upload-create_async_false-request": { + "$ref": "#/components/schemas/example-create_async_false-request" + }, + "example-obj_scheme_upload-create_async_false-response": { + "$ref": "#/components/schemas/example-create_async_false-response" + }, + "example-obj_scheme_upload-validate-request": { + "$ref": "#/components/schemas/example-validate-request" + }, + "example-obj_scheme_upload-validate-response": { + "$ref": "#/components/schemas/example-validate-response" + }, + "obj_scheme_download-download-request": { + "$ref": "#/components/schemas/download-request" + }, + "obj_scheme_download-download-response": { + "$ref": "#/components/schemas/download-response" + }, + "example-obj_scheme_download-download-request": { + "$ref": "#/components/schemas/example-download-request" + }, + "example-obj_scheme_download-download-response": { + "$ref": "#/components/schemas/example-download-response" + }, + "obj_scheme_compare-compare-request": { + "$ref": "#/components/schemas/compare-request" + }, + "obj_scheme_compare-compare-response": { + "$ref": "#/components/schemas/compare-response" + }, + "example-obj_scheme_compare-compare-response": { + "$ref": "#/components/schemas/example-compare-response" + }, + "example-obj_scheme_compare-compare_diff_status_false-response": { + "$ref": "#/components/schemas/example-compare_diff_status_false-response" + }, + "example-obj_scheme_compare-compare_num_stat_true-response": { + "$ref": "#/components/schemas/example-compare_diff_status_false_num_stat_true-response" + }, + "example-obj_scheme_compare-compare_num_stat_true2-request": { + "$ref": "#/components/schemas/example-compare_num_stat_true-request" + }, + "example-obj_scheme_compare-compare_num_stat_true2-response": { + "$ref": "#/components/schemas/example-compare_num_stat_true-response" + }, + "obj_scheme_merge-merge-request": { + "$ref": "#/components/schemas/merge-request" + }, + "example-obj_scheme_merge-merge-request": { + "$ref": "#/components/schemas/example-merge-request" + }, + "example-obj_scheme_merge-merge_async_false-request": { + "$ref": "#/components/schemas/example-merge_async_false-request" + }, + "obj_scheme_merge-merge-response": { + "$ref": "#/components/schemas/merge-response" + }, + "example-obj_scheme_merge-merge-response": { + "$ref": "#/components/schemas/example-merge-response" + }, + "example-obj_scheme_merge-merge_async_false-response": { + "$ref": "#/components/schemas/example-merge_async_false-response" + }, + "example-obj_scheme_merge-merge_apply_mode_false-response": { + "$ref": "#/components/schemas/example-merge_apply_mode_false-response" + }, + "obj_copy-copy-request": { + "$ref": "#/components/schemas/copy-request" + }, + "obj_copy-copy-response": { + "$ref": "#/components/schemas/copy-response" + }, + "obj_copy-copy-error_response": { + "$ref": "#/components/schemas/copy-error_response" + }, + "example-obj_copy-copy-request": { + "$ref": "#/components/schemas/example-copy-request" + }, + "example-obj_copy-copy-response": { + "$ref": "#/components/schemas/example-copy-response" + }, + "example-obj_copy-copy-error_response": { + "$ref": "#/components/schemas/example-copy-error_response" + }, + "example-obj_copy-copy_async_true-request": { + "$ref": "#/components/schemas/example-copy_async_true-request" + }, + "example-obj_copy-copy_async_true-response": { + "$ref": "#/components/schemas/example-copy_async_true-response" + }, + "node_download-download-request": { + "$ref": "#/components/schemas/download-request-2" + }, + "node_download-download-response": { + "$ref": "#/components/schemas/download-response-2" + }, + "example-node_download-download-request": { + "$ref": "#/components/schemas/example-download-request-2" + }, + "example-node_download-download-response": { + "$ref": "#/components/schemas/example-download-response-2" + }, + "version_upload-create-request": { + "$ref": "#/components/schemas/create-request-16" + }, + "version_upload-create-response": { + "$ref": "#/components/schemas/create-response-16" + }, + "example-version_upload-create-request": { + "$ref": "#/components/schemas/example-create-request-15" + }, + "example-version_upload-create-response": { + "$ref": "#/components/schemas/example-create-response-15" + }, + "example-version_upload-create-response-async": { + "$ref": "#/components/schemas/example-create-response-async" + }, + "task_upload-create-request": { + "$ref": "#/components/schemas/create-request-17" + }, + "task_upload-create-response": { + "$ref": "#/components/schemas/create-response-17" + }, + "example-task_upload-create-request": { + "$ref": "#/components/schemas/example-create-request-16" + }, + "example-task_upload-create-response": { + "$ref": "#/components/schemas/example-create-response-16" + }, + "example-task_upload-create_async_false-request": { + "$ref": "#/components/schemas/example-create_async_false-request-2" + }, + "example-task_upload-create_async_false-response": { + "$ref": "#/components/schemas/example-create_async_false-response-2" + }, + "object-get-request": { + "$ref": "#/components/schemas/get-request-2" + }, + "object-get-response": { + "$ref": "#/components/schemas/get-response-2" + }, + "example-object-get-request": { + "$ref": "#/components/schemas/example-get-request-2" + }, + "example-object-get-response": { + "$ref": "#/components/schemas/example-get-response-2" + }, + "callback_hash-create-request": { + "$ref": "#/components/schemas/create-request-18" + }, + "callback_hash-create-response": { + "$ref": "#/components/schemas/create-response-18" + }, + "callback_hash-modify-request": { + "$ref": "#/components/schemas/modify-request-15" + }, + "callback_hash-modify-response": { + "$ref": "#/components/schemas/modify-response-15" + }, + "callback_hash-get-request": { + "$ref": "#/components/schemas/get-request-3" + }, + "callback_hash-get-response": { + "$ref": "#/components/schemas/get-response-3" + }, + "callback_hash-delete-request": { + "$ref": "#/components/schemas/delete-request-15" + }, + "callback_hash-delete-response": { + "$ref": "#/components/schemas/delete-response-15" + }, + "example-callback_hash-create-request": { + "$ref": "#/components/schemas/example-create-request-17" + }, + "example-callback_hash-create-response": { + "$ref": "#/components/schemas/example-create-response-17" + }, + "example-callback_hash-modify-request": { + "$ref": "#/components/schemas/example-modify-request-14" + }, + "example-callback_hash-modify-response": { + "$ref": "#/components/schemas/example-modify-response-15" + }, + "example-callback_hash-modify-request-alias": { + "$ref": "#/components/schemas/example-modify-request-alias" + }, + "example-callback_hash-modify-response-alias": { + "$ref": "#/components/schemas/example-modify-response-alias" + }, + "example-callback_hash-get-request": { + "$ref": "#/components/schemas/example-get-request-3" + }, + "example-callback_hash-get-request-alias": { + "$ref": "#/components/schemas/example-get-request-alias" + }, + "example-callback_hash-get-response": { + "$ref": "#/components/schemas/example-get-response-3" + }, + "example-callback_hash-delete-request": { + "$ref": "#/components/schemas/example-delete-request-15" + }, + "example-callback_hash-delete-response": { + "$ref": "#/components/schemas/example-delete-response-15" + }, + "example-callback_hash-delete-request-alias": { + "$ref": "#/components/schemas/example-delete-request-alias" + }, + "example-callback_hash-delete-response-alias": { + "$ref": "#/components/schemas/example-delete-response-alias" + }, + "chart-create-request": { + "$ref": "#/components/schemas/create-request-19" + }, + "chart-create-response": { + "$ref": "#/components/schemas/create-response-19" + }, + "chart-modify-request": { + "$ref": "#/components/schemas/modify-request-16" + }, + "chart-modify-response": { + "$ref": "#/components/schemas/modify-response-16" + }, + "chart-get-request": { + "$ref": "#/components/schemas/get-request-4" + }, + "chart-get-response": { + "$ref": "#/components/schemas/get-response-4" + }, + "chart-delete-request": { + "$ref": "#/components/schemas/delete-request-16" + }, + "chart-delete-response": { + "$ref": "#/components/schemas/delete-response-16" + }, + "example-chart-create-request": { + "$ref": "#/components/schemas/example-create-request-18" + }, + "example-chart-create-response": { + "$ref": "#/components/schemas/example-create-response-18" + }, + "example-chart-modify-request": { + "$ref": "#/components/schemas/example-modify-request-15" + }, + "example-chart-modify-response": { + "$ref": "#/components/schemas/example-modify-response-16" + }, + "example-chart-get-request": { + "$ref": "#/components/schemas/example-get-request-4" + }, + "example-chart-get-request-alias": { + "$ref": "../schemas/objects/chart/example-get-request-alias.json" + }, + "example-chart-get-response": { + "$ref": "#/components/schemas/example-get-response-4" + }, + "example-chart-delete-request": { + "$ref": "#/components/schemas/example-delete-request-16" + }, + "example-chart-delete-response": { + "$ref": "#/components/schemas/example-delete-response-16" + }, + "git_call-create-request": { + "$ref": "#/components/schemas/create-request-20" + }, + "git_call-create-response": { + "$ref": "#/components/schemas/create-response-20" + }, + "git_call-compile-request": { + "$ref": "#/components/schemas/compile-request" + }, + "git_call-compile-response": { + "$ref": "#/components/schemas/compile-response" + }, + "git_call-get-request": { + "$ref": "#/components/schemas/get-request-5" + }, + "git_call-get-response": { + "$ref": "#/components/schemas/get-response-5" + }, + "git_call-load-request": { + "$ref": "#/components/schemas/load-request" + }, + "git_call-load-response": { + "$ref": "#/components/schemas/load-response" + }, + "git_call-clone-request": { + "$ref": "#/components/schemas/clone-request" + }, + "git_call-clone-response": { + "$ref": "#/components/schemas/clone-response" + }, + "git_call-reset-request": { + "$ref": "#/components/schemas/reset-request-2" + }, + "git_call-reset-response": { + "$ref": "#/components/schemas/reset-response-2" + }, + "example-git_call-create-request": { + "$ref": "#/components/schemas/example-create-request-19" + }, + "example-git_call-create-response": { + "$ref": "#/components/schemas/example-create-response-19" + }, + "example-git_call-compile-request": { + "$ref": "#/components/schemas/example-compile-request" + }, + "example-git_call-compile-response": { + "$ref": "#/components/schemas/example-compile-response" + }, + "example-git_call-get-request": { + "$ref": "#/components/schemas/example-get-request-5" + }, + "example-git_call-get-response-function": { + "$ref": "#/components/schemas/example-get-response-function" + }, + "example-git_call-get-response-function_build": { + "$ref": "#/components/schemas/example-get-response-function_build" + }, + "example-git_call-get-response-ssh_key": { + "$ref": "#/components/schemas/example-get-response-ssh_key" + }, + "example-git_call-load-request": { + "$ref": "#/components/schemas/example-load-request" + }, + "example-git_call-load-response": { + "$ref": "#/components/schemas/example-load-response" + }, + "example-git_call-clone-request": { + "$ref": "#/components/schemas/example-clone-request" + }, + "example-git_call-clone-response": { + "$ref": "#/components/schemas/example-clone-response" + }, + "example-git_call-reset-request": { + "$ref": "#/components/schemas/example-reset-request-2" + }, + "example-git_call-reset-response": { + "$ref": "#/components/schemas/example-reset-response-2" + }, + "obj_scheme-get-request": { + "$ref": "#/components/schemas/get-request-6" + }, + "obj_scheme-get-response": { + "$ref": "#/components/schemas/get-response-6" + }, + "obj_scheme-check-request": { + "$ref": "#/components/schemas/check-request-2" + }, + "obj_scheme-check-response": { + "$ref": "#/components/schemas/check-response-2" + }, + "example-obj_scheme-get-request": { + "$ref": "#/components/schemas/example-get-request-6" + }, + "example-obj_scheme-get-response": { + "$ref": "#/components/schemas/example-get-response-5" + }, + "example-obj_scheme-check-request": { + "$ref": "#/components/schemas/example-check-request-2" + }, + "example-obj_scheme-check-response": { + "$ref": "#/components/schemas/example-check-response-2" + }, + "example-obj_scheme-check-response-error": { + "$ref": "#/components/schemas/example-check-response-error" + }, + "api_key-show-request": { + "$ref": "#/components/schemas/show-request-16" + }, + "api_key-show-response": { + "$ref": "#/components/schemas/show-response-17" + }, + "example-api_key-show-request": { + "$ref": "#/components/schemas/example-show-request-15" + }, + "example-api_key-show-response": { + "$ref": "#/components/schemas/example-show-response-14" + }, + "upload-stop-request": { + "$ref": "#/components/schemas/stop-request" + }, + "upload-stop-response": { + "$ref": "#/components/schemas/stop-response" + }, + "example-upload-stop-request": { + "$ref": "#/components/schemas/example-stop-request" + }, + "example-upload-stop-response": { + "$ref": "#/components/schemas/example-stop-response" + }, + "objs-list-request": { + "$ref": "#/components/schemas/list-request-22" + }, + "objs-list-response": { + "$ref": "#/components/schemas/list-response-22" + }, + "example-objs-list-request": { + "$ref": "#/components/schemas/example-list-request-22" + }, + "example-objs-list-response": { + "$ref": "#/components/schemas/example-list-response-20" + }, + "example-objs-list-response-user": { + "$ref": "#/components/schemas/example-list-response-user-2" + }, + "example-objs-list-response-company": { + "$ref": "#/components/schemas/example-list-response-user-company" + }, + "global_counters-show-request": { + "$ref": "#/components/schemas/show-request-17" + }, + "global_counters-show-response": { + "$ref": "#/components/schemas/show-response-18" + }, + "example-global_counters-show-request": { + "$ref": "#/components/schemas/example-show-request-16" + }, + "example-global_counters-show-response": { + "$ref": "#/components/schemas/example-show-response-15" + }, + "conf-show-response": { + "$ref": "#/components/schemas/show-response" + }, + "example-conf-show-response": { + "$ref": "#/components/schemas/example-show-response-16" + }, + "bot_wizzard-create-request": { + "$ref": "#/components/schemas/create-request-21" + }, + "bot_wizzard-create-response": { + "$ref": "#/components/schemas/create-response-21" + }, + "bot_wizzard-modify-request": { + "$ref": "#/components/schemas/modify-request-17" + }, + "bot_wizzard-modify-response": { + "$ref": "#/components/schemas/modify-response-17" + }, + "bot_wizzard-check-request": { + "$ref": "#/components/schemas/check-request-3" + }, + "bot_wizzard-check-response": { + "$ref": "#/components/schemas/check-response-3" + }, + "example-bot_wizzard-create-request": { + "$ref": "#/components/schemas/example-create-request-20" + }, + "example-bot_wizzard-create-response-async-true": { + "$ref": "#/components/schemas/example-create-response-async-true" + }, + "example-bot_wizzard-create-response-async-false": { + "$ref": "#/components/schemas/example-create-response-async-false" + }, + "example-bot_wizzard-modify-request": { + "$ref": "#/components/schemas/example-modify-request-16" + }, + "example-bot_wizzard-modify-response": { + "$ref": "#/components/schemas/example-modify-response-17" + }, + "example-bot_wizzard-check-request": { + "$ref": "#/components/schemas/example-check-request-3" + }, + "example-bot_wizzard-check-response": { + "$ref": "#/components/schemas/example-check-response-3" + }, + "channel-create-request": { + "$ref": "#/components/schemas/create-request-22" + }, + "channel-create-response": { + "$ref": "#/components/schemas/create-response-22" + }, + "channel-modify-request": { + "$ref": "#/components/schemas/modify-request-18" + }, + "channel-modify-response": { + "$ref": "#/components/schemas/modify-response-18" + }, + "example-channel-create-request": { + "$ref": "#/components/schemas/example-create-request-21" + }, + "example-channel-create-response": { + "$ref": "#/components/schemas/example-create-response-20" + }, + "example-channel-modify-request": { + "$ref": "#/components/schemas/example-modify-request-17" + }, + "example-channel-modify-response": { + "$ref": "#/components/schemas/example-modify-response-18" + }, + "privs-get-request": { + "$ref": "#/components/schemas/get-request-7" + }, + "privs-get-response": { + "$ref": "#/components/schemas/get-response-7" + }, + "privs-show-request": { + "$ref": "#/components/schemas/show-request-18" + }, + "privs-show-response": { + "$ref": "#/components/schemas/show-response-19" + }, + "privs-check-request": { + "$ref": "#/components/schemas/check-request-4" + }, + "privs-check-response": { + "$ref": "#/components/schemas/check-response-4" + }, + "example-privs-get-request": { + "$ref": "#/components/schemas/example-get-request-7" + }, + "example-privs-get-response": { + "$ref": "#/components/schemas/example-get-response-6" + }, + "example-privs-show-request": { + "$ref": "#/components/schemas/example-show-request-17" + }, + "example-privs-show-response": { + "$ref": "#/components/schemas/example-show-response-17" + }, + "example-privs-check-request": { + "$ref": "#/components/schemas/example-check-request-4" + }, + "example-privs-check-response": { + "$ref": "#/components/schemas/example-check-response-4" + }, + "users-list-request": { + "$ref": "#/components/schemas/list-request-23" + }, + "users-list-response": { + "$ref": "#/components/schemas/list-response-23" + }, + "example-users-list-request": { + "$ref": "#/components/schemas/example-list-request-23" + }, + "example-users-list-response": { + "$ref": "#/components/schemas/example-list-response-21" + }, + "api_code-compile-request": { + "$ref": "#/components/schemas/compile-request-2" + }, + "api_code-compile-response": { + "$ref": "#/components/schemas/compile-response-2" + }, + "api_code-get-request": { + "$ref": "#/components/schemas/get-request-8" + }, + "api_code-get-response": { + "$ref": "#/components/schemas/get-response-8" + }, + "api_code-load-request": { + "$ref": "#/components/schemas/load-request-2" + }, + "api_code-load-response": { + "$ref": "#/components/schemas/load-response-2" + }, + "api_code-clone-request": { + "$ref": "#/components/schemas/clone-request-2" + }, + "api_code-clone-response": { + "$ref": "#/components/schemas/clone-response" + }, + "example-api_code-compile-request": { + "$ref": "#/components/schemas/example-compile-request-2" + }, + "example-api_code-compile-response": { + "$ref": "#/components/schemas/example-compile-response-2" + }, + "example-api_code-get-request": { + "$ref": "#/components/schemas/example-get-request-8" + }, + "example-api_code-get-response": { + "$ref": "#/components/schemas/example-get-response-7" + }, + "example-api_code-load-request": { + "$ref": "#/components/schemas/example-load-request-2" + }, + "example-api_code-load-response": { + "$ref": "#/components/schemas/example-load-response-2" + }, + "example-api_code-clone-request": { + "$ref": "#/components/schemas/example-clone-request-2" + }, + "example-api_code-clone-response": { + "$ref": "#/components/schemas/example-clone-response" + }, + "user_status-modify-request": { + "$ref": "#/components/schemas/modify-request-19" + }, + "user_status-modify-response": { + "$ref": "#/components/schemas/modify-response-19" + }, + "example-user_status-modify-request": { + "$ref": "#/components/schemas/example-modify-request-18" + }, + "example-user_status-modify-response": { + "$ref": "#/components/schemas/example-modify-response-19" + }, + "user_stat-show-request": { + "$ref": "#/components/schemas/show-request-12" + }, + "used_user_stattraff-show-response": { + "$ref": "#/components/schemas/show-response-13" + }, + "example-user_stat-show-request": { + "$ref": "#/components/schemas/example-show-request-12" + }, + "example-user_stat-show-response": { + "$ref": "#/components/schemas/example-show-response-11" + }, + "env_var-create-request": { + "$ref": "#/components/schemas/create-request-23" + }, + "env_var-create-response": { + "$ref": "#/components/schemas/create-response-23" + }, + "env_var-modify-request": { + "$ref": "#/components/schemas/modify-request-20" + }, + "env_var-modify-response": { + "$ref": "#/components/schemas/modify-response-20" + }, + "env_var-delete-request": { + "$ref": "#/components/schemas/delete-request-17" + }, + "env_var-delete-response": { + "$ref": "#/components/schemas/delete-response-17" + }, + "env_var-list-request": { + "$ref": "#/components/schemas/list-request-24" + }, + "env_var-list-response": { + "$ref": "#/components/schemas/list-response-24" + }, + "example-env_var-create-request": { + "$ref": "#/components/schemas/example-create-request-22" + }, + "example-env_var-create-response": { + "$ref": "#/components/schemas/example-create-response-21" + }, + "example-env_var-modify-request": { + "$ref": "#/components/schemas/example-modify-request-19" + }, + "example-env_var-modify-response": { + "$ref": "#/components/schemas/example-modify-response-20" + }, + "example-env_var-delete-request": { + "$ref": "#/components/schemas/example-delete-request-17" + }, + "example-env_var-delete-response": { + "$ref": "#/components/schemas/example-delete-response-17" + }, + "example-env_var-list-request": { + "$ref": "#/components/schemas/example-list-request-24" + }, + "example-env_var-list-response": { + "$ref": "#/components/schemas/example-list-response-22" + }, + "upload_info-success": { + "$ref": "#/components/schemas/upload_info-success-response" + }, + "upload_info-error_upload": { + "$ref": "#/components/schemas/upload_info-error_upload-response" + }, + "upload_info-error": { + "$ref": "#/components/schemas/upload_info-error-response" + }, + "example-upload_info-success": { + "$ref": "#/components/schemas/example-upload_info-success-response" + }, + "example-upload_info-error_upload": { + "$ref": "#/components/schemas/example-upload_info-error_upload-response" + }, + "example-upload_info-error": { + "$ref": "#/components/schemas/example-upload_info-error-response" + }, + "statistics-get-request": { + "$ref": "#/components/schemas/get-request-9" + }, + "statistics-get-response": { + "$ref": "#/components/schemas/get-response-9" + }, + "example-statistics-get-request": { + "$ref": "#/components/schemas/example-get-request-9" + }, + "example-statistics-get-response": { + "$ref": "#/components/schemas/example-get-response-8" + }, + "sum_stat-show-request": { + "$ref": "#/components/schemas/show-request-19" + }, + "sum_stat-show-response": { + "$ref": "#/components/schemas/show-response-20" + }, + "example-sum_stat-show-request": { + "$ref": "#/components/schemas/example-show-request-18" + }, + "example-sum_stat-show-response": { + "$ref": "#/components/schemas/example-show-response-18" + }, + "conf-show(json)-request": { + "$ref": "#/components/schemas/show(json)-request" + }, + "conf-show(json)-response": { + "$ref": "#/components/schemas/show(json)-response" + }, + "example-conf-show(json)-request": { + "$ref": "#/components/schemas/example-show(json)-request" + }, + "example-conf-show(json)-response": { + "$ref": "#/components/schemas/example-show(json)-response" + }, + "example-conf-show(json)ui-response": { + "$ref": "#/components/schemas/example-show(json)ui-response" + }, + "value-get-request": { + "$ref": "#/components/schemas/get-request-10" + }, + "value-get-response": { + "$ref": "#/components/schemas/get-response-10" + }, + "value-set-request": { + "$ref": "#/components/schemas/set-request" + }, + "value-set-response": { + "$ref": "#/components/schemas/set-response" + }, + "value-delete-request": { + "$ref": "#/components/schemas/delete-request-18" + }, + "value-delete-response": { + "$ref": "#/components/schemas/delete-response-18" + }, + "example-value-get-request": { + "$ref": "#/components/schemas/example-get-request-10" + }, + "example-value-get-response": { + "$ref": "#/components/schemas/example-get-response-9" + }, + "example-value-set-request": { + "$ref": "#/components/schemas/example-set-request" + }, + "example-value-set-response": { + "$ref": "#/components/schemas/example-set-response" + }, + "example-value-delete-request": { + "$ref": "#/components/schemas/example-delete-request-18" + }, + "example-value-delete-response": { + "$ref": "#/components/schemas/example-delete-response-5" + }, + "values-list-request": { + "$ref": "#/components/schemas/list-request-25" + }, + "values-list-response": { + "$ref": "#/components/schemas/list-response-25" + }, + "example-values-list-request": { + "$ref": "#/components/schemas/example-list-request-25" + }, + "example-values-list-response": { + "$ref": "#/components/schemas/example-list-response-23" + }, + "shared_session-show-request": { + "$ref": "#/components/schemas/show-request-20" + }, + "shared_session-show-response": { + "$ref": "#/components/schemas/show-response-21" + }, + "shared_session-set-request": { + "$ref": "#/components/schemas/set-request-2" + }, + "shared_session-set-response": { + "$ref": "#/components/schemas/set-response-2" + }, + "shared_session-delete-request": { + "$ref": "#/components/schemas/delete-request-19" + }, + "shared_session-delete-response": { + "$ref": "#/components/schemas/delete-response-19" + }, + "example-shared_session-show-request": { + "$ref": "#/components/schemas/example-show-request-19" + }, + "example-shared_session-show-response": { + "$ref": "#/components/schemas/example-show-response-19" + }, + "example-shared_session-set-request": { + "$ref": "#/components/schemas/example-set-request-2" + }, + "example-shared_session-set-response": { + "$ref": "#/components/schemas/example-set-response-2" + }, + "example-shared_session-delete-request": { + "$ref": "#/components/schemas/example-delete-request-19" + }, + "example-shared_session-delete-response": { + "$ref": "#/components/schemas/example-delete-response-18" + }, + "license-show-request": { + "$ref": "#/components/schemas/show-request-21" + }, + "license-show-response": { + "$ref": "#/components/schemas/show-response-22" + }, + "license-get-request": { + "$ref": "#/components/schemas/get-request-11" + }, + "license-get-response": { + "$ref": "#/components/schemas/get-response-11" + }, + "license-upload-request": { + "$ref": "#/components/schemas/upload-request" + }, + "license-upload-response": { + "$ref": "#/components/schemas/upload-response" + }, + "license-accept-request": { + "$ref": "#/components/schemas/accept-request" + }, + "license-accept-response": { + "$ref": "#/components/schemas/accept-response" + }, + "license-invalidate-request": { + "$ref": "#/components/schemas/invalidate-request" + }, + "license-invalidate-response": { + "$ref": "#/components/schemas/invalidate-response" + }, + "license-decline-request": { + "$ref": "#/components/schemas/decline-request" + }, + "license-decline-response": { + "$ref": "#/components/schemas/decline-response" + }, + "example-license-show-request": { + "$ref": "#/components/schemas/example-show-request-20" + }, + "example-license-show-response": { + "$ref": "#/components/schemas/example-show-response-20" + }, + "example-license-get-request": { + "$ref": "#/components/schemas/example-get-request-11" + }, + "example-license-get-response": { + "$ref": "#/components/schemas/example-get-response-10" + }, + "example-license-upload-request": { + "$ref": "#/components/schemas/example-upload-request" + }, + "example-license-upload-response": { + "$ref": "#/components/schemas/example-upload-response" + }, + "example-license-accept-request": { + "$ref": "#/components/schemas/example-accept-request" + }, + "example-license-accept-response": { + "$ref": "#/components/schemas/example-accept-response" + }, + "example-license-invalidate-request": { + "$ref": "#/components/schemas/example-invalidate-request" + }, + "example-license-invalidate-response": { + "$ref": "#/components/schemas/example-invalidate-response" + }, + "example-license-decline-request": { + "$ref": "#/components/schemas/example-decline-request" + }, + "example-license-decline-response": { + "$ref": "#/components/schemas/example-decline-response" + }, + "license-create-request": { + "$ref": "#/components/schemas/create-request-24" + }, + "license-create-response": { + "$ref": "#/components/schemas/create-response-24" + }, + "license-delete-request": { + "$ref": "#/components/schemas/delete-request-20" + }, + "license-delete-response": { + "$ref": "#/components/schemas/delete-response-20" + }, + "license-download-request": { + "$ref": "#/components/schemas/download-request-3" + }, + "license-download-response": { + "$ref": "#/components/schemas/download-response-3" + }, + "licenses-list-request": { + "$ref": "#/components/schemas/list-request-26" + }, + "example-license-create-request": { + "$ref": "#/components/schemas/example-create-request-23" + }, + "example-license-create-response": { + "$ref": "#/components/schemas/example-create-response-22" + }, + "example-license-delete-request": { + "$ref": "#/components/schemas/example-delete-request-20" + }, + "example-license-delete-response": { + "$ref": "#/components/schemas/example-delete-response-19" + }, + "example-license-download-request": { + "$ref": "#/components/schemas/example-download-request-3" + }, + "example-license-download-response": { + "$ref": "#/components/schemas/example-download-response-3" + }, + "example-licenses-list-request": { + "$ref": "#/components/schemas/example-list-request-26" + }, + "example-licenses-list-response": { + "$ref": "#/components/schemas/example-list-response-24" + }, + "example-users_info-request": { + "$ref": "#/components/schemas/example-request" + }, + "example-users_info-response": { + "$ref": "#/components/schemas/example-response" + }, + "conv_auth-show-request": { + "$ref": "#/components/schemas/show-request-22" + }, + "conv_auth-show-response": { + "$ref": "#/components/schemas/show-response-23" + }, + "conv_auth-modify-request": { + "$ref": "#/components/schemas/modify-request-21" + }, + "conv_auth-modify-response": { + "$ref": "#/components/schemas/modify-response-21" + }, + "conv_auth-delete-request": { + "$ref": "#/components/schemas/delete-request-21" + }, + "conv_auth-delete-response": { + "$ref": "#/components/schemas/delete-response-21" + }, + "example-conv_auth-show-request": { + "$ref": "#/components/schemas/example-show-request-21" + }, + "example-conv_auth-show-response": { + "$ref": "#/components/schemas/example-show-response-21" + }, + "example-conv_auth-modify-request": { + "$ref": "#/components/schemas/example-modify-request-20" + }, + "example-conv_auth-modify-response": { + "$ref": "#/components/schemas/example-modify-response-21" + }, + "example-conv_auth-delete-request": { + "$ref": "#/components/schemas/example-delete-request-21" + }, + "example-conv_auth-delete-response": { + "$ref": "#/components/schemas/example-delete-response-20" + }, + "license_attr-create-request": { + "$ref": "#/components/schemas/create-request-25" + }, + "license_attr-create-response": { + "$ref": "#/components/schemas/create-response-25" + }, + "license_attr-update-request": { + "$ref": "#/components/schemas/update-request" + }, + "license_attr-update-response": { + "$ref": "#/components/schemas/update-response" + }, + "license_attr-restore-request": { + "$ref": "#/components/schemas/restore-request-9" + }, + "license_attr-restore-response": { + "$ref": "../schemas/objects/license_attr/restore-response.yaml" + }, + "license_attr-destroy-request": { + "$ref": "../schemas/objects/license_attr/destroy-request.yaml" + }, + "license_attr-destroy-response": { + "$ref": "../schemas/objects/license_attr/destroy-response.yaml" + }, + "license_attr-delete-request": { + "$ref": "#/components/schemas/delete-request-22" + }, + "license_attr-delete-response": { + "$ref": "#/components/schemas/delete-response-22" + }, + "license_attr-view-request": { + "$ref": "#/components/schemas/view-request" + }, + "license_attr-view-response": { + "$ref": "#/components/schemas/view-response" + }, + "license_attr-list-request": { + "$ref": "#/components/schemas/list-request-27" + }, + "license_attr-list-response": { + "$ref": "#/components/schemas/list-response-26" + }, + "example-license_attr-create-request": { + "$ref": "#/components/schemas/example-create-request-24" + }, + "example-license_attr-create-response": { + "$ref": "#/components/schemas/example-create-response-23" + }, + "example-license_attr-update-request": { + "$ref": "#/components/schemas/example-update-request" + }, + "example-license_attr-update-response": { + "$ref": "#/components/schemas/example-update-response" + }, + "example-license_attr-restore-request": { + "$ref": "#/components/schemas/example-restore-request-9" + }, + "example-license_attr-restore-response": { + "$ref": "#/components/schemas/example-restore-response-9" + }, + "example-license_attr-destroy-request": { + "$ref": "../schemas/objects/license_attr/example-destroy-request.json" + }, + "example-license_attr-destroy-response": { + "$ref": "../schemas/objects/license_attr/example-destroy-response.json" + }, + "example-license_attr-delete-request": { + "$ref": "#/components/schemas/example-delete-request-22" + }, + "example-license_attr-delete-response": { + "$ref": "#/components/schemas/example-delete-response-21" + }, + "example-license_attr-view-request": { + "$ref": "#/components/schemas/example-view-request" + }, + "example-license_attr-view-response": { + "$ref": "#/components/schemas/example-view-response" + }, + "example-license_attr-list-request": { + "$ref": "#/components/schemas/example-list-request-27" + }, + "example-license_attr-list-response": { + "$ref": "#/components/schemas/example-list-response-25" + } + } + } +} \ No newline at end of file diff --git a/plugins/corezoid/docs/nodes/call-process-node.md b/plugins/corezoid/docs/nodes/call-process-node.md index 54ad37c..b0132fa 100644 --- a/plugins/corezoid/docs/nodes/call-process-node.md +++ b/plugins/corezoid/docs/nodes/call-process-node.md @@ -63,10 +63,10 @@ 2. **conv_id** (Number or String) - ID of the process to call - - Can be a static value or a dynamic value from the process task - - Example: `"conv_id": 9876543` or `"conv_id": "{{process_id}}"` - - Dynamic example: `"conv_id": "{{param1}}"` (with quotes for JSON format) - - Validation: Must be a valid process ID or reference + - Can be a static numeric ID, an alias string, or a dynamic value from the task + - Example: `"conv_id": 9876543` (numeric) or `"conv_id": "@payment-checkout"` (alias, if one exists) + - Dynamic example: `"conv_id": "{{process_id}}"` (with quotes for JSON format) + - Validation: Must be a valid process ID, `@alias`, or dynamic reference 3. **extra** (Object) diff --git a/plugins/corezoid/docs/nodes/copy-task-node.md b/plugins/corezoid/docs/nodes/copy-task-node.md index 64e627d..d59eddd 100644 --- a/plugins/corezoid/docs/nodes/copy-task-node.md +++ b/plugins/corezoid/docs/nodes/copy-task-node.md @@ -13,7 +13,7 @@ 1. **Target Process** (String/ID) - The Process that will receive the copied task. - - Example: `"conv_id": 1023393` + - Example: `"conv_id": 1023393` (numeric) or `"conv_id": "@send-notification"` (alias, if one exists) - Can be a dynamic value from the process task - Dynamic example: `"conv_id": "{{param1}}"` (with quotes for JSON format) 2. **Error Node ID** (String) diff --git a/plugins/corezoid/docs/nodes/set-parameters-dynamic-values.md b/plugins/corezoid/docs/nodes/set-parameters-dynamic-values.md index cb0329f..468dd41 100644 --- a/plugins/corezoid/docs/nodes/set-parameters-dynamic-values.md +++ b/plugins/corezoid/docs/nodes/set-parameters-dynamic-values.md @@ -156,6 +156,34 @@ the full array manipulation approach: "my_array": "{{JSON.stringify(my_array.map((item, idx) => idx === {{target_index}} ? {...item, updated: true} : item))}}" ``` +## Environment Variables + +Environment variables store stage-scoped constants (URLs, tokens, API keys) that must +not be hardcoded. They are resolved at runtime before the node executes. + +**Syntax:** `{{env_var[@variable-short-name]}}` + +```json +{ + "type": "set_param", + "extra": { + "baseUrl": "{{env_var[@payment-api-url]}}", + "token": "{{env_var[@payment-api-token]}}" + }, + "extra_type": { + "baseUrl": "string", + "token": "string" + }, + "err_node_id": "" +} +``` + +Environment variable references can be used anywhere a dynamic value is accepted: +in `extra` values, in condition `arg`/`val` fields, in API Call URLs and headers. + +To manage environment variables (create, list, modify, delete), see +`${CLAUDE_PLUGIN_ROOT}/skills/corezoid-variable-manager/SKILL.md`. + ## System Variables The following system variables are available in Set Parameters nodes: diff --git a/plugins/corezoid/docs/nodes/set-state-node.md b/plugins/corezoid/docs/nodes/set-state-node.md index 77ab553..b49ed04 100644 --- a/plugins/corezoid/docs/nodes/set-state-node.md +++ b/plugins/corezoid/docs/nodes/set-state-node.md @@ -183,6 +183,8 @@ you can retrieve the task's data (or specific parameters within it) from other p ``` {{conv[@user-states].ref[{{my_task_ref}}]}} ``` + Here `@user-states` is a Corezoid alias pointing to the State Diagram process. Aliases are + managed via the `corezoid-alias-manager` skill. This syntax allows other parts of your system to interact with and retrieve data persisted within State Diagrams. diff --git a/plugins/corezoid/docs/state-diagrams/state-diagram-node-structures.md b/plugins/corezoid/docs/state-diagrams/state-diagram-node-structures.md new file mode 100644 index 0000000..9d4b4f5 --- /dev/null +++ b/plugins/corezoid/docs/state-diagrams/state-diagram-node-structures.md @@ -0,0 +1,447 @@ +# State Diagram Node Structures + +Canonical JSON shapes for every node type that is **allowed inside a State Diagram** (`conv_type: "state"`). + +If a node type is not listed here, it is **forbidden** in a state diagram and will fail validation. See [state-diagram-overview.md](./state-diagram-overview.md) for the full rationale. + +For node types shared with regular processes (Condition, Code, Set Parameters, Copy Task, End), the JSON shape is identical to the one in `${CLAUDE_PLUGIN_ROOT}/docs/node-structures.md`; this file shows the **state-diagram-specific patterns** and the nodes that are unique to state diagrams. + +--- + +## Start Node (`obj_type: 1`) + +Identical to a regular process. Always one per state diagram. + +```json +{ + "id": "<24-hex>", + "obj_type": 1, + "condition": { + "logics": [ + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Start", + "description": "", + "x": 880, + "y": 100, + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"\"}", + "options": null +} +``` + +The `go.to_node_id` of the Start node usually points to the **initial state node** (e.g. `Active`, `Pending`, `New`). + +--- + +## State Node (`obj_type: 0`, logic begins with `api_callback`) + +This is the **defining node of a state diagram**. Every named state is one of these. The task parks on `api_callback` and re-evaluates the transitions whenever another process calls `api_copy mode: "modify"` on its ref. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { "type": "api_callback" }, + { + "type": "go_if_const", + "to_node_id": "", + "conditions": [ + { "param": "status", "const": "active", "fun": "eq", "cast": "string" } + ] + }, + { + "type": "go_if_const", + "to_node_id": "", + "conditions": [ + { "param": "status", "const": "blocked", "fun": "eq", "cast": "string" } + ] + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Inactive users", + "description": "", + "x": 1108, + "y": 400, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null +} +``` + +**Rules:** +- `obj_type: 0` (not `3` — older docs may show 3; current Corezoid uses 0 with the `api_callback`-first pattern). +- The **first logic must be `api_callback`** with no additional fields. This is what makes the node "park" the task. +- After `api_callback`, list each outbound transition as a `go_if_const`. Earliest match wins. +- The **last logic must be `go` pointing back to the same node's own `id`** — the "stay in this state" fallback. +- `extra` must include `"icon":"state"` for the UI to render the state pill. +- `title` is the **human-readable state name** (e.g. `Active`, `Pending`, `Blocked`). It is shown on the canvas and referenced in dashboards. +- Do not add `err_node_id` — `api_callback` does not raise the standard error path. + +--- + +## Condition Node (`obj_type: 0`, `type: "go_if_const"`) + +Same shape as in a regular process; commonly used to route a task **between states** before it parks on an `api_callback`. See `${CLAUDE_PLUGIN_ROOT}/docs/nodes/condition-node.md` for full details. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "go_if_const", + "to_node_id": "", + "conditions": [ + { "param": "status", "const": "active", "fun": "eq", "cast": "string" } + ] + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Route by status", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +--- + +## Code Node (`obj_type: 0`, `type: "api_code"`) + +Same shape as in a regular process. Use sparingly — most state diagrams should not run arbitrary code. Prefer `set_param` for simple transformations. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_code", + "lang": "js", + "src": "data.derived = (data.first || '') + '_' + (data.last || '');", + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Compose display name", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +`err_node_id` is **required** and must point to an End: Error node. + +--- + +## Set Parameters Node (`obj_type: 0`, `type: "set_param"`) + +Same shape as in a regular process. Use to compute / derive fields before parking on a state. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "set_param", + "extra": { + "entered_at": "$.date()", + "full_name": "{{first_name}}_{{last_name}}" + }, + "extra_type": { + "entered_at": "number", + "full_name": "string" + }, + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Stamp entered_at", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +`err_node_id` is **required**. + +--- + +## Copy Task Node (`obj_type: 0`, `type: "api_copy"`) + +Use to **fan out** data from a state diagram to another process (commonly: send a notification, record an audit event). The original task continues in the state diagram. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_copy", + "conv_id": "@notify-user", + "mode": "create", + "ref": "", + "group": "all", + "is_sync": false, + "send_parent_data": false, + "data": { "user_id": "{{ref}}", "new_status": "{{status}}" }, + "data_type": { "user_id": "string", "new_status": "string" }, + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Notify on state change", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +Notes: +- Do **not** use `api_copy` here to write back to the same state diagram — use Modify Task for that. +- `err_node_id` is **required**. + +--- + +## Modify Task Node (`obj_type: 0`, `type: "api_copy"` with `mode: "modify"`) + +"Modify Task" is **not a separate logic type** — it is `api_copy` with `mode: "modify"`. Used to update a task by `ref` in some target process (often the same state diagram). + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_copy", + "conv_id": , + "ref": "{{ref}}", + "mode": "modify", + "is_sync": true, + "group": "", + "send_parent_data": false, + "data": { + "previous_status": "{{status}}", + "updated_at": "$.date()" + }, + "data_type": { + "previous_status": "string", + "updated_at": "number" + }, + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Stamp previous status", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +Notes: +- To modify **fields on the current task in place** (without crossing a process boundary), prefer **Set Parameters** (`set_param`) — it edits the task's `data` object directly and has zero overhead. +- Use `api_copy mode: "modify"` only when you need to update a task in another process (or another state diagram) identified by `ref`. +- `err_node_id` is **required**. + +--- + +## Delay Node (`obj_type: 0`, semaphor only) + +Parks the task for a fixed time, then auto-routes via the semaphor target. Use for time-bounded states (e.g. "trial expires in 14 days"). + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [], + "semaphors": [ + { + "type": "time", + "value": 14, + "dimension": "day", + "to_node_id": "" + } + ] + }, + "title": "Trial period", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"\"}", + "options": null +} +``` + +`dimension` values: `"sec"`, `"min"`, `"hour"`, `"day"`. + +--- + +## Queue Node (`obj_type: 0`, `type: "api_queue"`) + +Holds tasks in a named queue until a consumer drains them with `api_get_task`. Rarely needed inside state diagrams — only use when you need ordered, throttled processing. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_queue", + "queue": "{{env_var[@user-status-queue]}}", + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Enqueue for review", + "x": 880, + "y": 250, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +See `${CLAUDE_PLUGIN_ROOT}/docs/nodes/queue-node.md` and `${CLAUDE_PLUGIN_ROOT}/docs/nodes/get-from-queue-node.md` for the full pattern. + +--- + +## End: Success / End: Error (`obj_type: 2`) + +Terminal nodes. Identical to a regular process; only the `extra.icon` differs. + +```json +{ + "id": "<24-hex>", + "obj_type": 2, + "condition": { "logics": [], "semaphors": [] }, + "title": "Closed", + "description": "", + "x": 880, + "y": 900, + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"success\"}", + "options": "{\"save_task\":true}" +} +``` + +For an error sink, set `"icon":"error"`. Use `options: "{\"save_task\":true}"` if you want the closed task to be archived for later audit. + +--- + +## Quick reference — full state diagram skeleton + +A minimal viable state diagram with two states and a Start: + +```json +{ + "obj_type": 1, + "obj_id": null, + "parent_id": , + "title": "User Status", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "state", + "scheme": { + "nodes": [ + { + "id": "aaaaaaaaaaaaaaaaaaaaaaaa", + "obj_type": 1, + "condition": { + "logics": [ { "type": "go", "to_node_id": "bbbbbbbbbbbbbbbbbbbbbbbb" } ], + "semaphors": [] + }, + "title": "Start", "x": 880, "y": 100, + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"\"}", + "options": null + }, + { + "id": "bbbbbbbbbbbbbbbbbbbbbbbb", + "obj_type": 0, + "condition": { + "logics": [ + { "type": "api_callback" }, + { + "type": "go_if_const", + "to_node_id": "cccccccccccccccccccccccc", + "conditions": [ { "param": "status", "const": "inactive", "fun": "eq", "cast": "string" } ] + }, + { "type": "go", "to_node_id": "bbbbbbbbbbbbbbbbbbbbbbbb" } + ], + "semaphors": [] + }, + "title": "Active", + "x": 740, "y": 400, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null + }, + { + "id": "cccccccccccccccccccccccc", + "obj_type": 0, + "condition": { + "logics": [ + { "type": "api_callback" }, + { + "type": "go_if_const", + "to_node_id": "bbbbbbbbbbbbbbbbbbbbbbbb", + "conditions": [ { "param": "status", "const": "active", "fun": "eq", "cast": "string" } ] + }, + { "type": "go", "to_node_id": "cccccccccccccccccccccccc" } + ], + "semaphors": [] + }, + "title": "Inactive", + "x": 1108, "y": 400, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null + } + ], + "web_settings": [[], []] + } +} +``` + +--- + +## Forbidden inside a state diagram + +| Node | Logic `type` | Why forbidden / alternative | +|---|---|---| +| API Call | `api` | State diagrams must not make HTTP requests. Do the call in the driver process. | +| Call a Process | `api_rpc` | State diagrams must not block on RPC. Use Copy Task fan-out instead. | +| Reply to Process | `api_rpc_reply` | A state task is not invoked via RPC — there is nothing to reply to. | +| DB Call | `db_call` | Same as API Call — do it in the driver process. | +| Git Call | `git_call` | Same. | +| Sum | `api_sum` | Aggregation belongs in the driver process or in dashboards. | +| API Form | `api_form` | Forms are user-facing — do not place them inside a storage diagram. | + +If the linter / `push-process` rejects a state diagram with `obj_type: 1, conv_type: "state"`, the most common cause is one of the forbidden logics above. Remove it and move the logic into the driver process. diff --git a/plugins/corezoid/docs/state-diagrams/state-diagram-overview.md b/plugins/corezoid/docs/state-diagrams/state-diagram-overview.md new file mode 100644 index 0000000..0c44e4b --- /dev/null +++ b/plugins/corezoid/docs/state-diagrams/state-diagram-overview.md @@ -0,0 +1,190 @@ +# State Diagram Overview + +A **State Diagram** (`conv_type: "state"`) is a special type of Corezoid object that **stores data as long-lived tasks** representing the current state of an entity (user, order, device, account, etc.). Other processes read, create, and modify these state tasks through a small set of dedicated logics. + +Think of a State Diagram as a **persistent key-value store with workflow semantics**: +- The **key** is the task's `ref` (passed when the state task is created) +- The **value** is the task's data (any parameters you store on it) +- The **workflow** is the set of states (nodes) the task transitions through over its lifetime + +## When to use a State Diagram + +Use a State Diagram when you need to: + +- Track the lifecycle of an entity (e.g. `pending → active → blocked → closed`) +- Persist the latest known data for an entity across many processes +- Trigger automatic transitions when an entity's data changes +- Share state between independent processes through a `ref` + +Do **not** use a State Diagram for transient processing — use a regular process for that. + +## How it differs from a regular Process + +| Aspect | Regular Process (`conv_type: "process"`) | State Diagram (`conv_type: "state"`) | +|---|---|---| +| Purpose | Run a workflow then complete | Store data and react to external changes | +| Task lifetime | Short-lived — flows from Start to End | Long-lived — parks in a state node, waits for callbacks | +| Allowed logic nodes | All 24 node types | 10 node types only (see below) | +| Triggered by | A new task created on Start | A new task on Start, **or** a `modify` callback from another process | +| State pattern | Linear flow | State machine — each state node waits for a callback, then conditionally transitions | +| Reads from outside | Returns a reply via `api_rpc_reply` | Read directly via `{{conv[].ref[].}}` | + +## Allowed nodes inside a State Diagram + +Only the following node logics may appear in a State Diagram. Adding any other node type will fail validation on push. + +| Node | Logic `type` | Purpose inside a state diagram | +|---|---|---| +| Start | `go` (Start, `obj_type: 1`) | Entry point — creates the state task | +| Condition | `go_if_const` | Branch between states based on data | +| Code | `api_code` | Transform data before it enters a state | +| Set Parameters | `set_param` | Set / compute parameters on the task | +| Copy Task | `api_copy` with `mode: "create"` | Fork data to another process (e.g. notification) | +| Modify Task | `api_copy` with `mode: "modify"` | Modify a target task by `ref` in some process (often this same state diagram) | +| Set State | `api_callback` + `go_if_const`s + self-`go` (see below) | The "park here" node — waits for callbacks | +| Delay | semaphor only (`semaphors: [{ "type": "time", ... }]`) | Park the task for a fixed time, then auto-transition | +| Queue | `api_queue` / `api_get_task` | Hold tasks in a queue until processed | +| End: Error | (terminal, `obj_type: 2`, icon `error`) | Final error sink | +| End: Success | (terminal, `obj_type: 2`, icon `success`) | Final success sink | + +> ⚠️ **Forbidden in state diagrams:** API Call (`api`), Call a Process (`api_rpc`), Reply to Process (`api_rpc_reply`), DB Call (`db_call`), Git Call (`git_call`), Sum (`api_sum`), API Form (`api_form`). +> +> If you need to call out to an external system from a state, do it from the **driver process** that triggered the state change — never from inside the state diagram. + +## The "state" node pattern + +A **state node** is the structural heart of a State Diagram. Each named state (e.g. `Active`, `Inactive`, `Blocked`) is one node with this exact shape: + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { "type": "api_callback" }, + { + "type": "go_if_const", + "to_node_id": "", + "conditions": [ + { "param": "status", "const": "active", "fun": "eq", "cast": "string" } + ] + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Inactive users", + "x": 1108, + "y": 400, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null +} +``` + +How it works at runtime: + +1. **`api_callback`** — the task **parks** here. The state is "stored". The task does nothing until an external `api_copy` with `mode: "modify"` updates its data. +2. When data is updated, the logics below `api_callback` re-evaluate top-to-bottom. +3. Each `go_if_const` checks updated data and routes the task to a different state if the condition matches. +4. The final `go` points back to the **same node's own id** — the "stay in this state" fallback. + +> ✏️ `extra` must include `"icon":"state"` so the Corezoid UI renders it as a state pill rather than a regular logic node. + +## Root document structure + +```json +{ + "obj_type": 1, + "obj_id": null, + "parent_id": , + "title": "User Status", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "state", + "scheme": { + "nodes": [], + "web_settings": [[], []] + } +} +``` + +The only difference from a regular process is `"conv_type": "state"`. Everything else uses the same envelope. + +## How processes interact with a state diagram + +A regular process can do four things to a state diagram task: + +### 1. Read a parameter (`set_param`) + +```json +{ + "type": "set_param", + "extra": { "user": "{{conv[1863140].ref[{{userId}}].status}}" }, + "extra_type": { "user": "string" }, + "err_node_id": "" +} +``` + +Templates: +- `{{conv[].ref[]}}` — the whole task object +- `{{conv[].ref[].}}` — a single field +- `{{conv[@user-states].ref[{{userId}}].status}}` — via alias and a dynamic ref + +### 2. Create a new state task (`api_copy` with `mode: "create"`) + +```json +{ + "type": "api_copy", + "conv_id": 1863140, + "ref": "{{userId}}", + "mode": "create", + "is_sync": true, + "group": "", + "data": { "status": "active" }, + "data_type": { "status": "string" }, + "err_node_id": "", + "user_id": +} +``` + +- **`ref` is mandatory.** It is the lookup key for this state task. Choose a stable, unique identifier (user id, order id, etc.). +- A new task starts at the State Diagram's Start node and is routed to its initial state. +- Possible errors: `not_unical_ref` (the ref already exists — use `modify` instead), `access_denied`, `copy_task_timeout`, `crash_api`. + +### 3. Modify an existing state task (`api_copy` with `mode: "modify"`) + +```json +{ + "type": "api_copy", + "conv_id": 1863140, + "ref": "{{userId}}", + "mode": "modify", + "is_sync": true, + "group": "", + "data": { "status": "inactive" }, + "data_type": { "status": "string" }, + "err_node_id": "", + "user_id": +} +``` + +- Updates the task data and **wakes up** the `api_callback` inside the state node so the transitions re-evaluate. +- Possible errors: `not_found_task` (no task with that `ref` exists yet — create it first), `access_denied`, `crash_api`. + +### 4. Delete / advance the state task + +State diagrams do not expose a direct "delete" — instead, transition the state into a terminal **End** node. A task that lands on `obj_type: 2` is removed from the state machine and can be archived via `options: "{\"save_task\":true}"`. + +## Reference workflow + +A typical "user lifecycle" example uses two artifacts: + +1. **State Diagram** (`User Status`, `conv_type: "state"`) with states `Active`, `Inactive`, `Blocked`. +2. **Driver Process** (`conv_type: "process"`) that: + - Reads the current status with `set_param` + `{{conv[].ref[{{userId}}].status}}` + - Branches with a `go_if_const` (Condition node) + - Calls `api_copy mode: "modify"` to flip the status, which triggers a transition inside the state diagram. + +See `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-state-diagram.conv.json` (the state diagram) and `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-driver-process.conv.json` (the driver process) for a complete working pair. diff --git a/plugins/corezoid/docs/state-diagrams/state-diagram-process-interaction.md b/plugins/corezoid/docs/state-diagrams/state-diagram-process-interaction.md new file mode 100644 index 0000000..2057dcf --- /dev/null +++ b/plugins/corezoid/docs/state-diagrams/state-diagram-process-interaction.md @@ -0,0 +1,194 @@ +# Interacting with a State Diagram from a Process + +A state diagram (`conv_type: "state"`) is a passive store — it does not start anything. Driver **processes** (`conv_type: "process"`) are responsible for creating, reading, and modifying its tasks. This document is the canonical reference for those four interactions. + +Every example below assumes a state diagram with process id `1863140` (or alias `@user-states`) and a `ref` taken from the driver task's `userId` parameter. + +--- + +## 1. Read a parameter — `set_param` with the `conv[]` template + +Use when the driver process needs to know the current value stored in the state diagram. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "set_param", + "extra": { + "user": "{{conv[1863140].ref[{{userId}}].status}}" + }, + "extra_type": { "user": "string" }, + "err_node_id": "" + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Read user status from state diagram", + "x": 780, "y": 196, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +Template forms (any of these may appear inside `extra`): + +| Template | What it returns | +|---|---| +| `{{conv[1863140].ref[{{userId}}]}}` | The entire task data object (type: `object`) | +| `{{conv[1863140].ref[{{userId}}].status}}` | A single field | +| `{{conv[@user-states].ref[{{userId}}].status}}` | Same, via alias | +| `{{conv[{{sd_id}}].ref[{{userId}}].status}}` | Both id and ref are dynamic | + +If the `ref` does not exist, the template resolves to an empty string. Add a Condition node afterwards to handle the "no state yet" case (typically by branching to a Copy Task that creates the state with `mode: "create"`). + +--- + +## 2. Create a new state task — `api_copy` with `mode: "create"` + +Use when the entity does not yet have a state task. The new task starts on the state diagram's Start node. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_copy", + "conv_id": 1863140, + "ref": "{{userId}}", + "mode": "create", + "is_sync": true, + "group": "", + "send_parent_data": false, + "data": { + "status": "active", + "created_at": "$.date()" + }, + "data_type": { + "status": "string", + "created_at": "number" + }, + "err_node_id": "", + "user_id": + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [ + { "type": "time", "value": 30, "dimension": "sec", "to_node_id": "" } + ] + }, + "title": "Create user state", + "x": 480, "y": 476, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +Rules: +- `ref` is **mandatory** and is what every subsequent read / modify will use. Choose a stable, unique identifier (e.g. `userId`, `orderId`). +- `mode: "create"` raises `not_unical_ref` if the ref already exists — handle it in the error condition node and fall through to `mode: "modify"` if needed. +- `is_sync: true` waits for the create to succeed before continuing. +- `group: ""` is required when `data` is non-empty in `mode: "create"`. (Different from "Copy Task to a regular process" — there it's `"all"`.) + +### Default error escalation pattern + +`api_copy` exposes the standard `__conveyor_copy_task_return_type_tag__` error tags. The minimum escalation is a Condition node that branches on: + +| Tag | Meaning | Suggested route | +|---|---|---| +| `not_unical_ref` | Ref already exists | Fall through to a Modify Task node | +| `not_found_task` | (Only in `modify`) the ref doesn't exist | Fall back to Create | +| `crash_api`, `copy_task_timeout`, `copy_task_fatal_error`, `duplicate_callback` | Transient failure | Delay → retry | +| `access_denied` | Permission missing | Error end (cannot be recovered) | + +See `${CLAUDE_PLUGIN_ROOT}/docs/nodes/copy-task-node.md` for the full error catalogue. + +--- + +## 3. Modify an existing state task — `api_copy` with `mode: "modify"` + +This is the interaction that **triggers a transition** inside the state diagram. The `api_callback` inside the current state node re-evaluates the data and routes the task to the next state. + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_copy", + "conv_id": 1863140, + "ref": "{{userId}}", + "mode": "modify", + "is_sync": true, + "group": "", + "send_parent_data": false, + "data": { "status": "inactive" }, + "data_type": { "status": "string" }, + "err_node_id": "", + "user_id": + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Mark user inactive", + "x": 480, "y": 476, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"\"}", + "options": null +} +``` + +Behaviour notes: +- Only the fields in `data` are merged onto the task. Existing fields are kept unless explicitly overwritten. +- After `modify`, the `api_callback` in the **current** state node re-fires its outgoing logics; if a `go_if_const` matches the new data the task moves to that next state. +- If no `go_if_const` matches, the task stays in the current state (the trailing `go` self-loop). + +--- + +## 4. Move a state task to End — let the state diagram do it + +There is no "delete by ref" API. To end a state task, design a transition inside the state diagram that routes to an End node: + +``` +[Active] --api_callback + go_if_const status=='closed'--> [Closed (End: Success)] +``` + +Then from the driver process, call `api_copy mode: "modify"` with `data: { "status": "closed" }`. The state node's outgoing `go_if_const` matches, the task hops to the End node, and it is removed from the live state machine. + +If you need to keep the closed task around for audits, set the End node's `options: "{\"save_task\":true}"`. + +--- + +## End-to-end example + +Driver process: read current status, branch on it, modify the state. + +``` +Start + └── set_param ({{conv[1863140].ref[{{userId}}].status}} → user) + └── go_if_const user == "active" → api_copy(mode:modify, data:{status:"inactive"}) → Final + go_if_const user == "inactive" → api_copy(mode:modify, data:{status:"active"}) → Final + go (default) → Final +``` + +This is exactly the pattern in `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-driver-process.conv.json`, paired with `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-state-diagram.conv.json`. + +--- + +## Common pitfalls + +| Pitfall | Symptom | Fix | +|---|---|---| +| Hardcoding the state diagram id in many processes | Hard to repoint when the id changes | Create an alias (`@user-states`) and reference it everywhere | +| Forgetting `ref` on `api_copy` | `mode: "create"` fails or silently creates one nameless task | `ref` is mandatory for any state-diagram interaction | +| Using `mode: "create"` for an existing ref | `not_unical_ref` error | Pre-read the ref or handle `not_unical_ref` and fall through to `modify` | +| Reading without handling "no state yet" | `{{conv[...]}}` resolves to empty string and subsequent logic silently misbehaves | Add a Condition right after `set_param` for the empty case | +| Modifying with `is_sync: false` then immediately reading | Race: the read returns the old value | Use `is_sync: true` for write-then-read flows | +| Calling APIs from inside the state diagram | Push fails validation, or worse, blocks the state machine | Move the API call into the driver process | diff --git a/plugins/corezoid/docs/variables-guide.md b/plugins/corezoid/docs/variables-guide.md index 0133146..a6a19d2 100644 --- a/plugins/corezoid/docs/variables-guide.md +++ b/plugins/corezoid/docs/variables-guide.md @@ -17,7 +17,10 @@ Variables store constants (URLs, tokens, endpoints, credentials) that should nev ### 1. Check if variable already exists -Read `_ENV_VARS_.json` before creating anything. If the variable exists, reuse it. +Check both local cache files before creating anything. If the variable exists, reuse it: + +- `_ENV_VARS_.json` — created by `pull-folder` (contains all variables exported from Corezoid) +- `.processes/variables.json` — created by the MCP `create-variable` tool during the current session ### 2. Create a new variable @@ -92,6 +95,6 @@ var url = data.baseUrl + "/endpoint"; ## Important Notes - Variables are resolved **at runtime** — the value `{{env_var[@name]}}` is replaced with the actual variable value before the node executes -- Variables are **workspace-scoped** — shared across all processes in the workspace +- Variables are **stage-scoped** — shared across all processes within the same stage - Changes to variable values take effect immediately without redeploying processes - Never store secrets directly in process JSON — always use variables \ No newline at end of file diff --git a/plugins/corezoid/mcp-server/analytics_test.go b/plugins/corezoid/mcp-server/analytics_test.go new file mode 100644 index 0000000..5b50285 --- /dev/null +++ b/plugins/corezoid/mcp-server/analytics_test.go @@ -0,0 +1,210 @@ +package main + +import ( + "os" + "path/filepath" + "regexp" + "strings" + "testing" + "time" +) + +// ---- classifyError --------------------------------------------------------- + +func TestClassifyError(t *testing.T) { + cases := []struct { + in string + want string + }{ + {"authentication failed", "auth_error"}, + {"invalid token supplied", "auth_error"}, + {"401 Unauthorized", "auth_error"}, + {"403 Forbidden", "auth_error"}, + {"validation failed: bad shape", "validation_error"}, + {"node is invalid", "validation_error"}, + {"lint reported issues", "validation_error"}, + {"resource not found", "not_found"}, + {"got 404 from server", "not_found"}, + {"api returned error", "api_error"}, + {"http request failed", "api_error"}, + {"fetch error", "api_error"}, + {"something else entirely", "unknown"}, + {"", "unknown"}, + } + for _, c := range cases { + got := classifyError(c.in) + if got != c.want { + t.Errorf("classifyError(%q) = %q, want %q", c.in, got, c.want) + } + } +} + +func TestClassifyError_CaseInsensitive(t *testing.T) { + if got := classifyError("AUTHENTICATION FAILED"); got != "auth_error" { + t.Errorf("expected auth_error for upper-case input, got %q", got) + } +} + +// ---- hostnameOnly ---------------------------------------------------------- + +func TestHostnameOnly(t *testing.T) { + cases := []struct { + in string + want string + }{ + {"https://api.corezoid.com/v2", "api.corezoid.com"}, + {"http://example.com:8080/path?x=1", "example.com"}, + {"api.corezoid.com", "api.corezoid.com"}, + {"api.corezoid.com/path", "api.corezoid.com"}, + {"", ""}, + } + for _, c := range cases { + got := hostnameOnly(c.in) + if got != c.want { + t.Errorf("hostnameOnly(%q) = %q, want %q", c.in, got, c.want) + } + } +} + +func TestHostnameOnly_InvalidURL(t *testing.T) { + // Pass a URL that fails url.Parse — strings with control characters. + got := hostnameOnly("https://exa mple.com") + if got != "" { + t.Errorf("expected empty string for malformed URL, got %q", got) + } +} + +// ---- generateUUIDv4 -------------------------------------------------------- + +var reUUIDv4 = regexp.MustCompile(`^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$`) + +func TestGenerateUUIDv4_Format(t *testing.T) { + id := generateUUIDv4() + if len(id) != 36 { + t.Fatalf("expected 36-char UUID, got %d: %q", len(id), id) + } + if !reUUIDv4.MatchString(id) { + t.Errorf("UUID %q does not match v4 pattern", id) + } +} + +func TestGenerateUUIDv4_Unique(t *testing.T) { + ids := make(map[string]struct{}, 50) + for i := 0; i < 50; i++ { + id := generateUUIDv4() + if _, dup := ids[id]; dup { + t.Fatalf("duplicate UUID generated: %s", id) + } + ids[id] = struct{}{} + } +} + +// ---- loadOrCreateInstallationID -------------------------------------------- + +// Replace HOME with a temp dir so the test does not touch the real +// ~/.corezoid/installation_id file. +func withTempHome(t *testing.T) string { + t.Helper() + dir := t.TempDir() + orig := os.Getenv("HOME") + t.Setenv("HOME", dir) + t.Cleanup(func() { _ = os.Setenv("HOME", orig) }) + return dir +} + +func TestLoadOrCreateInstallationID_CreatesFile(t *testing.T) { + home := withTempHome(t) + + id := loadOrCreateInstallationID() + if !reUUIDv4.MatchString(id) { + t.Fatalf("generated ID %q is not a valid UUID v4", id) + } + + // File should have been persisted. + path := filepath.Join(home, ".corezoid", "installation_id") + data, err := os.ReadFile(path) + if err != nil { + t.Fatalf("expected installation_id file to be created: %v", err) + } + if strings.TrimSpace(string(data)) != id { + t.Errorf("file content %q does not match returned id %q", strings.TrimSpace(string(data)), id) + } +} + +func TestLoadOrCreateInstallationID_ReadsExisting(t *testing.T) { + home := withTempHome(t) + + dir := filepath.Join(home, ".corezoid") + if err := os.MkdirAll(dir, 0700); err != nil { + t.Fatal(err) + } + existing := "11111111-2222-4333-8444-555555555555" + if err := os.WriteFile(filepath.Join(dir, "installation_id"), []byte(existing+"\n"), 0600); err != nil { + t.Fatal(err) + } + + id := loadOrCreateInstallationID() + if id != existing { + t.Errorf("expected to read existing id %q, got %q", existing, id) + } +} + +func TestLoadOrCreateInstallationID_RegeneratesOnInvalidLength(t *testing.T) { + home := withTempHome(t) + + dir := filepath.Join(home, ".corezoid") + if err := os.MkdirAll(dir, 0700); err != nil { + t.Fatal(err) + } + // Length != 36 — should be discarded and a new ID generated. + if err := os.WriteFile(filepath.Join(dir, "installation_id"), []byte("too-short\n"), 0600); err != nil { + t.Fatal(err) + } + + id := loadOrCreateInstallationID() + if id == "too-short" { + t.Error("expected invalid id to be discarded") + } + if !reUUIDv4.MatchString(id) { + t.Errorf("expected fresh UUID v4, got %q", id) + } +} + +// ---- emitAnalyticsEvent ---------------------------------------------------- + +func TestEmitAnalyticsEvent_DisabledIsNoOp(t *testing.T) { + // When analytics are disabled, emitAnalyticsEvent must not panic even if + // analyticsCh is nil. + prev := analyticsEnabled.Load() + analyticsEnabled.Store(false) + t.Cleanup(func() { analyticsEnabled.Store(prev) }) + + emitAnalyticsEvent(AnalyticsEvent{Tool: "test"}) +} + +func TestEmitAnalyticsEvent_FullChannelDoesNotBlock(t *testing.T) { + prevEnabled := analyticsEnabled.Load() + prevCh := analyticsCh + t.Cleanup(func() { + analyticsEnabled.Store(prevEnabled) + analyticsCh = prevCh + }) + + analyticsCh = make(chan AnalyticsEvent, 1) + analyticsEnabled.Store(true) + analyticsCh <- AnalyticsEvent{Tool: "filler"} // fill the buffer + + // Second emit should drop silently rather than block. If the function + // blocks, the goroutine never closes `done` and the timeout below fires. + done := make(chan struct{}) + go func() { + emitAnalyticsEvent(AnalyticsEvent{Tool: "dropped"}) + close(done) + }() + select { + case <-done: + // pass + case <-time.After(time.Second): + t.Fatal("emitAnalyticsEvent blocked on a full channel") + } +} diff --git a/plugins/corezoid/mcp-server/executor_access.go b/plugins/corezoid/mcp-server/executor_access.go new file mode 100644 index 0000000..ad51bde --- /dev/null +++ b/plugins/corezoid/mcp-server/executor_access.go @@ -0,0 +1,651 @@ +package main + +import ( + "encoding/json" + "fmt" + "os" + "path/filepath" + "regexp" + "strings" + "time" +) + +// Access-control operations: sharing processes/folders/stages/projects to +// users, groups and API keys; creating and managing groups and API keys. +// +// All of these hit POST /api/2/json (the unified Corezoid endpoint that +// Executor.req already dispatches to) and follow the same ops envelope as +// folder / conv / dashboard mutations. + +// Principal describes an entity that can hold privileges on a Corezoid +// object: a regular user, a user group, or an API key. From the link API's +// point of view an API key is just a "user" record whose login is of type +// "api" — so callers pass Kind="user" for both real users and API keys, and +// Kind="group" for groups. +type Principal struct { + Kind string // "user" | "group" (api_key shares as "user") + ID int + Title string + IsAPI bool // true when this user is actually an API key + APILogin string // populated for IsAPI=true; empty otherwise + APIKey string // populated for IsAPI=true after CreateAPIKey +} + +// PrivType is one of the four Corezoid privilege flavours. +type PrivType string + +const ( + PrivView PrivType = "view" + PrivCreate PrivType = "create" + PrivModify PrivType = "modify" + PrivDelete PrivType = "delete" +) + +// AllPrivs is the standard read+write+delete bundle returned for +// "full access" share requests. +var AllPrivs = []PrivType{PrivCreate, PrivModify, PrivDelete, PrivView} + +// privsPayload converts a list of privilege types into the +// [{type, list_obj:["all"]}] structure the API expects. +func privsPayload(privs []PrivType) []map[string]any { + if len(privs) == 0 { + return []map[string]any{} + } + out := make([]map[string]any, 0, len(privs)) + for _, p := range privs { + out = append(out, map[string]any{ + "type": string(p), + "list_obj": []string{"all"}, + }) + } + return out +} + +// validateObjKind rejects callers that supplied a sharing target the link API +// does not accept. Kept separate from the API call so unit tests can exercise +// it without hitting the network. +func validateObjKind(kind string) error { + switch kind { + case "conv", "folder", "stage", "project": + return nil + } + return fmt.Errorf("obj must be one of conv|folder|stage|project, got %q", kind) +} + +// validatePrincipalKind ensures the recipient kind is something the link API +// recognises. API keys share as kind="user" because they are user records in +// the data model. +func validatePrincipalKind(kind string) error { + switch kind { + case "user", "group": + return nil + } + return fmt.Errorf("obj_to must be one of user|group, got %q", kind) +} + +// ShareObject grants privileges on an object (conv/folder/stage/project) to +// a user, API key or group. Passing an empty privs slice unshares — Corezoid +// uses the same link op shape for grant and revoke, distinguished only by +// whether privs is populated. +func (v *Executor) ShareObject(objKind string, objID int, toKind string, toID int, privs []PrivType, notify bool) (map[string]any, error) { + if err := validateObjKind(objKind); err != nil { + return nil, err + } + if err := validatePrincipalKind(toKind); err != nil { + return nil, err + } + op := map[string]any{ + "type": "link", + "obj": objKind, + "obj_id": objID, + "obj_to": toKind, + "obj_to_id": toID, + "is_need_to_notify": notify, + "company_id": v.WorkspaceID, + "privs": privsPayload(privs), + } + resp, err := v.req("share_object", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ShareObject failed: %w", err) + } + return firstOp(resp) +} + +// ListShares returns the groups, users and API keys that currently have +// access to the given object. The API uses list_obj:"group" for this query +// but the response includes user and api_key entries too. +func (v *Executor) ListShares(objKind string, objID int) ([]map[string]any, error) { + if err := validateObjKind(objKind); err != nil { + return nil, err + } + op := map[string]any{ + "type": "list", + "obj": objKind, + "obj_id": objID, + "list_obj": "group", + "company_id": v.WorkspaceID, + } + resp, err := v.req("list_shares", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ListShares failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, err + } + list, _ := first["list"].([]any) + out := make([]map[string]any, 0, len(list)) + for _, item := range list { + if m, ok := item.(map[string]any); ok { + out = append(out, m) + } + } + return out, nil +} + +// CreateGroup creates a new user group in the current workspace and returns +// the new group's obj_id. obj_type is "admins" — the only kind end users can +// create ("supers" is system-owned). description is optional and only sent +// when non-empty. +func (v *Executor) CreateGroup(title, description string) (int, error) { + if strings.TrimSpace(title) == "" { + return 0, fmt.Errorf("group title must not be empty") + } + op := map[string]any{ + "type": "create", + "obj": "group", + "obj_type": "admins", + "title": title, + "company_id": v.WorkspaceID, + } + if description != "" { + op["description"] = description + } + resp, err := v.req("create_group", []map[string]any{op}) + if err != nil { + return 0, fmt.Errorf("CreateGroup failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return 0, err + } + id, ok := first["obj_id"].(float64) + if !ok { + return 0, fmt.Errorf("CreateGroup: obj_id missing in response") + } + return int(id), nil +} + +// ModifyGroup updates a group's title and/or description. Empty fields are +// not sent so callers can patch one field without overwriting others. +func (v *Executor) ModifyGroup(groupID int, title, description string) error { + if strings.TrimSpace(title) == "" && description == "" { + return fmt.Errorf("ModifyGroup: at least one of title or description must be provided") + } + op := map[string]any{ + "type": "modify", + "obj": "group", + "obj_id": groupID, + "obj_type": "admins", + "company_id": v.WorkspaceID, + } + if title != "" { + op["title"] = title + } + if description != "" { + op["description"] = description + } + _, err := v.req("modify_group", []map[string]any{op}) + if err != nil { + return fmt.Errorf("ModifyGroup failed: %w", err) + } + return nil +} + +// ListGroupObjects returns the processes (conv objects) currently shared with +// the group. Corezoid only documents list_obj="conv" for this endpoint — +// folders / stages / projects shared to the group are not retrievable in one +// call. Caller uses this list to warn before destructive group operations. +func (v *Executor) ListGroupObjects(groupID int) ([]map[string]any, error) { + op := map[string]any{ + "type": "list", + "obj": "group", + "obj_id": groupID, + "list_obj": "conv", + "company_id": v.WorkspaceID, + } + resp, err := v.req("list_group_objects", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ListGroupObjects failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, err + } + list, _ := first["list"].([]any) + out := make([]map[string]any, 0, len(list)) + for _, item := range list { + if m, ok := item.(map[string]any); ok { + out = append(out, m) + } + } + return out, nil +} + +// DeleteGroup removes a group. Existing share links that referenced the group +// are revoked server-side. Pass force=false to refuse deletion when the group +// still has objects attached — the caller then explicitly retries with force. +func (v *Executor) DeleteGroup(groupID int, force bool) ([]map[string]any, error) { + if !force { + objs, err := v.ListGroupObjects(groupID) + if err != nil { + return nil, fmt.Errorf("DeleteGroup precheck failed: %w", err) + } + if len(objs) > 0 { + return objs, fmt.Errorf("group #%d still has %d shared object(s); pass force=true to delete anyway", groupID, len(objs)) + } + } + op := map[string]any{ + "type": "delete", + "obj": "group", + "obj_id": groupID, + "company_id": v.WorkspaceID, + } + _, err := v.req("delete_group", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("DeleteGroup failed: %w", err) + } + return nil, nil +} + +// AddToGroup links a user (or API-key user) to a group. level=1 is the +// default admin role for the group; the API rejects 0 silently. +func (v *Executor) AddToGroup(groupID, userID int) error { + op := map[string]any{ + "type": "link", + "obj": "user", + "obj_id": userID, + "group_id": groupID, + "company_id": v.WorkspaceID, + "level": 1, + } + _, err := v.req("add_to_group", []map[string]any{op}) + if err != nil { + return fmt.Errorf("AddToGroup failed: %w", err) + } + return nil +} + +// RemoveFromGroup unlinks a user from a group. Corezoid keeps the same +// type:"link" envelope but expects level="" (empty) to mean remove — +// level=0 and type:"unlink" are both rejected by the server. +func (v *Executor) RemoveFromGroup(groupID, userID int) error { + op := map[string]any{ + "type": "link", + "obj": "user", + "obj_id": userID, + "group_id": groupID, + "company_id": v.WorkspaceID, + "level": "", + } + _, err := v.req("remove_from_group", []map[string]any{op}) + if err != nil { + return fmt.Errorf("RemoveFromGroup failed: %w", err) + } + return nil +} + +// ListGroups returns all groups visible in the current workspace. +// "name" filters server-side via substring match; pass "" for no filter. +func (v *Executor) ListGroups(name string) ([]map[string]any, error) { + op := map[string]any{ + "type": "list", + "obj": "company_users", + "filter": "group", + "sort": "title", + "order": "asc", + "company_id": v.WorkspaceID, + } + if name != "" { + op["name"] = name + } + resp, err := v.req("list_groups", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ListGroups failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, err + } + list, _ := first["list"].([]any) + out := make([]map[string]any, 0, len(list)) + for _, item := range list { + if m, ok := item.(map[string]any); ok { + out = append(out, m) + } + } + return out, nil +} + +// CreateAPIKey provisions a new API key under the current workspace and +// returns the principal (with APILogin/APIKey populated). The secret is +// also persisted to ~/.corezoid/api-keys/-.json with mode 0600 +// so the caller can surface a file path instead of leaking the secret into +// chat output. description is optional. +func (v *Executor) CreateAPIKey(title, description string) (*Principal, string, error) { + if strings.TrimSpace(title) == "" { + return nil, "", fmt.Errorf("api key title must not be empty") + } + op := map[string]any{ + "type": "create", + "obj": "user", + "title": title, + "company_id": v.WorkspaceID, + "logins": []map[string]any{{"type": "api"}}, + } + if description != "" { + op["description"] = description + } + resp, err := v.req("create_api_key", []map[string]any{op}) + if err != nil { + return nil, "", fmt.Errorf("CreateAPIKey failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, "", err + } + users, _ := first["users"].([]any) + if len(users) == 0 { + return nil, "", fmt.Errorf("CreateAPIKey: empty users list in response") + } + u, _ := users[0].(map[string]any) + p := &Principal{ + Kind: "user", + Title: stringValue(u, "title"), + IsAPI: true, + } + if f, ok := u["obj_id"].(float64); ok { + p.ID = int(f) + } + if logins, ok := u["logins"].([]any); ok && len(logins) > 0 { + if l, ok := logins[0].(map[string]any); ok { + p.APILogin = stringValue(l, "login") + p.APIKey = stringValue(l, "key") + } + } + if p.ID == 0 { + return nil, "", fmt.Errorf("CreateAPIKey: obj_id missing in response") + } + // The create response omits the login string (it returns only the + // inner login obj_id). Without that string the secret is unusable, + // because API_LOGIN in the signed-request URL expects it. Pull it + // from a follow-up show call so the file we persist is complete. + if p.APILogin == "" { + if info, sErr := v.ShowAPIKey(p.ID); sErr == nil { + if logins, ok := info["logins"].([]any); ok && len(logins) > 0 { + if l, ok := logins[0].(map[string]any); ok { + p.APILogin = stringValue(l, "login") + } + } + } + } + path, err := writeAPIKeySecret(p, title, description) + if err != nil { + return p, "", fmt.Errorf("CreateAPIKey: created obj_id=%d but failed to persist secret: %w", p.ID, err) + } + return p, path, nil +} + +// ModifyAPIKey updates the title and/or description of an existing API key +// user record. Empty arguments are omitted so callers can patch a single +// field without overwriting the other. +func (v *Executor) ModifyAPIKey(apiKeyUserID int, title, description string) error { + if strings.TrimSpace(title) == "" && description == "" { + return fmt.Errorf("ModifyAPIKey: at least one of title or description must be provided") + } + op := map[string]any{ + "type": "modify", + "obj": "user", + "obj_id": apiKeyUserID, + "company_id": v.WorkspaceID, + } + if title != "" { + op["title"] = title + } + if description != "" { + op["description"] = description + } + _, err := v.req("modify_api_key", []map[string]any{op}) + if err != nil { + return fmt.Errorf("ModifyAPIKey failed: %w", err) + } + return nil +} + +// ShowAPIKey returns metadata about an existing API-key user. CreateAPIKey +// calls it as a second hop to fetch the login string, which is not part of +// the create response. +func (v *Executor) ShowAPIKey(apiKeyUserID int) (map[string]any, error) { + op := map[string]any{ + "type": "show", + "obj": "user", + "obj_id": apiKeyUserID, + "obj_type": "company", + "company_id": v.WorkspaceID, + } + resp, err := v.req("show_api_key", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ShowAPIKey failed: %w", err) + } + return firstOp(resp) +} + +// reSlugUnsafe matches characters not allowed in our secret-filename slug. +// Anything outside ASCII letters/digits/dash/underscore is collapsed to '-'. +var reSlugUnsafe = regexp.MustCompile(`[^A-Za-z0-9_-]+`) + +// secretsDir returns ~/.corezoid/api-keys, creating it with mode 0700 if +// missing. Reusing the same root directory as credentials.go means a single +// `rm -rf ~/.corezoid` wipes all sensitive material at once. +func secretsDir() (string, error) { + home, err := os.UserHomeDir() + if err != nil { + return "", err + } + dir := filepath.Join(home, ".corezoid", "api-keys") + if err := os.MkdirAll(dir, 0700); err != nil { + return "", err + } + return dir, nil +} + +// writeAPIKeySecret persists a freshly generated key to a 0600 JSON file and +// returns the file path. The secret never leaves disk after this call — the +// MCP handler reports only the path back to the user. +func writeAPIKeySecret(p *Principal, title, description string) (string, error) { + dir, err := secretsDir() + if err != nil { + return "", err + } + slug := strings.Trim(reSlugUnsafe.ReplaceAllString(title, "-"), "-") + if slug == "" { + slug = "api-key" + } + name := fmt.Sprintf("%s-%d.json", slug, p.ID) + path := filepath.Join(dir, name) + payload := map[string]any{ + "title": title, + "description": description, + "obj_id": p.ID, + "login": p.APILogin, + "secret": p.APIKey, + "created_at": time.Now().UTC().Format(time.RFC3339), + } + data, err := json.MarshalIndent(payload, "", " ") + if err != nil { + return "", err + } + if err := os.WriteFile(path, append(data, '\n'), 0600); err != nil { + return "", err + } + return path, nil +} + +// DeleteAPIKey removes an API-key user record. After deletion every object +// owned by it is reassigned to the workspace owner, per the platform docs. +func (v *Executor) DeleteAPIKey(apiKeyUserID int) error { + op := map[string]any{ + "type": "delete", + "obj": "user", + "obj_id": apiKeyUserID, + "company_id": v.WorkspaceID, + } + _, err := v.req("delete_api_key", []map[string]any{op}) + if err != nil { + return fmt.Errorf("DeleteAPIKey failed: %w", err) + } + return nil +} + +// ListAPIKeys returns all API keys visible to the current user in the +// workspace. The optional name filter is a substring match on key title. +func (v *Executor) ListAPIKeys(name string) ([]map[string]any, error) { + op := map[string]any{ + "type": "list", + "obj": "company_users", + "filter": "api_key", + "sort": "title", + "order": "asc", + "company_id": v.WorkspaceID, + } + if name != "" { + op["name"] = name + } + resp, err := v.req("list_api_keys", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("ListAPIKeys failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, err + } + list, _ := first["list"].([]any) + out := make([]map[string]any, 0, len(list)) + for _, item := range list { + if m, ok := item.(map[string]any); ok { + out = append(out, m) + } + } + return out, nil +} + +// FindPrincipal does substring search across users, groups and API keys +// inside the current workspace. filter is "user" | "group" | "api_key" +// (or "" — defaults to "user"). The single endpoint is company_users with +// the requested filter applied. +func (v *Executor) FindPrincipal(name, filter string) ([]map[string]any, error) { + if filter == "" { + filter = "user" + } + switch filter { + case "user", "group", "api_key", "shared": + default: + return nil, fmt.Errorf("filter must be one of user|group|api_key|shared, got %q", filter) + } + op := map[string]any{ + "type": "list", + "obj": "company_users", + "filter": filter, + "sort": "title", + "order": "asc", + "company_id": v.WorkspaceID, + } + if name != "" { + op["name"] = name + } + resp, err := v.req("find_principal", []map[string]any{op}) + if err != nil { + return nil, fmt.Errorf("FindPrincipal failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return nil, err + } + list, _ := first["list"].([]any) + out := make([]map[string]any, 0, len(list)) + for _, item := range list { + if m, ok := item.(map[string]any); ok { + out = append(out, m) + } + } + return out, nil +} + +// InviteUser invites an external email (not yet a workspace member) and +// simultaneously shares a single object with them. loginType is typically +// "google" or "corezoid". Returns the activation URL the recipient must +// open to accept the invite. +func (v *Executor) InviteUser(email, loginType, linkObjKind string, linkObjID int, privs []PrivType) (string, error) { + if err := validateObjKind(linkObjKind); err != nil { + return "", err + } + if strings.TrimSpace(email) == "" { + return "", fmt.Errorf("email must not be empty") + } + if loginType == "" { + loginType = "google" + } + op := map[string]any{ + "type": "create", + "obj": "invite", + "login": email, + "login_type": loginType, + "company_id": v.WorkspaceID, + "link_to_obj": linkObjKind, + "link_to_obj_id": linkObjID, + "privs": privsPayload(privs), + } + resp, err := v.req("invite_user", []map[string]any{op}) + if err != nil { + return "", fmt.Errorf("InviteUser failed: %w", err) + } + first, err := firstOp(resp) + if err != nil { + return "", err + } + return stringValue(first, "url"), nil +} + +// firstOp extracts ops[0] from a Corezoid response envelope and verifies it +// reports proc=="ok". Centralising the unwrap keeps every executor method in +// this file free of boilerplate response-shape checks. +func firstOp(resp map[string]any) (map[string]any, error) { + if resp == nil { + return nil, fmt.Errorf("empty response") + } + opsRaw, ok := resp["ops"].([]any) + if !ok || len(opsRaw) == 0 { + return nil, fmt.Errorf("response has no ops") + } + op, ok := opsRaw[0].(map[string]any) + if !ok { + return nil, fmt.Errorf("unexpected op format") + } + if proc, _ := op["proc"].(string); proc != "ok" { + desc, _ := op["description"].(string) + if desc == "" { + desc = fmt.Sprintf("proc=%v", op["proc"]) + } + return op, fmt.Errorf("%s", desc) + } + return op, nil +} + +// stringValue safely reads a string field from a JSON-decoded map. +func stringValue(m map[string]any, key string) string { + if m == nil { + return "" + } + s, _ := m[key].(string) + return s +} diff --git a/plugins/corezoid/mcp-server/executor_access_test.go b/plugins/corezoid/mcp-server/executor_access_test.go new file mode 100644 index 0000000..993c238 --- /dev/null +++ b/plugins/corezoid/mcp-server/executor_access_test.go @@ -0,0 +1,301 @@ +package main + +import ( + "encoding/json" + "os" + "path/filepath" + "strings" + "testing" +) + +// ---- privsPayload ---------------------------------------------------------- + +func TestPrivsPayload_Empty(t *testing.T) { + got := privsPayload(nil) + if got == nil { + t.Fatal("expected non-nil empty slice") + } + if len(got) != 0 { + t.Errorf("expected empty payload, got %v", got) + } + + got = privsPayload([]PrivType{}) + if len(got) != 0 { + t.Errorf("expected empty payload for empty input, got %v", got) + } +} + +func TestPrivsPayload_AllPrivs(t *testing.T) { + got := privsPayload(AllPrivs) + if len(got) != 4 { + t.Fatalf("expected 4 entries, got %d", len(got)) + } + wantTypes := map[string]bool{"create": false, "modify": false, "delete": false, "view": false} + for _, m := range got { + typ, _ := m["type"].(string) + if _, ok := wantTypes[typ]; !ok { + t.Errorf("unexpected priv type %q", typ) + continue + } + wantTypes[typ] = true + listObj, _ := m["list_obj"].([]string) + if len(listObj) != 1 || listObj[0] != "all" { + t.Errorf("expected list_obj=[\"all\"], got %v", listObj) + } + } + for typ, seen := range wantTypes { + if !seen { + t.Errorf("priv %q missing from payload", typ) + } + } +} + +func TestPrivsPayload_PreservesOrder(t *testing.T) { + in := []PrivType{PrivView, PrivCreate} + got := privsPayload(in) + if len(got) != 2 { + t.Fatalf("expected 2 entries, got %d", len(got)) + } + if got[0]["type"] != "view" || got[1]["type"] != "create" { + t.Errorf("order not preserved: %v", got) + } +} + +// ---- validateObjKind ------------------------------------------------------- + +func TestValidateObjKind_Valid(t *testing.T) { + for _, k := range []string{"conv", "folder", "stage", "project"} { + if err := validateObjKind(k); err != nil { + t.Errorf("expected %q to be valid: %v", k, err) + } + } +} + +func TestValidateObjKind_Invalid(t *testing.T) { + for _, k := range []string{"", "user", "dashboard", "Conv", "FOLDER"} { + if err := validateObjKind(k); err == nil { + t.Errorf("expected %q to be rejected", k) + } + } +} + +// ---- validatePrincipalKind ------------------------------------------------- + +func TestValidatePrincipalKind_Valid(t *testing.T) { + for _, k := range []string{"user", "group"} { + if err := validatePrincipalKind(k); err != nil { + t.Errorf("expected %q to be valid: %v", k, err) + } + } +} + +func TestValidatePrincipalKind_Invalid(t *testing.T) { + for _, k := range []string{"", "api_key", "User", "GROUP", "other"} { + if err := validatePrincipalKind(k); err == nil { + t.Errorf("expected %q to be rejected", k) + } + } +} + +// ---- firstOp --------------------------------------------------------------- + +func TestFirstOp_Success(t *testing.T) { + resp := map[string]any{ + "ops": []any{ + map[string]any{"proc": "ok", "id": float64(1)}, + }, + } + op, err := firstOp(resp) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if op["id"].(float64) != 1 { + t.Errorf("unexpected op contents: %v", op) + } +} + +func TestFirstOp_NilResponse(t *testing.T) { + _, err := firstOp(nil) + if err == nil || !strings.Contains(err.Error(), "empty") { + t.Errorf("expected empty-response error, got %v", err) + } +} + +func TestFirstOp_NoOps(t *testing.T) { + _, err := firstOp(map[string]any{}) + if err == nil { + t.Error("expected error for missing ops") + } + + _, err = firstOp(map[string]any{"ops": []any{}}) + if err == nil { + t.Error("expected error for empty ops slice") + } +} + +func TestFirstOp_BadOpShape(t *testing.T) { + _, err := firstOp(map[string]any{ + "ops": []any{"not-a-map"}, + }) + if err == nil { + t.Error("expected error for non-map op") + } +} + +func TestFirstOp_ProcNotOK_WithDescription(t *testing.T) { + resp := map[string]any{ + "ops": []any{ + map[string]any{"proc": "fail", "description": "boom"}, + }, + } + op, err := firstOp(resp) + if err == nil { + t.Fatal("expected error for proc!=ok") + } + if !strings.Contains(err.Error(), "boom") { + t.Errorf("expected description in error, got %v", err) + } + // Caller should still see the op for inspection. + if op == nil { + t.Error("expected op to be returned alongside the error") + } +} + +func TestFirstOp_ProcNotOK_NoDescription(t *testing.T) { + resp := map[string]any{ + "ops": []any{ + map[string]any{"proc": "fail"}, + }, + } + _, err := firstOp(resp) + if err == nil || !strings.Contains(err.Error(), "fail") { + t.Errorf("expected proc value in error, got %v", err) + } +} + +// ---- stringValue ----------------------------------------------------------- + +func TestStringValue(t *testing.T) { + m := map[string]any{"url": "https://x", "count": 5, "obj": map[string]any{}} + if got := stringValue(m, "url"); got != "https://x" { + t.Errorf("expected URL, got %q", got) + } + // Non-string field is returned as empty. + if got := stringValue(m, "count"); got != "" { + t.Errorf("expected empty string for non-string value, got %q", got) + } + // Missing key. + if got := stringValue(m, "missing"); got != "" { + t.Errorf("expected empty string for missing key, got %q", got) + } + // Nil map. + if got := stringValue(nil, "url"); got != "" { + t.Errorf("expected empty string for nil map, got %q", got) + } +} + +// ---- secretsDir ------------------------------------------------------------ + +func TestSecretsDir_CreatesDir(t *testing.T) { + home := t.TempDir() + t.Setenv("HOME", home) + + dir, err := secretsDir() + if err != nil { + t.Fatalf("secretsDir error: %v", err) + } + want := filepath.Join(home, ".corezoid", "api-keys") + if dir != want { + t.Errorf("expected %q, got %q", want, dir) + } + info, err := os.Stat(dir) + if err != nil { + t.Fatalf("expected dir to exist: %v", err) + } + if !info.IsDir() { + t.Error("expected a directory") + } +} + +// ---- writeAPIKeySecret ----------------------------------------------------- + +func TestWriteAPIKeySecret_WritesValidJSON(t *testing.T) { + home := t.TempDir() + t.Setenv("HOME", home) + + p := &Principal{ID: 42, APILogin: "svc-bot", APIKey: "shhh"} + path, err := writeAPIKeySecret(p, "My API Key!", "for tests") + if err != nil { + t.Fatalf("writeAPIKeySecret error: %v", err) + } + // Slug should collapse unsafe characters; ID is appended. + wantSuffix := "My-API-Key-42.json" + if filepath.Base(path) != wantSuffix { + t.Errorf("expected file %q, got %q", wantSuffix, filepath.Base(path)) + } + + // File must be 0600. + info, err := os.Stat(path) + if err != nil { + t.Fatalf("stat: %v", err) + } + if info.Mode().Perm() != 0600 { + t.Errorf("expected mode 0600, got %v", info.Mode().Perm()) + } + + // Content must be valid JSON with the expected fields. + data, err := os.ReadFile(path) + if err != nil { + t.Fatalf("read: %v", err) + } + var payload map[string]any + if err := json.Unmarshal(data, &payload); err != nil { + t.Fatalf("invalid JSON: %v", err) + } + if payload["secret"] != "shhh" { + t.Errorf("expected secret to be persisted, got %v", payload["secret"]) + } + if payload["login"] != "svc-bot" { + t.Errorf("expected login persisted, got %v", payload["login"]) + } + if payload["title"] != "My API Key!" { + t.Errorf("expected title persisted, got %v", payload["title"]) + } + if payload["description"] != "for tests" { + t.Errorf("expected description persisted, got %v", payload["description"]) + } + // obj_id round-trips through JSON as float64. + if id, _ := payload["obj_id"].(float64); int(id) != 42 { + t.Errorf("expected obj_id 42, got %v", payload["obj_id"]) + } +} + +func TestWriteAPIKeySecret_EmptyTitleFallsBackToDefault(t *testing.T) { + home := t.TempDir() + t.Setenv("HOME", home) + + p := &Principal{ID: 7} + path, err := writeAPIKeySecret(p, "", "") + if err != nil { + t.Fatalf("writeAPIKeySecret error: %v", err) + } + if filepath.Base(path) != "api-key-7.json" { + t.Errorf("expected default slug, got %q", filepath.Base(path)) + } +} + +func TestWriteAPIKeySecret_SlugCollapsesUnsafeChars(t *testing.T) { + home := t.TempDir() + t.Setenv("HOME", home) + + p := &Principal{ID: 1} + path, err := writeAPIKeySecret(p, "a/b\\c?d", "") + if err != nil { + t.Fatalf("writeAPIKeySecret error: %v", err) + } + base := filepath.Base(path) + // All unsafe characters collapse to '-'. + if !strings.HasPrefix(base, "a-b-c-d-") { + t.Errorf("unexpected slug: %q", base) + } +} diff --git a/plugins/corezoid/mcp-server/executor_process.go b/plugins/corezoid/mcp-server/executor_process.go index 5277ad5..24d5a4f 100644 --- a/plugins/corezoid/mcp-server/executor_process.go +++ b/plugins/corezoid/mcp-server/executor_process.go @@ -423,9 +423,20 @@ func (v *Executor) GetProcessByID(id int) (rsp map[string]any, err error) { } func (v *Executor) CreateEmptyProcess(folderID int, title, desc string) int { + return v.CreateEmptyConv(folderID, title, desc, "process") +} + +// CreateEmptyConv creates an empty Corezoid object of the given conv_type +// ("process" for a regular process, "state" for a state diagram). +// CreateEmptyProcess is preserved as a backward-compatible wrapper that +// defaults to conv_type "process". +func (v *Executor) CreateEmptyConv(folderID int, title, desc, convType string) int { if title == "" { title = time.Now().String() } + if convType == "" { + convType = "process" + } ops := []map[string]any{ { "title": title, @@ -434,7 +445,7 @@ func (v *Executor) CreateEmptyProcess(folderID int, title, desc string) int { "company_id": v.WorkspaceID, "obj": "conv", "create_mode": "without_nodes", - "conv_type": "process", + "conv_type": convType, "type": "create", "obj_type": 0, "status": "active", diff --git a/plugins/corezoid/mcp-server/json-schema/process.json b/plugins/corezoid/mcp-server/json-schema/process.json index a3d0931..a8bda99 100644 --- a/plugins/corezoid/mcp-server/json-schema/process.json +++ b/plugins/corezoid/mcp-server/json-schema/process.json @@ -89,9 +89,10 @@ "conv_type": { "type": "string", "enum": [ - "process" + "process", + "state" ], - "description": "Conveyor type" + "description": "Conveyor type: 'process' for regular processes, 'state' for state diagrams" }, "scheme": { "type": "object", diff --git a/plugins/corezoid/mcp-server/main_config_test.go b/plugins/corezoid/mcp-server/main_config_test.go new file mode 100644 index 0000000..46df23a --- /dev/null +++ b/plugins/corezoid/mcp-server/main_config_test.go @@ -0,0 +1,207 @@ +package main + +import ( + "os" + "path/filepath" + "sync" + "testing" +) + +// ---- envFilePath ----------------------------------------------------------- + +func TestEnvFilePath(t *testing.T) { + dir := t.TempDir() + orig, _ := os.Getwd() + if err := os.Chdir(dir); err != nil { + t.Fatal(err) + } + t.Cleanup(func() { _ = os.Chdir(orig) }) + + got := envFilePath() + // On macOS /var and /private/var are the same path via symlink, so compare + // via EvalSymlinks to avoid flaking. + wantBase := filepath.Base(got) + if wantBase != ".env" { + t.Errorf("expected basename .env, got %q", wantBase) + } + gotDir, _ := filepath.EvalSymlinks(filepath.Dir(got)) + wantDir, _ := filepath.EvalSymlinks(dir) + if gotDir != wantDir { + t.Errorf("expected dir %q, got %q", wantDir, gotDir) + } +} + +// ---- withAuthLock ---------------------------------------------------------- + +func TestWithAuthLock_RunsFn(t *testing.T) { + called := false + withAuthLock(func() { called = true }) + if !called { + t.Error("expected fn to run") + } +} + +func TestWithAuthLock_SerializesAccess(t *testing.T) { + // Two goroutines both increment via withAuthLock; without the lock we'd + // expect races. With the lock, the final count equals the sum. + var counter int + var wg sync.WaitGroup + const iters = 200 + for i := 0; i < 2; i++ { + wg.Add(1) + go func() { + defer wg.Done() + for j := 0; j < iters; j++ { + withAuthLock(func() { counter++ }) + } + }() + } + wg.Wait() + if counter != 2*iters { + t.Errorf("expected counter %d, got %d", 2*iters, counter) + } +} + +// ---- findAndLoadDotEnv ----------------------------------------------------- + +// Helper to snapshot+restore os.Getwd so changing dirs in tests doesn't leak. +func chdirWithCleanup(t *testing.T, dir string) { + t.Helper() + orig, _ := os.Getwd() + if err := os.Chdir(dir); err != nil { + t.Fatal(err) + } + t.Cleanup(func() { _ = os.Chdir(orig) }) +} + +func TestFindAndLoadDotEnv_LocatesInParentDir(t *testing.T) { + root := t.TempDir() + // Make root a project root so the search has a definitive stopping point. + if err := os.WriteFile(filepath.Join(root, "1_project.stage.json"), []byte("{}"), 0644); err != nil { + t.Fatal(err) + } + // .env lives at the root. + if err := os.WriteFile(filepath.Join(root, ".env"), []byte("TEST_FA_VAR=found\n"), 0600); err != nil { + t.Fatal(err) + } + // We start two levels deep. + deep := filepath.Join(root, "a", "b") + if err := os.MkdirAll(deep, 0700); err != nil { + t.Fatal(err) + } + chdirWithCleanup(t, deep) + + os.Unsetenv("TEST_FA_VAR") + t.Cleanup(func() { os.Unsetenv("TEST_FA_VAR") }) + + findAndLoadDotEnv() + + if got := os.Getenv("TEST_FA_VAR"); got != "found" { + t.Errorf("expected TEST_FA_VAR=found, got %q", got) + } +} + +func TestFindAndLoadDotEnv_StopsAtProjectRoot(t *testing.T) { + // Layout: + // ancestor/.env (must NOT be loaded) + // ancestor/root/ (project root — search stops here) + // ancestor/root/sub (cwd) + ancestor := t.TempDir() + if err := os.WriteFile(filepath.Join(ancestor, ".env"), []byte("TEST_FA_BLOCKED=oops\n"), 0600); err != nil { + t.Fatal(err) + } + root := filepath.Join(ancestor, "root") + if err := os.MkdirAll(root, 0700); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(root, "1_p.stage.json"), []byte("{}"), 0644); err != nil { + t.Fatal(err) + } + sub := filepath.Join(root, "sub") + if err := os.MkdirAll(sub, 0700); err != nil { + t.Fatal(err) + } + chdirWithCleanup(t, sub) + + os.Unsetenv("TEST_FA_BLOCKED") + t.Cleanup(func() { os.Unsetenv("TEST_FA_BLOCKED") }) + + findAndLoadDotEnv() + + if got := os.Getenv("TEST_FA_BLOCKED"); got != "" { + t.Errorf("expected TEST_FA_BLOCKED to remain unset (search must stop at project root), got %q", got) + } +} + +// ---- loadConfig ------------------------------------------------------------ + +// Snapshot/restore the globals loadConfig writes so the test is isolated. +func snapshotConfigGlobals(t *testing.T) { + t.Helper() + prevAPI, prevAcc, prevWS, prevTok, prevGW := apiURL, accountURL, workspaceID, apiToken, apigwURL + prevStage, prevInsecure := stageID, insecureTLS + t.Cleanup(func() { + apiURL, accountURL, workspaceID, apiToken, apigwURL = prevAPI, prevAcc, prevWS, prevTok, prevGW + stageID, insecureTLS = prevStage, prevInsecure + }) +} + +func TestLoadConfig_ReadsEnvVars(t *testing.T) { + snapshotConfigGlobals(t) + + // Isolate from any real ~/.corezoid/credentials and project .env. + home := t.TempDir() + t.Setenv("HOME", home) + dir := t.TempDir() + chdirWithCleanup(t, dir) + + t.Setenv("COREZOID_API_URL", "https://api.example") + t.Setenv("ACCOUNT_URL", "https://account.example") + t.Setenv("WORKSPACE_ID", "ws-1") + t.Setenv("ACCESS_TOKEN", "tok-abc") + t.Setenv("COREZOID_STAGE_ID", "4242") + t.Setenv("COREZOID_INSECURE_TLS", "1") + // Force apigw URL default to be overridden so we exercise the explicit branch. + t.Setenv("COREZOID_APIGW_URL", "https://gw.example") + + loadConfig() + + if apiURL != "https://api.example" { + t.Errorf("apiURL = %q", apiURL) + } + if accountURL != "https://account.example" { + t.Errorf("accountURL = %q", accountURL) + } + if workspaceID != "ws-1" { + t.Errorf("workspaceID = %q", workspaceID) + } + if apiToken != "tok-abc" { + t.Errorf("apiToken = %q", apiToken) + } + if stageID != 4242 { + t.Errorf("stageID = %d, want 4242", stageID) + } + if !insecureTLS { + t.Error("expected insecureTLS=true when COREZOID_INSECURE_TLS is set") + } + if apigwURL != "https://gw.example" { + t.Errorf("apigwURL = %q", apigwURL) + } +} + +func TestLoadConfig_DefaultsApigwURL(t *testing.T) { + snapshotConfigGlobals(t) + + home := t.TempDir() + t.Setenv("HOME", home) + dir := t.TempDir() + chdirWithCleanup(t, dir) + + // Explicitly unset so loadConfig picks the default. + t.Setenv("COREZOID_APIGW_URL", "") + loadConfig() + + if apigwURL != "https://api-apigw.corezoid.com" { + t.Errorf("expected default apigwURL, got %q", apigwURL) + } +} diff --git a/plugins/corezoid/mcp-server/mcp_handlers.go b/plugins/corezoid/mcp-server/mcp_handlers.go index e1afd13..5c20027 100644 --- a/plugins/corezoid/mcp-server/mcp_handlers.go +++ b/plugins/corezoid/mcp-server/mcp_handlers.go @@ -23,15 +23,16 @@ var toolHandlers = map[string]toolHandler{ "logout": handleLogout, // process / folder / alias - "pull-process": handlePullProcess, - "pull-folder": handlePullFolder, - "create-variable": handleCreateVariable, - "push-process": handlePushProcess, - "lint-process": handleLintProcess, - "run-task": handleRunTask, - "create-process": handleCreateProcess, - "create-folder": handleCreateFolder, - "create-alias": handleCreateAlias, + "pull-process": handlePullProcess, + "pull-folder": handlePullFolder, + "create-variable": handleCreateVariable, + "push-process": handlePushProcess, + "lint-process": handleLintProcess, + "run-task": handleRunTask, + "create-process": handleCreateProcess, + "create-state-diagram": handleCreateStateDiagram, + "create-folder": handleCreateFolder, + "create-alias": handleCreateAlias, // discovery "list-workspaces": handleListWorkspaces, @@ -51,6 +52,23 @@ var toolHandlers = map[string]toolHandler{ "modify-chart": handleModifyChart, "get-chart": handleGetChart, "set-dashboard-layout": handleSetDashboardLayout, + + // access control (share, groups, api keys, invites) + "share-object": handleShareObject, + "list-shares": handleListShares, + "create-group": handleCreateGroup, + "modify-group": handleModifyGroup, + "list-group-objects": handleListGroupObjects, + "delete-group": handleDeleteGroup, + "add-to-group": handleAddToGroup, + "remove-from-group": handleRemoveFromGroup, + "list-groups": handleListGroups, + "create-api-key": handleCreateAPIKey, + "modify-api-key": handleModifyAPIKey, + "delete-api-key": handleDeleteAPIKey, + "list-api-keys": handleListAPIKeys, + "find-principal": handleFindPrincipal, + "invite-user": handleInviteUser, } // noAuthTools don't need any credentials. lint runs entirely on local files; diff --git a/plugins/corezoid/mcp-server/mcp_handlers_access.go b/plugins/corezoid/mcp-server/mcp_handlers_access.go new file mode 100644 index 0000000..6e370d9 --- /dev/null +++ b/plugins/corezoid/mcp-server/mcp_handlers_access.go @@ -0,0 +1,526 @@ +package main + +import ( + "context" + "encoding/json" + "fmt" + "strings" +) + +// privsExplicitNone reports whether the caller explicitly asked to revoke +// access. We need three-way detection — "missing", "explicitly empty" +// (revoke) and "explicit list" (grant) — because the underlying link op +// uses the same shape for both grant and revoke, distinguished only by an +// empty privs array. +func privsExplicitNone(s string) bool { + s = strings.TrimSpace(s) + if s == "" { + return false + } + switch strings.ToLower(s) { + case "none", "[]", "revoke", "unshare": + return true + } + return false +} + +// parsePrivs accepts either a comma-separated string ("view,modify") or a +// JSON array (`["view","modify"]`) and returns the canonical PrivType slice. +// "all" expands to the full bundle. Returns (nil, nil) on empty input — the +// caller decides whether absent means "grant all" or is an error. To request +// an explicit revoke, callers pass one of the privsExplicitNone keywords +// rather than going through this function. +func parsePrivs(s string) ([]PrivType, error) { + s = strings.TrimSpace(s) + if s == "" { + return nil, nil + } + var tokens []string + if strings.HasPrefix(s, "[") { + var arr []string + if err := json.Unmarshal([]byte(s), &arr); err != nil { + return nil, fmt.Errorf("privs JSON array invalid: %v", err) + } + tokens = arr + } else { + for _, t := range strings.Split(s, ",") { + t = strings.TrimSpace(t) + if t != "" { + tokens = append(tokens, t) + } + } + } + var out []PrivType + for _, t := range tokens { + t = strings.ToLower(t) + if t == "all" { + return AllPrivs, nil + } + switch PrivType(t) { + case PrivView, PrivCreate, PrivModify, PrivDelete: + out = append(out, PrivType(t)) + default: + return nil, fmt.Errorf("unknown priv %q (allowed: view, create, modify, delete, all, none)", t) + } + } + return out, nil +} + +// handleShareObject grants (or revokes) privileges on a process / folder / +// stage / project for a user, API key (kind=user) or group. Pass +// privs="none" (or "[]") to revoke — that's the same wire operation as +// share with privs=[]. Absent privs defaults to "all". +func handleShareObject(ctx context.Context, args map[string]interface{}) (string, bool) { + objKind, err := strArg(args, "obj") + if err != nil { + return "Error: " + err.Error(), true + } + objID, err := intArg(args, "obj_id") + if err != nil { + return "Error: " + err.Error(), true + } + toKind, err := strArg(args, "obj_to") + if err != nil { + return "Error: " + err.Error(), true + } + toID, err := intArg(args, "obj_to_id") + if err != nil { + return "Error: " + err.Error(), true + } + privsArg := optStrArg(args, "privs") + revoke := privsExplicitNone(privsArg) + var privs []PrivType + if !revoke { + p, err := parsePrivs(privsArg) + if err != nil { + return "Error: " + err.Error(), true + } + if len(p) == 0 { + p = AllPrivs + } + privs = p + } + notify := true + if v, ok := args["notify"]; ok { + if b, ok := v.(bool); ok { + notify = b + } + } + + v := NewValidator(ctx, 0) + op, err := v.ShareObject(objKind, objID, toKind, toID, privs, notify) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + title := stringValue(op, "obj_to_title") + if revoke { + return fmt.Sprintf("Revoked %s #%d access for %s #%d (%s)", + objKind, objID, toKind, toID, title), false + } + return fmt.Sprintf("Shared %s #%d with %s #%d (%s) — privs: %s", + objKind, objID, toKind, toID, title, privsString(privs)), false +} + +// handleListShares prints who currently has access to an object. +func handleListShares(ctx context.Context, args map[string]interface{}) (string, bool) { + objKind, err := strArg(args, "obj") + if err != nil { + return "Error: " + err.Error(), true + } + objID, err := intArg(args, "obj_id") + if err != nil { + return "Error: " + err.Error(), true + } + + v := NewValidator(ctx, 0) + list, err := v.ListShares(objKind, objID) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + if len(list) == 0 { + return fmt.Sprintf("No shares on %s #%d", objKind, objID), false + } + + var sb strings.Builder + sb.WriteString(fmt.Sprintf("Shares on %s #%d (%d):\n\n", objKind, objID, len(list))) + sb.WriteString(fmt.Sprintf(" %-8s %-10s %-30s %s\n", "kind", "id", "title", "privs")) + sb.WriteString(" " + strings.Repeat("-", 70) + "\n") + for _, item := range list { + kind := stringValue(item, "obj") + if kind == "" { + kind = "?" + } + title := stringValue(item, "title") + id := 0 + if f, ok := item["obj_id"].(float64); ok { + id = int(f) + } + privs := formatItemPrivs(item) + sb.WriteString(fmt.Sprintf(" %-8s %-10d %-30s %s\n", kind, id, truncate(title, 28), privs)) + } + return sb.String(), false +} + +// formatItemPrivs renders the privs array from a list-shares response item. +func formatItemPrivs(item map[string]any) string { + pp, ok := item["privs"].([]any) + if !ok { + return "" + } + var parts []string + for _, p := range pp { + m, _ := p.(map[string]any) + if t := stringValue(m, "type"); t != "" { + parts = append(parts, t) + } + } + return strings.Join(parts, ",") +} + +func privsString(p []PrivType) string { + out := make([]string, 0, len(p)) + for _, v := range p { + out = append(out, string(v)) + } + return strings.Join(out, ",") +} + +func truncate(s string, max int) string { + if max <= 0 || len(s) <= max { + return s + } + if max <= 1 { + return s[:max] + } + return s[:max-1] + "…" +} + +// handleCreateGroup creates a new user group and returns its obj_id. +func handleCreateGroup(ctx context.Context, args map[string]interface{}) (string, bool) { + title, err := strArg(args, "title") + if err != nil { + return "Error: " + err.Error(), true + } + description := optStrArg(args, "description") + v := NewValidator(ctx, 0) + id, err := v.CreateGroup(title, description) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf("Group %q created — obj_id=%d (use this as obj_to_id with obj_to=group when sharing).", title, id), false +} + +// handleModifyGroup renames or re-describes a group. At least one of title +// or description must be supplied. +func handleModifyGroup(ctx context.Context, args map[string]interface{}) (string, bool) { + groupID, err := intArg(args, "group_id") + if err != nil { + return "Error: " + err.Error(), true + } + title := optStrArg(args, "title") + description := optStrArg(args, "description") + v := NewValidator(ctx, 0) + if err := v.ModifyGroup(groupID, title, description); err != nil { + return fmt.Sprintf("Error: %v", err), true + } + parts := []string{} + if title != "" { + parts = append(parts, fmt.Sprintf("title=%q", title)) + } + if description != "" { + parts = append(parts, fmt.Sprintf("description=%q", description)) + } + return fmt.Sprintf("Group #%d updated (%s)", groupID, strings.Join(parts, ", ")), false +} + +// handleListGroupObjects shows processes the group currently has access to. +func handleListGroupObjects(ctx context.Context, args map[string]interface{}) (string, bool) { + groupID, err := intArg(args, "group_id") + if err != nil { + return "Error: " + err.Error(), true + } + v := NewValidator(ctx, 0) + list, err := v.ListGroupObjects(groupID) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + if len(list) == 0 { + return fmt.Sprintf("Group #%d has no processes attached.", groupID), false + } + var sb strings.Builder + sb.WriteString(fmt.Sprintf("Processes shared with group #%d (%d):\n\n", groupID, len(list))) + sb.WriteString(fmt.Sprintf(" %-10s %-40s %s\n", "obj_id", "title", "status")) + sb.WriteString(" " + strings.Repeat("-", 70) + "\n") + for _, item := range list { + id := 0 + if f, ok := item["obj_id"].(float64); ok { + id = int(f) + } + title := stringValue(item, "title") + status := stringValue(item, "status") + sb.WriteString(fmt.Sprintf(" %-10d %-40s %s\n", id, truncate(title, 38), status)) + } + sb.WriteString("\nNote: this list covers processes only — folders, stages and projects shared with the group are not retrievable via this endpoint.\n") + return sb.String(), false +} + +// handleDeleteGroup removes a group. Refuses by default if the group still +// has active shares — caller must pass force=true to proceed. +func handleDeleteGroup(ctx context.Context, args map[string]interface{}) (string, bool) { + groupID, err := intArg(args, "group_id") + if err != nil { + return "Error: " + err.Error(), true + } + force := false + if v, ok := args["force"]; ok { + if b, ok := v.(bool); ok { + force = b + } else if s, ok := v.(string); ok { + force = strings.EqualFold(s, "true") || s == "1" + } + } + v := NewValidator(ctx, 0) + blockers, err := v.DeleteGroup(groupID, force) + if err != nil { + if len(blockers) > 0 { + var sb strings.Builder + sb.WriteString(fmt.Sprintf("Refused to delete group #%d — still has %d active share(s):\n\n", groupID, len(blockers))) + for _, b := range blockers { + id := 0 + if f, ok := b["obj_id"].(float64); ok { + id = int(f) + } + sb.WriteString(fmt.Sprintf(" conv #%d %s\n", id, stringValue(b, "title"))) + } + sb.WriteString("\nRe-run with force=true to delete anyway. Members will lose all access inherited from this group.\n") + return sb.String(), true + } + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf("Deleted group #%d", groupID), false +} + +// handleAddToGroup attaches a user (or API key user) to a group. +func handleAddToGroup(ctx context.Context, args map[string]interface{}) (string, bool) { + groupID, err := intArg(args, "group_id") + if err != nil { + return "Error: " + err.Error(), true + } + userID, err := intArg(args, "user_id") + if err != nil { + return "Error: " + err.Error(), true + } + v := NewValidator(ctx, 0) + if err := v.AddToGroup(groupID, userID); err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf("Added user #%d to group #%d", userID, groupID), false +} + +// handleRemoveFromGroup detaches a user from a group. +func handleRemoveFromGroup(ctx context.Context, args map[string]interface{}) (string, bool) { + groupID, err := intArg(args, "group_id") + if err != nil { + return "Error: " + err.Error(), true + } + userID, err := intArg(args, "user_id") + if err != nil { + return "Error: " + err.Error(), true + } + v := NewValidator(ctx, 0) + if err := v.RemoveFromGroup(groupID, userID); err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf("Removed user #%d from group #%d", userID, groupID), false +} + +// handleListGroups prints all groups in the workspace, optionally filtered by substring. +func handleListGroups(ctx context.Context, args map[string]interface{}) (string, bool) { + name := optStrArg(args, "name") + v := NewValidator(ctx, 0) + list, err := v.ListGroups(name) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + if len(list) == 0 { + return "No groups found", false + } + var sb strings.Builder + sb.WriteString(fmt.Sprintf("Groups in workspace (%d):\n\n", len(list))) + sb.WriteString(fmt.Sprintf(" %-10s %-30s %-6s %s\n", "id", "title", "size", "owner")) + sb.WriteString(" " + strings.Repeat("-", 70) + "\n") + for _, g := range list { + id := 0 + if f, ok := g["obj_id"].(float64); ok { + id = int(f) + } + size := 0 + if f, ok := g["size"].(float64); ok { + size = int(f) + } + title := stringValue(g, "title") + owner := stringValue(g, "owner_name") + sb.WriteString(fmt.Sprintf(" %-10d %-30s %-6d %s\n", id, truncate(title, 28), size, owner)) + } + return sb.String(), false +} + +// handleCreateAPIKey provisions a new API key. The secret is written to a +// 0600 JSON file under ~/.corezoid/api-keys/ and the chat output reports +// only the file path — the secret itself is never printed to the agent +// response. +func handleCreateAPIKey(ctx context.Context, args map[string]interface{}) (string, bool) { + title, err := strArg(args, "title") + if err != nil { + return "Error: " + err.Error(), true + } + description := optStrArg(args, "description") + v := NewValidator(ctx, 0) + p, path, err := v.CreateAPIKey(title, description) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf( + "API key %q created.\n obj_id (use as obj_to_id when sharing): %d\n login: %s\n secret: \n secret file: %s (chmod 600, JSON with login+secret+metadata)\n\n ⚠ Corezoid only shows the secret on creation — back up or import the file before deleting it.", + title, p.ID, p.APILogin, path), false +} + +// handleModifyAPIKey updates an API key's title/description. +func handleModifyAPIKey(ctx context.Context, args map[string]interface{}) (string, bool) { + apiKeyID, err := intArg(args, "api_key_id") + if err != nil { + return "Error: " + err.Error(), true + } + title := optStrArg(args, "title") + description := optStrArg(args, "description") + v := NewValidator(ctx, 0) + if err := v.ModifyAPIKey(apiKeyID, title, description); err != nil { + return fmt.Sprintf("Error: %v", err), true + } + parts := []string{} + if title != "" { + parts = append(parts, fmt.Sprintf("title=%q", title)) + } + if description != "" { + parts = append(parts, fmt.Sprintf("description=%q", description)) + } + return fmt.Sprintf("API key #%d updated (%s)", apiKeyID, strings.Join(parts, ", ")), false +} + + +// handleDeleteAPIKey removes an API key user record. +func handleDeleteAPIKey(ctx context.Context, args map[string]interface{}) (string, bool) { + id, err := intArg(args, "api_key_id") + if err != nil { + return "Error: " + err.Error(), true + } + v := NewValidator(ctx, 0) + if err := v.DeleteAPIKey(id); err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf("Deleted API key #%d", id), false +} + +// handleListAPIKeys prints API keys in the workspace. +func handleListAPIKeys(ctx context.Context, args map[string]interface{}) (string, bool) { + name := optStrArg(args, "name") + v := NewValidator(ctx, 0) + list, err := v.ListAPIKeys(name) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + if len(list) == 0 { + return "No API keys found", false + } + var sb strings.Builder + sb.WriteString(fmt.Sprintf("API keys in workspace (%d):\n\n", len(list))) + sb.WriteString(fmt.Sprintf(" %-10s %-30s %-10s %s\n", "id", "title", "status", "login")) + sb.WriteString(" " + strings.Repeat("-", 70) + "\n") + for _, k := range list { + id := 0 + if f, ok := k["obj_id"].(float64); ok { + id = int(f) + } + title := stringValue(k, "title") + status := stringValue(k, "status") + login := "" + if logins, ok := k["logins"].([]any); ok && len(logins) > 0 { + if l, ok := logins[0].(map[string]any); ok { + login = stringValue(l, "login") + } + } + sb.WriteString(fmt.Sprintf(" %-10d %-30s %-10s %s\n", id, truncate(title, 28), status, login)) + } + return sb.String(), false +} + +// handleFindPrincipal resolves user / group / API-key names to obj_ids. +func handleFindPrincipal(ctx context.Context, args map[string]interface{}) (string, bool) { + name := optStrArg(args, "name") + filter := optStrArg(args, "kind") + if filter == "" { + filter = "user" + } + v := NewValidator(ctx, 0) + list, err := v.FindPrincipal(name, filter) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + if len(list) == 0 { + return fmt.Sprintf("No %s entries match %q", filter, name), false + } + var sb strings.Builder + sb.WriteString(fmt.Sprintf("%s matches for %q (%d):\n\n", filter, name, len(list))) + sb.WriteString(fmt.Sprintf(" %-10s %-35s %s\n", "obj_id", "title", "extra")) + sb.WriteString(" " + strings.Repeat("-", 70) + "\n") + for _, item := range list { + id := 0 + if f, ok := item["obj_id"].(float64); ok { + id = int(f) + } + title := stringValue(item, "title") + extra := "" + if logins, ok := item["logins"].([]any); ok && len(logins) > 0 { + if l, ok := logins[0].(map[string]any); ok { + extra = fmt.Sprintf("%s: %s", stringValue(l, "type"), stringValue(l, "login")) + } + } else if owner := stringValue(item, "owner_name"); owner != "" { + extra = "owner: " + owner + } + sb.WriteString(fmt.Sprintf(" %-10d %-35s %s\n", id, truncate(title, 33), extra)) + } + sb.WriteString("\nUse obj_id as obj_to_id when sharing.\n") + return sb.String(), false +} + +// handleInviteUser invites an external email and shares an object with them. +func handleInviteUser(ctx context.Context, args map[string]interface{}) (string, bool) { + email, err := strArg(args, "email") + if err != nil { + return "Error: " + err.Error(), true + } + linkObj, err := strArg(args, "obj") + if err != nil { + return "Error: " + err.Error(), true + } + linkObjID, err := intArg(args, "obj_id") + if err != nil { + return "Error: " + err.Error(), true + } + loginType := optStrArg(args, "login_type") + privs, err := parsePrivs(optStrArg(args, "privs")) + if err != nil { + return "Error: " + err.Error(), true + } + if len(privs) == 0 { + privs = []PrivType{PrivView} + } + v := NewValidator(ctx, 0) + url, err := v.InviteUser(email, loginType, linkObj, linkObjID, privs) + if err != nil { + return fmt.Sprintf("Error: %v", err), true + } + return fmt.Sprintf( + "Invited %s — share link: %s\n Object: %s #%d, privs: %s", + email, url, linkObj, linkObjID, privsString(privs)), false +} diff --git a/plugins/corezoid/mcp-server/mcp_handlers_access_test.go b/plugins/corezoid/mcp-server/mcp_handlers_access_test.go new file mode 100644 index 0000000..a29ee14 --- /dev/null +++ b/plugins/corezoid/mcp-server/mcp_handlers_access_test.go @@ -0,0 +1,190 @@ +package main + +import ( + "strings" + "testing" +) + +// ---- privsExplicitNone ----------------------------------------------------- + +func TestPrivsExplicitNone(t *testing.T) { + cases := []struct { + in string + want bool + }{ + {"", false}, + {" ", false}, + {"none", true}, + {"NONE", true}, + {" none ", true}, + {"[]", true}, + {"revoke", true}, + {"unshare", true}, + {"view", false}, + {"all", false}, + {"view,modify", false}, + } + for _, c := range cases { + if got := privsExplicitNone(c.in); got != c.want { + t.Errorf("privsExplicitNone(%q) = %v, want %v", c.in, got, c.want) + } + } +} + +// ---- parsePrivs ------------------------------------------------------------ + +func TestParsePrivs_Empty(t *testing.T) { + out, err := parsePrivs("") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if out != nil { + t.Errorf("expected nil for empty input, got %v", out) + } +} + +func TestParsePrivs_All(t *testing.T) { + out, err := parsePrivs("all") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if len(out) != len(AllPrivs) { + t.Errorf("expected full priv bundle, got %v", out) + } +} + +func TestParsePrivs_CommaSeparated(t *testing.T) { + out, err := parsePrivs("view, modify") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if len(out) != 2 || out[0] != PrivView || out[1] != PrivModify { + t.Errorf("unexpected result: %v", out) + } +} + +func TestParsePrivs_JSONArray(t *testing.T) { + out, err := parsePrivs(`["view","create","delete"]`) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if len(out) != 3 { + t.Fatalf("expected 3 privs, got %d", len(out)) + } + if out[0] != PrivView || out[1] != PrivCreate || out[2] != PrivDelete { + t.Errorf("unexpected ordering: %v", out) + } +} + +func TestParsePrivs_JSONArrayInvalid(t *testing.T) { + _, err := parsePrivs(`[not json`) + if err == nil { + t.Error("expected error for invalid JSON") + } +} + +func TestParsePrivs_UnknownPriv(t *testing.T) { + _, err := parsePrivs("view,wild") + if err == nil { + t.Error("expected error for unknown priv") + } +} + +func TestParsePrivs_CaseInsensitive(t *testing.T) { + out, err := parsePrivs("VIEW,Modify") + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + if len(out) != 2 || out[0] != PrivView || out[1] != PrivModify { + t.Errorf("unexpected result: %v", out) + } +} + +func TestParsePrivs_AllInJSONArray(t *testing.T) { + out, err := parsePrivs(`["view","all"]`) + if err != nil { + t.Fatalf("unexpected error: %v", err) + } + // "all" wins and replaces accumulated tokens. + if len(out) != len(AllPrivs) { + t.Errorf("expected full bundle when 'all' appears, got %v", out) + } +} + +// ---- privsString ----------------------------------------------------------- + +func TestPrivsString(t *testing.T) { + if got := privsString(nil); got != "" { + t.Errorf("expected empty for nil, got %q", got) + } + got := privsString([]PrivType{PrivView, PrivModify}) + if got != "view,modify" { + t.Errorf("expected \"view,modify\", got %q", got) + } +} + +// ---- truncate -------------------------------------------------------------- + +func TestTruncate(t *testing.T) { + cases := []struct { + s string + max int + want string + }{ + {"hello", 10, "hello"}, // shorter than max + {"hello", 5, "hello"}, // equal to max + {"hello world", 8, "hello w…"}, + {"abc", 1, "a"}, // max==1 uses raw slice + {"abc", 0, "abc"}, // max<=0 returns input as-is + {"abc", -3, "abc"}, // negative max returns input + {"", 5, ""}, + } + for _, c := range cases { + if got := truncate(c.s, c.max); got != c.want { + t.Errorf("truncate(%q, %d) = %q, want %q", c.s, c.max, got, c.want) + } + } +} + +// ---- formatItemPrivs ------------------------------------------------------- + +func TestFormatItemPrivs(t *testing.T) { + item := map[string]any{ + "privs": []any{ + map[string]any{"type": "view"}, + map[string]any{"type": "modify"}, + }, + } + if got := formatItemPrivs(item); got != "view,modify" { + t.Errorf("expected \"view,modify\", got %q", got) + } +} + +func TestFormatItemPrivs_EmptyOrMissing(t *testing.T) { + if got := formatItemPrivs(map[string]any{}); got != "" { + t.Errorf("expected empty for missing field, got %q", got) + } + // Field present but wrong type. + if got := formatItemPrivs(map[string]any{"privs": "view"}); got != "" { + t.Errorf("expected empty for non-slice privs, got %q", got) + } +} + +func TestFormatItemPrivs_SkipsBadEntries(t *testing.T) { + item := map[string]any{ + "privs": []any{ + map[string]any{"type": "view"}, + "not-a-map", + map[string]any{}, // missing type + map[string]any{"type": "delete"}, + }, + } + got := formatItemPrivs(item) + // Only entries with a non-empty type field contribute. + if !strings.Contains(got, "view") || !strings.Contains(got, "delete") { + t.Errorf("expected view and delete, got %q", got) + } + if parts := strings.Split(got, ","); len(parts) != 2 { + t.Errorf("expected 2 entries, got %q", got) + } +} diff --git a/plugins/corezoid/mcp-server/mcp_handlers_helpers_test.go b/plugins/corezoid/mcp-server/mcp_handlers_helpers_test.go new file mode 100644 index 0000000..b1ee7ea --- /dev/null +++ b/plugins/corezoid/mcp-server/mcp_handlers_helpers_test.go @@ -0,0 +1,303 @@ +package main + +import ( + "context" + "strings" + "testing" +) + +// ---- argInt (dashboard handler helper) ------------------------------------- + +func TestArgInt_Float64(t *testing.T) { + v, ok := argInt(map[string]interface{}{"n": float64(7)}, "n") + if !ok || v != 7 { + t.Errorf("got (%d, %v), want (7, true)", v, ok) + } +} + +func TestArgInt_StringNumeric(t *testing.T) { + v, ok := argInt(map[string]interface{}{"n": "123"}, "n") + if !ok || v != 123 { + t.Errorf("got (%d, %v), want (123, true)", v, ok) + } +} + +func TestArgInt_StringInvalid(t *testing.T) { + _, ok := argInt(map[string]interface{}{"n": "not-a-number"}, "n") + if ok { + t.Error("expected ok=false for non-numeric string") + } +} + +func TestArgInt_Missing(t *testing.T) { + _, ok := argInt(map[string]interface{}{}, "n") + if ok { + t.Error("expected ok=false for missing key") + } +} + +func TestArgInt_UnsupportedType(t *testing.T) { + _, ok := argInt(map[string]interface{}{"n": []int{1}}, "n") + if ok { + t.Error("expected ok=false for unsupported type") + } +} + +// ---- extractProcessIDFromPath ---------------------------------------------- + +func TestExtractProcessIDFromPath_Standard(t *testing.T) { + id, errMsg := extractProcessIDFromPath("/some/dir/12345_my_process.conv.json") + if errMsg != "" { + t.Fatalf("unexpected error: %s", errMsg) + } + if id != 12345 { + t.Errorf("expected 12345, got %d", id) + } +} + +func TestExtractProcessIDFromPath_RelativePath(t *testing.T) { + id, errMsg := extractProcessIDFromPath("999_test.conv.json") + if errMsg != "" { + t.Fatalf("unexpected error: %s", errMsg) + } + if id != 999 { + t.Errorf("expected 999, got %d", id) + } +} + +func TestExtractProcessIDFromPath_Invalid(t *testing.T) { + _, errMsg := extractProcessIDFromPath("no-id-here.conv.json") + if errMsg == "" { + t.Error("expected error for filename without leading ID") + } + if !strings.Contains(errMsg, "no-id-here.conv.json") { + t.Errorf("expected basename in error, got: %s", errMsg) + } +} + +func TestExtractProcessIDFromPath_OnlyDigits(t *testing.T) { + // Without trailing underscore the regex does not match. + _, errMsg := extractProcessIDFromPath("12345.conv.json") + if errMsg == "" { + t.Error("expected error for filename without underscore separator") + } +} + +// ---- isInSet ---------------------------------------------------------------- + +func TestIsInSet(t *testing.T) { + set := map[string]struct{}{"a": {}, "b": {}} + if !isInSet("a", set) { + t.Error("expected 'a' to be in set") + } + if isInSet("c", set) { + t.Error("expected 'c' not to be in set") + } + if isInSet("a", nil) { + t.Error("expected nil set lookup to return false") + } +} + +// ---- handleToolCall: nil ctx ----------------------------------------------- + +// Coverage for the `if ctx == nil` branch — handleToolCall must not panic. +func TestHandleToolCall_NilContextDoesNotPanic(t *testing.T) { + resetGlobals(t) + defer func() { + if r := recover(); r != nil { + t.Errorf("handleToolCall panicked on nil context: %v", r) + } + }() + // Use an unknown tool so we don't accidentally hit the network. + // ensureAuth() will short-circuit first; we just verify nil ctx is tolerated. + _, _ = handleToolCall(nil, "nonexistent-tool", map[string]interface{}{}) //nolint:staticcheck +} + +// ---- toMapSlice ------------------------------------------------------------ + +func TestToMapSlice_HappyPath(t *testing.T) { + in := []interface{}{ + map[string]interface{}{"id": "a"}, + map[string]interface{}{"id": "b"}, + } + out := toMapSlice(in) + if len(out) != 2 { + t.Fatalf("expected 2 items, got %d", len(out)) + } + if out[0]["id"] != "a" || out[1]["id"] != "b" { + t.Errorf("unexpected items: %v", out) + } +} + +func TestToMapSlice_NonMapEntriesSkipped(t *testing.T) { + in := []interface{}{ + map[string]interface{}{"id": "a"}, + "not-a-map", + 42, + map[string]interface{}{"id": "b"}, + } + out := toMapSlice(in) + if len(out) != 2 { + t.Errorf("expected 2 valid entries, got %d", len(out)) + } +} + +func TestToMapSlice_WrongType(t *testing.T) { + if got := toMapSlice("string"); got != nil { + t.Errorf("expected nil for non-slice input, got %v", got) + } + if got := toMapSlice(nil); got != nil { + t.Errorf("expected nil for nil input, got %v", got) + } +} + +// ---- parseProcessNodes ----------------------------------------------------- + +func TestParseProcessNodes_Basic(t *testing.T) { + raw := []interface{}{ + map[string]interface{}{ + "id": "node1", + "title": "Start", + "obj_type": float64(1), + "condition": map[string]interface{}{ + "logics": []interface{}{ + map[string]interface{}{"type": "go", "to_node_id": "node2"}, + }, + "semaphors": []interface{}{}, + }, + }, + map[string]interface{}{ + "id": "node2", + "obj_type": float64(2), + }, + } + got := parseProcessNodes(raw) + if len(got) != 2 { + t.Fatalf("expected 2 nodes, got %d", len(got)) + } + if got[0].id != "node1" || got[0].title != "Start" || got[0].objType != 1 { + t.Errorf("unexpected first node: %+v", got[0]) + } + if len(got[0].logics) != 1 { + t.Errorf("expected 1 logic, got %d", len(got[0].logics)) + } + // Missing condition map -> empty logics/sems, no panic. + if got[1].id != "node2" || got[1].objType != 2 { + t.Errorf("unexpected second node: %+v", got[1]) + } + if got[1].logics != nil { + t.Errorf("expected nil logics for node without condition, got %v", got[1].logics) + } +} + +func TestParseProcessNodes_SkipsNonMaps(t *testing.T) { + raw := []interface{}{ + "not-a-node", + 42, + map[string]interface{}{"id": "ok"}, + } + got := parseProcessNodes(raw) + if len(got) != 1 || got[0].id != "ok" { + t.Errorf("expected only valid map to be kept, got %+v", got) + } +} + +func TestParseProcessNodes_Empty(t *testing.T) { + got := parseProcessNodes(nil) + if got == nil || len(got) != 0 { + t.Errorf("expected empty slice, got %+v", got) + } +} + +// ---- FormatLintResult edge cases ------------------------------------------- + +func TestFormatLintResult_SchemaInvalid(t *testing.T) { + res := &LintResult{ + ProcessTitle: "X", + TotalNodes: 1, + SchemaValid: false, + SchemaError: "missing required field", + } + out := FormatLintResult(res) + if !strings.Contains(out, "JSON SCHEMA VALIDATION FAILED") { + t.Errorf("expected schema failure header: %s", out) + } + if !strings.Contains(out, "missing required field") { + t.Errorf("expected schema error message: %s", out) + } + if !strings.Contains(out, "Total issues: 1") { + t.Errorf("expected total count to include schema issue: %s", out) + } +} + +func TestFormatLintResult_OnlyNoopAndUnused(t *testing.T) { + res := &LintResult{ + ProcessTitle: "P", + TotalNodes: 3, + SchemaValid: true, + NoopConditions: []NoopCondition{ + {ID: "n1", Title: "Noop", Issue: "all branches go to same dest"}, + }, + UnusedSetParams: []UnusedSetParam{ + {ID: "n2", Title: "Setter", Issue: "vars never referenced"}, + }, + } + out := FormatLintResult(res) + if !strings.Contains(out, "NOOP CONDITIONS (1)") || !strings.Contains(out, "UNUSED SET_PARAM (1)") { + t.Errorf("expected both sections, got: %s", out) + } + if strings.Contains(out, "ORPHANED NODES") { + t.Errorf("did not expect orphan section, got: %s", out) + } + if !strings.Contains(out, "Total issues: 2") { + t.Errorf("expected Total issues: 2, got: %s", out) + } +} + +func TestFormatLintResult_NoIssues(t *testing.T) { + res := &LintResult{ + ProcessTitle: "Clean", + TotalNodes: 5, + SchemaValid: true, + } + out := FormatLintResult(res) + if !strings.Contains(out, "No issues found.") { + t.Errorf("expected clean output, got: %s", out) + } + if strings.Contains(out, "Total issues:") { + t.Errorf("did not expect a total-issues line when clean, got: %s", out) + } +} + +// ---- confineToWorkdir extra cases ------------------------------------------ + +func TestConfineToWorkdir_DotEqualsParent(t *testing.T) { + if _, err := confineToWorkdir(".."); err == nil { + t.Error("expected error for path \"..\"") + } +} + +func TestConfineToWorkdir_NestedEscape(t *testing.T) { + if _, err := confineToWorkdir("../etc/passwd"); err == nil { + t.Error("expected error for nested ../ traversal") + } +} + +func TestConfineToWorkdir_AllowsCleanRelative(t *testing.T) { + if _, err := confineToWorkdir("samples/foo.conv.json"); err != nil { + t.Errorf("expected ok, got: %v", err) + } +} + +func TestConfineToWorkdir_EmptyOK(t *testing.T) { + got, err := confineToWorkdir("") + if err != nil { + t.Errorf("expected nil error for empty path, got %v", err) + } + if got != "" { + t.Errorf("expected empty result, got %q", got) + } +} + +// Compile-time guard: keep context import alive for handleToolCall signature usage. +var _ = context.Background diff --git a/plugins/corezoid/mcp-server/mcp_handlers_process.go b/plugins/corezoid/mcp-server/mcp_handlers_process.go index 81e9b39..39a9e59 100644 --- a/plugins/corezoid/mcp-server/mcp_handlers_process.go +++ b/plugins/corezoid/mcp-server/mcp_handlers_process.go @@ -285,6 +285,19 @@ func handleRunTask(ctx context.Context, args map[string]interface{}) (string, bo // handleCreateProcess creates an empty process in the given local folder and // writes its skeleton JSON to disk for the user to flesh out. func handleCreateProcess(ctx context.Context, args map[string]interface{}) (string, bool) { + return createConv(ctx, args, "process") +} + +// handleCreateStateDiagram creates an empty state diagram (conv_type "state") +// in the given local folder and writes its skeleton JSON to disk. +func handleCreateStateDiagram(ctx context.Context, args map[string]interface{}) (string, bool) { + return createConv(ctx, args, "state") +} + +// createConv is the shared implementation for create-process and +// create-state-diagram. It accepts a conv_type ("process" or "state") and +// produces a .conv.json skeleton on disk inside the requested folder. +func createConv(ctx context.Context, args map[string]interface{}, convType string) (string, bool) { folderPath := resolveDirPath(args, "folder_path") processName, err := strArg(args, "process_name") if err != nil { @@ -297,9 +310,9 @@ func handleCreateProcess(ctx context.Context, args map[string]interface{}) (stri } v := NewValidator(ctx, 0) - processID := v.CreateEmptyProcess(folderID, processName, "") + processID := v.CreateEmptyConv(folderID, processName, "", convType) if processID == 0 { - return fmt.Sprintf("Error: failed to create process '%s'", processName), true + return fmt.Sprintf("Error: failed to create %s '%s'", convType, processName), true } procInfo1, err := v.ExportProcess() @@ -324,7 +337,11 @@ func handleCreateProcess(ctx context.Context, args map[string]interface{}) (stri return fmt.Sprintf("Error writing file: %v", err), true } - return fmt.Sprintf("Process '%s' created and saved to %s", processName, filePath), false + label := "Process" + if convType == "state" { + label = "State diagram" + } + return fmt.Sprintf("%s '%s' created and saved to %s", label, processName, filePath), false } // handleCreateFolder creates a new folder under the given parent, mirrors it diff --git a/plugins/corezoid/mcp-server/tools_registry.go b/plugins/corezoid/mcp-server/tools_registry.go index 6c0f2b8..9fb8a33 100644 --- a/plugins/corezoid/mcp-server/tools_registry.go +++ b/plugins/corezoid/mcp-server/tools_registry.go @@ -106,7 +106,7 @@ var toolRegistry = []mcpTool{ }, { Name: "create-process", - Description: "Create a new empty process inside a Corezoid folder.", + Description: "Create a new empty process (conv_type \"process\") inside a Corezoid folder.", InputSchema: map[string]interface{}{ "type": "object", "properties": map[string]interface{}{ @@ -122,6 +122,24 @@ var toolRegistry = []mcpTool{ "required": []string{"process_name"}, }, }, + { + Name: "create-state-diagram", + Description: "Create a new empty state diagram (conv_type \"state\") inside a Corezoid folder. Use this for status / lifecycle storage instead of create-process.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "folder_path": map[string]interface{}{ + "type": "string", + "description": "Relative path to the folder directory. Omit to use the current directory.", + }, + "process_name": map[string]interface{}{ + "type": "string", + "description": "Name for the new state diagram", + }, + }, + "required": []string{"process_name"}, + }, + }, { Name: "create-folder", Description: "Create a new folder inside a parent Corezoid folder.", @@ -455,4 +473,291 @@ var toolRegistry = []mcpTool{ "required": []string{"process_id"}, }, }, + { + Name: "share-object", + Description: "Grant or revoke access to a Corezoid object (process/folder/stage/project) for a user, API key, or group. To revoke, pass privs=\"none\" — that's the same wire operation as a share with empty privs. API keys share as obj_to=\"user\" with the api key's obj_id.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "obj": map[string]interface{}{ + "type": "string", + "description": "Object kind: conv | folder | stage | project", + }, + "obj_id": map[string]interface{}{ + "type": "integer", + "description": "Numeric ID of the object being shared", + }, + "obj_to": map[string]interface{}{ + "type": "string", + "description": "Recipient kind: user (includes API keys) | group", + }, + "obj_to_id": map[string]interface{}{ + "type": "integer", + "description": "Recipient obj_id (resolve via find-principal)", + }, + "privs": map[string]interface{}{ + "type": "string", + "description": "Comma-separated list, JSON array, or keyword. Allowed values: view, create (task management), modify, delete, all (default), none (revoke all access).", + }, + "notify": map[string]interface{}{ + "type": "boolean", + "description": "Send notification to recipient (default true). Ignored when revoking.", + }, + }, + "required": []string{"obj", "obj_id", "obj_to", "obj_to_id"}, + }, + }, + { + Name: "list-shares", + Description: "List users, API keys and groups that currently have access to a Corezoid object.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "obj": map[string]interface{}{ + "type": "string", + "description": "Object kind: conv | folder | stage | project", + }, + "obj_id": map[string]interface{}{ + "type": "integer", + "description": "Object ID", + }, + }, + "required": []string{"obj", "obj_id"}, + }, + }, + { + Name: "create-group", + Description: "Create a new user group in the current workspace. Returns the group's obj_id (use as obj_to_id when sharing).", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "title": map[string]interface{}{ + "type": "string", + "description": "Group title", + }, + "description": map[string]interface{}{ + "type": "string", + "description": "Optional group description", + }, + }, + "required": []string{"title"}, + }, + }, + { + Name: "modify-group", + Description: "Rename a user group and/or update its description. At least one of title or description must be supplied.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "group_id": map[string]interface{}{ + "type": "integer", + "description": "Group obj_id", + }, + "title": map[string]interface{}{ + "type": "string", + "description": "New group title", + }, + "description": map[string]interface{}{ + "type": "string", + "description": "New group description", + }, + }, + "required": []string{"group_id"}, + }, + }, + { + Name: "list-group-objects", + Description: "List the processes (conv objects) currently shared with a group. Used to audit group impact before destructive operations. Note: folders/stages/projects shared to the group are not retrievable via this endpoint.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "group_id": map[string]interface{}{ + "type": "integer", + "description": "Group obj_id", + }, + }, + "required": []string{"group_id"}, + }, + }, + { + Name: "delete-group", + Description: "Delete a user group. By default refuses to delete if the group still has active shares — pass force=true to override. Existing share links are revoked when the group is deleted.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "group_id": map[string]interface{}{ + "type": "integer", + "description": "Group obj_id", + }, + "force": map[string]interface{}{ + "type": "boolean", + "description": "Delete even if the group still has active shares (default false).", + }, + }, + "required": []string{"group_id"}, + }, + }, + { + Name: "add-to-group", + Description: "Add a user (or API key user) to a group.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "group_id": map[string]interface{}{ + "type": "integer", + "description": "Group obj_id", + }, + "user_id": map[string]interface{}{ + "type": "integer", + "description": "User or API-key user obj_id", + }, + }, + "required": []string{"group_id", "user_id"}, + }, + }, + { + Name: "remove-from-group", + Description: "Remove a user from a group.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "group_id": map[string]interface{}{ + "type": "integer", + "description": "Group obj_id", + }, + "user_id": map[string]interface{}{ + "type": "integer", + "description": "User or API-key user obj_id", + }, + }, + "required": []string{"group_id", "user_id"}, + }, + }, + { + Name: "list-groups", + Description: "List user groups visible in the current workspace.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "name": map[string]interface{}{ + "type": "string", + "description": "Optional substring filter on group title", + }, + }, + }, + }, + { + Name: "create-api-key", + Description: "Create a new API key in the workspace. The secret is written to ~/.corezoid/api-keys/-.json (mode 0600) and the chat output reports only the file path — the secret is never printed in agent responses.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "title": map[string]interface{}{ + "type": "string", + "description": "API key title", + }, + "description": map[string]interface{}{ + "type": "string", + "description": "Optional API key description", + }, + }, + "required": []string{"title"}, + }, + }, + { + Name: "modify-api-key", + Description: "Update title and/or description of an existing API key. Does not regenerate the secret.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "api_key_id": map[string]interface{}{ + "type": "integer", + "description": "API key obj_id", + }, + "title": map[string]interface{}{ + "type": "string", + "description": "New title", + }, + "description": map[string]interface{}{ + "type": "string", + "description": "New description", + }, + }, + "required": []string{"api_key_id"}, + }, + }, + { + Name: "delete-api-key", + Description: "Delete an API key. The secret is invalidated immediately — subsequent requests return 401. Objects owned by the key are reassigned to the workspace owner.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "api_key_id": map[string]interface{}{ + "type": "integer", + "description": "API-key user obj_id", + }, + }, + "required": []string{"api_key_id"}, + }, + }, + { + Name: "list-api-keys", + Description: "List API keys visible in the current workspace.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "name": map[string]interface{}{ + "type": "string", + "description": "Optional substring filter on key title", + }, + }, + }, + }, + { + Name: "find-principal", + Description: "Search users, groups or API keys in the workspace by substring. Returns obj_ids to pass as obj_to_id in share-object.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "name": map[string]interface{}{ + "type": "string", + "description": "Substring to match against title (omit to list all)", + }, + "kind": map[string]interface{}{ + "type": "string", + "description": "What to search: user | group | api_key | shared. Defaults to user.", + }, + }, + }, + }, + { + Name: "invite-user", + Description: "Invite an external email to the workspace AND share a process/folder/stage/project with them in one call. Returns the invite URL the recipient must open.", + InputSchema: map[string]interface{}{ + "type": "object", + "properties": map[string]interface{}{ + "email": map[string]interface{}{ + "type": "string", + "description": "Invitee email", + }, + "login_type": map[string]interface{}{ + "type": "string", + "description": "Login type: google | corezoid | phone (defaults to google)", + }, + "obj": map[string]interface{}{ + "type": "string", + "description": "Object to share: conv | folder | stage | project", + }, + "obj_id": map[string]interface{}{ + "type": "integer", + "description": "Object ID", + }, + "privs": map[string]interface{}{ + "type": "string", + "description": "Privs to grant (view, create, modify, delete, all). Defaults to view.", + }, + }, + "required": []string{"email", "obj", "obj_id"}, + }, + }, } diff --git a/plugins/corezoid/samples/state-diagrams/user-status-driver-process.conv.json b/plugins/corezoid/samples/state-diagrams/user-status-driver-process.conv.json new file mode 100644 index 0000000..f47ec2f --- /dev/null +++ b/plugins/corezoid/samples/state-diagrams/user-status-driver-process.conv.json @@ -0,0 +1 @@ +{"obj_type":1,"obj_id":1863139,"parent_id":679861,"title":"New Process","description":"","status":"active","params":[{"name":"userId","type":"string","descr":"","flags":["input"],"regex":"","regex_error_text":""}],"ref_mask":true,"conv_type":"process","scheme":{"nodes":[{"id":"6a29170fb677ac777054bfb8","obj_type":0,"condition":{"logics":[{"type":"set_param","extra":{"user":"{{conv[1863140].ref[{{userId}}].status}}"},"extra_type":{"user":"string"},"err_node_id":"6a29170fb677ac777054bfb9"},{"type":"go","to_node_id":"6a291731e552e8da3d5545b0"}],"semaphors":[]},"title":"","description":"","x":780,"y":196,"uuid":"187c6540-9a5b-4480-a00e-5297493b64e5","extra":"{\"modeForm\":\"expand\",\"icon\":\"\"}","options":null},{"id":"6a2917b0e552e8da3d5573dc","obj_type":0,"condition":{"logics":[{"type":"api_copy","conv_id":1863140,"ref":"{{userId}}","mode":"modify","is_sync":true,"group":"","data":{"status":"active"},"data_type":{"status":"string"},"err_node_id":"6a2917b0e552e8da3d5573e1","user_id":78545},{"type":"go","to_node_id":"6a291756b677ac777054cbda"}],"semaphors":[]},"title":"","description":"","x":480,"y":476,"uuid":"2084d1b9-3ed3-485b-b259-247bc0e1314b","extra":"{\"modeForm\":\"expand\",\"icon\":\"\"}","options":null},{"id":"6a291731e552e8da3d5545b0","obj_type":0,"condition":{"logics":[{"type":"go_if_const","to_node_id":"6a29173fb677ac777054c65d","conditions":[{"param":"{{user.status}}","const":"active","fun":"eq","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573dc","conditions":[{"param":"{{user.status}}","const":"inactive","fun":"eq","cast":"string"}]},{"type":"go","to_node_id":"6a291641b677ac7770545ea4"}],"semaphors":[]},"title":"","description":"","x":780,"y":408,"uuid":"092aac04-3201-4439-910e-95fd2eb76a44","extra":"{\"modeForm\":\"expand\",\"icon\":\"\"}","options":null},{"id":"6a2917b0e552e8da3d5573e1","obj_type":3,"condition":{"logics":[{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573df","conditions":[{"fun":"eq","const":"crash_api","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573df","conditions":[{"fun":"eq","const":"copy_task_timeout","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573df","conditions":[{"fun":"eq","const":"copy_task_fatal_error","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573e0","conditions":[{"fun":"eq","const":"access_denied","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573e0","conditions":[{"fun":"eq","const":"not_found_task","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go_if_const","to_node_id":"6a2917b0e552e8da3d5573df","conditions":[{"fun":"eq","const":"duplicate_callback","param":"__conveyor_copy_task_return_type_tag__","cast":"string"}]},{"type":"go","to_node_id":"6a2917b0e552e8da3d5573e0"}],"semaphors":[]},"title":"","description":"","x":728,"y":572,"uuid":"789d4bd7-ff70-47dc-9123-7307e6cbd31c","extra":"{\"modeForm\":\"collapse\",\"icon\":\"\"}","options":null},{"id":"6a2917b0e552e8da3d5573e0","obj_type":2,"condition":{"logics":[],"semaphors":[]},"title":"","description":"","x":864,"y":600,"uuid":"1021f080-81fc-4315-a748-d816e440051e","extra":"{\"modeForm\":\"collapse\",\"icon\":\"error\"}","options":null},{"id":"6a2917b0e552e8da3d5573df","obj_type":0,"condition":{"logics":[],"semaphors":[{"type":"time","value":30,"dimension":"sec","to_node_id":"6a2917b0e552e8da3d5573dc"}]},"title":"","description":"","x":728,"y":480,"uuid":"64c22824-c3cd-4586-a8c6-113f4696eb9c","extra":"{\"modeForm\":\"collapse\",\"icon\":\"\"}","options":null},{"id":"6a291756b677ac777054cbda","obj_type":2,"condition":{"logics":[],"semaphors":[]},"title":"User in active","description":"","x":328,"y":528,"uuid":"9ec3fd5e-2357-4c35-b2be-9b43d1a2fa4b","extra":"{\"modeForm\":\"collapse\",\"icon\":\"success\"}","options":null},{"id":"6a29173fb677ac777054c65d","obj_type":2,"condition":{"logics":[],"semaphors":[]},"title":"User Active","description":"","x":1152,"y":484,"uuid":"39bbe6ef-aedb-40d7-bc66-d12e162ee16a","extra":"{\"modeForm\":\"collapse\",\"icon\":\"success\"}","options":null},{"id":"6a291641b677ac7770545ea4","obj_type":2,"condition":{"logics":[],"semaphors":[]},"title":"Final","description":"","x":880,"y":628,"uuid":"acb99d1d-8fc6-47ce-9933-d1dfebc7f038","extra":"{\"modeForm\":\"collapse\",\"icon\":\"success\"}","options":"{\"save_task\":true}"},{"id":"6a291641b677ac7770545e9f","obj_type":1,"condition":{"logics":[{"type":"go","to_node_id":"6a29170fb677ac777054bfb8"}],"semaphors":[]},"title":"Start","description":"","x":880,"y":100,"uuid":"df14d0db-e552-41c1-8697-ee94659cde2e","extra":"{\"modeForm\":\"collapse\",\"icon\":\"\"}","options":null},{"id":"6a29170fb677ac777054bfb9","obj_type":2,"condition":{"logics":[],"semaphors":[]},"title":"","description":"","x":1060,"y":276,"uuid":"58fc87f4-a7f4-428f-ac42-f50827df7eed","extra":"{\"modeForm\":\"collapse\",\"icon\":\"error\"}","options":null}],"web_settings":[[],[]]},"uuid":"f509346b-84c2-42c6-97db-01eddf9e337e"} \ No newline at end of file diff --git a/plugins/corezoid/samples/state-diagrams/user-status-state-diagram.conv.json b/plugins/corezoid/samples/state-diagrams/user-status-state-diagram.conv.json new file mode 100644 index 0000000..7e359bd --- /dev/null +++ b/plugins/corezoid/samples/state-diagrams/user-status-state-diagram.conv.json @@ -0,0 +1,110 @@ +{ + "obj_type": 1, + "obj_id": 1863140, + "parent_id": 679861, + "title": "New State Diagram", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "state", + "scheme": { + "nodes": [ + { + "id": "6a29164bb677ac77705463fb", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_callback" + }, + { + "type": "go_if_const", + "to_node_id": "6a29164bb677ac77705463ff", + "conditions": [ + { + "param": "status", + "const": "active", + "fun": "eq", + "cast": "string" + } + ] + }, + { + "type": "go", + "to_node_id": "6a29164bb677ac77705463fb" + } + ], + "semaphors": [] + }, + "title": "Inactive users", + "description": "", + "x": 1108, + "y": 400, + "uuid": "9dbff1c7-eba8-487f-9220-63e3f0f65b4b", + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null + }, + { + "id": "6a29164bb677ac77705463ff", + "obj_type": 0, + "condition": { + "logics": [ + { + "type": "api_callback" + }, + { + "type": "go_if_const", + "to_node_id": "6a29164bb677ac77705463fb", + "conditions": [ + { + "param": "status", + "const": "inactive", + "fun": "eq", + "cast": "string" + } + ] + }, + { + "type": "go", + "to_node_id": "6a29164bb677ac77705463ff" + } + ], + "semaphors": [] + }, + "title": "Active users", + "description": "", + "x": 740, + "y": 400, + "uuid": "e92992aa-d65d-4b98-9088-9a7f421472f2", + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null + }, + { + "id": "6a29164bb677ac77705463f5", + "obj_type": 1, + "condition": { + "logics": [ + { + "type": "go", + "to_node_id": "6a29164bb677ac77705463ff" + } + ], + "semaphors": [] + }, + "title": "Start", + "description": "", + "x": 880, + "y": 100, + "uuid": "05db9d20-5c29-47b1-b449-1e45b699f3a1", + "extra": "{\"modeForm\":\"collapse\",\"icon\":\"\"}", + "options": null + } + ], + "web_settings": [ + [], + [] + ] + }, + "uuid": "ef790e06-a6dc-472b-bb86-4f1e52196634" +} \ No newline at end of file diff --git a/plugins/corezoid/skills/corezoid-access/SKILL.md b/plugins/corezoid/skills/corezoid-access/SKILL.md new file mode 100644 index 0000000..22a547b --- /dev/null +++ b/plugins/corezoid/skills/corezoid-access/SKILL.md @@ -0,0 +1,245 @@ +--- +name: corezoid-access +description: > + Corezoid access-control specialist. Use when the user wants to share a process, + folder, stage or project with another user / group / API key, create or delete + a user group, create or rotate an API key, invite an external user, or audit + who currently has access to a Corezoid object. Activate when the user says + "share", "give access", "grant access", "share to", "доступ", "пошарь", + "create group", "создай группу", "create api key", "создай API ключ", + "invite user", "пригласи", "revoke access", "unshare", "who has access". +--- + +# Corezoid Access Control + +You are the specialist for sharing Corezoid objects and managing principals +(users, groups, API keys) inside a workspace. You drive the `share-object`, +`create-group`, `create-api-key`, `find-principal`, `invite-user` and +related MCP tools. + +## Mental model + +Everything you share — a single process, a folder, a whole stage, or an +entire project — uses the **same** API operation: a `link` op against the +Corezoid `/api/2/json` endpoint with a `privs` payload. The MCP tools below +are thin wrappers around that one operation. + +``` +Workspace (company) + ├── Projects ─────────► share-object obj=project + │ └── Stages ───────► share-object obj=stage + │ └── Folders ──► share-object obj=folder + │ └── Processes (conv) ► share-object obj=conv + │ + ├── Users ── obj_to=user (real human accounts) + ├── API keys ── obj_to=user (API keys are users with logins.type=api) + └── Groups ── obj_to=group (bundles of users + api keys) +``` + +**Key consequence:** when you share to an API key, pass `obj_to=user` +with the key's `obj_id` — *not* `obj_to=api_key`. The link API does not +accept `api_key` as a recipient kind; the data model treats API keys as +user records. + +## Privilege model + +Four privileges, applied independently: + +| Priv | What it lets the principal do | UI label | +|----------|-----------------------------------------------------------|------------------| +| `view` | Read process/folder content and run-time data | View | +| `create` | Create new tasks in a process or new objects in a folder | Task management | +| `modify` | Edit the process / folder / stage definition | Modify | +| `delete` | Delete objects | Delete | + +In tools the `privs` argument accepts a comma-separated list (`"view,modify"`), +a JSON array (`'["view","create"]'`), or one of the keywords `"all"` / +`"none"`. Default when omitted is `"all"`. Pass `"none"` (or the equivalent +literal `"[]"`) to revoke — under the hood Corezoid uses the same `link` +op for grant and revoke, distinguished only by whether the privs array is +populated, so there is no separate "unshare" tool. + +## The standard share workflow + +The recipient is usually identified by **name**, not obj_id. Resolve first, +then share: + +``` +1. find-principal name="" kind=user|group|api_key + → returns obj_id(s) and titles +2. share-object obj= + obj_id= + obj_to= # user covers API keys + obj_to_id= + privs="view,create" # or "all" +``` + +Always confirm the match with the user when `find-principal` returns more +than one row — the wrong `obj_id` silently shares to the wrong person. + +## Common scenarios + +### Share a folder with a user (full access) + +``` +find-principal name="Andrii" +# → obj_id 78545, Andrii Chaban +share-object obj=folder obj_id=671259 obj_to=user obj_to_id=78545 privs="all" +``` + +### Share a process with a group (read-only) + +``` +find-principal name="Smart API" kind=group +# → obj_id 170464, Smart API Team +share-object obj=conv obj_id=834936 obj_to=group obj_to_id=170464 privs="view" +``` + +### Share an entire project with multiple principals + +Call `share-object` once per recipient. Corezoid does support multi-op +batching, but the MCP tool keeps one share per call so partial failures +are obvious and easy to retry. + +### Create a group, edit it, add members + +``` +create-group title="Backend Team" description="Owns the payment integration" +# → group_id=170800 +modify-group group_id=170800 title="Payments Backend" # rename +modify-group group_id=170800 description="Owns checkout flow" # update description + +find-principal name="@corezoid.com" +# → list of users; pick the user_ids you need +add-to-group group_id=170800 user_id=78545 +add-to-group group_id=170800 user_id=97636 +list-groups name="Payments" # size column shows current member count +# then share folders/processes once to the group instead of each user +``` + +### Audit a group's impact before deletion + +``` +list-group-objects group_id=170800 +# → lists every process the group has access to +``` + +Use this before `delete-group` to understand who loses what. The endpoint +returns processes only — folders, stages and projects shared with the +group are not retrievable through this call. + +### Delete a group safely + +``` +delete-group group_id=170800 +# → if any process is still shared with the group, the call refuses: +# "Refused to delete group #170800 — still has 3 active share(s): +# conv #1648675 Escalation +# conv #1839904 Deprecated +# conv #1840144 Deprecated_2 +# Re-run with force=true to delete anyway." + +delete-group group_id=170800 force=true # confirms destructive intent +``` + +Once the group is deleted, every share that referenced it is revoked +server-side — group members lose any access they inherited through the +group (this is automatic; no extra revocation calls needed). + +### Create and use an API key + +``` +create-api-key title="Integration: Salesforce sync" description="Pulls leads hourly" +# → obj_id=29299 +# login=61e566e382ba963bcb25be3 +# secret written to: ~/.corezoid/api-keys/Integration-Salesforce-sync-29299.json +# (chmod 600 JSON: title, description, obj_id, login, secret, created_at) +# ⚠ never paste the secret into chat — point the user at the file +share-object obj=conv obj_id=834936 obj_to=user obj_to_id=29299 privs="view,create" +``` + +**Secret hygiene** — the agent NEVER prints the raw secret in chat. The +secret lives in `~/.corezoid/api-keys/-.json` with +mode 0600 and the parent directory at 0700. Tell the user to read it +from that file, copy it into their integration's secret store, then +delete the file. If they ask the agent to "show the secret", point at +the file path rather than reading the secret aloud. + +### Edit an API key + +``` +modify-api-key api_key_id=29299 title="Integration: Salesforce v2" description="…" +``` + +**Gotcha** — Corezoid rejects `modify-api-key` with "User has no rights" +when the key is not a member of any group. Before renaming a freshly +created key, attach it to any group (e.g., create a host group with +`create-group` then `add-to-group`). + +### Deactivate an API key + +``` +delete-api-key api_key_id=29299 +``` + +Corezoid does not expose a non-superadmin "block/unblock" operation on +API keys. Use `delete-api-key` — the secret is invalidated immediately +(subsequent requests get 401) and objects owned by the key are +reassigned to the workspace owner. + +### Invite an external user (not yet in the workspace) + +``` +invite-user email="dev@external.com" login_type="google" + obj=folder obj_id=671259 privs="view" +# → returns invite URL the recipient must open +``` + +`login_type` is usually `google`; use `corezoid` for password-based +accounts. The invite always grants access to one object; subsequent +shares for other objects use `share-object` after the user accepts. + +### Audit who has access + +``` +list-shares obj=folder obj_id=671259 +# → table of users + groups + api keys + privs each holds +``` + +Use this before changing share state — verify expectations first. + +### Revoke access + +``` +share-object obj=conv obj_id=834936 obj_to=user obj_to_id=97636 privs=none +``` + +Same wire operation as a grant — the server distinguishes by whether +`privs` is an empty array. Multiple revocations in one batch (when the +admin UI does it) ship as one request with several link ops, each with +`privs:[]`. + +## Validation rules and pitfalls + +- **`obj_to` is `user` or `group` — never `api_key`.** API keys are users. +- **`obj_id` and `obj_to_id` are numeric.** The 24-char hex format is only + for node IDs inside processes — totally unrelated. +- **`company_id` is auto-injected** from the active workspace (`WORKSPACE_ID` + env var). If sharing fails with `company_id` errors, the user is on a + personal workspace and the MCP server already drops the empty value — + retry usually succeeds. +- **API key secrets are unrecoverable.** Surface them in the very next + message after `create-api-key`. Never log them to disk silently. +- **Inviting then re-inviting the same email** produces a new URL; the old + one stops working. Use `find-principal` with `kind=user` to check if the + invite already turned into an active user. +- **Sharing a stage gives access to every process below it.** If the user + only needs one process, share at `obj=conv` instead. + +## When NOT to use this skill + +- Creating processes / folders / variables → `corezoid-init`, `corezoid-create` +- Editing process JSON → `corezoid-edit` +- Reviewing process structure → `corezoid-review`, `corezoid-project-review` + +Hand control back to the main `corezoid` skill once access changes are done. diff --git a/plugins/corezoid/skills/corezoid-alias-manager/SKILL.md b/plugins/corezoid/skills/corezoid-alias-manager/SKILL.md new file mode 100644 index 0000000..b32b1fb --- /dev/null +++ b/plugins/corezoid/skills/corezoid-alias-manager/SKILL.md @@ -0,0 +1,407 @@ +--- +name: corezoid-alias-manager +description: > + Manages Corezoid aliases — create, list, modify, delete, link/unlink, and use aliases + in process JSON. Activate when the user mentions "alias", "short_name", "short name", + "create alias", "list aliases", "delete alias", "modify alias", "rename alias", + "unlink alias", "link alias", "get callback hash", "conv[@", or asks how to reference + a process by name instead of numeric ID. Also activate when reviewing a process that + uses numeric conv_id values and the user wants to replace them with aliases. +--- + +# Corezoid Alias Manager + +## What aliases are + +An alias is a human-readable `short_name` (e.g. `payment-service`, `send-otp`) that +maps to a process (`conv`). Aliases serve two purposes: + +1. **Process reference in JSON** — use `@alias-name` as `conv_id` instead of a numeric + process ID. This makes processes portable across environments and removes hardcoded IDs. +2. **External HTTP entry point** — each alias generates a `callback_hash` used to send + tasks to the process via the API Gateway URL. + +Alias naming rules (same as Corezoid short names): +- Only lowercase letters `[a-z]`, digits `[0-9]`, and hyphens `-` +- Must be at least 3 characters +- Must be unique within the stage +- Good: `payment-checkout`, `send-otp`, `create-user-v2` +- Bad: `MyAlias`, `PAYMENT`, `a` + +--- + +## MCP Tools + +| Tool | Purpose | +|------|---------| +| `create-alias` | Create an alias and link it to a process in one step | + +> **Note:** `list`, `modify`, `delete`, and `unlink` operations are not yet exposed as +> MCP tools. Use the direct API calls documented below to perform them. + +--- + +## Using aliases in process JSON + +Once an alias exists, replace the numeric `conv_id` with `@alias-name` in any node that +calls another process: + +### Call a Process node (`api_rpc`) +```json +{ + "type": "api_rpc", + "conv_id": "@payment-checkout", + "extra": { "amount": "{{amount}}", "currency": "{{currency}}" }, + "extra_type": { "amount": "number", "currency": "string" }, + "err_node_id": "" +} +``` + +### Copy Task node (`api_copy`) +```json +{ + "type": "api_copy", + "conv_id": "@send-notification", + "ref": "{{unique_ref}}", + "mode": "create", + "err_node_id": "" +} +``` + +### State store read in `set_param` or condition +``` +{{conv[@user-states].ref[{{task_ref}}].status}} +``` + +This reads the `status` field of the task with reference `{{task_ref}}` from the +`@user-states` state diagram process. + +--- + +## Workflow: Create an alias + +### Step 1 — Resolve the process + +Check whether the user provided a file path, process name, or process ID. +If a file path is given, the process ID is the leading number in the filename +(e.g. `1834583_My_Process.conv.json` → `process_id = 1834583`). + +If only a name is given, search locally: +```bash +find . -name "*.conv.json" | xargs grep -l '"title": "My Process"' +``` + +### Step 2 — Check if the alias already exists + +Before creating, verify the `short_name` is not taken. Call the list aliases API +(see "Workflow: List aliases" below) and scan the `short_name` fields. +If a conflict is found, suggest an alternative name to the user. + +### Step 3 — Decide the short_name + +Apply the naming rules: lowercase, hyphens, no spaces or underscores, at least 3 chars. +Suggest a name derived from the process title if the user hasn't specified one. + +### Step 4 — Create the alias + +Call MCP tool **`create-alias`** with: +- `process_path`: relative path to the `.conv.json` file +- `short_name`: the alias short name + +``` +create-alias( + process_path="./671255_develop/1834583_My_Process.conv.json", + short_name="payment-checkout" +) +``` + +The tool creates the alias, links it to the process, and returns the `alias_id`. +Requires `COREZOID_STAGE_ID` to be set in `.env`. + +### Step 5 — Update and redeploy referencing processes + +After creating the alias, replace any numeric `conv_id` references to this process +across the project with `@short-name`: + +```bash +grep -rl '"conv_id": 1834583' . --include="*.conv.json" +``` + +For each file found, replace `"conv_id": 1834583` with `"conv_id": "@payment-checkout"`. +Then for each modified file, run **`lint-process`** and on success **`push-process`**. + +> After pushing, tell the user: "Changes deployed. Please **refresh the page** in Corezoid to see the updated process." + +--- + +## Workflow: List aliases + +The MCP server does not yet expose a `list-aliases` tool. Use the Corezoid API directly. + +**Required fields:** +- `company_id` — workspace ID (from `.env` `WORKSPACE_ID`) +- `project_id` — project ID (from the `*.stage.json` file in the project root) +- `stage_id` — stage ID (from `.env` `COREZOID_STAGE_ID`) + +**API call:** +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "list", + "obj": "aliases", + "sort": "date", + "order": "desc", + "id": "", + "company_id": "", + "project_id": , + "stage_id": + }] +} +``` + +**Response fields per alias:** +| Field | Description | +|-------|-------------| +| `obj_id` | Alias numeric ID (needed for modify/delete/link) | +| `title` | Human-readable display title | +| `short_name` | The `@short-name` used in `conv_id` references | +| `description` | Optional description | +| `obj_to_id` | Process (`conv`) ID this alias points to | +| `obj_to_type` | Always `"conv"` for process aliases | +| `uuid` | Alias UUID | +| `create_time` / `change_time` | Unix timestamps | +| `project_title`, `stage_title` | Context information | + +--- + +## Workflow: Modify an alias + +To rename an alias or change its title/description (does NOT change which process it +points to — use unlink + link for that). + +**API call:** +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "modify", + "obj": "alias", + "obj_id": , + "title": "New Display Title", + "short_name": "new-short-name", + "description": "Updated description", + "company_id": "", + "project_id": , + "stage_id": + }] +} +``` + +> ⚠️ Changing `short_name` invalidates all `"conv_id": "@old-name"` references +> across every process in the project. Grep all `.conv.json` files and update them, +> then push each modified process. + +--- + +## Workflow: Repoint an alias to a different process + +Use two API calls: unlink from the current process, then link to the new one. + +### Step 1 — Unlink from current process +``` +POST {COREZOID_API_URL}/api/2/json + +{ + "ops": [{ + "type": "link", + "obj": "alias", + "link": false, + "obj_id": , + "obj_to_id": , + "obj_to_type": "conv", + "company_id": "" + }] +} +``` + +### Step 2 — Link to new process +``` +POST {COREZOID_API_URL}/api/2/json + +{ + "ops": [{ + "type": "link", + "obj": "alias", + "link": true, + "obj_id": , + "obj_to_id": , + "obj_to_type": "conv", + "company_id": "" + }] +} +``` + +--- + +## Workflow: Delete an alias + +> ⚠️ Before deleting, check all `.conv.json` files for `"conv_id": "@alias-name"` references. +> Deleting an alias breaks every process that uses it. + +**API call:** +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "delete", + "obj": "alias", + "obj_id": , + "company_id": "" + }] +} +``` + +After deletion, replace all `"conv_id": "@alias-name"` references with the numeric +process ID (or create a new alias), then push each affected process. + +--- + +## Workflow: Get callback hash (external task submission URL) + +The callback hash is used to send tasks to a process from external systems via the +API Gateway. Each alias has its own hash. + +**API call:** +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "get", + "obj": "callback_hash", + "obj_type": "alias", + "alias_id": , + "company_id": "" + }] +} +``` + +**Response:** +```json +{ "request_proc": "ok", "ops": [{ "proc": "ok", "callback_hash": "19e339a865d676db68b776f440443821c49a0e30" }] } +``` + +**External submission URL:** +``` +POST {COREZOID_APIGW_URL}/api/1/json// +Content-Type: application/json + +{ "ops": [{ "ref": "unique-task-ref", "type": "create", "obj": "task", "data": { "key": "value" } }] } +``` + +Where `COREZOID_APIGW_URL` defaults to `https://api-apigw.corezoid.com`. + +--- + +## Resolving environment values + +All API calls above require `company_id`, `project_id`, `stage_id`. Find them: + +| Value | Where to find it | +|-------|-----------------| +| `WORKSPACE_ID` (company_id) | `.env` file — `WORKSPACE_ID=...` | +| `COREZOID_STAGE_ID` (stage_id) | `.env` file — `COREZOID_STAGE_ID=...` | +| `project_id` | Read the `*.stage.json` file in the project root; field `project_id` | +| `COREZOID_API_URL` | `.env` file — `COREZOID_API_URL=...` | +| `ACCESS_TOKEN` | `~/.corezoid/credentials` or `.env` | + +If `.env` is missing, run the `corezoid-init` skill to set up the environment. + +--- + +## Two-step create (alternative manual flow) + +The `create-alias` MCP tool creates and links in a single request. If you need +finer control (create first, link later), use the two-step API flow: + +### Step 1 — Create the alias object +```json +{ + "ops": [{ + "type": "create", + "obj": "alias", + "title": "My Alias Title", + "short_name": "my-alias", + "description": "", + "company_id": "", + "project_id": , + "stage_id": + }] +} +``` +Response: `{ "obj_id": , "proc": "ok" }` + +### Step 2 — Link the alias to a process +```json +{ + "ops": [{ + "type": "link", + "obj": "alias", + "link": true, + "obj_id": , + "obj_to_id": , + "obj_to_type": "conv", + "company_id": "" + }] +} +``` + +--- + +## Common pitfalls + +| Mistake | Correct approach | +|---------|-----------------| +| `"conv_id": "@My-Alias"` (uppercase) | `"conv_id": "@my-alias"` — always lowercase | +| Deleting an alias without updating referencing processes | Search all `.conv.json` first with `grep -r "@alias-name"` | +| Renaming `short_name` without updating process JSON | Same — grep, replace, push each changed process | +| Creating an alias with `short_name` that already exists | Use `list aliases` API call first to check | +| Forgetting to push processes after replacing numeric IDs with aliases | Always `lint-process` then `push-process` for every modified file | +| Using alias without `COREZOID_STAGE_ID` set | Run `corezoid-init` or set `COREZOID_STAGE_ID` in `.env` | + +--- + +## Decision guide + +| Situation | Action | +|-----------|--------| +| Process has numeric `conv_id` references from other processes | Create alias, then replace all numeric IDs | +| Setting up a new process that others will call | Create alias at creation time, use `@alias` from the start | +| Want to swap which process an alias points to (blue/green deploy) | Unlink + Link (keep the `short_name`, update the target) | +| Decommissioning a process | Check alias references, delete alias, update or deprecate callers | +| External system needs to send tasks to a process | Get callback hash for the alias, build API Gateway URL | +| Reviewing a process for hardcoded numeric `conv_id` | Flag each one, suggest alias creation and replacement | + +--- + +## Reference Documents + +| Path | When to read | +|------|-------------| +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/call-process-node.md` | `api_rpc` node — where `conv_id: "@alias"` is used | +| `${CLAUDE_PLUGIN_ROOT}/docs/node-structures.md` | JSON schemas for `api_rpc` and `api_copy` (both use `conv_id`) | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/set-parameters-dynamic-values.md` | `{{conv[@alias].ref[...].field}}` state store read pattern | +| `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md` | Variable naming rules (same convention as alias short names) | +| `${CLAUDE_PLUGIN_ROOT}/skills/corezoid-review/SKILL.md` | Step 10: External Dependencies — alias audit and creation | diff --git a/plugins/corezoid/skills/corezoid-create/SKILL.md b/plugins/corezoid/skills/corezoid-create/SKILL.md index 9067bfa..cf593a8 100644 --- a/plugins/corezoid/skills/corezoid-create/SKILL.md +++ b/plugins/corezoid/skills/corezoid-create/SKILL.md @@ -110,7 +110,7 @@ Produce a valid `.conv.json` file. - Connect nodes only through the `go` field - Every node that can fail must have `err_node_id` pointing to a dedicated error node - All constants (URLs, tokens, IDs) must be Corezoid variables — never hardcoded: - 1. Check for existing variables: read `_ENV_VARS_.json` in the project folder + 1. Check for existing variables: read `_ENV_VARS_.json` (from `pull-folder`) or `.processes/variables.json` (from this session) 2. Create a new variable if needed: call MCP tool **`create-variable`** with `name`, `description`, `value` 3. Reference in logic: `{{env_var[@variable-name]}}` - Use descriptive `title` values (e.g., "Call Payment Process", not "RPC") diff --git a/plugins/corezoid/skills/corezoid-edit/SKILL.md b/plugins/corezoid/skills/corezoid-edit/SKILL.md index 141ab86..6e93342 100644 --- a/plugins/corezoid/skills/corezoid-edit/SKILL.md +++ b/plugins/corezoid/skills/corezoid-edit/SKILL.md @@ -54,7 +54,7 @@ Apply changes to `PROCESS_PATH`. All constants (URLs, tokens, endpoints, hosts) must be stored as variables — never hardcoded: -1. Check `_ENV_VARS_.json` for existing variables +1. Check `_ENV_VARS_.json` (from `pull-folder`) or `.processes/variables.json` (from this session) for existing variables 2. Create a new variable if needed: call MCP tool **`create-variable`** with `name`, `description`, `value` 3. Reference in logic using `{{env_var[@variable-name]}}` diff --git a/plugins/corezoid/skills/corezoid-process-optimizer/SKILL.md b/plugins/corezoid/skills/corezoid-process-optimizer/SKILL.md new file mode 100644 index 0000000..e1d794a --- /dev/null +++ b/plugins/corezoid/skills/corezoid-process-optimizer/SKILL.md @@ -0,0 +1,321 @@ +--- +name: corezoid-process-optimizer +description: > + Optimizes a Corezoid process JSON — reduces tact consumption by merging nodes, + cleans data flow, fills missing node titles, and adds resilience patterns. + Activate when the user says "optimize", "improve", "reduce tacts", "merge nodes", + "clean up process", "what can be improved", "show optimizations", or any phrase + implying they want to make a process faster, cheaper, or more readable. + Two modes: plan-only (analysis + report, no changes) and auto (plan + execute immediately). +--- + +# Corezoid Process Optimizer + +## Mode and scope detection + +Determine **mode** and **scope** from the user's phrasing before doing anything else. + +### Mode + +| User intent | Mode | +|-------------|------| +| "optimize", "apply", "fix", "improve" — action verb | **AUTO** — analyze, plan, execute | +| "show", "what can", "suggest", "check" — analysis verb | **PLAN** — analyze, report, wait | + +In PLAN mode, after presenting the report ask: +> "Apply all? Apply by group? (1 — tacts, 2 — data, 3 — naming, 4 — resilience)" + +### Scope + +The user may request a specific optimization group. Detect from keywords: + +| Keyword(s) in request | Scope — run only | +|-----------------------|------------------| +| "tacts", "tact", "state changes", "nodes", "merge" | Group 1 | +| "data", "payload", "cleanup", "garbage", "fields" | Group 2 | +| "names", "naming", "titles", "readability", "descriptions" | Group 3 | +| "resilience", "semaphors", "timeouts", "stability" | Group 4 | +| No group keyword — general request | All groups | + +If scope is a single group — run Phase 1 analysis only for that group. Skip all others entirely. +Still run `lint-process` first (its findings feed Group 1 regardless). + +Examples: +- "optimize by tacts" → AUTO + Group 1 only +- "show tact optimizations" → PLAN + Group 1 only +- "add missing semaphors" → AUTO + Group 4 only +- "optimize" → AUTO + all groups + +--- + +## Step 0 — Resolve process + +Resolve `PROCESS_PATH` before calling any tools: +1. Check if the user provided a path, name, or ID. +2. If not — ask: "Which process? Provide a file path, name, or ID." +3. If name or ID — search locally: `find . -name "*.conv.json"`. +4. Read and parse the file. +5. Call **`lint-process`** — record findings. They become Group 1 quick-wins. + +--- + +## Step 1 — Analyze + +Build a node map: `id → { title, obj_type, logics[], sems[], outgoing edges }`. + +Trace the execution graph from the Start node following `go.to_node_id` and `err_node_id` edges. + +Collect candidates for all four groups below. + +--- + +## Group 1 — Tact Reduction + +> Formula: SC = (N – 1) × T. Every node transition costs one state change. Fewer nodes = fewer tacts. + +### 1.1 Merge consecutive set_param nodes + +Detect chains A → B → C where all nodes have `type: "set_param"`, connected sequentially with no branching. + +Merge condition: all nodes share the same `err_node_id` (or all have none). +If `err_node_id` values differ — flag as candidate, do not merge automatically. + +Merge action: combine all `extra` and `extra_type` objects into the first node. Remove subsequent nodes. Reconnect routing to where the chain ended. + +Tacts saved: (chain length − 1) per task. + +--- + +### 1.2 Merge consecutive code nodes + +Detect chains of `type: "api_code"` nodes connected sequentially with no branching. + +Merge condition: all share the same `err_node_id`. +If different — flag only; note that error handling must be unified first. + +Merge action: concatenate `src` fields in order, separated by `\n// ---\n`. Keep one `err_node_id`. Remove subsequent nodes. Reconnect routing. + +Tacts saved: (chain length − 1) per task. + +--- + +### 1.3 Merge consecutive condition nodes checking the same field + +Detect chains of `type: "go_if_const"` nodes where all check the **same `arg` field**. + +Merge action: combine all `conditions[]` arrays into the first node. Each original branch keeps its own `to_node_id`. Remove subsequent condition nodes. + +Do NOT merge if conditions check different fields — different semantics, merging hurts readability. + +After merging, add a note to the plan: +> "Merged conditions on field '{{field}}'. Review combined node for readability." + +Tacts saved: (chain length − 1) per task. + +--- + +### 1.4 Replace api_rpc with api_copy when reply is unused + +Detect `api_rpc` nodes where no downstream node references any field that could only originate from the called process's reply. + +Check: scan all downstream `extra`, condition `arg`/`val`, and `src` fields for parameter names not present in the task before the call. If none found — candidate for api_copy. + +This change requires confirmation even in AUTO mode. Present: +> "Node '[title]' calls process but does not use the reply. Replace with api_copy (fire-and-forget)? [yes/no]" + +If confirmed: change `type: "api_rpc"` → `type: "api_copy"`. Switch `extra`/`extra_type` to `data`/`data_type` per the api_copy schema (see `${CLAUDE_PLUGIN_ROOT}/docs/node-structures.md`). + +--- + +### 1.5 Remove dead nodes + +Apply lint findings: +- **Orphaned nodes** — remove from `scheme.nodes`. +- **No-op conditions** — re-route the incoming edge to the single destination; remove the condition node. +- **Unused set_params** — if the node sets only unused variables, remove the node. If mixed, remove only the unused keys from `extra`/`extra_type`. + +--- + +## Group 2 — Data Cleanup + +### 2.1 Inline payload cleanup after API calls + +After each `type: "api"` node, identify response fields not referenced by any downstream node. + +Do NOT add a new cleanup node — inline the cleanup into the nearest existing downstream node: +- **code node**: prepend `delete data.;` at the top of `src`. +- **set_param node**: set_param cannot delete keys. Find the next code node and add the delete there. If no downstream code node exists — flag for the user, do not create a new node. + +--- + +### 2.2 Remove dead code inside code nodes + +Inside each `api_code` node's `src`, detect: +- `data.x = data.x` — self-assignment, remove. +- Variables declared but never read after declaration — flag for user review. +- Large commented-out blocks — flag for user review. + +--- + +## Group 3 — Readability + +Run this group when: +- User explicitly requested it, OR +- AUTO mode is active. + +**Critical nodes always get titles filled** regardless of mode: + +| Node type | Always fill `title` if empty | +|-----------|------------------------------| +| `api_code` | Yes | +| `api` | Yes | +| `api_rpc` | Yes | +| `api_copy` | Yes | +| `obj_type: 2` (End/Error) | Yes | + +### Title inference rules + +| Node type | Inference | +|-----------|-----------| +| `api` | `"[METHOD] [hostname][path]"` from the `url` field | +| `api_rpc` | `"Call @[alias]"` or `"Call [conv_id]"` | +| `api_copy` | `"Copy → @[alias]"` or `"Copy → [conv_id]"` | +| `api_code` | First meaningful line of `src` (strip `data.`, max 40 chars) | +| `set_param` | `"Set [key1], [key2], ..."` (first 3 keys) | +| `go_if_const` | `"Check [arg field]"` | +| `obj_type: 2`, icon `error` | `"Error"` | +| `obj_type: 2` | `"Final"` | + +Never overwrite an existing non-empty `title`. + +### 3.1 Fill process params array + +If `params: []` and the Start node clearly receives input (inferred from downstream references to fields never set internally) — propose a `params` array. + +Always ask for confirmation before applying — field types cannot be reliably inferred. + +--- + +## Group 4 — Resilience + +### 4.1 Add missing time semaphors + +| Node type | Severity | Default timeout | +|-----------|----------|-----------------| +| `api_callback` (Waiting for Callback) | 🔴 Critical — always add | 3600 sec | +| `api` (API Call) | 🟡 Important — add without asking | 30 sec | +| `api_rpc` (Call a Process) | 🟢 Recommended — add without asking | 60 sec | + +Semaphor `to_node_id` must point to a valid error node. +If no suitable error node exists — create one at `x + 300`, same `y` as the parent node. +Use `obj_type: 2` with `title: "Timeout"` and connect the semaphor to it. + +Semaphor JSON: +```json +{ + "type": "time", + "value": 30, + "dimension": "sec", + "to_node_id": "" +} +``` + +--- + +## Step 2 — Plan report + +Present findings in this format before executing anything: + +``` +## Optimization Plan: () + +### Group 1 — Tact Reduction +| # | Type | Nodes | Tacts saved | +|---|--------------------|---------------------------------------|-------------| +| 1 | Merge set_param | "Set ref" → "Set amount" → "Set cur" | 2/task | +| 2 | Merge code | "Parse" → "Validate" | 1/task | +| 3 | Remove orphaned | "Old handler" (abc123) | 1/task | +| 4 | rpc→copy ⚠️ confirm | "Send notification" | wait saved | + +Total nodes removed: N | Tacts saved: X/task + +### Group 2 — Data Cleanup +| # | After node | Fields to remove | Inline into | +|---|---------------------|---------------------------|----------------------| +| 1 | "Call Stripe API" | payment_method_details... | "Parse response" | + +### Group 3 — Readability +| # | Node (id) | Suggested title | +|---|----------------|----------------------------------------| +| 1 | api (abc123) | "POST api.stripe.com/v1/charges" | +| 2 | api_rpc (def) | "Call @payment-process" | + +### Group 4 — Resilience +| # | Node | Issue | Action | +|---|-------------------------|-------------------------------|--------------------| +| 1 | "Call SMS API" | Missing timeout semaphor | Add 30sec | +| 2 | "Wait callback" 🔴 | Missing timeout semaphor | Add 3600sec | + +### Requires action outside this process +- Hardcoded URL in "Call Stripe API" → use /corezoid-variable-manager +- Numeric conv_id 1307813 (×3 nodes) → use /corezoid-alias-manager +``` + +--- + +## Step 3 — Execute + +### Execution order + +Always apply in this sequence: +1. Group 1 — tact reduction (graph changes first) +2. Group 4 — resilience (semaphors reference the now-clean graph) +3. Group 2 — data cleanup (inline into final node set) +4. Group 3 — naming (operates on final nodes) + +### Confirmation rules + +| Change | Confirm in AUTO | Confirm in PLAN | +|--------|----------------|-----------------| +| Merge set_param / code / condition | No | Yes per group | +| api_rpc → api_copy | **Always** | **Always** | +| Add semaphors | No | Yes per group | +| Fill titles (critical nodes) | No | No | +| Fill titles (other nodes) | No | Yes per group | +| Fill `params` array | **Always** | **Always** | +| Create variable for hardcoded value | **Always** | **Always** | + +### After all changes + +1. Write updated JSON to `PROCESS_PATH`. +2. Call **`lint-process`** — fix any errors before proceeding. +3. Call **`push-process`**. +4. Notify the user: "Deployed. Please **refresh the page** in Corezoid to see the updated process." + +--- + +## Boundaries — what the optimizer does not do + +| Finding | Action | +|---------|--------| +| Hardcoded URLs / tokens | Flag + point to `/corezoid-variable-manager` | +| Numeric conv_id without alias | Flag + point to `/corezoid-alias-manager` | +| Full Markdown documentation | Point to `/corezoid-process-tech-writer` | +| Cross-process audit | Point to `/corezoid-project-review` | +| Extract subprocess (architecture) | Discuss with user + point to `/corezoid-create` | + +--- + +## Reference Documents + +| Path | When to read | +|------|-------------| +| `${CLAUDE_PLUGIN_ROOT}/docs/node-structures.md` | JSON schemas for all node types | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/set-parameters-node.md` | set_param merge rules | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/code-node.md` | Code node structure | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/api-call-node.md` | API Call semaphor configuration | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/call-process-node.md` | api_rpc vs api_copy decision | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/copy-task-node.md` | api_copy structure | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/waiting-for-callback-node.md` | api_callback critical semaphor | +| `${CLAUDE_PLUGIN_ROOT}/docs/process/error-handling.md` | Error node patterns | +| `${CLAUDE_PLUGIN_ROOT}/docs/process/node-positioning-best-practices.md` | Positioning new nodes | diff --git a/plugins/corezoid/skills/corezoid-project-review/SKILL.md b/plugins/corezoid/skills/corezoid-project-review/SKILL.md index 225c0cf..65cb6e6 100644 --- a/plugins/corezoid/skills/corezoid-project-review/SKILL.md +++ b/plugins/corezoid/skills/corezoid-project-review/SKILL.md @@ -94,9 +94,9 @@ Flag: Aggregate only normalized `hardcode.*` findings from per-process reports. Do **not** aggregate dynamic Corezoid expressions, `dependency.state_store_ref`, or values fully wrapped in `{{...}}` as shared hardcodes. -- Same URL in > 2 processes → recommend shared `env_var` +- Same URL in > 2 processes → recommend shared `env_var` (use `/corezoid-variable-manager` to create) - Same numeric `conv_id` in > 1 process → one alias fix resolves all -- Same token/key fragment in > 1 process → security risk, centralize immediately +- Same token/key fragment in > 1 process → security risk, centralize immediately via `/corezoid-variable-manager` as `secret` variable - Same status string in > 2 processes → recommend shared constant or `env_var` - Same error text in > 1 process → recommend shared text constant @@ -112,6 +112,9 @@ Flag: - Alias defined in one process but used with numeric `conv_id` in another → inconsistency - Aliases referenced in processes but absent from project inventory → undocumented external dependency +To fix alias issues found here (create missing aliases, rename, repoint, delete conflicts), +use the `/corezoid-alias-manager` skill. + ### Step 2.5: Naming Consistency Flag: @@ -251,7 +254,7 @@ Cross-process finding example: | 0.1 List processes | `list folder filter:"conveyor" obj_id:` | | 1 Pull process | `pull-process process_id:` | | 1 Lint process | `lint-process process_path:` | -| 2.1 Resolve alias | `show conv` with alias | +| 2.1 List & resolve aliases | `/corezoid-alias-manager` → "Workflow: List aliases" | --- diff --git a/plugins/corezoid/skills/corezoid-review/SKILL.md b/plugins/corezoid/skills/corezoid-review/SKILL.md index cdb0665..f5e2d59 100644 --- a/plugins/corezoid/skills/corezoid-review/SKILL.md +++ b/plugins/corezoid/skills/corezoid-review/SKILL.md @@ -66,7 +66,7 @@ cond_nodes = [n for n in nodes for lg in n['condition']['logics'] if lg['type'] ## Step 3: Hardcode Check - **`code` nodes** — look for hardcoded IDs, URLs, tokens -- **`api` nodes** — check URLs; must use `{{env_var_name}}` or `{{variable}}`, not literals +- **`api` nodes** — check URLs; must use `{{env_var[@name]}}`, not literals - **`api_rpc` / `api_copy`** — check `conv_id` values; numeric IDs instead of `@alias` are a flag - **`api_rpc` extra fields** — check for hardcoded values that should be variables @@ -176,10 +176,7 @@ Scan all nodes and collect every outbound reference: 3. **State reads** — `conv[@alias]` references inside `set_param` extra values or condition parameters Flag: -- ⚠️ Numeric `conv_id` without `@alias` — suggest creating an alias: - 1. Derive `short_name`: lowercase, spaces/underscores → hyphens, strip special chars - 2. Call MCP tool **`create-alias`** with `process_path` and `short_name` - 3. Include suggested alias names in the report for team approval before applying +- ⚠️ Numeric `conv_id` without `@alias` — flag in the report; suggest a `short_name` derived from the process title (lowercase, hyphens). Do **not** call `create-alias` automatically — only create aliases when the user explicitly requests it. - ⚠️ Same alias called with both create and modify modes - ⚠️ More than 5 unique dependencies — note coupling risk - ⚠️ `conv[@alias]` state reads — implicit dependencies that break if the referenced process changes schema diff --git a/plugins/corezoid/skills/corezoid-state-diagram-create/SKILL.md b/plugins/corezoid/skills/corezoid-state-diagram-create/SKILL.md new file mode 100644 index 0000000..3eefd1f --- /dev/null +++ b/plugins/corezoid/skills/corezoid-state-diagram-create/SKILL.md @@ -0,0 +1,227 @@ +--- +name: corezoid-state-diagram-create +description: > + Corezoid state diagram creation specialist. Use when the user wants to create + a new Corezoid state diagram, build a state machine, design a status / lifecycle + store, or set up a "state" object with conv_type "state". Activate when the + user says "create a state diagram", "build a state machine", "new state diagram", + "design states", "track status", "user lifecycle", "состояния", "стейт диаграмма", + "создать state diagram", or mentions storing state-by-ref between processes. +--- + +# Create a New Corezoid State Diagram + +You are a specialist in creating Corezoid **state diagrams** (`conv_type: "state"`) using the `corezoid` MCP server. + +A state diagram is a long-lived data store: each task is one entity's state, referenced by a stable `ref`. Other processes read, create, and modify these state tasks. The state diagram itself only contains states (parked tasks), transitions between them, and a tiny subset of helper nodes. + +Before you start, make sure you understand: +- A state diagram has `conv_type: "state"` at the root (not `"process"`). +- Only 10 node types are allowed: Start, Condition, Code, Set Parameters, Copy Task, Modify Task, Set State (= a state node), Delay, Queue, End: Success, End: Error. +- API Call, Call a Process, Reply to Process, DB Call, Git Call, Sum, API Form are **forbidden** inside a state diagram — they belong in the driver process. + +Read `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-overview.md` if you need a refresher on the model. + +--- + +## Step 1: Gather Requirements + +Ask the user for the following before proceeding: + +- **What entity is being tracked?** (user, order, device, subscription, account, …) +- **What is the `ref`?** — the stable identifier (e.g. `userId`, `orderId`). This is the lookup key every reader and writer will use. +- **List the states.** A name and a one-line description for each (e.g. `Pending`, `Active`, `Suspended`, `Closed`). +- **List the transitions.** For every state, what data change causes it to move to which other state? (e.g. `Active → Suspended when status == "suspended"`). +- **Initial state.** Which state does a newly created task enter first? +- **Terminal states.** Which states are "End: Success" / "End: Error", if any? +- **Side effects on entry / exit (optional).** Should entering a state trigger a notification, stamp a timestamp, etc.? (These are Copy Task / Modify Task nodes between states.) + +If any of the above is missing, ask the user before continuing. + +--- + +## Step 2: Create the Empty State Diagram + +Call MCP tool **`create-state-diagram`** with: +- `folder_path`: Relative path to the folder directory. Omit to use the current directory. +- `process_name`: the state diagram name. + +This creates an empty state diagram in Corezoid with `conv_type: "state"` and writes its skeleton JSON to `_.conv.json` inside `folder_path`. The returned file path is `PROCESS_PATH` — all subsequent steps use it. + +> ⚠️ Always verify `folder_path` points to the intended target folder. Omitting it places the diagram in the project root, which may not be the correct location. + +> ⚠️ Open the new file and confirm `"conv_type": "state"` at the root before doing anything else. The push pipeline now accepts both `"process"` and `"state"`, but if `conv_type` is accidentally `"process"`, the next push will redeploy it as a regular process. + +**Already exists in Corezoid?** If the user pre-created the diagram in the Corezoid UI, pull it instead: call MCP tool **`pull-process`** with `process_id: `. `pull-process` works for both processes and state diagrams — the resulting file preserves `conv_type: "state"`. + +--- + +## Step 3: Design the State Diagram Structure + +A state diagram is structured as: + +| # | Node | obj_type | Purpose | +|---|------|----------|---------| +| 1 | Start | 1 | Entry — routes a newly-created task to its initial state | +| 2 | _(optional)_ Set Parameters / Code | 0 | Compute / normalise data on entry | +| 3 | One state node per state | 0 (logic begins with `api_callback`) | Park the task until externally modified | +| 4 | _(optional)_ Copy Task / Modify Task between states | 0 | Side effects on transition | +| 5 | _(optional)_ Delay node | 0 | Time-bounded states (e.g. trial expiry) | +| 6 | End: Success | 2 | Terminal state for "happy" closure | +| 7 | End: Error | 2 | Terminal state for failure closure | + +### State node anatomy (memorise this shape) + +```json +{ + "id": "<24-hex>", + "obj_type": 0, + "condition": { + "logics": [ + { "type": "api_callback" }, + { + "type": "go_if_const", + "to_node_id": "", + "conditions": [ + { "param": "status", "const": "blocked", "fun": "eq", "cast": "string" } + ] + }, + { "type": "go", "to_node_id": "" } + ], + "semaphors": [] + }, + "title": "Active", + "x": 880, "y": 400, + "extra": "{\"modeForm\":\"expand\",\"icon\":\"state\"}", + "options": null +} +``` + +Key invariants for every state node: +- **First logic is `api_callback`** (with no other fields). This is what "parks" the task. +- One `go_if_const` per outbound transition. Order matters — first match wins. +- **Last logic is `go` pointing back to the node's own id** (the "stay here" fallback). +- `extra` must include `"icon":"state"` so the UI renders the state pill correctly. +- Do not add `err_node_id` — `api_callback` does not surface the regular error path. + +--- + +## Step 4: Generate the State Diagram JSON + +Produce a valid `.conv.json` file with the following root envelope: + +```json +{ + "obj_type": 1, + "obj_id": , + "parent_id": , + "title": "", + "description": "", + "status": "active", + "params": [], + "ref_mask": true, + "conv_type": "state", + "scheme": { + "nodes": [], + "web_settings": [[], []] + } +} +``` + +### Core rules + +- `conv_type` **must** be `"state"`. +- Node IDs are 24-character hex: `^[0-9a-f]{24}$`. Generate with `crypto.randomBytes(12).toString('hex')` or any equivalent. +- Connect nodes only through the `go` / `go_if_const` `to_node_id` fields. +- Every node that uses logic with `err_node_id` (Code, Set Parameters, Copy Task, Modify Task, Queue) must point at a dedicated End: Error node. +- Use descriptive node `title` values — they are the state names visible on the canvas and in dashboards. +- Layout: spread states **horizontally** (different `x` per state), keep the Start above them. State nodes sit around `y ≈ 400`, Start at `y = 100`. Increment `x` by ≈ 320–400 between adjacent states. Place End nodes at the bottom (`y ≈ 700–900`). + +### Allowed logics inside a state diagram + +| Node | Logic `type` | Notes | +|---|---|---| +| Start | `go` (`obj_type: 1`) | Exactly one per diagram | +| State (Set State) | `api_callback` + `go_if_const`s + self-`go` | The structural heart of the diagram | +| Condition | `go_if_const` | For pre-state routing | +| Code | `api_code` | Avoid unless necessary; prefer `set_param` | +| Set Parameters | `set_param` | Compute / stamp fields | +| Copy Task | `api_copy` with `mode: "create"` | Fan out to another process (notifications, audit) — **not** to write back to this same diagram | +| Modify Task | `api_copy` with `mode: "modify"` | Update a task by `ref` in some target process — note: in-place edits to the current task should use `set_param` instead | +| Delay | semaphor-only | Time-bounded states | +| Queue | `api_queue` | Ordered / throttled processing | +| End | (`obj_type: 2`) | Terminal node (success or error icon) | + +### Variables for constants + +If a node references an external id (e.g. another process to notify), store it as a Corezoid variable and reference it as `{{env_var[@variable-name]}}` — never hardcode. Use **`create-variable`** if the variable does not yet exist. See `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md`. + +### Common pitfalls + +- Forgetting `"icon":"state"` in `extra` for a state node — the node renders as a plain logic node. +- Missing the trailing self-loop `go` on a state node — the task escapes the state on every callback. +- Putting an API Call, Call a Process, or Reply to Process node in a state diagram — these are **forbidden**. Move them into the driver process. +- Using `api_copy mode: "modify"` from inside the state diagram targeting its own ref — that creates an infinite re-callback loop. Use `set_param` to update the current task in place instead. +- Raw JSON objects as `extra` / `data` values — must be stringified (`"{\"k\":\"v\"}"`). + +--- + +## Step 5: Validate with Lint + +Call MCP tool **`lint-process`** with `process_path: ""`. + +Fix every reported error and re-run until the output is clean. Do not proceed with lint errors. + +> If the linter complains about a forbidden logic (`api`, `api_rpc`, `api_rpc_reply`, `db_call`, `git_call`, `api_sum`, `api_form`), remove the node and re-design the side effect to live in the driver process. + +--- + +## Step 6: Deploy + +Call MCP tool **`push-process`** with `process_path: ""`. + +If the push fails: +- Re-read the file and confirm `"conv_type": "state"` is present at the root. +- Confirm every state node ends in `go → self`. +- Confirm only allowed logic types are present. + +After a successful push, notify the user: + +> "State diagram deployed. Refresh the Corezoid page to see the new diagram. To start using it, create the driver process that calls `api_copy mode:create` with a `ref` to add entities, and `mode:modify` to drive transitions." + +--- + +## Step 7 (optional): Build the Driver Process + +A state diagram is useless without a driver process that creates and modifies its tasks. If the user has not already built one, offer to: + +1. Hand off to `/corezoid-create` to scaffold the driver process. +2. Wire it with three node patterns: + - **Read state:** `set_param` with `{{conv[].ref[{{ref}}].}}` + - **Create state task:** `api_copy` with `conv_id: `, `ref: {{}}`, `mode: "create"`, `data: {...}` + - **Modify state task:** `api_copy` with `conv_id: `, `ref: {{}}`, `mode: "modify"`, `data: {...}` + +Read `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-process-interaction.md` for full templates. + +Recommend creating an alias (`/corezoid-alias-manager`) for the state diagram so the driver references `@user-states` instead of a numeric id. + +--- + +## Reference Documents + +| Path | When to read | +|---|---| +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-overview.md` | Concepts, allowed nodes, root structure | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-node-structures.md` | Canonical JSON for every allowed node type | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-process-interaction.md` | How driver processes read / create / modify state tasks | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/set-state-node.md` | Background on Set State (legacy `obj_type:3` form) and the `{{conv[...]}}` template | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/copy-task-node.md` | Error catalogue for `api_copy` | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/condition-node.md` | `go_if_const` reference | +| `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md` | Variables (`{{env_var[@…]}}`) | + +## Example Files + +| Path | Description | +|---|---| +| `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-state-diagram.conv.json` | Minimal two-state diagram (`Active` ⇄ `Inactive`) | +| `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-driver-process.conv.json` | Companion driver process that reads + modifies the state | diff --git a/plugins/corezoid/skills/corezoid-state-diagram-edit/SKILL.md b/plugins/corezoid/skills/corezoid-state-diagram-edit/SKILL.md new file mode 100644 index 0000000..8bf4590 --- /dev/null +++ b/plugins/corezoid/skills/corezoid-state-diagram-edit/SKILL.md @@ -0,0 +1,173 @@ +--- +name: corezoid-state-diagram-edit +description: > + Corezoid state diagram editing specialist. Use when the user wants to modify, + update, or fix an existing Corezoid state diagram — add or remove a state, change + a transition, add a side effect on transition, fix the wiring of an api_callback + state node, or rework transitions. Activate when the user says "edit a state + diagram", "add a state", "remove a state", "change transitions", "fix state + diagram", "update state machine", "поправить state diagram", "изменить состояния", + or refers to modifying a .conv.json with conv_type "state". +--- + +# Edit an Existing Corezoid State Diagram + +You are a specialist in modifying Corezoid **state diagrams** (`conv_type: "state"`) using the `corezoid` MCP server. + +A state diagram is a long-lived data store; modifying it means changing the set of states, the data conditions that drive transitions between them, or the side effects performed on transition. The driver processes that read / write the diagram are usually edited separately via `/corezoid-edit`. + +Read `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-overview.md` for a refresher on the model before editing. + +--- + +## Identify the State Diagram (MANDATORY FIRST STEP) + +**Before doing anything else**, resolve `PROCESS_PATH`: + +1. Check whether the user already provided an identifier — a file path, state diagram name, or numeric id — in the current message or conversation history. +2. If no identifier is provided, ask: + > "Please specify the state diagram — a file path (e.g. `1863140_User_Status.conv.json`), a name, or a state diagram id." + Do **not** call any MCP tools until the user provides one. +3. If the user gives a **name or id**, search the local working directory for the matching `.conv.json` using `find` / `grep`. +4. Open the file and **confirm `"conv_type": "state"`** at the root. If `conv_type` is `"process"`, this is a regular process — hand off to `/corezoid-edit` instead. +5. Once `PROCESS_PATH` is confirmed, analyze the file before changing anything. + +--- + +## Step 1: Analyze the State Diagram + +Read the file and map out: + +- The list of state nodes (every node with `obj_type: 0` whose first logic is `api_callback`). Note each state's `id`, `title`, and outbound `go_if_const` transitions. +- The Start node and which state it routes to (the initial state). +- Any helper nodes between states (Set Parameters, Code, Modify Task, Copy Task, Delay, Queue). +- Terminal nodes (`obj_type: 2`). + +> 🔍 If you see `obj_type: 3` state nodes, you are looking at the legacy state-node format. The current Corezoid format uses `obj_type: 0` with `api_callback` as the first logic. Convert old nodes to the new format only if the user explicitly asks — otherwise leave them as-is and edit in place. + +Make sure you also locate any **driver processes** that reference this state diagram (search the project for `conv[]`, `conv[@]`, and `api_copy` nodes with `conv_id: `). When editing, you may need to update those drivers too. + +--- + +## Step 2: Plan the Edit + +Categorise the change before touching JSON: + +| Change type | What to touch | +|---|---| +| Add a new state | Insert a new `obj_type: 0` state node with `api_callback` + transitions + self-loop. Wire at least one inbound transition from an existing state's `go_if_const`. | +| Remove a state | Delete the node and re-route every inbound transition that pointed to it. Search the file for `to_node_id: ""`. | +| Change a transition condition | Edit the `conditions` array of the relevant `go_if_const` in the source state. | +| Re-target a transition | Change `to_node_id` of the relevant `go_if_const`. | +| Add a side effect on transition | Insert a Modify Task / Copy Task / Set Parameters node between the source state and the target state. Update the source state's `go_if_const.to_node_id` to point at the new helper, and have the helper `go` to the original target. | +| Rename a state | Change `title` only — the `id` must stay the same to preserve drivers that reference it. | +| Add an alias | Hand off to `/corezoid-alias-manager`. | + +--- + +## Step 3: Apply Changes + +Edit `PROCESS_PATH` directly. + +### Core rules + +- Connect nodes only through `go` / `go_if_const` `to_node_id` fields. +- Every node that has `err_node_id` (Code, Set Parameters, Copy Task, Modify Task, Queue) must point at a real End: Error node — never to a state node. +- Node ids are 24-character hex: `^[0-9a-f]{24}$`. For new nodes, generate fresh ids; **never reuse** an old id, even if its node was deleted. +- Use descriptive `title` values — they are the state names visible on the canvas and dashboards. +- Layout: keep states roughly on the same `y` lane (≈ 400); increment `x` by ≈ 320–400 between adjacent states. Start at `y = 100`. End nodes at the bottom. + +### State node invariants (do not break these) + +For every state node: + +- `obj_type: 0` +- First logic is exactly `{ "type": "api_callback" }` (no extra fields) +- Every outbound transition is a `go_if_const` between the `api_callback` and the trailing `go` +- The final logic is `{ "type": "go", "to_node_id": "" }` — the "stay here" fallback +- `extra` contains `"icon":"state"` +- No `err_node_id` on `api_callback` + +If you add or modify transitions, the order matters — **first matching `go_if_const` wins**. Put more specific conditions first. + +### Allowed logics + +Only these logics may appear inside a state diagram. Adding anything else will fail validation on push. + +| Allowed | Type | +|---|---| +| Start | `go` (`obj_type: 1`) | +| State | `api_callback` + `go_if_const`s + self-`go` | +| Condition | `go_if_const` | +| Code | `api_code` | +| Set Parameters | `set_param` | +| Copy Task (fan-out) | `api_copy` with `mode: "create"` | +| Modify Task (by ref) | `api_copy` with `mode: "modify"` | +| Delay | semaphor-only | +| Queue | `api_queue` | +| End | (`obj_type: 2`) | + +**Forbidden:** `api`, `api_rpc`, `api_rpc_reply`, `db_call`, `git_call`, `api_sum`, `api_form`. If the user asks to add one of these, push back: move the side effect into the driver process and explain why. + +### Common pitfalls + +- Adding a state but forgetting to wire any inbound transition → unreachable state. +- Deleting a state but leaving a `go_if_const` somewhere with `to_node_id` pointing to the deleted id → push will fail with "unknown node". +- Reordering transitions accidentally: the **first matching `go_if_const` wins**, so order is semantically meaningful. +- Using `api_copy mode: "modify"` from inside the state diagram targeting its own ref — that re-triggers `api_callback` and can loop. Use `set_param` to update the current task in place instead. +- Forgetting to update the driver process when you rename a state and the driver compares against its name (e.g. `{{conv[…].ref[…].status}} == "Active"`). The state name is `title`; the driver compares against a stored **value**, not the title — confirm with the user which they're checking. + +--- + +## Step 4: Deploy the Changes + +**MANDATORY: Always push after any change — even if work is in-flight. Without push, the changes exist only on disk.** + +Call MCP tool **`push-process`** with `process_path: ""`. + +If push fails: +- Re-read the file and confirm `"conv_type": "state"` is still at the root (a stray editor save or auto-format may have flipped it). +- Lint with **`lint-process`** to localise the issue. +- Confirm every state node still ends in `go → self_id`. +- Confirm no forbidden logic types were introduced. + +After a successful push, notify the user: + +> "State diagram updated. Refresh the Corezoid page to see the new states / transitions. Any tasks already parked in renamed states keep their `id` references intact, but tasks parked in **deleted** states are now stranded — check the workspace before deleting a populated state." + +> ⚠️ **Live data warning:** Unlike regular processes, a state diagram usually has **live tasks parked in its states**. Deleting or restructuring a state can strand those tasks. Before deleting a state, ask the user whether they want to migrate parked tasks first (e.g. by modifying their `ref` so they transition out of the doomed state). + +--- + +## Step 5 (optional): Update Driver Processes + +If your edit changed the **observable interface** of the state diagram — added a new field that drivers should now read, renamed a field drivers compare against, or removed a state drivers used to detect — hand off to `/corezoid-edit` for each driver process that needs updating. + +To find driver processes affected by the edit, search the project: + +``` +grep -rn "conv\[\]" . +grep -rn "conv_id\": " . +grep -rn "conv\[@\]" . +``` + +--- + +## Reference Documents + +| Path | When to read | +|---|---| +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-overview.md` | Concepts, allowed nodes, root structure | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-node-structures.md` | Canonical JSON for every allowed node type | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-process-interaction.md` | How driver processes read / create / modify state tasks | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/set-state-node.md` | Background and the `{{conv[...]}}` template | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/copy-task-node.md` | Error catalogue for `api_copy` | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/condition-node.md` | `go_if_const` reference | +| `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md` | Variables (`{{env_var[@…]}}`) | + +## Example Files + +| Path | Description | +|---|---| +| `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-state-diagram.conv.json` | Minimal two-state diagram (`Active` ⇄ `Inactive`) | +| `${CLAUDE_PLUGIN_ROOT}/samples/state-diagrams/user-status-driver-process.conv.json` | Companion driver process | diff --git a/plugins/corezoid/skills/corezoid-variable-manager/SKILL.md b/plugins/corezoid/skills/corezoid-variable-manager/SKILL.md new file mode 100644 index 0000000..206a321 --- /dev/null +++ b/plugins/corezoid/skills/corezoid-variable-manager/SKILL.md @@ -0,0 +1,416 @@ +--- +name: corezoid-variable-manager +description: > + Manages Corezoid environment variables (env_var) — create, list, modify, delete, and + use variables in process JSON. Activate when the user mentions "variable", "env var", + "environment variable", "secret", "create variable", "list variables", "delete variable", + "modify variable", "env_var", "{{env_var", or asks how to store a URL, token, API key, + or any constant that should not be hardcoded in a process. Also activate when a process + references {{env_var[@name]}} and the variable does not exist yet. +--- + +# Corezoid Variable Manager + +## What variables are + +Environment variables store constants (URLs, tokens, API keys, IDs, configuration values) +that must not be hardcoded in process logic. The reference syntax `{{env_var[@name]}}` is +resolved at runtime — changing a variable value takes effect immediately without +redeploying any process. + +Variables are **stage-scoped**: shared across all processes within a stage. + +--- + +## Variable types + +### By data type + +| `data_type` | When to use | Value format | +|-------------|-------------|--------------| +| `raw` | Plain string (URL, token, ID, any scalar) | `"https://api.example.com"` | +| `json` | Structured config, multi-field config, feature flags | `{"key":"value","nested":{...}}` | + +### By visibility + +| `env_var_type` | UI display | Accessible from | Scopes | +|----------------|------------|-----------------|--------| +| `visible` | Value shown in plain text | All node types | `[{"type":"*","fields":"*"}]` | +| `secret` | Value masked, shows only fingerprint | API Call nodes only | `[{"type":"api_call","fields":"*"}]` | + +> ⚠️ **Secret variables** are designed for tokens, passwords, and API keys. They are +> never returned in plain text by the API after creation — only an MD5/SHA256 fingerprint +> is available. Use `visible` for non-sensitive configuration. + +--- + +## MCP Tools + +| Tool | Purpose | +|------|---------| +| `create-variable` | Create a `raw` + `visible` variable in one step | + +> **Note:** `list`, `modify`, `delete`, and creating `secret` or `json` variables are +> not yet exposed as MCP tools. Use the direct API calls documented below. + +--- + +## Using variables in process JSON + +Once a variable exists, reference it with `{{env_var[@short-name]}}` anywhere a value +is expected. + +### API Call node — URL field +```json +{ + "type": "api", + "url": "{{env_var[@payment-api-url]}}/charge", + "method": "POST", + "err_node_id": "" +} +``` + +### API Call node — header field +```json +{ + "type": "api", + "url": "{{env_var[@payment-api-url]}}/charge", + "method": "POST", + "extra": { "Authorization": "Bearer {{env_var[@payment-api-token]}}" }, + "extra_type": { "Authorization": "string" }, + "err_node_id": "" +} +``` + +### Set Parameters node +```json +{ + "type": "set_param", + "extra": { + "baseUrl": "{{env_var[@service-url]}}", + "token": "{{env_var[@service-token]}}" + }, + "extra_type": { + "baseUrl": "string", + "token": "string" + }, + "err_node_id": "" +} +``` + +### Call a Process node — passing variable as parameter +```json +{ + "type": "api_rpc", + "conv_id": "@target-process", + "extra": { "endpoint": "{{env_var[@service-endpoint]}}" }, + "extra_type": { "endpoint": "string" }, + "err_node_id": "" +} +``` + +### Condition node (`go_if_const`) + +Variable references work in condition expressions as both the left-hand value and the +comparison value: + +```json +{ + "type": "go_if_const", + "conditions": [ + { + "fun": "equal", + "arg": "{{env_var[@feature-flag]}}", + "val": "enabled" + } + ], + "to_node_id": "" +} +``` + +### Code node — variables must be pre-loaded via set_param +Variables are not directly accessible inside `api_code` JavaScript. First assign them +to task fields using a `set_param` node upstream, then read via `data.*` in code: +```javascript +// In set_param upstream: "apiUrl": "{{env_var[@my-api-url]}}" +var url = data.apiUrl + "/endpoint"; +``` + +--- + +## Naming rules + +- Only lowercase letters `[a-z]`, digits `[0-9]`, and hyphens `-` +- Name and description must be **at least 3 characters** +- Must be unique within the stage +- Good: `stripe-secret-key`, `payment-api-url`, `db-host-prod` +- Bad: `URL`, `TOKEN`, `x`, `My_Var` + +--- + +## Local cache files + +Two files store variable information locally. Check **both** before creating a new variable: + +| File | Created by | Contains | +|------|------------|---------| +| `_ENV_VARS_.json` | `pull-folder` (ZIP export from Corezoid) | All variables in the stage | +| `.processes/variables.json` | MCP `create-variable` tool | Only variables created in this session | + +If neither file exists, run `pull-folder` or call the list API (see below) to get the +current state. + +--- + +## Workflow: Create a visible raw variable (MCP tool) + +### Step 1 — Check if variable already exists + +Read `_ENV_VARS_.json` (or `.processes/variables.json`) and search for the `short_name`. +If found, reuse it — do not create a duplicate. + +### Step 2 — Create the variable + +Call MCP tool **`create-variable`** with: +- `stage_id`: value of `COREZOID_STAGE_ID` from `.env` +- `name`: the `short_name` (kebab-case, e.g. `stripe-api-key`) +- `description`: human-readable label (min 3 chars), used as `title` in the API +- `value`: the actual value + +``` +create-variable( + stage_id="671255", + name="payment-api-url", + description="Payment Service Base URL", + value="https://api.payments.example.com" +) +``` + +The tool creates the variable in Corezoid and appends it to `.processes/variables.json`. + +### Step 3 — Reference in process JSON + +Use `{{env_var[@payment-api-url]}}` wherever this value is needed. + +--- + +## Workflow: Create a secret variable (direct API) + +Use when storing tokens, passwords, API keys — values that must be masked in the UI. + +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "create", + "obj": "env_var", + "obj_type": 0, + "status": "active", + "data_type": "raw", + "env_var_type": "secret", + "title": "Stripe Secret Key", + "short_name": "stripe-secret-key", + "description": "", + "value": "sk_live_...", + "company_id": "", + "project_id": , + "stage_id": , + "scopes": [{"type": "api_call", "fields": "*"}] + }] +} +``` + +Response: `{ "obj_id": 2192, "proc": "ok", "fingerprints": [...] }` + +> The value is never returned after creation. Store it securely before calling this API. + +--- + +## Workflow: Create a JSON variable (direct API) + +Use when a variable holds a structured config object or array. + +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "create", + "obj": "env_var", + "obj_type": 0, + "status": "active", + "data_type": "json", + "env_var_type": "visible", + "title": "Service Config", + "short_name": "service-config", + "description": "", + "value": "{\"host\":\"db.example.com\",\"port\":5432,\"name\":\"prod\"}", + "company_id": "", + "project_id": , + "stage_id": , + "scopes": [{"type": "*", "fields": "*"}] + }] +} +``` + +> The `value` field must be a **JSON string** (the JSON content encoded as a string). +> A secret JSON variable uses `"env_var_type": "secret"` and +> `"scopes": [{"type": "api_call", "fields": "*"}]`. + +--- + +## Workflow: List variables (direct API) + +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "list", + "obj": "env_var", + "sort": "date", + "order": "asc", + "id": "", + "company_id": "", + "project_id": , + "stage_id": + }] +} +``` + +**Response fields per variable:** + +| Field | Description | +|-------|-------------| +| `obj_id` | Numeric ID (needed for modify/delete) | +| `short_name` | The `@name` used in `{{env_var[@name]}}` | +| `title` | Human-readable display label | +| `data_type` | `raw` or `json` | +| `env_var_type` | `visible` or `secret` | +| `value` | Actual value (empty for `secret` after creation) | +| `fingerprints` | MD5 + SHA256 hashes — use to detect value changes | +| `scopes` | Access scope rules | +| `create_time` / `change_time` | Unix timestamps | +| `uuid` | Variable UUID | + +--- + +## Workflow: Modify a variable (direct API) + +Modify updates all mutable fields in one call. Always send the full payload — partial +updates are not supported. + +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "modify", + "obj": "env_var", + "obj_id": , + "data_type": "raw", + "env_var_type": "visible", + "title": "Updated Display Title", + "short_name": "new-short-name", + "description": "", + "value": "new-value", + "company_id": "", + "project_id": , + "stage_id": , + "scopes": [{"type": "*", "fields": "*"}] + }] +} +``` + +> ⚠️ Changing `short_name` invalidates all `{{env_var[@old-name]}}` references across +> every process in the stage. After renaming, grep all `.conv.json` files for the old +> name and update them, then `push-process` each affected file. + +--- + +## Workflow: Delete a variable (direct API) + +> ⚠️ Before deleting, verify no process references `{{env_var[@short-name]}}`. +> `push-process` validates env_var references and will fail if the variable is missing. + +```bash +# Check which processes reference this variable +grep -r "env_var\[@variable-name\]" . --include="*.conv.json" +``` + +``` +POST {COREZOID_API_URL}/api/2/json +Authorization: Simulator {ACCESS_TOKEN} +Content-Type: application/json + +{ + "ops": [{ + "type": "delete", + "obj": "env_var", + "obj_id": , + "company_id": "", + "project_id": , + "stage_id": + }] +} +``` + +--- + +## Resolving environment values + +| Value | Where to find it | +|-------|-----------------| +| `WORKSPACE_ID` (company_id) | `.env` — `WORKSPACE_ID=...` | +| `COREZOID_STAGE_ID` (stage_id) | `.env` — `COREZOID_STAGE_ID=...` | +| `project_id` | `*.stage.json` in project root — field `project_id` | +| `COREZOID_API_URL` | `.env` — `COREZOID_API_URL=...` | +| `ACCESS_TOKEN` | `~/.corezoid/credentials` | +| `obj_id` of variable | List API response, or `_ENV_VARS_.json` | + +If `.env` is missing, run the `corezoid-init` skill. + +--- + +## Runtime behaviour + +- Variables are resolved **before** the node executes — the `{{env_var[@name]}}` token + is replaced with the live value at the moment the task reaches that node +- Updating a variable value takes effect **immediately** — no process redeploy needed +- `push-process` validates all `{{env_var[@name]}}` references: if the variable does not + exist in the stage, deployment fails with an error + +--- + +## Common pitfalls + +| Mistake | Correct approach | +|---------|-----------------| +| `{{env_var[payment-url]}}` — missing `@` | `{{env_var[@payment-url]}}` — `@` is required | +| `{{env_var[@Payment-URL]}}` — uppercase | `{{env_var[@payment-url]}}` — always lowercase | +| Storing secrets as `visible` variables | Use `env_var_type: "secret"` for tokens and passwords | +| Trying to read a `secret` variable in a Code node | Secret variables are only accessible from `api` (API Call) nodes | +| Duplicate variable creation | Always read `_ENV_VARS_.json` or call the list API first | +| Renaming `short_name` without updating process files | Grep all `.conv.json`, update references, push each changed process | +| Deleting a variable used by active processes | `push-process` will fail; remove all references first | +| Passing large JSON config as raw string | Use `data_type: json` for structured values | + +--- + +## Reference Documents + +| Path | When to read | +|------|-------------| +| `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md` | Naming rules and usage examples (quick reference) | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/set-parameters-node.md` | How `set_param` feeds variables into task data for Code nodes | +| `${CLAUDE_PLUGIN_ROOT}/docs/nodes/api-call-node.md` | How variables are used in URL, headers, and body fields | +| `${CLAUDE_PLUGIN_ROOT}/docs/process/process-json-validation.md` | How `push-process` validates `{{env_var[@name]}}` references | diff --git a/plugins/corezoid/skills/corezoid/SKILL.md b/plugins/corezoid/skills/corezoid/SKILL.md index 07108ad..d83e502 100644 --- a/plugins/corezoid/skills/corezoid/SKILL.md +++ b/plugins/corezoid/skills/corezoid/SKILL.md @@ -26,7 +26,8 @@ You have access to the Corezoid API via the `corezoid` MCP server. | `push-process` | Validate and deploy a `.conv.json` file | | `lint-process` | Validate process structure locally (no API needed) | | `run-task` | Run a task on an already-deployed process | -| `create-process` | Create a new empty process in a folder | +| `create-process` | Create a new empty process (`conv_type: "process"`) in a folder | +| `create-state-diagram` | Create a new empty state diagram (`conv_type: "state"`) in a folder | | `create-folder` | Create a new subfolder | | `create-alias` | Create a short alias for a process | | `create-variable` | Create a Corezoid environment variable | @@ -36,6 +37,18 @@ You have access to the Corezoid API via the `corezoid` MCP server. | `get-chart` | Get a single chart with its series data | | `modify-chart` | Modify an existing chart (full series required) | | `set-dashboard-layout` | Save chart positions on the grid (required to make charts visible) | +| `share-object` | Grant or revoke access on a process / folder / stage / project (use privs="none" to revoke — same wire op as share with empty privs) | +| `list-shares` | Audit who currently has access to an object | +| `create-group` / `modify-group` / `delete-group` | Manage workspace user groups (delete refuses if group has active shares unless force=true) | +| `list-group-objects` | List processes currently shared with a group (used to audit impact before delete) | +| `add-to-group` / `remove-from-group` | Manage group membership | +| `list-groups` | List groups in the workspace | +| `create-api-key` | Create an API key. Secret is written to ~/.corezoid/api-keys/.json (chmod 600) — never printed in chat | +| `modify-api-key` | Rename or re-describe an API key | +| `delete-api-key` | Delete an API key (invalidates the secret immediately) | +| `list-api-keys` | List API keys in the workspace | +| `find-principal` | Resolve user / group / API-key name → obj_id (call before share-object) | +| `invite-user` | Invite an external email AND share an object in one call | ## Platform Architecture @@ -56,6 +69,7 @@ Workspace - **Nodes** — processing units connected via `go` transitions - **Tasks** — data objects that flow through process nodes - **Variables** — workspace-scoped constants referenced as `{{env_var[@name]}}` +- **State Diagrams** — a special object (`conv_type: "state"`) that stores long-lived tasks keyed by `ref`. Other processes read with `{{conv[].ref[].}}` and write with `api_copy mode: "create"/"modify"`. Allowed node set is restricted to 10 logics (Start, Condition, Code, Set Parameters, Copy Task, Modify Task, Set State, Delay, Queue, End). Use `/corezoid-state-diagram-create` and `/corezoid-state-diagram-edit`. ## Node Types @@ -106,10 +120,15 @@ For domain-specific workflows use the specialized skills: - `/corezoid-init` — setting up environment and pulling from Corezoid - `/corezoid-create` — creating a new process from scratch - `/corezoid-edit` — modifying an existing process +- `/corezoid-state-diagram-create` — creating a new state diagram (`conv_type: "state"`) from scratch +- `/corezoid-state-diagram-edit` — modifying an existing state diagram - `/corezoid-review` — auditing and analyzing a single process - `/corezoid-project-review` — auditing an entire project or folder (cross-process analysis) - `/corezoid-dashboard-manager` — creating dashboards and charts for process metrics - `/corezoid-process-tech-writer` — documenting a process (Markdown + enriched JSON) +- `/corezoid-alias-manager` — creating, listing, modifying, deleting, and using aliases +- `/corezoid-variable-manager` — creating, listing, modifying, deleting variables (visible/secret, raw/json) +- `/corezoid-process-optimizer` — reduce tacts (merge nodes), clean data flow, fill names, add semaphors ## Reference Documents @@ -126,6 +145,9 @@ Use the `Read` tool to load these files when you need deeper detail: | `${CLAUDE_PLUGIN_ROOT}/docs/nodes/end-node.md` | End node success/error configuration | | `${CLAUDE_PLUGIN_ROOT}/docs/process/process-json-validation.md` | Validation rules and common errors | | `${CLAUDE_PLUGIN_ROOT}/docs/process/error-handling.md` | Error handling patterns | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-overview.md` | State diagram concepts and allowed nodes | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-node-structures.md` | JSON schemas for nodes inside a state diagram | +| `${CLAUDE_PLUGIN_ROOT}/docs/state-diagrams/state-diagram-process-interaction.md` | How driver processes read / create / modify state tasks | | `${CLAUDE_PLUGIN_ROOT}/docs/variables-guide.md` | Variable naming rules, creation workflow, usage examples | ## Tips diff --git a/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md b/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md index 217e891..e090d12 100644 --- a/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md +++ b/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md @@ -372,7 +372,7 @@ because private dependencies are the most common hard blocker. | 0.2 Load process inventory | `list folder filter:"conveyor" obj_id:` | | 2.1 Pull process definition | `pull-process process_id:` | | 2.2 Get system processes | `list folder filter:"system" obj_id:` | -| 2.4 Resolve state alias | `show conv with alias` | +| 2.4 Resolve state alias | `pull-process process_id:` then check `short_name` | | 3.1 Get env_var declarations | `get project_env obj_id:` | | 4–5 Scan code / api nodes | `pull-process process_id:` then filter node types | diff --git a/public/.well-known/skills/index.json b/public/.well-known/skills/index.json new file mode 100644 index 0000000..0f0eca3 --- /dev/null +++ b/public/.well-known/skills/index.json @@ -0,0 +1,67 @@ +{ + "skills": [ + { + "name": "corezoid", + "description": "Universal Corezoid assistant. Use when the user asks anything about Corezoid processes, wants to work with process JSON files, mentions process nodes, MCP tools, process validation, or any Corezoid-specific task. Also use when the user mentions \"Corezoid\", \"BPM process\", \"conv.json\", \"push process\", \"run task\", or asks for general platform knowledge. This skill provides deep knowledge of the platform model and guides you to use the Corezoid MCP tools correctly.", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid/SKILL.md" + ] + }, + { + "name": "corezoid-create", + "description": "Corezoid process creation specialist. Use when the user wants to create a new Corezoid process from scratch, build a new automation flow, design a new BPM process, or implement a new API connector. Activate when the user says \"create a process\", \"build a new flow\", \"new process\", \"design from scratch\", \"implement a connector\", \"create an automation\", or \"add a new process\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-create/SKILL.md" + ] + }, + { + "name": "corezoid-dashboard-manager", + "description": "Creates and manages Corezoid dashboards — adds charts (column, pie, funnel, table), binds metrics to process nodes, configures real-time mode, and sets up drill-down linking between dashboards. Activate whenever a user asks to create a dashboard, add a chart, visualize process metrics, set up reporting for a Corezoid process, configure real-time monitoring, or asks what dashboards or charts exist. Also activate when the user wants to show task counts, completion rates, error rates, or any other process statistics visually in Corezoid.", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-dashboard-manager/SKILL.md" + ] + }, + { + "name": "corezoid-edit", + "description": "Corezoid process editing specialist. Use when the user wants to modify, update, or fix an existing Corezoid process, add or remove nodes, change node behavior, add an API call, fix an error, or update process logic. Activate when the user says \"edit a process\", \"modify\", \"update\", \"fix\", \"add a node\", \"change behavior\", \"add a call\", \"remove a node\", or \"update the logic\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-edit/SKILL.md" + ] + }, + { + "name": "corezoid-init", + "description": "Corezoid environment setup specialist. Use when the user wants to connect to Corezoid, set up credentials, authenticate, pull a project, configure the environment, or start working with a Corezoid project for the first time. Activate when the user says \"init\", \"setup\", \"connect to corezoid\", \"login\", \"pull workspace\", \"configure environment\", or \"get started\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-init/SKILL.md" + ] + }, + { + "name": "corezoid-process-tech-writer", + "description": "Documents a Corezoid process — produces a human-readable Markdown file AND enriches the process JSON with descriptions on every node and parameter. Output is designed for team wikis, internal portals, and future product integration. Activate whenever a user asks to document a process, write docs for a connector, add descriptions to a process, create documentation for a logic, describe what a process does, or any similar phrasing. Also activate when the user shares a process JSON and asks to explain it or make it self-documenting. Always produce BOTH outputs (Markdown file + enriched JSON) — never just one.", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-process-tech-writer/SKILL.md" + ] + }, + { + "name": "corezoid-project-review", + "description": "Corezoid project review and audit specialist. Use when the user wants to review or audit an entire Corezoid project or folder — multiple processes at once. Activate when the user says \"review project\", \"audit project\", \"review all processes\", \"audit all processes\", \"review folder\", \"review all processes in\", \"project-wide review\", \"cross-process analysis\", \"find issues across processes\", \"review the whole project\", or \"audit folder\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-project-review/SKILL.md" + ] + }, + { + "name": "corezoid-review", + "description": "Corezoid process review and audit specialist. Use when the user wants to analyze, review, audit, or improve an existing Corezoid process. Activate when the user says \"review a process\", \"analyze\", \"check\", \"audit\", \"find issues\", \"explain this process\", \"what's wrong with\", \"optimize\", or \"check for hardcoded values\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-review/SKILL.md" + ] + }, + { + "name": "marketplace-publish-validation", + "description": "Corezoid marketplace pre-publication validator. Standalone skill — no external skill dependencies required. Use this skill whenever the user wants to publish, release, or submit a project or folder to the Corezoid marketplace, or asks to check if a project is ready to publish. Activate on phrases: \"publish to marketplace\", \"готово до публікації\", \"можна публікувати\", \"перевір перед публікацією\", \"validate for marketplace\", \"pre-publish check\", \"marketplace validation\", \"publication readiness\", \"check before publish\", \"submit to marketplace\", \"перевірка публікації\". Also activate when the user asks \"what's blocking publication\" or \"why can't I publish this\".", + "files": [ + "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md" + ] + } + ] +} diff --git a/public/llms.txt b/public/llms.txt new file mode 100644 index 0000000..d929a77 --- /dev/null +++ b/public/llms.txt @@ -0,0 +1,49 @@ +# Corezoid AI Plugin + +> Official Claude Code plugin for Corezoid BPM platform. Provides skills and MCP tools for creating, editing, reviewing, and managing Corezoid business processes directly from the IDE. + +## Skills + +- [corezoid](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid/SKILL.md): Universal Corezoid assistant +- [corezoid-create](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-create/SKILL.md): Corezoid process creation specialist +- [corezoid-dashboard-manager](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-dashboard-manager/SKILL.md): Creates and manages Corezoid dashboards — adds charts (column, pie, funnel, table), binds metrics to process nodes, configures real-time mode, and sets up drill-down linking between dashboards +- [corezoid-edit](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-edit/SKILL.md): Corezoid process editing specialist +- [corezoid-init](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-init/SKILL.md): Corezoid environment setup specialist +- [corezoid-process-tech-writer](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-process-tech-writer/SKILL.md): Documents a Corezoid process — produces a human-readable Markdown file AND enriches the process JSON with descriptions on every node and parameter +- [corezoid-project-review](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-project-review/SKILL.md): Corezoid project review and audit specialist +- [corezoid-review](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/corezoid-review/SKILL.md): Corezoid process review and audit specialist +- [marketplace-publish-validation](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/skills/marketplace-publish-validation/SKILL.md): Corezoid marketplace pre-publication validator + +## MCP Tools + +The plugin bundles a Go MCP server (`convctl`) with these tools: + +- **login**: Authenticate with Corezoid via OAuth2 browser flow +- **pull-process**: Export a single process definition to a local .conv.json file +- **pull-folder**: Recursively export all processes from a Corezoid folder +- **push-process**: Validate and deploy a local process file to Corezoid +- **lint-process**: Validate process structure — orphaned nodes, noop conditions, unused params +- **run-task**: Execute a task on a deployed Corezoid process +- **create-process**: Create a new empty process inside a Corezoid folder +- **create-folder**: Create a new folder inside a Corezoid folder +- **create-variable**: Create an environment variable in a Corezoid folder +- **create-dashboard**: Create a dashboard for visualizing process node metrics +- **add-chart**: Add a chart (column, pie, funnel, table) to a dashboard +- **list-workspaces**: List Corezoid workspaces available to the authenticated user +- **list-projects**: List projects inside a workspace +- **list-stages**: List stages (environments) inside a project +- **modify-task**: Modify an existing task's data +- **delete-task**: Delete a task from a process +- **logout**: Remove saved Corezoid credentials from disk + +## Documentation + +- [Node Structures](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/docs/node-structures.md): JSON schemas for all 24 Corezoid node types +- [Variables Guide](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/docs/variables-guide.md): Environment variable syntax `{{env_var[@name]}}` +- [Process Docs](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/docs/process/): Process format, validation rules, and error handling +- [Node Docs](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/plugins/corezoid/docs/nodes/): Per-node-type documentation (24 types) + +## Optional + +- [Skills Index](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/public/.well-known/skills/index.json): Machine-readable agent discovery index +- [Changelog](https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main/CHANGELOG.md): Release history diff --git a/scripts/generate-discovery.py b/scripts/generate-discovery.py new file mode 100644 index 0000000..3e5de66 --- /dev/null +++ b/scripts/generate-discovery.py @@ -0,0 +1,237 @@ +#!/usr/bin/env python3 +""" +Generate public/.well-known/skills/index.json and public/llms.txt +from plugin SKILL.md files. + +Usage: + python3 scripts/generate-discovery.py +""" + +import json +import os +import re +import sys + +ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) +SKILLS_DIR = os.path.join(ROOT, "plugins", "corezoid", "skills") +PUBLIC_DIR = os.path.join(ROOT, "public") +REPO_RAW = "https://raw.githubusercontent.com/corezoid/corezoid-ai-plugin/main" +SKILLS_RAW = f"{REPO_RAW}/plugins/corezoid/skills" +DOCS_RAW = f"{REPO_RAW}/plugins/corezoid/docs" + + +# --------------------------------------------------------------------------- +# Frontmatter parsing (no external deps) +# --------------------------------------------------------------------------- + +def _parse_description(fm): + # Folded/literal scalar (description: >\n line1\n line2) + folded = re.search(r"^description:\s*[>|]\s*\n((?:[ \t]+[^\n]*\n?)+)", fm, re.MULTILINE) + if folded: + lines = folded.group(1).splitlines() + return " ".join(ln.strip() for ln in lines if ln.strip()) + + # Double-quoted inline + dq = re.search(r'^description:\s*"(.*)"', fm, re.MULTILINE) + if dq: + return dq.group(1).replace('\\"', '"').strip() + + # Single-quoted inline + sq = re.search(r"^description:\s*'(.*)'", fm, re.MULTILINE) + if sq: + return sq.group(1).replace("''", "'").strip() + + # Plain inline + plain = re.search(r"^description:\s*(.+)$", fm, re.MULTILINE) + if plain: + return plain.group(1).strip() + + return None + + +def parse_frontmatter(path): + with open(path, encoding="utf-8") as f: + content = f.read() + + m = re.match(r"^---\n(.*?)\n---", content, re.DOTALL) + if not m: + return None + fm = m.group(1) + + name_m = re.search(r"^name:\s*(.+)$", fm, re.MULTILINE) + name = name_m.group(1).strip() if name_m else None + + return {"name": name, "description": _parse_description(fm)} + + +# --------------------------------------------------------------------------- +# Skills discovery +# --------------------------------------------------------------------------- + +def collect_skills(): + skills = [] + for entry in sorted(os.listdir(SKILLS_DIR)): + skill_path = os.path.join(SKILLS_DIR, entry) + skill_md = os.path.join(skill_path, "SKILL.md") + if not os.path.isfile(skill_md): + continue + + fm = parse_frontmatter(skill_md) + if not fm or not fm["name"] or not fm["description"]: + print(f"WARN: skipping {entry} — missing name or description", file=sys.stderr) + continue + + # List all .md files in the skill directory + md_files = [] + for root, dirs, files in os.walk(skill_path): + dirs.sort() + for fname in sorted(files): + if fname.endswith(".md"): + rel = os.path.relpath(os.path.join(root, fname), skill_path) + md_files.append(rel) + + skills.append({ + "name": fm["name"], + "description": fm["description"], + "dir": entry, + "files": md_files, + }) + return skills + + +# --------------------------------------------------------------------------- +# Generators +# --------------------------------------------------------------------------- + +def generate_index_json(skills): + return { + "skills": [ + { + "name": s["name"], + "description": s["description"], + "files": [f"{SKILLS_RAW}/{s['dir']}/{f}" for f in s["files"]], + } + for s in skills + ] + } + + +MCP_TOOLS = [ + ("login", "Authenticate with Corezoid via OAuth2 browser flow"), + ("pull-process", "Export a single process definition to a local .conv.json file"), + ("pull-folder", "Recursively export all processes from a Corezoid folder"), + ("push-process", "Validate and deploy a local process file to Corezoid"), + ("lint-process", "Validate process structure — orphaned nodes, noop conditions, unused params"), + ("run-task", "Execute a task on a deployed Corezoid process"), + ("create-process", "Create a new empty process inside a Corezoid folder"), + ("create-folder", "Create a new folder inside a Corezoid folder"), + ("create-variable", "Create an environment variable in a Corezoid folder"), + ("create-dashboard", "Create a dashboard for visualizing process node metrics"), + ("add-chart", "Add a chart (column, pie, funnel, table) to a dashboard"), + ("list-workspaces", "List Corezoid workspaces available to the authenticated user"), + ("list-projects", "List projects inside a workspace"), + ("list-stages", "List stages (environments) inside a project"), + ("modify-task", "Modify an existing task's data"), + ("delete-task", "Delete a task from a process"), + ("logout", "Remove saved Corezoid credentials from disk"), +] + + +def generate_llms_txt(skills, version): + lines = [ + "# Corezoid AI Plugin", + "", + "> Official Claude Code plugin for Corezoid BPM platform. " + "Provides skills and MCP tools for creating, editing, reviewing, " + "and managing Corezoid business processes directly from the IDE.", + "", + "## Skills", + "", + ] + + for s in skills: + url = f"{SKILLS_RAW}/{s['dir']}/SKILL.md" + # First sentence as teaser + teaser = s["description"].split(". ")[0].rstrip(".") + lines.append(f"- [{s['name']}]({url}): {teaser}") + + lines += [ + "", + "## MCP Tools", + "", + "The plugin bundles a Go MCP server (`convctl`) with these tools:", + "", + ] + + for name, desc in MCP_TOOLS: + lines.append(f"- **{name}**: {desc}") + + lines += [ + "", + "## Documentation", + "", + f"- [Node Structures]({DOCS_RAW}/node-structures.md): " + "JSON schemas for all 24 Corezoid node types", + f"- [Variables Guide]({DOCS_RAW}/variables-guide.md): " + "Environment variable syntax `{{env_var[@name]}}`", + f"- [Process Docs]({DOCS_RAW}/process/): " + "Process format, validation rules, and error handling", + f"- [Node Docs]({DOCS_RAW}/nodes/): " + "Per-node-type documentation (24 types)", + "", + "## Optional", + "", + f"- [Skills Index]({REPO_RAW}/public/.well-known/skills/index.json): " + "Machine-readable agent discovery index", + f"- [Changelog]({REPO_RAW}/CHANGELOG.md): Release history", + "", + ] + + return "\n".join(lines) + + +# --------------------------------------------------------------------------- +# Main +# --------------------------------------------------------------------------- + +def read_version(): + plugin_json = os.path.join(ROOT, "plugins", "corezoid", ".claude-plugin", "plugin.json") + try: + with open(plugin_json) as f: + return json.load(f).get("version", "unknown") + except OSError: + return "unknown" + + +def main(): + if not os.path.isdir(SKILLS_DIR): + print(f"ERROR: skills dir not found: {SKILLS_DIR}", file=sys.stderr) + sys.exit(1) + + skills = collect_skills() + if not skills: + print("ERROR: no skills found", file=sys.stderr) + sys.exit(1) + print(f"Found {len(skills)} skills: {[s['name'] for s in skills]}") + + version = read_version() + + # public/.well-known/skills/index.json + skills_out_dir = os.path.join(PUBLIC_DIR, ".well-known", "skills") + os.makedirs(skills_out_dir, exist_ok=True) + index_path = os.path.join(skills_out_dir, "index.json") + with open(index_path, "w", encoding="utf-8") as f: + json.dump(generate_index_json(skills), f, indent=2, ensure_ascii=False) + f.write("\n") + print(f"Written: {os.path.relpath(index_path, ROOT)}") + + # public/llms.txt + os.makedirs(PUBLIC_DIR, exist_ok=True) + llms_path = os.path.join(PUBLIC_DIR, "llms.txt") + with open(llms_path, "w", encoding="utf-8") as f: + f.write(generate_llms_txt(skills, version)) + print(f"Written: {os.path.relpath(llms_path, ROOT)}") + + +if __name__ == "__main__": + main()