How to get HTTPAPI Help

Discussions related to HTTPAPI (An HTTP Client Package for RPG programming.) http://www.scottklement.com/httpapi/
Locked
Scott Klement
Site Admin
Posts: 799
Joined: Sun Jul 04, 2021 5:12 am

How to get HTTPAPI Help

Post by Scott Klement »

Welcome to the HTTPAPI forum!

This forum is for community discussions of HTTPAPI, and is the best place to get help with HTTPAPI-related issues.


To get help with HTTPAPI, please consider the following:
  1. Every Web Service / API is different. Please provide information about what the API expects.
  2. Please provide a snippet of the code you are using to call HTTPAPI. Everyone does things differently, so it is hard for us to know what you've done if you don't provide your code.
  3. Please mention the version of HTTPAPI you are using. If you're not sure, look inside the HTTPAPI_H copy book, and search for the HTTPAPI_VERSION constant.
  4. Please consider creating a debug/trace file (see below). This provides details of what happened under the covers when you ran HTTPAPI.

How to create a debug/trace file:

A debug/trace file is an IFS file that logs exactly what happened during an HTTPAPI communications session. To create one, you will need to add a line of code to your RPG program. It is recommended that this line be placed before any other HTTPAPI-related code to ensure that everything is included in the log:

Code: Select all

http_debug(*on: '/tmp/my_httpapi_log.txt');
  • First parameter to http_debug is *ON, indicating that you wish to enable logging. (You can also pass *OFF to turn logging off.)
  • The second parameter is an IFS path to where you want to write the log file.

How to post source code:

Source code, including RPG, can be very difficult to read if not formatted as 'code' in the forum software. To post code, please:
  1. Open your source member/file in RDi
  2. Select all of the desired code
  3. Paste it into a forum message
  4. Highlight the code with the mouse, and click the </> button in the editor
The </> button will put [code] before the start of your RPG code and [/code] after it. Anything enclosed in these tags will be posted in a code block which retains all special characters and makes it much easier to read your code.


Older Archives

Before these forums were created, there was a mailing list called FTPAPI that was used for both the HTTPAPI and FTPAPI open source projects. In case it is useful, I have kept an archived copy of the mailing list posts.


Good Luck!
Locked