response schema / documentation?

You are here

4 posts / 0 new
Last post
AndrewKoransky
response schema / documentation?
Where might I find response documentation and/or a schema for post_charges?  PS please change your website to point to the API Sandbox instead of GitHub for documentation. This would have saved me a bit of aggravation. I found much of what I needed not just in the API Sandbox's documentation, but in the easy-to-miss Schema tab there... (example would be eCommerce.recurringSchedule.frequency where documentation does not list possible values but the Schema does).  
thomash
Re: response schema / documentation?

Thank you for your post, we love to receive this type of feedback. It helps us refine our documentation and processes and make them more accessable to our integrators. We are working on updates to our developer portal and we are looking to better label the various sections and links. Regarding your question about response schema. We have a few basic response schemas for Direct API post_charges requests.

1. Aproved Response:

stdClass Object
(
    [status] => Approved
    [reference] => ECEH7MyFz0
    [message] => APPROVED 000001
    [code] => 000001
    [cvvResult] => M
    [avsResult] =>  
    [riskCode] => 00
    [networkId] => 10
    [isPurchaseCard] => 
    [orderNumber] => Invoice 25
    [transactionId] => SDK TransId 1
    [timestamp] => 2017-12-14T07:22:59.9061469-05:00
)

2. Approved with Vault Token:

stdClass Object
(
    [status] => Approved
    [reference] => FCEH7S3jH0
    [message] => APPROVED 000001
    [code] => 000001
    [cvvResult] => M
    [avsResult] =>  
    [riskCode] => 00
    [networkId] => 10
    [isPurchaseCard] => 
    [vaultResponse] => stdClass Object
        (
            [status] => 1
            [message] => Success
            [data] => 3e3e0b131bd8404e9636d3076f191814
        )

    [orderNumber] => Invoice 527
    [transactionId] => SDK TransId 1
    [timestamp] => 2017-12-14T07:28:03.0961616-05:00
)

3. Declined Response:

stdClass Object
(
    [status] => Declined
    [reference] => CCEH7Txnt0
    [message] => DECLINED
    [code] => 000005
    [cvvResult] => U
    [avsResult] =>  
    [riskCode] => 00
    [networkId] => 10
    [isPurchaseCard] => 
    [orderNumber] => Invoice 866
    [transactionId] => SDK TransId 1
    [timestamp] => 2017-12-14T07:29:58.5147623-05:00
)

4. Error:

stdClass Object
(
    [code] => 400000
    [message] => There was a problem with the request. Please see 'detail' for more.
    [info] => https://developer.sagepayments.com/docs/errors#400000
    [detail] => InvalidRequestData : request: You must supply one and only one of the following entities: Retail or ECommerce
)

Please let us know if you need any further details. You are welcome to reply to this post or reach out to us directly at [email protected].

thomash
Re: New Columns

BobStein,

Thank you for your post, we're happy to help. These field came as a bit of a surprise to us as well. As you can see they are being sent, but not currently being used. Once the formatting of the values has been finalized we will post additional documentation here on the developer portal giving information on how these fields may be used. I will also make a note to come here to update this post with those details. Our apologies if the additional fields caused any issue with transaction processing.

Thomas H

SDKSupport

thomash
Re: Ghostly Postings

I'm not sure why you are not seeing your comments and why you don't receive notifications of updates to the thread. However, if you'll send us a note directly I will make sure to update you as soon as I have details on the new fields. You can reach us at [email protected].

Thomas H

SDKSupport

Log in or register to post comments