```hook: web_hook # To use webhooks, you must set ...
# talk-kratos
b
Copy code
hook: web_hook # To use webhooks, you must set 'hook' to 'web_hook'
config:
  url: <https://test.hook.site.sh/before_login_hook> # Webhook URL.
  method: POST # HTTP method used to send request to the webhook URL.
  body: <base64://ENCODED_JSONNET>
what does base 64 encoded jsonnet mean. I have jsonnet file, so shoule I provide a path to it or do I have to run some operation before doing it.
w
You must encode the Jsonnet to B64 and paste the string you get after the
base64://
“prefix”
You can use an online tool like this one to encode https://www.base64decode.org/
b
Thanks @wonderful-lamp-2357
g
In javascript: ``base64://${Buffer.from("function(ctx) ctx").toString("base64")}``
r
or in shell:
Copy code
base64 < config.jsonnet