{
  "openapi": "3.0.4",
  "info": {
    "title": "Engauge.Web",
    "version": "1.0"
  },
  "paths": {
    "/api/v1/servers/{id}": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server",
        "description": "Gets a server. May return 404 if the server is private and you are unauthorized.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The server.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Server"
                }
              }
            }
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server does not exist or is private, and you are not authorized."
          }
        }
      },
      "patch": {
        "tags": [
          "Servers"
        ],
        "summary": "Update Server",
        "description": "Update a server. Uses JSON patch. Note that some fields are not patchable.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "description": "A JSON patch document to apply to the server.",
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/ServerJsonPatchDocument"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerJsonPatchDocument"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ServerJsonPatchDocument"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ServerJsonPatchDocument"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Server"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/servers/{id}/@me": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Current User",
        "description": "Gets the state of the current user in the server.\nThis includes the user's stats and their permissions in the server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The user's stats."
          },
          "404": {
            "description": "If the user could not be found."
          }
        }
      }
    },
    "/api/v1/servers/{id}/leaderboard": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Leaderboard",
        "description": "Gets a page of the leaderboard on this server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The rank to start at. This field is zero-indexed, so 0 is 1st.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 0
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "The number of members to show after `start`. Maximum 100.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The leaderboard.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": { }
                }
              }
            }
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/audit": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Audit Log",
        "description": "Gets a page of the audit log on this server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The audit number to start at. This field is zero-indexed, so 0 is 1st.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 0
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "The number of audit entries to show after `start`. Maximum 100.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The audit log."
          },
          "403": {
            "description": "If you do not have access to this server's audit log."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/economy": {
      "delete": {
        "tags": [
          "Servers"
        ],
        "summary": "Delete Server Economy",
        "description": "Resets the server's economy. All members have their currencies back to original.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "On deletion success."
          },
          "403": {
            "description": "If you do not have permission to reset this server's economy."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/members/{memberId}/card": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Member Rank Card",
        "description": "Generates a member's rank card.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A file stream containing the rank card in PNG format."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server could not be found."
          }
        }
      }
    },
    "/api/v1/servers/{id}/leaderboard/card": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Leaderboard Card",
        "description": "Generates a page of the leaderboard card for the server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The rank to start at. Zero-indexed, so 0 is 1st.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum number of places to show. Maximum 10.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A file stream containing the leaderboard card in PNG format."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server could not be found."
          }
        }
      }
    },
    "/api/v1/servers/{id}/crates/{crateId}/drop": {
      "post": {
        "tags": [
          "Servers"
        ],
        "summary": "Drop Crate",
        "description": "Drops a crate. Returns HTTP 400 if the crate is not ready to be dropped yet.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "crateId",
            "in": "path",
            "description": "The ID of the crate.",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "On drop success."
          },
          "400": {
            "description": "If the crate is not ready to be dropped."
          },
          "403": {
            "description": "If you do not have access to drop crates in this server."
          },
          "404": {
            "description": "If the server or crate could not be found."
          }
        }
      }
    },
    "/api/v1/servers/{id}/members": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Members",
        "description": "Gets members in this server. This endpoint has sorting and filtering options, making it\nmore adequate than the leaderboard endpoint for advanced uses.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "name",
            "in": "query",
            "description": "Optional username search.",
            "schema": {
              "type": "string",
              "default": ""
            }
          },
          {
            "name": "order",
            "in": "query",
            "description": "Order to return users in. Must be `xp`, `currency`, `messages`, or `voice. Default `xp`.",
            "schema": {
              "type": "string",
              "default": "xp"
            }
          },
          {
            "name": "direction",
            "in": "query",
            "description": "Order direction to return users in. Must be either `asc` or `desc`. Default `desc`.",
            "schema": {
              "type": "string",
              "default": "desc"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The rank index to start with, zero-indexed.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 0
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Limit of members to show. Maximum and default 50.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 50
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A list of members."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/members/{memberId}": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Member",
        "description": "Gets a member's stats from the server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The member's stats.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Member"
                }
              }
            }
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server does not exist."
          }
        }
      },
      "patch": {
        "tags": [
          "Servers"
        ],
        "summary": "Patch Server Member",
        "description": "Patch a member in the server. The only valid fields are `/xp` and `/currency`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "description": "A JSON patch document to modify the member by. The only valid fields are `/xp` and `/currency`.",
          "content": {
            "application/json-patch+json": {
              "schema": {
                "$ref": "#/components/schemas/MemberJsonPatchDocument"
              }
            },
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MemberJsonPatchDocument"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/MemberJsonPatchDocument"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/MemberJsonPatchDocument"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The member's stats, post-modification."
          },
          "400": {
            "description": "If the patch makes the member's XP or currency invalid."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server does not exist."
          }
        }
      },
      "delete": {
        "tags": [
          "Servers"
        ],
        "summary": "Delete Server Member",
        "description": "Delete a member from the server's leaderboard.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "On deletion success."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/members/{memberId}/xp": {
      "post": {
        "tags": [
          "Servers"
        ],
        "summary": "Add Server Member XP",
        "description": "Adds XP to a member in the server. May trigger a level up.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "amount",
            "in": "query",
            "description": "The amount of XP to give to the member.",
            "schema": {
              "type": "string",
              "format": "int64",
              "default": "0"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The member's stats, post-modification."
          },
          "400": {
            "description": "If the amount is invalid."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server does not exist."
          },
          "502": {
            "description": "If the level up message could not be posted. In this case, the XP addition is still commmitted."
          }
        }
      }
    },
    "/api/v1/servers/{id}/members/{memberId}/currency": {
      "post": {
        "tags": [
          "Servers"
        ],
        "summary": "Add Server Member Currency",
        "description": "Adds currency to a member in the server.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "memberId",
            "in": "path",
            "description": "The ID of the member.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "amount",
            "in": "query",
            "description": "The amount of currency to give to the member.",
            "schema": {
              "type": "string",
              "format": "int64",
              "default": "0"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The member's stats, post-modification."
          },
          "400": {
            "description": "If the amount is invalid, or would put the member at a below-zero balance."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the member or server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/shop": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Shop Items",
        "description": "Gets *all* items in a server's shop, regardless of whether or not economy/shop is enabled.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A list of shop items.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/Shop"
                  }
                }
              }
            }
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    },
    "/api/v1/servers/{id}/shop/transactions": {
      "get": {
        "tags": [
          "Servers"
        ],
        "summary": "Get Server Transactions",
        "description": "Gets a list of transactions in this server - shop purchases, /pay, etc.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the server.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "int64"
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "The transaction to start at. Zero-indexed, lower numbers are more recent.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 0
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "The number of transactions to show. Maximum 50, default 25.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 25
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A list of transactions."
          },
          "403": {
            "description": "If you do not have access to this server."
          },
          "404": {
            "description": "If the server does not exist."
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Admin": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "blog": {
            "type": "boolean"
          },
          "serverSettings": {
            "type": "boolean"
          },
          "kb": {
            "type": "boolean"
          },
          "user": {
            "$ref": "#/components/schemas/User"
          }
        },
        "additionalProperties": false
      },
      "Audit": {
        "type": "object",
        "properties": {
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "userId": {
            "type": "string",
            "format": "int64"
          },
          "action": {
            "type": "string",
            "nullable": true
          },
          "timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "subject": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          },
          "userName": {
            "type": "string",
            "nullable": true
          },
          "server": {
            "$ref": "#/components/schemas/Server"
          }
        },
        "additionalProperties": false
      },
      "Crate": {
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int32"
          },
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "criteria": {
            "type": "integer",
            "format": "int32"
          },
          "criteriaCount": {
            "type": "integer",
            "format": "int32"
          },
          "channels": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          },
          "xp": {
            "type": "integer",
            "format": "int32"
          },
          "duration": {
            "type": "integer",
            "format": "int32"
          },
          "criteriaProgress": {
            "type": "integer",
            "format": "int32"
          },
          "dropTime": {
            "type": "string",
            "format": "date-time"
          },
          "announcementChannel": {
            "type": "string",
            "format": "int64"
          },
          "announcementMessage": {
            "type": "string",
            "nullable": true
          },
          "color": {
            "type": "integer",
            "format": "int32"
          },
          "maxRedeemers": {
            "type": "integer",
            "format": "int32"
          },
          "pingHere": {
            "type": "boolean"
          },
          "redeemers": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          },
          "cooldown": {
            "type": "integer",
            "format": "int32"
          },
          "imageUrl": {
            "type": "string",
            "nullable": true
          },
          "reaction": {
            "type": "boolean"
          },
          "currency": {
            "type": "integer",
            "format": "int32"
          },
          "dropMessage": {
            "type": "string",
            "format": "int64"
          },
          "dropNow": {
            "type": "boolean"
          },
          "showRedeems": {
            "type": "boolean"
          },
          "pingRoles": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          },
          "server": {
            "$ref": "#/components/schemas/Server"
          }
        },
        "additionalProperties": false
      },
      "IContractResolver": {
        "type": "object",
        "additionalProperties": false
      },
      "Job": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "state": {
            "type": "integer",
            "format": "int32"
          },
          "resources": {
            "type": "integer",
            "format": "int32"
          },
          "message": {
            "type": "string",
            "nullable": true
          },
          "created": {
            "type": "string",
            "format": "date-time"
          },
          "updated": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "finished": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "server": {
            "$ref": "#/components/schemas/Server"
          }
        },
        "additionalProperties": false
      },
      "Kb": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "nullable": true
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "created": {
            "type": "string",
            "format": "date-time"
          },
          "author": {
            "type": "string",
            "format": "int64"
          },
          "body": {
            "type": "string",
            "nullable": true
          },
          "edited": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          },
          "active": {
            "type": "boolean"
          },
          "brief": {
            "type": "string",
            "nullable": true
          },
          "authorNavigation": {
            "$ref": "#/components/schemas/User"
          }
        },
        "additionalProperties": false
      },
      "Member": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "xp": {
            "type": "string",
            "format": "int64"
          },
          "messages": {
            "type": "integer",
            "format": "int32"
          },
          "voiceSeconds": {
            "type": "integer",
            "format": "int32"
          },
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "voiceAudible": {
            "type": "boolean"
          },
          "avatar": {
            "type": "string",
            "nullable": true
          },
          "currency": {
            "type": "string",
            "format": "int64"
          },
          "level": {
            "type": "integer",
            "format": "int32"
          },
          "levelXp": {
            "type": "string",
            "format": "int64"
          }
        },
        "additionalProperties": false
      },
      "MemberJsonPatchDocument": {
        "type": "object",
        "properties": {
          "operations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MemberOperation"
            },
            "nullable": true,
            "readOnly": true
          },
          "contractResolver": {
            "$ref": "#/components/schemas/IContractResolver"
          }
        },
        "additionalProperties": false
      },
      "MemberOperation": {
        "type": "object",
        "properties": {
          "operationType": {
            "$ref": "#/components/schemas/OperationType"
          },
          "path": {
            "type": "string",
            "nullable": true
          },
          "op": {
            "type": "string",
            "nullable": true
          },
          "from": {
            "type": "string",
            "nullable": true
          },
          "value": {
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "OperationType": {
        "enum": [
          0,
          1,
          2,
          3,
          4,
          5,
          6
        ],
        "type": "integer",
        "format": "int32"
      },
      "PatreonConnection": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "accessToken": {
            "type": "string",
            "nullable": true
          },
          "refreshToken": {
            "type": "string",
            "nullable": true
          },
          "expiresIn": {
            "type": "integer",
            "format": "int32"
          },
          "scope": {
            "type": "string",
            "nullable": true
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "idNavigation": {
            "$ref": "#/components/schemas/User"
          }
        },
        "additionalProperties": false
      },
      "PremiumServer": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "userId": {
            "type": "string",
            "format": "int64"
          },
          "idNavigation": {
            "$ref": "#/components/schemas/Server"
          },
          "user": {
            "$ref": "#/components/schemas/User"
          }
        },
        "additionalProperties": false
      },
      "ProblemDetails": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "nullable": true
          },
          "title": {
            "type": "string",
            "nullable": true
          },
          "status": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "detail": {
            "type": "string",
            "nullable": true
          },
          "instance": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": { }
      },
      "Role": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "level": {
            "type": "integer",
            "format": "int32"
          },
          "xpMultiplier": {
            "type": "number",
            "format": "float"
          },
          "levelMessage": {
            "type": "string",
            "nullable": true
          },
          "stack": {
            "type": "boolean"
          },
          "stackGroup": {
            "type": "string",
            "nullable": true
          },
          "dependencies": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Server": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "icon": {
            "type": "string",
            "nullable": true
          },
          "commandsWhitelist": {
            "type": "boolean"
          },
          "xpWhitelist": {
            "type": "boolean"
          },
          "commandsChannels": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          },
          "xpChannels": {
            "type": "array",
            "items": {
              "type": "string",
              "format": "int64"
            },
            "nullable": true
          },
          "messageXp": {
            "type": "integer",
            "format": "int32"
          },
          "levelFormula": {
            "type": "string",
            "nullable": true
          },
          "levelMessageEnabled": {
            "type": "boolean",
            "nullable": true
          },
          "levelMessage": {
            "type": "string",
            "nullable": true
          },
          "levelMessageLocation": {
            "type": "string",
            "format": "int64"
          },
          "voiceXp": {
            "type": "integer",
            "format": "int32"
          },
          "deleteOnLeave": {
            "type": "boolean",
            "nullable": true
          },
          "economy": {
            "type": "boolean"
          },
          "currencySymbol": {
            "type": "string",
            "nullable": true
          },
          "levelCurrency": {
            "type": "integer",
            "format": "int32"
          },
          "startingCurrency": {
            "type": "integer",
            "format": "int32"
          },
          "currencyTransfer": {
            "type": "boolean",
            "nullable": true
          },
          "public": {
            "type": "boolean",
            "nullable": true
          },
          "crateError": {
            "type": "boolean",
            "nullable": true
          },
          "shop": {
            "type": "boolean"
          },
          "shopLogChannel": {
            "type": "string",
            "format": "int64"
          },
          "aboutText": {
            "type": "string",
            "nullable": true
          },
          "currencyTransferMin": {
            "type": "integer",
            "format": "int32"
          },
          "currencyTransferPing": {
            "type": "boolean",
            "nullable": true
          },
          "economyGames": {
            "type": "boolean",
            "nullable": true
          },
          "hideCurrency": {
            "type": "boolean"
          },
          "hideMessages": {
            "type": "boolean"
          },
          "hideVoiceMinutes": {
            "type": "boolean"
          },
          "hideRoleInfo": {
            "type": "boolean"
          },
          "crates": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Crate"
            },
            "nullable": true
          },
          "roles": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Role"
            },
            "nullable": true
          },
          "shops": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Shop"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ServerJsonPatchDocument": {
        "type": "object",
        "properties": {
          "operations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ServerOperation"
            },
            "nullable": true,
            "readOnly": true
          },
          "contractResolver": {
            "$ref": "#/components/schemas/IContractResolver"
          }
        },
        "additionalProperties": false
      },
      "ServerOperation": {
        "type": "object",
        "properties": {
          "operationType": {
            "$ref": "#/components/schemas/OperationType"
          },
          "path": {
            "type": "string",
            "nullable": true
          },
          "op": {
            "type": "string",
            "nullable": true
          },
          "from": {
            "type": "string",
            "nullable": true
          },
          "value": {
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Shop": {
        "type": "object",
        "properties": {
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "price": {
            "type": "integer",
            "format": "int32"
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "reward": {
            "type": "string",
            "nullable": true
          },
          "imageUrl": {
            "type": "string",
            "nullable": true
          },
          "bgUrl": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "Transaction": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "userId": {
            "type": "string",
            "format": "int64"
          },
          "username": {
            "type": "string",
            "nullable": true
          },
          "serverId": {
            "type": "string",
            "format": "int64"
          },
          "item": {
            "type": "string",
            "format": "uuid",
            "nullable": true
          },
          "timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "amount": {
            "type": "integer",
            "format": "int32"
          },
          "recipientId": {
            "type": "string",
            "format": "int64"
          },
          "recipientUsername": {
            "type": "string",
            "nullable": true
          },
          "member": {
            "$ref": "#/components/schemas/Member"
          },
          "server": {
            "$ref": "#/components/schemas/Server"
          },
          "shopItem": {
            "$ref": "#/components/schemas/Shop"
          }
        },
        "additionalProperties": false
      },
      "User": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "int64"
          },
          "votes": {
            "type": "integer",
            "format": "int32"
          },
          "earlyVotes": {
            "type": "integer",
            "format": "int32"
          },
          "avatar": {
            "type": "string",
            "nullable": true
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "bio": {
            "type": "string",
            "nullable": true
          },
          "donator": {
            "type": "boolean"
          },
          "premiumStart": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "premiumEnd": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "premiumCharged": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "premiumServers": {
            "type": "integer",
            "format": "int32"
          },
          "premiumCredits": {
            "type": "boolean",
            "nullable": true
          },
          "backgroundIndex": {
            "type": "integer",
            "format": "int32"
          },
          "premiumOverride": {
            "type": "boolean",
            "nullable": true
          },
          "admin": {
            "$ref": "#/components/schemas/Admin"
          },
          "patreonConnection": {
            "$ref": "#/components/schemas/PatreonConnection"
          },
          "kbs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Kb"
            },
            "nullable": true
          },
          "premiumServersNavigation": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PremiumServer"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      }
    }
  },
  "tags": [
    {
      "name": "Servers"
    }
  ]
}