Created
May 12, 2023 14:05
-
-
Save atwalsh/e6b834f178777e29f884292cd877d7de to your computer and use it in GitHub Desktop.
Stripe Connect account update business icon
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import stripe | |
stripe.api_key = '' | |
file_path = '' | |
connected_account_id = '' | |
with open(file_path, "rb") as fp: | |
# Upload file to the platform account | |
file = stripe.File.create( | |
purpose="business_icon", | |
file=fp | |
) | |
# Set file as account icon on the connect account | |
stripe.Account.modify( | |
connected_account_id, | |
settings={"branding": {"icon": file['id']}}, | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment