All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 5m16s
主要变更: - 新增 Carrier CRUD API(创建、列表、详情、更新、删除、状态更新) - IotCard/IotCardImportTask 添加 carrier_type/carrier_name 冗余字段 - 移除 Carrier 表的 channel_name/channel_code 字段 - 查询时直接使用冗余字段,避免 JOIN Carrier 表 - 添加数据库迁移脚本(000021-000023) - 添加单元测试和集成测试 - 同步更新 OpenAPI 文档和 specs
9487 lines
347 KiB
YAML
9487 lines
347 KiB
YAML
components:
|
||
schemas:
|
||
DtoAccountPageResult:
|
||
properties:
|
||
items:
|
||
description: 账号列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoAccountResponse:
|
||
properties:
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
creator:
|
||
description: 创建人ID
|
||
minimum: 0
|
||
type: integer
|
||
enterprise_id:
|
||
description: 关联企业ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
id:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
phone:
|
||
description: 手机号
|
||
type: string
|
||
shop_id:
|
||
description: 关联店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
updater:
|
||
description: 更新人ID
|
||
minimum: 0
|
||
type: integer
|
||
user_type:
|
||
description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
type: string
|
||
type: object
|
||
DtoAllocateCardsReq:
|
||
properties:
|
||
confirm_device_bundles:
|
||
description: 确认整体授权设备下所有卡
|
||
type: boolean
|
||
iccids:
|
||
description: 需要授权的 ICCID 列表
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
required:
|
||
- iccids
|
||
type: object
|
||
DtoAllocateCardsResp:
|
||
properties:
|
||
allocated_devices:
|
||
description: 连带授权的设备列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAllocatedDevice'
|
||
nullable: true
|
||
type: array
|
||
fail_count:
|
||
description: 失败数量
|
||
type: integer
|
||
failed_items:
|
||
description: 失败详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoFailedItem'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数量
|
||
type: integer
|
||
type: object
|
||
DtoAllocateDevicesRequest:
|
||
properties:
|
||
device_ids:
|
||
description: 设备ID列表
|
||
items:
|
||
minimum: 0
|
||
type: integer
|
||
maxItems: 100
|
||
minItems: 1
|
||
nullable: true
|
||
type: array
|
||
remark:
|
||
description: 备注
|
||
maxLength: 500
|
||
type: string
|
||
target_shop_id:
|
||
description: 目标店铺ID
|
||
minimum: 1
|
||
type: integer
|
||
required:
|
||
- target_shop_id
|
||
- device_ids
|
||
type: object
|
||
DtoAllocateDevicesResponse:
|
||
properties:
|
||
fail_count:
|
||
description: 失败数量
|
||
type: integer
|
||
failed_items:
|
||
description: 失败详情列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAllocationDeviceFailedItem'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数量
|
||
type: integer
|
||
type: object
|
||
DtoAllocateStandaloneCardsRequest:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号(selection_type=filter时可选)
|
||
maxLength: 100
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID(selection_type=filter时可选)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
iccid_end:
|
||
description: 结束ICCID(selection_type=range时必填)
|
||
maxLength: 20
|
||
type: string
|
||
iccid_start:
|
||
description: 起始ICCID(selection_type=range时必填)
|
||
maxLength: 20
|
||
type: string
|
||
iccids:
|
||
description: ICCID列表(selection_type=list时必填,最多1000个)
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
remark:
|
||
description: 备注
|
||
maxLength: 500
|
||
type: string
|
||
selection_type:
|
||
description: 选卡方式 (list:ICCID列表, range:号段范围, filter:筛选条件)
|
||
enum:
|
||
- list
|
||
- range
|
||
- filter
|
||
type: string
|
||
status:
|
||
description: 卡状态 (1:在库, 2:已分销)(selection_type=filter时可选)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
to_shop_id:
|
||
description: 目标店铺ID
|
||
minimum: 1
|
||
type: integer
|
||
required:
|
||
- to_shop_id
|
||
- selection_type
|
||
type: object
|
||
DtoAllocateStandaloneCardsResponse:
|
||
properties:
|
||
allocation_no:
|
||
description: 分配单号
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
failed_items:
|
||
description: 失败项列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAllocationFailedItem'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
total_count:
|
||
description: 待分配总数
|
||
type: integer
|
||
type: object
|
||
DtoAllocatedDevice:
|
||
properties:
|
||
card_count:
|
||
description: 卡数量
|
||
type: integer
|
||
device_id:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
iccids:
|
||
description: 卡ICCID列表
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
type: object
|
||
DtoAllocationDeviceFailedItem:
|
||
properties:
|
||
device_id:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
reason:
|
||
description: 失败原因
|
||
type: string
|
||
type: object
|
||
DtoAllocationFailedItem:
|
||
properties:
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
reason:
|
||
description: 失败原因
|
||
type: string
|
||
type: object
|
||
DtoApproveWithdrawalReq:
|
||
properties:
|
||
account_name:
|
||
description: 修正后的收款人姓名
|
||
maxLength: 100
|
||
nullable: true
|
||
type: string
|
||
account_number:
|
||
description: 修正后的收款账号
|
||
maxLength: 100
|
||
nullable: true
|
||
type: string
|
||
amount:
|
||
description: 修正后的提现金额(分),不填则使用原金额
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
payment_type:
|
||
description: 放款类型(目前只支持manual人工打款)
|
||
type: string
|
||
remark:
|
||
description: 备注
|
||
maxLength: 500
|
||
type: string
|
||
withdrawal_method:
|
||
description: 修正后的收款类型 (alipay:支付宝, wechat:微信, bank:银行卡)
|
||
nullable: true
|
||
type: string
|
||
required:
|
||
- payment_type
|
||
type: object
|
||
DtoAssetAllocationRecordDetailResponse:
|
||
properties:
|
||
allocation_name:
|
||
description: 分配类型名称
|
||
type: string
|
||
allocation_no:
|
||
description: 分配单号
|
||
type: string
|
||
allocation_type:
|
||
description: 分配类型 (allocate:分配, recall:回收)
|
||
type: string
|
||
asset_id:
|
||
description: 资产ID
|
||
minimum: 0
|
||
type: integer
|
||
asset_identifier:
|
||
description: 资产标识符(ICCID或设备号)
|
||
type: string
|
||
asset_type:
|
||
description: 资产类型 (iot_card:物联网卡, device:设备)
|
||
type: string
|
||
asset_type_name:
|
||
description: 资产类型名称
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
from_owner_id:
|
||
description: 来源所有者ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
from_owner_name:
|
||
description: 来源所有者名称
|
||
type: string
|
||
from_owner_type:
|
||
description: 来源所有者类型
|
||
type: string
|
||
id:
|
||
description: 记录ID
|
||
minimum: 0
|
||
type: integer
|
||
operator_id:
|
||
description: 操作人ID
|
||
minimum: 0
|
||
type: integer
|
||
operator_name:
|
||
description: 操作人名称
|
||
type: string
|
||
related_card_count:
|
||
description: 关联卡数量
|
||
type: integer
|
||
related_card_ids:
|
||
description: 关联卡ID列表
|
||
items:
|
||
minimum: 0
|
||
type: integer
|
||
type: array
|
||
related_device_id:
|
||
description: 关联设备ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
remark:
|
||
description: 备注
|
||
type: string
|
||
to_owner_id:
|
||
description: 目标所有者ID
|
||
minimum: 0
|
||
type: integer
|
||
to_owner_name:
|
||
description: 目标所有者名称
|
||
type: string
|
||
to_owner_type:
|
||
description: 目标所有者类型
|
||
type: string
|
||
type: object
|
||
DtoAssetAllocationRecordResponse:
|
||
properties:
|
||
allocation_name:
|
||
description: 分配类型名称
|
||
type: string
|
||
allocation_no:
|
||
description: 分配单号
|
||
type: string
|
||
allocation_type:
|
||
description: 分配类型 (allocate:分配, recall:回收)
|
||
type: string
|
||
asset_id:
|
||
description: 资产ID
|
||
minimum: 0
|
||
type: integer
|
||
asset_identifier:
|
||
description: 资产标识符(ICCID或设备号)
|
||
type: string
|
||
asset_type:
|
||
description: 资产类型 (iot_card:物联网卡, device:设备)
|
||
type: string
|
||
asset_type_name:
|
||
description: 资产类型名称
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
from_owner_id:
|
||
description: 来源所有者ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
from_owner_name:
|
||
description: 来源所有者名称
|
||
type: string
|
||
from_owner_type:
|
||
description: 来源所有者类型
|
||
type: string
|
||
id:
|
||
description: 记录ID
|
||
minimum: 0
|
||
type: integer
|
||
operator_id:
|
||
description: 操作人ID
|
||
minimum: 0
|
||
type: integer
|
||
operator_name:
|
||
description: 操作人名称
|
||
type: string
|
||
related_card_count:
|
||
description: 关联卡数量
|
||
type: integer
|
||
related_device_id:
|
||
description: 关联设备ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
remark:
|
||
description: 备注
|
||
type: string
|
||
to_owner_id:
|
||
description: 目标所有者ID
|
||
minimum: 0
|
||
type: integer
|
||
to_owner_name:
|
||
description: 目标所有者名称
|
||
type: string
|
||
to_owner_type:
|
||
description: 目标所有者类型
|
||
type: string
|
||
type: object
|
||
DtoAssignPermissionsParams:
|
||
properties:
|
||
perm_ids:
|
||
description: 权限ID列表
|
||
items:
|
||
minimum: 0
|
||
type: integer
|
||
minItems: 1
|
||
nullable: true
|
||
type: array
|
||
required:
|
||
- perm_ids
|
||
type: object
|
||
DtoAssignRolesParams:
|
||
properties:
|
||
role_ids:
|
||
description: 角色ID列表,传空数组可清空所有角色
|
||
items:
|
||
minimum: 0
|
||
type: integer
|
||
nullable: true
|
||
type: array
|
||
type: object
|
||
DtoAuthorizationItem:
|
||
properties:
|
||
authorized_at:
|
||
description: 授权时间
|
||
format: date-time
|
||
type: string
|
||
authorized_by:
|
||
description: 授权人ID
|
||
minimum: 0
|
||
type: integer
|
||
authorizer_name:
|
||
description: 授权人名称
|
||
type: string
|
||
authorizer_type:
|
||
description: 授权人类型:2=平台,3=代理
|
||
type: integer
|
||
card_id:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
enterprise_id:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
enterprise_name:
|
||
description: 企业名称
|
||
type: string
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 授权记录ID
|
||
minimum: 0
|
||
type: integer
|
||
msisdn:
|
||
description: 手机号
|
||
type: string
|
||
remark:
|
||
description: 备注
|
||
type: string
|
||
revoked_at:
|
||
description: 回收时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
revoked_by:
|
||
description: 回收人ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
revoker_name:
|
||
description: 回收人名称
|
||
type: string
|
||
status:
|
||
description: 状态:1=有效,0=已回收
|
||
type: integer
|
||
type: object
|
||
DtoAuthorizationListResp:
|
||
properties:
|
||
items:
|
||
description: 授权记录列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAuthorizationItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoBindCardToDeviceRequest:
|
||
properties:
|
||
iot_card_id:
|
||
description: IoT卡ID
|
||
minimum: 1
|
||
type: integer
|
||
slot_position:
|
||
description: 插槽位置 (1-4)
|
||
maximum: 4
|
||
minimum: 1
|
||
type: integer
|
||
required:
|
||
- iot_card_id
|
||
- slot_position
|
||
type: object
|
||
DtoBindCardToDeviceResponse:
|
||
properties:
|
||
binding_id:
|
||
description: 绑定记录ID
|
||
minimum: 0
|
||
type: integer
|
||
message:
|
||
description: 提示信息
|
||
type: string
|
||
type: object
|
||
DtoCarrierPageResult:
|
||
properties:
|
||
list:
|
||
description: 运营商列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoCarrierResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoCarrierResponse:
|
||
properties:
|
||
carrier_code:
|
||
description: 运营商编码
|
||
type: string
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
description:
|
||
description: 运营商描述
|
||
type: string
|
||
id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
status:
|
||
description: 状态 (1:启用, 0:禁用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
type: object
|
||
DtoChangePasswordRequest:
|
||
properties:
|
||
new_password:
|
||
type: string
|
||
old_password:
|
||
type: string
|
||
type: object
|
||
DtoCreateAccountRequest:
|
||
properties:
|
||
enterprise_id:
|
||
description: 关联企业ID(企业账号必填)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
password:
|
||
description: 密码
|
||
maxLength: 32
|
||
minLength: 8
|
||
type: string
|
||
phone:
|
||
description: 手机号
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
shop_id:
|
||
description: 关联店铺ID(代理账号必填)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
user_type:
|
||
description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
maximum: 4
|
||
minimum: 1
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
maxLength: 50
|
||
minLength: 3
|
||
type: string
|
||
required:
|
||
- username
|
||
- phone
|
||
- password
|
||
- user_type
|
||
type: object
|
||
DtoCreateCarrierRequest:
|
||
properties:
|
||
carrier_code:
|
||
description: 运营商编码
|
||
maxLength: 50
|
||
minLength: 1
|
||
type: string
|
||
carrier_name:
|
||
description: 运营商名称
|
||
maxLength: 100
|
||
minLength: 1
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
description:
|
||
description: 运营商描述
|
||
maxLength: 500
|
||
type: string
|
||
required:
|
||
- carrier_code
|
||
- carrier_name
|
||
- carrier_type
|
||
type: object
|
||
DtoCreateCustomerAccountReq:
|
||
properties:
|
||
password:
|
||
description: 密码
|
||
maximum: 20
|
||
minimum: 6
|
||
type: string
|
||
phone:
|
||
description: 手机号
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
maximum: 50
|
||
minimum: 2
|
||
type: string
|
||
required:
|
||
- username
|
||
- phone
|
||
- password
|
||
- shop_id
|
||
type: object
|
||
DtoCreateEnterpriseReq:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
maximum: 255
|
||
type: string
|
||
business_license:
|
||
description: 营业执照号
|
||
maximum: 100
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
maximum: 50
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
maximum: 50
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
maximum: 20
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
maximum: 50
|
||
type: string
|
||
enterprise_code:
|
||
description: 企业编号(唯一)
|
||
maximum: 50
|
||
type: string
|
||
enterprise_name:
|
||
description: 企业名称
|
||
maximum: 100
|
||
type: string
|
||
legal_person:
|
||
description: 法人代表
|
||
maximum: 50
|
||
type: string
|
||
login_phone:
|
||
description: 登录手机号(作为企业账号)
|
||
type: string
|
||
owner_shop_id:
|
||
description: 归属店铺ID(可不填则归属平台)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
password:
|
||
description: 登录密码
|
||
maximum: 20
|
||
minimum: 6
|
||
type: string
|
||
province:
|
||
description: 省份
|
||
maximum: 50
|
||
type: string
|
||
required:
|
||
- enterprise_name
|
||
- enterprise_code
|
||
- contact_name
|
||
- contact_phone
|
||
- login_phone
|
||
- password
|
||
type: object
|
||
DtoCreateEnterpriseResp:
|
||
properties:
|
||
account_id:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
enterprise:
|
||
$ref: '#/components/schemas/DtoEnterpriseItem'
|
||
type: object
|
||
DtoCreateMyWithdrawalReq:
|
||
properties:
|
||
account_name:
|
||
description: 收款人姓名
|
||
maximum: 50
|
||
type: string
|
||
account_number:
|
||
description: 收款账号
|
||
maximum: 100
|
||
type: string
|
||
amount:
|
||
description: 提现金额(分)
|
||
minimum: 1
|
||
type: integer
|
||
withdrawal_method:
|
||
description: 收款类型
|
||
enum:
|
||
- alipay
|
||
type: string
|
||
required:
|
||
- amount
|
||
- withdrawal_method
|
||
- account_name
|
||
- account_number
|
||
type: object
|
||
DtoCreateMyWithdrawalResp:
|
||
properties:
|
||
actual_amount:
|
||
description: 实际到账金额(分)
|
||
type: integer
|
||
amount:
|
||
description: 提现金额(分)
|
||
type: integer
|
||
created_at:
|
||
description: 申请时间
|
||
type: string
|
||
fee:
|
||
description: 手续费(分)
|
||
type: integer
|
||
fee_rate:
|
||
description: 手续费比率(基点)
|
||
type: integer
|
||
id:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
status:
|
||
description: 状态
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
withdrawal_no:
|
||
description: 提现单号
|
||
type: string
|
||
type: object
|
||
DtoCreatePermissionRequest:
|
||
properties:
|
||
parent_id:
|
||
description: 父权限ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
perm_code:
|
||
description: 权限编码
|
||
maxLength: 100
|
||
minLength: 1
|
||
type: string
|
||
perm_name:
|
||
description: 权限名称
|
||
maxLength: 50
|
||
minLength: 1
|
||
type: string
|
||
perm_type:
|
||
description: 权限类型 (1:菜单, 2:按钮)
|
||
maximum: 2
|
||
minimum: 1
|
||
type: integer
|
||
platform:
|
||
description: 适用端口 (all:全部, web:Web后台, h5:H5端),默认为 all
|
||
type: string
|
||
sort:
|
||
description: 排序值
|
||
minimum: 0
|
||
type: integer
|
||
url:
|
||
description: 请求路径
|
||
maxLength: 255
|
||
type: string
|
||
required:
|
||
- perm_name
|
||
- perm_code
|
||
- perm_type
|
||
type: object
|
||
DtoCreateRoleRequest:
|
||
properties:
|
||
role_desc:
|
||
description: 角色描述
|
||
maxLength: 255
|
||
type: string
|
||
role_name:
|
||
description: 角色名称
|
||
maxLength: 50
|
||
minLength: 1
|
||
type: string
|
||
role_type:
|
||
description: 角色类型 (1:平台角色, 2:客户角色)
|
||
maximum: 2
|
||
minimum: 1
|
||
type: integer
|
||
required:
|
||
- role_name
|
||
- role_type
|
||
type: object
|
||
DtoCreateShopAccountRequest:
|
||
properties:
|
||
password:
|
||
description: 密码
|
||
maxLength: 32
|
||
minLength: 8
|
||
type: string
|
||
phone:
|
||
description: 手机号
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 1
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
maxLength: 50
|
||
minLength: 3
|
||
type: string
|
||
required:
|
||
- shop_id
|
||
- username
|
||
- phone
|
||
- password
|
||
type: object
|
||
DtoCreateShopRequest:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
maxLength: 255
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
maxLength: 50
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
maxLength: 50
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
maxLength: 50
|
||
type: string
|
||
init_password:
|
||
description: 初始账号密码
|
||
maxLength: 32
|
||
minLength: 8
|
||
type: string
|
||
init_phone:
|
||
description: 初始账号手机号
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
init_username:
|
||
description: 初始账号用户名
|
||
maxLength: 50
|
||
minLength: 3
|
||
type: string
|
||
parent_id:
|
||
description: 上级店铺ID(一级店铺可不填)
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
province:
|
||
description: 省份
|
||
maxLength: 50
|
||
type: string
|
||
shop_code:
|
||
description: 店铺编号
|
||
maxLength: 50
|
||
minLength: 1
|
||
type: string
|
||
shop_name:
|
||
description: 店铺名称
|
||
maxLength: 100
|
||
minLength: 1
|
||
type: string
|
||
required:
|
||
- shop_name
|
||
- shop_code
|
||
- init_password
|
||
- init_username
|
||
- init_phone
|
||
type: object
|
||
DtoCreateWithdrawalSettingReq:
|
||
properties:
|
||
daily_withdrawal_limit:
|
||
description: 每日提现次数限制
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
fee_rate:
|
||
description: 手续费比率(基点,100=1%)
|
||
maximum: 10000
|
||
minimum: 0
|
||
type: integer
|
||
min_withdrawal_amount:
|
||
description: 最低提现金额(分)
|
||
minimum: 1
|
||
type: integer
|
||
required:
|
||
- daily_withdrawal_limit
|
||
- min_withdrawal_amount
|
||
- fee_rate
|
||
type: object
|
||
DtoCustomerAccountItem:
|
||
properties:
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
enterprise_id:
|
||
description: 企业ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
enterprise_name:
|
||
description: 企业名称
|
||
type: string
|
||
id:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
phone:
|
||
description: 手机号
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态(0=禁用, 1=启用)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
user_type:
|
||
description: 用户类型(3=代理账号, 4=企业账号)
|
||
type: integer
|
||
user_type_name:
|
||
description: 用户类型名称
|
||
type: string
|
||
username:
|
||
description: 用户名
|
||
type: string
|
||
type: object
|
||
DtoCustomerAccountPageResult:
|
||
properties:
|
||
items:
|
||
description: 账号列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoCustomerAccountItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoDeviceCardBindingResponse:
|
||
properties:
|
||
bind_time:
|
||
description: 绑定时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 绑定记录ID
|
||
minimum: 0
|
||
type: integer
|
||
iot_card_id:
|
||
description: IoT卡ID
|
||
minimum: 0
|
||
type: integer
|
||
msisdn:
|
||
description: 接入号
|
||
type: string
|
||
slot_position:
|
||
description: 插槽位置 (1-4)
|
||
type: integer
|
||
status:
|
||
description: 卡状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
type: integer
|
||
type: object
|
||
DtoDeviceImportResultItemDTO:
|
||
properties:
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
line:
|
||
description: 行号
|
||
type: integer
|
||
reason:
|
||
description: 原因
|
||
type: string
|
||
type: object
|
||
DtoDeviceImportTaskDetailResponse:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
completed_at:
|
||
description: 完成时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
error_message:
|
||
description: 错误信息
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
failed_items:
|
||
description: 失败记录详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceImportResultItemDTO'
|
||
nullable: true
|
||
type: array
|
||
file_name:
|
||
description: 文件名
|
||
type: string
|
||
id:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
skip_count:
|
||
description: 跳过数
|
||
type: integer
|
||
skipped_items:
|
||
description: 跳过记录详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceImportResultItemDTO'
|
||
nullable: true
|
||
type: array
|
||
started_at:
|
||
description: 开始处理时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
type: integer
|
||
status_text:
|
||
description: 任务状态文本
|
||
type: string
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
total_count:
|
||
description: 总数
|
||
type: integer
|
||
warning_count:
|
||
description: 警告数(部分成功的设备数量)
|
||
type: integer
|
||
warning_items:
|
||
description: 警告记录详情(部分成功的设备及其卡绑定失败原因)
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceImportResultItemDTO'
|
||
nullable: true
|
||
type: array
|
||
type: object
|
||
DtoDeviceImportTaskResponse:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
completed_at:
|
||
description: 完成时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
error_message:
|
||
description: 错误信息
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
file_name:
|
||
description: 文件名
|
||
type: string
|
||
id:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
skip_count:
|
||
description: 跳过数
|
||
type: integer
|
||
started_at:
|
||
description: 开始处理时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
type: integer
|
||
status_text:
|
||
description: 任务状态文本
|
||
type: string
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
total_count:
|
||
description: 总数
|
||
type: integer
|
||
warning_count:
|
||
description: 警告数(部分成功的设备数量)
|
||
type: integer
|
||
type: object
|
||
DtoDeviceResponse:
|
||
properties:
|
||
activated_at:
|
||
description: 激活时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
bound_card_count:
|
||
description: 已绑定卡数量
|
||
type: integer
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
device_model:
|
||
description: 设备型号
|
||
type: string
|
||
device_name:
|
||
description: 设备名称
|
||
type: string
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
device_type:
|
||
description: 设备类型
|
||
type: string
|
||
id:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
manufacturer:
|
||
description: 制造商
|
||
type: string
|
||
max_sim_slots:
|
||
description: 最大插槽数
|
||
type: integer
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
updated_at:
|
||
description: 更新时间
|
||
format: date-time
|
||
type: string
|
||
type: object
|
||
DtoEnterpriseCardItem:
|
||
properties:
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
device_id:
|
||
description: 设备ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
msisdn:
|
||
description: 手机号
|
||
type: string
|
||
network_status:
|
||
description: 网络状态
|
||
type: integer
|
||
network_status_name:
|
||
description: 网络状态名称
|
||
type: string
|
||
package_id:
|
||
description: 套餐ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
package_name:
|
||
description: 套餐名称
|
||
type: string
|
||
status:
|
||
description: 状态
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
type: object
|
||
DtoEnterpriseCardPageResult:
|
||
properties:
|
||
items:
|
||
description: 卡列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoEnterpriseCardItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoEnterpriseItem:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
type: string
|
||
business_license:
|
||
description: 营业执照号
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
type: string
|
||
enterprise_code:
|
||
description: 企业编号
|
||
type: string
|
||
enterprise_name:
|
||
description: 企业名称
|
||
type: string
|
||
id:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
legal_person:
|
||
description: 法人代表
|
||
type: string
|
||
login_phone:
|
||
description: 登录手机号
|
||
type: string
|
||
owner_shop_id:
|
||
description: 归属店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
owner_shop_name:
|
||
description: 归属店铺名称
|
||
type: string
|
||
province:
|
||
description: 省份
|
||
type: string
|
||
status:
|
||
description: 状态(0=禁用, 1=启用)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
type: object
|
||
DtoEnterprisePageResult:
|
||
properties:
|
||
items:
|
||
description: 企业列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoEnterpriseItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoFailedItem:
|
||
properties:
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
reason:
|
||
description: 失败原因
|
||
type: string
|
||
type: object
|
||
DtoGetUploadURLRequest:
|
||
properties:
|
||
content_type:
|
||
description: 文件 MIME 类型(如:text/csv),留空则自动推断
|
||
maxLength: 100
|
||
type: string
|
||
file_name:
|
||
description: 文件名(如:cards.csv)
|
||
maxLength: 255
|
||
minLength: 1
|
||
type: string
|
||
purpose:
|
||
description: 文件用途 (iot_import:ICCID导入, export:数据导出, attachment:附件)
|
||
type: string
|
||
required:
|
||
- file_name
|
||
- purpose
|
||
type: object
|
||
DtoGetUploadURLResponse:
|
||
properties:
|
||
expires_in:
|
||
description: URL 有效期(秒)
|
||
type: integer
|
||
file_key:
|
||
description: 文件路径标识,上传成功后用于调用业务接口
|
||
type: string
|
||
upload_url:
|
||
description: 预签名上传 URL,使用 PUT 方法上传文件
|
||
type: string
|
||
type: object
|
||
DtoImportDeviceRequest:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
maxLength: 100
|
||
type: string
|
||
file_key:
|
||
description: 对象存储文件路径(通过 /storage/upload-url 获取)
|
||
maxLength: 500
|
||
minLength: 1
|
||
type: string
|
||
required:
|
||
- file_key
|
||
type: object
|
||
DtoImportDeviceResponse:
|
||
properties:
|
||
message:
|
||
description: 提示信息
|
||
type: string
|
||
task_id:
|
||
description: 导入任务ID
|
||
minimum: 0
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
type: object
|
||
DtoImportIotCardRequest:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
maxLength: 100
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 1
|
||
type: integer
|
||
file_key:
|
||
description: 对象存储文件路径(通过 /storage/upload-url 获取)
|
||
maxLength: 500
|
||
minLength: 1
|
||
type: string
|
||
required:
|
||
- carrier_id
|
||
- file_key
|
||
type: object
|
||
DtoImportIotCardResponse:
|
||
properties:
|
||
message:
|
||
description: 提示信息
|
||
type: string
|
||
task_id:
|
||
description: 导入任务ID
|
||
minimum: 0
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
type: object
|
||
DtoImportResultItemDTO:
|
||
properties:
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
line:
|
||
description: 行号
|
||
type: integer
|
||
msisdn:
|
||
description: 接入号
|
||
type: string
|
||
reason:
|
||
description: 原因
|
||
type: string
|
||
type: object
|
||
DtoImportTaskDetailResponse:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
completed_at:
|
||
description: 完成时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
error_message:
|
||
description: 错误信息
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
failed_items:
|
||
description: 失败记录详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoImportResultItemDTO'
|
||
nullable: true
|
||
type: array
|
||
file_name:
|
||
description: 文件名
|
||
type: string
|
||
id:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
skip_count:
|
||
description: 跳过数
|
||
type: integer
|
||
skipped_items:
|
||
description: 跳过记录详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoImportResultItemDTO'
|
||
nullable: true
|
||
type: array
|
||
started_at:
|
||
description: 开始处理时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
type: integer
|
||
status_text:
|
||
description: 任务状态文本
|
||
type: string
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
total_count:
|
||
description: 总数
|
||
type: integer
|
||
type: object
|
||
DtoImportTaskResponse:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
completed_at:
|
||
description: 完成时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
error_message:
|
||
description: 错误信息
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
file_name:
|
||
description: 文件名
|
||
type: string
|
||
id:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
skip_count:
|
||
description: 跳过数
|
||
type: integer
|
||
started_at:
|
||
description: 开始处理时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
type: integer
|
||
status_text:
|
||
description: 任务状态文本
|
||
type: string
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
task_no:
|
||
description: 任务编号
|
||
type: string
|
||
total_count:
|
||
description: 总数
|
||
type: integer
|
||
type: object
|
||
DtoIotCardDetailResponse:
|
||
properties:
|
||
activated_at:
|
||
description: 激活时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
activation_status:
|
||
description: 激活状态 (0:未激活, 1:已激活)
|
||
type: integer
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
card_category:
|
||
description: 卡业务类型 (normal:普通卡, industry:行业卡)
|
||
type: string
|
||
card_type:
|
||
description: 卡类型
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
cost_price:
|
||
description: 成本价(分)
|
||
type: integer
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
data_usage_mb:
|
||
description: 累计流量使用(MB)
|
||
type: integer
|
||
distribute_price:
|
||
description: 分销价(分)
|
||
type: integer
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
imsi:
|
||
description: IMSI
|
||
type: string
|
||
msisdn:
|
||
description: 卡接入号
|
||
type: string
|
||
network_status:
|
||
description: 网络状态 (0:停机, 1:开机)
|
||
type: integer
|
||
real_name_status:
|
||
description: 实名状态 (0:未实名, 1:已实名)
|
||
type: integer
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
type: integer
|
||
supplier:
|
||
description: 供应商
|
||
type: string
|
||
updated_at:
|
||
description: 更新时间
|
||
format: date-time
|
||
type: string
|
||
type: object
|
||
DtoListAssetAllocationRecordResponse:
|
||
properties:
|
||
list:
|
||
description: 分配记录列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAssetAllocationRecordResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoListDeviceCardsResponse:
|
||
properties:
|
||
bindings:
|
||
description: 绑定列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceCardBindingResponse'
|
||
nullable: true
|
||
type: array
|
||
type: object
|
||
DtoListDeviceImportTaskResponse:
|
||
properties:
|
||
list:
|
||
description: 任务列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceImportTaskResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoListDeviceResponse:
|
||
properties:
|
||
list:
|
||
description: 设备列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoDeviceResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoListImportTaskResponse:
|
||
properties:
|
||
list:
|
||
description: 任务列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoImportTaskResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoListStandaloneIotCardResponse:
|
||
properties:
|
||
list:
|
||
description: 单卡列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoStandaloneIotCardResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
page_size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总数
|
||
type: integer
|
||
total_pages:
|
||
description: 总页数
|
||
type: integer
|
||
type: object
|
||
DtoLoginRequest:
|
||
properties:
|
||
device:
|
||
type: string
|
||
password:
|
||
type: string
|
||
username:
|
||
type: string
|
||
type: object
|
||
DtoLoginResponse:
|
||
properties:
|
||
access_token:
|
||
type: string
|
||
expires_in:
|
||
type: integer
|
||
permissions:
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
refresh_token:
|
||
type: string
|
||
user:
|
||
$ref: '#/components/schemas/DtoUserInfo'
|
||
type: object
|
||
DtoMyCommissionRecordItem:
|
||
properties:
|
||
amount:
|
||
description: 佣金金额(分)
|
||
type: integer
|
||
commission_type:
|
||
description: 佣金类型 (one_time:一次性, long_term:长期)
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
id:
|
||
description: 佣金记录ID
|
||
minimum: 0
|
||
type: integer
|
||
order_id:
|
||
description: 订单ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
status:
|
||
description: 状态 (1:已冻结, 2:解冻中, 3:已发放, 4:已失效)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
type: object
|
||
DtoMyCommissionRecordPageResult:
|
||
properties:
|
||
items:
|
||
description: 佣金记录列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoMyCommissionRecordItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoMyCommissionSummaryResp:
|
||
properties:
|
||
available_commission:
|
||
description: 可提现佣金(分)
|
||
type: integer
|
||
frozen_commission:
|
||
description: 冻结佣金(分)
|
||
type: integer
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
total_commission:
|
||
description: 累计佣金(分)
|
||
type: integer
|
||
unwithdraw_commission:
|
||
description: 未提现佣金(分)
|
||
type: integer
|
||
withdrawing_commission:
|
||
description: 提现中佣金(分)
|
||
type: integer
|
||
withdrawn_commission:
|
||
description: 已提现佣金(分)
|
||
type: integer
|
||
type: object
|
||
DtoPermissionPageResult:
|
||
properties:
|
||
items:
|
||
description: 权限列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoPermissionResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoPermissionResponse:
|
||
properties:
|
||
available_for_role_types:
|
||
description: 可用角色类型 (1:平台角色, 2:客户角色)
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
creator:
|
||
description: 创建人ID
|
||
minimum: 0
|
||
type: integer
|
||
id:
|
||
description: 权限ID
|
||
minimum: 0
|
||
type: integer
|
||
parent_id:
|
||
description: 父权限ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
perm_code:
|
||
description: 权限编码
|
||
type: string
|
||
perm_name:
|
||
description: 权限名称
|
||
type: string
|
||
perm_type:
|
||
description: 权限类型 (1:菜单, 2:按钮)
|
||
type: integer
|
||
platform:
|
||
description: 适用端口 (all:全部, web:Web后台, h5:H5端)
|
||
type: string
|
||
sort:
|
||
description: 排序值
|
||
type: integer
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
updater:
|
||
description: 更新人ID
|
||
minimum: 0
|
||
type: integer
|
||
url:
|
||
description: 请求路径
|
||
type: string
|
||
type: object
|
||
DtoPermissionTreeNode:
|
||
properties:
|
||
available_for_role_types:
|
||
description: 可用角色类型 (1:平台角色, 2:客户角色)
|
||
type: string
|
||
children:
|
||
description: 子权限列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoPermissionTreeNode'
|
||
type: array
|
||
id:
|
||
description: 权限ID
|
||
minimum: 0
|
||
type: integer
|
||
perm_code:
|
||
description: 权限编码
|
||
type: string
|
||
perm_name:
|
||
description: 权限名称
|
||
type: string
|
||
perm_type:
|
||
description: 权限类型 (1:菜单, 2:按钮)
|
||
type: integer
|
||
platform:
|
||
description: 适用端口 (all:全部, web:Web后台, h5:H5端)
|
||
type: string
|
||
sort:
|
||
description: 排序值
|
||
type: integer
|
||
url:
|
||
description: 请求路径
|
||
type: string
|
||
type: object
|
||
DtoRecallCardsReq:
|
||
properties:
|
||
iccids:
|
||
description: 需要回收授权的 ICCID 列表
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
required:
|
||
- iccids
|
||
type: object
|
||
DtoRecallCardsResp:
|
||
properties:
|
||
fail_count:
|
||
description: 失败数量
|
||
type: integer
|
||
failed_items:
|
||
description: 失败详情
|
||
items:
|
||
$ref: '#/components/schemas/DtoFailedItem'
|
||
nullable: true
|
||
type: array
|
||
recalled_devices:
|
||
description: 连带回收的设备列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoRecalledDevice'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数量
|
||
type: integer
|
||
type: object
|
||
DtoRecallDevicesRequest:
|
||
properties:
|
||
device_ids:
|
||
description: 设备ID列表
|
||
items:
|
||
minimum: 0
|
||
type: integer
|
||
maxItems: 100
|
||
minItems: 1
|
||
nullable: true
|
||
type: array
|
||
remark:
|
||
description: 备注
|
||
maxLength: 500
|
||
type: string
|
||
required:
|
||
- device_ids
|
||
type: object
|
||
DtoRecallDevicesResponse:
|
||
properties:
|
||
fail_count:
|
||
description: 失败数量
|
||
type: integer
|
||
failed_items:
|
||
description: 失败详情列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAllocationDeviceFailedItem'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数量
|
||
type: integer
|
||
type: object
|
||
DtoRecallStandaloneCardsRequest:
|
||
properties:
|
||
batch_no:
|
||
description: 批次号(selection_type=filter时可选)
|
||
maxLength: 100
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID(selection_type=filter时可选)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
from_shop_id:
|
||
description: 来源店铺ID(被回收方)
|
||
minimum: 1
|
||
type: integer
|
||
iccid_end:
|
||
description: 结束ICCID(selection_type=range时必填)
|
||
maxLength: 20
|
||
type: string
|
||
iccid_start:
|
||
description: 起始ICCID(selection_type=range时必填)
|
||
maxLength: 20
|
||
type: string
|
||
iccids:
|
||
description: ICCID列表(selection_type=list时必填,最多1000个)
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
remark:
|
||
description: 备注
|
||
maxLength: 500
|
||
type: string
|
||
selection_type:
|
||
description: 选卡方式 (list:ICCID列表, range:号段范围, filter:筛选条件)
|
||
enum:
|
||
- list
|
||
- range
|
||
- filter
|
||
type: string
|
||
required:
|
||
- from_shop_id
|
||
- selection_type
|
||
type: object
|
||
DtoRecallStandaloneCardsResponse:
|
||
properties:
|
||
allocation_no:
|
||
description: 回收单号
|
||
type: string
|
||
fail_count:
|
||
description: 失败数
|
||
type: integer
|
||
failed_items:
|
||
description: 失败项列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoAllocationFailedItem'
|
||
nullable: true
|
||
type: array
|
||
success_count:
|
||
description: 成功数
|
||
type: integer
|
||
total_count:
|
||
description: 待回收总数
|
||
type: integer
|
||
type: object
|
||
DtoRecalledDevice:
|
||
properties:
|
||
card_count:
|
||
description: 卡数量
|
||
type: integer
|
||
device_id:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
iccids:
|
||
description: 卡ICCID列表
|
||
items:
|
||
type: string
|
||
nullable: true
|
||
type: array
|
||
type: object
|
||
DtoRefreshTokenRequest:
|
||
properties:
|
||
refresh_token:
|
||
type: string
|
||
type: object
|
||
DtoRefreshTokenResponse:
|
||
properties:
|
||
access_token:
|
||
type: string
|
||
expires_in:
|
||
type: integer
|
||
type: object
|
||
DtoRejectWithdrawalReq:
|
||
properties:
|
||
remark:
|
||
description: 拒绝原因(必填)
|
||
maxLength: 500
|
||
type: string
|
||
required:
|
||
- remark
|
||
type: object
|
||
DtoRolePageResult:
|
||
properties:
|
||
items:
|
||
description: 角色列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoRoleResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoRoleResponse:
|
||
properties:
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
creator:
|
||
description: 创建人ID
|
||
minimum: 0
|
||
type: integer
|
||
id:
|
||
description: 角色ID
|
||
minimum: 0
|
||
type: integer
|
||
role_desc:
|
||
description: 角色描述
|
||
type: string
|
||
role_name:
|
||
description: 角色名称
|
||
type: string
|
||
role_type:
|
||
description: 角色类型 (1:平台角色, 2:客户角色)
|
||
type: integer
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
updater:
|
||
description: 更新人ID
|
||
minimum: 0
|
||
type: integer
|
||
type: object
|
||
DtoShopAccountPageResult:
|
||
properties:
|
||
items:
|
||
description: 代理账号列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoShopAccountResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoShopAccountResponse:
|
||
properties:
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
id:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
phone:
|
||
description: 手机号
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
user_type:
|
||
description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
type: string
|
||
type: object
|
||
DtoShopCommissionRecordItem:
|
||
properties:
|
||
amount:
|
||
description: 佣金金额(分)
|
||
type: integer
|
||
balance_after:
|
||
description: 入账后佣金余额(分)
|
||
type: integer
|
||
commission_type:
|
||
description: 佣金类型 (one_time:一次性, long_term:长期)
|
||
type: string
|
||
created_at:
|
||
description: 佣金入账时间
|
||
type: string
|
||
device_no:
|
||
description: 设备号
|
||
type: string
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 佣金记录ID
|
||
minimum: 0
|
||
type: integer
|
||
order_created_at:
|
||
description: 订单创建时间
|
||
type: string
|
||
order_id:
|
||
description: 订单ID
|
||
minimum: 0
|
||
type: integer
|
||
order_no:
|
||
description: 订单号
|
||
type: string
|
||
status:
|
||
description: 状态 (1:已冻结, 2:解冻中, 3:已发放, 4:已失效)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
type: object
|
||
DtoShopCommissionRecordPageResult:
|
||
properties:
|
||
items:
|
||
description: 佣金明细列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoShopCommissionRecordItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoShopCommissionSummaryItem:
|
||
properties:
|
||
available_commission:
|
||
description: 可提现佣金(分)
|
||
type: integer
|
||
created_at:
|
||
description: 店铺创建时间
|
||
type: string
|
||
frozen_commission:
|
||
description: 冻结中佣金(分)
|
||
type: integer
|
||
phone:
|
||
description: 主账号手机号
|
||
type: string
|
||
shop_code:
|
||
description: 店铺编码
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
total_commission:
|
||
description: 总佣金(分)
|
||
type: integer
|
||
unwithdraw_commission:
|
||
description: 未提现佣金(分)
|
||
type: integer
|
||
username:
|
||
description: 主账号用户名
|
||
type: string
|
||
withdrawing_commission:
|
||
description: 提现中佣金(分)
|
||
type: integer
|
||
withdrawn_commission:
|
||
description: 已提现佣金(分)
|
||
type: integer
|
||
type: object
|
||
DtoShopCommissionSummaryPageResult:
|
||
properties:
|
||
items:
|
||
description: 代理商佣金列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoShopCommissionSummaryItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoShopPageResult:
|
||
properties:
|
||
items:
|
||
description: 店铺列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoShopResponse'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoShopResponse:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
type: string
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
type: string
|
||
id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
level:
|
||
description: 店铺层级 (1-7级)
|
||
type: integer
|
||
parent_id:
|
||
description: 上级店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
province:
|
||
description: 省份
|
||
type: string
|
||
shop_code:
|
||
description: 店铺编号
|
||
type: string
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
updated_at:
|
||
description: 更新时间
|
||
type: string
|
||
type: object
|
||
DtoShopWithdrawalRequestItem:
|
||
properties:
|
||
account_name:
|
||
description: 收款账户名称
|
||
type: string
|
||
account_number:
|
||
description: 收款账号
|
||
type: string
|
||
actual_amount:
|
||
description: 实际到账金额(分)
|
||
type: integer
|
||
amount:
|
||
description: 提现金额(分)
|
||
type: integer
|
||
applicant_id:
|
||
description: 申请人账号ID
|
||
minimum: 0
|
||
type: integer
|
||
applicant_name:
|
||
description: 申请人用户名
|
||
type: string
|
||
bank_name:
|
||
description: 银行名称(银行卡提现时)
|
||
type: string
|
||
created_at:
|
||
description: 申请时间
|
||
type: string
|
||
fee:
|
||
description: 手续费(分)
|
||
type: integer
|
||
fee_rate:
|
||
description: 手续费比率(基点,100=1%)
|
||
type: integer
|
||
id:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
paid_at:
|
||
description: 到账时间
|
||
type: string
|
||
payment_type:
|
||
description: 放款类型 (manual:人工打款)
|
||
type: string
|
||
processed_at:
|
||
description: 处理时间
|
||
type: string
|
||
processor_id:
|
||
description: 处理人账号ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
processor_name:
|
||
description: 处理人用户名
|
||
type: string
|
||
reject_reason:
|
||
description: 拒绝原因
|
||
type: string
|
||
remark:
|
||
description: 备注
|
||
type: string
|
||
shop_hierarchy:
|
||
description: 店铺层级路径(格式:上上级_上级_本身,最多两层上级)
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (1:待审核, 2:已通过, 3:已拒绝, 4:已到账)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
withdrawal_method:
|
||
description: 提现方式 (alipay:支付宝, wechat:微信, bank:银行卡)
|
||
type: string
|
||
withdrawal_no:
|
||
description: 提现单号
|
||
type: string
|
||
type: object
|
||
DtoShopWithdrawalRequestPageResult:
|
||
properties:
|
||
items:
|
||
description: 提现记录列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoShopWithdrawalRequestItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoStandaloneIotCardResponse:
|
||
properties:
|
||
activated_at:
|
||
description: 激活时间
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
activation_status:
|
||
description: 激活状态 (0:未激活, 1:已激活)
|
||
type: integer
|
||
batch_no:
|
||
description: 批次号
|
||
type: string
|
||
card_category:
|
||
description: 卡业务类型 (normal:普通卡, industry:行业卡)
|
||
type: string
|
||
card_type:
|
||
description: 卡类型
|
||
type: string
|
||
carrier_id:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
type: integer
|
||
carrier_name:
|
||
description: 运营商名称
|
||
type: string
|
||
carrier_type:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
type: string
|
||
cost_price:
|
||
description: 成本价(分)
|
||
type: integer
|
||
created_at:
|
||
description: 创建时间
|
||
format: date-time
|
||
type: string
|
||
data_usage_mb:
|
||
description: 累计流量使用(MB)
|
||
type: integer
|
||
distribute_price:
|
||
description: 分销价(分)
|
||
type: integer
|
||
iccid:
|
||
description: ICCID
|
||
type: string
|
||
id:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
imsi:
|
||
description: IMSI
|
||
type: string
|
||
msisdn:
|
||
description: 卡接入号
|
||
type: string
|
||
network_status:
|
||
description: 网络状态 (0:停机, 1:开机)
|
||
type: integer
|
||
real_name_status:
|
||
description: 实名状态 (0:未实名, 1:已实名)
|
||
type: integer
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
type: integer
|
||
supplier:
|
||
description: 供应商
|
||
type: string
|
||
updated_at:
|
||
description: 更新时间
|
||
format: date-time
|
||
type: string
|
||
type: object
|
||
DtoUnbindCardFromDeviceResponse:
|
||
properties:
|
||
message:
|
||
description: 提示信息
|
||
type: string
|
||
type: object
|
||
DtoUpdateAccountParams:
|
||
properties:
|
||
password:
|
||
description: 密码
|
||
maxLength: 32
|
||
minLength: 8
|
||
nullable: true
|
||
type: string
|
||
phone:
|
||
description: 手机号
|
||
maxLength: 11
|
||
minLength: 11
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
username:
|
||
description: 用户名
|
||
maxLength: 50
|
||
minLength: 3
|
||
nullable: true
|
||
type: string
|
||
type: object
|
||
DtoUpdateAuthorizationRemarkReq:
|
||
properties:
|
||
remark:
|
||
description: 备注(最多500字)
|
||
type: string
|
||
type: object
|
||
DtoUpdateCarrierParams:
|
||
properties:
|
||
carrier_name:
|
||
description: 运营商名称
|
||
maxLength: 100
|
||
minLength: 1
|
||
nullable: true
|
||
type: string
|
||
description:
|
||
description: 运营商描述
|
||
maxLength: 500
|
||
nullable: true
|
||
type: string
|
||
type: object
|
||
DtoUpdateCarrierStatusParams:
|
||
properties:
|
||
status:
|
||
description: 状态 (1:启用, 0:禁用)
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUpdateCustomerAccountPasswordReq:
|
||
properties:
|
||
password:
|
||
description: 新密码
|
||
maximum: 20
|
||
minimum: 6
|
||
type: string
|
||
required:
|
||
- password
|
||
type: object
|
||
DtoUpdateCustomerAccountReq:
|
||
properties:
|
||
phone:
|
||
description: 手机号
|
||
nullable: true
|
||
type: string
|
||
username:
|
||
description: 用户名
|
||
maximum: 50
|
||
minimum: 2
|
||
nullable: true
|
||
type: string
|
||
type: object
|
||
DtoUpdateCustomerAccountStatusReq:
|
||
properties:
|
||
status:
|
||
description: 状态(0=禁用, 1=启用)
|
||
enum:
|
||
- "0"
|
||
- "1"
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUpdateEnterprisePasswordReq:
|
||
properties:
|
||
password:
|
||
description: 新密码
|
||
maximum: 20
|
||
minimum: 6
|
||
type: string
|
||
required:
|
||
- password
|
||
type: object
|
||
DtoUpdateEnterpriseReq:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
maximum: 255
|
||
nullable: true
|
||
type: string
|
||
business_license:
|
||
description: 营业执照号
|
||
maximum: 100
|
||
nullable: true
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
maximum: 20
|
||
nullable: true
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
enterprise_code:
|
||
description: 企业编号
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
enterprise_name:
|
||
description: 企业名称
|
||
maximum: 100
|
||
nullable: true
|
||
type: string
|
||
legal_person:
|
||
description: 法人代表
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
owner_shop_id:
|
||
description: 归属店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
province:
|
||
description: 省份
|
||
maximum: 50
|
||
nullable: true
|
||
type: string
|
||
type: object
|
||
DtoUpdateEnterpriseStatusReq:
|
||
properties:
|
||
status:
|
||
description: 状态(0=禁用, 1=启用)
|
||
enum:
|
||
- "0"
|
||
- "1"
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUpdatePasswordParams:
|
||
properties:
|
||
new_password:
|
||
description: 新密码(8-32位)
|
||
maxLength: 32
|
||
minLength: 8
|
||
type: string
|
||
required:
|
||
- new_password
|
||
type: object
|
||
DtoUpdatePermissionParams:
|
||
properties:
|
||
parent_id:
|
||
description: 父权限ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
perm_code:
|
||
description: 权限编码
|
||
maxLength: 100
|
||
minLength: 1
|
||
nullable: true
|
||
type: string
|
||
perm_name:
|
||
description: 权限名称
|
||
maxLength: 50
|
||
minLength: 1
|
||
nullable: true
|
||
type: string
|
||
platform:
|
||
description: 适用端口 (all:全部, web:Web后台, h5:H5端)
|
||
nullable: true
|
||
type: string
|
||
sort:
|
||
description: 排序值
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
url:
|
||
description: 请求路径
|
||
maxLength: 255
|
||
nullable: true
|
||
type: string
|
||
type: object
|
||
DtoUpdateRoleParams:
|
||
properties:
|
||
role_desc:
|
||
description: 角色描述
|
||
maxLength: 255
|
||
nullable: true
|
||
type: string
|
||
role_name:
|
||
description: 角色名称
|
||
maxLength: 50
|
||
minLength: 1
|
||
nullable: true
|
||
type: string
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
type: object
|
||
DtoUpdateRoleStatusParams:
|
||
properties:
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUpdateShopAccountParams:
|
||
properties:
|
||
username:
|
||
description: 用户名
|
||
maxLength: 50
|
||
minLength: 3
|
||
type: string
|
||
required:
|
||
- username
|
||
type: object
|
||
DtoUpdateShopAccountPasswordParams:
|
||
properties:
|
||
new_password:
|
||
description: 新密码
|
||
maxLength: 32
|
||
minLength: 8
|
||
type: string
|
||
required:
|
||
- new_password
|
||
type: object
|
||
DtoUpdateShopAccountStatusParams:
|
||
properties:
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUpdateShopParams:
|
||
properties:
|
||
address:
|
||
description: 详细地址
|
||
maxLength: 255
|
||
type: string
|
||
city:
|
||
description: 城市
|
||
maxLength: 50
|
||
type: string
|
||
contact_name:
|
||
description: 联系人姓名
|
||
maxLength: 50
|
||
type: string
|
||
contact_phone:
|
||
description: 联系人电话
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
district:
|
||
description: 区县
|
||
maxLength: 50
|
||
type: string
|
||
province:
|
||
description: 省份
|
||
maxLength: 50
|
||
type: string
|
||
shop_name:
|
||
description: 店铺名称
|
||
maxLength: 100
|
||
minLength: 1
|
||
type: string
|
||
status:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
type: integer
|
||
required:
|
||
- shop_name
|
||
- status
|
||
type: object
|
||
DtoUpdateStatusParams:
|
||
properties:
|
||
status:
|
||
description: 状态(0:禁用,1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
type: integer
|
||
required:
|
||
- status
|
||
type: object
|
||
DtoUserInfo:
|
||
properties:
|
||
enterprise_id:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
enterprise_name:
|
||
description: 企业名称
|
||
type: string
|
||
id:
|
||
description: 用户ID
|
||
minimum: 0
|
||
type: integer
|
||
phone:
|
||
description: 手机号
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
user_type:
|
||
description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
type: integer
|
||
user_type_name:
|
||
description: 用户类型名称
|
||
type: string
|
||
username:
|
||
description: 用户名
|
||
type: string
|
||
type: object
|
||
DtoWithdrawalApprovalResp:
|
||
properties:
|
||
id:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
processed_at:
|
||
description: 处理时间
|
||
type: string
|
||
status:
|
||
description: 状态 (1:待审核, 2:已通过, 3:已拒绝, 4:已到账)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
withdrawal_no:
|
||
description: 提现单号
|
||
type: string
|
||
type: object
|
||
DtoWithdrawalRequestItem:
|
||
properties:
|
||
account_name:
|
||
description: 收款账户名称
|
||
type: string
|
||
account_number:
|
||
description: 收款账号
|
||
type: string
|
||
actual_amount:
|
||
description: 实际到账金额(分)
|
||
type: integer
|
||
amount:
|
||
description: 提现金额(分)
|
||
type: integer
|
||
applicant_id:
|
||
description: 申请人账号ID
|
||
minimum: 0
|
||
type: integer
|
||
applicant_name:
|
||
description: 申请人用户名
|
||
type: string
|
||
bank_name:
|
||
description: 银行名称
|
||
type: string
|
||
created_at:
|
||
description: 申请时间
|
||
type: string
|
||
fee:
|
||
description: 手续费(分)
|
||
type: integer
|
||
fee_rate:
|
||
description: 手续费比率(基点,100=1%)
|
||
type: integer
|
||
id:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
payment_type:
|
||
description: 放款类型 (manual:人工打款)
|
||
type: string
|
||
processed_at:
|
||
description: 处理时间
|
||
type: string
|
||
processor_id:
|
||
description: 处理人账号ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
processor_name:
|
||
description: 处理人用户名
|
||
type: string
|
||
reject_reason:
|
||
description: 拒绝原因
|
||
type: string
|
||
remark:
|
||
description: 备注
|
||
type: string
|
||
shop_hierarchy:
|
||
description: 店铺层级路径
|
||
type: string
|
||
shop_id:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
shop_name:
|
||
description: 店铺名称
|
||
type: string
|
||
status:
|
||
description: 状态 (1:待审核, 2:已通过, 3:已拒绝, 4:已到账)
|
||
type: integer
|
||
status_name:
|
||
description: 状态名称
|
||
type: string
|
||
withdrawal_method:
|
||
description: 提现方式 (alipay:支付宝, wechat:微信, bank:银行卡)
|
||
type: string
|
||
withdrawal_no:
|
||
description: 提现单号
|
||
type: string
|
||
type: object
|
||
DtoWithdrawalRequestPageResult:
|
||
properties:
|
||
items:
|
||
description: 提现申请列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoWithdrawalRequestItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
DtoWithdrawalSettingItem:
|
||
properties:
|
||
arrival_days:
|
||
description: 到账天数
|
||
type: integer
|
||
created_at:
|
||
description: 创建时间
|
||
type: string
|
||
creator_id:
|
||
description: 创建人ID
|
||
minimum: 0
|
||
type: integer
|
||
creator_name:
|
||
description: 创建人用户名
|
||
type: string
|
||
daily_withdrawal_limit:
|
||
description: 每日提现次数限制
|
||
type: integer
|
||
fee_rate:
|
||
description: 手续费比率(基点,100=1%)
|
||
type: integer
|
||
id:
|
||
description: 配置ID
|
||
minimum: 0
|
||
type: integer
|
||
is_active:
|
||
description: 是否生效
|
||
type: boolean
|
||
min_withdrawal_amount:
|
||
description: 最低提现金额(分)
|
||
type: integer
|
||
type: object
|
||
DtoWithdrawalSettingPageResult:
|
||
properties:
|
||
items:
|
||
description: 配置列表
|
||
items:
|
||
$ref: '#/components/schemas/DtoWithdrawalSettingItem'
|
||
nullable: true
|
||
type: array
|
||
page:
|
||
description: 当前页码
|
||
type: integer
|
||
size:
|
||
description: 每页数量
|
||
type: integer
|
||
total:
|
||
description: 总记录数
|
||
type: integer
|
||
type: object
|
||
ErrorResponse:
|
||
properties:
|
||
code:
|
||
description: 错误码
|
||
type: integer
|
||
message:
|
||
description: 错误消息
|
||
type: string
|
||
timestamp:
|
||
description: 时间戳
|
||
format: date-time
|
||
type: string
|
||
required:
|
||
- code
|
||
- message
|
||
- timestamp
|
||
type: object
|
||
ModelPermission:
|
||
properties:
|
||
available_for_role_types:
|
||
type: string
|
||
creator:
|
||
minimum: 0
|
||
type: integer
|
||
parent_id:
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
perm_code:
|
||
type: string
|
||
perm_name:
|
||
type: string
|
||
perm_type:
|
||
type: integer
|
||
platform:
|
||
type: string
|
||
sort:
|
||
type: integer
|
||
status:
|
||
type: integer
|
||
updater:
|
||
minimum: 0
|
||
type: integer
|
||
url:
|
||
type: string
|
||
type: object
|
||
ModelRole:
|
||
properties:
|
||
creator:
|
||
minimum: 0
|
||
type: integer
|
||
role_desc:
|
||
type: string
|
||
role_name:
|
||
type: string
|
||
role_type:
|
||
type: integer
|
||
status:
|
||
type: integer
|
||
updater:
|
||
minimum: 0
|
||
type: integer
|
||
type: object
|
||
RoutesHealthResponse:
|
||
properties:
|
||
service:
|
||
description: 服务名称
|
||
type: string
|
||
status:
|
||
description: 健康状态
|
||
type: string
|
||
type: object
|
||
RoutesTaskStatusResponse:
|
||
properties:
|
||
id:
|
||
description: 任务ID
|
||
type: string
|
||
status:
|
||
description: 任务状态 (pending:待处理, running:执行中, completed:已完成, failed:失败)
|
||
type: string
|
||
type: object
|
||
securitySchemes:
|
||
BearerAuth:
|
||
bearerFormat: JWT
|
||
scheme: bearer
|
||
type: http
|
||
info:
|
||
title: Admin API
|
||
version: "1.0"
|
||
openapi: 3.0.3
|
||
paths:
|
||
/api/admin/accounts:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 用户名模糊查询
|
||
in: query
|
||
name: username
|
||
schema:
|
||
description: 用户名模糊查询
|
||
maxLength: 50
|
||
type: string
|
||
- description: 手机号模糊查询
|
||
in: query
|
||
name: phone
|
||
schema:
|
||
description: 手机号模糊查询
|
||
maxLength: 20
|
||
type: string
|
||
- description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
in: query
|
||
name: user_type
|
||
schema:
|
||
description: 用户类型 (1:超级管理员, 2:平台用户, 3:代理账号, 4:企业账号)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 账号列表
|
||
tags:
|
||
- 账号相关
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateAccountRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建账号
|
||
tags:
|
||
- 账号相关
|
||
/api/admin/accounts/{account_id}/roles/{role_id}:
|
||
delete:
|
||
parameters:
|
||
- description: 账号ID
|
||
in: path
|
||
name: account_id
|
||
required: true
|
||
schema:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: 角色ID
|
||
in: path
|
||
name: role_id
|
||
required: true
|
||
schema:
|
||
description: 角色ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 移除角色
|
||
tags:
|
||
- 账号相关
|
||
/api/admin/accounts/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除账号
|
||
tags:
|
||
- 账号相关
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取账号详情
|
||
tags:
|
||
- 账号相关
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateAccountParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新账号
|
||
tags:
|
||
- 账号相关
|
||
/api/admin/accounts/{id}/roles:
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
items:
|
||
$ref: '#/components/schemas/ModelRole'
|
||
type: array
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取账号角色
|
||
tags:
|
||
- 账号相关
|
||
post:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAssignRolesParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 分配角色
|
||
tags:
|
||
- 账号相关
|
||
/api/admin/asset-allocation-records:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 分配类型 (allocate:分配, recall:回收)
|
||
in: query
|
||
name: allocation_type
|
||
schema:
|
||
description: 分配类型 (allocate:分配, recall:回收)
|
||
enum:
|
||
- allocate
|
||
- recall
|
||
type: string
|
||
- description: 资产类型 (iot_card:物联网卡, device:设备)
|
||
in: query
|
||
name: asset_type
|
||
schema:
|
||
description: 资产类型 (iot_card:物联网卡, device:设备)
|
||
enum:
|
||
- iot_card
|
||
- device
|
||
type: string
|
||
- description: 资产标识符(ICCID或设备号,模糊查询)
|
||
in: query
|
||
name: asset_identifier
|
||
schema:
|
||
description: 资产标识符(ICCID或设备号,模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 分配单号(精确匹配)
|
||
in: query
|
||
name: allocation_no
|
||
schema:
|
||
description: 分配单号(精确匹配)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 来源店铺ID
|
||
in: query
|
||
name: from_shop_id
|
||
schema:
|
||
description: 来源店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 目标店铺ID
|
||
in: query
|
||
name: to_shop_id
|
||
schema:
|
||
description: 目标店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 操作人ID
|
||
in: query
|
||
name: operator_id
|
||
schema:
|
||
description: 操作人ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 创建时间起始
|
||
in: query
|
||
name: created_at_start
|
||
schema:
|
||
description: 创建时间起始
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
- description: 创建时间结束
|
||
in: query
|
||
name: created_at_end
|
||
schema:
|
||
description: 创建时间结束
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListAssetAllocationRecordResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 分配记录列表
|
||
tags:
|
||
- 资产分配记录
|
||
/api/admin/asset-allocation-records/{id}:
|
||
get:
|
||
parameters:
|
||
- description: 记录ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 记录ID
|
||
minimum: 1
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAssetAllocationRecordDetailResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 分配记录详情
|
||
tags:
|
||
- 资产分配记录
|
||
/api/admin/authorizations:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 按企业ID筛选
|
||
in: query
|
||
name: enterprise_id
|
||
schema:
|
||
description: 按企业ID筛选
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 按ICCID模糊查询
|
||
in: query
|
||
name: iccid
|
||
schema:
|
||
description: 按ICCID模糊查询
|
||
type: string
|
||
- description: 授权人类型:2=平台,3=代理
|
||
in: query
|
||
name: authorizer_type
|
||
schema:
|
||
description: 授权人类型:2=平台,3=代理
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态:0=已回收,1=有效
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态:0=已回收,1=有效
|
||
nullable: true
|
||
type: integer
|
||
- description: 授权时间起(格式:2006-01-02)
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 授权时间起(格式:2006-01-02)
|
||
type: string
|
||
- description: 授权时间止(格式:2006-01-02)
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 授权时间止(格式:2006-01-02)
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAuthorizationListResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 授权记录列表
|
||
tags:
|
||
- 授权记录管理
|
||
/api/admin/authorizations/{id}:
|
||
get:
|
||
parameters:
|
||
- description: 授权记录ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 授权记录ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAuthorizationItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 授权记录详情
|
||
tags:
|
||
- 授权记录管理
|
||
/api/admin/authorizations/{id}/remark:
|
||
put:
|
||
parameters:
|
||
- description: 授权记录ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 授权记录ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateAuthorizationRemarkReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAuthorizationItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改授权备注
|
||
tags:
|
||
- 授权记录管理
|
||
/api/admin/carriers:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
in: query
|
||
name: carrier_type
|
||
schema:
|
||
description: 运营商类型 (CMCC:中国移动, CUCC:中国联通, CTCC:中国电信, CBN:中国广电)
|
||
nullable: true
|
||
type: string
|
||
- description: 运营商名称(模糊搜索)
|
||
in: query
|
||
name: carrier_name
|
||
schema:
|
||
description: 运营商名称(模糊搜索)
|
||
maxLength: 100
|
||
nullable: true
|
||
type: string
|
||
- description: 状态 (1:启用, 0:禁用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (1:启用, 0:禁用)
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCarrierPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 运营商列表
|
||
tags:
|
||
- 运营商管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateCarrierRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCarrierResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建运营商
|
||
tags:
|
||
- 运营商管理
|
||
/api/admin/carriers/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除运营商
|
||
tags:
|
||
- 运营商管理
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCarrierResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取运营商详情
|
||
tags:
|
||
- 运营商管理
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateCarrierParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCarrierResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新运营商
|
||
tags:
|
||
- 运营商管理
|
||
/api/admin/carriers/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateCarrierStatusParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新运营商状态
|
||
tags:
|
||
- 运营商管理
|
||
/api/admin/commission/withdrawal-requests:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 状态 (1:待审核, 2:已通过, 3:已拒绝, 4:已到账)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (1:待审核, 2:已通过, 3:已拒绝, 4:已到账)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 提现单号(精确查询)
|
||
in: query
|
||
name: withdrawal_no
|
||
schema:
|
||
description: 提现单号(精确查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 店铺名称(模糊查询)
|
||
in: query
|
||
name: shop_name
|
||
schema:
|
||
description: 店铺名称(模糊查询)
|
||
maxLength: 100
|
||
type: string
|
||
- description: 申请开始时间(格式:2006-01-02 15:04:05)
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 申请开始时间(格式:2006-01-02 15:04:05)
|
||
type: string
|
||
- description: 申请结束时间(格式:2006-01-02 15:04:05)
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 申请结束时间(格式:2006-01-02 15:04:05)
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalRequestPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 提现申请列表
|
||
tags:
|
||
- 佣金提现审批
|
||
/api/admin/commission/withdrawal-requests/{id}/approve:
|
||
post:
|
||
parameters:
|
||
- description: 提现申请ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoApproveWithdrawalReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalApprovalResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 审批通过提现申请
|
||
tags:
|
||
- 佣金提现审批
|
||
/api/admin/commission/withdrawal-requests/{id}/reject:
|
||
post:
|
||
parameters:
|
||
- description: 提现申请ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 提现申请ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRejectWithdrawalReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalApprovalResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 拒绝提现申请
|
||
tags:
|
||
- 佣金提现审批
|
||
/api/admin/commission/withdrawal-settings:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalSettingPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 提现配置列表
|
||
tags:
|
||
- 提现配置管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateWithdrawalSettingReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalSettingItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 新增提现配置
|
||
tags:
|
||
- 提现配置管理
|
||
/api/admin/commission/withdrawal-settings/current:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalSettingItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取当前生效的提现配置
|
||
tags:
|
||
- 提现配置管理
|
||
/api/admin/customer-accounts:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 用户名(模糊查询)
|
||
in: query
|
||
name: username
|
||
schema:
|
||
description: 用户名(模糊查询)
|
||
type: string
|
||
- description: 手机号(模糊查询)
|
||
in: query
|
||
name: phone
|
||
schema:
|
||
description: 手机号(模糊查询)
|
||
type: string
|
||
- description: 用户类型(3=代理账号, 4=企业账号)
|
||
in: query
|
||
name: user_type
|
||
schema:
|
||
description: 用户类型(3=代理账号, 4=企业账号)
|
||
nullable: true
|
||
type: integer
|
||
- description: 店铺ID
|
||
in: query
|
||
name: shop_id
|
||
schema:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 企业ID
|
||
in: query
|
||
name: enterprise_id
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态(0=禁用, 1=启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态(0=禁用, 1=启用)
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCustomerAccountPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 客户账号列表
|
||
tags:
|
||
- 客户账号管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateCustomerAccountReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCustomerAccountItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 新增代理商账号
|
||
tags:
|
||
- 客户账号管理
|
||
/api/admin/customer-accounts/{id}:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateCustomerAccountReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCustomerAccountItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 编辑账号
|
||
tags:
|
||
- 客户账号管理
|
||
/api/admin/customer-accounts/{id}/password:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateCustomerAccountPasswordReq'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改账号密码
|
||
tags:
|
||
- 客户账号管理
|
||
/api/admin/customer-accounts/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateCustomerAccountStatusReq'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改账号状态
|
||
tags:
|
||
- 客户账号管理
|
||
/api/admin/devices:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 设备号(模糊查询)
|
||
in: query
|
||
name: device_no
|
||
schema:
|
||
description: 设备号(模糊查询)
|
||
maxLength: 100
|
||
type: string
|
||
- description: 设备名称(模糊查询)
|
||
in: query
|
||
name: device_name
|
||
schema:
|
||
description: 设备名称(模糊查询)
|
||
maxLength: 255
|
||
type: string
|
||
- description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 店铺ID (NULL表示平台库存)
|
||
in: query
|
||
name: shop_id
|
||
schema:
|
||
description: 店铺ID (NULL表示平台库存)
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 批次号
|
||
in: query
|
||
name: batch_no
|
||
schema:
|
||
description: 批次号
|
||
maxLength: 100
|
||
type: string
|
||
- description: 设备类型
|
||
in: query
|
||
name: device_type
|
||
schema:
|
||
description: 设备类型
|
||
maxLength: 50
|
||
type: string
|
||
- description: 制造商(模糊查询)
|
||
in: query
|
||
name: manufacturer
|
||
schema:
|
||
description: 制造商(模糊查询)
|
||
maxLength: 255
|
||
type: string
|
||
- description: 创建时间起始
|
||
in: query
|
||
name: created_at_start
|
||
schema:
|
||
description: 创建时间起始
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
- description: 创建时间结束
|
||
in: query
|
||
name: created_at_end
|
||
schema:
|
||
description: 创建时间结束
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 设备列表
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/{id}:
|
||
delete:
|
||
description: 仅平台用户可操作。删除设备时自动解绑所有卡(卡不会被删除)。
|
||
parameters:
|
||
- description: 设备ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除设备
|
||
tags:
|
||
- 设备管理
|
||
get:
|
||
parameters:
|
||
- description: 设备ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 设备详情
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/{id}/cards:
|
||
get:
|
||
parameters:
|
||
- description: 设备ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListDeviceCardsResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取设备绑定的卡列表
|
||
tags:
|
||
- 设备管理
|
||
post:
|
||
description: 仅平台用户可操作。用于导入后调整卡绑定关系(补卡、换卡)。
|
||
parameters:
|
||
- description: 设备ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoBindCardToDeviceRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoBindCardToDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 绑定卡到设备
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/{id}/cards/{cardId}:
|
||
delete:
|
||
description: 仅平台用户可操作。解绑不改变卡的 shop_id。
|
||
parameters:
|
||
- description: 设备ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 设备ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: IoT卡ID
|
||
in: path
|
||
name: cardId
|
||
required: true
|
||
schema:
|
||
description: IoT卡ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUnbindCardFromDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 解绑设备上的卡
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/allocate:
|
||
post:
|
||
description: 分配设备给直属下级店铺。分配时自动同步绑定的所有卡的 shop_id。
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateDevicesRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateDevicesResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量分配设备
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/by-imei/{imei}:
|
||
get:
|
||
parameters:
|
||
- description: 设备号(IMEI)
|
||
in: path
|
||
name: imei
|
||
required: true
|
||
schema:
|
||
description: 设备号(IMEI)
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 通过设备号查询设备详情
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/import:
|
||
post:
|
||
description: |-
|
||
仅平台用户可操作。
|
||
|
||
### 完整导入流程
|
||
|
||
1. **获取上传 URL**: 调用 `POST /api/admin/storage/upload-url`
|
||
2. **上传 CSV 文件**: 使用预签名 URL 上传文件到对象存储
|
||
3. **调用本接口**: 使用返回的 `file_key` 提交导入任务
|
||
|
||
### CSV 文件格式
|
||
|
||
必须包含列(首行为表头):
|
||
- `device_no`: 设备号(必填,唯一)
|
||
- `device_name`: 设备名称
|
||
- `device_model`: 设备型号
|
||
- `device_type`: 设备类型
|
||
- `max_sim_slots`: 最大插槽数(默认4)
|
||
- `manufacturer`: 制造商
|
||
- `iccid_1` ~ `iccid_4`: 绑定的卡 ICCID(卡必须已存在且未绑定)
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoImportDeviceRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoImportDeviceResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量导入设备
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/import/tasks:
|
||
get:
|
||
description: 仅平台用户可操作。
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 批次号(模糊查询)
|
||
in: query
|
||
name: batch_no
|
||
schema:
|
||
description: 批次号(模糊查询)
|
||
maxLength: 100
|
||
type: string
|
||
- description: 创建时间起始
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 创建时间起始
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
- description: 创建时间结束
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 创建时间结束
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListDeviceImportTaskResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 导入任务列表
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/import/tasks/{id}:
|
||
get:
|
||
description: 仅平台用户可操作。包含跳过和失败记录的详细信息。
|
||
parameters:
|
||
- description: 任务ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoDeviceImportTaskDetailResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 导入任务详情
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/devices/recall:
|
||
post:
|
||
description: 从直属下级店铺回收设备。回收时自动同步绑定的所有卡的 shop_id。
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallDevicesRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallDevicesResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量回收设备
|
||
tags:
|
||
- 设备管理
|
||
/api/admin/enterprises:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 企业名称(模糊查询)
|
||
in: query
|
||
name: enterprise_name
|
||
schema:
|
||
description: 企业名称(模糊查询)
|
||
type: string
|
||
- description: 登录手机号(模糊查询)
|
||
in: query
|
||
name: login_phone
|
||
schema:
|
||
description: 登录手机号(模糊查询)
|
||
type: string
|
||
- description: 联系人电话(模糊查询)
|
||
in: query
|
||
name: contact_phone
|
||
schema:
|
||
description: 联系人电话(模糊查询)
|
||
type: string
|
||
- description: 归属店铺ID
|
||
in: query
|
||
name: owner_shop_id
|
||
schema:
|
||
description: 归属店铺ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态(0=禁用, 1=启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态(0=禁用, 1=启用)
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoEnterprisePageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 查询企业客户列表
|
||
tags:
|
||
- 企业客户管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateEnterpriseReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateEnterpriseResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 新增企业客户
|
||
tags:
|
||
- 企业客户管理
|
||
/api/admin/enterprises/{id}:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateEnterpriseReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoEnterpriseItem'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 编辑企业信息
|
||
tags:
|
||
- 企业客户管理
|
||
/api/admin/enterprises/{id}/allocate-cards:
|
||
post:
|
||
parameters:
|
||
- description: 企业ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateCardsReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateCardsResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 授权卡给企业
|
||
tags:
|
||
- 企业卡授权
|
||
/api/admin/enterprises/{id}/cards:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 卡状态
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 卡状态
|
||
nullable: true
|
||
type: integer
|
||
- description: 运营商ID
|
||
in: query
|
||
name: carrier_id
|
||
schema:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: ICCID(模糊查询)
|
||
in: query
|
||
name: iccid
|
||
schema:
|
||
description: ICCID(模糊查询)
|
||
type: string
|
||
- description: 设备号(模糊查询)
|
||
in: query
|
||
name: device_no
|
||
schema:
|
||
description: 设备号(模糊查询)
|
||
type: string
|
||
- description: 企业ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoEnterpriseCardPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 企业卡列表
|
||
tags:
|
||
- 企业卡授权
|
||
/api/admin/enterprises/{id}/cards/{card_id}/resume:
|
||
post:
|
||
parameters:
|
||
- description: 企业ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: 卡ID
|
||
in: path
|
||
name: card_id
|
||
required: true
|
||
schema:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 复机卡
|
||
tags:
|
||
- 企业卡授权
|
||
/api/admin/enterprises/{id}/cards/{card_id}/suspend:
|
||
post:
|
||
parameters:
|
||
- description: 企业ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: 卡ID
|
||
in: path
|
||
name: card_id
|
||
required: true
|
||
schema:
|
||
description: 卡ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 停机卡
|
||
tags:
|
||
- 企业卡授权
|
||
/api/admin/enterprises/{id}/password:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateEnterprisePasswordReq'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改企业账号密码
|
||
tags:
|
||
- 企业客户管理
|
||
/api/admin/enterprises/{id}/recall-cards:
|
||
post:
|
||
parameters:
|
||
- description: 企业ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 企业ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallCardsReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallCardsResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 回收卡授权
|
||
tags:
|
||
- 企业卡授权
|
||
/api/admin/enterprises/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateEnterpriseStatusReq'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 启用/禁用企业
|
||
tags:
|
||
- 企业客户管理
|
||
/api/admin/iot-cards/by-iccid/{iccid}:
|
||
get:
|
||
parameters:
|
||
- description: ICCID
|
||
in: path
|
||
name: iccid
|
||
required: true
|
||
schema:
|
||
description: ICCID
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoIotCardDetailResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 通过ICCID查询单卡详情
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/import:
|
||
post:
|
||
description: |-
|
||
## ⚠️ 接口变更说明(BREAKING CHANGE)
|
||
|
||
本接口已从 `multipart/form-data` 改为 `application/json`。
|
||
|
||
### 完整导入流程
|
||
|
||
1. **获取上传 URL**: 调用 `POST /api/admin/storage/upload-url`
|
||
2. **上传 CSV 文件**: 使用预签名 URL 上传文件到对象存储
|
||
3. **调用本接口**: 使用返回的 `file_key` 提交导入任务
|
||
|
||
### 请求示例
|
||
|
||
```json
|
||
{
|
||
"carrier_id": 1,
|
||
"batch_no": "BATCH-2025-01",
|
||
"file_key": "imports/2025/01/24/abc123.csv"
|
||
}
|
||
```
|
||
|
||
### CSV 文件格式
|
||
|
||
- 必须包含两列:`iccid`, `msisdn`
|
||
- 首行为表头
|
||
- 编码:UTF-8
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoImportIotCardRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoImportIotCardResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量导入IoT卡(ICCID+MSISDN)
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/import-tasks:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 任务状态 (1:待处理, 2:处理中, 3:已完成, 4:失败)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 运营商ID
|
||
in: query
|
||
name: carrier_id
|
||
schema:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 批次号(模糊查询)
|
||
in: query
|
||
name: batch_no
|
||
schema:
|
||
description: 批次号(模糊查询)
|
||
maxLength: 100
|
||
type: string
|
||
- description: 创建时间起始
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 创建时间起始
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
- description: 创建时间结束
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 创建时间结束
|
||
format: date-time
|
||
nullable: true
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListImportTaskResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 导入任务列表
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/import-tasks/{id}:
|
||
get:
|
||
parameters:
|
||
- description: 任务ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: 任务ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoImportTaskDetailResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 导入任务详情
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/standalone:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (1:在库, 2:已分销, 3:已激活, 4:已停用)
|
||
maximum: 4
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 运营商ID
|
||
in: query
|
||
name: carrier_id
|
||
schema:
|
||
description: 运营商ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 分销商ID
|
||
in: query
|
||
name: shop_id
|
||
schema:
|
||
description: 分销商ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: ICCID(模糊查询)
|
||
in: query
|
||
name: iccid
|
||
schema:
|
||
description: ICCID(模糊查询)
|
||
maxLength: 20
|
||
type: string
|
||
- description: 卡接入号(模糊查询)
|
||
in: query
|
||
name: msisdn
|
||
schema:
|
||
description: 卡接入号(模糊查询)
|
||
maxLength: 20
|
||
type: string
|
||
- description: 批次号
|
||
in: query
|
||
name: batch_no
|
||
schema:
|
||
description: 批次号
|
||
maxLength: 100
|
||
type: string
|
||
- description: 套餐ID
|
||
in: query
|
||
name: package_id
|
||
schema:
|
||
description: 套餐ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 是否已分销 (true:已分销, false:未分销)
|
||
in: query
|
||
name: is_distributed
|
||
schema:
|
||
description: 是否已分销 (true:已分销, false:未分销)
|
||
nullable: true
|
||
type: boolean
|
||
- description: 是否有换卡记录 (true:有换卡记录, false:无换卡记录)
|
||
in: query
|
||
name: is_replaced
|
||
schema:
|
||
description: 是否有换卡记录 (true:有换卡记录, false:无换卡记录)
|
||
nullable: true
|
||
type: boolean
|
||
- description: ICCID起始号
|
||
in: query
|
||
name: iccid_start
|
||
schema:
|
||
description: ICCID起始号
|
||
maxLength: 20
|
||
type: string
|
||
- description: ICCID结束号
|
||
in: query
|
||
name: iccid_end
|
||
schema:
|
||
description: ICCID结束号
|
||
maxLength: 20
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoListStandaloneIotCardResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 单卡列表(未绑定设备)
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/standalone/allocate:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateStandaloneCardsRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAllocateStandaloneCardsResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量分配单卡
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/iot-cards/standalone/recall:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallStandaloneCardsRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRecallStandaloneCardsResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 批量回收单卡
|
||
tags:
|
||
- IoT卡管理
|
||
/api/admin/login:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoLoginRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoLoginResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 后台登录
|
||
tags:
|
||
- 认证
|
||
/api/admin/logout:
|
||
post:
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 登出
|
||
tags:
|
||
- 认证
|
||
/api/admin/me:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUserInfo'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取当前用户信息
|
||
tags:
|
||
- 认证
|
||
/api/admin/my/commission-records:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 佣金类型
|
||
in: query
|
||
name: commission_type
|
||
schema:
|
||
description: 佣金类型
|
||
nullable: true
|
||
type: string
|
||
- description: ICCID(模糊查询)
|
||
in: query
|
||
name: iccid
|
||
schema:
|
||
description: ICCID(模糊查询)
|
||
type: string
|
||
- description: 设备号(模糊查询)
|
||
in: query
|
||
name: device_no
|
||
schema:
|
||
description: 设备号(模糊查询)
|
||
type: string
|
||
- description: 订单号(模糊查询)
|
||
in: query
|
||
name: order_no
|
||
schema:
|
||
description: 订单号(模糊查询)
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoMyCommissionRecordPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 我的佣金明细
|
||
tags:
|
||
- 我的佣金
|
||
/api/admin/my/commission-summary:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoMyCommissionSummaryResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 我的佣金概览
|
||
tags:
|
||
- 我的佣金
|
||
/api/admin/my/withdrawal-requests:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 状态(1=待审批, 2=已通过, 3=已拒绝)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态(1=待审批, 2=已通过, 3=已拒绝)
|
||
nullable: true
|
||
type: integer
|
||
- description: 申请开始时间
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 申请开始时间
|
||
type: string
|
||
- description: 申请结束时间
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 申请结束时间
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoWithdrawalRequestPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 我的提现记录
|
||
tags:
|
||
- 我的佣金
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateMyWithdrawalReq'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateMyWithdrawalResp'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 发起提现申请
|
||
tags:
|
||
- 我的佣金
|
||
/api/admin/password:
|
||
put:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoChangePasswordRequest'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改密码
|
||
tags:
|
||
- 认证
|
||
/api/admin/permissions:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 权限名称模糊查询
|
||
in: query
|
||
name: perm_name
|
||
schema:
|
||
description: 权限名称模糊查询
|
||
maxLength: 50
|
||
type: string
|
||
- description: 权限编码模糊查询
|
||
in: query
|
||
name: perm_code
|
||
schema:
|
||
description: 权限编码模糊查询
|
||
maxLength: 100
|
||
type: string
|
||
- description: 权限类型 (1:菜单, 2:按钮)
|
||
in: query
|
||
name: perm_type
|
||
schema:
|
||
description: 权限类型 (1:菜单, 2:按钮)
|
||
maximum: 2
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 适用端口 (all:全部, web:Web后台, h5:H5端)
|
||
in: query
|
||
name: platform
|
||
schema:
|
||
description: 适用端口 (all:全部, web:Web后台, h5:H5端)
|
||
type: string
|
||
- description: 可用角色类型 (1:平台角色, 2:客户角色)
|
||
in: query
|
||
name: available_for_role_type
|
||
schema:
|
||
description: 可用角色类型 (1:平台角色, 2:客户角色)
|
||
maximum: 2
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 父权限ID
|
||
in: query
|
||
name: parent_id
|
||
schema:
|
||
description: 父权限ID
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoPermissionPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 权限列表
|
||
tags:
|
||
- 权限
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreatePermissionRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoPermissionResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建权限
|
||
tags:
|
||
- 权限
|
||
/api/admin/permissions/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除权限
|
||
tags:
|
||
- 权限
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoPermissionResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取权限详情
|
||
tags:
|
||
- 权限
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdatePermissionParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoPermissionResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新权限
|
||
tags:
|
||
- 权限
|
||
/api/admin/permissions/tree:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
items:
|
||
$ref: '#/components/schemas/DtoPermissionTreeNode'
|
||
type: array
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取权限树
|
||
tags:
|
||
- 权限
|
||
/api/admin/platform-accounts:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 用户名模糊查询
|
||
in: query
|
||
name: username
|
||
schema:
|
||
description: 用户名模糊查询
|
||
maxLength: 50
|
||
type: string
|
||
- description: 手机号模糊查询
|
||
in: query
|
||
name: phone
|
||
schema:
|
||
description: 手机号模糊查询
|
||
maxLength: 20
|
||
type: string
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 平台账号列表
|
||
tags:
|
||
- 平台账号
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateAccountRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 新增平台账号
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/platform-accounts/{account_id}/roles/{role_id}:
|
||
delete:
|
||
parameters:
|
||
- description: 账号ID
|
||
in: path
|
||
name: account_id
|
||
required: true
|
||
schema:
|
||
description: 账号ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: 角色ID
|
||
in: path
|
||
name: role_id
|
||
required: true
|
||
schema:
|
||
description: 角色ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 移除角色
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/platform-accounts/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除平台账号
|
||
tags:
|
||
- 平台账号
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取平台账号详情
|
||
tags:
|
||
- 平台账号
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateAccountParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 编辑平台账号
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/platform-accounts/{id}/password:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdatePasswordParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改密码
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/platform-accounts/{id}/roles:
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
items:
|
||
$ref: '#/components/schemas/ModelRole'
|
||
type: array
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取账号角色
|
||
tags:
|
||
- 平台账号
|
||
post:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAssignRolesParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 分配角色
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/platform-accounts/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateStatusParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 启用/禁用账号
|
||
tags:
|
||
- 平台账号
|
||
/api/admin/refresh-token:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRefreshTokenRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRefreshTokenResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 刷新 Token
|
||
tags:
|
||
- 认证
|
||
/api/admin/roles:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 角色名称模糊查询
|
||
in: query
|
||
name: role_name
|
||
schema:
|
||
description: 角色名称模糊查询
|
||
maxLength: 50
|
||
type: string
|
||
- description: 角色类型 (1:平台角色, 2:客户角色)
|
||
in: query
|
||
name: role_type
|
||
schema:
|
||
description: 角色类型 (1:平台角色, 2:客户角色)
|
||
maximum: 2
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
maximum: 1
|
||
minimum: 0
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRolePageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 角色列表
|
||
tags:
|
||
- 角色
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateRoleRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRoleResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建角色
|
||
tags:
|
||
- 角色
|
||
/api/admin/roles/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除角色
|
||
tags:
|
||
- 角色
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRoleResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取角色详情
|
||
tags:
|
||
- 角色
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateRoleParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRoleResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新角色
|
||
tags:
|
||
- 角色
|
||
/api/admin/roles/{id}/permissions:
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
items:
|
||
$ref: '#/components/schemas/ModelPermission'
|
||
type: array
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取角色权限
|
||
tags:
|
||
- 角色
|
||
post:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoAssignPermissionsParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 分配权限
|
||
tags:
|
||
- 角色
|
||
/api/admin/roles/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateRoleStatusParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新角色状态
|
||
tags:
|
||
- 角色
|
||
/api/admin/roles/{role_id}/permissions/{perm_id}:
|
||
delete:
|
||
parameters:
|
||
- description: 角色ID
|
||
in: path
|
||
name: role_id
|
||
required: true
|
||
schema:
|
||
description: 角色ID
|
||
minimum: 0
|
||
type: integer
|
||
- description: 权限ID
|
||
in: path
|
||
name: perm_id
|
||
required: true
|
||
schema:
|
||
description: 权限ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 移除权限
|
||
tags:
|
||
- 角色
|
||
/api/admin/shop-accounts:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 店铺ID过滤
|
||
in: query
|
||
name: shop_id
|
||
schema:
|
||
description: 店铺ID过滤
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 用户名(模糊查询)
|
||
in: query
|
||
name: username
|
||
schema:
|
||
description: 用户名(模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 手机号(精确查询)
|
||
in: query
|
||
name: phone
|
||
schema:
|
||
description: 手机号(精确查询)
|
||
maxLength: 11
|
||
minLength: 11
|
||
type: string
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopAccountPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 代理账号列表
|
||
tags:
|
||
- 代理账号管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateShopAccountRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建代理账号
|
||
tags:
|
||
- 代理账号管理
|
||
/api/admin/shop-accounts/{id}:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateShopAccountParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopAccountResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新代理账号
|
||
tags:
|
||
- 代理账号管理
|
||
/api/admin/shop-accounts/{id}/password:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateShopAccountPasswordParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 重置代理账号密码
|
||
tags:
|
||
- 代理账号管理
|
||
/api/admin/shop-accounts/{id}/status:
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateShopAccountStatusParams'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 启用/禁用代理账号
|
||
tags:
|
||
- 代理账号管理
|
||
/api/admin/shops:
|
||
get:
|
||
parameters:
|
||
- description: 页码
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 店铺名称模糊查询
|
||
in: query
|
||
name: shop_name
|
||
schema:
|
||
description: 店铺名称模糊查询
|
||
maxLength: 100
|
||
type: string
|
||
- description: 店铺编号模糊查询
|
||
in: query
|
||
name: shop_code
|
||
schema:
|
||
description: 店铺编号模糊查询
|
||
maxLength: 50
|
||
type: string
|
||
- description: 上级店铺ID
|
||
in: query
|
||
name: parent_id
|
||
schema:
|
||
description: 上级店铺ID
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 店铺层级 (1-7级)
|
||
in: query
|
||
name: level
|
||
schema:
|
||
description: 店铺层级 (1-7级)
|
||
maximum: 7
|
||
minimum: 1
|
||
nullable: true
|
||
type: integer
|
||
- description: 状态 (0:禁用, 1:启用)
|
||
in: query
|
||
name: status
|
||
schema:
|
||
description: 状态 (0:禁用, 1:启用)
|
||
nullable: true
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 店铺列表
|
||
tags:
|
||
- 店铺管理
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoCreateShopRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 创建店铺
|
||
tags:
|
||
- 店铺管理
|
||
/api/admin/shops/{id}:
|
||
delete:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 删除店铺
|
||
tags:
|
||
- 店铺管理
|
||
put:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUpdateShopParams'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 更新店铺
|
||
tags:
|
||
- 店铺管理
|
||
/api/admin/shops/{shop_id}/commission-records:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 佣金类型 (one_time:一次性, long_term:长期)
|
||
in: query
|
||
name: commission_type
|
||
schema:
|
||
description: 佣金类型 (one_time:一次性, long_term:长期)
|
||
type: string
|
||
- description: ICCID(模糊查询)
|
||
in: query
|
||
name: iccid
|
||
schema:
|
||
description: ICCID(模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 设备号(模糊查询)
|
||
in: query
|
||
name: device_no
|
||
schema:
|
||
description: 设备号(模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 订单号(模糊查询)
|
||
in: query
|
||
name: order_no
|
||
schema:
|
||
description: 订单号(模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 店铺ID
|
||
in: path
|
||
name: shop_id
|
||
required: true
|
||
schema:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopCommissionRecordPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 代理商佣金明细
|
||
tags:
|
||
- 代理商佣金管理
|
||
/api/admin/shops/{shop_id}/withdrawal-requests:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 提现单号(精确查询)
|
||
in: query
|
||
name: withdrawal_no
|
||
schema:
|
||
description: 提现单号(精确查询)
|
||
maxLength: 50
|
||
type: string
|
||
- description: 申请开始时间(格式:2006-01-02 15:04:05)
|
||
in: query
|
||
name: start_time
|
||
schema:
|
||
description: 申请开始时间(格式:2006-01-02 15:04:05)
|
||
type: string
|
||
- description: 申请结束时间(格式:2006-01-02 15:04:05)
|
||
in: query
|
||
name: end_time
|
||
schema:
|
||
description: 申请结束时间(格式:2006-01-02 15:04:05)
|
||
type: string
|
||
- description: 店铺ID
|
||
in: path
|
||
name: shop_id
|
||
required: true
|
||
schema:
|
||
description: 店铺ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopWithdrawalRequestPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 代理商提现记录
|
||
tags:
|
||
- 代理商佣金管理
|
||
/api/admin/shops/commission-summary:
|
||
get:
|
||
parameters:
|
||
- description: 页码(默认1)
|
||
in: query
|
||
name: page
|
||
schema:
|
||
description: 页码(默认1)
|
||
minimum: 1
|
||
type: integer
|
||
- description: 每页数量(默认20,最大100)
|
||
in: query
|
||
name: page_size
|
||
schema:
|
||
description: 每页数量(默认20,最大100)
|
||
maximum: 100
|
||
minimum: 1
|
||
type: integer
|
||
- description: 店铺名称(模糊查询)
|
||
in: query
|
||
name: shop_name
|
||
schema:
|
||
description: 店铺名称(模糊查询)
|
||
maxLength: 100
|
||
type: string
|
||
- description: 主账号用户名(模糊查询)
|
||
in: query
|
||
name: username
|
||
schema:
|
||
description: 主账号用户名(模糊查询)
|
||
maxLength: 50
|
||
type: string
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoShopCommissionSummaryPageResult'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 代理商佣金列表
|
||
tags:
|
||
- 代理商佣金管理
|
||
/api/admin/storage/upload-url:
|
||
post:
|
||
description: |-
|
||
## 文件上传流程
|
||
|
||
本接口用于获取对象存储的预签名上传 URL,实现前端直传文件到对象存储。
|
||
|
||
### 完整流程
|
||
|
||
1. **调用本接口** 获取预签名 URL 和 file_key
|
||
2. **使用预签名 URL 上传文件** 发起 PUT 请求直接上传到对象存储
|
||
3. **调用业务接口** 使用 file_key 调用相关业务接口(如 ICCID 导入)
|
||
|
||
### 前端上传示例
|
||
|
||
```javascript
|
||
// 1. 获取预签名 URL
|
||
const { data } = await api.post('/storage/upload-url', {
|
||
file_name: 'cards.csv',
|
||
content_type: 'text/csv',
|
||
purpose: 'iot_import'
|
||
});
|
||
|
||
// 2. 上传文件到对象存储
|
||
await fetch(data.upload_url, {
|
||
method: 'PUT',
|
||
headers: { 'Content-Type': 'text/csv' },
|
||
body: file
|
||
});
|
||
|
||
// 3. 调用业务接口
|
||
await api.post('/iot-cards/import', {
|
||
carrier_id: 1,
|
||
batch_no: 'BATCH-2025-01',
|
||
file_key: data.file_key
|
||
});
|
||
```
|
||
|
||
### purpose 可选值
|
||
|
||
| 值 | 说明 | 生成路径格式 |
|
||
|---|------|-------------|
|
||
| iot_import | ICCID 导入 | imports/YYYY/MM/DD/uuid.csv |
|
||
| export | 数据导出 | exports/YYYY/MM/DD/uuid.xlsx |
|
||
| attachment | 附件上传 | attachments/YYYY/MM/DD/uuid.ext |
|
||
|
||
### 注意事项
|
||
|
||
- 预签名 URL 有效期 **15 分钟**,请及时使用
|
||
- 上传时 Content-Type 需与请求时一致
|
||
- file_key 在上传成功后永久有效,用于后续业务接口调用
|
||
- 上传失败时可重新调用本接口获取新的 URL
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoGetUploadURLRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoGetUploadURLResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取文件上传预签名 URL
|
||
tags:
|
||
- 对象存储
|
||
/api/admin/tasks/{id}:
|
||
get:
|
||
parameters:
|
||
- description: ID
|
||
in: path
|
||
name: id
|
||
required: true
|
||
schema:
|
||
description: ID
|
||
minimum: 0
|
||
type: integer
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/RoutesTaskStatusResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 查询任务状态
|
||
tags:
|
||
- 任务管理
|
||
/api/h5/login:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoLoginRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoLoginResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: H5 登录
|
||
tags:
|
||
- H5 认证
|
||
/api/h5/logout:
|
||
post:
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 登出
|
||
tags:
|
||
- H5 认证
|
||
/api/h5/me:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoUserInfo'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 获取当前用户信息
|
||
tags:
|
||
- H5 认证
|
||
/api/h5/password:
|
||
put:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoChangePasswordRequest'
|
||
responses:
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"401":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 未认证或认证已过期
|
||
"403":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 无权访问
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
security:
|
||
- BearerAuth: []
|
||
summary: 修改密码
|
||
tags:
|
||
- H5 认证
|
||
/api/h5/refresh-token:
|
||
post:
|
||
requestBody:
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRefreshTokenRequest'
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/DtoRefreshTokenResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 刷新 Token
|
||
tags:
|
||
- H5 认证
|
||
/health:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/RoutesHealthResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 健康检查
|
||
tags:
|
||
- 系统
|
||
/ready:
|
||
get:
|
||
responses:
|
||
"200":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/RoutesHealthResponse'
|
||
description: OK
|
||
"400":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 请求参数错误
|
||
"500":
|
||
content:
|
||
application/json:
|
||
schema:
|
||
$ref: '#/components/schemas/ErrorResponse'
|
||
description: 服务器内部错误
|
||
summary: 就绪检查
|
||
tags:
|
||
- 系统
|