{
  "components": {
    "securitySchemes": {
      "managementAPIToken": {
        "type": "oauth2",
        "description": "Your Management API token must be added to the request _Authorization_ header using the following format:\n\n `Authorization: Bearer YOUR_MANAGEMENT_API_KEY`",
        "flows": {
          "password": {
            "tokenUrl": "https://api.moesif.com/v1/:orgId/oauth/access_tokens",
            "scopes": {
              "create:encrypted_keys": "Create encrypted Keys for the Moesif secure proxy",
              "delete:dashboards": "Delete existing dashboards",
              "update:dashboards": "Update existing dashboards",
              "create:dashboards": "Create a new team dashboard that can be shared",
              "read:public_workspaces": "Read public workspaces/shared links",
              "read:virtual_eventtypes": "Read existing virtual events/tags",
              "update:companies": "Update existing companies and associated company metadata",
              "create:companies": "Create new companies and associated company metadata",
              "create:reports": "Create a new report such as SmartDiff",
              "delete:workspaces": "Delete existing workspaces",
              "create:workspaces": "Create a new workspace/chart that can be shared",
              "read:workspaces": "Read existing workspaces",
              "update:virtual_eventtypes": "Update existing virtual events/tags",
              "create:cohorts": "Save new customer cohorts",
              "delete:encrypted_keys": "Delete encrypted Keys for the Moesif secure proxy",
              "read:dashboards": "Read existing dashboards",
              "read:events": "Read/query events and associated event metadata",
              "create:events": "Create new events and associated event metadata",
              "read:cohorts": "Read previously saved customer cohorts",
              "read:encrypted_keys": "Read encrypted Keys for the Moesif secure proxy",
              "update:apps": "Update an existing application",
              "update:encrypted_keys": "Update encrypted Keys for the Moesif secure proxy",
              "update:organizations": "Update an existing application",
              "create:access_tokens": "Create new tokens to access the Management API or Collector API",
              "create:users": "Create new users and associated user metadata",
              "create:apps": "Create a new application/project under the organization",
              "update:workspaces": "Update existing workspaces",
              "delete:cohorts": "Delete previously saved customer cohorts",
              "read:users": "Read/query users and associated user metadata",
              "delete:virtual_eventtypes": "Delete existing virtual events/tags",
              "read:reports": "Read reports such as SmartDiff",
              "delete:reports": "Delete existing reports such as SmartDiff",
              "update:users": "Update existing users and associated user metadata",
              "update:cohorts": "Update previously saved customer cohorts",
              "read:companies": "Read/query companies and associated company metadata",
              "create:virtual_eventtypes": "Create virtual events/tags",
              "delete:apps": "Delete an existing application",
              "delete:companies": "Delete existing companies and associated company metadata",
              "read:apps": "Read the organization's applications",
              "create:eth_abi": "Create/upload new Ethereum ABI Entries",
              "delete:users": "Delete existing users and associated user metadata"
            }
          }
        }
      }
    },
    "schemas": {
      "StripeTier": {
        "properties": {
          "flat_amount_decimal": {
            "type": "string"
          },
          "up_to": {
            "type": "integer",
            "format": "int64"
          },
          "unit_amount_decimal": {
            "type": "string"
          },
          "flat_amount": {
            "type": "integer",
            "format": "int64"
          },
          "unit_amount": {
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "CohortDocument": {
        "properties": {
          "channels": {
            "type": "array[string]"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "url_query": {
            "type": "string"
          },
          "criteria": {
            "type": "string"
          },
          "_id": {
            "type": "string"
          },
          "sample_rate": {
            "type": "integer",
            "format": "int32"
          },
          "notification_rule": {
            "$ref": "#/components/schemas/NotificationRule"
          },
          "cohort_name": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "locked_by": {
            "type": "string"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "from": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "app_id": {
            "type": "string"
          },
          "cohort_type": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          },
          "org_id": {
            "type": "string"
          }
        },
        "required": [
          "org_id",
          "app_id",
          "created_at",
          "modified_at",
          "criteria",
          "cohort_name",
          "cohort_type"
        ]
      },
      "RulesResponseItem": {
        "properties": {
          "status": {
            "type": "integer",
            "format": "int32"
          },
          "headers": {
            "type": "collection.immutable.map[string,string]"
          },
          "body": {
            "type": "object"
          },
          "original_encoded_body": {
            "type": "string"
          }
        }
      },
      "AppCreateDTO": {
        "properties": {
          "name": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "custom_app_id": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ]
      },
      "AppUpdateDTO": {
        "properties": {
          "name": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "custom_app_id": {
            "type": "string"
          }
        }
      },
      "BillingReportUsageInvoice": {
        "properties": {
          "period_start": {
            "type": "string",
            "format": "date-time"
          },
          "period_end": {
            "type": "string",
            "format": "date-time"
          },
          "id": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ]
      },
      "CohortCreateItem": {
        "properties": {
          "channels": {
            "type": "array[string]"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "url_query": {
            "type": "string"
          },
          "criteria": {
            "type": "object"
          },
          "notification_rule": {
            "$ref": "#/components/schemas/NotificationRule"
          },
          "cohort_name": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "locked_by": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "cohort_type": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          }
        },
        "required": [
          "cohort_name",
          "cohort_type",
          "criteria"
        ]
      },
      "CustomReportPlan": {
        "properties": {
          "plan_id": {
            "type": "string"
          }
        },
        "required": [
          "plan_id"
        ]
      },
      "BillingReportUsage": {
        "properties": {
          "invoice": {
            "$ref": "#/components/schemas/BillingReportUsageInvoice"
          },
          "aggregator": {
            "type": "string"
          }
        }
      },
      "BillingMetricResponse": {
        "properties": {
          "buckets": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BillingMetricBucket"
            }
          }
        },
        "required": [
          "buckets"
        ]
      },
      "EmailAddresses": {
        "properties": {
          "from": {
            "type": "string"
          },
          "cc": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "bcc": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "from",
          "cc",
          "bcc"
        ]
      },
      "Plan": {
        "properties": {
          "provider": {
            "type": "string"
          },
          "plan_id": {
            "type": "string"
          },
          "price_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "provider",
          "plan_id",
          "price_ids"
        ]
      },
      "SequenceItem": {
        "properties": {
          "delay": {
            "type": "integer",
            "format": "int32"
          },
          "submit_data": {
            "$ref": "#/components/schemas/SubmitData"
          }
        },
        "required": [
          "delay",
          "submit_data"
        ]
      },
      "Cohort": {
        "properties": {
          "id": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "config": {
            "$ref": "#/components/schemas/CohortConfig"
          }
        },
        "required": [
          "id",
          "type"
        ]
      },
      "BalanceChange": {
        "properties": {
          "amount": {
            "type": "number",
            "format": "double"
          }
        },
        "required": [
          "amount"
        ]
      },
      "StripePrice": {
        "properties": {
          "tiers_mode": {
            "type": "string"
          },
          "transform_quantity": {
            "$ref": "#/components/schemas/StripeTransformQuantity"
          },
          "price_id": {
            "type": "string"
          },
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StripeTier"
            }
          },
          "recurring": {
            "$ref": "#/components/schemas/StripeRecurring"
          },
          "unit_amount_decimal": {
            "type": "string"
          },
          "price_nickname": {
            "type": "string"
          },
          "currency": {
            "type": "string"
          },
          "billing_scheme": {
            "type": "string"
          },
          "unit_amount": {
            "type": "integer",
            "format": "int64"
          },
          "created": {
            "type": "integer",
            "format": "int64"
          },
          "active": {
            "type": "boolean"
          }
        },
        "required": [
          "price_id"
        ]
      },
      "RegexCondition": {
        "properties": {
          "path": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        },
        "required": [
          "path",
          "value"
        ]
      },
      "TemplateConfig": {
        "properties": {
          "subject": {
            "type": "string"
          },
          "editor": {
            "type": "string"
          },
          "design": {
            "type": "object"
          },
          "thumbnail_url": {
            "type": "string"
          }
        },
        "required": [
          "subject",
          "editor",
          "design"
        ]
      },
      "RecurlyCurrencyAmount": {
        "properties": {
          "currency": {
            "type": "string"
          },
          "unit_amount": {
            "type": "double"
          },
          "unit_amount_decimal": {
            "type": "string"
          }
        },
        "required": [
          "currency"
        ]
      },
      "MoesifTransformQuantity": {
        "properties": {
          "divide_by": {
            "type": "integer",
            "format": "int64"
          },
          "round": {
            "type": "string"
          }
        },
        "required": [
          "divide_by",
          "round"
        ]
      },
      "StripeRecurring": {
        "properties": {
          "trial_period_days": {
            "type": "integer",
            "format": "int64"
          },
          "interval": {
            "type": "string"
          },
          "usage_type": {
            "type": "string"
          },
          "interval_count": {
            "type": "integer",
            "format": "int64"
          },
          "aggregate_usage": {
            "type": "string"
          }
        }
      },
      "DashboardUpdateItem": {
        "properties": {
          "parent": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "dashboard_id": {
            "type": "string"
          },
          "workspace_ids": {
            "type": "array",
            "items": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "sort_order": {
            "type": "number",
            "format": "double"
          },
          "dashboard_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "policy": {
            "$ref": "#/components/schemas/PolicyItem"
          }
        }
      },
      "Comments": {
        "properties": {
          "summary": {
            "$ref": "#/components/schemas/Summary"
          }
        },
        "required": [
          "summary"
        ]
      },
      "SignedTokenDTO": {
        "properties": {
          "_id": {
            "type": "string"
          },
          "token": {
            "type": "string"
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "_id",
          "token"
        ]
      },
      "ChargebeeItemPrice": {
        "properties": {
          "name": {
            "type": "string"
          },
          "item_id": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "price": {
            "type": "integer",
            "format": "int64"
          },
          "price_in_decimal": {
            "type": "string"
          },
          "external_name": {
            "type": "string"
          },
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ChargebeeItemPriceTier"
            }
          },
          "trial_end_action": {
            "type": "string"
          },
          "trial_period": {
            "type": "integer",
            "format": "int64"
          },
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "pricing_model": {
            "type": "string"
          },
          "created_at": {
            "type": "integer",
            "format": "int64"
          },
          "period_unit": {
            "type": "string"
          },
          "updated_at": {
            "type": "integer",
            "format": "int64"
          },
          "trial_period_unit": {
            "type": "string"
          },
          "item_type": {
            "type": "string"
          },
          "currency_code": {
            "type": "string"
          },
          "archived_at": {
            "type": "integer",
            "format": "int64"
          },
          "free_quantity": {
            "type": "integer",
            "format": "int64"
          },
          "period": {
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "id"
        ]
      },
      "MoesifPrice": {
        "properties": {
          "name": {
            "type": "string"
          },
          "transform_quantity": {
            "$ref": "#/components/schemas/MoesifTransformQuantity"
          },
          "provider": {
            "type": "string"
          },
          "price_in_decimal": {
            "type": "string"
          },
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MoesifPriceTier"
            }
          },
          "period_units": {
            "type": "string"
          },
          "plan_id": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "pricing_model": {
            "type": "string"
          },
          "tax_behavior": {
            "type": "string"
          },
          "currency": {
            "type": "string"
          },
          "metadata": {
            "type": "collection.immutable.map[string,string]"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "unit": {
            "type": "string"
          },
          "usage_aggregator": {
            "type": "string"
          },
          "period": {
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "EmailTemplateCreateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "cohorts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Cohort"
            }
          },
          "dynamic_fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DynamicField"
            }
          },
          "content": {
            "$ref": "#/components/schemas/TemplateContent"
          },
          "template": {
            "$ref": "#/components/schemas/TemplateConfig"
          },
          "period": {
            "type": "string"
          },
          "addresses": {
            "$ref": "#/components/schemas/EmailAddresses"
          }
        },
        "required": [
          "name",
          "state",
          "addresses",
          "cohorts",
          "template",
          "content"
        ]
      },
      "PolicyItem": {
        "properties": {
          "acl": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ACLItem"
            }
          },
          "resource": {
            "type": "object"
          },
          "api_scopes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "original_encoded_resource": {
            "type": "string"
          }
        },
        "required": [
          "acl",
          "resource"
        ]
      },
      "RecurlyAddOnPercentageTier": {
        "properties": {
          "ending_amount": {
            "type": "double"
          },
          "usage_percent": {
            "type": "string"
          }
        }
      },
      "StripeTransformQuantity": {
        "properties": {
          "divide_by": {
            "type": "integer",
            "format": "int64"
          },
          "round": {
            "type": "string"
          }
        }
      },
      "BillingMetricBucket": {
        "properties": {
          "start": {
            "type": "string",
            "format": "date-time"
          },
          "metric": {
            "type": "number",
            "format": "double"
          },
          "amounts": {
            "type": "collection.immutable.map[string,scala.double]"
          },
          "ending_balance": {
            "$ref": "#/components/schemas/CreditBalanceMetric"
          }
        },
        "required": [
          "start"
        ]
      },
      "DashboardDocument": {
        "properties": {
          "parent": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "_id": {
            "type": "string"
          },
          "auth_user_id": {
            "type": "string"
          },
          "profile_view_promotion": {
            "type": "string"
          },
          "app_id": {
            "type": "string"
          },
          "workspace_ids": {
            "type": "array",
            "items": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          },
          "sort_order": {
            "type": "number",
            "format": "double"
          },
          "dashboard_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "policy": {
            "$ref": "#/components/schemas/PolicyItem"
          },
          "org_id": {
            "type": "string"
          },
          "migration": {
            "type": "object"
          },
          "created": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "auth_user_id",
          "org_id",
          "app_id",
          "created",
          "name",
          "dashboard_ids",
          "workspace_ids"
        ]
      },
      "ChargebeeItemPlan": {
        "properties": {
          "name": {
            "type": "string"
          },
          "item_family_id": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "usage_calculation": {
            "type": "string"
          },
          "external_name": {
            "type": "string"
          },
          "metered": {
            "type": "boolean"
          },
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "unit": {
            "type": "string"
          },
          "updated_at": {
            "type": "integer",
            "format": "int64"
          },
          "archived_at": {
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "id"
        ]
      },
      "CreditBalanceMetric": {
        "properties": {
          "current_balance": {
            "type": "number",
            "format": "double"
          },
          "pending_activity": {
            "type": "number",
            "format": "double"
          },
          "available_balance": {
            "type": "number",
            "format": "double"
          }
        },
        "required": [
          "current_balance",
          "pending_activity",
          "available_balance"
        ]
      },
      "CreateCommentItem": {
        "properties": {
          "auth_user_id": {
            "type": "string"
          },
          "comment_id": {
            "type": "string"
          },
          "mentions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "partner_user_id": {
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "StripeBillingParams": {
        "properties": {
          "product": {
            "$ref": "#/components/schemas/StripeProduct"
          },
          "price": {
            "$ref": "#/components/schemas/StripePrice"
          },
          "prices": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StripePrice"
            }
          },
          "reporting": {
            "$ref": "#/components/schemas/ProviderReporting"
          }
        }
      },
      "TemplateContent": {
        "properties": {
          "html": {
            "type": "string"
          },
          "chunks": {
            "type": "object"
          }
        },
        "required": [
          "html",
          "chunks"
        ]
      },
      "DynamicField": {
        "properties": {
          "token": {
            "type": "string"
          },
          "field": {
            "type": "string"
          },
          "aggregator": {
            "type": "string",
            "enum": [
              "avg",
              "min",
              "max",
              "terms",
              "sum"
            ]
          }
        },
        "required": [
          "token",
          "field",
          "aggregator"
        ]
      },
      "BillingReportBalanceTransCreate": {
        "properties": {
          "company_id": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "expire_at": {
            "type": "string",
            "format": "date-time"
          },
          "active_at": {
            "type": "string",
            "format": "date-time"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "transaction_id": {
            "type": "string"
          },
          "subscription_id": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        },
        "required": [
          "company_id",
          "amount",
          "type",
          "subscription_id",
          "transaction_id"
        ]
      },
      "WorkspaceCreateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "is_default": {
            "type": "boolean"
          },
          "view_count": {
            "type": "integer",
            "format": "int32"
          },
          "dashboard": {
            "type": "object"
          },
          "colors": {
            "type": "object"
          },
          "drawings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DrawingItem"
            }
          },
          "chart": {
            "$ref": "#/components/schemas/ChartItem"
          },
          "template": {
            "$ref": "#/components/schemas/TemplateItem"
          },
          "type": {
            "type": "string"
          },
          "width": {
            "type": "number",
            "format": "double"
          },
          "sort_order": {
            "type": "number",
            "format": "double"
          },
          "policy": {
            "$ref": "#/components/schemas/PolicyItem"
          }
        },
        "required": [
          "name",
          "policy",
          "chart"
        ]
      },
      "RecurlyAddOnTier": {
        "properties": {
          "ending_quantity": {
            "type": "integer",
            "format": "int64"
          },
          "currencies": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyCurrencyAmount"
            }
          }
        },
        "required": [
          "currencies"
        ]
      },
      "CreditBalance": {
        "properties": {
          "sequence_id": {
            "type": "integer",
            "format": "int32"
          },
          "current_balance": {
            "type": "number",
            "format": "double"
          },
          "pending_activity": {
            "type": "number",
            "format": "double"
          },
          "available_balance": {
            "type": "number",
            "format": "double"
          }
        },
        "required": [
          "sequence_id",
          "current_balance",
          "pending_activity",
          "available_balance"
        ]
      },
      "ChargebeeItemPriceTier": {
        "properties": {
          "starting_unit": {
            "type": "integer",
            "format": "int32"
          },
          "ending_unit": {
            "type": "integer",
            "format": "int32"
          },
          "price": {
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "starting_unit",
          "price"
        ]
      },
      "MoesifPlan": {
        "properties": {
          "name": {
            "type": "string"
          },
          "prices": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MoesifPrice"
            }
          },
          "provider": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "product_id": {
            "type": "string"
          },
          "metadata": {
            "type": "collection.immutable.map[string,string]"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "unit": {
            "type": "string"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ChargebeeBillingParams": {
        "properties": {
          "item_plan": {
            "$ref": "#/components/schemas/ChargebeeItemPlan"
          },
          "item_price": {
            "$ref": "#/components/schemas/ChargebeeItemPrice"
          },
          "item_prices": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ChargebeeItemPrice"
            }
          },
          "reporting": {
            "$ref": "#/components/schemas/ProviderReporting"
          }
        }
      },
      "GovernanceRuleCreateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "model": {
            "type": "string"
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "cohorts": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "variables": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GovernanceRulesVariables"
            }
          },
          "applied_to": {
            "type": "string"
          },
          "block": {
            "type": "boolean"
          },
          "response": {
            "$ref": "#/components/schemas/RulesResponseItem"
          },
          "applied_to_unidentified": {
            "type": "boolean"
          },
          "regex_config": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RegexRule"
            }
          },
          "plans": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Plan"
            }
          },
          "type": {
            "type": "string"
          }
        },
        "required": [
          "type",
          "state",
          "name",
          "block"
        ]
      },
      "RecurlyPlanAddOn": {
        "properties": {
          "name": {
            "type": "string"
          },
          "currencies": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyCurrencyAmount"
            }
          },
          "usage_percentage": {
            "type": "double"
          },
          "add_on_type": {
            "type": "string"
          },
          "external_sku": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyAddOnTier"
            }
          },
          "tier_type": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "plan_id": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "percentage_tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyAddOnPercentageTiers"
            }
          },
          "usage_type": {
            "type": "string"
          },
          "created_at": {
            "type": "string"
          },
          "usage_calculation_type": {
            "type": "string"
          },
          "updated_at": {
            "type": "string"
          },
          "deleted_at": {
            "type": "string"
          }
        },
        "required": [
          "code"
        ]
      },
      "DrawingItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "direction": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "value": {
            "type": "number",
            "format": "double"
          }
        },
        "required": [
          "id",
          "name",
          "type",
          "value",
          "direction"
        ]
      },
      "ChartItem": {
        "properties": {
          "original_encoded_view_elements": {
            "type": "string"
          },
          "funnel_query": {
            "type": "object"
          },
          "url_query": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "view_elements": {
            "type": "object"
          },
          "from": {
            "type": "string"
          },
          "original_encoded_funnel_query": {
            "type": "string"
          },
          "es_query": {
            "type": "object"
          },
          "args": {
            "type": "string"
          },
          "original_encoded_query": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          },
          "view": {
            "type": "string"
          }
        },
        "required": [
          "view",
          "url_query"
        ]
      },
      "RecurlyAddOnPercentageTiers": {
        "properties": {
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyAddOnPercentageTier"
            }
          },
          "currency": {
            "type": "string"
          }
        }
      },
      "CustomReporting": {
        "properties": {
          "report_when": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "report_when"
        ]
      },
      "BillingReport": {
        "properties": {
          "ending_balance": {
            "$ref": "#/components/schemas/CreditBalance"
          },
          "company_id": {
            "type": "string"
          },
          "success": {
            "type": "boolean"
          },
          "provider": {
            "type": "string"
          },
          "report_version": {
            "type": "integer",
            "format": "int32"
          },
          "usage_end_time": {
            "type": "string",
            "format": "date-time"
          },
          "usage": {
            "$ref": "#/components/schemas/BillingReportUsage"
          },
          "_id": {
            "type": "string"
          },
          "meter_usage": {
            "type": "integer",
            "format": "int64"
          },
          "last_success_time": {
            "type": "string",
            "format": "date-time"
          },
          "beginning_balance": {
            "$ref": "#/components/schemas/CreditBalance"
          },
          "billing_meter_id": {
            "type": "string"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "usage_start_time": {
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "type": "string"
          },
          "provider_requests": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProviderRequest"
            }
          },
          "currency": {
            "type": "string"
          },
          "report_total_usage": {
            "type": "integer",
            "format": "int64"
          },
          "channel_requests": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ChannelRequest"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "app_id": {
            "type": "string"
          },
          "subscription_id": {
            "type": "string"
          },
          "subscription_period_start": {
            "type": "string",
            "format": "date-time"
          },
          "balance_changes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BalanceChange"
            }
          },
          "type": {
            "type": "string"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "org_id": {
            "type": "string"
          },
          "subscription_period_end": {
            "type": "string",
            "format": "date-time"
          },
          "meter_metric": {
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "org_id",
          "app_id",
          "usage_start_time",
          "usage_end_time",
          "subscription_id",
          "billing_meter_id",
          "provider",
          "company_id",
          "meter_metric",
          "meter_usage",
          "report_total_usage",
          "success",
          "provider_requests"
        ]
      },
      "ACLItem": {
        "properties": {
          "grantee": {
            "type": "string"
          },
          "permission": {
            "type": "string"
          }
        },
        "required": [
          "grantee",
          "permission"
        ]
      },
      "ZuoraBillingParams": {
        "properties": {
          "plan_id": {
            "type": "string"
          },
          "price_id": {
            "type": "string"
          },
          "price_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "CohortConfig": {
        "properties": {
          "url_query": {
            "type": "string"
          },
          "criteria": {
            "type": "string"
          },
          "cohort_name": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "cohort_type": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          }
        },
        "required": [
          "criteria",
          "url_query",
          "cohort_name",
          "cohort_type",
          "from",
          "to",
          "time_zone"
        ]
      },
      "RegexRule": {
        "properties": {
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RegexCondition"
            }
          },
          "sample_rate": {
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "conditions"
        ]
      },
      "GovernanceRulesVariables": {
        "properties": {
          "name": {
            "type": "string"
          },
          "path": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "path"
        ]
      },
      "ChannelRequest": {
        "properties": {
          "channel_id": {
            "type": "string"
          },
          "channel_name": {
            "type": "string"
          },
          "provider_requests": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProviderRequest"
            }
          }
        },
        "required": [
          "channel_id",
          "channel_name",
          "provider_requests"
        ]
      },
      "WorkspaceDocument": {
        "properties": {
          "name": {
            "type": "string"
          },
          "is_default": {
            "type": "boolean"
          },
          "view_count": {
            "type": "integer",
            "format": "int32"
          },
          "_id": {
            "type": "string"
          },
          "is_template": {
            "type": "boolean"
          },
          "dashboard": {
            "type": "object"
          },
          "auth_user_id": {
            "type": "string"
          },
          "colors": {
            "type": "object"
          },
          "sequence": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SequenceItem"
            }
          },
          "drawings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DrawingItem"
            }
          },
          "chart": {
            "$ref": "#/components/schemas/ChartItem"
          },
          "template": {
            "$ref": "#/components/schemas/TemplateItem"
          },
          "app_id": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "width": {
            "type": "number",
            "format": "double"
          },
          "sort_order": {
            "type": "number",
            "format": "double"
          },
          "policy": {
            "$ref": "#/components/schemas/PolicyItem"
          },
          "org_id": {
            "type": "string"
          },
          "migration": {
            "type": "object"
          },
          "created": {
            "type": "string",
            "format": "date-time"
          },
          "comments": {
            "$ref": "#/components/schemas/Comments"
          }
        },
        "required": [
          "auth_user_id",
          "org_id",
          "app_id",
          "created",
          "view_count"
        ]
      },
      "MoesifPriceTier": {
        "properties": {
          "up_to": {
            "type": "util.either[scala.long,string]"
          },
          "unit_price_in_decimal": {
            "type": "string"
          },
          "flat_price_in_decimal": {
            "type": "string"
          }
        },
        "required": [
          "up_to"
        ]
      },
      "BillingMeterDocument": {
        "properties": {
          "name": {
            "type": "string"
          },
          "billing_plan": {
            "$ref": "#/components/schemas/BillingPlan"
          },
          "url_query": {
            "type": "string"
          },
          "_id": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "es_query": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "app_id": {
            "type": "string"
          },
          "org_id": {
            "type": "string"
          }
        },
        "required": [
          "org_id",
          "app_id",
          "slug",
          "name",
          "es_query",
          "url_query",
          "status",
          "billing_plan",
          "created_at",
          "modified_at"
        ]
      },
      "KeyValuePair": {
        "properties": {
          "key": {
            "type": "string"
          },
          "val": {
            "type": "string"
          }
        },
        "required": [
          "key",
          "val"
        ]
      },
      "ProviderReporting": {
        "properties": {
          "reporting_period": {
            "type": "string"
          }
        }
      },
      "AppResponseDTO": {
        "properties": {
          "name": {
            "type": "string"
          },
          "custom_app_id": {
            "type": "string"
          },
          "search_api_base_url": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "id": {
            "type": "string"
          },
          "portal_api_base_url": {
            "type": "string"
          },
          "secure_proxy": {
            "type": "boolean"
          },
          "time_zone": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ]
      },
      "CohortUpdateItem": {
        "properties": {
          "channels": {
            "type": "array[string]"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "url_query": {
            "type": "string"
          },
          "criteria": {
            "type": "object"
          },
          "sample_rate": {
            "type": "integer",
            "format": "int32"
          },
          "notification_rule": {
            "$ref": "#/components/schemas/NotificationRule"
          },
          "cohort_name": {
            "type": "string"
          },
          "to": {
            "type": "string"
          },
          "week_starts_on": {
            "type": "integer",
            "format": "int32"
          },
          "locked_by": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "cohort_type": {
            "type": "string"
          },
          "time_zone": {
            "type": "string"
          }
        },
        "required": [
          "cohort_type"
        ]
      },
      "EmailTemplateUpdateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "cohorts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Cohort"
            }
          },
          "dynamic_fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DynamicField"
            }
          },
          "content": {
            "$ref": "#/components/schemas/TemplateContent"
          },
          "template": {
            "$ref": "#/components/schemas/TemplateConfig"
          },
          "period": {
            "type": "string"
          },
          "addresses": {
            "$ref": "#/components/schemas/EmailAddresses"
          }
        }
      },
      "RecurlyPlan": {
        "properties": {
          "name": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "code": {
            "type": "string"
          }
        },
        "required": [
          "code"
        ]
      },
      "StripeProduct": {
        "properties": {
          "name": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "unit_label": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "usage_type": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "id"
        ]
      },
      "BillingParams": {
        "properties": {
          "usage_rounding_mode": {
            "type": "string"
          },
          "webhook_params": {
            "$ref": "#/components/schemas/BillingWebhookParams"
          },
          "recurly_params": {
            "$ref": "#/components/schemas/RecurlyBillingParams"
          },
          "chargebee_params": {
            "$ref": "#/components/schemas/ChargebeeBillingParams"
          },
          "stripe_params": {
            "$ref": "#/components/schemas/StripeBillingParams"
          },
          "zuora_params": {
            "$ref": "#/components/schemas/ZuoraBillingParams"
          },
          "usage_multiplier": {
            "type": "double"
          }
        }
      },
      "RecurlyBillingParams": {
        "properties": {
          "plan": {
            "$ref": "#/components/schemas/RecurlyPlan"
          },
          "add_on": {
            "$ref": "#/components/schemas/RecurlyPlanAddOn"
          },
          "add_ons": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecurlyPlanAddOn"
            }
          }
        }
      },
      "GovernanceRulesDocument": {
        "properties": {
          "name": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "model": {
            "type": "string"
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "cohorts": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "_id": {
            "type": "string"
          },
          "variables": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GovernanceRulesVariables"
            }
          },
          "applied_to": {
            "type": "string"
          },
          "block": {
            "type": "boolean"
          },
          "response": {
            "$ref": "#/components/schemas/RulesResponseItem"
          },
          "applied_to_unidentified": {
            "type": "boolean"
          },
          "regex_config": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RegexRule"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "app_id": {
            "type": "string"
          },
          "plans": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Plan"
            }
          },
          "type": {
            "type": "string"
          },
          "org_id": {
            "type": "string"
          }
        },
        "required": [
          "created_at",
          "type",
          "state",
          "org_id",
          "app_id",
          "name",
          "block"
        ]
      },
      "BillingPlan": {
        "properties": {
          "provider_slug": {
            "type": "string"
          },
          "friendly_name": {
            "type": "string"
          },
          "params": {
            "$ref": "#/components/schemas/BillingParams"
          }
        },
        "required": [
          "provider_slug"
        ]
      },
      "SubmitData": {
        "properties": {
          "body": {
            "type": "object"
          },
          "url": {
            "type": "string"
          },
          "params": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KeyValuePair"
            }
          },
          "verb": {
            "type": "string"
          },
          "headers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KeyValuePair"
            }
          }
        },
        "required": [
          "url",
          "verb"
        ]
      },
      "ProviderRequest": {
        "properties": {
          "success": {
            "type": "boolean"
          },
          "status_code": {
            "type": "integer",
            "format": "int32"
          },
          "job_id": {
            "type": "string"
          },
          "error_message": {
            "type": "string"
          },
          "error_code": {
            "type": "string"
          },
          "request_time": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "job_id",
          "request_time",
          "success",
          "status_code",
          "error_code",
          "error_message"
        ]
      },
      "CommentItem": {
        "properties": {
          "message": {
            "type": "string"
          },
          "mentions": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "NotificationRule": {
        "properties": {
          "send_on_addition": {
            "type": "boolean"
          },
          "send_on_removal": {
            "type": "boolean"
          },
          "period": {
            "type": "string"
          },
          "fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "send_on_addition",
          "send_on_removal"
        ]
      },
      "TemplateItem": {
        "properties": {
          "dynamic_fields": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "dynamic_time": {
            "type": "boolean"
          }
        },
        "required": [
          "dynamic_fields"
        ]
      },
      "Summary": {
        "properties": {
          "count": {
            "type": "integer",
            "format": "int32"
          },
          "latest_comment": {
            "$ref": "#/components/schemas/CreateCommentItem"
          }
        },
        "required": [
          "count"
        ]
      },
      "GovernanceRuleUpdateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "priority": {
            "type": "integer",
            "format": "int32"
          },
          "model": {
            "type": "string"
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "cohorts": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "variables": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GovernanceRulesVariables"
            }
          },
          "applied_to": {
            "type": "string"
          },
          "block": {
            "type": "boolean"
          },
          "response": {
            "$ref": "#/components/schemas/RulesResponseItem"
          },
          "applied_to_unidentified": {
            "type": "boolean"
          },
          "regex_config": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RegexRule"
            }
          },
          "plans": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Plan"
            }
          },
          "type": {
            "type": "string"
          }
        }
      },
      "WorkspaceUpdateItem": {
        "properties": {
          "name": {
            "type": "string"
          },
          "colors": {
            "type": "object"
          },
          "drawings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DrawingItem"
            }
          },
          "chart": {
            "$ref": "#/components/schemas/ChartItem"
          },
          "template": {
            "$ref": "#/components/schemas/TemplateItem"
          },
          "width": {
            "type": "number",
            "format": "double"
          },
          "sort_order": {
            "type": "number",
            "format": "double"
          },
          "policy": {
            "$ref": "#/components/schemas/PolicyItem"
          }
        }
      },
      "BillingWebhookParams": {
        "properties": {
          "reporting": {
            "$ref": "#/components/schemas/CustomReporting"
          },
          "channel_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "custom_plan": {
            "$ref": "#/components/schemas/CustomReportPlan"
          }
        },
        "required": [
          "channel_ids",
          "custom_plan"
        ]
      },
      "searchUsersResponseDTO": {
        "properties": {
          "took": {
            "type": "integer",
            "default": 0,
            "examples": [
              11
            ]
          },
          "timed_out": {
            "type": "boolean",
            "default": false,
            "examples": [
              false
            ]
          },
          "hits": {
            "type": "object",
            "properties": {
              "total": {
                "type": "integer",
                "default": 0,
                "examples": [
                  420
                ]
              },
              "hits": {
                "type": "array",
                "items": {
                  "type": "object",
                  "$ref": "#/components/schemas/userResponseDTO"
                }
              }
            }
          }
        },
        "user_response_d_t_o": {
          "properties": {
            "_id": {
              "type": "string",
              "default": "",
              "examples": [
                "123456"
              ]
            },
            "_source": {
              "type": "object",
              "properties": {
                "first_name": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "John"
                  ]
                },
                "body": {
                  "type": "object"
                },
                "name": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "John Doe"
                  ]
                },
                "email": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "john.doe@gmail.com"
                  ]
                },
                "first_seen_time": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "2023-07-27T21:52:58.0990000Z"
                  ]
                },
                "user_agent": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "Android"
                      ]
                    },
                    "os_major": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "7"
                      ]
                    },
                    "os": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "Android 7.0"
                      ]
                    },
                    "os_name": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "Android"
                      ]
                    },
                    "os_minor": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "0"
                      ]
                    },
                    "major": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "7"
                      ]
                    },
                    "device": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "Samsung SM-G955U"
                      ]
                    },
                    "minor": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "0"
                      ]
                    }
                  }
                },
                "geo_ip": {
                  "type": "object",
                  "properties": {
                    "ip": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "107.200.85.196"
                      ]
                    },
                    "region_name": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "South Carolina"
                      ]
                    },
                    "continent_code": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "NA"
                      ]
                    },
                    "location": {
                      "type": "object",
                      "properties": {
                        "lon": {
                          "type": "double",
                          "default": 0,
                          "examples": [
                            -79.85489654541016
                          ]
                        },
                        "lat": {
                          "type": "double",
                          "default": 0,
                          "examples": [
                            32.822898864746094
                          ]
                        }
                      }
                    },
                    "latitude": {
                      "type": "double",
                      "default": 0,
                      "examples": [
                        32.822898864746094
                      ]
                    },
                    "timezone": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "America/New_York"
                      ]
                    },
                    "longitude": {
                      "type": "double",
                      "default": 0,
                      "examples": [
                        -79.85489654541016
                      ]
                    },
                    "dma_code": {
                      "type": "integer",
                      "default": 0,
                      "examples": [
                        519
                      ]
                    },
                    "postal_code": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "29464"
                      ]
                    },
                    "region_code": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "SC"
                      ]
                    },
                    "city_name": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "Mt. Pleasant"
                      ]
                    },
                    "country_code2": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "US"
                      ]
                    },
                    "country_code3": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "US"
                      ]
                    },
                    "country_name": {
                      "type": "string",
                      "default": "",
                      "examples": [
                        "United States"
                      ]
                    }
                  }
                },
                "modified_time": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "2023-07-27T21:55:19.464"
                  ]
                },
                "last_name": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "Doe"
                  ]
                },
                "ip_address": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "107.200.85.196"
                  ]
                },
                "session_token": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "ZH3V67YNS31MDG0vhzwT3qXEoY0Ltlii"
                    ]
                  }
                },
                "last_seen_time": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "2023-07-27T21:52:58.0990000Z"
                  ]
                },
                "app_id": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "198:3"
                  ]
                },
                "org_id": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "177:3"
                  ]
                }
              }
            },
            "sort": {
              "type": "array",
              "items": {
                "type": "integer",
                "default": 0,
                "examples": [
                  1519768519464
                ]
              }
            }
          }
        }
      },
      "SubscriptionDTO": {
        "properties": {
          "trial_start": {
            "type": "string",
            "format": "date-time"
          },
          "company_id": {
            "type": "string"
          },
          "start_date": {
            "type": "string",
            "format": "date-time"
          },
          "collection_method": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SubscriptionItem"
            }
          },
          "current_period_start": {
            "type": "string",
            "format": "date-time"
          },
          "company_external_id": {
            "type": "string"
          },
          "payment_status": {
            "type": "string"
          },
          "modified_time": {
            "type": "string",
            "format": "date-time"
          },
          "cancel_time": {
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "type": "string"
          },
          "trial_end": {
            "type": "string",
            "format": "date-time"
          },
          "external_id": {
            "type": "string"
          },
          "metadata": {
            "type": "object"
          },
          "app_id": {
            "type": "string"
          },
          "subscription_id": {
            "type": "string"
          },
          "version_id": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "current_period_end": {
            "type": "string",
            "format": "date-time"
          },
          "org_id": {
            "type": "string"
          },
          "created": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "org_id",
          "app_id",
          "type",
          "subscription_id",
          "company_id",
          "status"
        ]
      },
      "searchEventsResponseDTO": {
        "properties": {
          "took": {
            "type": "integer",
            "default": 0,
            "examples": [
              358
            ]
          },
          "timed_out": {
            "type": "boolean",
            "default": false,
            "examples": [
              false
            ]
          },
          "hits": {
            "type": "object",
            "properties": {
              "total": {
                "type": "integer",
                "default": 0,
                "examples": [
                  947
                ]
              },
              "hits": {
                "type": "array",
                "items": {
                  "type": "object",
                  "$ref": "#/components/schemas/eventResponseDTO"
                }
              }
            }
          }
        }
      },
      "searchcompanysResponseDTO": {
        "properties": {
          "took": {
            "type": "integer",
            "default": 0,
            "examples": [
              11
            ]
          },
          "timed_out": {
            "type": "boolean",
            "default": false,
            "examples": [
              false
            ]
          },
          "hits": {
            "type": "object",
            "properties": {
              "total": {
                "type": "integer",
                "default": 0,
                "examples": [
                  420
                ]
              },
              "hits": {
                "type": "array",
                "items": {
                  "type": "object",
                  "$ref": "#/components/schemas/companyResponseDTO"
                }
              }
            }
          }
        },
        "company_response_d_t_o": {
          "properties": {
            "_id": {
              "type": "string",
              "default": "",
              "examples": [
                "123456"
              ]
            },
            "_source": {
              "type": "object",
              "properties": {
                "body": {
                  "type": "object"
                },
                "first_seen_time": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "2023-07-27T21:52:58.0990000Z"
                  ]
                },
                "domain_name": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "John"
                  ]
                },
                "modified_time": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "2023-07-27T21:55:19.464"
                  ]
                },
                "session_token": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "WcgkoP1VE5zAApvVDvP7yckYAsLhG1Jl"
                    ]
                  }
                }
              }
            },
            "sort": {
              "type": "array",
              "items": {
                "type": "integer",
                "default": 0,
                "examples": [
                  1519768519464
                ]
              }
            }
          }
        }
      },
      "UserUpdateDTO": {
        "properties": {
          "company_id": {
            "type": "string"
          },
          "first_name": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "photo_url": {
            "type": "string"
          },
          "user_id": {
            "type": "string"
          },
          "modified_time": {
            "type": "string",
            "format": "date-time"
          },
          "last_name": {
            "type": "string"
          },
          "metadata": {
            "type": "object"
          },
          "user_name": {
            "type": "string"
          },
          "phone": {
            "type": "string"
          }
        },
        "required": [
          "user_id"
        ]
      },
      "SubscriptionItem": {
        "properties": {
          "item_price_id": {
            "type": "string"
          },
          "price_id": {
            "type": "string"
          },
          "is_metered": {
            "type": "boolean"
          },
          "plan_id": {
            "type": "string"
          },
          "unit_of_measure": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "subscription_item_id": {
            "type": "string"
          }
        },
        "required": [
          "plan_id"
        ]
      },
      "userResponseDTO": {
        "properties": {
          "_id": {
            "type": "string",
            "default": "",
            "examples": [
              "123456"
            ]
          },
          "_source": {
            "type": "object",
            "properties": {
              "first_name": {
                "type": "string",
                "default": "",
                "examples": [
                  "John"
                ]
              },
              "body": {
                "type": "object"
              },
              "name": {
                "type": "string",
                "default": "",
                "examples": [
                  "John Doe"
                ]
              },
              "email": {
                "type": "string",
                "default": "",
                "examples": [
                  "john.doe@gmail.com"
                ]
              },
              "first_seen_time": {
                "type": "string",
                "default": "",
                "examples": [
                  "2023-07-27T21:52:58.0990000Z"
                ]
              },
              "user_agent": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "Android"
                    ]
                  },
                  "os_major": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "7"
                    ]
                  },
                  "os": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "Android 7.0"
                    ]
                  },
                  "os_name": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "Android"
                    ]
                  },
                  "os_minor": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "0"
                    ]
                  },
                  "major": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "7"
                    ]
                  },
                  "device": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "Samsung SM-G955U"
                    ]
                  },
                  "minor": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "0"
                    ]
                  }
                }
              },
              "geo_ip": {
                "type": "object",
                "properties": {
                  "ip": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "107.200.85.196"
                    ]
                  },
                  "region_name": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "South Carolina"
                    ]
                  },
                  "continent_code": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "NA"
                    ]
                  },
                  "location": {
                    "type": "object",
                    "properties": {
                      "lon": {
                        "type": "double",
                        "default": 0,
                        "examples": [
                          -79.85489654541016
                        ]
                      },
                      "lat": {
                        "type": "double",
                        "default": 0,
                        "examples": [
                          32.822898864746094
                        ]
                      }
                    }
                  },
                  "latitude": {
                    "type": "double",
                    "default": 0,
                    "examples": [
                      32.822898864746094
                    ]
                  },
                  "timezone": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "America/New_York"
                    ]
                  },
                  "longitude": {
                    "type": "double",
                    "default": 0,
                    "examples": [
                      -79.85489654541016
                    ]
                  },
                  "dma_code": {
                    "type": "integer",
                    "default": 0,
                    "examples": [
                      519
                    ]
                  },
                  "postal_code": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "29464"
                    ]
                  },
                  "region_code": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "SC"
                    ]
                  },
                  "city_name": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "Mt. Pleasant"
                    ]
                  },
                  "country_code2": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "US"
                    ]
                  },
                  "country_code3": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "US"
                    ]
                  },
                  "country_name": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "United States"
                    ]
                  }
                }
              },
              "modified_time": {
                "type": "string",
                "default": "",
                "examples": [
                  "2023-07-27T21:55:19.464"
                ]
              },
              "last_name": {
                "type": "string",
                "default": "",
                "examples": [
                  "Doe"
                ]
              },
              "ip_address": {
                "type": "string",
                "default": "",
                "examples": [
                  "107.200.85.196"
                ]
              },
              "session_token": {
                "type": "array",
                "items": {
                  "type": "string",
                  "default": "",
                  "examples": [
                    "e93u2jiry8fij8q09-tfZ9SIK9DERDXUYMF"
                  ]
                }
              },
              "last_seen_time": {
                "type": "string",
                "default": "",
                "examples": [
                  "2023-07-27T21:52:58.0990000Z"
                ]
              },
              "app_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "198:3"
                ]
              },
              "org_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "177:3"
                ]
              }
            }
          },
          "sort": {
            "type": "array",
            "items": {
              "type": "integer",
              "default": 0,
              "examples": [
                1519768519464
              ]
            }
          }
        }
      },
      "eventResponseDTO": {
        "properties": {
          "_id": {
            "type": "string",
            "default": "",
            "examples": [
              "AWF5M-FDTqLFD8l5y2f4"
            ]
          },
          "_source": {
            "type": "object",
            "properties": {
              "company_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "67890"
                ]
              },
              "duration_ms": {
                "type": "integer",
                "default": 0,
                "examples": [
                  76
                ]
              },
              "request": {
                "type": "object",
                "properties": {
                  "body": {
                    "type": "object",
                    "examples": [
                      "json",
                      "base64"
                    ]
                  },
                  "uri": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "https://api.github.com"
                    ]
                  },
                  "user_agent": {
                    "type": "object",
                    "properties": {
                      "patch": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "1"
                        ]
                      },
                      "major": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "7"
                        ]
                      },
                      "minor": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "1"
                        ]
                      },
                      "name": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "PostmanRuntime"
                        ]
                      }
                    }
                  },
                  "geo_ip": {
                    "type": "object",
                    "properties": {
                      "ip": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "73.189.235.253"
                        ]
                      },
                      "region_name": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "CA"
                        ]
                      },
                      "continent_code": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "NA"
                        ]
                      },
                      "location": {
                        "type": "array",
                        "items": {
                          "type": "double",
                          "default": 0,
                          "examples": [
                            -122.393,
                            37.769
                          ]
                        }
                      },
                      "latitude": {
                        "type": "double",
                        "default": 0,
                        "examples": [
                          37.769
                        ]
                      },
                      "timezone": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "America/Los_Angeles"
                        ]
                      },
                      "area_code": {
                        "type": "integer",
                        "default": 0,
                        "examples": [
                          415
                        ]
                      },
                      "longitude": {
                        "type": "double",
                        "default": 0,
                        "examples": [
                          -122.393
                        ]
                      },
                      "real_region_name": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "California"
                        ]
                      },
                      "dma_code": {
                        "type": "integer",
                        "default": 0,
                        "examples": [
                          807
                        ]
                      },
                      "postal_code": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "94107"
                        ]
                      },
                      "city_name": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "San Francisco"
                        ]
                      },
                      "country_code2": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "US"
                        ]
                      },
                      "country_code3": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "USA"
                        ]
                      },
                      "country_name": {
                        "type": "string",
                        "default": "",
                        "examples": [
                          "United States"
                        ]
                      }
                    }
                  },
                  "ip_address": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "73.189.235.253"
                    ]
                  },
                  "verb": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "GET"
                    ]
                  },
                  "route": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "/"
                    ]
                  },
                  "time": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "2023-07-09T06:14:58.550"
                    ]
                  },
                  "headers": {
                    "type": "object"
                  }
                }
              },
              "user_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "123454"
                ]
              },
              "company": {
                "type": "object"
              },
              "response": {
                "type": "object",
                "properties": {
                  "body": {
                    "type": "object"
                  },
                  "transfer_encoding": {
                    "type": "string",
                    "examples": [
                      "json",
                      "base64"
                    ]
                  },
                  "status": {
                    "type": "integer",
                    "default": 0,
                    "examples": [
                      200
                    ]
                  },
                  "time": {
                    "type": "string",
                    "default": "",
                    "examples": [
                      "2023-07-09T06:14:58.626"
                    ]
                  },
                  "headers": {
                    "type": "object"
                  }
                }
              },
              "id": {
                "type": "string",
                "default": "",
                "examples": [
                  "AWF5M-FDTqLFD8l5y2f4"
                ]
              },
              "event_type": {
                "type": "string",
                "examples": [
                  "api_call",
                  "user_action"
                ]
              },
              "session_token": {
                "type": "string",
                "default": "",
                "examples": [
                  "rdfmnw3fu24309efjc534nb421UZ9-]2JDO[ME"
                ]
              },
              "metadata": {
                "type": "object"
              },
              "app_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "198:3"
                ]
              },
              "org_id": {
                "type": "string",
                "default": "",
                "examples": [
                  "177:3"
                ]
              },
              "user": {
                "type": "object"
              }
            }
          },
          "sort": {
            "type": "array",
            "items": {
              "type": "integer",
              "default": 0
            }
          }
        }
      },
      "AddSubscriptionDTO": {
        "properties": {
          "trial_start": {
            "type": "string",
            "format": "date-time"
          },
          "company_id": {
            "type": "string"
          },
          "start_date": {
            "type": "string",
            "format": "date-time"
          },
          "collection_method": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SubscriptionItem"
            }
          },
          "current_period_start": {
            "type": "string",
            "format": "date-time"
          },
          "company_external_id": {
            "type": "string"
          },
          "payment_status": {
            "type": "string"
          },
          "cancel_time": {
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "type": "string"
          },
          "trial_end": {
            "type": "string",
            "format": "date-time"
          },
          "external_id": {
            "type": "string"
          },
          "metadata": {
            "type": "object"
          },
          "subscription_id": {
            "type": "string"
          },
          "version_id": {
            "type": "string"
          },
          "current_period_end": {
            "type": "string",
            "format": "date-time"
          },
          "created": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "subscription_id",
          "company_id",
          "status"
        ]
      },
      "CompanyUpdateDTO": {
        "properties": {
          "company_id": {
            "type": "string"
          },
          "modified_time": {
            "type": "string",
            "format": "date-time"
          },
          "session_token": {
            "type": "string"
          },
          "company_domain": {
            "type": "string"
          },
          "metadata": {
            "type": "object"
          }
        },
        "required": [
          "company_id"
        ]
      }
    }
  },
  "consumes": [
    "application/json",
    "application/json"
  ],
  "externalDocs": {
    "description": "Developer Docs",
    "url": "https://moesif.com/docs"
  },
  "info": {
    "description": "Management API to query data in Moesif. You can use the management API to export data for custom reports or to build custom dashboards.",
    "contact": [
      {
        "email": "support@moesif.com"
      },
      {
        "email": "support@moesif.com"
      }
    ],
    "termsOfService": "https://www.moesif.com/terms",
    "version": "1",
    "title": "Management API"
  },
  "openapi": "3.0.0",
  "paths": {
    "/search/~/companies": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:companies",
              "update:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "operationId": "updateCompanies",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CompanyUpdateDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Update a Company",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/companyResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/companies/batch": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:companies",
              "update:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "operationId": "batchUpdateCompanies",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CompanyUpdateDTO"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Update Companies in Batch",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/companyResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/companies/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "operationId": "getCompany",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a Company",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/companyResponseDTO"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "operationId": "deleteCompany",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "name": "delete_events",
            "in": "query",
            "description": "Delete events associated with the company which can be set to true or false(default)",
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "required": false
          }
        ],
        "summary": "Delete a Company",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/search/~/companies/{id}/subscriptions": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:companies"
            ]
          }
        ],
        "tags": [
          "Subscriptions"
        ],
        "operationId": "getCompanySubscriptions",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get the Subscriptions of a Company",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/companyResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/count/companies": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "documentation": "http://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html",
        "operationId": "countCompanies",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          }
        ],
        "summary": "Count Companies",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/count/events": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:events"
            ]
          }
        ],
        "tags": [
          "Metrics"
        ],
        "documentation": "http://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html",
        "operationId": "countEvents",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "name": "from",
            "in": "query",
            "description": "The start date, which can be absolute such as 2019-07-01T00:00:00Z or relative such as -24h",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          },
          {
            "name": "to",
            "in": "query",
            "description": "The end date, which can be absolute such as 2019-07-02T00:00:00Z or relative such as now",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          },
          {
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "in": "query",
            "name": "track_total_hits",
            "required": false
          }
        ],
        "summary": "Count Events",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/count/users": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "documentation": "http://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html",
        "operationId": "countUsers",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          }
        ],
        "summary": "Count Users",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/events/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:events"
            ]
          }
        ],
        "tags": [
          "Metrics"
        ],
        "operationId": "getEvent",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "event_time",
            "required": true
          }
        ],
        "summary": "Get an Event",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/eventResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/companies/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:company_properties"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          }
        ],
        "summary": "Get Property Mapping for Companies",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/companymetrics/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:companies"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": false
          }
        ],
        "summary": "Get Property Mapping for CompanyMetrics",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/events/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:properties"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "to",
            "required": false
          }
        ],
        "summary": "Get Property Mapping for Events",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/events/request/body/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:request_body_properties"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getRequestBodyProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "to",
            "required": true
          },
          {
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "in": "query",
            "name": "include_values",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "key_path",
            "required": false
          }
        ],
        "summary": "Get Property Mapping for Events Request Body",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/events/response/body/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:response_body_properties"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getResponseBodyProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "to",
            "required": true
          },
          {
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "in": "query",
            "name": "include_values",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "key_path",
            "required": false
          }
        ],
        "summary": "Get Property Mapping for Events Response Body",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/usermetrics/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:users"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": false
          }
        ],
        "summary": "Get Property Mapping for UserMetrics",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/mappings/users/properties": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:users"
            ]
          }
        ],
        "tags": [
          "Properties"
        ],
        "operationId": "getProperties",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          }
        ],
        "summary": "Get Property Mapping for Users",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/object"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/search/companymetrics/companies": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:companies"
            ]
          }
        ],
        "tags": [
          "Companies"
        ],
        "documentation": "https://www.moesif.com/docs/api#pagination-and-filtering",
        "operationId": "searchCompanyMetrics",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "description": "The search definition using the Elasticsearch Query DSL",
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "name": "from",
            "in": "query",
            "description": "The start date, which can be absolute such as 2023-07-01T00:00:00Z or relative such as -24h",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": false
          },
          {
            "name": "to",
            "in": "query",
            "description": "The end date, which can be absolute such as 2023-07-02T00:00:00Z or relative such as now",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": false
          }
        ],
        "summary": "Search CompanyMetrics/Companies",
        "responses": {
          "200": {
            "description": "success",
            "content": "application/json"
          }
        }
      }
    },
    "/search/~/search/events": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:events"
            ]
          }
        ],
        "tags": [
          "Metrics"
        ],
        "documentation": "https://www.moesif.com/docs/api#pagination-and-filtering",
        "operationId": "searchEvents",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "description": "The search definition using the Elasticsearch Query DSL",
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "name": "from",
            "in": "query",
            "description": "The start date, which can be absolute such as 2023-07-01T00:00:00Z or relative such as -24h",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          },
          {
            "name": "to",
            "in": "query",
            "description": "The end date, which can be absolute such as 2023-07-02T00:00:00Z or relative such as now",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          }
        ],
        "summary": "Search Events",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/searchEventsResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/search/usermetrics/users": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "documentation": "https://www.moesif.com/docs/api#pagination-and-filtering",
        "operationId": "searchUserMetrics",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "description": "The search definition using the Elasticsearch Query DSL",
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "name": "from",
            "in": "query",
            "description": "The start date, which can be absolute such as 2023-07-01T00:00:00Z or relative such as -24h",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": false
          },
          {
            "name": "to",
            "in": "query",
            "description": "The end date, which can be absolute such as 2023-07-02T00:00:00Z or relative such as now",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": false
          }
        ],
        "summary": "Search UserMetrics/Users",
        "responses": {
          "200": {
            "description": "success",
            "content": "application/json"
          }
        }
      }
    },
    "/search/~/subscriptions": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:subscriptions",
              "update:subscriptions"
            ]
          }
        ],
        "tags": [
          "Subscriptions"
        ],
        "operationId": "createSubscription",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddSubscriptionDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create or Update a Subscription",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/subscriptions/batch": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:subscriptions",
              "update:subscriptions"
            ]
          }
        ],
        "tags": [
          "Subscriptions"
        ],
        "operationId": "batchCreateSubscriptions",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddSubscriptionDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create or Update Subscriptions in Batch",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/subscriptions/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:subscriptions"
            ]
          }
        ],
        "tags": [
          "Subscriptions"
        ],
        "operationId": "getSubscription",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a Subscription",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/users": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:users",
              "update:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "operationId": "updateUsers",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserUpdateDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Update a User",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/userResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/users/batch": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:users",
              "update:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "operationId": "batchUpdateUsers",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/UserUpdateDTO"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Update Users in Batch",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/userResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/search/~/users/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "operationId": "getUser",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a User",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/userResponseDTO"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:users"
            ]
          }
        ],
        "tags": [
          "Users"
        ],
        "operationId": "deleteUser",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "name": "delete_events",
            "in": "query",
            "description": "Delete events associated with the user which can be set to true or false(default)",
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "required": false
          }
        ],
        "summary": "Delete a User",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/search/~/workspaces/{workspaceId}/search": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "read:events"
            ]
          }
        ],
        "tags": [
          "Metrics"
        ],
        "documentation": "https://www.moesif.com/docs/api#pagination-and-filtering",
        "operationId": "searchPublicWorkspaces",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "description": "The search definition using the Elasticsearch Query DSL",
              "schema": {
                "$ref": "#/components/schemas/object"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "name": "from",
            "in": "query",
            "description": "The start date, which can be absolute such as 2023-07-01T00:00:00Z or relative such as -24h",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          },
          {
            "name": "to",
            "in": "query",
            "description": "The end date, which can be absolute such as 2023-07-02T00:00:00Z or relative such as now",
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "workspaceId",
            "required": true
          },
          {
            "schema": {
              "default": false,
              "type": "boolean"
            },
            "in": "query",
            "name": "include_details",
            "required": false
          },
          {
            "schema": {
              "default": 1000,
              "format": "int32",
              "type": "integer"
            },
            "in": "query",
            "name": "take",
            "required": false
          }
        ],
        "summary": "Search Events in saved public Workspace",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/searchEventsResponseDTO"
                }
              }
            }
          }
        }
      }
    },
    "/workspaces/access_token": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:workspaces"
            ]
          }
        ],
        "description": "Get a new Workspace Access Token",
        "tags": [
          "Workspaces"
        ],
        "operationId": "getWorkspaceToken",
        "summary": "Get new Workspace Token",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SignedTokenDTO"
                }
              }
            }
          }
        }
      }
    },
    "/workspaces/public/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:public_workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "getPublicWorkspace",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a Public Workspace",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceDocument"
                }
              }
            }
          }
        }
      }
    },
    "/~/apps": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:apps"
            ]
          }
        ],
        "description": "Create a new app under the selected organization",
        "tags": [
          "Applications"
        ],
        "operationId": "addApp",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AppCreateDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          }
        ],
        "summary": "Create a new App",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AppResponseDTO"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:apps"
            ]
          }
        ],
        "description": "Gets a list of apps for the selected organization",
        "tags": [
          "Applications"
        ],
        "operationId": "getApps",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "format": "int32",
              "type": "integer"
            },
            "in": "query",
            "name": "take",
            "required": true
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "before_id",
            "required": false
          }
        ],
        "summary": "Gets Apps",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppResponseDTO"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/apps/{id}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:apps"
            ]
          }
        ],
        "description": "Update the name of the app for the selected organization",
        "tags": [
          "Applications"
        ],
        "operationId": "updateApp",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AppUpdateDTO"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Update Apps",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AppUpdateDTO"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:apps"
            ]
          }
        ],
        "description": "Delete the app for the selected organization",
        "tags": [
          "Applications"
        ],
        "operationId": "deleteApp",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Delete Apps",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/billing/catalog/plans": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:plans"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "createMoesifPlan",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoesifPlan"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Create a new Moesif Plan",
        "responses": {
          "201": {
            "description": "created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPlan"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:plans"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "listMoesifPlans",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "default": "all",
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": false
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "includes",
            "required": false
          }
        ],
        "summary": "List all Moesif Plans",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MoesifPlan"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/catalog/plans/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:plans"
            ]
          }
        ],
        "description": "Get the Moesif Plan for authenticated users",
        "tags": [
          "Product Catalog"
        ],
        "operationId": "getMoesifPlan",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Get a Moesif Plan",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPlan"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:plans"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "deleteMoesifPlan",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Delete a Moesif Plan",
        "responses": {
          "204": {
            "description": "no content"
          }
        }
      },
      "put": {
        "security": [
          {
            "managementAPIToken": [
              "update:plans"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "updateMoesifPlan",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoesifPlan"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Update a Moesif Plan",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPlan"
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/catalog/prices": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:prices"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "createMoesifPrice",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoesifPrice"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Create a new Moesif Price",
        "responses": {
          "201": {
            "description": "created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPrice"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:prices"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "listMoesifPrices",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "default": "all",
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": false
          }
        ],
        "summary": "List all Moesif Prices for a specific Plan",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MoesifPrice"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/catalog/prices/{id}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:prices"
            ]
          }
        ],
        "description": "Get the Moesif Price for a specific Plan for authenticated users",
        "tags": [
          "Product Catalog"
        ],
        "operationId": "getMoesifPrice",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Get a Moesif Price",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPrice"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:prices"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "deleteMoesifPrice",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Delete a Moesif Price",
        "responses": {
          "204": {
            "description": "no content"
          }
        }
      },
      "put": {
        "security": [
          {
            "managementAPIToken": [
              "update:prices"
            ]
          }
        ],
        "tags": [
          "Product Catalog"
        ],
        "operationId": "updateMoesifPrice",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoesifPrice"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": true
          }
        ],
        "summary": "Update a Moesif Price",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MoesifPrice"
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/meters": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:billing_meters"
            ]
          }
        ],
        "description": "List Billing Meters",
        "tags": [
          "Billing Meters"
        ],
        "operationId": "listMeters",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "List Billing Meters",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/BillingMeterDocument"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/meters/{meterId}": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:billing_meters"
            ]
          }
        ],
        "description": "Get Billing Meter by id",
        "tags": [
          "Billing Meters"
        ],
        "operationId": "getMeter",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "meterId",
            "required": true
          }
        ],
        "summary": "Get Billing Meter by id",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingMeterDocument"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:billing_meters"
            ]
          }
        ],
        "description": "Delete Billing Meter by id",
        "tags": [
          "Billing Meters"
        ],
        "operationId": "deleteMeter",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "meterId",
            "required": true
          }
        ],
        "summary": "Delete Billing Meter by id",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/billing/reports": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:billing_meters",
              "read:billing_reports"
            ]
          }
        ],
        "description": "Query audit history of billing reports to external billing providers",
        "tags": [
          "Billing Reports"
        ],
        "operationId": "getBillingReports",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "to",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "billing_meter_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "company_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "provider",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "subscription_id",
            "required": false
          },
          {
            "schema": {
              "type": "boolean"
            },
            "in": "query",
            "name": "success",
            "required": false
          },
          {
            "schema": {
              "format": "int32",
              "type": "integer"
            },
            "in": "query",
            "name": "status_code",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "error_code",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "`type`",
            "required": false
          }
        ],
        "summary": "Get BillingReports",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/BillingReport"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/billing/reports/balance_transactions": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:billing_meters",
              "create:billing_reports"
            ]
          }
        ],
        "description": "Post a billing report of type balance_transaction",
        "tags": [
          "Balance Transactions"
        ],
        "operationId": "createBalanceTransaction",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BillingReportBalanceTransCreate"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Post BillingReports Balance Transactions",
        "responses": {
          "204": {
            "description": "success, no content and BillingReports were created or updated"
          }
        }
      }
    },
    "/~/billing/reports/metrics": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "create:billing_meters",
              "create:billing_reports"
            ]
          }
        ],
        "description": "Get BillingReports' values for a given meter and time range for a single company or all companies",
        "tags": [
          "Billing Reports"
        ],
        "operationId": "getBillingReportsMetrics",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "from",
            "required": true
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "to",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "billing_meter_id",
            "required": false
          },
          {
            "schema": {
              "type": "boolean"
            },
            "in": "query",
            "name": "success",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "aggregator",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "interval",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "company_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "subscription_id",
            "required": false
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "in": "query",
            "name": "`type`",
            "required": false
          }
        ],
        "summary": "Get BillingReports' values for a given meter and time range for a single company or all companies",
        "responses": {
          "200": {
            "description": "three buckets of aggregates for the given meter and time range including Metric Value, Reported Usage, and list of errors.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingMetricResponse"
                }
              }
            }
          }
        }
      }
    },
    "/~/cohorts": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "createCohort",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CohortCreateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create New Cohort",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CohortDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "getCohorts",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "cohort_type",
            "required": true
          }
        ],
        "summary": "Get Cohorts",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/cohorts/{cohortId}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "updateCohort",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CohortUpdateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "cohortId",
            "required": true
          }
        ],
        "summary": "Update a Cohort",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "getCohort",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "cohort_type",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "cohortId",
            "required": true
          }
        ],
        "summary": "Get Cohort",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "deleteCohort",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "cohortId",
            "required": true
          }
        ],
        "summary": "Delete Cohort",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/cohorts/{cohortId}/sample_rate": {
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "update:cohorts"
            ]
          }
        ],
        "tags": [
          "Cohorts"
        ],
        "operationId": "deleteCohortSampleRate",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "cohortId",
            "required": true
          }
        ],
        "summary": "Delete Sample Rate for a Cohort",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboard/{dashId}": {
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "deleteDashboards",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "dashId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "parent_id",
            "required": false
          }
        ],
        "summary": "Delete a Dashboard",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboard/{id}/copy": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "copyDashboard",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "to_app_id",
            "required": false
          }
        ],
        "summary": "Copy Dashboard",
        "responses": {
          "201": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboards": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "createDashboard",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create New Dashboard",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DashboardDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "getDashboards",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Get a Dashboard",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboards/copy": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "copyAllDashboards",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "to_app_id",
            "required": true
          }
        ],
        "summary": "Copy All Dashboards",
        "responses": {
          "201": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboards/{dashId}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "updateDashboard",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DashboardUpdateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "dashId",
            "required": true
          }
        ],
        "summary": "Update a Dashboard",
        "responses": {
          "201": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "deleteDashboard",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "dashId",
            "required": true
          }
        ],
        "summary": "Delete a Dashboard",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboards/{dashId}/cascade": {
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "cascadeDeleteDashboard",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "dashId",
            "required": true
          }
        ],
        "summary": "Casccade delete a Dashboard",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/dashboards/{id}/policy/acl": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "addACLPermissions",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "grantee",
            "required": false
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "permission",
            "required": false
          }
        ],
        "summary": "Add Dashboards ACL permission",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:dashboards"
            ]
          }
        ],
        "tags": [
          "Dashboards"
        ],
        "operationId": "deleteACLPermissions",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "grantee",
            "required": true
          }
        ],
        "summary": "Delete Dashboards ACL permission",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/emails/templates": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:email_templates"
            ]
          }
        ],
        "tags": [
          "Email Templates"
        ],
        "operationId": "createEmailTemplate",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EmailTemplateCreateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create New Email Template",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/com.moesif.docdb.emailtemplates.EmailTemplateDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:email_templates"
            ]
          }
        ],
        "tags": [
          "Email Templates"
        ],
        "operationId": "getEmailTemplates",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "cohort_id",
            "required": false
          }
        ],
        "summary": "Get Email Templates",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/emails/templates/{id}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:email_templates"
            ]
          }
        ],
        "tags": [
          "Email Templates"
        ],
        "operationId": "updateEmailTemplate",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EmailTemplateUpdateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Update an Email Template",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:email_templates"
            ]
          }
        ],
        "tags": [
          "Email Templates"
        ],
        "operationId": "getEmailTemplate",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get Email Template",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:email_templates"
            ]
          }
        ],
        "tags": [
          "Email Templates"
        ],
        "operationId": "deleteEmailTemplate",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Delete Email Template",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/governance/rules": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:governance_rules"
            ]
          }
        ],
        "tags": [
          "Governance Rules"
        ],
        "operationId": "createGovernanceRule",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GovernanceRuleCreateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Create New Governance Rules",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GovernanceRulesDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:governance_rules"
            ]
          }
        ],
        "tags": [
          "Governance Rules"
        ],
        "operationId": "getGovernanceRules",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Get Governance Rules",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GovernanceRulesDocument"
                }
              }
            }
          }
        }
      }
    },
    "/~/governance/rules/{id}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:governance_rules"
            ]
          }
        ],
        "tags": [
          "Governance Rules"
        ],
        "operationId": "updateGovernanceRule",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GovernanceRuleUpdateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Update a Governance Rule",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GovernanceRulesDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:governance_rules"
            ]
          }
        ],
        "tags": [
          "Governance Rules"
        ],
        "operationId": "getGovernanceRule",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a Governance Rule",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GovernanceRulesDocument"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:governance_rules"
            ]
          }
        ],
        "tags": [
          "Governance Rules"
        ],
        "operationId": "deleteGovernanceRule",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Delete a Governance Rule",
        "responses": {
          "204": {
            "description": "success"
          }
        }
      }
    },
    "/~/workspaces": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:workspaces",
              "create:public_workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "createWorkspace",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WorkspaceCreateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string",
              "format": "date-time"
            },
            "in": "query",
            "name": "expiration",
            "required": false
          }
        ],
        "summary": "Create New Workspace",
        "responses": {
          "201": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceDocument"
                }
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "getWorkspaces",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "format": "int32",
              "type": "integer"
            },
            "in": "query",
            "name": "take",
            "required": true
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "before_id",
            "required": false
          },
          {
            "schema": {
              "default": "sequence",
              "type": "string"
            },
            "in": "query",
            "name": "`type`",
            "required": false
          },
          {
            "schema": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "in": "query",
            "name": "access",
            "required": true
          }
        ],
        "summary": "Get Workspaces",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/WorkspaceDocument"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/workspaces/templates": {
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "getWorkspaceTemplates",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          }
        ],
        "summary": "Get Workspace Templates",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/WorkspaceDocument"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/~/workspaces/{id}": {
      "post": {
        "body": null,
        "security": [
          {
            "managementAPIToken": [
              "update:workspaces",
              "update:public_workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "updateWorkspace",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WorkspaceUpdateItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Update a Workspace",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "getWorkspace",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get a Workspace",
        "responses": {
          "200": {
            "description": "success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceDocument"
                }
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "deleteWorkspace",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Delete a Workspace",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/workspaces/{id}/comments": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "createComment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CommentItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Create a New Comment",
        "responses": {
          "201": {
            "description": "success"
          }
        }
      },
      "get": {
        "security": [
          {
            "managementAPIToken": [
              "read:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "getComments",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          }
        ],
        "summary": "Get all Comments",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    },
    "/~/workspaces/{id}/comments/{commentId}": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "update:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "updateComment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CommentItem"
              }
            }
          }
        },
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "commentId",
            "required": true
          }
        ],
        "summary": "Update Existing Comment",
        "responses": {
          "201": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "update:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "deleteComment",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "commentId",
            "required": true
          }
        ],
        "summary": "Delete a Comment",
        "responses": {
          "204": {
            "description": "success"
          }
        }
      }
    },
    "/~/workspaces/{id}/policy/acl": {
      "post": {
        "security": [
          {
            "managementAPIToken": [
              "create:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "addACLPermissions",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "grantee",
            "required": false
          },
          {
            "schema": {
              "default": "None",
              "type": "string"
            },
            "in": "query",
            "name": "permission",
            "required": false
          }
        ],
        "summary": "Add ACL permission",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      },
      "delete": {
        "security": [
          {
            "managementAPIToken": [
              "delete:workspaces"
            ]
          }
        ],
        "tags": [
          "Workspaces"
        ],
        "operationId": "deleteACLPermissions",
        "parameters": [
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "orgId",
            "required": true
          },
          {
            "schema": {
              "default": "~",
              "type": "string"
            },
            "in": "query",
            "name": "app_id",
            "required": false
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "path",
            "name": "id",
            "required": true
          },
          {
            "schema": {
              "type": "string"
            },
            "in": "query",
            "name": "grantee",
            "required": true
          }
        ],
        "summary": "Delete ACL permission",
        "responses": {
          "200": {
            "description": "success"
          }
        }
      }
    }
  },
  "produces": [
    "application/json",
    "application/json"
  ],
  "servers": [
    {
      "url": "https://api.moesif.com/v1",
      "description": "Management API V1"
    },
    {
      "url": "https://api.moesif.com/v1",
      "description": "Management API V1"
    }
  ],
  "tags": [
    {
      "name": "routes"
    },
    {
      "name": "routes"
    }
  ]
}