ActivityPub.Web.ProxyRemoteObjectController (Bonfire v1.0.1-social-alpha.28)
View SourceSummary
Functions
Proxies a remote ActivityStreams object given by the id parameter.
Rate limit plug for controllers.
Functions
Proxies a remote ActivityStreams object given by the id parameter.
Examples
POST /proxy
Content-Type: application/x-www-form-urlencoded
id=https://remote.server/object/123Returns the fetched object as JSON, or an error if not found or fetch fails.
Rate limit plug for controllers.
Reads configuration from Application.get_env(:activity_pub, :rate_limit)[key_prefix] with fallback to default options provided in the plug call.
Options
:key_prefix- Prefix for the rate limit bucket key (required):scale_ms- Default time window in milliseconds (can be overridden by config):limit- Default number of requests (can be overridden by config)
Examples
plug :rate_limit,
key_prefix: :webfinger,
scale_ms: 60_000,
limit: 200