Invalid funding source error in Sandbox when transferring between Customers

Hi,

I get an “Invalid funding source” error when attempting a transfer from an unverified Customer to a verified large business Customer. Both users are connected to Dwolla via Plaid. What could be the causes of this error?

Here is my setup:

  • I happen to store the funding sources of every user locally (in this case, I didn’t query Dwolla again to retrieve the funding source)
  • the funding source of each user was added from a plaidToken
  • unverified user A is attempting to send a transfer to verified business customer Big League Potato, Inc.
  • neither user has funds in their total balance (even with bank accounts connected via Plaid)

My request object looks like this:

let requestInfo = {
	_links: {
		source: {
			href: "https://api-sandbox.dwolla.com/funding-sources/f2738b36-9628-46d8-b3f1-fa376f0da05f"
		},
		destination: {
			href: "https://api-sandbox.dwolla.com/funding-sources/f32a09b9-b97b-49e2-9810-c175288012aa"
		},
	},
	amount: {
		currency: "USD",
		value: "10.00"
	}
}

Below is my error message:
sending from: https://api-sandbox.dwolla.com/funding-sources/f2738b36-9628-46d8-b3f1-fa376f0da05f
to: https://api-sandbox.dwolla.com/funding-sources/f32a09b9-b97b-49e2-9810-c175288012aa
we have an error:
Error: {
“code”: “ValidationError”,
“message”: “Validation error(s) present. See embedded errors list for more details.”,
“_embedded”: {
“errors”: [{
“code”: “Invalid”,
“message”: “Invalid funding source.”,
“path”: “/_links/source/href”,
“_links”:{}
}]
}
}
at errorFrom (/mnt/c/Users/potato/git-clones/Payee/Payee-v1/passport-test/node_modules/dwolla-v2/src/dwolla/Token.js:49:15)

Hi @ngwattcos, thanks for posting the full request/response body: it helps pinpoint the error/issue.

I looked up the funding-sources and it looks like the source funding source with the ID f32a09b9-b97b-49e2-9810-c175288012aa has been removed. That’s causing the transfer request to fail.

Since you have the funding-source IDs saved locally, you could perhaps query on the funding-source to see if the response body contains

“removed”: “false”

before making the transfer to avoid validation errors with the funding-source. Let me know if you have any questions!

1 Like

Thank you!