fix: corregir URL de upload binario a graph.facebook.com/{version}/{session_id}
This commit is contained in:
@@ -99,11 +99,11 @@ try {
|
||||
$uploadSessionId = $sessionData['id'];
|
||||
|
||||
// ── Paso 2: Subir el archivo binario ──────────────────────────────────────
|
||||
// POST https://rupload.facebook.com/whatsapp-business-profile/{session_id}
|
||||
// POST https://graph.facebook.com/{version}/{upload_session_id}
|
||||
$fileContent = file_get_contents($file['tmp_name']);
|
||||
if ($fileContent === false) throw new Exception("No se pudo leer el archivo temporal");
|
||||
|
||||
$uploadUrl = "https://rupload.facebook.com/whatsapp-business-profile/{$uploadSessionId}";
|
||||
$uploadUrl = "https://graph.facebook.com/{$apiVersion}/{$uploadSessionId}";
|
||||
|
||||
$ch2 = curl_init();
|
||||
curl_setopt_array($ch2, [
|
||||
|
||||
Reference in New Issue
Block a user