-
Notifications
You must be signed in to change notification settings - Fork 185
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
Existing encoding of url query parameters is being rewritten #559
Comments
@xavdid, as you've added the existing flag, maybe you know a workaround we could make use of? |
Quick update: we figured that we can just use |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Description
#497 added support to skip the encoding of certain characters via the
skipEncodingChars
option.This at first glance looked promising to use, as we were running into an issue where we had to ensure an
=
is not being encoded. It only solved half of our issues though.It turns out that the API that we're talking to (Cloudinary) is even pickier about the encoding of the parameters, as it only accepts lower-cased encodings, e.g. %2f instead of %2F.
But when we provide a url with query parameters like this
?__cld_token__=exp=1657025954~acl=%2f*%2fauthenticated%2fa2fd268b-ac62-4473-b906-8d28dd163e9a%2f*~hmac=XXXXXXXX
,z.request
changes all occurrences of%2f
to%2F
which causes the request to fail.I personally feel like a cleaner solution to having a list of characters to exclude from encoding, is simply to add a flag that will allow keeping query parameters already provided on the URL untouched.
Reproduction Steps
Make a request like this:
You'll see that the query string is being changed to
___token___=path=%2Ftest%2F
.Version Info
zapier-platform-core
dependency: 12.0.3Operating System: OSX
App id: 127170
The text was updated successfully, but these errors were encountered: