Skip to content

Instantly share code, notes, and snippets.

@ccj242
Last active June 21, 2018 16:58
Show Gist options
  • Select an option

  • Save ccj242/d895989cf85ca337ce8a6a0691a64831 to your computer and use it in GitHub Desktop.

Select an option

Save ccj242/d895989cf85ca337ce8a6a0691a64831 to your computer and use it in GitHub Desktop.
<?php
use Abraham\TwitterOAuth\TwitterOAuth;
$tweet="this is a test tweet";
$connection = new TwitterOAuth(/*CONSUMER_KEY*/, /*CONSUMER_SECRET*/, /*ACCESS_TOKEN*/, /*ACCESS_TOKEN_SECRET*/);
$content = $connection->get('account/verify_credentials');
$connection->post('statuses/update', array('status' => $tweet));
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment