1. Waine Abreu
  2. PowerBuilder
  3. Tuesday, 9 May 2023 13:07 PM UTC

Hi everyone,

 

I have some webservices using SOAP and I'm migrating to PB22 which i need to use REST.

which function in REST that is similar to "objectname.setbasicauthentication" use in soap?

 

Thanks in Advance 

Accepted Answer
Andreas Mykonios Accepted Answer Pending Moderation
  1. Tuesday, 9 May 2023 14:31 PM UTC
  2. PowerBuilder
  3. # Permalink

It should be something like:

lnv_restclient.SetRequestHeader("Authorization", "Basic " + ls_auth)

Where ls_auth should contain "username:password" and should be encoded using base64 before issuing SetRequestHeader...

Andreas.

Comment
There are no comments made yet.


There are replies in this question but you are not allowed to view the replies from this question.