Being notified by Saferpay about the "deadline for the introduction of the Second EU Payment Services Directive (PSD 2)" on 14 September 2019, I'm wondering what the options are for continuing to provide Saferpay payments on a Drupal Commerce shop with this module.
Saferpay refer to a Drupal Commerce integration by sellxed / customweb for CHF 200 (!) and provide a configuration manual for switching to their new JSON API, which seems to be the only way to support the required 3-D Secure 2.0 standard for compliance with the new regulations for the EU and Switzerland.
Is this module the same as they "sell"? If not, can this module be used with their new JSON API to support 3-D Secure 2.0?
Thanks for your feedback!
| Comment | File | Size | Author |
|---|---|---|---|
| #12 | 3062680-12-json-api-support-interdiff.txt | 10.28 KB | berdir |
| #12 | 3062680-12-json-api-support.patch | 24.37 KB | berdir |
| #11 | 3062680-11-json-api-support-interdiff.txt | 7.68 KB | berdir |
| #11 | 3062680-11-json-api-support.patch | 25.03 KB | berdir |
| #10 | 3062680-10-json-api-support-interdiff.txt | 17.72 KB | berdir |
Comments
Comment #2
primsi commentedNo, this is not the same module. But we are just about to start implementing the new api and the plan is to make it in time before 14 September. One thing that needs to be pointed out though is that the new module version will only support payment page (and not business).
Comment #3
primsi commentedComment #4
primsi commentedThe authentication and other configurations required for the json api are not compatible with the existing one (json api basic auth for example). This means that if I understand that correctly we cannot have a drop-in replacement.
So the plan is:
Comment #5
primsi commentedFirst iteration. I added a new module, although there already are 3. We discussed with @Berdir how to approach this and he suggested it might make sense to have this in the main module. In light of EOL of the old api, we might delete the submodules anyway.
Comment #6
primsi commentedMoved to main module.
Comment #7
berdirusin => using, although we have two using's then, maybe "through the JSON API"?
We should also prepare a snippet that we can put into the release notes that explains that the old modules are now basically deprecated and no longer supported. And that everyone should update to the new integration, with short instructions on how to do that.
we need support for this, we have projects that specifcally rely on it. We added that feature for those :)
looks like we have a debug option and are logging, just nothing useful yet? :) also wrong type.
and, don't we need to assert that this is valid here? otherwise you could just visit the redirect page directly and we'd think it has been paid?
does that means we only process the payment async? This might be a problem with one of our sites that we'll need to test and deal with.
maybe an existing pattern, but this is problematic as watchdog() expects a string that is passed to t() and shouldn't have dynamic values.
you can set arguments to NULL to disable translation, but I think we could easily use placeholders here? We could likely even drop the imploding then and use short placeholders on a single line?
https://www.grammarly.com/blog/paid-payed/, I'm pretty sure we're not doing anything with ships here :)
not a fan of this pattern. this add a function call to load that file dynamically during an early bootstrap phase.
I'd rather add some of the methods that we call ourself to a class with static methods or just put it all in the .module file.. I don't really care about another 300 loc in there. And if we ever do a 7.x-2.x branch without the old methods then it will be easier to clean up, would be weird to have basically nothing but the include then.
Comment #8
primsi commentedThanks for the review.
1. Removed anyway.
2. Added support for that
3. As discussed, AFAIK we don't get anything from Saferpay at that point
4. Yes
5. Fixed that
6. Fixed that :)
7. Moved to the main file.
Comment #9
primsi commentedWill be afk for a while, unassigning :)
Comment #10
berdirLots of small improvements, in no specific order:
* Improvements on the settings form, keeping related settings together, using customer id and not account id
* Improved default settings
* Notify callback improvements, year is now 4-digit, so we no longer need the 20 prefix, also card types are completely different now, so new mapping is needed. Also the same callback url was defined commerce_saferpay_pp, so that overlapped and the other one won, resulting in a lot of confusion.
* Error handling improved to have more useful errors
interdiff is large because a lot of code was slightly touched.
Comment #11
berdirThis fixes the alias stuff, wasn't actually setting the correct keys before to request it and saving the wrong data. Also passes through the language like before and some other fixes.
Comment #12
berdirWas fighting with race conditions that resulted in losing the information in $order->data, so I changed the API to return arrays which are easier to store in $transaction->payload and instead storing the cardonfile ID in there.
Comment #14
berdirCommitted.