community.general.hipchat (8.5.0) — module

Send a message to Hipchat

Authors: Shirou Wakayama (@shirou), Paul Bourdel (@pb8226)

Install collection

Install with ansible-galaxy collection install community.general:==8.5.0


Add to requirements.yml

  collections:
    - name: community.general
      version: 8.5.0

Description

Send a message to a Hipchat room, with options to control the formatting.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Send a message to a Hipchat room
  community.general.hipchat:
    room: notif
    msg: Ansible task finished
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Send a message to a Hipchat room using Hipchat API version 2
  community.general.hipchat:
    api: https://api.hipchat.com/v2/
    token: OAUTH2_TOKEN
    room: notify
    msg: Ansible task finished

Inputs

    
api:
    default: https://api.hipchat.com/v1
    description:
    - API url if using a self-hosted hipchat server. For Hipchat API version 2 use the
      default URI with C(/v2) instead of C(/v1).
    type: str

msg:
    description:
    - The message body.
    required: true
    type: str

room:
    description:
    - ID or name of the room.
    required: true
    type: str

color:
    choices:
    - yellow
    - red
    - green
    - purple
    - gray
    - random
    default: yellow
    description:
    - Background color for the message.
    type: str

token:
    description:
    - API token.
    required: true
    type: str

notify:
    default: true
    description:
    - If true, a notification will be triggered for users in the room.
    type: bool

msg_from:
    aliases:
    - from
    default: Ansible
    description:
    - Name the message will appear to be sent from. Max length is 15 characters - above
      this it will be truncated.
    type: str

msg_format:
    choices:
    - text
    - html
    default: text
    description:
    - Message format.
    type: str

validate_certs:
    default: true
    description:
    - If V(false), SSL certificates will not be validated. This should only be used on
      personally controlled sites using self-signed certificates.
    type: bool