# Converting Postman Prerequest Script to Julia Script

**URL:** https://discourse.julialang.org/t/converting-postman-prerequest-script-to-julia-script/69832
**Category:** Web Stack
**Tags:** web
**Created:** [October 15, 2021, 3:19pm UTC](https://discourse.julialang.org/t/converting-postman-prerequest-script-to-julia-script/69832 "2021-10-15T15:19:26Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![bww00](https://avatars.discourse-cdn.com/v4/letter/b/bc8723/32.png) [@bww00](https://discourse.julialang.org/u/bww00)
#### Post date: [October 19, 2021, 2:24pm UTC](https://discourse.julialang.org/t/converting-postman-prerequest-script-to-julia-script/69832/5 "2021-10-19T14:24:35Z")

</div>

Got it to work!!!

encoding issue was below that I found searching

For this you want to use Base64 from the standard library. First use hex2bytes to convert your string to a byte array, then base64encode to convert it back to a string:  
using Base64  
function base16to64(st::AbstractString)  
bytes = hex2bytes(st)  
return base64encode(bytes)  
end

---

_[View the full topic](https://discourse.julialang.org/t/converting-postman-prerequest-script-to-julia-script/69832)._
