Description Usage Arguments Value References Examples
Send a message to the hipchat API v2.
1 2 | hipchat_send(type, var, ..., api_token = hipchat_api_token(),
method = "GET")
|
type |
character. One of the native Hipchat API domains:
|
var |
character. Whatever goes after the |
... |
HTTP arguments to send to the Hipchat API. Unnamed arguments will be passed in to the URL; named arguments will be assumed to be API parameters. See the examples section. |
api_token |
character. By default, |
method |
character. HTTP method. Either |
the JSON output response from the Hipchat API.
https://www.hipchat.com/docs/apiv2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ## Not run:
hipchat_send('room', 'My room', 'notification',
color = 'green', message = 'Everything looks <b>green</b>',
notify = FALSE, message_format = 'html')
# posts to https://api.hipchat.com/v2/room/My room/notification
hipchat_send('room', 'My room', 'share', 'link',
message = 'This looks like a cool package',
link = 'http://github.com/robertzk/hipchat')
# posts to https://api.hipchat.com/v2/room/My room/share/link
# and shares a link with the room.
hipchat_send('user', 'your@friend.org', 'message')
message = "Hey buddy what's going on?", notify = TRUE,
message_format = 'text')
# posts to https://api.hipchat.com/v2/user/your@friend.org/message
hipchat_send('room', 'My room', 'invite', 'your@friend.org',
reason = "Come join this room mang")
# posts to https://api.hipchat.com/v2/room/My room/invite/your@friend.org
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.