OneSignal\Notifications::getAll PHP Méthode

getAll() public méthode

Application authentication key and ID must be set.
public getAll ( integer $limit = self::NOTIFICATIONS_LIMIT, integer $offset ) : array
$limit integer How many notifications to return (max 50)
$offset integer Results offset (results are sorted by ID)
Résultat array
    public function getAll($limit = self::NOTIFICATIONS_LIMIT, $offset = 0)
    {
        $query = ['limit' => max(1, min(self::NOTIFICATIONS_LIMIT, filter_var($limit, FILTER_VALIDATE_INT))), 'offset' => max(0, min(self::NOTIFICATIONS_LIMIT, filter_var($offset, FILTER_VALIDATE_INT))), 'app_id' => $this->api->getConfig()->getApplicationId()];
        return $this->api->request('GET', '/notifications?' . http_build_query($query), ['Authorization' => 'Basic ' . $this->api->getConfig()->getApplicationAuthKey()]);
    }