defmodule Pleroma.Web.Router do
use Pleroma.Web, :router
- alias Pleroma.{Repo, User, Web.Router}
-
pipeline :api do
plug(:accepts, ["json"])
plug(:fetch_session)
plug(:accepts, ["xml", "atom", "html", "activity+json"])
end
+ pipeline :oembed do
+ plug(:accepts, ["json", "xml"])
+ end
+
scope "/", Pleroma.Web do
pipe_through(:ostatus)
post("/push/subscriptions/:id", Websub.WebsubController, :websub_incoming)
end
+ scope "/", Pleroma.Web do
+ pipe_through(:oembed)
+
+ get("/oembed", OEmbed.OEmbedController, :url)
+ end
+
pipeline :activitypub do
plug(:accepts, ["activity+json"])
plug(Pleroma.Web.Plugs.HTTPSignaturePlug)