Android应用程序:Paypal API:getVerifiedStatus

时间:2014-06-03 05:48:13

标签: android paypal paypal-sandbox

我想为PayPal构建Android移动应用程序。 我必须获取我需要使用以下API的帐户状态:

getVerifiedStatus

但我无法为其创建请求。我想要发布请求的结构(任何格式都可以)。

链接: https://devtools-paypal.com/apiexplorer/AdaptiveAccount :: GetVerifiedStatus

1 个答案:

答案 0 :(得分:0)

以下是我刚刚提交的工作申请的样本。

请求标题

Array
(
    [0] => X-PAYPAL-SECURITY-USERID: ***
    [1] => X-PAYPAL-SECURITY-PASSWORD: ***
    [2] => X-PAYPAL-SECURITY-SIGNATURE: ***
    [3] => X-PAYPAL-SECURITY-SUBJECT: 
    [4] => X-PAYPAL-SECURITY-VERSION: 112.0
    [5] => X-PAYPAL-REQUEST-DATA-FORMAT: XML
    [6] => X-PAYPAL-RESPONSE-DATA-FORMAT: XML
    [7] => X-PAYPAL-APPLICATION-ID: APP-80W284485P519543T
    [8] => X-PAYPAL-DEVICE-ID: 
    [9] => X-PAYPAL-DEVICE-IPADDRESS: 192.168.1.1
    [10] => X-PAYPAL-SANDBOX-EMAIL-ADDRESS: email@angelleye.com
)

XML请求

<?xml version="1.0" encoding="utf-8"?>
<GetVerifiedStatusRequest xmlns="http://svcs.paypal.com/types/ap">
  <requestEnvelope xmlns="">
    <detailLevel>ReturnAll</detailLevel>
    <errorLanguage>en_US</errorLanguage>
  </requestEnvelope>
  <emailAddress xmlns="">sandbo_1204199080_biz@angelleye.com</emailAddress>
  <matchCriteria xmlns="">NAME</matchCriteria>
  <firstName xmlns="">Drew</firstName>
  <lastName xmlns="">Angell</lastName>
</GetVerifiedStatusRequest>

XML响应

<?xml version='1.0' encoding='UTF-8'?>
<ns2:GetVerifiedStatusResponse xmlns:ns2="http://svcs.paypal.com/types/aa">
  <responseEnvelope>
    <timestamp>2014-06-02T23:30:06.532-07:00</timestamp>
    <ack>Success</ack>
    <correlationId>b5922b69bcfc3</correlationId>
    <build>11017889</build>
  </responseEnvelope>
  <accountStatus>VERIFIED</accountStatus>
  <userInfo>
    <emailAddress>sandbo_1204199080_biz@angelleye.com</emailAddress>
    <accountType>BUSINESS</accountType>
    <accountId>E7BTGVXBFSUAU</accountId>
    <name>
      <salutation></salutation>
      <firstName>Drew</firstName>
      <middleName></middleName>
      <lastName>Angell</lastName>
      <suffix></suffix>
    </name>
    <businessName>Drew Angell's Test Store</businessName>
  </userInfo>
</ns2:GetVerifiedStatusResponse>