流量充值记录查询接口(QueryChargeDetail)
入参列表
出参列表
技术对接步骤
1:下载SDK工具包
SDK工具包中一共包含了2个类库,一个aliyun-php-sdk-core包,另外一个是alicom-dycdp-api包,将这两个包添加到工程类库依赖。
SDK&DEMO[
下载地址]
2: 编写样例程序
- [backcolor=transparent] [backcolor=transparent]//此处需要替换成自己的AK信息
- [backcolor=transparent] $accessKeyId [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]"yourAccessKeyId"[backcolor=transparent];
- [backcolor=transparent] $accessKeySecret [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]"yourAccessKeySecret"[backcolor=transparent];
- [backcolor=transparent] [backcolor=transparent]//流量API产品名
- [backcolor=transparent] $product [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]"Dycdpapi"[backcolor=transparent];
- [backcolor=transparent] [backcolor=transparent]//流量API产品域名
- [backcolor=transparent] $domain [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]"dycdpapi.aliyuncs.com"[backcolor=transparent];
- [backcolor=transparent] [backcolor=transparent]//暂时不支持多Region
- [backcolor=transparent] $region [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]"cn-hangzhou"[backcolor=transparent];
- [backcolor=transparent] [backcolor=transparent]//初始化访问的acsCleint
- [backcolor=transparent] $profile [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]DefaultProfile[backcolor=transparent]::[backcolor=transparent]getProfile[backcolor=transparent]([backcolor=transparent]$region[backcolor=transparent],[backcolor=transparent] $accessKeyId[backcolor=transparent],[backcolor=transparent] $accessKeySecret[backcolor=transparent]);
- [backcolor=transparent] [backcolor=transparent]DefaultProfile[backcolor=transparent]::[backcolor=transparent]addEndpoint[backcolor=transparent]([backcolor=transparent]"cn-hangzhou"[backcolor=transparent],[backcolor=transparent] [backcolor=transparent]"cn-hangzhou"[backcolor=transparent],[backcolor=transparent] $product[backcolor=transparent],[backcolor=transparent] $domain[backcolor=transparent]);
- [backcolor=transparent] $acsClient[backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]new[backcolor=transparent] [backcolor=transparent]DefaultAcsClient[backcolor=transparent]([backcolor=transparent]$profile[backcolor=transparent]);
- [backcolor=transparent] $request [backcolor=transparent]=[backcolor=transparent] [backcolor=transparent]new[backcolor=transparent] [backcolor=transparent]Dycdpapi[backcolor=transparent]\Request\V[backcolor=transparent]20170525[backcolor=transparent]\QueryChargeDetailRequest[backcolor=transparent]();
- [backcolor=transparent] [backcolor=transparent]//必填-充值流水号,由调用方在调用充值接口时指定的OutId
- [backcolor=transparent] $request[backcolor=transparent]->[backcolor=transparent]setOutId[backcolor=transparent]([backcolor=transparent]"6d9fce1e"[backcolor=transparent]);
- [backcolor=transparent] [backcolor=transparent]//发起访问请求
- [backcolor=transparent] $acsResponse [backcolor=transparent]=[backcolor=transparent] $acsClient[backcolor=transparent]->[backcolor=transparent]getAcsResponse[backcolor=transparent]([backcolor=transparent]$request[backcolor=transparent]);