MassPay - BadRequest


#1

Hello,

I am attempting to initiate a masspay request in the sandbox. I already have the funding-source token. I just keep getting the following exception when intiating Post.

This is the server call and obj being passed into call

JSON format (these are hard coded at the moment in an attempt to get successful transfer)

Thanks


(Spencer Hunter) #2

@Bohica1, hmm based on the screenshot you showed of your request body it looks okay. Are you able to log out the request body before making the request on your server to the Dwolla API? As an aside, are you using dwolla-v2-node?


(Valentyn Ostakh) #3

I have the similar issue.
I am using ruby client and working with sandbox.
I want to do mass payment and I am using account id and customer id for items.
For example I can get info about customer
client.get 'https://api-sandbox.dwolla.com/customers/80ab732d-f4aa-476b-95ec-a334edce3f68'
But with mass payment request I receive The request body contains bad syntax or is incomplete.


#4

@Valentyn_Ostakh, my issue was with the formatting of the object when passing it from client to server. I was getting the same error msg. I was trying to format the obj differently than what Dwolla api was expecting. Once I fixed the object formatting, basically take the sample code provided put it on your server and debug when executing and make sure yours is formatting the same when it hits your server and is getting sent off.

At least that was my issue and fix.


(Valentyn Ostakh) #5

Found my mistake.
I have used account href for source in body. There should be funding-resource instead.
But destination can be as link to customer, or account or funding-resource.