文档

更快上手 TicketsX

配置指南、完整命令说明、Premium 功能和 REST API 都在这里。

13.10

获取面板

GET/<guild_id>/api/panels/<panel_id>

获取单个面板的完整配置:名称、工单模式、面板消息(经典嵌入或组件布局)、按钮样式、自动关闭行为,以及(组合面板的)下拉菜单设置。需要 `list_panels` 权限。

请求示例
curl -X GET \
  -H "Authorization: Bearer <API_TOKEN>" \
  https://api.ticketsx.xyz/<guild_id>/api/panels/<panel_id>
响应示例
{
  "panel": {
    "PanelId": 1,
    "Type": "single",
    "PanelName": "Support",
    "TicketMode": "channel",
    "BypassAutoClose": false,
    "MessageId": "1234567890123456789",
    "PanelMessage": {
      "PanelChannel": "1098765432101234567",
      "PanelTitle": "Open a ticket!",
      "PanelDescription": "Click the button below to contact staff.",
      "PanelColor": "#5865F2",
      "ButtonColor": "primary",
      "ButtonText": "Open Ticket",
      "ButtonEmoji": "\ud83d\udce9",
      "DisablePanel": false,
      "MessageFormat": "embed",
      "Content": "",
      "Embeds": [
        {
          "Title": "Open a ticket!",
          "Description": "Click the button below to contact staff.",
          "Color": "#5865F2",
          "Fields": [],
          "Timestamp": false
        }
      ],
      "LinkButtons": [],
      "Components": []
    }
  }
}