muck_out.process
activity_stub
activity_stub(
data: dict, actor_id: str | None = None
) -> ActivityStub
Builds the activity stub
Source code in muck_out/process/activity.py
actor_stub
collection_stub
collection_stub(data: dict[str, Any]) -> CollectionStub
Returns a normalized version of a collection, which possible null values
Source code in muck_out/process/collection.py
normalize_activity
Normalizes activities.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
activity
|
dict
|
The activity being normalized |
required |
actor_id
|
str | None
|
Actor receiving this activity |
None
|
Returns:
| Type | Description |
|---|---|
Activity
|
|
Source code in muck_out/process/activity.py
normalize_actor
Normalizes an ActivityPub actor
Source code in muck_out/process/actor.py
normalize_collection
normalize_collection(
collection: dict[str, Any],
) -> Collection | None
Normalizes a collection
Source code in muck_out/process/collection.py
normalize_object
Normalizes an object
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
obj
|
dict[str, Any]
|
The object to be normalized |
required |
Returns:
| Type | Description |
|---|---|
Object
|
|
Source code in muck_out/process/object.py
object_stub
object_stub(data: dict[str, Any]) -> ObjectStub
Constructs a stub from data
This function is not a direct equivalent to ObjectStub.model_validate as functionality happens that is not field to field for
contentfilled fromcontentMap