Skip to content

修改令牌

OpenAPI Specification

yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /api/token/:
    put:
      summary: 修改令牌
      deprecated: false
      description: ''
      tags:
        - 系统API
      parameters:
        - name: content-type
          in: header
          description: ''
          required: true
          example: application/json
          schema:
            type: string
        - name: new-api-user
          in: header
          description: ''
          required: true
          example: '1'
          schema:
            type: string
        - name: Authorization
          in: header
          description: 系统令牌
          required: false
          example: ''
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: 令牌名字
                remain_quota:
                  type: integer
                  description: 50w为1刀
                expired_time:
                  type: integer
                  description: 到期时间戳  单位秒 没有到期限制设置为-1
                unlimited_quota:
                  type: boolean
                  description: 无限额度设置
                model_limits_enabled:
                  type: boolean
                  description: 可用模型限制设置
                model_limits:
                  type: string
                  description: '可用模型列表:  模型名字按,号分割'
                allow_ips:
                  type: string
                  description: '白名单IP列表:  按\n号分割'
                group:
                  type: string
                  description: 支持分组  按,号分割
              required:
                - name
                - remain_quota
                - expired_time
                - unlimited_quota
                - model_limits_enabled
                - model_limits
                - allow_ips
                - group
              x-apifox-orders:
                - name
                - remain_quota
                - expired_time
                - unlimited_quota
                - model_limits_enabled
                - model_limits
                - allow_ips
                - group
            example:
              id: 194804
              remain_quota: 250000000000
              expired_time: -1
              unlimited_quota: false
              model_limits_enabled: false
              model_limits: ''
              group: ''
              mj_image_mode: default
              mj_custom_proxy: ''
              selected_groups: []
              name: 令牌22名字
              allow_ips: ''
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties: {}
          headers: {}
          x-apifox-name: 成功
      security: []
      x-apifox-folder: 系统API
      x-apifox-status: released
      x-run-in-apifox: https://app.apifox.com/web/project/5443236/apis/api-356116138-run
components:
  schemas: {}
  securitySchemes:
    bearer:
      type: http
      scheme: bearer
servers:
  - url: https://www.anyapi.vip
    description: 正式环境
security:
  - bearer: []

AnyAPI — 专业的 AI 接口聚合服务