Here's an example calling a language translation service.
VALUES
HTTP_POST('https://translate.argosopentech.com/translate',
'q=Can%20I%20see%20the%20wine%list%3F&source=en&target=es&api_key=xxxxxxxx',
'{"header":"accept, application/json",
"header":"Content-Type, application/x-www-form-urlencoded",
"sslTolerate":"true"} ')
------------------------------
Kent Milligan
------------------------------
Original Message:
Sent: Tue November 22, 2022 11:20 PM
From: Amy Vozza
Subject: QSYS2.HTTP_POST Example with Content-Type application/x-www-form-urlencoded
Can someone provide, or point me to, an example of using QSYS2.HTTP_POST where the Content-Type is application/x-www-form-urlencoded? I'm not sure how to send the data in the body of the request other than when it is application/json.
------------------------------
Amy Vozza
------------------------------
#SQL