Learn R Programming

pushoverr (version 1.0.0)

check_receipt: Check whether an emergency priority message was received

Description

check_receipt checks the status of an emergency priority message, receiving information about whether and by whom it was acknowledged, when the message was last delivered, whether a callback URL was visited, and more.

is.acknowledged returns a logical value indicating whether the emergency message was acknowledged (TRUE) or not (FALSE).

Usage

check_receipt(receipt, app = get_pushover_app())

is.acknowledged(receipt, app = get_pushover_app())

Arguments

receipt

receipt ID from sending an emergency message

app

application token (see set_pushover_app)

Value

a list containing the following fields:

  • status: request status (1 = success)

  • acknowledged: number indicating whether (1) or not (0) notification has been acknowledged

  • acknowledged_at: Unix timestamp indicating when notification was acknowledged, or 0

  • acknowledged_by: key of the user who first acknowledged the notification, or ""

  • acknowledged_by_device: name of the device on which the first user acknowledged the notification

  • last_delivered_at: Unix timestamp of when the notification was last acknowledged, or 0

  • expired: whether (1) or not (0) the notification has expired

  • expires_at: Unix timestamp indicating when the notificaion will no longer be retried

  • called_back: whether (1) or not (0) the callback URL has been visited

  • called_back_at: Unix timestamp indicating when the callback URL was visited

  • request: unique request ID

  • errors: a list of error messages (only for unsuccessful requests)

  • raw: the raw response object

Examples

Run this code
# NOT RUN {
msg1 <- pushover_emergency(message = "Test emergency message")
check_recepit(receipt = msg1$receipt)
is.acknowledged(receipt = msg1$receipt)
# }

Run the code above in your browser using DataLab