Learn R Programming

pushoverr (version 0.1.4)

content_value,PushoverResponse-method: Get a value from a API query response

Description

Pushover API calls return JSON data containing parameter-value data related to the query. content_value extracts the value for a given parameter from a PushoverResponse-class object.

Usage

"content_value"(object, param)

Arguments

object
param
The name of a parameter in the response

Value

A string containing the value associated with the given parameter.

Examples

Run this code
## Not run: 
# # Get the acknowledged status of an emergency message
# message <- PushoverMessage(message='EMERGENCY!', priority=2,
#                            token='KzGDORePK8gMaC0QOYAMyEEuzJnyUi',
#                            user='uQiRzpo4DXghDmr9QzzfQu27cmVRsG')
# response <- send(message)
# acknowledged <- as.numeric(content_value(response, 'acknowledged'))
# ## End(Not run)

Run the code above in your browser using DataLab