Closed Bug 1048831 Opened 11 years ago Closed 9 years ago

[spartacus] Deal with the JWT on the initial SPA view instead of requiring it to be sent by the API.

Categories

(Marketplace Graveyard :: Payments/Refunds, defect, P4)

Avenir
x86
macOS
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: muffinresearch, Unassigned)

References

Details

Currently the JWT is sent in the request to /mozpay/?reg=[JWT] currently we then pull this from the url and re-send it via the API. This request takes some time and slows the initialisation. As we already have the JWT on the server we should process it directly there and provide details in the API request that checks the state. Once this is done we can remove from the SPA the api call that sends the JWT a second time.
See Also: → 1042688
Summary: Deal with the JWT on the initial SPA view instead of requiring it to be sent by the API. → [spartacus] Deal with the JWT on the initial SPA view instead of requiring it to be sent by the API.
Keep in mind that we still need to make an API call to begin a transaction from the client because it relies on mcc/mnc. However, pre-validating the JWT (when present) might help with bug 1042688
Also we'll need to weigh-up the error-handling aspects of this if we go this route.
Blocks: 909896
This maybe related to bug 1042688, in which case we'll need to increase its priority.
Flags: needinfo?(mstriemer)
Priority: -- → P4
This does not appear to be blocking bug 1042688. We're going to assume that if a user ends up at the SPA without a JWT then a transaction is being resumed. Once we are making the assumption that transactions are already started it might be easier to implement this.
Flags: needinfo?(mstriemer)
No longer blocks: 909896
Based on the recently announced future plans for the Marketplace to remove payments, closing these bugs.
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.