[ { "endpoint": "GET /v1/messages/latest", "example_response": "
{ \"messages\" : [ { \"client\" : \"website\",\n \"content\" : \"hi\",\n \"content_type\" : \"text/x-markdown\",\n \"display_recipient\" : [ { \"email\" : \"wdaher@humbughq.com\",\n \"full_name\" : \"Waseem Daher\",\n \"short_name\" : \"wdaher\"\n },\n { \"email\" : \"othello@humbughq.com\",\n \"full_name\" : \"Othello, Moor of Venice\",\n \"short_name\" : \"othello\"\n }\n ],\n \"gravatar_hash\" : \"948fcdfa93dd8986106032f1bad7f2c8\",\n \"id\" : 400,\n \"recipient_id\" : 101,\n \"sender_email\" : \"othello@humbughq.com\",\n \"sender_full_name\" : \"Othello, Moor of Venice\",\n \"sender_short_name\" : \"othello\",\n \"subject\" : \"\",\n \"timestamp\" : 1365532669,\n \"type\" : \"private\"\n } ],\n \"msg\" : \"\",\n \"result\" : \"success\",\n \"update_types\" : [ \"new_messages\" ]\n}\n
client.get_messages()\n
curl -G http://api.humbughq.com/v1/messages \\\n -u you@example.com:a0b1c2d3e4f5a6b7c8d9e0f1a2b3c4d5 \\\n -d \"last=102345\"\n
{\"msg\": \"\", \"result\": \"success\"}\n
\nclient.send_message({\n \"type\": \"private\",\n \"to\": \"wdaher@humbughq.com\",\n \"content\": \"I come not, friends, to steal away your hearts.\"\n})\nclient.send_message({\n \"type\": \"stream\",\n \"to\": \"Denmark\",\n \"subject\": \"Castle\",\n \"content\": \"Something is rotten in the state of Denmark.\"\n})\n
curl https://humbughq.com/api/v1/messages \\\n -u YOUR_EMAIL:YOUR_API_KEY \\\n -d \"type=stream\" \\\n -d \"to=Denmark\" \\\n -d \"subject=Castle\" \\\n -d \"content=Something is rotten in the state of Denmark.\"\n
curl https://humbughq.com/api/v1/messages \\\n -u YOUR_EMAIL:YOUR_API_KEY \\\n -d \"type=private\" \\\n -d \"to=wdaher@humbughq.com\" \\\n -d \"content=I come not, friends, to steal away your hearts.\"\n
humbug-send --stream Denmark --subject Castle
humbug-send wdaher@humbughq.com\n
If you'd like, you can also provide the message on the command-line with the -m
flag, as follows:
humbug-send --stream Denmark --subject Castle -m \"Something is rotten in the state of Denmark.\"\n