private static function fetchApnsId(string $headers): string
    {
        $data = explode("\n", trim($headers));

        foreach ($data as $part) {
            $middle = explode(":", $part);

            if ($middle[0] !== 'apns-id') {
                continue;
            }

            return trim($middle[1]);
        }

        return '';
    }