Video upload always return type unrecognized. Abraham Williams PHP


#1

Hello,

I am trying to upload a video using Abraham Williams Twitter OAuth.
Here the code:

$connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET, $oauth[0]->platformOauthToken, $oauth[0]->platformOauthTokenSecret);
$content = $connection->get("account/verify_credentials");

	$status = "my status";

	$media1 = $connection->upload('media/upload', array('media' => $videoUrl, 'media_type' => 'video/mp4'), true);


	$result = $connection->post('statuses/update', array(
		'status' => $status,
		'media_ids' => implode(',', array($media1->media_id_string))
	));

	echo json_encode($result);

This code, always return:
{“error”:“media type unrecognized.”}

Some ideas?
Thank you.


I’m trying with very different video formats, as following:



https://video.twimg.com/ext_tw_video/560070131976392705/pu/pl/r1kgzh5PmLgium3-.m3u8