OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
firebase
/
vendor
/
kreait
/
firebase-php
/
src
/
Firebase
/
Messaging
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/12/2024 10:35:39 AM
rwxr-xr-x
📄
AndroidConfig.php
3.1 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
ApiClient.php
1.57 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
ApnsConfig.php
3.43 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
AppInstance.php
2.36 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
AppInstanceApiClient.php
5.45 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
CloudMessage.php
9.41 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
Condition.php
1.09 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
FcmOptions.php
1.15 KB
08/12/2024 10:35:38 AM
rw-r--r--
📁
Http
-
08/12/2024 10:36:41 AM
rwxr-xr-x
📄
Message.php
128 bytes
08/12/2024 10:35:38 AM
rw-r--r--
📄
MessageData.php
2.75 KB
08/12/2024 10:35:38 AM
rw-r--r--
📄
MessageTarget.php
1.78 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
Messages.php
717 bytes
08/12/2024 10:35:38 AM
rw-r--r--
📄
MulticastSendReport.php
5.25 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
Notification.php
2.55 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
RawMessageFromArray.php
471 bytes
08/12/2024 10:35:39 AM
rw-r--r--
📄
RegistrationToken.php
639 bytes
08/12/2024 10:35:39 AM
rw-r--r--
📄
RegistrationTokens.php
2.58 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
SendReport.php
2.2 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
Topic.php
929 bytes
08/12/2024 10:35:39 AM
rw-r--r--
📄
TopicSubscription.php
1.2 KB
08/12/2024 10:35:39 AM
rw-r--r--
📄
TopicSubscriptions.php
950 bytes
08/12/2024 10:35:39 AM
rw-r--r--
📄
WebPushConfig.php
2.63 KB
08/12/2024 10:35:39 AM
rw-r--r--
Editing: ApnsConfig.php
Close
<?php declare(strict_types=1); namespace Kreait\Firebase\Messaging; use JsonSerializable; /** * @see https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/generating_a_remote_notification * @see https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/sending_notification_requests_to_apns * @see https://firebase.google.com/docs/reference/fcm/rest/v1/projects.messages#apnsconfig */ final class ApnsConfig implements JsonSerializable { private const PRIORITY_CONSERVE_POWER = '5'; private const PRIORITY_IMMEDIATE = '10'; /** @var array{ * headers?: array<string, string>, * payload?: array<string, mixed>, * fcm_options?: array{ * analytics_label?: string, * image?: string * } * } */ private array $config; /** * @param array{ * headers?: array<string, string>, * payload?: array<string, mixed>, * fcm_options?: array{ * analytics_label?: string, * image?: string * } * } $config */ private function __construct(array $config) { $this->config = $config; } public static function new(): self { return new self([]); } /** * @param array{ * headers?: array<string, string>, * payload?: array<string, mixed>, * fcm_options?: array{ * analytics_label?: string, * image?: string * } * } $data */ public static function fromArray(array $data): self { return new self($data); } public function withDefaultSound(): self { return $this->withSound('default'); } /** * The name of a sound file in your app’s main bundle or in the Library/Sounds folder of your app’s * container directory. Specify the string "default" to play the system sound. */ public function withSound(string $sound): self { $config = clone $this; $config->config['payload'] ??= []; $config->config['payload']['aps'] ??= []; $config->config['payload']['aps']['sound'] = $sound; return $config; } /** * The number to display in a badge on your app’s icon. Specify 0 to remove the current badge, if any. */ public function withBadge(int $number): self { $config = clone $this; $config->config['payload'] ??= []; $config->config['payload']['aps'] ??= []; $config->config['payload']['aps']['badge'] = $number; return $config; } public function withImmediatePriority(): self { return $this->withPriority(self::PRIORITY_IMMEDIATE); } public function withPowerConservingPriority(): self { return $this->withPriority(self::PRIORITY_CONSERVE_POWER); } public function withPriority(string $priority): self { $config = clone $this; $config->config['headers'] ??= []; $config->config['headers']['apns-priority'] = $priority; return $config; } /** * @return array<string, mixed> */ public function jsonSerialize(): array { return \array_filter($this->config, static fn ($value) => $value !== null && $value !== []); } }