

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Vivox Moderation API",
    "version": "v1",
    "description": "## Overview\n\nThe Vivox Moderation API allows users to moderate Vivox Voice and Text channels in real-time.\n\nFor more information about Vivox Voice and Text Services, refer to our [documentation](https://docs.unity.com/ugs/en-us/manual/vivox-unity/manual/Unity/Unity).\n\nRequest access to these APIs from a Vivox technical account manager or by submitting a request to [Vivox Support](https://support.unity.com/hc/en-us/requests/new?ticket_form_id=360003199531)."
  },
  "servers": [
    {
      "url": "https://services.api.unity.com"
    }
  ],
  "paths": {
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/server-kick": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Kick a user from all channels",
        "description": "Provide a Vivox user uri to kick the game user from all Vivox channels.",
        "tags": [
          "Vivox Server Kick"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerKickBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/kick": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Kick a user from a channel",
        "description": "Kick a user from a single channel by providing the channel URI and the user URI.",
        "tags": [
          "Vivox Channel Kick"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelCmdBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/kick-all": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Kick all users from a channel",
        "description": "Kick all users from a channel by providing the channel URI.",
        "tags": [
          "Vivox Channel Kick All"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelCmdAllBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/mute": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Mute a user in a channel",
        "description": "Mute a user in a channel by providing the channel URI and the user URI.",
        "tags": [
          "Vivox Channel Mute"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelMuteBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/unmute": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Unmute a user in a channel",
        "description": "Unmute a user in a channel by providing the channel URI and the user URI.",
        "tags": [
          "Vivox Channel Unmute"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelMuteBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/mute-all": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Mute all users in a channel",
        "description": "Mute all users in a channel by providing the channel URI.",
        "tags": [
          "Vivox Channel Mute All"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelMuteAllBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    },
    "/vivox/v1/organizations/{organizationId}/projects/{projectId}/unmute-all": {
      "parameters": [
        {
          "$ref": "#/components/parameters/organizationId"
        },
        {
          "$ref": "#/components/parameters/projectId"
        }
      ],
      "post": {
        "summary": "Unmute all users in a channel",
        "description": "Unmute all users in a channel by providing the channel URI.",
        "tags": [
          "Vivox Channel Unmute All"
        ],
        "security": [
          {
            "ServiceAccount": []
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChannelMuteAllBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          },
          "400": {
            "$ref": "#/components/responses/ErrorResponseBadRequest"
          },
          "403": {
            "$ref": "#/components/responses/ErrorResponseForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ErrorResponseNotFound"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponseInternalServerError"
          }
        }
      }
    }
  },
  "components": {
    "parameters": {
      "organizationId": {
        "name": "organizationId",
        "in": "path",
        "required": true,
        "schema": {
          "type": "string"
        },
        "description": "ID of the organization"
      },
      "projectId": {
        "name": "projectId",
        "in": "path",
        "required": true,
        "schema": {
          "type": "string"
        },
        "description": "ID of the project"
      }
    },
    "schemas": {
      "ServerKickBody": {
        "type": "object",
        "required": [
          "user_uri"
        ],
        "properties": {
          "user_uri": {
            "type": "string",
            "description": "The URI of the user to kick"
          }
        }
      },
      "ChannelCmdBody": {
        "type": "object",
        "required": [
          "user_uri",
          "chan_uri"
        ],
        "properties": {
          "user_uri": {
            "type": "string",
            "description": "The URI of the user to moderate"
          },
          "chan_uri": {
            "type": "string",
            "description": "The URI of the channel to moderate"
          }
        }
      },
      "ChannelCmdAllBody": {
        "type": "object",
        "required": [
          "chan_uri"
        ],
        "properties": {
          "chan_uri": {
            "type": "string",
            "description": "The URI of the channel to moderate"
          }
        }
      },
      "ChannelMuteBody": {
        "type": "object",
        "required": [
          "user_uri",
          "chan_uri"
        ],
        "properties": {
          "user_uri": {
            "type": "string",
            "description": "The URI of the user to moderate"
          },
          "chan_uri": {
            "type": "string",
            "description": "The URI of the channel to moderate"
          },
          "scope": {
            "type": "string",
            "enum": [
              "audio",
              "text",
              "all"
            ],
            "default": "all",
            "description": "The type of media to mute or unmute"
          }
        }
      },
      "ChannelMuteAllBody": {
        "type": "object",
        "required": [
          "chan_uri"
        ],
        "properties": {
          "chan_uri": {
            "type": "string",
            "description": "The URI of the channel to moderate"
          },
          "scope": {
            "type": "string",
            "enum": [
              "audio",
              "text",
              "all"
            ],
            "default": "all",
            "description": "The type of media to mute or unmute"
          }
        }
      }
    },
    "responses": {
      "ErrorResponseBadRequest": {
        "description": "Bad Request",
        "content": {
          "application/problem+json": {
            "schema": {
              "properties": {
                "title": {
                  "type": "string",
                  "example": "Bad Request"
                },
                "detail": {
                  "type": "string",
                  "example": "Missing required chan_uri parameter"
                },
                "status": {
                  "type": "integer",
                  "description": "request status code",
                  "example": 400
                },
                "details": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "example": [
                    "project=<projectId>"
                  ],
                  "description": "error status"
                }
              }
            }
          }
        }
      },
      "ErrorResponseForbidden": {
        "description": "Permission Denied",
        "content": {
          "application/problem+json": {
            "schema": {
              "properties": {
                "title": {
                  "type": "string",
                  "example": "Permission Denied"
                },
                "detail": {
                  "type": "string",
                  "example": "The issuer in the channel URI does not match a project issuer"
                },
                "status": {
                  "type": "integer",
                  "description": "request status code",
                  "example": 403
                },
                "details": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "example": [
                    "project=<projectId>"
                  ],
                  "description": "error status"
                }
              }
            }
          }
        }
      },
      "ErrorResponseNotFound": {
        "description": "Not Found",
        "content": {
          "application/problem+json": {
            "schema": {
              "properties": {
                "title": {
                  "type": "string",
                  "example": "Not found"
                },
                "detail": {
                  "type": "string",
                  "example": "The channel is invalid or not an active channel"
                },
                "status": {
                  "type": "integer",
                  "description": "request status code",
                  "example": 404
                },
                "details": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "example": [
                    "project=<projectId>"
                  ],
                  "description": "error status"
                }
              }
            }
          }
        }
      },
      "ErrorResponseInternalServerError": {
        "description": "Internal Server Error",
        "content": {
          "application/json": {
            "schema": {
              "properties": {
                "msg": {
                  "type": "string",
                  "example": "internal server error"
                }
              }
            }
          }
        }
      }
    },
    "securitySchemes": {
      "ServiceAccount": {
        "type": "http",
        "scheme": "basic",
        "description": "To get started with Authentication, refer to the [Service Account Authentication documentation](https://services.docs.unity.com/docs/service-account-auth).\nFor these APIs, you must request the following role(s) for your service account:\n| Purpose | Roles | Permissions |\n| --- | --- | --- |\n| Moderation APIs | Vivox Moderator | <ul><li>vivox.moderation.create</li></ul> |"
      }
    }
  }
}
```