Module: Fedipub::ActorEntity
- Extended by:
- ActiveSupport::Concern
- Defined in:
- app/models/concerns/fedipub/actor_entity.rb
Overview
Concern to include in models that acts as actors.
Actors can be anything; they authors content via their outbox and receive content in their inbox. Actors can follow and be followed by each other
By default, when an entry is created on models using this concern, a local Fedipub::Actor will be created.
See also:
Usage
Include the concern in an existing model:
class User < ApplicationRecord
include Fedipub::ActorEntity
acts_as_fedipub_actor options
end
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
-
#to_activitypub_object ⇒ Object
Add custom data to actor responses.
Instance Method Details
#to_activitypub_object ⇒ Object
Add custom data to actor responses.
Override in your own model to add extra data, which will be merged into the actor response
generated by Fedipub. You can include extra @context for activitypub extensions and it will
be merged with the main response context.
141 142 143 |
# File 'app/models/concerns/fedipub/actor_entity.rb', line 141 def to_activitypub_object {} end |