I am using a ServiceCallout policy to send a SOAP request to an identity service. Is there a way I can mask only particular elements in the SOAP request (Ex: username, password) instead of masking the entire ServiceCallout.request content?
Yes, You can mask part of request / response using XPath. For more details please find here.
Hi @bibin_kurian the link can be a little confusing as it talks about Data Masking in general & how it works when trace sessions are turned on. Looks like you are looking to mask some data elements when making service callouts to external services.
I think there are 2 options to achieve this:
I know I am a little late to this question (only about 10 months or so :P)
Afaik, there is no way to use Data masking to mask the contents of a Service Callout. Data Masking can be used for variables and specific paths in the XML/JSON requests and responses. Nothing in-between is maskable.
You can use an AssignMessage to create the ServiceCallout request and then mask the that variable.