Add Referer header to Zibal requests - #362
Merged
Merged
Conversation
According to Zibal's latest update, we need to add the `Referer` header to Zibal requests by September 11 (20 Shahrivar). https://zib.al/UWHS3PC
Member
|
could you please fix the failed pipelines? hint: this package is not a laravel package but a pure PHP package. Laravel / symfony or any functions are not available in this package. you can rely on the config object that is injected to the driver. |
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #362 +/- ##
=========================================
Coverage ? 79.61%
Complexity ? 1041
=========================================
Files ? 65
Lines ? 5499
Branches ? 0
=========================================
Hits ? 4378
Misses ? 1121
Partials ? 0 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Added configurable
Referersupport to Zibal payment requests.The
refereroption is now available in the Zibal driver configuration and defaults tonull. When configured, it is sent as theRefererheader in both purchase and verification requests; otherwise, the header is omitted.Motivation and context
Zibal requires a
Refererheader in payment requests by September 11 (20 Shahrivar). Making the value configurable lets applications provide their approved domain without coupling the driver to Laravel’sapp.urlconfiguration.Responsible team: Backend Team
How has this been tested?
Added unit tests covering both Zibal purchase and verification requests:
referervalue is sent as theRefererheader.refererremains at its defaultnullvalue.Screenshots (if appropriate)
Not applicable.
Types of changes
Checklist: