API v2 breaking change: Removing a funding source


(Spencer Hunter) #1

What’s changing?

Beginning on June 1, 2016, there will be a change in functionality when removing a funding source for an Account or Customer in API v2. The method for removing a funding source will change from a DELETE to a POST with the need to supply { "removed": true } in the body of the request. Additionally, a removed attribute is added to the funding source object and is returned from the API when retrieving a list of funding sources or GETting a funding source by id.

By default, all funding sources will be returned from the API when listing the funding sources for an Account or Customer. Removed funding sources can then be filtered out of the funding source listing by passing in a “removed” querystring parameter and setting the value to false(i.e. GET /customers/5b29279d-6359-4c87-a318-e09095532733/funding-sources?removed=false).

Example funding source listing response:

Why the change and what’s the benefit?

Current functionality is limited in that once you remove a funding source you can no longer fetch any details on this funding source because it no longer exists in the API. Changing to “soft delete” functionality will give you the ability to access any removed funding sources on an Account or Customer, which can be useful for referencing funding-sources that you’ve previously transacted with.


To ensure a seamless transition, we recommend testing and implementing these changes in our Sandbox (UAT) environment ahead of moving to production and prior the deprecation date of June 1, 2016.

If you have any questions please don’t hesitate to reach out. To stay up-to-date with the latest from the Dwolla API, review our changelog and subscribe to our mailing list.


(Samuel Reed) #2

Why not just change the behavior of the DELETE handler rather than push a breaking change?


(Max M) #3

Does this mean you can restore the funding source by POSTing with removed: false afterwards?


(Jared Dellitt) #4

@STRML We did change the behavior of the DELETE endpoint to do the soft delete, but we’re not returning those in the list just yet. We want to maintain the semantics of DELETE (actually removing it from the collection) and what that means for future endpoints. We really don’t like pushing breaking changes and try to avoid it as much as possible, but we felt this is one that warranted it. I’m sorry for the inconvenience.

@djmax Initially this won’t be supported, but that doesn’t mean we won’t add it in the future!

Thanks for the feedback, and let us know if you have any other questions or concerns!


(PJ Caraher) #5

@spencer I just ran a funding_source soft remove in production and it had no effect.

I ran the following python code:

    fundingSource = str(dwollaURL + '/funding-sources/' + fundingSourceId)
    request_body = { "removed": true }
    app_token = client.Auth.client()
    app_token.post(fundingSource, request_body)

I then fetched the funding_source and saw the following: ‘removed’: False

What is the proper way to soft delete a funding source via Python?


(Spencer Hunter) #6

Your request looks correct to me. Do you have the funding source id for the funding source you were attempting to remove?