HTTP_PUT
Sends a PUT request: stores something on the server, replacing what was there.
The data is sent as UTF-8. Set its type in the Content-Type header of the connection.
Parameters and results
connectionSTRUCT c0de_net/http/HTTP_CONNECTION: the serverendpointSTRING: the path behind the base endpoint (optional, default empty)dataSTRING: the data sent with the request (optional, default empty)- result
resultSTRING: the raw data of the answer - result
statusINTEGER: the HTTP status - result
headersHASH STRING: the headers of the answer
Example
c0de
CALL c0de_net/http/HTTP_PUT
PARAMETER connection api ;
PARAMETER endpoint "/lamps/kitchen" ;
PARAMETER data state ;
RESULT status status