Skip to main content
Version: 5.7.0

SendRawPushNotification

Sends a notification to a user consisting of raw platform dependent content.

ServiceOperation
pushNotificationSEND_RAW

Method Parameters

ParameterDescription
toProfileIdThe profileId of the user to receive the notification
fcmContentFCM dependent content
iosContentIOS (APNS) dependent content
facebookContentFacebook dependent content

Usage

http://localhost:3000
string toProfileId = "profile1";
string fcmContent = "{\"notification\":{\"body\":\"content of message\",\"title\":\"message title\"},\"data\":{\"customfield1\":\"customValue1\",\"customfield2\":\"customValue2\"},\"priority\":\"normal\"}";
string iosContent = "{\"aps\":{\"alert\":{\"body\":\"content of message\",\"title\":\"message title\"},\"badge\":0,\"sound\":\"gggg\"}}";
string facebookContent = "{\"template\":\"content of message\"}";
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.SendRawPushNotification(toProfileId, fcmContent, iosContent, facebookContent, successCallback, failureCallback);
JSON Response
{
"status": 200,
"data": null
}