Created
July 30, 2021 04:02
-
-
Save ndunks/8b36b9866cee2be695fc8733b2538362 to your computer and use it in GitHub Desktop.
This file contains 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
// IF using cookie, make sure the domain was added in "Cookie" -> Whitelist Domain | |
// Walk cookie | |
const cookie = pm.cookies.jar(); | |
cookie.getAll(pm.request.url, (v1, cookies) => { | |
for (let v of cookies.map()) { | |
if (v.name.length > 32 && v.name.match(/[0-9a-f]/i)) { | |
pm.request.body.urlencoded.add({ | |
key: v.name, | |
value: v.value | |
}) | |
} | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment