components:
  parameters:
    connectionID:
      description: ID of the private connection
      in: path
      name: connectionID
      required: true
      schema:
        format: uuid
        type: string
    fields:
      description: Comma-separated values list that correspond to the filtered fields
        for returned entities
      in: query
      name: fields
      schema:
        type: string
    jobID:
      description: ID of the job
      example: 7b68b78d-a3cc-4153-9b56-0864fd331524
      in: path
      name: jobID
      required: true
      schema:
        format: uuid
        type: string
    organizationID:
      description: ID of the organization
      in: path
      name: organizationID
      required: true
      schema:
        format: uuid
        type: string
    secretID:
      description: ID of the secret
      in: path
      name: secretID
      required: true
      schema:
        format: uuid
        type: string
    teamID:
      description: ID of the team
      in: path
      name: teamID
      required: true
      schema:
        format: uuid
        type: string
    workspaceGroupID:
      description: ID of the workspace group
      in: path
      name: workspaceGroupID
      required: true
      schema:
        format: uuid
        type: string
    workspaceID:
      description: ID of the workspace
      in: path
      name: workspaceID
      required: true
      schema:
        format: uuid
        type: string
  schemas:
    AuditLog:
      description: Represents an audit log entry
      properties:
        attributes:
          description: additional keys and values that are specific to the audit log
            type
          type: object
        auditID:
          example: 17290909-0000-1000-9000-e30410f1b05a
          format: uuid
          type: string
        clusterID:
          description: The database cluster tied to this event
          format: uuid
          type: string
        createdAt:
          description: The timestamp of when the audit log entry was created in RFC3339Nano
            format
          type: string
        error:
          description: text error message, if any relating to this entry
          example: ""
          type: string
        firstName:
          description: The first name of a redacted user
          type: string
        labels:
          description: A list of audit keywords
          example:
          - featureflag
          items:
            type: string
          type: array
        lastName:
          description: The last name of a redacted user
          type: string
        orgID:
          description: The organization tied to this event
          format: uuid
          type: string
        projectID:
          description: The project id tied to this event
          format: uuid
          type: string
        reason:
          description: A human-readable description of what happened
          example: feature flag (ssoLogin) enabled for all orgs
          type: string
        sessionID:
          description: the authorization session id tied to this event
          format: uuid
          type: string
        source:
          description: The audit log entry source
          enum:
          - Portal
          - Admin
          - SystemJob
          example: Portal
          type: string
        teamID:
          description: The tem id tied to this event
          format: uuid
          type: string
        type:
          description: The audit log entry type
          example: Login
          type: string
        userEmail:
          description: The user email address
          example: user@email.com
          type: string
        userID:
          description: The user ID
          example: 17290909-0000-1000-9000-e30410f1b05a
          type: string
        userType:
          description: the type of user that triggered the audit log entry
          enum:
          - Unspecified
          - System
          - Employee
          - Customer
          - Automation
          - Studio
          - CIAutomation
          - SharedTier
          example: Customer
          type: string
        workspaceID:
          description: The workspace id tied to this event
          format: uuid
          type: string
      type: object
    BillingUsage:
      description: Represents the information related to billing usage
      properties:
        description:
          description: A description of what the metric represents
          type: string
        metric:
          description: The metric type
          type: string
        usage:
          description: Usage information
          items:
            properties:
              endTime:
                description: The end time of the interval
                example: 2024-06-01 09:00:00 +0000 UTC
                type: string
              ownerId:
                description: ID of the owner of the resource
                example: 78af2f46-0000-1000-9000-3f6f5365d878
                type: string
              resourceId:
                description: ID of the resource
                example: 78af2f46-0000-1000-9000-3f6f5365d878
                type: string
              resourceName:
                description: Name of the resource
                example: test-workspace
                type: string
              resourceType:
                description: The resource type
                example: Workspace
                type: string
              startTime:
                description: The start time of the interval
                example: 2024-06-01 08:00:00 +0000 UTC
                type: string
              value:
                description: Resource usage value
                example: "30.00"
                type: string
            type: object
          type: array
      type: object
    EgressClusterIdentityCreate:
      description: Represents the information specified to create an egress cluster
        identity
      properties:
        catalogInfo:
          description: Catalog information for creating the egress cluster identity
          type: object
        storageInfo:
          description: Storage information for creating the egress cluster identity
          type: object
      required:
      - storageInfo
      - catalogInfo
      type: object
    Execution:
      properties:
        executionID:
          description: The ID of execution
          format: uuid
          type: string
        executionNumber:
          description: Number of the execution
          example: 1
          type: integer
        finishedAt:
          description: Finish time of the execution
          format: date-time
          nullable: true
          type: string
        jobID:
          description: ID of the job that this execution belongs to
          format: uuid
          type: string
        scheduledStartTime:
          description: Scheduled start time of the execution
          format: date-time
          type: string
        snapshotNotebookPath:
          description: Path to the notebook which captures the result of this execution
          nullable: true
          type: string
        startedAt:
          description: Actual start time of the execution
          format: date-time
          nullable: true
          type: string
        status:
          enum:
          - Unknown
          - Scheduled
          - Running
          - Completed
          - Failed
          - Error
          - Canceled
          example: Scheduled
          type: string
      required:
      - executionID
      - jobID
      - status
      - scheduledStartTime
      - executionNumber
      type: object
    ExecutionsMetadata:
      properties:
        endExecutionNumber:
          example: 10
          type: integer
        startExecutionNumber:
          example: 1
          type: integer
      required:
      - startExecutionNumber
      - endExecutionNumber
      type: object
    ExecutionsResult:
      properties:
        executions:
          items:
            $ref: '#/components/schemas/Execution'
          type: array
        executionsMetadata:
          $ref: '#/components/schemas/ExecutionsMetadata'
      required:
      - executions
      - executionsMetadata
      type: object
    FileLocationSchema:
      description: The file location can be either 'personal' or 'shared'
      enum:
      - personal
      - shared
      example: personal
      type: string
    FileObjectMetadata:
      description: Represents the metadata corresponding to a file object
      properties:
        content:
          oneOf:
          - example: Hello World!
            type: string
          - example: []
            items:
              $ref: '#/components/schemas/FileObjectMetadata'
            type: array
        created:
          example: "2023-09-08T17:35:43Z"
          type: string
        format:
          description: Format of the response
          enum:
          - json
          nullable: true
          type: string
        last_modified:
          example: "2023-09-08T17:35:43Z"
          type: string
        mimetype:
          type: string
        name:
          description: Name of the file object
          example: file.json
          type: string
        path:
          description: Path of the file object
          example: parent_folder/sample_folder/file.json
          type: string
        size:
          example: 32
          type: integer
        type:
          description: Object type
          enum:
          - ""
          - json
          - directory
          nullable: true
          type: string
        writable:
          type: boolean
      type: object
    Job:
      properties:
        completedExecutionsCount:
          description: Count of completed executions for the job
          example: 10
          type: integer
        createdAt:
          description: Creation time of the job
          format: date-time
          type: string
        description:
          description: Description of the job
          example: Sample Description
          nullable: true
          type: string
        enqueuedBy:
          description: ID of the user who created the job
          format: uuid
          type: string
        executionConfig:
          $ref: '#/components/schemas/JobExecutionConfig'
        jobID:
          description: ID of the job
          format: uuid
          type: string
        jobMetadata:
          description: Array containing information about the max/avg execution duration
            and the number of executions with a particular status for the job
          items:
            $ref: '#/components/schemas/JobMetadata'
          type: array
        name:
          description: Name of the job
          example: Sample Job
          nullable: true
          type: string
        schedule:
          $ref: '#/components/schemas/JobSchedule'
        targetConfig:
          $ref: '#/components/schemas/JobTargetConfig'
        terminatedAt:
          description: Termination time of the job
          format: date-time
          nullable: true
          type: string
      required:
      - jobID
      - enqueuedBy
      - executionConfig
      - schedule
      - createdAt
      - completedExecutionsCount
      - jobMetadata
      type: object
    JobCreate:
      description: Represents the information specified when creating a job.
      properties:
        description:
          description: Description of the job
          example: Job Description
          nullable: true
          type: string
        executionConfig:
          properties:
            createSnapshot:
              description: Indicates whether the job will save snapshots
              type: boolean
            notebookPath:
              description: Path to the shared notebook file that contains the code
                that needs to be run on a schedule as part of this job
              example: sample_notebook.ipynb
              type: string
            runtimeName:
              description: Name of the runtime
              example: notebooks-cpu-small
              nullable: true
              type: string
          required:
          - notebookPath
          - createSnapshot
          type: object
        name:
          description: Name of the job
          example: Job Name
          nullable: true
          type: string
        parameters:
          description: Array containing the parameters for the job
          items:
            $ref: '#/components/schemas/JobParameter'
          type: array
        schedule:
          $ref: '#/components/schemas/JobSchedule'
        targetConfig:
          $ref: '#/components/schemas/JobTargetConfig'
      required:
      - name
      - executionConfig
      - schedule
      type: object
    JobExecutionConfig:
      properties:
        createSnapshot:
          description: Indicates whether the job will save snapshots
          example: true
          type: boolean
        maxAllowedExecutionDurationInMinutes:
          description: Maximum allowed execution duration for the job in minutes
          example: 30
          type: integer
        notebookPath:
          description: Path to the shared notebook file that contains the code that
            needs to be run on a schedule as part of this job
          example: sample_notebook.ipynb
          type: string
      required:
      - notebookPath
      - createSnapshot
      - maxAllowedExecutionDurationInMinutes
      type: object
    JobMetadata:
      properties:
        avgDurationInSeconds:
          description: Average duration of executions (in seconds) with the corresponding
            status
          example: 3.21
          format: float
          nullable: true
          type: number
        count:
          description: The number of executions with the corresponding status
          example: 10
          type: integer
        maxDurationInSeconds:
          description: Maximum duration of executions (in seconds) with the corresponding
            status
          example: 7.73
          format: float
          nullable: true
          type: number
        status:
          enum:
          - Unknown
          - Scheduled
          - Running
          - Completed
          - Failed
          - Error
          - Canceled
          example: Completed
          type: string
      required:
      - status
      - count
      type: object
    JobParameter:
      properties:
        name:
          description: Name of the parameter
          example: foo
          type: string
        type:
          description: Type of the parameter
          enum:
          - string
          - integer
          - float
          - boolean
          example: integer
          type: string
        value:
          description: Value of the parameter
          example: "10"
          type: string
      required:
      - name
      - value
      - type
      type: object
    JobSchedule:
      properties:
        executionIntervalInMinutes:
          description: The time interval between executions of this job. This is required
            for a Recurring job.
          example: 60
          nullable: true
          type: integer
        mode:
          enum:
          - Recurring
          - Once
          type: string
        startAt:
          description: The time at which the first execution of this job should begin.
          format: date-time
          nullable: true
          type: string
      required:
      - mode
      type: object
    JobTargetConfig:
      nullable: true
      properties:
        databaseName:
          description: Name of the database
          example: sample_db
          type: string
        resumeTarget:
          description: Indicates whether executions of this job will resume the target
            associated with the job, if it is suspended
          example: true
          type: boolean
        targetID:
          description: The target ID for the job, this could be the ID of Workspace,
            Cluster or VirtualWorkspace (in case of shared-tier).
          format: uuid
          type: string
        targetType:
          enum:
          - Workspace
          - Cluster
          - VirtualWorkspace
          type: string
      required:
      - targetType
      - targetID
      - resumeTarget
      type: object
    Organization:
      description: Represents information related to an organization
      properties:
        firewallRanges:
          description: The list of allowed IP addresses which can access the Management
            API
          items:
            type: string
          type: array
        name:
          description: Name of the organization
          type: string
        orgID:
          description: ID of the organization
          format: uuid
          type: string
      required:
      - orgID
      type: object
    PrivateConnection:
      description: Represents information related to a private link connection
      properties:
        activeAt:
          description: The timestamp of when the private connection became active
          example: "2023-09-18T09:56:56Z"
          type: string
        allowList:
          description: The private connection allow list. This is the account ID for
            AWS,  subscription ID for Azure, and the project name GCP
          example: my-allow-list
          type: string
        createdAt:
          description: The timestamp of when the private connection was created
          example: "2023-09-18T09:56:56Z"
          type: string
        deletedAt:
          description: The timestamp of when the private connection was deleted
          example: "2023-09-18T09:56:56Z"
          type: string
        endpoint:
          description: The service endpoint
          example: com.amazonaws.vpce.us-east-1.vpce-svc-08e20961f648f9d
          type: string
        outboundAllowList:
          description: The account ID which must be allowed for outbound connections
          example: arn:aws:iam:xxxxxxxxx:root
          type: string
        privateConnectionID:
          description: The ID of the private connection
          example: 8900372e-0000-1000-9000-4c47638040af
          format: uuid
          type: string
        serviceName:
          description: The name of the private connection service
          example: My service
          type: string
        status:
          description: The status of the private connection
          enum:
          - PENDING
          - ACTIVE
          - DELETED
          example: ACTIVE
          type: string
        type:
          description: The private connection type
          enum:
          - INBOUND
          - OUTBOUND
          example: INBOUND
          type: string
        updatedAt:
          description: The timestamp of when the private connection was last updated
          example: "2023-09-18T09:56:56Z"
          type: string
        workspaceGroupID:
          description: The ID of the workspace group containing the private connection
          example: 68af2f46-0000-1000-9000-3f6f5365d878
          format: uuid
          type: string
        workspaceID:
          description: The ID of the workspace to connect with
          example: 7d6b3a5a-0000-1000-9000-d454af4c785b
          format: uuid
          type: string
      required:
      - privateConnectionID
      - workspaceGroupID
      type: object
    PrivateConnectionCreate:
      description: Represents the information specified when creating a private connection
      properties:
        allowList:
          description: The private connection allow list
          example: my-allow-list
          type: string
        kaiEndpointID:
          description: VPC Endpoint ID for AWS
          example: vpce-12345678901234567
          type: string
        serviceName:
          description: The name of the private connection service
          example: My private link
          type: string
        sqlPort:
          description: The SQL port
          example: 3306
          type: number
        type:
          description: The private connection type
          enum:
          - INBOUND
          - OUTBOUND
          example: INBOUND
          type: string
        websocketsPort:
          description: The websockets port
          example: 443
          type: number
        workspaceGroupID:
          description: The ID of the workspace group containing the private connection
          example: 68af2f46-0000-1000-9000-3f6f5365d878
          format: uuid
          type: string
        workspaceID:
          description: The ID of the workspace to connect with
          format: uuid
          type: string
      required:
      - workspaceGroupID
      type: object
    PrivateConnectionKaiInfo:
      description: Represents the information for creating private connection to SingleStore
        Kai
      properties:
        serviceName:
          description: VPC Endpoint Service Name for AWS
          example: com.amazonaws.vpce.us-east-1.vpce-svc-0123456789abcdefg
          type: string
      type: object
    PrivateConnectionOutboundAllowList:
      description: Represents information related to a private connection outbound
        allow list
      properties:
        outboundAllowList:
          description: The account ID allowed for outbound connections
          example: arn:aws:iam:xxxxxxxxx:root
          type: string
      type: object
    PrivateConnectionUpdate:
      description: Represents the information specfied when updating a private connection
      properties:
        allowList:
          description: The private connection allow list
          example: my-allow-list
          type: string
      type: object
    Region:
      description: Represents information related to a region in which a workspace
        group is created
      properties:
        provider:
          description: Name of the provider
          enum:
          - AWS
          - GCP
          - Azure
          type: string
        region:
          description: Name of the region
          type: string
        regionID:
          description: ID of the region
          format: uuid
          type: string
      required:
      - regionID
      - region
      - provider
      type: object
    ReplicatedDatabase:
      description: Represents information related to a database's replication status
      properties:
        databaseName:
          description: Name of the database
          type: string
        duplicationState:
          description: Duplication state of the database
          enum:
          - Pending
          - Active
          - Inactive
          - Error
          type: string
        region:
          description: Name of the region
          type: string
      required:
      - databaseName
      - region
      - duplicationState
      type: object
    RuntimesResult:
      properties:
        description:
          description: The description of the runtime
          example: 1750m vCPU | 15Gi
          type: string
        name:
          description: The name of the runtime
          example: notebooks-cpu-small
          type: string
      required:
      - name
      - description
      type: object
    Secret:
      description: Represents information related to SingleStore Helios secrets.
      properties:
        createdAt:
          description: The timestamp of when the secret was created.
          example: "2023-09-18T09:56:56Z"
          type: string
        createdBy:
          description: The ID of the user that created the secret.
          example: 17290909-0000-1000-9000-e30410f1b05a
          format: uuid
          type: string
        deletedAt:
          description: The timestamp of when the secret was deleted.
          example: "2023-09-18T09:56:56Z"
          type: string
        deletedBy:
          description: The ID of the user that deleted the secret.
          example: 17290909-0000-1000-9000-e30410f1b05a
          format: uuid
          type: string
        lastUpdatedAt:
          description: The timestamp of when the secret was last updated.
          example: "2023-09-18T09:56:56Z"
          type: string
        lastUpdatedBy:
          description: The ID of the user that last updated the secret.
          example: 17290909-0000-1000-9000-e30410f1b05a
          format: uuid
          type: string
        name:
          description: The name of the secret. It can only contain alphanumeric characters
            or underscores.
          example: my_secret
          type: string
        secretID:
          description: The ID of the secret.
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          format: uuid
          type: string
        value:
          description: The value of the secret.
          example: my_secret_value
          type: string
      required:
      - secretID
      - name
      - createdAt
      - createdBy
      - lastUpdatedAt
      - lastUpdatedBy
      type: object
    SecretCreate:
      description: Represents the information specified when creating a secret.
      properties:
        name:
          description: The name of the secret. It can only contain alphanumeric characters
            or underscores.
          example: my_secret
          type: string
        value:
          description: The value of the secret.
          example: my_secret_value
          type: string
      required:
      - name
      - value
      type: object
    SecretUpdate:
      description: Represents the information specified when updating a secret.
      properties:
        value:
          description: The value of the secret.
          example: my_secret_value
          type: string
      type: object
    SharedTierUpdateUser:
      description: Represents the information specified when updating a user in a
        shared tier workspace
      properties:
        password:
          description: The virtual workspace user password to connect the new user
            to the database.
          example: My-password1!
          type: string
      type: object
    StorageDRSetup:
      description: Represents the information specified to setup Storage DR
      properties:
        autoReplication:
          description: |
            If set to true, all existing and future databases created will be automatically replicated to the secondary region. If set to false, turns off auto replication.
          type: boolean
        backupBucketKMSKeyID:
          description: |
            Specifies the KMS key ID associated with the backup bucket. If specified, enables Customer-Managed Encryption Keys (CMEK) encryption for the backup bucket of the secondary workspace group. This feature is only supported in workspace groups deployed in AWS.
          type: string
        dataBucketKMSKeyID:
          description: |
            Specifies the KMS key ID associated with the data bucket. If specified, enables Customer-Managed Encryption Keys (CMEK) encryption for the data bucket and Amazon Elastic Block Store (EBS) volumes of the secondary workspace group. This feature is only supported in workspace groups deployed in AWS.
          type: string
        databaseNames:
          description: List of database names (can be an empty list if setting up
            Auto-Replication).
          items:
            example: x_db
            type: string
          type: array
        regionID:
          description: Region ID of the secondary region
          format: uuid
          type: string
      required:
      - regionID
      - databaseNames
      type: object
    StorageDRStatus:
      description: Represents Storage DR status information
      properties:
        compute:
          description: Represents information related to a workspace group's latest
            storage DR operation
          properties:
            completedAttachments:
              description: The number of database attachments that have been setup
              type: integer
            completedWorkspaces:
              description: The number of workspaces that have been setup
              type: integer
            storageDRState:
              description: Status of Storage DR operation
              enum:
              - Active
              - Completed
              - Failed
              - Expired
              - Canceled
              type: string
            storageDRType:
              description: Name of Storage DR operation
              enum:
              - Failover
              - Failback
              - PreProvisionStart
              - PreProvisionStop
              type: string
            totalAttachments:
              description: The total number of database attachments to setup
              type: integer
            totalWorkspaces:
              description: The total number of workspaces to setup
              type: integer
          required:
          - storageDRType
          - storageDRState
          - totalWorkspaceBuildTasks
          - totalDatabaseAttachTasks
          - completedWorkspaceBuildTasks
          - completedDatabaseAttachTasks
          type: object
        storage:
          items:
            $ref: '#/components/schemas/ReplicatedDatabase'
          type: array
      required:
      - compute
      - storage
      type: object
    TableEgressStart:
      description: Represents the information specified to start egressing data from
        a table
      properties:
        catalogInfo:
          description: Catalog information for egressing data
          type: object
        columnNames:
          items:
            description: The names of the columns to egress
            example: column1
            type: string
          type: array
        databaseName:
          description: The name of the database
          example: sample_db
          type: string
        storageInfo:
          description: Storage information for egressing data
          type: object
        tableName:
          description: The name of the table
          example: sample_table
          type: string
      required:
      - databaseName
      - tableName
      - columnNames
      - storageInfo
      - catalogInfo
      type: object
    TableEgressStatus:
      description: Represents the status of egress operation
      properties:
        status:
          description: The status of the egress operation
          example: Running
          type: string
        statusMsg:
          description: The status message of the egress operation
          type: string
      required:
      - status
      type: object
    TableEgressStatusParams:
      description: Represents the status of egressing data from a table
      properties:
        egressID:
          description: The ID of the egress operation
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          type: string
      required:
      - egressID
      type: object
    Team:
      description: A SingleStoreDB Cloud team.
      example:
        createdAt: "2023-09-18T09:56:56Z"
        description: All analysts in the abc.com organization
        memberTeams:
        - description: ""
          name: APAC Analysts
          teamID: 3a6fd5c9-616c-4dea-b41c-92eb1d442889
        memberUsers:
        - email: jane.doe@abc.com
          firstName: Jane
          lastName: Doe
          userID: 121e74be-6b93-44ac-b240-9be663f680de
        - email: jack.smith@abc.com
          firstName: Jack
          lastName: Smith
          userID: a69181f0-8d64-4b31-a516-ce1b6483edd4
        name: Analysts
        teamID: c74bb6a6-0000-1000-9000-1d874fa277b0
      properties:
        createdAt:
          description: Team creation timestamp.
          example: "2023-09-18T09:56:56Z"
          type: string
        description:
          description: Team description.
          example: All analysts in the abc.com organization
          type: string
        memberTeams:
          items:
            $ref: '#/components/schemas/TeamInfo'
          type: array
        memberUsers:
          items:
            $ref: '#/components/schemas/UserInfo'
          type: array
        name:
          description: Team name.
          example: Analysts
          type: string
        teamID:
          description: Team identifier.
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          format: uuid
          type: string
      required:
      - teamID
      - name
      - description
      type: object
    TeamCreate:
      description: Information specified when creating a team.
      properties:
        description:
          description: Optional team description.
          example: All analysts in the abc.com organization
          type: string
        name:
          description: Team name.
          example: Analysts
          type: string
      required:
      - name
      type: object
    TeamInfo:
      description: Summary information about a SingleStoreDB Cloud team.
      properties:
        description:
          description: Team description.
          example: All analysts in the abc.com organization
          type: string
        name:
          description: Team name.
          example: Analysts
          type: string
        teamID:
          description: Team identifier.
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          format: uuid
          type: string
      required:
      - teamID
      - name
      - description
      type: object
    TeamUpdate:
      description: Information specified when updating a team.
      properties:
        addMemberTeamIDs:
          description: List of identifiers of teams to be added as members.
          items:
            example: c74bb6a6-0000-1000-9000-1d874fa277b0
            format: uuid
            type: string
          type: array
        addMemberUserIDs:
          description: List of identifiers of users to be added as members.
          items:
            example: 121e74be-6b93-44ac-b240-9be663f680de
            format: uuid
            type: string
          type: array
        description:
          description: Team description.
          example: All analysts in the abc.com organization
          type: string
        name:
          description: Team name.
          example: Analysts
          type: string
        removeMemberTeamIDs:
          description: List of identifiers of teams to be removed from members.
          items:
            example: c74bb6a6-0000-1000-9000-1d874fa277b0
            format: uuid
            type: string
          type: array
        removeMemberUserIDs:
          description: List of identifiers of users to be removed from members.
          items:
            example: 121e74be-6b93-44ac-b240-9be663f680de
            format: uuid
            type: string
          type: array
      type: object
    UpdateWindow:
      description: Represents information related to an update window
      properties:
        day:
          description: Day of week (0-6), starting on Sunday
          example: 2
          type: number
        hour:
          description: Hour of day - 0 to 23 (UTC)
          example: 1
          type: number
      required:
      - hour
      - day
      type: object
    UserInfo:
      description: Summary information about a SingleStoreDB Cloud user.
      properties:
        email:
          description: The email address of the user.
          example: jane.doe@abc.com
          type: string
        firstName:
          description: First name of the user.
          example: Jane
          type: string
        lastName:
          description: Last name of the user.
          example: Doe
          type: string
        userID:
          description: User identifier.
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          format: uuid
          type: string
      required:
      - userID
      - email
      - firstName
      - lastName
      type: object
    Workspace:
      description: Represents information related to a workspace
      properties:
        autoSuspend:
          description: (If included in the output) Represents the current auto suspend
            settings enabled for this workspace. If autoSuspend has an empty value,
            then the auto suspend settings are disabled
          properties:
            idleAfterSeconds:
              description: (If included in the output) The duration (in seconds) the
                workspace must be inactive until it automatically suspends
              type: number
            idleChangedAt:
              description: (If included in the output) The timestamp when idleAfterSeconds
                was last changed
              type: string
            scheduledChangedAt:
              description: (If included in the output) The timestamp when scheduledSuspendAt
                was last changed
              type: string
            scheduledSuspendAt:
              description: (If included in the output) The timestamp when the workspace
                will be suspended
              type: string
            suspendType:
              description: The type of auto suspend currently enabled
              enum:
              - IDLE
              - SCHEDULED
              type: string
            suspendTypeChangedAt:
              description: (If included in the output) The timestamp when suspendType
                was last changed
              type: string
          required:
          - suspendType
          type: object
        cacheConfig:
          description: |
            Specifies the multiplier for the persistent cache associated with the workspace. It can have one of the following values: 1, 2, or 4.
          type: number
        createdAt:
          description: The timestamp of when the workspace was created
          type: string
        deploymentType:
          description: |
            Specifies the deployment type for the workspace. It can have one of the following values: `PRODUCTION` or `NON-PRODUCTION`. If the value wasn't changed on creation, then the default will be `PRODUCTION`. If set to `NON-PRODUCTION`, the upgrades are only applied to the non-production workspaces.
          enum:
          - PRODUCTION
          - NON-PRODUCTION
          type: string
        endpoint:
          description: Endpoint to connect to the workspace
          type: string
        kaiEnabled:
          description: Specifies if the workspace is kai enabled or not.
          type: boolean
        lastResumedAt:
          description: (If included in the output) The timestamp of when the workspace
            was last resumed
          type: string
        name:
          description: Name of the workspace
          type: string
        resumeAttachments:
          description: (If included in the output) The result of database attachments
            after the workspace was resumed
          items:
            description: Represents information related to database attachments
            properties:
              attachment:
                description: The type of attachment
                enum:
                - READWRITE
                - READONLY
                type: string
              database:
                description: Name of the database
                type: string
              error:
                description: The error if the attachment was not successful
                type: string
              success:
                description: Whether the attachment was successful or not
                type: boolean
            required:
            - database
            - attachment
            - success
            type: object
          type: array
        scaleFactor:
          description: |
            (If included in the output) The scale factor specified for the workspace. The scale factor can be 1, 2 or 4.
          type: number
        scalingProgress:
          description: (If included in the output) The current progress percentage
            for the scaling workspace
          type: number
        size:
          description: |
            Size of the workspace (in workspace size notation), such as "S-00" or "S-1"
          type: string
        state:
          description: State of the workspace
          enum:
          - ACTIVE
          - PENDING
          - SUSPENDED
          - FAILED
          - TERMINATED
          type: string
        terminatedAt:
          description: (If included in the output) The timestamp of when the workspace
            was terminated
          type: string
        workspaceGroupID:
          description: ID of the workspace group containing the workspace
          format: uuid
          type: string
        workspaceID:
          description: ID of the workspace
          format: uuid
          type: string
      required:
      - name
      - workspaceID
      - workspaceGroupID
      - size
      - state
      - createdAt
      type: object
    WorkspaceCreate:
      description: Represents the information specified while creating a workspace
      properties:
        autoSuspend:
          description: Auto suspend settings for the workspace. If this field is not
            provided, no settings will be enabled.
          properties:
            suspendAfterSeconds:
              description: When to suspend the workspace, according to the suspend
                type chosen
              example: 1200
              type: number
            suspendType:
              description: The auto suspend mode for the workspace can have the values
                `IDLE`, `SCHEDULED`, or `DISABLED` (to create the workspace with no
                auto suspend settings).
              enum:
              - IDLE
              - SCHEDULED
              - DISABLED
              example: IDLE
              type: string
          type: object
        cacheConfig:
          description: |
            Specifies the multiplier for the persistent cache associated with the workspace. If specified, it enables the cache configuration multiplier. It can have one of the following values: 1, 2, or 4.
          example: 2
          type: number
        enableKai:
          description: Whether to create a SingleStore Kai-enabled workspace
          type: boolean
        name:
          description: Name of the workspace
          example: demo-workspace
          type: string
        scaleFactor:
          description: "Specifies the scale factor for scaling the workspace base
            size. \nWhen specified, the compute resources are scaled in proportion
            to the specified scale factor, while the disk remains unaffected. \nConsequently,
            the credit consumption is also increased proportionately. \nIt can have
            one of the following values: 1, 2, or 4. \nFor more information, refer
            to [Workspace Scaling](https://docs.singlestore.com/cloud/getting-started-with-singlestore-helios/about-workspaces/workspace-scaling/).\n"
          example: 2
          type: number
        size:
          description: |
            Size of the workspace (in workspace size notation), such as "S-1". The default value is "S-00".
          example: S-2
          type: string
        workspaceGroupID:
          description: ID of the workspace group in which the workspace is created
          example: c74bb6a6-0000-1000-9000-1d874fa277b0
          format: uuid
          type: string
      required:
      - name
      - workspaceGroupID
      type: object
    WorkspaceGroup:
      description: Represents information related to a workspace group
      properties:
        allowAllTraffic:
          description: Whether or not all traffic is allowed to the workspace group
          type: boolean
        createdAt:
          description: The timestamp of when the workspace was created
          type: string
        expiresAt:
          description: The timestamp of when the workspace group will expire. At expiration,
            the workspace group is terminated and all the data is lost.
          type: string
        firewallRanges:
          description: The list of allowed inbound IP addresses. An empty list indicates
            that no inbound requests are allowed.
          items:
            type: string
          type: array
        name:
          description: Name of the workspace group
          type: string
        regionID:
          description: ID of the region
          format: uuid
          type: string
        smartDRStatus:
          description: The status of Smart Disaster Recovery (SmartDR) for the workspace
            group. For more information, refer to [the documentation](https://docs.singlestore.com/cloud/manage-data/smart-disaster-recovery-dr-smartdr/).
          enum:
          - ACTIVE
          - STANDBY
          type: string
        state:
          description: State of the workspace group
          enum:
          - ACTIVE
          - PENDING
          - FAILED
          - TERMINATED
          type: string
        terminatedAt:
          description: (If included in the output) The timestamp of when the workspace
            group was terminated
          type: string
        updateWindow:
          $ref: '#/components/schemas/UpdateWindow'
        workspaceGroupID:
          description: ID of the workspace group
          format: uuid
          type: string
      required:
      - name
      - state
      - workspaceGroupID
      - createdAt
      - regionID
      type: object
    WorkspaceGroupCreate:
      description: Represents the information specified while creating a workspace
        group
      properties:
        adminPassword:
          description: |
            The admin password for the workspace group. The password must contain:

              * At least 8 characters
              * At least one uppercase character
              * At least one lowercase character
              * At least one number or special character

            If a password is not specified while creating a workspace group, a password is generated and returned in the response object.
          example: ""
          type: string
        allowAllTraffic:
          description: If enabled, allows all traffic to the workspace group.
          type: boolean
        backupBucketKMSKeyID:
          description: |
            Specifies the KMS key ID associated with the backup bucket. If specified, enables Customer-Managed Encryption Keys (CMEK) encryption for the backup bucket of the workspace group. This feature is only supported in workspace groups deployed in AWS.
          type: string
        dataBucketKMSKeyID:
          description: "Specifies the KMS key ID associated with the data bucket.
            If specified, enables Customer-Managed Encryption Keys (CMEK) encryption
            for the data bucket and Amazon Elastic Block Store (EBS) volumes of the
            workspace group. This feature is only supported in workspace groups deployed
            in AWS. \n"
          type: string
        expiresAt:
          description: |
            The timestamp of when the workspace group will expire. If the expiration time is not specified, the workspace group will have no expiration time. At expiration, the workspace group is terminated and all the data is lost. Expiration time can be specified as a timestamp or duration. For example,

              * "2023-09-02T15:04:05Z07:00"
              * "2023-09-02T15:04:05-0700"
              * "2023-09-02T15:04:05"
              * "2023-09-02"
              * "3h30m"
          example: ""
          type: string
        firewallRanges:
          description: |
            A list of allowed CIDR ranges. An empty list indicates that no inbound requests are allowed. Required
          example:
          - 192.168.0.1/32
          - 192.168.0.81/12
          items:
            type: string
          type: array
        name:
          description: Name of the workspace group
          example: demo-workspace-group
          type: string
        regionID:
          description: ID of the region where the new workspace group is created
          example: 7e7ffd27-0000-1000-9000-e72828a81ac7
          format: uuid
          type: string
        updateWindow:
          $ref: '#/components/schemas/UpdateWindow'
      required:
      - name
      - regionID
      - firewallRanges
      type: object
    WorkspaceGroupUpdate:
      description: Represents the information specified while updating a workspace
        group
      properties:
        adminPassword:
          description: |
            The admin password for the workspace group. The password must contain:

              * At least 8 characters
              * At least one uppercase character
              * At least one lowercase character
              * At least one number or special character
          example: ""
          type: string
        allowAllTraffic:
          description: Whether to allow all traffic to the workspace group
          type: boolean
        expiresAt:
          description: |
            The timestamp of when the workspace group will expire. If the expiration time is not specified, the workspace group will have no expiration time. At expiration, the workspace group is terminated and all the data is lost. Expiration time can be specified as a timestamp or duration. For example,

              * "2023-09-02T15:04:05Z07:00"
              * "2023-09-02T15:04:05-0700"
              * "2023-09-02T15:04:05"
              * "2023-09-02"
              * "3h30m"
          example: ""
          type: string
        firewallRanges:
          description: A list of allowed CIDR ranges. An empty list indicates that
            no inbound requests are allowed.
          example:
          - 192.168.0.1/32
          - 192.168.0.81/12
          items:
            type: string
          type: array
        name:
          description: Name of the workspace group
          example: new-workspace-group-name
          type: string
        updateWindow:
          $ref: '#/components/schemas/UpdateWindow'
      type: object
    WorkspaceResume:
      description: Represents additional information specified when resuming a workspace
      properties:
        disableAutoSuspend:
          description: Whether to disable auto suspend or keep the existing auto suspend
            settings. By default, `disableAutoSuspend` is set to `false`, and the
            existing auto suspend settings are preserved.
          example: false
          type: boolean
      type: object
    WorkspaceUpdate:
      description: Represents the information specified while updating a workspace
      properties:
        autoSuspend:
          description: 'Specifies the auto suspend mode for the workspace. It can
            have one of the following values: `IDLE`, `SCHEDULED`, or `DISABLED`.'
          properties:
            suspendAfterSeconds:
              description: The time interval (in seconds) after which the workspace
                is suspended, depending on the auto suspend mode.
              example: 1200
              type: number
            suspendType:
              description: The type of auto suspend mode. Set to `DISABLED` to disable
                auto suspend.
              enum:
              - IDLE
              - SCHEDULED
              - DISABLED
              example: IDLE
              type: string
          type: object
        cacheConfig:
          description: |
            Specifies the multiplier for the persistent cache associated with the workspace. If specified, it enables the cache configuration multiplier. It can have one of the following values: 1, 2, or 4.
          example: 2
          type: number
        deploymentType:
          description: The deployment type that will be applied to all the workspaces
            within the group
          enum:
          - PRODUCTION
          - NON-PRODUCTION
          example: PRODUCTION
          type: string
        enableKai:
          description: Whether to enable SingleStore Kai in this workspace
          enum:
          - true
          - false
          type: boolean
        scaleFactor:
          description: "Specifies the scale factor for scaling the workspace base
            size. \nWhen specified, the compute resources are scaled in proportion
            to the specified scale factor, while the disk remains unaffected.\nConsequently,
            the credit consumption is also increased proportionately. \nIt can have
            one of the following values: 1, 2, or 4. \nFor more information, refer
            to [Workspace Scaling](https://docs.singlestore.com/cloud/getting-started-with-singlestore-helios/about-workspaces/workspace-scaling/).\n"
          example: 2
          type: number
        size:
          description: |
            Size of the workspace (in workspace size notation), such as "S-1". The default value is "S-00".
          example: S-2
          type: string
      type: object
  securitySchemes:
    ApiKeyAuth:
      bearerFormat: API key
      description: |
        For information on authenticating your API requests, refer to [`Management` API Overview](https://docs.singlestore.com/managed-service/en/reference/management-api.html).
      scheme: bearer
      type: http
info:
  contact:
    name: SingleStore Support
    url: https://www.singlestore.com/support/
  description: |
    The `Management` API can be used to create and manage workspaces, workspace groups, private connections, etc. SingleStore recommends reading the [`Management` API Overview](https://docs.singlestore.com/managed-service/en/reference/management-api.html) before getting started with the API reference.

    All the URLs referenced in this API documentation use the `https://api.singlestore.com` service endpoint as their base.
  title: SingleStore Management API
  version: 1.1.93
openapi: 3.0.0
paths:
  /v1/auditLogs:
    get:
      description: Returns a list of all of the audit log entries for the user organization
        or audit logs for user redaction
      parameters:
      - description: The audit log type
        in: query
        name: type
        schema:
          type: string
      - description: The audit log source
        in: query
        name: source
        schema:
          type: string
      - description: The start date (inclusive) for the query in RFC3339 format (2019-10-12T07:20:50.52Z)
        in: query
        name: startDate
        schema:
          type: string
      - description: The end date (inclusive) for the query in RFC3339 format (2019-10-12T07:20:50.52Z)
        in: query
        name: endDate
        schema:
          type: string
      - description: The maximum number of rows to return
        in: query
        name: limit
        schema:
          type: number
      - description: The value of the nextToken returned from a previous query. This
          will guarantee the next results are new since the last query
        in: query
        name: nextToken
        schema:
          type: string
      - description: A first name to match against
        in: query
        name: firstName
        schema:
          type: string
      - description: A last name to match against
        in: query
        name: lastName
        schema:
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  auditLogs:
                    items:
                      $ref: '#/components/schemas/AuditLog'
                    type: array
                  nextToken:
                    description: The nextToken value can be used in a subsequent query
                      to guarantee any log entries are new since this query
                    type: string
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists all of the audit logs for the user organization or audit logs
        for user redaction
      tags:
      - AuditLogs
  /v1/billing/usage:
    description: The `usage` endpoint under billing can report compute and storage
      usage.
    get:
      description: |
        Returns the compute and storage usage of an organization in a specified timeframe. The results can be grouped by hour, day, and month using the `aggregateType` parameter. The usage entries in the result set also include information on the resource ID, type, name, and usage.
      parameters:
      - description: "The metric type. It can have the following values:\n\n  * `ComputeCredit`:
          Returns the compute usage. \n  * `StorageAvgByte`: Returns the storage usage.
          \n\nBy default, usage for both metrics is returned.\n"
        in: query
        name: metric
        schema:
          enum:
          - ComputeCredit
          - StorageAvgByte
          type: string
      - description: |
          The start time for the usage interval in UTC ISO8601 format. For example, "2023-07-30T18:30:00Z".
        in: query
        name: startTime
        required: true
        schema:
          type: string
      - description: |
          The end time for the usage interval in UTC ISO8601 format. For example, "2023-07-30T18:30:00Z".
        in: query
        name: endTime
        required: true
        schema:
          type: string
      - description: |
          The interval used to aggregate the usage. It can have the following values: `hour`, `day`, and `month`. By default, the results are grouped by hour."
        in: query
        name: aggregateBy
        schema:
          enum:
          - hour
          - day
          - month
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  billingUsage:
                    items:
                      $ref: '#/components/schemas/BillingUsage'
                    type: array
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Returns the compute and storage usage of an organization
      tags:
      - Billing
  /v1/files/fs/{location}:
    get:
      description: |
        Returns a list of all files from the personal or shared space.

        You must specify the `location`.
      parameters:
      - description: Location of the files
        in: path
        name: location
        required: true
        schema:
          $ref: '#/components/schemas/FileLocationSchema'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileObjectMetadata'
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists all files from a personal or shared space.
      tags:
      - Files
  /v1/files/fs/{location}/{path}:
    delete:
      description: |
        Deletes the file at the specified path in a personal or shared space.

        You must specify the `location` and file `path` in the API call.
      parameters:
      - description: Location of the files
        in: path
        name: location
        required: true
        schema:
          $ref: '#/components/schemas/FileLocationSchema'
      - description: Path in a shared/personal space to a file to delete
        example: filename.ipynb
        in: path
        name: path
        required: true
        schema:
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    description: filename.ipynb
                    type: string
                  path:
                    description: /
                    type: string
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Deletes a file from a personal or shared space.
      tags:
      - Files
    get:
      description: |
        Returns the information about a file or redirects to the file download URL.

        You must specify the `location` and the file `path` in the API call.
      parameters:
      - description: Location of the files
        in: path
        name: location
        required: true
        schema:
          $ref: '#/components/schemas/FileLocationSchema'
      - description: Path in a personal/shared space to a file
        example: filename.ipynb
        in: path
        name: path
        required: true
        schema:
          type: string
      - description: If enabled, the API request returns only metadata for the specified
          file instead of downloading it.
        in: query
        name: metadata
        schema:
          type: boolean
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileObjectMetadata'
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a file or downloads a file from a personal or
        shared space.
      tags:
      - Files
    patch:
      description: |
        Modifies the path of the existing file in a personal or shared space to the new path specified in the request body.

        You must specify the `location` and file `path` in the API call.
      parameters:
      - description: Location of the files
        in: path
        name: location
        required: true
        schema:
          $ref: '#/components/schemas/FileLocationSchema'
      - description: Path in a personal/shared space to modify
        example: filename.ipynb
        in: path
        name: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            example:
              newPath: new_filename.ipynb
            schema:
              properties:
                newPath:
                  description: New path of the file
                  type: string
              type: object
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    description: filename.ipynb
                    type: string
                  path:
                    description: /
                    type: string
                type: object
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Modifies a file in a personal or shared space.
      tags:
      - Files
    put:
      description: |
        This endpoint allows you to create or upload a new file at a specified path within a personal/shared space. The behavior depends on the contents of the request body and the format of the path:
         - **File Upload:** If the request body contains a file, the file is uploaded to the specified path within a personal/shared space.
         - **Empty File Creation:** If the request body does not contain a file, an empty file is created at the specified path.

        You must specify the `location` and the file `path` in the API call.
      parameters:
      - description: Location of the files
        in: path
        name: location
        required: true
        schema:
          $ref: '#/components/schemas/FileLocationSchema'
      - description: Path in a personal/shared space
        example: filename.ipynb
        in: path
        name: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              properties:
                file:
                  description: File to upload
                  format: binary
                  type: string
              type: object
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    example: filename.ipynb
                    type: string
                  path:
                    example: /
                    type: string
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new file or uploads a file to a personal or shared space.
      tags:
      - Files
  /v1/jobs:
    post:
      description: |
        This creates a job. A job sets a scheduled execution of a notebook and can cause notebooks to be run on a schedule or one-time only
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/JobCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Job'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Creates a new job
      tags:
      - Jobs
  /v1/jobs/{jobID}:
    delete:
      description: |
        This deletes a job and all execution snapshots associated with a job.
      parameters:
      - $ref: '#/components/parameters/jobID'
      responses:
        "200":
          content:
            application/json:
              schema:
                type: boolean
          description: OK
        "400":
          description: Bad request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Deletes a job
      tags:
      - Jobs
    get:
      description: |
        Returns the metadata on target, schedule and notebook for a job specified by a jobid.
      parameters:
      - $ref: '#/components/parameters/jobID'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Job'
          description: OK
        "400":
          description: Bad request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Gets information about the specified job
      tags:
      - Jobs
  /v1/jobs/{jobID}/executions:
    get:
      description: |
        Returns the information of the executions of a specified job. Specify which executions you want with the parameters.
      parameters:
      - $ref: '#/components/parameters/jobID'
      - description: Start execution number.
        example: 1
        in: query
        name: start
        required: true
        schema:
          type: number
      - description: End execution number.
        example: 10
        in: query
        name: end
        required: true
        schema:
          type: number
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExecutionsResult'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Get executions for a job
      tags:
      - Jobs
  /v1/jobs/{jobID}/parameters:
    get:
      description: |
        Returns the array of the parameters of a specified job.
      parameters:
      - $ref: '#/components/parameters/jobID'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JobParameter'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Get parameters for a job
      tags:
      - Jobs
  /v1/jobs/runtimes:
    get:
      description: |
        Returns the list of available runtimes for jobs.
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/RuntimesResult'
                type: array
          description: OK
        "400":
          description: Bad request
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      summary: Get the list of available job runtimes
      tags:
      - Jobs
  /v1/organizations/current:
    get:
      description: Returns information about the current authorized user's organization.
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Organization'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about the current organization
      tags:
      - Organizations
  /v1/privateConnections:
    description: The `privateConnections` endpoint can be used to create and manage
      private connections to SingleStoreDB Cloud workspaces.
    post:
      description: |
        Creates a new private connection. Upon successful completion of the request, a private connection is scheduled for creation. To query the private connection status, use the endpoints for the workspace group and workspace (if provided).
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PrivateConnectionCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                privateConnectionID: b07fff9f-0000-1000-9000-b1974e06b736
              schema:
                properties:
                  privateConnectionID:
                    format: uuid
                    type: string
                required:
                - privateConnectionID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new private connection
      tags:
      - Private Connections
  /v1/privateConnections/{connectionID}:
    delete:
      description: Deletes a private connection for the specified connection ID. Upon
        successful completion, a private connection is scheduled for deletion.
      parameters:
      - $ref: '#/components/parameters/connectionID'
      responses:
        "200":
          content:
            application/json:
              example:
                privateConnectionID: b07fff9f-0000-1000-9000-b1974e06b736
              schema:
                properties:
                  privateConnectionID:
                    format: uuid
                    type: string
                required:
                - privateConnectionID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A private connection with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Deletes a private connection
      tags:
      - Private Connections
    get:
      description: Returns private connection information for the specified connection
        ID, in JSON format. You must specify the connection ID in the API call.
      parameters:
      - $ref: '#/components/parameters/connectionID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PrivateConnection'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A private connection with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a private connection
      tags:
      - Private Connections
    patch:
      description: Updates a private connection. You must specify the connection ID
        in the API call.
      parameters:
      - $ref: '#/components/parameters/connectionID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PrivateConnectionUpdate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                privateConnectionID: b07fff9f-0000-1000-9000-b1974e06b736
              schema:
                properties:
                  privateConnectionID:
                    format: uuid
                    type: string
                required:
                - privateConnectionID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A private connection with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Updates a private connection
      tags:
      - Private Connections
  /v1/regions:
    get:
      description: Returns a list of valid regions for the user that support workspaces,
        including the region ID and provider for each region.
      parameters:
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              example:
              - provider: GCP
                region: US West 1 (Oregon)
                regionID: 1c1de314-0000-1000-9000-5047ff90842e
              - provider: AWS
                region: Europe Central 1 (Frankfurt)
                regionID: 7e7ffd27-0000-1000-9000-e72828a81ac7
              - provider: AWS
                region: Asia Pacific Southeast 2 (Sydney)
                regionID: c74bb6a6-0000-1000-9000-1d874fa277b7
              schema:
                items:
                  $ref: '#/components/schemas/Region'
                type: array
          description: OK
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists all of the regions for the user that support workspaces
      tags:
      - Regions
  /v1/secrets:
    description: The `secrets` endpoint can be used to create and manage secrets.
    get:
      description: |
        Returns a list of all of the secrets accessible to the user.
      parameters:
      - description: Name of the secret.
        in: query
        name: name
        schema:
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/Secret'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists the secrets the user can access.
      tags:
      - Secrets
    post:
      description: Creates a new secret, which can be used to store sensitive information
        such as passwords, API keys, and other credentials. You must specify a name
        and value for the secret in the API request body.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SecretCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Secret'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "409":
          description: Secret with specified name already exists
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new secret
      tags:
      - Secrets
  /v1/secrets/{secretID}:
    delete:
      description: |
        Deletes a secret with the specified ID. You must specify the secret ID in the API call.
      parameters:
      - $ref: '#/components/parameters/secretID'
      responses:
        "200":
          content:
            application/json:
              example:
                secretID: 03891d70-0000-1000-9000-113917fd0355
              schema:
                properties:
                  secretID:
                    format: uuid
                    type: string
                required:
                - secretID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A secret with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Deletes a secret
      tags:
      - Secrets
    get:
      description: |
        Returns information for the specified secret ID, in JSON format. You must specify the secret ID in the API call.
      parameters:
      - $ref: '#/components/parameters/secretID'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Secret'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A secret with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a secret
      tags:
      - Secrets
    patch:
      description: |
        Updates the name or value for the specified secret ID. You must specify the secret ID in the API call and at least one parameter (name or value) in the request body.
      parameters:
      - $ref: '#/components/parameters/secretID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SecretUpdate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Secret'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A secret with the specified ID was not found
        "409":
          description: Secret with specified name already exists
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Updates the name or value of a secret
      tags:
      - Secrets
  /v1/sharedtier/virtualWorkspaces/{virtualWorkspaceID}/users/{userID}:
    delete:
      parameters:
      - in: path
        name: virtualWorkspaceID
        required: true
        schema:
          format: uuid
          type: string
      - in: path
        name: userID
        required: true
        schema:
          format: uuid
          type: string
      requestBody:
        content:
          application/json:
            schema:
              type: boolean
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                type: boolean
          description: OK
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      tags:
      - SharedTier
    patch:
      parameters:
      - in: path
        name: virtualWorkspaceID
        required: true
        schema:
          format: uuid
          type: string
      - in: path
        name: userID
        required: true
        schema:
          format: uuid
          type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SharedTierUpdateUser'
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                type: boolean
          description: OK
        "401":
          description: Unauthorized
        "500":
          description: Internal server error
      tags:
      - SharedTier
  /v1/stage/{deploymentID}/fs:
    get:
      description: |
        Returns a list of all files and folders located in the Stage's root folder of the specified deployment (either a workspace group or starter workspace).

        You must specify the `deploymentID`.
      parameters:
      - description: ID of the deployment
        example: 68af2f46-0000-1000-9000-3f6f5365d878
        in: path
        name: deploymentID
        required: true
        schema:
          format: uuid
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileObjectMetadata'
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists files and folders in the root folder.
      tags:
      - Stage
  /v1/stage/{deploymentID}/fs/{path}:
    delete:
      description: |
        Deletes the file or folder at the specified path in a Stage.

        This endpoint supports both URL-encoded and regular URL paths. Here are some examples of valid requests:

        - Delete a folder:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_folder/
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_folder%2F

        - Delete a file:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_file.txt
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_file.txt

        You must specify the `deploymentID` and the folder/file path in the API call.

        ## Note: To delete a folder, ensure that the path includes a trailing slash.
      parameters:
      - description: ID of the deployment
        example: 68af2f46-0000-1000-9000-3f6f5365d878
        in: path
        name: deploymentID
        required: true
        schema:
          format: uuid
          type: string
      - description: Path in the Stage to a file or folder to delete
        examples:
          file:
            value: parent_folder/sample_folder/file.json
          folder:
            value: parent_folder/sample_folder/
        in: path
        name: path
        required: true
        schema:
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    description: sample_file.txt
                    type: string
                  path:
                    description: parent_folder/sample_file.txt
                    type: string
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Deletes a file or folder
      tags:
      - Stage
    get:
      description: |
        If the specified path is a folder, the API returns the list of files and folders inside this folder in the Stage. If the specified path is a file, the API call is redirected to a download URL.

        This endpoint supports both URL-encoded and regular URL paths. Here are some examples of valid requests:

        - Get a folder:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_folder/
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_folder%2F

        - Get a file:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_file.txt
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_file.txt

        You must specify the `deploymentID` and the folder/file path in the API call.

        ## Note: To Get a folder, ensure that the path includes a trailing slash.
      parameters:
      - description: ID of the deployment
        example: 68af2f46-0000-1000-9000-3f6f5365d878
        in: path
        name: deploymentID
        required: true
        schema:
          format: uuid
          type: string
      - description: Path in the Stage to a file or folder
        examples:
          file:
            value: parent_folder/sample_folder/filename.json
          folder:
            value: parent_folder/sample_folder/
        in: path
        name: path
        required: true
        schema:
          type: string
      - description: If enabled, the API request returns only metadata for the specified
          file instead of downloading it. This parameter is ignored if the specified
          path is a folder.
        in: query
        name: metadata
        schema:
          type: boolean
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileObjectMetadata'
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a folder or downloads a file
      tags:
      - Stage
    patch:
      description: |
        Modifies the path of the existing file or folder in a Stage to the new path specified in the request body.

        This endpoint supports both URL-encoded and regular URL paths, so both of the following examples are valid requests:

        - Modify a folder:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_folder/
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_folder%2F

        - Modify a file:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_file.txt
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_file.txt

        You must specify the `deploymentID` and the folder/file path in the API call.

        ## Note: To modify the path of a folder, ensure that it includes a trailing slash.
      parameters:
      - description: ID of the deployment
        example: 68af2f46-0000-1000-9000-3f6f5365d878
        in: path
        name: deploymentID
        required: true
        schema:
          format: uuid
          type: string
      - description: Path in the Stage to modify
        examples:
          file:
            value: parent_folder/sample_folder/file.json
          folder:
            value: parent_folder/sample_folder/
        in: path
        name: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            examples:
              file:
                value:
                  newPath: parent_folder/sample_folder/file.json
              folder:
                value:
                  newPath: parent_folder/sample_folder/
            schema:
              properties:
                newPath:
                  description: New path of the file or folder
                  type: string
              type: object
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    description: sample_file.txt
                    type: string
                  path:
                    description: parent_folder/sample_file.txt
                    type: string
                type: object
          description: OK
        "307":
          description: Temporary Redirect
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: Not Found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Modifies a file or folder in a Stage
      tags:
      - Stage
    put:
      description: |
        This endpoint allows you to create a new folder or upload a new file at a specified path within Stage. The behavior depends on the contents of the request body and the format of the path:
         - **File Upload:** If the request body contains a file, the file is uploaded to the specified path within the Stage.
         - **Folder Creation:** If the request body does not contain a file and the path ends with a trailing slash (`/`), a new folder is created at the specified path.
         - **Empty File Creation:** If the request body does not contain a file and the path does not end with a trailing slash, an empty file is created at the specified path.

        **Please ensure that the path is correctly formatted according to the desired action. Misformatted paths may lead to unexpected behavior.**

        This endpoint supports both URL-encoded and regular URL paths. Here are some examples of valid requests:

        - Create a folder:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_folder/
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_folder%2F

        - Upload a file:
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder/sample_folder/file.json
          - /v1/stage/68af2f46-0000-1000-9000-3f6f5365d878/fs/parent_folder%2Fsample_folder%2Ffile.json

        You must specify the `deploymentID` and the folder/file path in the API call.
      parameters:
      - description: ID of the deployment
        example: 68af2f46-0000-1000-9000-3f6f5365d878
        in: path
        name: deploymentID
        required: true
        schema:
          format: uuid
          type: string
      - description: Path in the Stage
        examples:
          file:
            value: parent_folder/sample_folder/file.json
          folder:
            value: parent_folder/sample_folder/
        in: path
        name: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          multipart/form-data:
            schema:
              properties:
                file:
                  description: File to upload
                  format: binary
                  type: string
              type: object
      responses:
        "200":
          content:
            application/json:
              schema:
                properties:
                  name:
                    example: file.json
                    type: string
                  path:
                    example: /parent_folder/sample_folder
                    type: string
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new folder or uploads a file
      tags:
      - Stage
  /v1/teams:
    description: The `teams` endpoint is used to manage teams.
    get:
      description: |
        Returns a list of teams in the current organization.
      parameters:
      - description: Show only teams with names matching this value or regular expression.
        in: query
        name: name
        schema:
          type: string
      - description: Show only teams with descriptions matching this value or regular
          expression.
        in: query
        name: description
        schema:
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/Team'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists the teams defined for the current organization. Teams may be
        filtered by name or description. An empty list is returned if no teams match
        the filter.
      tags:
      - Teams
    post:
      description: Creates a new team. You must specify a name in the API request
        body.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TeamCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Team'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "409":
          description: Team with specified name already exists
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new team
      tags:
      - Teams
  /v1/teams/{teamID}:
    delete:
      description: |
        Deletes the specified team.
      parameters:
      - $ref: '#/components/parameters/teamID'
      responses:
        "200":
          content:
            application/json:
              example:
                teamID: 03891d70-ea86-403e-8463-113917fd0355
              schema:
                properties:
                  teamID:
                    format: uuid
                    type: string
                required:
                - teamID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A team with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Deletes a team
      tags:
      - Teams
    get:
      description: |
        Returns information for the specified team.
      parameters:
      - $ref: '#/components/parameters/teamID'
      responses:
        "200":
          content:
            application/json:
              example:
                createdAt: 2023-09-18T09:56:56Z"
                description: All analysts in the abc.com organization
                name: Analysts
                teamID: c74bb6a6-0000-1000-9000-1d874fa277b0
              schema:
                $ref: '#/components/schemas/Team'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A team with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a team.
      tags:
      - Teams
    patch:
      description: |
        Updates the name, description, and/or members for the specified team.
      parameters:
      - $ref: '#/components/parameters/teamID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TeamUpdate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                teamID: 03891d70-ea86-403e-8463-113917fd0355
              schema:
                properties:
                  teamID:
                    format: uuid
                    type: string
                required:
                - teamID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A team with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Updates the name, description, and/or members of a team
      tags:
      - Teams
  /v1/workspaceGroups:
    description: The `workspaceGroups` endpoint can be used to manage workspaces.
    get:
      description: |
        Returns a list of all of the workspace groups accessible to the user. Use the `includeTerminated` parameter to get a list of terminated workspace groups.
      parameters:
      - description: To include any terminated workspace groups, set to `true`
        in: query
        name: includeTerminated
        schema:
          type: boolean
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              example:
              - createdAt: "2023-09-18T09:56:56Z"
                name: demo-workspace-group
                regionID: 7d6b3a5a-0000-1000-9000-d454af4c785c
                state: ACTIVE
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                items:
                  $ref: '#/components/schemas/WorkspaceGroup'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists the workspace groups the user can access
      tags:
      - Workspace Groups
    post:
      description: |
        Creates a new workspace group for the current user. You must specify the name, region ID, and firewall ranges for the workspace group in the API request body.

        You may use the admin user password to connect with any workspace of the group. The admin user password can be specified in the request body. If the admin user password is not specified in the API request, a password is generated and returned in the response object.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceGroupCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  adminPassword:
                    type: string
                  workspaceGroupID:
                    format: uuid
                    type: string
                required:
                - workspaceGroupID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new workspace group
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}:
    delete:
      description: |
        Terminates a workspace group with the specified workspace group ID. You must specify the workspace group ID in the API call.

        By default, you may only terminate empty workspace groups (a workspace group without workspaces). To terminate a workspace group with active workspaces, use the `force` parameter.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      - description: To terminate a workspace group even if it has active workspaces,
          set to `true`
        in: query
        name: force
        schema:
          type: boolean
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceGroupID:
                    format: uuid
                    type: string
                required:
                - workspaceGroupID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace group with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Terminates a workspace group
      tags:
      - Workspace Groups
    get:
      description: |
        Returns information for the specified
        workspace group ID, in JSON format. You must specify the workspace group ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              example:
                createdAt: "2023-09-18T09:56:56Z"
                name: demo-workspace-group
                regionID: 7d6b3a5a-0000-1000-9000-d454af4c785c
                state: ACTIVE
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                $ref: '#/components/schemas/WorkspaceGroup'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace group with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a workspace group
      tags:
      - Workspace Groups
    patch:
      description: |
        Updates workspace group information for the specified workspace group, including the name, admin password, and firewall ranges. Specify the workspace group's new parameters in the request body. You must specify the workspace group ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceGroupUpdate'
        description: Here's a sample of JSON data sent to the API in the request body.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceGroupID:
                    format: uuid
                    type: string
                required:
                - workspaceGroupID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace group with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Updates a workspace group
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/egress/createEgressClusterIdentity:
    post:
      description: Creates an egress cluster identity for the workspace group. You
        must specify the workspace group ID of the group you are creating the egress
        cluster identity for.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EgressClusterIdentityCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates an egress cluster identity
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/egress/startTableEgress:
    post:
      description: Starts egress for a table in the workspace group. You must specify
        the workspace group ID of the group you are starting egress for.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TableEgressStart'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Starts egress for a table
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/egress/tableEgressStatus:
    get:
      description: Gets the egress status for a table in the workspace group. You
        must specify the workspace group ID of the group you are getting the egress
        status for.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TableEgressStatusParams'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TableEgressStatus'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets the egress status for a table
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/privateConnections:
    get:
      description: |
        Returns private connection information for the specified
        workspace group ID, in JSON format. You must specify the workspace group ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/PrivateConnection'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace group with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets private connection information for a workspace group
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/failback:
    patch:
      description: You must specify the workspace group ID of the group in the standby
        (secondary) region from which you are triggering the failback.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Starts failback to the primary region
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/failover:
    patch:
      description: You must specify the workspace group ID of the group in the inactive
        (primary) region from which you are triggering the failover.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Starts failover to the secondary region
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/regions:
    get:
      description: Returns a list of regions with regions IDs in JSON format. You
        must specify the workspace group ID of the group you are setting up for disaster
        recovery.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/Region'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about which regions you can setup as a disaster recovery
        backup
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/setup:
    post:
      description: You must specify the workspace group ID of the group you are setting
        up for disaster recovery and the region ID of your secondary region.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/StorageDRSetup'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Sets up Storage DR for the workspace group. Backup region and selected
        databases to be replicated are provided as part of the request.
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/startPreProvision:
    patch:
      description: You must specify the workspace group ID of the group in the primary
        region from which you are requesting to start pre-provision.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Start pre-provisioning from primary region
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/status:
    get:
      description: Returns the replication status of each database and the status
        of the latest Storage DR operation (Failover, Failback, etc.). You must specify
        the workspace group ID of the group that you are requesting status information
        for.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/StorageDRStatus'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about the storage DR status of the workspace group
      tags:
      - Workspace Groups
  /v1/workspaceGroups/{workspaceGroupID}/storage/DR/stopPreProvision:
    patch:
      description: You must specify the workspace group ID of the group in the primary
        region from which you are requesting to stop pre-provision.
      parameters:
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Stops pre-provisioning from primary region
      tags:
      - Workspace Groups
  /v1/workspaces:
    description: The `workspaces` endpoint can be used to manage workspaces.
    get:
      description: |
        Returns a list of all of the workspaces accessible to the user in the specified workspace group. You must specify the workspace group ID in the API call to list the workspaces in the group. Use the `includeTerminated` parameter to list the terminated workspaces.
      parameters:
      - description: ID of the workspace group
        in: query
        name: workspaceGroupID
        required: true
        schema:
          format: uuid
          type: string
      - description: To include any terminated workspaces, set to `true`
        in: query
        name: includeTerminated
        schema:
          type: boolean
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              example:
              - createdAt: "2023-09-18T09:56:56Z"
                endpoint: 192.168.224.3:30342
                name: demo-workspace
                size: S-00
                state: ACTIVE
                workspaceGroupID: 7d6b3a5a-0000-1000-9000-d454af4c785b
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                items:
                  $ref: '#/components/schemas/Workspace'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace group with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Lists the workspaces the user can access
      tags:
      - Workspaces
    post:
      description: |-
        Creates a new workspace for the current user in the specified workspace group. You must specify the name of the workspace and the workspace group ID in the request body. Once a workspace is created, you can neither change its name nor its workspace group. See [Workspaces](https://docs.singlestore.com/managed-service/en/reference/management-api.html#workspaces-729524) for more information.
        This API call does not take any request parameters.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceID:
                    format: uuid
                    type: string
                required:
                - workspaceID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates a new workspace
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}:
    delete:
      description: |
        Terminates a workspace with the specified workspace ID. You must specify the workspace ID in the API call.

        All the databases attached to the workspace are detached when the workspace is terminated.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceID:
                    format: uuid
                    type: string
                required:
                - workspaceID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Terminates a workspace
      tags:
      - Workspaces
    get:
      description: Returns workspace information for the specified workspace ID, in
        JSON format. You must specify the workspace ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              example:
                createdAt: "2023-09-18T09:56:56Z"
                endpoint: 192.168.224.3:30342
                name: demo-workspace
                size: S-00
                state: ACTIVE
                workspaceGroupID: 7d6a4a5a-0000-1000-9000-d454af4c785b
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                $ref: '#/components/schemas/Workspace'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information about a workspace
      tags:
      - Workspaces
    patch:
      description: |
        Updates workspace information for the specified workspace, including the size. Specify the workspace's new parameters in the request body. You must specify the workspace ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceUpdate'
        description: Here's a sample of JSON data sent to the API in the request body.
        required: true
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceID:
                    format: uuid
                    type: string
                required:
                - workspaceID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "409":
          description: Request conflict
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Updates information about a workspace
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/egress/createEgressClusterIdentity:
    post:
      description: Creates an egress cluster identity for the workspace. You must
        specify the workspace ID of the workspace you are creating the egress cluster
        identity for.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EgressClusterIdentityCreate'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Creates an egress cluster identity
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/egress/startTableEgress:
    post:
      description: Starts egress for a table in the workspace. You must specify the
        workspace ID of the workspace you are starting egress for.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TableEgressStart'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Starts egress for a table
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/egress/tableEgressStatus:
    get:
      description: Gets the egress status for a table in the workspace. You must specify
        the workspace ID of the workspace you are getting the egress status for.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TableEgressStatusParams'
        description: Here's a sample of JSON data sent in the request body to the
          API.
        required: true
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TableEgressStatus'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets the egress status for a table
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/privateConnections:
    get:
      description: Returns private connection information for the specified workspace
        ID, in JSON format. You must specify the workspace ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      - $ref: '#/components/parameters/fields'
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/PrivateConnection'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets private connection information for a workspace
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/privateConnections/kai:
    get:
      description: Returns the information needed to create private connection to
        SingleStore Kai.
      parameters:
      - in: path
        name: workspaceID
        required: true
        schema:
          format: uuid
          type: string
      responses:
        "200":
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PrivateConnectionKaiInfo'
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A private connection with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets information to create private connection to SingleStore Kai for
        a workspace
      tags:
      - Private Connections
      - Workspaces
  /v1/workspaces/{workspaceID}/privateConnections/outboundAllowList:
    get:
      description: Returns the account ID which must be allowed for outbound connections.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      responses:
        "200":
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/PrivateConnectionOutboundAllowList'
                type: array
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets the outbound allow list for a workspace
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/resume:
    post:
      description: |
        Resumes a workspace with the specified workspace ID. You must specify the workspace ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspaceResume'
        description: Here's a sample of JSON data sent in the request body to the
          API.
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceID:
                    format: uuid
                    type: string
                required:
                - workspaceID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Resumes a workspace
      tags:
      - Workspaces
  /v1/workspaces/{workspaceID}/suspend:
    post:
      description: Suspends a workspace with the specified workspace ID. You must
        specify the workspace ID in the API call.
      parameters:
      - $ref: '#/components/parameters/workspaceID'
      responses:
        "200":
          content:
            application/json:
              example:
                workspaceID: 7d6b3a5a-0000-1000-9000-d454af4c785b
              schema:
                properties:
                  workspaceID:
                    format: uuid
                    type: string
                required:
                - workspaceID
                type: object
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "404":
          description: A workspace with the specified ID was not found
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Suspends a workspace
      tags:
      - Workspaces
  /v2/organizations/{organizationID}/workspaceGroups/{workspaceGroupID}/metrics:
    get:
      description: Returns metrics for the specified workspace group ID, in [OpenMetrics](https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md)
        compatible format. You must specify the organization ID and workspace group
        ID in the API call. To fetch the organization id use the /v1/organizations/current
        endpoint.
      parameters:
      - $ref: '#/components/parameters/organizationID'
      - $ref: '#/components/parameters/workspaceGroupID'
      responses:
        "200":
          content:
            text/plain:
              example: |-
                # TYPE singlestoredb_cloud_threads_running gauge
                # singlestoredb_cloud_threads_running{extractor="monitoring-customer-prd/memsql-exporter",node="node-3337afc7-443e-4126-b784-413903527186-aggregator-0",role="CA",workspace_group_id="3337afc7-443e-4126-b784-413903527186",workspace_name="singlestore-central"} 1
              schema:
                type: string
          description: OK
        "400":
          description: Invalid request
        "401":
          description: Unauthorized
        "429":
          description: Too many requests
        "500":
          description: Internal server error
      summary: Gets metrics for a workspace group
      tags:
      - Metrics
security:
- ApiKeyAuth: []
servers:
- url: https://api.singlestore.com

