-
Notifications
You must be signed in to change notification settings - Fork 59
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
switch from submodules to virtualenv, package w/setuptools for pypi
- Loading branch information
Showing
89 changed files
with
220 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,8 @@ | ||
/build/ | ||
/dist/ | ||
/.eggs/ | ||
/*.egg-info | ||
/local/ | ||
datastore.dat | ||
oauth_client_secret | ||
plus-dogfood.json | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +0,0 @@ | ||
[submodule "oauth_dropins"] | ||
path = oauth_dropins | ||
url = [email protected]:snarfed/oauth-dropins.git | ||
[submodule "beautifulsoup"] | ||
path = beautifulsoup | ||
url = [email protected]:snarfed/beautifulsoup.git | ||
[submodule "mf2py"] | ||
path = mf2py | ||
url = [email protected]:kartikprabhu/mf2py.git | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
|ActivityStreams| | ||
|
||
This is a library and REST API that fetches and converts social network | ||
data between a wide variety of formats: | ||
- Facebook, Google+, Instagram, and Twitter native APIs | ||
- `ActivityStreams <http://activitystrea.ms/>`__ | ||
- `microformats2 <http://microformats.org/wiki/microformats2>`__ HTML | ||
- `microformats2 <http://microformats.org/wiki/microformats2>`__ JSON | ||
- `Atom <http://atomenabled.org/>`__ | ||
- XML | ||
|
||
You can try it out with these interactive demos: | ||
|
||
http://facebook-activitystreams.appspot.com/ | ||
http://twitter-activitystreams.appspot.com/ | ||
http://instagram-activitystreams.appspot.com/ | ||
|
||
`Check out the docs for more! <https://github.com/snarfed/activitystreams-unofficial>`__ | ||
|
||
License: This project is placed in the public domain. | ||
|
||
|
||
Using | ||
----- | ||
|
||
The library and REST API are both based on the `OpenSocial Activity | ||
Streams | ||
service <http://opensocial-resources.googlecode.com/svn/spec/2.0.1/Social-API-Server.xml#ActivityStreams-Service>`__. | ||
|
||
Let's start with an example. This code using the library: | ||
|
||
.. code:: python | ||
from activitystreams_unofficial import twitter | ||
... | ||
tw = twitter.Twitter(ACCESS_TOKEN_KEY, ACCESS_TOKEN_SECRET) | ||
tw.get_activities(group_id='@friends') | ||
is equivalent to this ``HTTP GET`` request: | ||
|
||
:: | ||
|
||
https://twitter-activitystreams.appspot.com/@me/@friends/@app/ | ||
?access_token_key=ACCESS_TOKEN_KEY&access_token_secret=ACCESS_TOKEN_SECRET | ||
|
||
They return the authenticated user's Twitter stream, ie tweets from the | ||
people they follow. Here's the JSON output: | ||
|
||
.. code:: json | ||
{ | ||
"itemsPerPage": 10, | ||
"startIndex": 0, | ||
"totalResults": 12 | ||
"items": [{ | ||
"verb": "post", | ||
"id": "tag:twitter.com,2013:374272979578150912" | ||
"url": "http://twitter.com/evanpro/status/374272979578150912", | ||
"content": "Getting stuff for barbecue tomorrow. No ribs left! Got some nice tenderloin though. (@ Metro Plus Famille Lemay) http://t.co/b2PLgiLJwP", | ||
"actor": { | ||
"username": "evanpro", | ||
"displayName": "Evan Prodromou", | ||
"description": "Prospector.", | ||
"url": "http://twitter.com/evanpro", | ||
}, | ||
"object": { | ||
"tags": [{ | ||
"url": "http://4sq.com/1cw5vf6", | ||
"startIndex": 113, | ||
"length": 22, | ||
"objectType": "article" | ||
}, ...], | ||
}, | ||
}, ...] | ||
... | ||
} | ||
`Check out the docs for more! <https://github.com/snarfed/activitystreams-unofficial>`__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
from oauth_dropins.appengine_config import * | ||
|
||
# Suppress BeautifulSoup warning that we let it pick the XML parser instead of | ||
# specifying one explicitly. | ||
import warnings | ||
warnings.filterwarnings('ignore', module='bs4', category=UserWarning) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,9 +6,9 @@ | |
|
||
__author__ = ['Ryan Barrett <[email protected]>'] | ||
|
||
import microformats2 | ||
from activitystreams_unofficial import microformats2 | ||
import re | ||
from oauth_dropins.webutil import testutil | ||
from activitystreams_unofficial import testutil | ||
|
||
|
||
class Microformats2Test(testutil.HandlerTest): | ||
|
Oops, something went wrong.