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 PI: Update API version #5360

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

almalee24
Copy link
Contributor

Update API version to 2022-11-15

Remote
104 tests, 483 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed

@almalee24 almalee24 force-pushed the update_stripe_pi_version branch 3 times, most recently from 630c7af to e11d0f3 Compare December 5, 2024 20:55
Update API version to 2022-11-15

Remote
104 tests, 483 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
Copy link
Collaborator

@Buitragox Buitragox left a comment

Choose a reason for hiding this comment

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

I agree with most changes, but I have some questions.

@@ -65,7 +64,7 @@ def create_intent(money, payment_method, options = {})
end

def show_intent(intent_id, options)
commit(:get, "payment_intents/#{intent_id}", nil, options)
commit(:get, "payment_intents/#{intent_id}?expand[]=latest_charge.balance_transaction", nil, options)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I noticed that you added the expand parameter to the URL. Should this always be added? I understand that we need this in Spreedly, but should this be added in ActiveMerchant?

@@ -228,11 +221,11 @@ def void(intent_id, options = {})

def refund(money, intent_id, options = {})
if intent_id.include?('pi_')
intent = api_request(:get, "payment_intents/#{intent_id}", nil, options)
intent = api_request(:get, "payment_intents/#{intent_id}?expand[]=latest_charge.balance_transaction", nil, options)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same question here.

Comment on lines +330 to +333
if url.include?('payment_intents')
post[:expand].concat(['latest_charge', 'latest_charge.balance_transaction'])
elsif url.include?('setup_intents')
post[:expand] << 'latest_attempt'
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same question here.

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