Skip to content

Update get_customer_verify_beneficial_ownership_from_body/1 to match resp#5

Open
jmillxyz wants to merge 1 commit intoaxlepayments:mainfrom
viabeacon:m-2139-fix-ex_dwolla-verify-beneficial-ownership-bug-on-customers
Open

Update get_customer_verify_beneficial_ownership_from_body/1 to match resp#5
jmillxyz wants to merge 1 commit intoaxlepayments:mainfrom
viabeacon:m-2139-fix-ex_dwolla-verify-beneficial-ownership-bug-on-customers

Conversation

@jmillxyz
Copy link
Copy Markdown

@jmillxyz jmillxyz commented Aug 1, 2024

The Dwolla endpoint at /customers/{id} returns a few _links; one of those is used to populate the Dwolla.Customer struct field verify_beneficial_ownership.

The response I see when hitting this endpoint is (irrelevant portions omitted):

{
	"_links": {
		"verify-beneficial-owners": {
			"href": "https://api-sandbox.dwolla.com/customers/135ceaf3-7774-4f56-a602-ca0f8ea65af9/beneficial-owners",
			"type": "application/vnd.dwolla.v1.hal+json",
			"resource-type": "beneficial-owner"
		},
		"certify-beneficial-ownership": {
			"href": "https://api-sandbox.dwolla.com/customers/135ceaf3-7774-4f56-a602-ca0f8ea65af9/beneficial-ownership",
			"type": "application/vnd.dwolla.v1.hal+json",
			"resource-type": "beneficial-ownership"
		},
                ...
	},
        ...
}

I updated the first get_customer_verify_beneficial_ownership_from_body/1 function clause to account for this.

Please let me know if I can help with tests, or whether you can update the test factory to properly account for this scenario -- it looks like it uses real data from a sandbox account?

Thanks!

Copy link
Copy Markdown

@axelclark axelclark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies for the approval, I got confused and thought this PR was in our repo...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants