Closed avaussant closed 5 years ago
How we can manage the authentication with gosoap, can you give me a solution with your module.
Please
Many thanks
You can do it with
soap.Username = "user" soap.Password = "pass"
@avaussant the newest version, Username and Password are properties of the Client struct.
Hello
Many thanks for your code, but i have an issue with my use case. It's possible to add credentials for SOAP endpoint with gosoap.
I have try with this option and the soap have an error like output:
func main() { soap, err := gosoap.SoapClient("https://enpoint_url") if err != nil { fmt.Errorf("error not expected: %s", err) } soap.HeaderParams = gosoap.Params{ "Authorization": "Basic" + basicAuth("user", "password"), }