Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stripe.Account.retrieve does not allow for account id #822

Closed
1 task done
d3mcfadden opened this issue Dec 11, 2023 · 4 comments
Closed
1 task done

Stripe.Account.retrieve does not allow for account id #822

d3mcfadden opened this issue Dec 11, 2023 · 4 comments

Comments

@d3mcfadden
Copy link

Package Version

3.1.1

Are you using the latest version?

  • Yes, I verified the issue is still present in the latest version.

Steps to Reproduce

Our app makes use of Stripe.Account.retrieve("acct_abc123") to fetch a connect account under our main account. Prior to the 3.x release this call worked and would return the details of a connected account based on the passed id.

It looks like since 3.x the code is being auto-generated based off the OpenAPI spec and this function no longer works. The function signature now accepts a map of params, not a binary account id.

Happy to fix this with some guidance on the code generation. Thanks for taking a look!

Expected Result

What is expected is to be able to get an account by a id.

Stripe.Account.retrieve("acct_abc123")

{:ok,
 %Stripe.Account{
   business_profile: nil,
   business_type: nil,
   capabilities: %{
     acss_debit_payments: "active",
     affirm_payments: "active",
 ...
}}

Actual Result

Stripe.Account.retrieve("account_foo")
** (BadMapError) expected a map, got: "account_foo"
@yordis
Copy link
Member

yordis commented Dec 11, 2023

I believe this is related to #786 I can support you if you continue the work here!

@d3mcfadden
Copy link
Author

Thanks for the response @yordis. This definitely looks related. Sorry for the dip, I checked the open issue list and didn't see anything.

@yordis
Copy link
Member

yordis commented Dec 12, 2023

Good catch! Let me update the template!

@yordis
Copy link
Member

yordis commented Dec 12, 2023

Gonna close it in favor of #786 Reopen it if you feel I made a mistake! I encourage you to take the PR to the finish line. Let me know if I can help you with it!

@yordis yordis closed this as completed Dec 22, 2023
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

No branches or pull requests

2 participants