implement EphemeralKey.create_async
Is your feature request related to a problem? Please describe.
EphemeralKey only provides delete async methods, and no create
Describe the solution you'd like
A create async method consistent with other objects
Describe alternatives you've considered
No response
Additional context
No response
the sync create is also missing the return type hint
Hi! Thanks for bringing this up. We'll look into why this isn't being generated. In the meantime, we do have an async create for StripeClient, which could satisfy your needs:
from stripe import StripeClient
client = StripeClient("sk_test_...")
client.ephemeral_keys.create_async({ <YOUR_CREATE_PARAMS> })
Hi there! I've submitted a pull request (#1676) that implements the create_async method for EphemeralKey.
The implementation follows the same pattern as other async methods in the codebase (like delete_async) and includes comprehensive test coverage. I've also added return type annotations to both create() and create_async() methods to address the type hint concern mentioned in the comments.
The PR is ready for review whenever the maintainers have time. Happy to make any adjustments if needed.
Re-opening until we ship an update with the fix next month