diff options
author | Evan Prodromou <evan@status.net> | 2010-12-13 14:35:42 -0500 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2010-12-13 14:35:42 -0500 |
commit | 027c73a4a1e1509b7cacc6068dacfb4fc778c872 (patch) | |
tree | f0127e35e046836148fd090663e6754db5cbbe37 /lib | |
parent | bb55784e902388f12ae9a0beddf283b48f19531e (diff) | |
parent | 1033e1e5199bd0c5889ecbc915c6b644cff23c10 (diff) |
Merge branch 'activityatompub' into 0.9.x
Diffstat (limited to 'lib')
-rw-r--r-- | lib/router.php | 43 |
1 files changed, 36 insertions, 7 deletions
diff --git a/lib/router.php b/lib/router.php index d747493de..c42cca5f6 100644 --- a/lib/router.php +++ b/lib/router.php @@ -761,13 +761,6 @@ class Router $m->connect('api/oauth/authorize', array('action' => 'ApiOauthAuthorize')); - $m->connect('api/statusnet/app/service/:id.xml', - array('action' => 'ApiAtomService', - 'id' => Nickname::INPUT_FMT)); - - $m->connect('api/statusnet/app/service.xml', - array('action' => 'ApiAtomService')); - // Admin $m->connect('admin/site', array('action' => 'siteadminpanel')); @@ -909,6 +902,42 @@ class Router array('nickname' => Nickname::DISPLAY_FMT)); } + // AtomPub API + + $m->connect('api/statusnet/app/service/:id.xml', + array('action' => 'ApiAtomService', + 'id' => Nickname::DISPLAY_FMT)); + + $m->connect('api/statusnet/app/service.xml', + array('action' => 'ApiAtomService')); + + $m->connect('api/statusnet/app/subscriptions/:subscriber/:subscribed.atom', + array('action' => 'AtomPubShowSubscription'), + array('subscriber' => '[0-9]+', + 'subscribed' => '[0-9]+')); + + $m->connect('api/statusnet/app/subscriptions/:subscriber.atom', + array('action' => 'AtomPubSubscriptionFeed'), + array('subscriber' => '[0-9]+')); + + $m->connect('api/statusnet/app/favorites/:profile/:notice.atom', + array('action' => 'AtomPubShowFavorite'), + array('profile' => '[0-9]+', + 'notice' => '[0-9]+')); + + $m->connect('api/statusnet/app/favorites/:profile.atom', + array('action' => 'AtomPubFavoriteFeed'), + array('profile' => '[0-9]+')); + + $m->connect('api/statusnet/app/memberships/:profile/:group.atom', + array('action' => 'AtomPubShowMembership'), + array('profile' => '[0-9]+', + 'group' => '[0-9]+')); + + $m->connect('api/statusnet/app/memberships/:profile.atom', + array('action' => 'AtomPubMembershipFeed'), + array('profile' => '[0-9]+')); + // user stuff Event::handle('RouterInitialized', array($m)); |