{
  "openapi": "3.1.0",
  "info": {
    "title": "Yurbi API",
    "version": "1.0.0",
    "summary": "Developer Documentation",
    "description": "Reference for the Yurbi API — authenticate, manage users, configure apps, and refresh licenses on your own Yurbi server. JSON over HTTPS. The path prefix is `/api` on Linux/Docker and `/yurbi/api` on Windows. Authenticate with DoLogin to obtain a session token, then include it in the body of authenticated calls.",
    "contact": {
      "name": "5000fish, Inc.",
      "url": "https://developers.yurbi.com",
      "email": "support@yurbi.com"
    }
  },
  "servers": [
    {
      "url": "https://your-yurbi-server.com",
      "description": "Your Yurbi server (replace with your own host)"
    }
  ],
  "tags": [
    {
      "name": "Authentication"
    },
    {
      "name": "Users"
    },
    {
      "name": "Groups & Roles"
    },
    {
      "name": "Data Security"
    },
    {
      "name": "Apps & Servers"
    },
    {
      "name": "Library"
    },
    {
      "name": "App Builder"
    },
    {
      "name": "Reports"
    },
    {
      "name": "Email (SMTP)"
    },
    {
      "name": "Instance Settings"
    },
    {
      "name": "Licensing"
    }
  ],
  "components": {
    "securitySchemes": {
      "sessionToken": {
        "type": "apiKey",
        "in": "header",
        "name": "sessionToken",
        "description": "Session token from DoLogin. Most endpoints accept it as a body field; included here as a scheme for tooling."
      }
    }
  },
  "paths": {
    "/api/login/DoLogin": {
      "post": {
        "operationId": "do-login",
        "summary": "Log in",
        "description": "Authenticate a user and receive a session token. On success the token is in LoginSession.SessionToken and ErrorCode is 0. Invalid credentials return ErrorCode 101 with \"Login Failed - Username or Password is invalid.\" and a null session. Yurbi maintains one session per user: each successful login issues a new token and ends that user's previous session. The full response is around 200&nbsp;KB, because LoginUser.Language.phraselist carries the interface phrase table. The sample below shortens that list.",
        "tags": [
          "Authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "UserId": {
                    "type": "string",
                    "description": "The user's login name."
                  },
                  "UserPassword": {
                    "type": "string",
                    "description": "The user's PIN or password."
                  },
                  "isGuest": {
                    "type": "boolean",
                    "description": "Set true only for a guest login; otherwise false."
                  },
                  "bolForceLogin": {
                    "type": "boolean",
                    "description": "Send true. The field is required; omitting it returns ErrorCode 9000."
                  }
                },
                "required": [
                  "UserId",
                  "UserPassword",
                  "isGuest",
                  "bolForceLogin"
                ]
              },
              "example": {
                "bolForceLogin": true,
                "UserId": "admin",
                "UserPassword": "YOUR_PASSWORD",
                "isGuest": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "LoginSession": {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "SessionToken": "QK[OFHLQSDQROJQULKPJQPGXG",
                    "SessionFlag": 0,
                    "isGuestSession": false,
                    "SessionTimeLeft": 0,
                    "SessionExpir": "2026-08-27T14:33:48.4458383+00:00",
                    "Duo2FA_State": "",
                    "Duo2FA_AuthURI": null,
                    "Duo2FA_AuthStatus": null
                  },
                  "LoginUser": {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ID": "639234363032231617",
                    "LoginName": "apitest",
                    "FirstName": "API",
                    "LastName": "Test",
                    "EmailAddress": "",
                    "Company": "",
                    "twofa": "none",
                    "CreateDate": "2026-08-27T14:05:03",
                    "ModifyDate": "2026-08-27T14:05:03",
                    "LoginDate": "2026-08-27T14:05:03",
                    "Pin": null,
                    "AuthType": "PIN",
                    "isAdmin": true,
                    "isSuperAdmin": false,
                    "isBuilder": false,
                    "isAgent": false,
                    "isArchitect": true,
                    "SecurityGroups": [
                      {
                        "GroupId": "1",
                        "GroupName": "Administrators",
                        "GroupDescription": "Yurbi Admins",
                        "GroupRoles": [
                          {
                            "RoleId": "1",
                            "RoleName": "Admin"
                          }
                        ],
                        "GroupStatus": 0
                      }
                    ],
                    "ComboName": "Test, API",
                    "FullName": "API Test",
                    "UserApplications": [
                      {
                        "ApplicationID": "1001",
                        "ApplicationName": "Sample Data",
                        "ApplicationRoleID": "7",
                        "ApplicationRoleName": "Architect",
                        "ApplicationRoleType": "0",
                        "applicationUserDataSourceID": ""
                      }
                    ],
                    "Language": {
                      "id": 1,
                      "nativename": "English",
                      "englishname": "English",
                      "iso_name": "EN",
                      "phraselist": [
                        {
                          "internalname": "Login",
                          "text": "Log In",
                          "dialog": "Main"
                        }
                      ]
                    },
                    "timezone": -6,
                    "timezonename": "America/Bahia_Banderas",
                    "isFastCache": 0,
                    "FastCacheLimit": 30,
                    "bforcepasschange": false
                  },
                  "Tenant_Mode": false,
                  "ProductName": "Yurbi",
                  "ProductType": 2,
                  "ProductVersion": "12.26.08.24",
                  "LicensedFeatures": [
                    {
                      "Feature": "monthly active users",
                      "count": "100",
                      "id": "86"
                    }
                  ],
                  "maustate": "Normal",
                  "maxrecords": "500000"
                }
              }
            }
          }
        }
      }
    },
    "/api/Session/CheckSession": {
      "post": {
        "operationId": "check-session",
        "summary": "Check session",
        "description": "Confirm a session token is still valid. A valid token returns ErrorCode 0 with the session's current SessionExpir. An expired or unknown token returns ErrorCode 101 with \"Session Expired\" and a SessionExpir of 0001-01-01T00:00:00.",
        "tags": [
          "Authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "The session token to validate."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "SessionToken": "QK[OFHLQSDQROJQULKPJQPGXG",
                  "SessionFlag": 0,
                  "isGuestSession": false,
                  "SessionExpir": "2026-08-27T14:41:05.1956089+00:00"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Session/RefreshSession": {
      "post": {
        "operationId": "refresh-session",
        "summary": "Refresh session",
        "description": "Extend a session token's lifetime without a full re-login, resetting SessionExpir to the current time plus the server's session timeout. That timeout is SESSION_TIMEOUT in app settings and defaults to 20 minutes.",
        "tags": [
          "Authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "The session token to extend."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "SessionToken": "JDEJGZRMSTXHYJJTOEHMSNYMN",
                  "SessionFlag": 0,
                  "isGuestSession": false,
                  "SessionExpir": "2026-08-27T14:41:01.738885"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Session/ResetPassport": {
      "post": {
        "operationId": "reset-passport",
        "summary": "Reset session passport",
        "description": "Rebuild the session's passport — its cached licence and permission state — and return it. The response describes licensed modules, registered servers and SMTP configuration for the instance.",
        "tags": [
          "Authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "The session token whose passport should be rebuilt."
                  },
                  "withReturn": {
                    "type": "boolean",
                    "description": "Reserved. Send false."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "withReturn": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "isFirstRun": true,
                  "isExpiredBase": false,
                  "isValidBase": false,
                  "isValidTrial": false,
                  "Version": 0,
                  "ProdType": 0,
                  "TotalReportCount": 0,
                  "TotalUserCount": 0,
                  "YurbiModuleProfiles": [],
                  "isSchedulerLicensed": false,
                  "isConnectLicensed": false,
                  "isRolesLicensed": false,
                  "isLDAPLicensed": false,
                  "isAppShieldLicensed": false,
                  "RegisteredServerList": [],
                  "YurbiLicenses": [],
                  "TrialLicenses": [],
                  "TeamLicenses": [],
                  "EnterpriseLicenses": [],
                  "SMTPServerList": []
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/login/DoLogout": {
      "post": {
        "operationId": "do-logout",
        "summary": "Log out",
        "description": "End a session and release its token. Returns a bare 0 rather than a JSON object. Afterwards the token returns ErrorCode 101 from Check session.",
        "tags": [
          "Authentication"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "The session token to end."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 0
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/NewContact": {
      "post": {
        "operationId": "new-contact",
        "summary": "New user template",
        "description": "Return an empty user object with every collection initialised. Fill it in and pass it to Save user.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "ID": null,
                  "LoginName": null,
                  "FirstName": null,
                  "LastName": null,
                  "EmailAddress": null,
                  "Company": null,
                  "Tag1": null,
                  "twofa": null,
                  "Pin": null,
                  "AuthType": null,
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": false,
                  "SecurityGroups": [],
                  "UserApplications": [],
                  "Preferences": [],
                  "timezone": 0,
                  "timezonename": null,
                  "isFastCache": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/SaveContact": {
      "post": {
        "operationId": "save-contact",
        "summary": "Create or update a user",
        "description": "Create a user or update an existing one. user.ID decides which: send null to create, or an existing ID to update. Set withpin to true when the payload carries a Pin to apply. App access is assigned in the same call through user.UserApplications, and Profile Tags through Tag1–Tag4.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "withpin": {
                    "type": "boolean",
                    "description": "True when user.Pin should be applied."
                  },
                  "user": {
                    "type": "object",
                    "description": "The user object. Start from New user template. ID null creates; an existing ID updates."
                  }
                },
                "required": [
                  "sessionToken",
                  "withpin",
                  "user"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "withpin": true,
                "user": {
                  "ID": null,
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Pin": "1234",
                  "AuthType": "PIN",
                  "twofa": "none",
                  "Tag1": "TENANT-A",
                  "timezone": -5,
                  "timezonename": "Eastern Standard Time",
                  "SecurityGroups": [],
                  "UserApplications": [
                    {
                      "ApplicationID": "1001",
                      "ApplicationName": "Sample Data",
                      "ApplicationRoleID": "7",
                      "ApplicationRoleName": "Architect",
                      "ApplicationRoleType": "0",
                      "applicationUserDataSourceID": ""
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "639234395265102835",
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Tag1": "TENANT-A",
                  "Tag2": "",
                  "Tag3": "",
                  "Tag4": "",
                  "twofa": "none",
                  "CreateDate": "2026-08-27T14:58:46",
                  "ModifyDate": "2026-08-27T14:58:47",
                  "LoginDate": "2026-08-27T14:58:46",
                  "Pin": null,
                  "AuthType": "PIN",
                  "Description": "",
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": true,
                  "SecurityGroups": [
                    {
                      "GroupId": "12",
                      "GroupName": "Tenant A",
                      "GroupRoles": [
                        {
                          "RoleId": "3",
                          "RoleName": "Modify"
                        }
                      ],
                      "GroupStatus": 0
                    }
                  ],
                  "ComboName": "Smith, Jane",
                  "FullName": "Jane Smith",
                  "UserApplications": [
                    {
                      "ApplicationID": "1001",
                      "ApplicationName": "Sample Data",
                      "ApplicationRoleID": "7",
                      "ApplicationRoleName": "Architect",
                      "ApplicationRoleType": "0",
                      "applicationUserDataSourceID": ""
                    }
                  ],
                  "Preferences": [],
                  "UserState": 0,
                  "Language": {
                    "id": 1,
                    "nativename": "English",
                    "englishname": "English",
                    "iso_name": "EN",
                    "phraselist": null
                  },
                  "timezone": -5,
                  "timezonename": "America/New_York",
                  "isFastCache": 0,
                  "FastCacheLimit": 0,
                  "lockdate": "0001-01-01T00:00:00",
                  "bforcepasschange": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/SaveMYContact": {
      "post": {
        "operationId": "save-my-contact",
        "summary": "Update my profile",
        "description": "Update the profile of the user who owns the session. Same payload shape as Save user, scoped to the caller.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "withpin": {
                    "type": "boolean",
                    "description": "True when a new Pin is being set."
                  },
                  "user": {
                    "type": "object",
                    "description": "The signed-in user's object with the fields to change."
                  }
                },
                "required": [
                  "sessionToken",
                  "withpin",
                  "user"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "withpin": false,
                "user": {
                  "ID": "639234395265102835",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jane@example.com",
                  "Description": ""
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "639234395265102835",
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Tag1": "TENANT-A",
                  "Tag2": "",
                  "Tag3": "",
                  "Tag4": "",
                  "twofa": "none",
                  "CreateDate": "2026-08-27T14:58:46",
                  "ModifyDate": "2026-08-27T14:58:47",
                  "LoginDate": "2026-08-27T14:58:46",
                  "Pin": null,
                  "AuthType": "PIN",
                  "Description": "",
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": true,
                  "SecurityGroups": [
                    {
                      "GroupId": "12",
                      "GroupName": "Tenant A",
                      "GroupRoles": [
                        {
                          "RoleId": "3",
                          "RoleName": "Modify"
                        }
                      ],
                      "GroupStatus": 0
                    }
                  ],
                  "ComboName": "Smith, Jane",
                  "FullName": "Jane Smith",
                  "UserApplications": [
                    {
                      "ApplicationID": "1001",
                      "ApplicationName": "Sample Data",
                      "ApplicationRoleID": "7",
                      "ApplicationRoleName": "Architect",
                      "ApplicationRoleType": "0",
                      "applicationUserDataSourceID": ""
                    }
                  ],
                  "Preferences": [],
                  "UserState": 0,
                  "Language": {
                    "id": 1,
                    "nativename": "English",
                    "englishname": "English",
                    "iso_name": "EN",
                    "phraselist": []
                  },
                  "timezone": -5,
                  "timezonename": "America/New_York",
                  "isFastCache": 0,
                  "FastCacheLimit": 0,
                  "lockdate": "0001-01-01T00:00:00",
                  "bforcepasschange": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/GetContactList": {
      "post": {
        "operationId": "get-contact-list",
        "summary": "List users",
        "description": "Return every user on the instance as an array. Each entry carries its own ErrorCode; there is no wrapper object.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ID": "639234395265102835",
                    "LoginName": "jsmith",
                    "FirstName": "Jane",
                    "LastName": "Smith",
                    "EmailAddress": "jsmith@example.com",
                    "Company": "Acme",
                    "Tag1": "TENANT-A",
                    "Tag2": "",
                    "Tag3": "",
                    "Tag4": "",
                    "twofa": "none",
                    "CreateDate": "2026-08-27T14:58:46",
                    "ModifyDate": "2026-08-27T14:58:47",
                    "LoginDate": "2026-08-27T14:58:46",
                    "Pin": null,
                    "AuthType": "PIN",
                    "Description": "",
                    "isAdmin": false,
                    "isSuperAdmin": false,
                    "isBuilder": false,
                    "isAgent": false,
                    "isArchitect": true,
                    "SecurityGroups": [
                      {
                        "GroupId": "12",
                        "GroupName": "Tenant A",
                        "GroupRoles": [
                          {
                            "RoleId": "3",
                            "RoleName": "Modify"
                          }
                        ],
                        "GroupStatus": 0
                      }
                    ],
                    "ComboName": "Smith, Jane",
                    "FullName": "Jane Smith",
                    "UserApplications": [
                      {
                        "ApplicationID": "1001",
                        "ApplicationName": "Sample Data",
                        "ApplicationRoleID": "7",
                        "ApplicationRoleName": "Architect",
                        "ApplicationRoleType": "0",
                        "applicationUserDataSourceID": ""
                      }
                    ],
                    "Preferences": [],
                    "UserState": 0,
                    "Language": {
                      "id": 1,
                      "nativename": "English",
                      "englishname": "English",
                      "iso_name": "EN",
                      "phraselist": []
                    },
                    "timezone": -5,
                    "timezonename": "America/New_York",
                    "isFastCache": 0,
                    "FastCacheLimit": 0,
                    "lockdate": "0001-01-01T00:00:00",
                    "bforcepasschange": false
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/GetContactById": {
      "post": {
        "operationId": "get-contact-by-id",
        "summary": "Get a user",
        "description": "Return a single user by ID, including group memberships, app assignments and Profile Tags.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ContactId": {
                    "type": "string",
                    "description": "The user's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "ContactId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ContactId": "639234395265102835"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "639234395265102835",
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Tag1": "TENANT-A",
                  "Tag2": "",
                  "Tag3": "",
                  "Tag4": "",
                  "twofa": "none",
                  "CreateDate": "2026-08-27T14:58:46",
                  "ModifyDate": "2026-08-27T14:58:47",
                  "LoginDate": "2026-08-27T14:58:46",
                  "Pin": null,
                  "AuthType": "PIN",
                  "Description": "",
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": true,
                  "SecurityGroups": [
                    {
                      "GroupId": "12",
                      "GroupName": "Tenant A",
                      "GroupRoles": [
                        {
                          "RoleId": "3",
                          "RoleName": "Modify"
                        }
                      ],
                      "GroupStatus": 0
                    }
                  ],
                  "ComboName": "Smith, Jane",
                  "FullName": "Jane Smith",
                  "UserApplications": [
                    {
                      "ApplicationID": "1001",
                      "ApplicationName": "Sample Data",
                      "ApplicationRoleID": "7",
                      "ApplicationRoleName": "Architect",
                      "ApplicationRoleType": "0",
                      "applicationUserDataSourceID": ""
                    }
                  ],
                  "Preferences": [],
                  "UserState": 0,
                  "Language": {
                    "id": 1,
                    "nativename": "English",
                    "englishname": "English",
                    "iso_name": "EN",
                    "phraselist": []
                  },
                  "timezone": -5,
                  "timezonename": "America/New_York",
                  "isFastCache": 0,
                  "FastCacheLimit": 0,
                  "lockdate": "0001-01-01T00:00:00",
                  "bforcepasschange": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/DeleteContact": {
      "post": {
        "operationId": "delete-contact",
        "summary": "Delete a user",
        "description": "Remove a user. The request takes the whole user object under user, not an ID, so fetch it first with List users or Get a user. The deleted record is echoed back with ErrorCode 0; group membership and application assignments are already detached, so those collections come back null or empty.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "user": {
                    "type": "object",
                    "description": "The complete user object to delete."
                  }
                },
                "required": [
                  "sessionToken",
                  "user"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "user": {
                  "ID": "639234395265102835",
                  "LoginName": "jsmith"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "639234395265102835",
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Tag1": "TENANT-A",
                  "Tag2": "",
                  "Tag3": "",
                  "Tag4": "",
                  "twofa": "none",
                  "CreateDate": "2026-08-27T14:58:46",
                  "ModifyDate": "2026-08-27T14:58:47",
                  "LoginDate": "2026-08-27T14:58:46",
                  "Pin": null,
                  "AuthType": "PIN",
                  "Description": "",
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": false,
                  "SecurityGroups": null,
                  "UserApplications": [],
                  "Preferences": [],
                  "UserState": 0,
                  "ComboName": "Smith, Jane",
                  "FullName": "Jane Smith",
                  "Language": {
                    "id": 1,
                    "nativename": null,
                    "englishname": null,
                    "iso_name": null,
                    "phraselist": null
                  },
                  "timezone": -5,
                  "timezonename": "America/New_York",
                  "isFastCache": 0,
                  "FastCacheLimit": 0,
                  "lockdate": "0001-01-01T00:00:00",
                  "bforcepasschange": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/UnlockContact": {
      "post": {
        "operationId": "unlock-contact",
        "summary": "Unlock a user",
        "description": "Clear a lockout applied after repeated failed sign-ins. Like Delete a user, it takes the whole user object under user. The account's lockdate is reset. The response returns the account record; membership and application collections are not populated on this call.",
        "tags": [
          "Users"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "user": {
                    "type": "object",
                    "description": "The complete user object to unlock."
                  }
                },
                "required": [
                  "sessionToken",
                  "user"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "user": {
                  "ID": "639234395265102835",
                  "LoginName": "jsmith"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "639234395265102835",
                  "LoginName": "jsmith",
                  "FirstName": "Jane",
                  "LastName": "Smith",
                  "EmailAddress": "jsmith@example.com",
                  "Company": "Acme",
                  "Tag1": "TENANT-A",
                  "Tag2": "",
                  "Tag3": "",
                  "Tag4": "",
                  "twofa": "none",
                  "CreateDate": "2026-08-27T14:58:46",
                  "ModifyDate": "2026-08-27T14:58:47",
                  "LoginDate": "2026-08-27T14:58:46",
                  "Pin": null,
                  "AuthType": "PIN",
                  "Description": "",
                  "isAdmin": false,
                  "isSuperAdmin": false,
                  "isBuilder": false,
                  "isAgent": false,
                  "isArchitect": false,
                  "SecurityGroups": null,
                  "UserApplications": [],
                  "Preferences": [],
                  "UserState": 0,
                  "ComboName": "Smith, Jane",
                  "FullName": "Jane Smith",
                  "Language": {
                    "id": 1,
                    "nativename": null,
                    "englishname": null,
                    "iso_name": null,
                    "phraselist": null
                  },
                  "timezone": -5,
                  "timezonename": "America/New_York",
                  "isFastCache": 0,
                  "FastCacheLimit": 0,
                  "lockdate": "0001-01-01T00:00:00",
                  "bforcepasschange": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/GetAllSecurityGroups": {
      "post": {
        "operationId": "get-all-security-groups",
        "summary": "List security groups",
        "description": "Return every security group with its full membership. Each member is a complete user object, so responses grow with the size of the instance.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "GroupId": "12",
                    "GroupName": "Tenant A",
                    "GroupDescription": "All users for Tenant A",
                    "GroupCreated": "2026-08-27T14:58:49",
                    "GroupModified": "2026-08-27T14:58:49",
                    "GroupRoles": [],
                    "Membership": [
                      {
                        "ErrorCode": 0,
                        "ErrorMessage": "",
                        "ID": "639234395265102835",
                        "LoginName": "jsmith",
                        "FirstName": "Jane",
                        "LastName": "Smith",
                        "EmailAddress": "jsmith@example.com",
                        "Company": "Acme",
                        "Tag1": "TENANT-A",
                        "Tag2": "",
                        "Tag3": "",
                        "Tag4": "",
                        "twofa": "none",
                        "CreateDate": "2026-08-27T14:58:46",
                        "ModifyDate": "2026-08-27T14:58:47",
                        "LoginDate": "2026-08-27T14:58:46",
                        "Pin": null,
                        "AuthType": "PIN",
                        "Description": "",
                        "isAdmin": false,
                        "isSuperAdmin": false,
                        "isBuilder": false,
                        "isAgent": false,
                        "isArchitect": true,
                        "SecurityGroups": [
                          {
                            "GroupId": "12",
                            "GroupName": "Tenant A",
                            "GroupRoles": [
                              {
                                "RoleId": "3",
                                "RoleName": "Modify"
                              }
                            ],
                            "GroupStatus": 0
                          }
                        ],
                        "ComboName": "Smith, Jane",
                        "FullName": "Jane Smith",
                        "UserApplications": [
                          {
                            "ApplicationID": "1001",
                            "ApplicationName": "Sample Data",
                            "ApplicationRoleID": "7",
                            "ApplicationRoleName": "Architect",
                            "ApplicationRoleType": "0",
                            "applicationUserDataSourceID": ""
                          }
                        ],
                        "Preferences": [],
                        "UserState": 0,
                        "Language": {
                          "id": 1,
                          "nativename": null,
                          "englishname": null,
                          "iso_name": null,
                          "phraselist": []
                        },
                        "timezone": -5,
                        "timezonename": "America/New_York",
                        "isFastCache": 0,
                        "FastCacheLimit": 0,
                        "lockdate": "0001-01-01T00:00:00",
                        "bforcepasschange": false
                      }
                    ],
                    "AllUsers": [],
                    "AllRoles": [],
                    "GroupStatus": 0
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/GetSecurityGroupById": {
      "post": {
        "operationId": "get-security-group-by-id",
        "summary": "Get a security group",
        "description": "Return a single group with its membership.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "GroupId": {
                    "type": "string",
                    "description": "The group's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "GroupId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "GroupId": "12"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "GroupId": "12",
                  "GroupName": "Tenant A",
                  "GroupDescription": "All users for Tenant A",
                  "GroupCreated": "2026-08-27T14:58:49",
                  "GroupModified": "2026-08-27T14:58:49",
                  "GroupRoles": [],
                  "Membership": [
                    {
                      "ErrorCode": 0,
                      "ErrorMessage": "",
                      "ID": "639234395265102835",
                      "LoginName": "jsmith",
                      "FirstName": "Jane",
                      "LastName": "Smith",
                      "EmailAddress": "jsmith@example.com",
                      "Company": "Acme",
                      "Tag1": "TENANT-A",
                      "Tag2": "",
                      "Tag3": "",
                      "Tag4": "",
                      "twofa": "none",
                      "CreateDate": "2026-08-27T14:58:46",
                      "ModifyDate": "2026-08-27T14:58:47",
                      "LoginDate": "2026-08-27T14:58:46",
                      "Pin": null,
                      "AuthType": "PIN",
                      "Description": "",
                      "isAdmin": false,
                      "isSuperAdmin": false,
                      "isBuilder": false,
                      "isAgent": false,
                      "isArchitect": true,
                      "SecurityGroups": [
                        {
                          "GroupId": "12",
                          "GroupName": "Tenant A",
                          "GroupRoles": [
                            {
                              "RoleId": "3",
                              "RoleName": "Modify"
                            }
                          ],
                          "GroupStatus": 0
                        }
                      ],
                      "ComboName": "Smith, Jane",
                      "FullName": "Jane Smith",
                      "UserApplications": [
                        {
                          "ApplicationID": "1001",
                          "ApplicationName": "Sample Data",
                          "ApplicationRoleID": "7",
                          "ApplicationRoleName": "Architect",
                          "ApplicationRoleType": "0",
                          "applicationUserDataSourceID": ""
                        }
                      ],
                      "Preferences": [],
                      "UserState": 0,
                      "Language": {
                        "id": 1,
                        "nativename": null,
                        "englishname": null,
                        "iso_name": null,
                        "phraselist": []
                      },
                      "timezone": -5,
                      "timezonename": "America/New_York",
                      "isFastCache": 0,
                      "FastCacheLimit": 0,
                      "lockdate": "0001-01-01T00:00:00",
                      "bforcepasschange": false
                    }
                  ],
                  "AllUsers": [],
                  "AllRoles": [],
                  "GroupStatus": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/NewSecurityGroup": {
      "post": {
        "operationId": "new-security-group",
        "summary": "New group template",
        "description": "Return an empty security group object ready to fill in and pass to Save a security group.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "GroupId": null,
                  "GroupName": null,
                  "GroupDescription": null,
                  "GroupCreated": "2026-08-27T14:58:48.6587525+00:00",
                  "GroupModified": "2026-08-27T14:58:48.658753+00:00",
                  "GroupRoles": [],
                  "Membership": [],
                  "AllUsers": [],
                  "AllRoles": [],
                  "GroupStatus": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/SaveSecurityGroup": {
      "post": {
        "operationId": "save-security-group",
        "summary": "Create or update a group",
        "description": "Create a security group or update an existing one. group.GroupId decides which: null creates and the server returns the new ID; an existing ID updates.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "group": {
                    "type": "object",
                    "description": "The group object. Start from New group template."
                  }
                },
                "required": [
                  "sessionToken",
                  "group"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "group": {
                  "GroupId": null,
                  "GroupName": "Tenant A",
                  "GroupDescription": "All users for Tenant A",
                  "GroupStatus": 0,
                  "AllUsers": [],
                  "AllRoles": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "GroupId": "12",
                  "GroupName": "Tenant A",
                  "GroupDescription": "All users for Tenant A",
                  "GroupCreated": "0001-01-01T00:00:00",
                  "GroupModified": "0001-01-01T00:00:00",
                  "GroupRoles": [],
                  "Membership": [],
                  "AllUsers": [],
                  "AllRoles": [],
                  "GroupStatus": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/DeleteSecurityGroup": {
      "post": {
        "operationId": "delete-security-group",
        "summary": "Delete a security group",
        "description": "Remove a security group. The request takes the whole group object under group, so fetch it first with List security groups. The deleted record is echoed back with ErrorCode 0.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "group": {
                    "type": "object",
                    "description": "The complete group object to delete."
                  }
                },
                "required": [
                  "sessionToken",
                  "group"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "group": {
                  "GroupId": "12",
                  "GroupName": "Tenant A"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "GroupId": "12",
                  "GroupName": "Tenant A",
                  "GroupDescription": "All users for Tenant A",
                  "GroupCreated": "2026-08-27T14:58:49",
                  "GroupModified": "2026-08-27T14:58:49",
                  "GroupRoles": [],
                  "Membership": [],
                  "AllUsers": [],
                  "AllRoles": [],
                  "GroupStatus": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/AddUser": {
      "post": {
        "operationId": "add-user",
        "summary": "Add user to group",
        "description": "Add a user to a security group with a role. The role controls what the user may do with content in folders scoped to that group. Returns the plain-text string User Added Successfully. Supply valid IDs: an unrecognised ContactId returns an error message rather than a status.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "GroupId": {
                    "type": "string",
                    "description": "The group to add the user to."
                  },
                  "ContactId": {
                    "type": "string",
                    "description": "The user's ID."
                  },
                  "RoleId": {
                    "type": "string",
                    "description": "The role to grant within the group."
                  }
                },
                "required": [
                  "sessionToken",
                  "GroupId",
                  "ContactId",
                  "RoleId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "GroupId": "12",
                "ContactId": "639234395265102835",
                "RoleId": "3"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "User Added Successfully."
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Group/RemoveUser": {
      "post": {
        "operationId": "remove-user",
        "summary": "Remove user from group",
        "description": "Remove a user from a security group. Returns the plain string \"User Removed Successfully.\".",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "GroupId": {
                    "type": "string",
                    "description": "The group to remove the user from."
                  },
                  "ContactId": {
                    "type": "string",
                    "description": "The user's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "GroupId",
                  "ContactId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "GroupId": "12",
                "ContactId": "639234395265102835"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "User Removed Successfully."
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Contact/GetRolesList": {
      "post": {
        "operationId": "get-roles-list",
        "summary": "List roles",
        "description": "Return the fixed role list used by group membership and app assignment. Note these entries use ERROR_CODE and ERROR_MESSAGE rather than the usual casing.",
        "tags": [
          "Groups & Roles"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "0",
                    "RoleName": "None",
                    "RoleDescription": "No access to resources within this group"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "1",
                    "RoleName": "Admin",
                    "RoleDescription": "Full access to resources assigned to this group"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "2",
                    "RoleName": "View",
                    "RoleDescription": "Read-Only access to resources within this group"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "3",
                    "RoleName": "Modify",
                    "RoleDescription": "Edit permissions granted on resources assigned to this group"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "4",
                    "RoleName": "Delete",
                    "RoleDescription": "Delete permissions granted on resources assigned to this group"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "5",
                    "RoleName": "Builder",
                    "RoleDescription": "Consumes Builder License Type"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "6",
                    "RoleName": "Agent",
                    "RoleDescription": "Consumes Agent License Type"
                  },
                  {
                    "ERROR_CODE": 0,
                    "ERROR_MESSAGE": "",
                    "RoleId": "7",
                    "RoleName": "Architect",
                    "RoleDescription": "Consumes Architect License Type"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/DataTag/NewDataTag": {
      "post": {
        "operationId": "new-data-tag",
        "summary": "New data tag template",
        "description": "Return an empty data tag object ready to fill in and pass to Save a data tag.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ID": "",
                  "Label": "New Data Tag",
                  "SecurityGroups": [],
                  "Contacts": [],
                  "DataTypeEnum": 1,
                  "isGroup": false,
                  "isUser": true,
                  "isActive": true,
                  "DefaultValue": "",
                  "TagGroup": "",
                  "Index": 0,
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ModifiedDate": "0001-01-01T00:00:00",
                  "CreatedDate": "0001-01-01T00:00:00"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/DataTag/SaveDataTag": {
      "post": {
        "operationId": "save-data-tag",
        "summary": "Create or update a data tag",
        "description": "Create a data tag or update an existing one. An empty ID creates and the server returns the new one. Per-group values go in SecurityGroups: set RelationshipType and RelationType to tag_grp, RightID to the group's ID, and the value itself in Option1. Per-user values use the Contacts collection the same way. DefaultValue applies to anyone with no specific value assigned.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "datatag": {
                    "type": "object",
                    "description": "The data tag object. Start from New data tag template."
                  }
                },
                "required": [
                  "sessionToken",
                  "datatag"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "datatag": {
                  "ID": "",
                  "Label": "tenantid",
                  "TagGroup": "Tenancy",
                  "DataTypeEnum": 1,
                  "isGroup": true,
                  "isUser": false,
                  "isActive": true,
                  "DefaultValue": "NONE",
                  "Contacts": [],
                  "Index": 0,
                  "SecurityGroups": [
                    {
                      "LeftID": "",
                      "RightID": "12",
                      "RelationshipType": "tag_grp",
                      "RelationType": "tag_grp",
                      "Option1": "TENANT-A",
                      "PermissionTypeEnum": 0
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ID": "639234411252055064",
                  "Label": "tenantid",
                  "SecurityGroups": [
                    {
                      "ErrorCode": 0,
                      "ErrorMessage": "",
                      "LeftID": "639234411252055064",
                      "RightID": "12",
                      "RelationshipType": "tag_grp",
                      "RelationType": "tag_grp",
                      "Option1": "TENANT-A",
                      "Option2": "",
                      "Option3": "",
                      "Option4": "",
                      "Option5": "",
                      "Option6": "",
                      "Option7": "",
                      "Option8": "",
                      "Option9": "",
                      "Option10": "",
                      "PermissionTypeEnum": 20
                    }
                  ],
                  "Contacts": [],
                  "DataTypeEnum": 1,
                  "isGroup": true,
                  "isUser": false,
                  "isActive": true,
                  "DefaultValue": "NONE",
                  "TagGroup": "Tenancy",
                  "Index": 0,
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ModifiedDate": "2026-08-27T15:25:25",
                  "CreatedDate": "2026-08-27T15:25:25"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/DataTag/GetAllDataTags": {
      "post": {
        "operationId": "get-all-data-tags",
        "summary": "List data tags",
        "description": "Return every data tag with its group and user value assignments.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ID": "639234411252055064",
                    "Label": "tenantid",
                    "SecurityGroups": [
                      {
                        "ErrorCode": 0,
                        "ErrorMessage": "",
                        "LeftID": "639234411252055064",
                        "RightID": "12",
                        "RelationshipType": "tag_grp",
                        "RelationType": "tag_grp",
                        "Option1": "TENANT-A",
                        "Option2": "",
                        "Option3": "",
                        "Option4": "",
                        "Option5": "",
                        "Option6": "",
                        "Option7": "",
                        "Option8": "",
                        "Option9": "",
                        "Option10": "",
                        "PermissionTypeEnum": 20
                      }
                    ],
                    "Contacts": [],
                    "DataTypeEnum": 1,
                    "isGroup": true,
                    "isUser": false,
                    "isActive": true,
                    "DefaultValue": "NONE",
                    "TagGroup": "Tenancy",
                    "Index": 0,
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModifiedDate": "2026-08-27T15:25:25",
                    "CreatedDate": "2026-08-27T15:25:25"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/DataTag/DeleteDataTag": {
      "post": {
        "operationId": "delete-data-tag",
        "summary": "Delete a data tag",
        "description": "Remove a data tag. Takes the whole tag object under datatag, so fetch it first with List data tags. Returns a {Code, Message} result.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "datatag": {
                    "type": "object",
                    "description": "The complete data tag object to delete."
                  }
                },
                "required": [
                  "sessionToken",
                  "datatag"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "datatag": {
                  "ID": "639234411252055064",
                  "Label": "tenantid"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "Code": 0,
                  "Message": "Data Tag Successfully Deleted"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/NewPolicy": {
      "post": {
        "operationId": "new-policy",
        "summary": "New policy template",
        "description": "Return an empty AppShield policy with a generated name and date, ready to fill in and pass to Save a policy.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": null,
                  "ErrorMessage": null,
                  "id": null,
                  "Name": "New AppShield Policy",
                  "Description": "AppShield Policy Created 08/27/2026 14:58:50",
                  "CreatedDate": "2026-08-27T14:58:50.949385+00:00",
                  "ModifiedDate": "08/27/2026 14:58:50",
                  "CreatedBy": null,
                  "ModifiedBy": null,
                  "Constraints": [],
                  "Groups": null,
                  "Users": null,
                  "isActive": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/GetAllAppshieldPolicies": {
      "post": {
        "operationId": "get-all-appshield-policies",
        "summary": "List policies",
        "description": "Return every AppShield policy on the instance with its constraints, assigned groups and assigned users.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ErrorCode": "0",
                    "ErrorMessage": "",
                    "id": "639234411233338341",
                    "Name": "Tenant row-level security",
                    "Description": "Constrains every report to the caller's tenant id",
                    "CreatedDate": "2026-08-27T15:25:23.3338367+00:00",
                    "ModifiedDate": "08/27/2026 15:25:23",
                    "CreatedBy": {
                      "ID": "639234363032231617",
                      "LoginName": "apitest",
                      "FullName": "API Test"
                    },
                    "Constraints": [],
                    "Groups": [
                      {
                        "GroupId": "12"
                      }
                    ],
                    "Users": [],
                    "isActive": false
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/SaveAppShieldPolicy": {
      "post": {
        "operationId": "save-appshield-policy",
        "summary": "Create or update a policy",
        "description": "Create or update an AppShield policy and assign it to groups and users in the same call. Build the policy from New policy template; Constraints, Groups and Users must be arrays rather than null. The groups and users parameters are arrays of IDs and are what the assignment is built from. The response echoes the saved policy and is large, because it embeds the full user records of everyone the policy touches. When updating a policy, build the request from the compact object returned by List policies rather than resending a previous save response, which can exceed the request size limit.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "policy": {
                    "type": "object",
                    "description": "The policy object, built from the template."
                  },
                  "isDeepSave": {
                    "type": "boolean",
                    "description": "Save the policy together with its constraints."
                  },
                  "groups": {
                    "type": "array",
                    "description": "Group IDs the policy applies to. Send an empty array for none."
                  },
                  "users": {
                    "type": "array",
                    "description": "User IDs the policy applies to. Send an empty array for none."
                  }
                },
                "required": [
                  "sessionToken",
                  "policy",
                  "isDeepSave",
                  "groups",
                  "users"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "policy": {
                  "id": null,
                  "Name": "Tenant row-level security",
                  "Description": "Constrains every report to the caller's tenant id",
                  "Constraints": [],
                  "Groups": [],
                  "Users": [],
                  "isActive": false
                },
                "isDeepSave": true,
                "groups": [
                  "12"
                ],
                "users": []
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": "0",
                  "ErrorMessage": "",
                  "id": "639234411233338341",
                  "Name": "Tenant row-level security",
                  "Description": "Constrains every report to the caller's tenant id",
                  "CreatedDate": "2026-08-27T15:25:23.3338367+00:00",
                  "ModifiedDate": "08/27/2026 15:25:23",
                  "CreatedBy": {
                    "ID": "639234363032231617",
                    "LoginName": "apitest",
                    "FullName": "API Test"
                  },
                  "Constraints": [],
                  "Groups": [
                    {
                      "GroupId": "12"
                    }
                  ],
                  "Users": [],
                  "isActive": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/DeletePolicy": {
      "post": {
        "operationId": "delete-policy",
        "summary": "Delete a policy",
        "description": "Remove an AppShield policy. Takes the whole policy object under policy, so fetch it first with List policies. Returns a plain status string.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "policy": {
                    "type": "object",
                    "description": "The complete policy object to delete."
                  }
                },
                "required": [
                  "sessionToken",
                  "policy"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "policy": {
                  "id": "639234411233338341",
                  "Name": "Tenant row-level security"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "App Shield Policy Deleted"
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/AddGroup": {
      "post": {
        "operationId": "appshield-add-group",
        "summary": "Add group to policy",
        "description": "Attach a security group to an existing policy. Returns the plain-text string Success. An unknown policy id returns Policy not found. Other inputs, including an unknown group id, also return Success, so confirm the assignment by reading the policy back with List policies.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "policyid": {
                    "type": "string",
                    "description": "The policy's ID."
                  },
                  "groupid": {
                    "type": "string",
                    "description": "The security group's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "policyid",
                  "groupid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "policyid": "639234411233338341",
                "groupid": "12"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "Success"
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppShield/RemoveGroup": {
      "post": {
        "operationId": "appshield-remove-group",
        "summary": "Remove group from policy",
        "description": "Detach a security group from a policy. Returns the plain-text string Success. An unknown policy id returns Policy not found. Other inputs, including an unknown group id, also return Success, so confirm the assignment by reading the policy back with List policies.",
        "tags": [
          "Data Security"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "policyid": {
                    "type": "string",
                    "description": "The policy's ID."
                  },
                  "groupid": {
                    "type": "string",
                    "description": "The security group's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "policyid",
                  "groupid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "policyid": "639234411233338341",
                "groupid": "12"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "Success"
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/App/GetApplicationList": {
      "post": {
        "operationId": "get-app-list",
        "summary": "List applications",
        "description": "Return every application on the instance with its licence position, the users assigned to it, and its registered database servers. Responses are large: each entry embeds a full module profile including user records.",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ReportModule": {
                      "ID": "1003",
                      "Name": "Test Load",
                      "ModuleType": "anydb1003",
                      "ProductCode": "ANYDB",
                      "isAnyDbApp": true
                    },
                    "ModuleProfile": {
                      "isLicensed": true,
                      "LicensedQuanity": 999,
                      "ConsumedQuanity": 1,
                      "NextExpiration": "12/31/2035",
                      "IsExpired": false,
                      "ArchitectConsumptionCount": 3,
                      "BuilderConsumptionCount": 1,
                      "AgentConsumptionCount": 1,
                      "Membership": []
                    },
                    "Status": 0,
                    "RegisteredServers": [
                      {
                        "ErrorCode": 0,
                        "ErrorMessage": "",
                        "ID": "17769733521",
                        "ReportModule": {
                          "ID": "1003",
                          "Name": "Test Load",
                          "ModuleType": "anydb1003",
                          "ProductCode": "ANYDB",
                          "isAnyDbApp": true,
                          "isPremiumApp": false,
                          "isAPIApp": false
                        },
                        "ModuleType": "ANYDB",
                        "TimeZone": 0,
                        "DaylightSavings": false,
                        "DatabaseOwner": "",
                        "DatabaseServer": "db.internal.example.com",
                        "DatabaseLogin": "reporting",
                        "DatabaseName": "sales",
                        "DatabasePassword": "",
                        "DatabaseDriver": "POSTGRESQL",
                        "DatabasePlatform": "postgresql",
                        "CommandTimeout": 30,
                        "ConnectionTimeout": 10,
                        "Permissions": [],
                        "MappedAnyDB": "",
                        "DisplayName": "Test Load",
                        "allowstoredproc": 0,
                        "allowdirectsql": 0,
                        "datasources": [],
                        "additionalparams": ""
                      }
                    ]
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/GetAdminRegisteredServers": {
      "post": {
        "operationId": "get-registered-servers",
        "summary": "List registered servers",
        "description": "Return every registered database server with its connection settings. DatabasePassword is always returned empty.",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ID": "17769733521",
                    "ReportModule": {
                      "ID": "1003",
                      "Name": "Test Load",
                      "ModuleType": "anydb1003",
                      "ProductCode": "ANYDB",
                      "isAnyDbApp": true,
                      "isPremiumApp": false,
                      "isAPIApp": false
                    },
                    "ModuleType": "ANYDB",
                    "TimeZone": 0,
                    "DaylightSavings": false,
                    "DatabaseOwner": "",
                    "DatabaseServer": "db.internal.example.com",
                    "DatabaseLogin": "reporting",
                    "DatabaseName": "sales",
                    "DatabasePassword": "",
                    "DatabaseDriver": "POSTGRESQL",
                    "DatabasePlatform": "postgresql",
                    "CommandTimeout": 30,
                    "ConnectionTimeout": 10,
                    "Permissions": [],
                    "MappedAnyDB": "",
                    "DisplayName": "Test Load",
                    "allowstoredproc": 0,
                    "allowdirectsql": 0,
                    "datasources": [],
                    "additionalparams": ""
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/GetTimeZones": {
      "post": {
        "operationId": "get-timezones",
        "summary": "List time zones",
        "description": "Return the time zone list Yurbi uses for users and registered servers.",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "Name": "Eastern Time",
                    "Code": "GMT -0500",
                    "Offset": -5
                  },
                  {
                    "Name": "Central Time",
                    "Code": "GMT -0600",
                    "Offset": -6
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/InsertAnyDbModule": {
      "post": {
        "operationId": "insert-anydb-module",
        "summary": "Register an AnyDB app",
        "description": "Create a new AnyDB application shell. The returned module carries the ID used by every App Builder call.",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "appname": {
                    "type": "string",
                    "description": "Name for the new application."
                  },
                  "description": {
                    "type": "string",
                    "description": "Description for the new application."
                  }
                },
                "required": [
                  "sessionToken",
                  "appname",
                  "description"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "appname": "Tenant A Data",
                "description": "Provisioned via the API"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "ID": "1010",
                  "Name": "Tenant A Data",
                  "ModuleType": "anydb1010",
                  "ProductCode": "ANYDB",
                  "isAnyDbApp": true
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/SaveRegSrv": {
      "post": {
        "operationId": "save-regsrv",
        "summary": "Save a registered server",
        "description": "Create or update the database connection behind an application. Test the settings with Test connection before saving.",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "regserver": {
                    "type": "object",
                    "description": "The registered server object."
                  },
                  "bsaveasanydb": {
                    "type": "boolean",
                    "description": "Save as an AnyDB application."
                  },
                  "badvrpt": {
                    "type": "boolean",
                    "description": "Enable advanced report support."
                  }
                },
                "required": [
                  "sessionToken",
                  "regserver"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "bsaveasanydb": true,
                "badvrpt": false,
                "regserver": {
                  "ID": "17769733521",
                  "DisplayName": "Tenant A Data",
                  "DatabaseDriver": "POSTGRESQL",
                  "DatabasePlatform": "postgresql",
                  "DatabaseServer": "db.internal.example.com",
                  "DatabaseLogin": "reporting",
                  "DatabasePassword": "YOUR_DB_PASSWORD",
                  "DatabaseName": "sales",
                  "DatabaseOwner": "",
                  "ConnectionTimeout": 10,
                  "CommandTimeout": 30
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ID": "17769733521",
                  "ReportModule": {
                    "ID": "1003",
                    "Name": "Test Load",
                    "ModuleType": "anydb1003",
                    "ProductCode": "ANYDB",
                    "isAnyDbApp": true,
                    "isPremiumApp": false,
                    "isAPIApp": false
                  },
                  "ModuleType": "ANYDB",
                  "TimeZone": 0,
                  "DaylightSavings": false,
                  "DatabaseOwner": "",
                  "DatabaseServer": "db.internal.example.com",
                  "DatabaseLogin": "reporting",
                  "DatabaseName": "sales",
                  "DatabasePassword": "",
                  "DatabaseDriver": "POSTGRESQL",
                  "DatabasePlatform": "postgresql",
                  "CommandTimeout": 30,
                  "ConnectionTimeout": 10,
                  "Permissions": [],
                  "MappedAnyDB": "",
                  "DisplayName": "Test Load",
                  "allowstoredproc": 0,
                  "allowdirectsql": 0,
                  "datasources": [],
                  "additionalparams": ""
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/TestConnection": {
      "post": {
        "operationId": "test-connection",
        "summary": "Test connection",
        "description": "Test a database connection without saving it. Returns a plain string: \"Passed\" on success, otherwise a message describing the failure, for example \"Test Failed - Name or service not known\".",
        "tags": [
          "Apps & Servers"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "regserver": {
                    "type": "object",
                    "description": "The connection settings to test."
                  }
                },
                "required": [
                  "sessionToken",
                  "regserver"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "regserver": {
                  "DisplayName": "Tenant A Data",
                  "DatabaseDriver": "POSTGRESQL",
                  "DatabasePlatform": "postgresql",
                  "DatabaseServer": "db.internal.example.com",
                  "DatabaseLogin": "reporting",
                  "DatabasePassword": "YOUR_DB_PASSWORD",
                  "DatabaseName": "sales",
                  "DatabaseOwner": "",
                  "ConnectionTimeout": 10,
                  "CommandTimeout": 30
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "Passed"
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppBuilder/GetAnyDbModulesList": {
      "post": {
        "operationId": "get-anydb-modules-list",
        "summary": "List AnyDB apps",
        "description": "Return every AnyDB application with its registered server. ID is the RegServerID and ReportModule.ID is the ModuleID — App Builder calls need both.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ID": "17769733521",
                    "ReportModule": {
                      "ID": "1003",
                      "Name": "Test Load",
                      "ModuleType": "anydb1003",
                      "ProductCode": "ANYDB",
                      "isAnyDbApp": true,
                      "isPremiumApp": false,
                      "isAPIApp": false
                    },
                    "ModuleType": "ANYDB",
                    "TimeZone": 0,
                    "DaylightSavings": false,
                    "DatabaseOwner": "",
                    "DatabaseServer": "db.internal.example.com",
                    "DatabaseLogin": "reporting",
                    "DatabaseName": "sales",
                    "DatabasePassword": "",
                    "DatabaseDriver": "POSTGRESQL",
                    "DatabasePlatform": "postgresql",
                    "CommandTimeout": 30,
                    "ConnectionTimeout": 10,
                    "Permissions": [],
                    "MappedAnyDB": "",
                    "DisplayName": "Test Load",
                    "allowstoredproc": 0,
                    "allowdirectsql": 0,
                    "datasources": [],
                    "additionalparams": ""
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppBuilder/GetAnyDbModule": {
      "post": {
        "operationId": "get-anydb-module",
        "summary": "Get an AnyDB app",
        "description": "Return an application's report types, including their SQL tables, joins and field trees. Responses are large — an app with a few hundred tables runs to several megabytes.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "moduleid": {
                    "type": "string",
                    "description": "The application's module ID."
                  },
                  "regserverid": {
                    "type": "string",
                    "description": "The registered server ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "moduleid",
                  "regserverid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "moduleid": "1003",
                "regserverid": "17769733521"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ReportTypes": [
                    {
                      "ErrorCode": 0,
                      "Moduleid": 1003,
                      "RepTypeID": 0,
                      "RepTypeName": "Sales_Orders",
                      "SQLTables": [
                        {
                          "tablename": "sales_orders",
                          "tableowner": "",
                          "tablealias": "Sales_Orders"
                        }
                      ],
                      "FieldTree": [
                        {
                          "id": 0,
                          "fname": "Data",
                          "flevel": "0",
                          "nodetype": "G",
                          "idx_order": 1
                        },
                        {
                          "id": 2,
                          "fname": "order_id",
                          "flevel": "0:2",
                          "nodetype": "F",
                          "tablealias": "Sales_Orders",
                          "sqlfieldname": "order_id",
                          "datatype": "cha",
                          "idx_order": 3
                        }
                      ]
                    }
                  ],
                  "DBSQLTableList": {
                    "AllDbtables": []
                  },
                  "isExcelCSV": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppBuilder/SaveAnyDbModule": {
      "post": {
        "operationId": "save-anydb-module",
        "summary": "Save an AnyDB app",
        "description": "Write report types to an application. Each report type in the payload is replaced in full; report types you leave out are untouched. Returns 1 on success and 0 otherwise, so confirm the result by reading the module back.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "anydbmodule": {
                    "type": "object",
                    "description": "The module payload containing the report types to write."
                  }
                },
                "required": [
                  "sessionToken",
                  "anydbmodule"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "anydbmodule": {
                  "ReportTypes": [],
                  "DBSQLTableList": {
                    "AllDbtables": []
                  },
                  "isExcelCSV": false,
                  "ApiEndpointList": null
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 1
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppBuilder/GetTableDef": {
      "post": {
        "operationId": "get-table-def",
        "summary": "Get a table definition",
        "description": "Return the columns of a database table as the driver reports them. datatype is the native database type, not a Yurbi field code.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "tablename": {
                    "type": "string",
                    "description": "The table to describe."
                  },
                  "tableowner": {
                    "type": "string",
                    "description": "Schema or owner. Send an empty string when the app registers tables without one."
                  },
                  "regserverid": {
                    "type": "string",
                    "description": "The registered server ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "tablename",
                  "regserverid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "tablename": "sales_orders",
                "tableowner": "",
                "regserverid": "17769733521"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "columnname": "order_id",
                    "datatype": "text",
                    "tablealias": null,
                    "MaxLength": 1,
                    "isNullValueAllowed": true
                  },
                  {
                    "columnname": "order_date",
                    "datatype": "timestamp without time zone",
                    "tablealias": null,
                    "MaxLength": 1,
                    "isNullValueAllowed": true
                  },
                  {
                    "columnname": "revenue",
                    "datatype": "real",
                    "tablealias": null,
                    "MaxLength": 24,
                    "isNullValueAllowed": true
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppBuilder/GetDataTypes": {
      "post": {
        "operationId": "get-data-types",
        "summary": "List field type codes",
        "description": "Return the Yurbi field type codes and what each one does. These codes appear throughout report metadata as Fieldtype and yurbitype.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "name": "cha",
                    "description": "Character type field",
                    "id": 1
                  },
                  {
                    "name": "num",
                    "description": "Integer and other numeric field types",
                    "id": 2
                  },
                  {
                    "name": "dat",
                    "description": "SQL datetime field",
                    "id": 4
                  },
                  {
                    "name": "doz",
                    "description": "sql date only field with no timezone conversions.",
                    "id": 28
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/GetReportTypes": {
      "post": {
        "operationId": "get-report-types",
        "summary": "List report types",
        "description": "List the report types available in an app. A report type is the semantic layer a report is built on — it defines which tables are in play and how they join. Every report belongs to exactly one, and a report references its report type by name, so names must stay unique within an app.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ModuleType": {
                    "type": "string",
                    "description": "The module type, e.g. ANYDB."
                  },
                  "RegServerID": {
                    "type": "string",
                    "description": "The app's RegServerID."
                  },
                  "ReportModuleID": {
                    "type": "string",
                    "description": "The app's ModuleID."
                  }
                },
                "required": [
                  "sessionToken",
                  "ModuleType",
                  "RegServerID",
                  "ReportModuleID"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ModuleType": "ANYDB",
                "RegServerID": "177340979543",
                "ReportModuleID": "1001"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "reporttypeid": 0,
                    "name": "Sales Pipeline Dataset",
                    "moduleid": 1001
                  },
                  {
                    "reporttypeid": 1,
                    "name": "Manufacturing Dataset",
                    "moduleid": 1001
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/RegServers/GetReportTree": {
      "post": {
        "operationId": "get-report-tree",
        "summary": "Get a report type's field tree",
        "description": "Return the browsable field tree for one report type: folders (type: \"Folder\") containing fields (type: \"Field\"). Each field node carries everything NewField needs — dbfieldname, dbtablealias, dbparenttablealias, fieldtype and Tag. Pass a node straight through to NewField to add it to a report.",
        "tags": [
          "App Builder"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "RegServerID": {
                    "type": "string",
                    "description": "The app's RegServerID."
                  },
                  "ReportType": {
                    "type": "string",
                    "description": "The report type's name."
                  }
                },
                "required": [
                  "sessionToken",
                  "RegServerID",
                  "ReportType"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "RegServerID": "177340979543",
                "ReportType": "Sales Pipeline Dataset"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "rootnode": {
                    "id": 0,
                    "text": "Sales Pipeline Dataset",
                    "type": "Folder",
                    "Tag": "RN",
                    "children": [
                      {
                        "id": 1,
                        "text": "Service Data",
                        "type": "Folder",
                        "Tag": "900000",
                        "children": [
                          {
                            "id": 2,
                            "text": "Ticket ID",
                            "type": "Field",
                            "Tag": "900001",
                            "dbfieldname": "Report_ID",
                            "dbtablealias": "Service Data",
                            "dbparenttablealias": "Service Data",
                            "fieldtype": "cha",
                            "ReportFieldName": "Ticket ID",
                            "children": []
                          }
                        ]
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/GetListByFolderID": {
      "post": {
        "operationId": "get-list-by-folder",
        "summary": "List a folder's contents",
        "description": "Return the reports and dashboards in a folder. itemtype identifies the kind of item — 0 is a dashboard and other values are report output types. item_flags is a JSON string rather than an object.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "LibraryID": {
                    "type": "string",
                    "description": "The folder ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "LibraryID"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "LibraryID": "2"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "id": 1776974455,
                    "ReportName": "Count of Records",
                    "ReportType": "Sales_Orders",
                    "AppDisplayName": "Test Load",
                    "ModType": "anydb1003",
                    "folderid": 2,
                    "folderpath": "",
                    "Published": "",
                    "Description": "Count of Records",
                    "PluginId": 0,
                    "error_code": 0,
                    "error_message": null,
                    "CreatedDate": "2026-04-23T20:00:55Z",
                    "CreatedBy": "Ferguson, David",
                    "ModifiedBy": "Ferguson, David",
                    "LastModified": "2026-04-23T20:00:51Z",
                    "Permissions": [],
                    "Application": "Test Load",
                    "isUserAdmin": true,
                    "isUserView": true,
                    "isUserModify": true,
                    "isUserDelete": true,
                    "itemtype": 1,
                    "itemsubtype": "",
                    "isFav": false,
                    "index": 0,
                    "isUserArchitect": true,
                    "isUserBuilder": true,
                    "isUserAgent": true,
                    "isPublicView": false,
                    "isEmbedable": false,
                    "isPrivate": false,
                    "item_flags": "{\"isLagacyMode\":0,\"visualizationOnly\":0,\"DisplayFullRecords\":0}"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/GetAllLibraryTree": {
      "post": {
        "operationId": "get-all-library-tree",
        "summary": "Get the library tree",
        "description": "Return the folder tree the calling user can see. Each entry wraps its tree under a rootnode key: the Public Library (libtype 1), the caller's personal library (libtype 2), and Favorites when includefav is true. isUserAdmin, isUserModify and isUserDelete describe what the caller may do in each folder.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "includefav": {
                    "type": "boolean",
                    "description": "Include the Favorites tree."
                  },
                  "includePersonal": {
                    "type": "boolean",
                    "description": "Include personal folders."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "includefav": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "rootnode": {
                      "id": 0,
                      "text": "Public Library",
                      "level": "###",
                      "libtype": 1,
                      "children": [
                        {
                          "id": 2,
                          "text": "Tenant A",
                          "children": [],
                          "level": "0",
                          "isUserAdmin": true,
                          "isUserModify": true,
                          "isUserDelete": true,
                          "isUserView": false,
                          "isPublicView": false,
                          "libtype": 1
                        }
                      ]
                    }
                  },
                  {
                    "rootnode": {
                      "id": 0,
                      "text": "My Library",
                      "children": [],
                      "level": "###",
                      "libtype": 2
                    }
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/NewLibraryFolder": {
      "post": {
        "operationId": "new-library-folder",
        "summary": "New folder template",
        "description": "Return an empty folder object ready to fill in and pass to Save a folder. The folder's name is the fname field.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "error_code": 0,
                  "error_message": "",
                  "ParentLibrary": null,
                  "id": 0,
                  "folderpath": null,
                  "fname": "New Folder",
                  "flevel": null,
                  "fmodtype": null,
                  "isParent": false,
                  "isHidden": false,
                  "InheritPermissions": false,
                  "Permissions": [],
                  "isUserAdmin": false,
                  "isUserView": false,
                  "isUserModify": false,
                  "isPublicView": false,
                  "isUserDelete": false,
                  "isPersonalFolder": false,
                  "isRestricted": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/SaveLibraryFolder": {
      "post": {
        "operationId": "save-library-folder",
        "summary": "Create or update a folder",
        "description": "Create or update a library folder. Set the name in fname. Scope the folder to security groups through the Permissions array: one entry per group, with RelationshipType and RelationType set to fld_grp, RightID set to the group ID, and PermissionTypeEnum 2. A folder with no group permissions is visible to All Users.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "libraryfolder": {
                    "type": "object",
                    "description": "The folder object. Start from New folder template."
                  },
                  "isShared": {
                    "type": "boolean",
                    "description": "True for a shared folder in the Public Library."
                  },
                  "currentUserId": {
                    "type": "string",
                    "description": "Owner for a personal folder."
                  }
                },
                "required": [
                  "sessionToken",
                  "libraryfolder"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "isShared": true,
                "currentUserId": "",
                "libraryfolder": {
                  "id": 0,
                  "fname": "Tenant A",
                  "isParent": false,
                  "isHidden": false,
                  "InheritPermissions": false,
                  "Permissions": [
                    {
                      "LeftID": "",
                      "RightID": "12",
                      "RelationshipType": "fld_grp",
                      "RelationType": "fld_grp",
                      "PermissionTypeEnum": 2
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "error_code": 0,
                  "error_message": "",
                  "ParentLibrary": null,
                  "id": 4,
                  "folderpath": "",
                  "fname": "Tenant A",
                  "flevel": ":4",
                  "fmodtype": "AHD",
                  "isParent": false,
                  "isHidden": false,
                  "InheritPermissions": false,
                  "Permissions": [
                    {
                      "ErrorCode": 0,
                      "ErrorMessage": "",
                      "LeftID": "4",
                      "RightID": "12",
                      "RelationshipType": "fld_grp",
                      "RelationType": "fld_grp",
                      "PermissionTypeEnum": 2
                    }
                  ],
                  "Application": null,
                  "isUserAdmin": true,
                  "isUserView": true,
                  "isUserModify": true,
                  "isPublicView": false,
                  "isUserDelete": true,
                  "isPersonalFolder": false,
                  "isRestricted": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/GetFolderById": {
      "post": {
        "operationId": "get-folder-by-id",
        "summary": "Get a folder",
        "description": "Return a single folder with its permission assignments.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "folderid": {
                    "type": "string",
                    "description": "The folder ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "folderid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "folderid": "4"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "error_code": 0,
                  "error_message": "",
                  "ParentLibrary": null,
                  "id": 4,
                  "folderpath": "",
                  "fname": "Tenant A",
                  "flevel": ":4",
                  "fmodtype": "AHD",
                  "isParent": false,
                  "isHidden": false,
                  "InheritPermissions": false,
                  "Permissions": [
                    {
                      "ErrorCode": 0,
                      "ErrorMessage": "",
                      "LeftID": "4",
                      "RightID": "12",
                      "RelationshipType": "fld_grp",
                      "RelationType": "fld_grp",
                      "PermissionTypeEnum": 2
                    }
                  ],
                  "Application": null,
                  "isUserAdmin": true,
                  "isUserView": true,
                  "isUserModify": true,
                  "isPublicView": false,
                  "isUserDelete": true,
                  "isPersonalFolder": false,
                  "isRestricted": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/DelFolder": {
      "post": {
        "operationId": "del-folder",
        "summary": "Delete a folder",
        "description": "Delete a library folder and its contents. Returns a {returncode, message} result reporting how many items were affected.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "folderid": {
                    "type": "string",
                    "description": "The folder ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "folderid"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "folderid": "4"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "returncode": 0,
                  "message": "Delete Action Complete: 1 affected"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/DelReport": {
      "post": {
        "operationId": "del-report",
        "summary": "Delete a report",
        "description": "Delete a report by ID. Returns 0 on success and 9000 on failure — the opposite of the numeric conventions used elsewhere.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ReportId": {
                    "type": "string",
                    "description": "The report's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "ReportId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ReportId": "1776974455"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 0
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/SearchReports": {
      "post": {
        "operationId": "search-reports",
        "summary": "Search reports",
        "description": "Search library items by name. Returns an array of matches, or an empty array when nothing matches.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "searchstring": {
                    "type": "string",
                    "description": "Text to match against item names."
                  }
                },
                "required": [
                  "sessionToken",
                  "searchstring"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "searchstring": "Revenue"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "id": 1776974455,
                    "ReportName": "Count of Records",
                    "ReportType": "Sales_Orders",
                    "AppDisplayName": "Test Load",
                    "ModType": "anydb1003",
                    "folderid": 2,
                    "folderpath": "",
                    "Published": "",
                    "Description": "Count of Records",
                    "PluginId": 0,
                    "error_code": 0,
                    "error_message": null,
                    "CreatedDate": "2026-04-23T20:00:55Z",
                    "CreatedBy": "Ferguson, David",
                    "ModifiedBy": "Ferguson, David",
                    "LastModified": "2026-04-23T20:00:51Z",
                    "Permissions": [],
                    "Application": "Test Load",
                    "isUserAdmin": true,
                    "isUserView": true,
                    "isUserModify": true,
                    "isUserDelete": true,
                    "itemtype": 1,
                    "itemsubtype": null,
                    "isFav": false,
                    "index": 0,
                    "isUserArchitect": true,
                    "isUserBuilder": true,
                    "isUserAgent": true,
                    "isPublicView": false,
                    "isEmbedable": false,
                    "isPrivate": false,
                    "item_flags": null
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Dashboard/SearchDashboardList": {
      "post": {
        "operationId": "search-dashboard-list",
        "summary": "Search dashboards",
        "description": "Search dashboards by name. Returns a compact list — note the field names differ from report search results.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "search": {
                    "type": "string",
                    "description": "Text to match. Send an empty string to list all."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "search": "Sales"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "id": 1,
                    "name": "Sales Overview",
                    "descr": "Tenant A sales",
                    "weight": 0,
                    "isFav": 1,
                    "isPersonal": 0
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/FavDash": {
      "post": {
        "operationId": "fav-dashboard",
        "summary": "Favourite a dashboard",
        "description": "Add a dashboard to the calling user's favourites. Takes DashboardId; the favourite is recorded against the session's user. Returns a number rather than an envelope. Confirm the change through isFav in Search dashboards.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "DashboardId": {
                    "type": "string",
                    "description": "The dashboard's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "DashboardId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "DashboardId": "1"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 0
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/UnFavDash": {
      "post": {
        "operationId": "unfav-dashboard",
        "summary": "Un-favourite a dashboard",
        "description": "Remove a dashboard from the calling user's favourites. Returns a number rather than an envelope. Confirm the change through isFav in Search dashboards.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "DashboardId": {
                    "type": "string",
                    "description": "The dashboard's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "DashboardId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "DashboardId": "1"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 1
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/FavReport": {
      "post": {
        "operationId": "fav-report",
        "summary": "Favourite a report",
        "description": "Add a report to the calling user's favourites. The favourite is recorded against the session's user, so no contact ID is needed. Returns a number rather than an envelope. Treat any 2xx response as accepted and confirm the change through isFav in Search reports.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ReportId": {
                    "type": "string",
                    "description": "The report's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "ReportId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ReportId": "1776974455"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 1
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/library/UnFavReport": {
      "post": {
        "operationId": "unfav-report",
        "summary": "Un-favourite a report",
        "description": "Remove a report from the calling user's favourites. Returns a number rather than an envelope. Treat any 2xx response as accepted and confirm the change through isFav in Search reports.",
        "tags": [
          "Library"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ReportId": {
                    "type": "string",
                    "description": "The report's ID."
                  }
                },
                "required": [
                  "sessionToken",
                  "ReportId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ReportId": "1776974455"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": 1
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/NewReport": {
      "post": {
        "operationId": "new-report",
        "summary": "New report template",
        "description": "Return an empty report object with every collection initialised, ready to fill in and pass to Save a report.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ReportID": null,
                  "Reportname": "New Report",
                  "ModType": null,
                  "ReportType": null,
                  "ServerName": null,
                  "Description": "",
                  "FieldList": [],
                  "Permissions": [],
                  "AdHocFields": [],
                  "linkreports": [],
                  "FormLayout": [],
                  "OutputType": 1,
                  "OutputTypeClass": null,
                  "Distinct": 0,
                  "TopN": null,
                  "folderid": 0
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/NewField": {
      "post": {
        "operationId": "new-field",
        "summary": "New report field",
        "description": "Turn a node from Get the report tree into a report field, filling in derived values such as RenamedField, the alias used in the generated SQL.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "field": {
                    "type": "object",
                    "description": "A Field node from the report tree."
                  },
                  "bAdvRpt": {
                    "type": "boolean",
                    "description": "True when building an advanced report."
                  }
                },
                "required": [
                  "sessionToken",
                  "field"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "bAdvRpt": false,
                "field": {
                  "id": 2,
                  "text": "order_id",
                  "type": "Field",
                  "Tag": "900001",
                  "dbfieldname": "order_id",
                  "dbtablealias": "Sales_Orders",
                  "dbparenttablealias": "Sales_Orders",
                  "fieldtype": "cha",
                  "ReportFieldName": "order_id",
                  "RenamedField": null,
                  "children": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "fieldindex": 0,
                  "DbParentTableAlias": "Sales_Orders",
                  "DbTableAlias": "Sales_Orders",
                  "DbFieldName": "order_id",
                  "DisplayFieldName": "Order",
                  "ReportFieldName": "Order",
                  "RenamedField": "Order",
                  "Fieldtype": "cha",
                  "SearchCriteria": "",
                  "strGroup": null,
                  "Formula": "",
                  "tbl5": "Y",
                  "grouped": 0,
                  "Criteria": null,
                  "ERROR_CODE": 0,
                  "ERROR_MESSAGE": ""
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/NewCriteria": {
      "post": {
        "operationId": "new-criteria",
        "summary": "New criteria template",
        "description": "Return an empty criteria object for a report field.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "field": {
                    "type": "object",
                    "description": "The field the criteria belongs to."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "Index": 0,
                  "Field": null,
                  "Op": null,
                  "Value1": null,
                  "Value2": null,
                  "Logical": null,
                  "Nested": false,
                  "cond": null,
                  "bskip": false,
                  "bprompt": false,
                  "sortorder": null,
                  "vrpt": null,
                  "vrpt_displaycol": null,
                  "vrpt_valuecol": null,
                  "vdefaulttop": 0,
                  "bgetvalues": false,
                  "flags": null
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/NewTotals": {
      "post": {
        "operationId": "new-totals",
        "summary": "New totals template",
        "description": "Return an empty totals object for a report field.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "type": {
                    "type": "string",
                    "description": "Totals type to pre-set on the returned object."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "type": null,
                  "func": null,
                  "field1": null,
                  "field2": null,
                  "Value2": null,
                  "percent": null,
                  "addgtotal": false
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/SaveReport": {
      "post": {
        "operationId": "save-report",
        "summary": "Create or update a report",
        "description": "Create a report or update an existing one. report.ReportID decides which: an empty string creates and the server returns the new ID; an existing ID updates. Build the object from New report template so its collections are populated, and set folderid to a folder the user can modify.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "report": {
                    "type": "object",
                    "description": "The report object, built from the template."
                  },
                  "processlinks": {
                    "type": "boolean",
                    "description": "Process linked reports on save. Defaults to true."
                  }
                },
                "required": [
                  "sessionToken",
                  "report"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "report": {
                  "ReportID": "",
                  "Reportname": "Orders by Customer",
                  "Description": "Created via the API",
                  "ModType": "anydb1003",
                  "ReportType": "Sales_Orders",
                  "ServerName": "db.internal.example.com",
                  "ModuleName": "Test Load",
                  "folderid": 2,
                  "OutputType": 1,
                  "OutputTypeClass": "datagrid",
                  "Distinct": 0,
                  "TopN": "0",
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": null,
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": []
                    }
                  ],
                  "linkreports": [],
                  "AdHocFields": [],
                  "FormLayout": [],
                  "Permissions": [
                    {
                      "RelationshipType": "rpt_grp",
                      "RelationType": "rpt_grp",
                      "LeftID": "1",
                      "RightID": "0",
                      "Option10": "1",
                      "PermissionTypeEnum": 1
                    }
                  ],
                  "flags": "{\"isLagacyMode\":0,\"visualizationOnly\":0,\"DisplayFullRecords\":0}"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ReportID": "1787843241",
                  "Reportname": "Orders by Customer",
                  "ModuleName": "Test Load",
                  "ModType": "anydb1003",
                  "ReportType": "Sales_Orders",
                  "folderid": 2,
                  "OutputType": 1,
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": null,
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": []
                    }
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/UpdateReport": {
      "post": {
        "operationId": "update-report",
        "summary": "Update a report",
        "description": "Update an existing report from a report object carrying its ReportID. The response echoes the fields supplied in the request, so send the complete object — most usefully the Report node from Get report metadata — rather than a partial one.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "report": {
                    "type": "object",
                    "description": "The report object to update, including its ReportID."
                  }
                },
                "required": [
                  "sessionToken",
                  "report"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "report": {
                  "ReportID": "1787843241",
                  "Reportname": "Orders by Customer",
                  "Description": "Updated via the API",
                  "ModType": "anydb1003",
                  "ReportType": "Sales_Orders",
                  "folderid": 2,
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": "/Sales_Orders/Order",
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": []
                    }
                  ],
                  "linkreports": [],
                  "Permissions": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ReportID": "1787843241",
                  "Reportname": "Orders by Customer",
                  "Description": "Updated via the API"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetReport": {
      "post": {
        "operationId": "get-report",
        "summary": "Get a report definition",
        "description": "Return a report's stored definition — fields, criteria, output settings, permissions and audit information. Connection fields such as DbLogin and DbPass are returned empty, and CreatedBy and LastModifiedBy are null on reports created before audit information was recorded.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ReportId": {
                    "type": "string",
                    "description": "The report's ID."
                  },
                  "isbuilder": {
                    "type": "boolean",
                    "description": "True when loading the report for editing."
                  }
                },
                "required": [
                  "sessionToken",
                  "ReportId"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ReportId": "1787843241",
                "isbuilder": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ReportID": "1787843241",
                  "Reportname": "Orders by Customer",
                  "ModuleName": "Test Load",
                  "ModType": "anydb1003",
                  "ReportType": "Sales_Orders",
                  "ServerName": "db.internal.example.com",
                  "DbLogin": "",
                  "DbPass": "",
                  "DbName": "",
                  "DbDriver": "",
                  "folderid": 2,
                  "OutputType": 1,
                  "OutputTypeClass": "datagrid",
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": "/Sales_Orders/Order",
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": []
                    }
                  ],
                  "Permissions": [],
                  "CreatedBy": {
                    "LoginName": "jsmith",
                    "FullName": "Jane Smith"
                  },
                  "LastModifiedBy": {
                    "LoginName": "jsmith",
                    "FullName": "Jane Smith"
                  },
                  "CreatedDate": "2026-04-23T20:00:55Z",
                  "LastModifiedDate": "2026-04-23T20:00:51Z"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetSQL": {
      "post": {
        "operationId": "get-sql",
        "summary": "Get generated SQL",
        "description": "Return the SQL a report object would generate, as a plain string. Prompt placeholders appear unresolved until prompts have been applied.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "Reportobj": {
                    "type": "object",
                    "description": "A report object — the Report node of a metadata response, or one you have assembled."
                  }
                },
                "required": [
                  "sessionToken",
                  "Reportobj"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "Reportobj": {
                  "ReportID": "1738259678",
                  "Reportname": "Tickets by Customer",
                  "ModuleName": "Ticket Data",
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "ModType": "anydb1009",
                  "ReportType": "Service Data",
                  "folderid": 2,
                  "OutputType": 1,
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": "/Sales_Orders/Order",
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": []
                    }
                  ],
                  "Permissions": [],
                  "linkreports": [],
                  "AdHocFields": []
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "Select \"Sales_Orders\".\"order_id\" AS \"Order\" From \"sales_orders\" \"Sales_Orders\"  Where 1=1 And ((\"Sales_Orders\".\"customer_id\" = 1115))"
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/ReportProcUI": {
      "post": {
        "operationId": "report-proc-ui",
        "summary": "Compile criteria",
        "description": "Compile a report's structured criteria into the SQL fragments the engine uses, and return the report object with those fragments filled in.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "db_platform": {
                    "type": "string",
                    "description": "Target platform, for example postgresql, oracle or mssql."
                  },
                  "report": {
                    "type": "object",
                    "description": "The report object whose criteria should be compiled."
                  }
                },
                "required": [
                  "sessionToken",
                  "db_platform",
                  "report"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "db_platform": "postgresql",
                "report": {
                  "ReportID": "",
                  "Reportname": "Preview",
                  "ModType": "anydb1003",
                  "ReportType": "Sales_Orders",
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DbParentTableAlias": "Sales_Orders",
                      "DbTableAlias": "Sales_Orders",
                      "DbFieldName": "order_id",
                      "DisplayFieldName": "Order",
                      "ReportFieldName": "Order",
                      "RenamedField": "Order",
                      "Fieldtype": "cha",
                      "SearchCriteria": "",
                      "strGroup": "/Sales_Orders/Order",
                      "Formula": "",
                      "tbl5": "Y",
                      "grouped": 0,
                      "Criteria": [
                        {
                          "Index": 0,
                          "Field": "Order",
                          "Op": "inlist",
                          "Value1": "D,O",
                          "Value2": "",
                          "Logical": "And",
                          "cond": "is",
                          "Nested": false
                        }
                      ]
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "FieldList": [
                    {
                      "fieldindex": 1,
                      "DisplayFieldName": "Order",
                      "SearchCriteria": "? In ('D','O')",
                      "tbl10": "? In ('D','O')",
                      "tbl11": "And"
                    }
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetSQLFunctions": {
      "post": {
        "operationId": "get-sql-functions",
        "summary": "List SQL functions",
        "description": "Return the SQL functions available for formula fields on a database platform. expression is the template, where ? stands for the field the formula is attached to.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "db_plat": {
                    "type": "string",
                    "description": "Database platform, for example postgresql, oracle or mssql."
                  }
                },
                "required": [
                  "sessionToken",
                  "db_plat"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "db_plat": "postgresql"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "id": "4",
                    "name": "SUM",
                    "description": "Sum of numeric values in a group; NULLs ignored.",
                    "expression": "SUM(?)",
                    "type": "Aggregate",
                    "dbplat": "4",
                    "rdatatype": "num",
                    "systemdefault": false,
                    "error_message": null
                  },
                  {
                    "id": "36",
                    "name": "UPPER",
                    "description": "Convert character data to uppercase.",
                    "expression": "UPPER(?)",
                    "type": "String",
                    "dbplat": "4",
                    "rdatatype": "cha",
                    "systemdefault": false,
                    "error_message": null
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetReportMetadataById": {
      "post": {
        "operationId": "get-report-metadata",
        "summary": "Get report metadata",
        "description": "Return the runtime metadata for a report: Report holds the definition and Prompts holds any prompts it defines. Prompts is null when the report has none. An unknown ID returns ErrorCode 586 with \"Report does not exist.\" inside Report. Dashboards are not reports and return the same error.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "ReportID": {
                    "type": "string",
                    "description": "The report's ID."
                  },
                  "isTarget": {
                    "type": "boolean",
                    "description": "True when loading a drill-down target."
                  },
                  "PreviousMetadata": {
                    "type": "object",
                    "description": "Prior metadata to carry forward. Send null."
                  },
                  "Criteria": {
                    "type": "string",
                    "description": "Additional criteria to apply. Send null."
                  }
                },
                "required": [
                  "sessionToken",
                  "ReportID"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "ReportID": "1738259678",
                "isTarget": false,
                "PreviousMetadata": null,
                "Criteria": null
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": null,
                      "HighValue": null
                    }
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetFieldValues": {
      "post": {
        "operationId": "get-field-values",
        "summary": "Get prompt values",
        "description": "Return the selectable values for a prompt as {key, val} pairs. For a date prompt the list contains relative expressions such as [Today] and [Last Month], which are intended for interface pickers; send an explicit date when setting the value through the API.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "Reportobj": {
                    "type": "object",
                    "description": "The metadata object the prompt belongs to."
                  },
                  "Prompt": {
                    "type": "object",
                    "description": "The prompt to list values for."
                  }
                },
                "required": [
                  "sessionToken",
                  "Reportobj",
                  "Prompt"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "Reportobj": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": null,
                      "HighValue": null
                    }
                  ]
                },
                "Prompt": {
                  "HasError": false,
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "PromptField": {
                    "fieldindex": 3,
                    "DbParentTableAlias": "Service Data",
                    "DbTableAlias": "Service Data",
                    "DbFieldName": "customer_id",
                    "DisplayFieldName": "Customer ID",
                    "ReportFieldName": "Customer ID",
                    "Fieldtype": "num",
                    "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                    "strGroup": "/Service Data/Customer ID",
                    "RenamedField": "Customer_ID",
                    "Criteria": [
                      {
                        "Index": 0,
                        "Field": "Customer ID",
                        "Op": "=",
                        "Value1": "1115",
                        "Value2": "",
                        "Logical": "And",
                        "cond": "is",
                        "bskip": false,
                        "bprompt": true,
                        "bgetvalues": true,
                        "sortorder": "None"
                      }
                    ]
                  },
                  "isSkipable": false,
                  "isBetween": false,
                  "isInList": false,
                  "isLike": false,
                  "isGreaterThan": false,
                  "isLessThan": false,
                  "isSkipped": false,
                  "LowValue": null,
                  "HighValue": null
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "key": "1115",
                    "val": "1115"
                  },
                  {
                    "key": "1006",
                    "val": "1006"
                  },
                  {
                    "key": "1043",
                    "val": "1043"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/ReplacePrompt": {
      "post": {
        "operationId": "replace-prompt",
        "summary": "Apply one prompt",
        "description": "Apply a value for a single prompt and return the updated metadata. Only the prompt you pass is compiled into the report's criteria, so for a report with several prompts call this once per prompt, passing the previous response back in as Reportobj each time. Set the value on LowValue, and HighValue as well when isBetween is true. The applied value appears in the returned Report, compiled into that field's criteria; the Prompts array is echoed back as it was supplied in Reportobj. Return the prompt object otherwise unchanged: it is matched to its field by table alias, field name, display name and field index.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "Reportobj": {
                    "type": "object",
                    "description": "The metadata object, or the response from the previous call in the chain."
                  },
                  "Prompt": {
                    "type": "object",
                    "description": "One prompt with its value set."
                  }
                },
                "required": [
                  "sessionToken",
                  "Reportobj",
                  "Prompt"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "Reportobj": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": null,
                      "HighValue": null
                    }
                  ]
                },
                "Prompt": {
                  "HasError": false,
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "PromptField": {
                    "fieldindex": 3,
                    "DbParentTableAlias": "Service Data",
                    "DbTableAlias": "Service Data",
                    "DbFieldName": "customer_id",
                    "DisplayFieldName": "Customer ID",
                    "ReportFieldName": "Customer ID",
                    "Fieldtype": "num",
                    "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                    "strGroup": "/Service Data/Customer ID",
                    "RenamedField": "Customer_ID",
                    "Criteria": [
                      {
                        "Index": 0,
                        "Field": "Customer ID",
                        "Op": "=",
                        "Value1": "1115",
                        "Value2": "",
                        "Logical": "And",
                        "cond": "is",
                        "bskip": false,
                        "bprompt": true,
                        "bgetvalues": true,
                        "sortorder": "None"
                      }
                    ]
                  },
                  "isSkipable": false,
                  "isBetween": false,
                  "isInList": false,
                  "isLike": false,
                  "isGreaterThan": false,
                  "isLessThan": false,
                  "isSkipped": false,
                  "LowValue": null,
                  "HighValue": null
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": "1115",
                      "HighValue": ""
                    }
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/ReplacePromptCollection": {
      "post": {
        "operationId": "replace-prompt-collection",
        "summary": "Apply all prompts",
        "description": "Apply values for every prompt on a report in one call and return the metadata with those values compiled into the report's criteria. Set each value on the prompt's LowValue, and HighValue as well when isBetween is true. Send the Prompts array in the same order and length as the metadata returned it: values are matched to prompts by position.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "Reportobj": {
                    "type": "object",
                    "description": "The metadata object from Get report metadata."
                  },
                  "Prompts": {
                    "type": "array",
                    "description": "The prompts with values set, in the order metadata returned them."
                  }
                },
                "required": [
                  "Reportobj",
                  "Prompts"
                ]
              },
              "example": {
                "Reportobj": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": null,
                      "HighValue": null
                    }
                  ]
                },
                "Prompts": [
                  {
                    "HasError": false,
                    "ErrorCode": 0,
                    "ErrorMessage": null,
                    "PromptField": {
                      "fieldindex": 3,
                      "DbParentTableAlias": "Service Data",
                      "DbTableAlias": "Service Data",
                      "DbFieldName": "customer_id",
                      "DisplayFieldName": "Customer ID",
                      "ReportFieldName": "Customer ID",
                      "Fieldtype": "num",
                      "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                      "strGroup": "/Service Data/Customer ID",
                      "RenamedField": "Customer_ID",
                      "Criteria": [
                        {
                          "Index": 0,
                          "Field": "Customer ID",
                          "Op": "=",
                          "Value1": "1115",
                          "Value2": "",
                          "Logical": "And",
                          "cond": "is",
                          "bskip": false,
                          "bprompt": true,
                          "bgetvalues": true,
                          "sortorder": "None"
                        }
                      ]
                    },
                    "isSkipable": false,
                    "isBetween": false,
                    "isInList": false,
                    "isLike": false,
                    "isGreaterThan": false,
                    "isLessThan": false,
                    "isSkipped": false,
                    "LowValue": "1115",
                    "HighValue": ""
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": "1115",
                      "HighValue": ""
                    }
                  ]
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetReportData": {
      "post": {
        "operationId": "get-report-data",
        "summary": "Run a report",
        "description": "Execute a report and return its rows. Reportobj must be the complete metadata object from Get report metadata, with prompts applied when the report has any. Rows are in Data, one object per row keyed by column, and Columns describes each column. Check HasError rather than ErrorCode on this endpoint: a failed execution returns HasError: true with the message in ErrorMessage while ErrorCode stays 0. The response also carries interface bindings such as jqxColumns, and etime, the execution time in milliseconds.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "Reportobj": {
                    "type": "object",
                    "description": "The prepared metadata object."
                  },
                  "IsDrillDown": {
                    "type": "boolean",
                    "description": "Whether this is a drill-down run. Defaults to false."
                  },
                  "DrillDownCriteria": {
                    "type": "object",
                    "description": "Criteria for a drill-down; null otherwise."
                  },
                  "TargetReportobj": {
                    "type": "object",
                    "description": "Target report for a drill-down; null otherwise."
                  },
                  "supressprompts": {
                    "type": "boolean",
                    "description": "Run without applying prompts, returning the unfiltered result."
                  },
                  "cacheok": {
                    "type": "boolean",
                    "description": "Allow a cached result to be returned."
                  }
                },
                "required": [
                  "sessionToken",
                  "Reportobj"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "IsDrillDown": false,
                "DrillDownCriteria": null,
                "Reportobj": {
                  "Report": {
                    "ReportID": "1738259678",
                    "Reportname": "Tickets by Customer",
                    "ModuleName": "Ticket Data",
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "ModType": "anydb1009",
                    "ReportType": "Service Data",
                    "folderid": 2,
                    "OutputType": 1,
                    "FieldList": [
                      {
                        "fieldindex": 1,
                        "DbParentTableAlias": "Sales_Orders",
                        "DbTableAlias": "Sales_Orders",
                        "DbFieldName": "order_id",
                        "DisplayFieldName": "Order",
                        "ReportFieldName": "Order",
                        "RenamedField": "Order",
                        "Fieldtype": "cha",
                        "SearchCriteria": "",
                        "strGroup": "/Sales_Orders/Order",
                        "Formula": "",
                        "tbl5": "Y",
                        "grouped": 0,
                        "Criteria": []
                      }
                    ],
                    "Permissions": [],
                    "linkreports": [],
                    "AdHocFields": []
                  },
                  "Prompts": [
                    {
                      "HasError": false,
                      "ErrorCode": 0,
                      "ErrorMessage": null,
                      "PromptField": {
                        "fieldindex": 3,
                        "DbParentTableAlias": "Service Data",
                        "DbTableAlias": "Service Data",
                        "DbFieldName": "customer_id",
                        "DisplayFieldName": "Customer ID",
                        "ReportFieldName": "Customer ID",
                        "Fieldtype": "num",
                        "SearchCriteria": "? = Prompt for:Customer ID#:#num#:##:#",
                        "strGroup": "/Service Data/Customer ID",
                        "RenamedField": "Customer_ID",
                        "Criteria": [
                          {
                            "Index": 0,
                            "Field": "Customer ID",
                            "Op": "=",
                            "Value1": "1115",
                            "Value2": "",
                            "Logical": "And",
                            "cond": "is",
                            "bskip": false,
                            "bprompt": true,
                            "bgetvalues": true,
                            "sortorder": "None"
                          }
                        ]
                      },
                      "isSkipable": false,
                      "isBetween": false,
                      "isInList": false,
                      "isLike": false,
                      "isGreaterThan": false,
                      "isLessThan": false,
                      "isSkipped": false,
                      "LowValue": null,
                      "HighValue": null
                    }
                  ]
                },
                "TargetReportobj": null
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": "",
                  "HasError": false,
                  "ReportID": "1738259678",
                  "OutputType": 1,
                  "Columns": [
                    {
                      "headerText": "Customer",
                      "key": "Customer_ID",
                      "dataType": "number",
                      "width": 0,
                      "dataFormatString": null,
                      "yurbitype": "num",
                      "columngroup": ""
                    },
                    {
                      "headerText": "Tickets",
                      "key": "Ticket_ID",
                      "dataType": "number",
                      "width": 0,
                      "dataFormatString": null,
                      "yurbitype": "num",
                      "columngroup": ""
                    }
                  ],
                  "Data": [
                    {
                      "Customer_ID": 1115,
                      "Ticket_ID": 10
                    }
                  ],
                  "GroupMetadata": [],
                  "groups": [],
                  "IsFromCache": false,
                  "IsTopLevel": true,
                  "ContainsDrilldown": false,
                  "etime": "79",
                  "dbtime": null
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Report/GetOutputTypes": {
      "post": {
        "operationId": "get-output-types",
        "summary": "List output types",
        "description": "Return the output types a report can use. id is the value carried by a report's OutputType and by itemtype in library listings; uiclass is the matching interface class.",
        "tags": [
          "Reports"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "id": 1,
                    "name": "DataGrid",
                    "uiclass": "datagrid"
                  },
                  {
                    "id": 2,
                    "name": "Chart",
                    "uiclass": "chart"
                  },
                  {
                    "id": 3,
                    "name": "KPI Text",
                    "uiclass": "kpi_metric"
                  },
                  {
                    "id": 4,
                    "name": "KPI Gauge",
                    "uiclass": "kpi_gauge"
                  },
                  {
                    "id": 6,
                    "name": "Pie Chart",
                    "uiclass": "pie-chart"
                  },
                  {
                    "id": 7,
                    "name": "Combo Chart",
                    "uiclass": "combochart"
                  },
                  {
                    "id": 8,
                    "name": "Pivot Grid",
                    "uiclass": "pivotgrid"
                  },
                  {
                    "id": 9,
                    "name": "Tree Map",
                    "uiclass": "treemap"
                  },
                  {
                    "id": 10,
                    "name": "Vector Map",
                    "uiclass": "vectormap"
                  },
                  {
                    "id": 11,
                    "name": "Skyline",
                    "uiclass": "skyline"
                  },
                  {
                    "id": 12,
                    "name": "Aggregate Grid",
                    "uiclass": "datagrid2"
                  },
                  {
                    "id": 13,
                    "name": "Adv Pivot Grid",
                    "uiclass": "pivotgrid2"
                  },
                  {
                    "id": 14,
                    "name": "Chartv2",
                    "uiclass": "chart2"
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/SMTP/GetSMTP": {
      "post": {
        "operationId": "get-smtp",
        "summary": "Get SMTP configuration",
        "description": "Return the instance's outgoing mail configuration. SMTPPassword is always returned empty. The settings are nested inside a realm; SMTPRealm.SMTPSetting is null on the master realm.",
        "tags": [
          "Email (SMTP)"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "SMTPId": "177341830687",
                  "SMTPHost": "smtp.example.com",
                  "SMTPPort": "587",
                  "SMTPFromAddress": "reports@example.com",
                  "SMTPRequiredSecurity": "True",
                  "SMTPUserName": "reports@example.com",
                  "SMTPPassword": "",
                  "SMTPCreated": "03/13/2026 16:11:46",
                  "SMTPModified": "03/13/2026 16:11:46",
                  "SMTPEnableSSL": "True",
                  "SMTPRealm": {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "RealmId": "1",
                    "RealmName": "MASTER",
                    "RealmDescription": "This is a default realm. Cannot be edited.",
                    "RealmCreated": "2009-06-29T00:00:00",
                    "RealmModified": "2009-06-29T00:00:00",
                    "ProviderList": [],
                    "SMTPSetting": null
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/SMTP/SaveSMTP": {
      "post": {
        "operationId": "save-smtp",
        "summary": "Save SMTP configuration",
        "description": "Create or update the outgoing mail configuration. Read the current settings with Get SMTP configuration, change what you need, and send the whole object back. Supply SMTPPassword whenever SMTPRequiredSecurity is true, since it is never returned by a read.",
        "tags": [
          "Email (SMTP)"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "smtp": {
                    "type": "object",
                    "description": "The SMTP configuration object."
                  }
                },
                "required": [
                  "sessionToken",
                  "smtp"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "smtp": {
                  "SMTPId": "177341830687",
                  "SMTPHost": "smtp.example.com",
                  "SMTPPort": "587",
                  "SMTPFromAddress": "reports@example.com",
                  "SMTPRequiredSecurity": "True",
                  "SMTPUserName": "reports@example.com",
                  "SMTPPassword": "YOUR_SMTP_PASSWORD",
                  "SMTPEnableSSL": "True"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "SMTPId": "177341830687",
                  "SMTPHost": "smtp.example.com",
                  "SMTPPort": "587",
                  "SMTPFromAddress": "reports@example.com",
                  "SMTPRequiredSecurity": "True",
                  "SMTPUserName": "reports@example.com",
                  "SMTPPassword": "",
                  "SMTPCreated": "03/13/2026 16:11:46",
                  "SMTPModified": "03/13/2026 16:11:46",
                  "SMTPEnableSSL": "True",
                  "SMTPRealm": {
                    "ErrorCode": 0,
                    "ErrorMessage": "",
                    "RealmId": "1",
                    "RealmName": "MASTER",
                    "RealmDescription": "This is a default realm. Cannot be edited.",
                    "RealmCreated": "2009-06-29T00:00:00",
                    "RealmModified": "2009-06-29T00:00:00",
                    "ProviderList": [],
                    "SMTPSetting": null
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/SMTP/DeleteSMTP": {
      "post": {
        "operationId": "delete-smtp",
        "summary": "Delete SMTP configuration",
        "description": "Remove the outgoing mail configuration. Takes the whole configuration object under smtp, so read it first with Get SMTP configuration.",
        "tags": [
          "Email (SMTP)"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "smtp": {
                    "type": "object",
                    "description": "The SMTP configuration object to remove."
                  }
                },
                "required": [
                  "sessionToken",
                  "smtp"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "smtp": {
                  "SMTPId": "177341830687"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "ErrorCode": 0,
                  "ErrorMessage": null,
                  "SMTPId": null,
                  "SMTPHost": null,
                  "SMTPPort": null,
                  "SMTPFromAddress": null,
                  "SMTPRequiredSecurity": null,
                  "SMTPUserName": null,
                  "SMTPPassword": null,
                  "SMTPRealm": null,
                  "SMTPEnableSSL": null
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppSettings/GetAppSettings": {
      "post": {
        "operationId": "get-app-settings",
        "summary": "Get instance settings",
        "description": "Return the instance's configuration: session timeout, record limits, tenant mode, single sign-on, two-factor settings and scheduler concurrency. Boolean values are returned as the strings \"True\" and \"False\".",
        "tags": [
          "Instance Settings"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "DebugLevel": 0,
                  "SESSION_TIMEOUT": 20,
                  "PROMPT_VALUES_LIMIT": 10000,
                  "SSOEnabled": "True",
                  "SSOHeader": "ssoheadertoken",
                  "IIS_PASSTHROUGH_ENABLED": "False",
                  "TENANT_MODE_ENABLED": "False",
                  "USERTZ_MODE_ENABLED": "False",
                  "GUEST_FASTCACHE": "False",
                  "FastCacheMin": 30,
                  "duo_clientid": "",
                  "duo_clientsecret": "",
                  "duo_apihost": "",
                  "duo_redirect": "",
                  "duo_enabled": "False",
                  "bulkemail_enabled": "False",
                  "sqlnolocks": "False",
                  "SchedulerMode": 8,
                  "MaxRecords": 500000,
                  "Productname": "Yurbi",
                  "enableallusersgrp": "False",
                  "enforcestrongpassword": "False"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/AppSettings/SaveAppSettings": {
      "post": {
        "operationId": "save-app-settings",
        "summary": "Save instance settings",
        "description": "Update instance configuration. Read the current settings first, change what you need, and send the whole object back — omitted values are not preserved.",
        "tags": [
          "Instance Settings"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "appsettings": {
                    "type": "object",
                    "description": "The complete settings object."
                  }
                },
                "required": [
                  "sessionToken",
                  "appsettings"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "appsettings": {
                  "DebugLevel": 0,
                  "SESSION_TIMEOUT": 20,
                  "PROMPT_VALUES_LIMIT": 10000,
                  "SSOEnabled": "True",
                  "SSOHeader": "ssoheadertoken",
                  "IIS_PASSTHROUGH_ENABLED": "False",
                  "TENANT_MODE_ENABLED": "False",
                  "USERTZ_MODE_ENABLED": "False",
                  "GUEST_FASTCACHE": "False",
                  "FastCacheMin": 30,
                  "duo_clientid": "",
                  "duo_clientsecret": "",
                  "duo_apihost": "",
                  "duo_redirect": "",
                  "duo_enabled": "False",
                  "bulkemail_enabled": "False",
                  "sqlnolocks": "False",
                  "SchedulerMode": 8,
                  "MaxRecords": 500000,
                  "Productname": "Yurbi",
                  "enableallusersgrp": "False",
                  "enforcestrongpassword": "False"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "DebugLevel": 0,
                  "SESSION_TIMEOUT": 20,
                  "PROMPT_VALUES_LIMIT": 10000,
                  "SSOEnabled": "True",
                  "SSOHeader": "ssoheadertoken",
                  "IIS_PASSTHROUGH_ENABLED": "False",
                  "TENANT_MODE_ENABLED": "False",
                  "USERTZ_MODE_ENABLED": "False",
                  "GUEST_FASTCACHE": "False",
                  "FastCacheMin": 30,
                  "duo_clientid": "",
                  "duo_clientsecret": "",
                  "duo_apihost": "",
                  "duo_redirect": "",
                  "duo_enabled": "False",
                  "bulkemail_enabled": "False",
                  "sqlnolocks": "False",
                  "SchedulerMode": 8,
                  "MaxRecords": 500000,
                  "Productname": "Yurbi",
                  "enableallusersgrp": "False",
                  "enforcestrongpassword": "False"
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Audit/GetAuditTypes": {
      "post": {
        "operationId": "get-audit-types",
        "summary": "Get audit settings",
        "description": "Return every auditable event with whether it is recorded and how long it is retained. recorded is -1 when the event is captured and 0 when it is not; retention is in days.",
        "tags": [
          "Instance Settings"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ID": 1,
                    "type": 0,
                    "symbol": "Login Success",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 2,
                    "type": 1,
                    "symbol": "Login Failure",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 7,
                    "type": 6,
                    "symbol": "Report Execution",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 16,
                    "type": 15,
                    "symbol": "Report Execution SQL",
                    "recorded": 0,
                    "retention": 365,
                    "options": ""
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/Audit/SaveAuditTypes": {
      "post": {
        "operationId": "save-audit-types",
        "summary": "Save audit settings",
        "description": "Update which events are audited and how long each is retained. Send the full list as returned by Get audit settings, with recorded and retention adjusted.",
        "tags": [
          "Instance Settings"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  },
                  "AuditTypeList": {
                    "type": "array",
                    "description": "The complete list of audit types with their settings."
                  }
                },
                "required": [
                  "sessionToken",
                  "AuditTypeList"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN",
                "AuditTypeList": [
                  {
                    "ID": 1,
                    "type": 0,
                    "symbol": "Login Success",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 2,
                    "type": 1,
                    "symbol": "Login Failure",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 7,
                    "type": 6,
                    "symbol": "Report Execution",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 16,
                    "type": 15,
                    "symbol": "Report Execution SQL",
                    "recorded": 0,
                    "retention": 365,
                    "options": ""
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": [
                  {
                    "ID": 1,
                    "type": 0,
                    "symbol": "Login Success",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 2,
                    "type": 1,
                    "symbol": "Login Failure",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 7,
                    "type": 6,
                    "symbol": "Report Execution",
                    "recorded": -1,
                    "retention": 365,
                    "options": ""
                  },
                  {
                    "ID": 16,
                    "type": 15,
                    "symbol": "Report Execution SQL",
                    "recorded": 0,
                    "retention": 365,
                    "options": ""
                  }
                ]
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/LicenseManager/RefreshInstalledLicenses": {
      "post": {
        "operationId": "refresh-licenses",
        "summary": "Refresh licences",
        "description": "Re-read installed licence keys from the licence service and update the instance's entitlements.",
        "tags": [
          "Licensing"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sessionToken": {
                    "type": "string",
                    "description": "A valid session token."
                  }
                },
                "required": [
                  "sessionToken"
                ]
              },
              "example": {
                "sessionToken": "YOUR_SESSION_TOKEN"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": {
                  "returncode": 0,
                  "message": ""
                }
              }
            }
          }
        },
        "security": [
          {
            "sessionToken": []
          }
        ]
      }
    },
    "/api/LicenseManager/GetInstallationID": {
      "post": {
        "operationId": "get-installation-id",
        "summary": "Get installation ID",
        "description": "Return the instance's installation identifier as a plain string, formatted as six groups of four digits. This endpoint does not require a session token — it is used during activation, before anyone can sign in.",
        "tags": [
          "Licensing"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {}
              },
              "example": {}
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "example": "4446-4836-3034-3631-4452-3666"
              }
            }
          }
        }
      }
    }
  }
}
