How to use encrypted text in web service requests

I have a password that I need to pass in the body of a REST POST in order to obtain a bearer token.

I have encrypted the password and stored as a global variable. I know how to use these encrypted strings when testing a WEB UI (WebUI.setEncryptedText).

How can I use this with a Web Service? I really don’t want to store the password in plain text.



This is a security concern and seems like a major need / gap.