taobao.bill.accounts.get (查询费用科目信息(限自研商家))

查询费用账户信息

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
fields String [] 必须 account_id,account_code,,account_name,account_type,related_order,gmt_create,gmt_modified,status
  • 最大列表长度:20
  • 需要返回的字段
    aids String [] 可选 10002011,10003011,10005011
  • 最大列表长度:200
  • 需要获取的科目ID

    响应参数

    名称 类型 示例值 描述
    accounts Account [] 返回的科目信息
    • └ gmt_create
    • Date
    • 2000-01-01 00:00:00
    • 创建时间
    • └ account_id
    • Number
    • 10003011
    • 费用科目编号
    • └ status
    • Number
    • 1
    • 状态:0-不可用 1-可用
    • └ account_code
    • String
    • ACCT_TMALL_COMM
    • 费用科目编码
    • └ gmt_modified
    • Date
    • 2000-01-01 00:00:00
    • 修改时间
    • └ account_type
    • Number
    • 1
    • 费用科目类型:1-虚拟账户 2-交易 3-交易佣金 4-服务费 5-天猫积分 6-其他
    • └ account_name
    • String
    • 天猫佣金
    • 费用科目名称
    • └ related_order
    • Number
    • 1
    • 是否订单相关:0-订单无关 1-订单相关
    total_results Number 20 返回记录行数

    请求示例

    • JAVA
    • .NET
    • PHP
    • CURL
    • Python
    • C/C++
    • NodeJS
    TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
    BillAccountsGetRequest req = new BillAccountsGetRequest();
    req.setFields("account_id,account_code,,account_name,account_type,related_order,gmt_create,gmt_modified,status");
    req.setAids("10002011,10003011,10005011");
    BillAccountsGetResponse rsp = client.execute(req, sessionKey);
    System.out.println(rsp.getBody());

    响应示例

    • XML示例
    • JSON示例
    <bill_accounts_get_response>
        <accounts>
            <account>
                <gmt_create>2000-01-01 00:00:00</gmt_create>
                <account_id>10003011</account_id>
                <status>1</status>
                <account_code>ACCT_TMALL_COMM</account_code>
                <gmt_modified>2000-01-01 00:00:00</gmt_modified>
                <account_type>1</account_type>
                <account_name>天猫佣金</account_name>
                <related_order>1</related_order>
            </account>
        </accounts>
        <total_results>20</total_results>
    </bill_accounts_get_response>

    异常示例

    • XML示例
    • JSON示例
    <error_response>
        <code>50</code>
        <msg>Remote service error</msg>
        <sub_code>isv.invalid-parameter</sub_code>
        <sub_msg>非法参数</sub_msg>
    </error_response>

    错误码解释

    错误码 错误描述 解决方案
    isp.remote-service-timeout API调用远程服务超时 1. 每次返回50条以下,时间跨度小于半个小时 2. 避开交易高峰期上午9:30-11:00,下午14:00-17:00,晚上20:00-22:30,凌晨:1:00-3:00

    API工具

    如何获得此API

    FAQ

    返回
    顶部