mispex v0.1.4 MISP.HTTP View Source

Standard functions to deal with posting and recieving JSON

Link to this section Summary

Functions

An HTTP DELETE Request

An HTTP GET Request

An HTTP POST Request

Link to this section Functions

An HTTP DELETE Request

iex> MISP.HTTP.delete("/events/16")
%{"message" => "Event deleted."}
Link to this function

get(path, decode_as \\ nil) View Source

An HTTP GET Request

iex> MISP.HTTP.get("/events/16", MISP.Event.decoder())
%MISP.Event{}
Link to this function

post(path, body, decode_as \\ nil) View Source

An HTTP POST Request

iex> MISP.HTTP.post("/events/add", %MISP.Event{}, MISP.Event.decoder())
%MISP.Event{}