This package is abandoned and no longer maintained. No replacement package was suggested.


0.1.1 2014-08-15 01:12 UTC

This package is not auto-updated.

Last update: 2020-01-24 15:11:47 UTC


This module takes a tweet URL and returns a data structure as if the URL had been marked up with a proper h-entry.


Bring in this library using composer, or just by including the src\p3k\twitter-shim.php file.

  "p3k/mf2-twitter-shim": "0.1.*",

First, initialize the Twitter client with your credentials.

p3k\twitter\client($twitterClientID, $twitterClientSecret, $twitterAccessToken, $twitterAccessTokenSecret);

Then you can call parseTweet with a URL to a tweet and get back a nicely formatted h-entry.

$data = p3k\twitter\parseTweet('https://twitter.com/aaronpk/status/429757886953033728');


Copyright 2014 by Aaron Parecki

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at


Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.