getNotificationPreferences

getNotificationPreferences return information about which notifications you are currently receiving for a given user.

getNotificationPreferences Input

getNotificationPreferences is a secure API method with the following URL and HTTP header requirements:

Submit to URL: https://api.bonanza.com/api_requests/secure_request
Required in HTTP header: X-BONANZLE-API-DEV-NAME set to your dev_id
  X-BONANZLE-API-CERT-NAME set to your cert_id

Note that all secure methods except for fetchToken and getBoothItems require you to submit a user token so that we know what user account you are acting on behalf of.  For details about setting up and submitting user tokens, see our intro to user tokens.

The name for your request should be getNotificationPreferencesRequest.

Here are the available input parameters that can be serialized into JSON:

Argument Type Occurrence Meaning
requesterCredentials Container Required Container for user credentials
requesterCredentials .bonanzleAuthToken string Required The verified user token for the user who you are acting on behalf of.

getNotificationPreferences Output

The name for the output returned from this request is getNotificationPreferencesResponse. So, after parsing the serialized response into JSON, you can access the data with something like my_json_hash['getNotificationPreferencesResponse']

Here are all the possible output parameters:

Argument Type Occurrence Meaning
errorMessage Container Conditionally Description of an error or warning that occurred when Bonanza processed the request. Not returned if the ack value is Success.
errorMessage.error Container Conditionally,
repeatable: [0..*]
errorMessage.error.category ErrorCategory Conditionally Currently unused.
errorMessage.error.message string Conditionally A description of the error
errorMessage.error.type ErrorType Conditionally A unique descriptive name for the error.
Standard Output Fields
timestamp dateTime Always This value represents the date and time when Bonanza processed the request. The time zone of this value is GMT and the format is the ISO 8601 date and time format (YYYY-MM-DDTHH:MM:SS.SSSZ). See the "dateTime" type for information about this time format and converting to and from the GMT time zone.
Call-specific Output Fields
applicationDeliveryPreferences Container Required Container to hold all the details about notification being setup.
applicationDeliveryPreferences .applicationEnable string Optional Enables or disables notifications and alerts. If you disable notifications, the application will not receive them, but its notification preferences are preserved. Possible values are
  • Disable: The entry is disabled.
  • Enable: The entry is enabled.
applicationDeliveryPreferences .applicationURL string optional The address of a notification delivery URL. This address applies to the DeliveryURLName within the same ApplicationDeliveryPreferences.DeliveryURLDetails container. For delivery to a server, the URL begins with http:// or https:// and must be well formed. Use a URL that is functional at the time of the call. For delivery to an email address, the URL begins with mailto:// and specifies a valid email address.
applicationDeliveryPreferences .deliveryURLDetails Container Optional  
applicationDeliveryPreferences.
deliveryURLDetails.
deliveryURL
string Optional The address of a notification delivery URL. This address applies to the DeliveryURLName within the same ApplicationDeliveryPreferences.DeliveryURLDetails container. For delivery to a server, the URL begins with http:// or https:// and must be well formed. Use a URL that is functional at the time of the call. For delivery to an email address, the URL begins with mailto:// and specifies a valid email address.
applicationDeliveryPreferences.
deliveryURLDetails.
status
string Optional Enables or disables this notifications URL. Possible values are
  • Disable: The entry is disabled.
  • Enable: The entry is enabled.
userDeliveryPreferenceArray Container Optional  
userDeliveryPreferenceArray.
notificationEnable
Container Optional Array container for individual events.
userDeliveryPreferenceArray.
notificationEnable.eventEnable
string Optional Whether this event is enabled or not Possible values are
  • Disable: The entry is disabled.
  • Enable: The entry is enabled.
userDeliveryPreferenceArray.
notificationEnable.eventType
EventNotificationType Optional See list of possible values in EventNotificationType