404 when trying to send push notifications

#1

Hi all! I’m trying to send a push notification using the EXPO API but it gives me a 404 message, any ideas why, this is the PHP code I’m using:

        $client = new Client();
		$result = $client->post('https://exp.host/--/api/v2/push/send', [
			'headers' => [
				'accept' => 'application/json',
				'accept-encoding' => 'gzip, deflate',
				'content-type' => 'application/json'
			],
    		'form_params' => [
				'to' => array('ExponentPushToken[XXXXX_YYYYYYY]'),
        		'title' => $notification->title,
        		'body' => $notification->body
    		]
		]);
closed #2

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.