(subscribers->notifications)
- getFeed - Get in-app notification feed for a particular subscriber
Get in-app notification feed for a particular subscriber
declare(strict_types=1);
require 'vendor/autoload.php';
use novu;
use novu\Models\Operations;
$sdk = novu\Novu::builder()
->setSecurity(
'<YOUR_API_KEY_HERE>'
)
->build();
$request = new Operations\SubscribersV1ControllerGetNotificationsFeedRequest(
subscriberId: '<id>',
payload: 'btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=',
);
$response = $sdk->subscribers->notifications->getFeed(
request: $request
);
if ($response->feedResponseDto !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
$request |
Operations\SubscribersV1ControllerGetNotificationsFeedRequest | ✔️ | The request object to use for the request. |
?Operations\SubscribersV1ControllerGetNotificationsFeedResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ErrorDto | 414 | application/json |
Errors\ErrorDto | 400, 401, 403, 404, 405, 409, 413, 415 | application/json |
Errors\ValidationErrorDto | 422 | application/json |
Errors\ErrorDto | 500 | application/json |
Errors\APIException | 4XX, 5XX | */* |