Skip to main content
Version: SDK-5.9.6

AgreeNightPushNotification

public BackendReturnObject AgreeNightPushNotification(bool isAgree);

Parameter

ValueTypeDescription
isAgreeboolNighttime push message consent status.
false: the user did not give consent; night time push notifications cannot be checked
true: the user gave consent; night time push notifications can be checked

Description

Sets whether push notifications sent between 8:40 pm to 8 am will be received.
Upon consent(true), the user can receive push notifications during the specified period; if there is no consent(false), the push notifications will not be sent to the user during that period.

Users cannot check the statuses of nighttime push messages set by themselves.

Example

Synchronous

Backend.Android.AgreeNightPushNotification(true);

Asynchronous

Backend.Android.AgreeNightPushNotification(true, (callback) => {
// Post-process
});

SendQueue

SendQueue.Enqueue(Backend.Android.AgreeNightPushNotification, true, (callback) => {
// Post-process
});

Return cases

Success cases

When registration is successful
statusCode : 204
message : Success