首页 新闻 会员 周边 捐助

有没有大佬知道速卖通订单列表怎么获取的求救,官方的sdk真的太坑 自己写又老是不对 在线等 急!

0
悬赏园豆:40 [待解决问题]

刚进一家外贸公司,需要根据速卖通提供的API开发一个管理平台  但是官方提供的sdk真的看不了  全靠自己一个人摸索。现在遇到瓶颈了  求大佬在线支招,万分感谢!   也不知道是哪个团队开发的速卖通平台 真的给跪了  

下面是代码

String createDateStart = req.getParameter("createDateStart");
String createDateEnd = req.getParameter("createDateEnd");
String orderStatus = req.getParameter("orderStatus");
System.out.println("access_Token值:" + access_token);

String timestamp = Long.toString(new Date().getTime()).substring(0, 13);
Map<String, String> params = new HashMap<String, String>();
params.put("_aop_timestamp", timestamp);// 请求时间戳
params.put("access_token", access_token);
params.put("page", "1");
params.put("pageSize", "50");
params.put("createDateStart", createDateStart);
params.put("createDateEnd", createDateEnd);
params.put("orderStatus", orderStatus);

// 签名
String signature = CommonUtil.signatureWithParamsOnly(params,
SmtAPI.APP_SECRET);
System.out.println("signature:" + signature);
String str = webpageutil.sendPost("http://gw.api.alibaba.com/openapi/param2/1/aliexpress.open/api.findOrderListQuery/"
+ SmtAPI.APP_KEY
+ "?page=1&pageSize=50&createDateStart="
+ createDateStart
+ "&createDateEnd="
+ createDateEnd
+ "Status="
+ orderStatus
+ "&access_token="
+ access_token
+ "&_aop_timestamp="
+ timestamp
+ "&_aop_signature=" + signature + "", "");

 

下面是错误

java.io.IOException: Server returned HTTP response code: 400 for URL: http://gw.api.alibaba.com/openapi/param2/1/aliexpress.open/api.findOrderListQuery/30795675?page=1&pageSize=50&createDateStart=null&createDateEnd=nullStatus=null&access_token=3ee0a3f0-1b7e-4d64-8ee5-594218103476&_aop_timestamp=1500627204823&_aop_signature=F6DE239667E46339473C8AC5E1F3B91FEE421F67
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at com.sale.service.impl.TevoWebPageServiceImpl.send(TevoWebPageServiceImpl.java:68)
at com.sale.service.impl.TevoWebPageServiceImpl.sendPost(TevoWebPageServiceImpl.java:24)
at com.sale.controll.SmtController.findOrderListQuery(SmtController.java:133)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:827)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:620)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:503)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Unknown Source)

 

Ming明的主页 Ming明 | 初学一级 | 园豆:8
提问于:2017-07-21 16:54
< >
分享
所有回答(1)
0

错误提示不是http返回errorcode 400 检查下URL对不对。。

~扎克伯格 | 园豆:1923 (小虾三级) | 2017-07-24 09:08
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册