Model Registration

In order to have your models be either an actor, target, or action object they must first be registered with actstream. In v0.5 and above, actstream has a registry of all actionable model classes. When you register them, actstream sets up certain GenericRelations that are required for generating activity streams.

For Django versions 1.7 or later, you should use AppConfig.

# myapp/
from django.apps import AppConfig

class MyAppConfig(AppConfig):
    name = 'myapp'

    def ready(self):
        from actstream import registry

# myapp/
default_app_config = 'myapp.apps.MyAppConfig'


Update these settings in your project’s As of v0.4.4, all settings are contained inside the ACTSTREAM_SETTINGS dictionary. Here is an example of what you can set in your

    'MANAGER': 'myapp.managers.MyActionManager',
    'USE_PREFETCH': True,
    'USE_JSONFIELD': True,


Please decide early on whether you want to USE_JSONFIELD or not, as the field will be removed during initial migrations when this option is set to False (the default).


In v0.5 and above, since only Django>=1.4 is supported all generic lookups fall back to QuerySet.prefetch_related so the USE_PREFETCH and GFK_FETCH_DEPTH settings have been deprecated.

Supported settings are defined below.


The action manager is the Django manager interface used for querying activity data from the database.

The Python import path of the manager to use for Action.objects. Add your own manager here to create custom streams. There can only be one manager class per Django project.

For more info, see Writing Custom Streams

Defaults to actstream.managers.ActionManager


Set this to False to disable select_related and prefetch_related when querying for any streams. When True, related generic foreign keys will be prefetched for stream generation (preferable).

Defaults to True


Deprecated since version 0.5: This setting is no longer used (see note above).

Set this to True to forcefully enable prefetch_related (Django>=1.4 only). On earlier versions, the generic foreign key prefetch fallback contained within actstream.gfk will be enabled.

Defaults to whatever version you have.


Set this setting to True to enable the JSONField for all actions. Lets you add custom data to any of your actions, see Custom Action Data

Defaults to False


Deprecated since version 0.5: This setting is no longer used (see note above).

Number of levels of relations that select_related will perform. Only matters if you are not running prefetch_related (Django<=1.3).

Defaults to 0