Other APIs

Explanations of the Close, Slist_append, and Slist_free_all APIs for the wsCurl command.

In addition to the Setopt and Exec APIs previously introduced, there are three other APIs that are avail;able in wsCurl. These are as follows:

CLOSE

The close API closes the handle to fetch the request and also frees up all memory allocated to the operation. The syntax is as follows:

wsCurl.close();

There are no options or other parameters associated with the CLOSE API.

SLIST_APPEND

The slist_append API enables you to add email addresses to the list. You can specify if the appended mail is to be on the main recipient list or if it is to be a CC or a BCC. The syntax is as follows:

wsCurl.slist_append("<recipient_email@company.com>");
Note: Make sure to use the same email addresses as those you defined in the setopt READDATA email header.

There are no options or other parameters associated with the SLIST_APPEND API.

SLIST_FREE_ALL

The slist_free_all API frees all resources allocated to the creation of the eamil lists done through the slist_append API. The syntax is as follows:

wsCurl.slist_free_all();

There are no options or other parameters associated with the SLIST_APPEND API.