solidusio / solidus_affirm Goto Github PK
View Code? Open in Web Editor NEWAffirm payment option for your Solidus storefront
License: BSD 3-Clause "New" or "Revised" License
Affirm payment option for your Solidus storefront
License: BSD 3-Clause "New" or "Revised" License
Update README with static preferences, also see https://github.com/solidusio/solidus_stripe#usage
est: 0.5h
this might be a Solidus core related issue / feature, but with the fix of #32 I also think this is solved as well.
todo: verifying this while developing the updated checkout flow for Affirm
DEPRECATION WARNING: SolidusSupport::EngineExtensions::Decorators is deprecated! Use SolidusSupport::EngineExtensions instead. (called from <class:Engine> at /Users/peterberkenbosch/code/peterberkenbosch/solidus_affirm/lib/solidus_affirm/engine.rb:7)
We use VCR and store the responses in casettes, we should remove these regularly to make sure we are still testing against the "real world".
est: 1h to 3h
We had a customer reach out about an order he had placed that he had not received any follow-up information on. Normally this is because the customer completed the Affirm portion of the checkout but not the confirmation page when redirected back to the site, but this will result in an incomplete order if you search including incomplete orders in a search in the order admin. Which this is a separate issue with the affirm implementation
This one is strange because there is no order in our backend that we can find. Checked using his name, the order ID assigned in Affirm and his email address. Also checked using the SKU of one of the line items listed in Affirm. Did find an incomplete order for the email address, but the line items that were in the cart did not match, and there were no payment attempts in that order.
Have examples of this on our store with customer info and records but cannot publicly list this.
In the confirm state the user uses the back button the select the affirm payment and moves next. This is breaking the AASM.
This one is related to #32 as well, when the Affirm Payment completion is part of the confirm / completion of the order this will also be not a problem with the state machine.
Affirm is rolling out a beta product which offers secondary finance options if a customer fails affirm approval. The backup funding source would be Zibby which is another popular financing option.
Documentation
https://docs.affirm.com/Integrate_Affirm/Affirm_Connect_API
https://docs.affirm.com/Connect
The used affirm-ruby gem has not been touched in 4 years, and has old dependencies that are blocking usage upstream.
Took a second to figure that out, since the current gem we use is named affirm-ruby
where the repository is at https://github.com/spectator/affirm
and the suggested new gem is named affirm
but the repository is at https://github.com/reverbdotcom/affirm-ruby
The clients are not compatible, so we need some additional refactoring.
Planning on doing some work around that, but leaving this issue here to have visibility around it.
Steps to recreate:
Customer adds item(s) to cart and selects affirm in checkout
Customer gets approved but exits the site before completing an order or exits checkout
Customer comes back to checkout and must get preapproved again even if cart total or items did not change
Issue:
Multiple authorizations will exists on customers affirm account as well as under payment history of the Order ID which can be captured/voided. When processing the order you must manually void all prior authorizations and capture the affirm authorization that is the most recent. For customers who actually did purchase this leads to confusion that they have either multiple orders for the same item or multiple loans for the same order since their personal affirm will show all loans/preapprovals until the retailer captures/voids. See below example
This also makes other customers who abandon before clicking to submit order be confused as they think they did order since their affirm account shows outstanding loan but they have no records of solidus store order (transactional email etc) since as far as Solidus goes they never completed the order. Example below of order/payment state in this scenario
Proposed Solution
When an order is being processed any other payment method that has an open authorization should be voided when a new payment method is applied and able to be captured
Potentially void authorizations of affirm orders after a certain time period to handle customers just verifying if they can get approved? Currently we do it after a number of days have passed. We manually go into our affirm merchant dashboard to find these authorizations that are tied to abandoned orders
Affirm rolled out a notice today about marketing messaging onsite. Below is the email and attaching their attachment
I am working on an Affirm payment method integration. Sending checkut object to Affirm, but getting an error message:
{
"status_code": 400,
"type": "invalid_request",
"message": "Invalid Request: Must be valid Amount"
}
Given below is the checkout object I am sending with public API key as well:
{
"merchant": {
"user_confirmation_url": "http://localhost/Able9B6750Test3/Affirm/Confirm",
"user_cancel_url": "http://localhost/Able9B6750Test3/Checkout/Payment",
"public_api_key": "ABCDEFGHI",
"user_confirmation_url_action": "GET",
"name": "W2M.Affirm"
},
"shipping": {
"name": {
"first": "Market",
"last": "aa"
},
"address": {
"line1": "5628 W 120TH ST",
"line2": "",
"city": "ALSIP",
"state": "IL",
"zipcode": "60803-3410",
"country": "United States"
},
"phone_number": "1-888-128-3772",
"email": "[email protected]"
},
"billing": {
"name": {
"first": "Web2Market",
"last": "Web2Market"
},
"address": {
"line1": "5628 W 120TH ST",
"line2": "",
"city": "ALSIP",
"state": "IL",
"zipcode": "60803-2210",
"country": "United States"
},
"phone_number": "1-888-968-3772",
"email": "[email protected]"
},
"items": [
{
"display_name": "Prima Chain Lock (66", Heavy Duty); Universal",
"sku": "0300-0103 ",
"unit_price": 101,
"qty": 1,
"item_image_url": "http://localhost/Able9B6750Test3/Assets/ProductImages/0300-0103.jpg",
"item_url": "http://localhost/Able9B6750Test3/Abandoned-Products/Prima-Chain-Lock-66-Heavy-Duty-Universal",
"categories": [
[
"Springs"
]
]
}
],
"discounts": null,
"metadata": {
"shipping_type": "Free Shipping",
"mode": "redirect"
},
"order_id": "6260588",
"currency": "USD",
"financing_program": "",
"shipping_amount": 0,
"tax_amount": 10,
"total": 111
}
Also, checkout oubject is being build while I am on payment page and it has orderID and OrderNumber required. But, Order is not yet generated on my ecommerce website. What should I do ?
Add this extension and visit rails/mailers
A list of available previews should be shown
It raises the error:
No route matches {:action=>"preview", :controller=>"rails/mailers", :path=>"spree/mailer_previews/carton"}
v1.4...v2.4
I'm not sure if this is more related to the extension or if it's more of an issue with Affirm but we had a customer reach out that they were receiving errors when clicking the Affirm payment option.
I recreated the user's cart exactly as he had it, and did in fact get an error that states "We encountered a problem with your checkout. The provided checkout total is invalid. Please contact the merchant to complete your purchase."
After trying a couple of things with the cart contents with no luck, I noticed that the user had an apostrophe at the end of their first name. Once I removed that, I was able to proceed to the Affirm portal.
We've had a number of incomplete orders with completed Affirm loan authorizations. In many instances, our customers are stating that they were not redirected back to the site correctly (we've had some complaints that they were redirected to the homepage, others saying that they were directed to an account sign up page). Because the Affirm portion takes you offsite, I'm unable to capture the behavior. I'm curious if anyone else has had this issue come up and if so, do you have any insight?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.