View Source ActivityPub.Federator.APPublisher (Bonfire v0.9.11-social-beta.6)

Summary

Functions

Determine a user inbox to use based on heuristics. These heuristics are based on an approximation of the sharedInbox rules in the ActivityPub specification.

If you put the URL of the shared inbox of an ActivityPub instance in the following env variable, all public content will be pushed there via AP federation for search indexing purposes: PUSH_ALL_PUBLIC_CONTENT_TO_INSTANCE #TODO: move to adapter

Publish a single message to a peer. Takes a struct with the following parameters set

Functions

determine_inbox(user, is_public, type, num_recipients)

Determine a user inbox to use based on heuristics. These heuristics are based on an approximation of the sharedInbox rules in the ActivityPub specification.

gather_webfinger_links(actor)

Callback implementation for ActivityPub.Federator.Publisher.gather_webfinger_links/1.

is_representable?(activity)

Callback implementation for ActivityPub.Federator.Publisher.is_representable?/1.

maybe_federate_to_search_index(recipients, activity)

If you put the URL of the shared inbox of an ActivityPub instance in the following env variable, all public content will be pushed there via AP federation for search indexing purposes: PUSH_ALL_PUBLIC_CONTENT_TO_INSTANCE #TODO: move to adapter

publish(actor, activity, opts \\ [])

publish_one(params)

Publish a single message to a peer. Takes a struct with the following parameters set:

  • inbox: the inbox to publish to
  • json: the JSON message body representing the ActivityPub message
  • actor: the actor which is signing the message
  • id: the ActivityStreams URI of the message