HONK(3) | Library Functions Manual | HONK(3) |
honk
— API
access
In addition to the standard web interface, some functionality is
available via the honk
HTTP API.
With the exception of login, all requests should contain the following form values.
The API URL for all actions other than login and logout is /api.
Send a POST request to /dologin with the following form values.
This will return a token to be used for future requests. The token is valid for one year.
Send a request to /logout with the token to be expired.
The action value should be “honk”. Content type should be multipart/form-data if an attachment is included. The following values are recognized:
Upon success, the honk action will return the URL for the created honk.
Upload just an attachment using donk and donkdesc. Content type must be multipart/form-data. Will return the XID.
The “gethonks” action can be used to query for honks. The following parameters are used.
The result will be returned as json.
The “zonkit” action began life as a delete function, but has since evolved some other powers as specified by the wherefore parameter. The target of the action is specified by the what parameter and is generally the XID of a honk.
Wherefore must be one of the following.
Returns a list of current honkers in json format.
Save a new honker, or update an existing one. The following fields are used.
The honker numeric ID will be returned for success. To delete, unsub, or sub, include a form value with name and value equal. As in, a form value named delete with the value delete, or unsub=unsub, etc.
Send anything. No limits, no error checking.
Refer to the sample code in the toys directory.
June 6, 2025 | macOS 13.7 |