Skip to main content
Version: 5.7.0

SendNormalizedPushNotification

Sends a notification to a user consisting of alert content and custom data.

ServiceOperation
pushNotificationSEND_NORMALIZED

Method Parameters

ParameterDescription
toProfileIdThe profileId of the user to receive the notification
alertContentJsonBody and title of alert
customDataJsonOptional custom data

Usage

http://localhost:3000
string toProfileId = "profile1";
string alertContentJson = "{\"body\":\"content of message\",\"title\":\"message title\"}";
string customDataJson = "{\"field1\":\"value1\",\"field2\":\"value2\"}";
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};

_bc.PushNotificationService.SendNormalizedPushNotification(toProfileId, alertContentJson, customDataJson, successCallback, failureCallback);
JSON Response
{
"status": 200,
"data": null
}