获取计费账户列表 | 大装置帮助中心
跳到主要内容

获取计费账户列表

接口描述

GET /v1/billingaccounts/console 获取计费账户列表

请求头(Request Header)

参考认证(authentication)

请求参数(Request Parameters)

名称位置类型必须描述
filterquerystringfalse过滤条件
order_byquerystringfalse排序
page_sizequeryinteger(int32)false分页大小
page_tokenquerystringfalse分页

请求体(Request Body)

请求示例(Request Example)

curl --request GET \
--url https://finance.sensecoreapi.dev/boss/account/v1/billingaccounts/console \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}'

响应参数(Response Parameters)

StatusMeaningDescriptionSchema
200OKOKListBillingAccountsResponse

响应示例(Response Example)

200 Response

{
"billing_accounts": [
{
"id": "string",
"name": "string",
"display_name": "string",
"type": "string",
"parent_id": "string",
"state": "BA_UNSPECIFIED",
"auto_pay": true,
"auto_voucher": true,
"allow_arrears": true,
"allow_managed": true,
"credit_line": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"threshold_balance": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"owner_id": "string",
"tenant_id": "string",
"escrow_account_id": "string",
"password_pay": "string",
"available_balance": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"available_credit_limit": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"available_voucher_number": 0,
"available_coupon_number": 0,
"creator": "string",
"updater": "string",
"create_time": "2019-08-24T14:15:22Z",
"update_time": "2019-08-24T14:15:22Z",
"frozen": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"currency_code": "string",
"balance": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"available_contract_number": 0,
"linked_subscription_number": 0,
"disable_threshold": true,
"threshold_balance2": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"threshold_balance3": {
"currency_code": "string",
"units": 0,
"nanos": 0
},
"arrears": {
"currency_code": "string",
"units": 0,
"nanos": 0
}
}
],
"next_page_token": "string",
"total_size": 0
}

数据结构(Schemas)

BillingAccount

名称类型必须限制描述
idstringtruenone计费账户ID create: not REQUIRED, if not assign id, give "" update: REQUIRED
namestringtruenone计费账户标识
display_namestringtruenone计费账户名
typestringfalsenone类型,默认、自定义 两种
parent_idstringfalsenone父帐号 ID create: REQUIRED, if no parent, value is "" update: REQUIRED, can be updated
statestring(enum)truenone账户状态 create: REQUIRED, default value is BA_ACTIVE update: REQUIRED, can be updated
auto_paybooleantruenone是否自动支付
auto_voucherbooleantruenone是否自动使用代金券
allow_arrearsbooleantruenone是否允许欠费
allow_managedbooleantruenone是否允许被其它帐号管理,查看账单等
credit_lineMoneytruenone价格
threshold_balanceMoneytruenone价格
owner_idstringtruenone归属人ID
tenant_idstringtruenone租户ID
escrow_account_idstringfalsenone托管账户 账单将由托管账号支付,托管账户拥有管理权
password_paystringtruenone支付密码
available_balanceMoneyfalsenone价格
available_credit_limitMoneyfalsenone价格
available_voucher_numberinteger(int32)falseread-only可用代金券数
available_coupon_numberinteger(int32)falseread-only可用优惠券数
creatorstringfalseread-only创建人
updaterstringfalseread-only变更人
create_timestring(date-time)falseread-only创建时间
update_timestring(date-time)falseread-only变更时间
frozenMoneyfalsenone价格
currency_codestringtruenone货币代码
balanceMoneyfalsenone价格
available_contract_numberinteger(int32)falseread-only可用合同包数
linked_subscription_numberinteger(int32)falseread-only关联订阅数
disable_thresholdbooleanfalsenone是否关闭余额报警
threshold_balance2Moneyfalsenone价格
threshold_balance3Moneyfalsenone价格
arrearsMoneyfalsenone价格

state Enumerated Values

枚举值
BA_UNSPECIFIED
BA_ACTIVE
BA_DISABLED
BA_FROZEN

ListBillingAccountsResponse

名称类型必须限制描述
billing_accounts[BillingAccount]falsenone计费账户列表
next_page_tokenstringfalsenone下一页页码token
total_sizeinteger(int32)falsenone总页数

Money

名称类型必须限制描述
currency_codestringfalsenone货币代码, 参考ISO 4217
unitsinteger(int64)falsenone价格整数部分
nanosinteger(int32)falsenone价格小数部分