httpapi documentation
Posted: Thu Dec 16, 2021 1:45 am
pls let me know if there is any docs for httpapi ?
for eg, doc which describes parameters to pass to http_xproc?
I am struggling to understand below code. the http_strig is taking only the form_data as input..so how exactly is the form header used? Apologies my web knowledge is very limited.
for eg, doc which describes parameters to pass to http_xproc?
I am struggling to understand below code. the http_strig is taking only the form_data as input..so how exactly is the form header used? Apologies my web knowledge is very limited.
Code: Select all
form_header = 'Authorization: Basic ' + %trim(WSBASE64) + CRLF;
http_xproc( HTTP_POINT_ADDL_HEADER : %paddr(setHeader));
url = WSAUTURL;
//-------------------------------------------------------------
// Step 1 - Get ID Token
//-------------------------------------------------------------
form_data = 'grant_type=client_credentials'
//+ '&' + 'client_id=' + %Trim(WSCSKEY)
//+ '&' + 'client_secret=' + %Trim(WSCSSEC)
+ '&' + 'scope=openid';
enJL = %len(%trim(form_data));
clear retdata;
Monitor;
retdata = http_string('POST': url : %trim(form_data) :
'application/x-www-form-urlencoded');