.activity_pub.server
cattle_grid.activity_pub.server
This package contains the overall router for all connection needs to the Fediverse. This means the .well-known endpoints.
webfinger_responder(resource)
async
Handles requests to .well-known/webfinger. Results are determined by the identifier property of [PublicIdentifier][cattle_grid.ap.models.PublicIdentifier] matching the resource parameter.
See RFC 7033 WebFinger.
Source code in cattle_grid/activity_pub/server/__init__.py
cattle_grid.activity_pub.server.router
ActivityPub related functionality
APHeaders
Bases: BaseModel
Headers every request should have. These should be added by the remote proxy.
Source code in cattle_grid/activity_pub/server/router.py
x_ap_location: str
instance-attribute
URI of the resource being retrieved
x_cattle_grid_requester: str
instance-attribute
URI of the actor making the request
ActivityResponse
Bases: JSONResponse
Response that ensures the content-type is “application/activity+json”
Source code in cattle_grid/activity_pub/server/router.py
actor_profile(id_str, headers)
async
Returns the actor
Source code in cattle_grid/activity_pub/server/router.py
followers(id_str, headers)
async
Returns the followers
Source code in cattle_grid/activity_pub/server/router.py
following(id_str, headers)
async
Returns the following
Source code in cattle_grid/activity_pub/server/router.py
outbox(id_str, headers)
async
Returns an empty ordered collection as outbox