Issue Ticca Portal / Documentation / Install the SDK
Sign in

Documentation

One subsection per page, so each topic stays readable. Use the tabs above to move between them.

Install

pip install django-issue-ticca

# optional integrations
pip install "django-issue-ticca[drf,redis,celery]"

Installed here: 0.3.0 · PyPI · Source

Settings

INSTALLED_APPS += ['django_issue_ticca']

MIDDLEWARE += [
    'django_issue_ticca.middleware.ActiveUserTrackingMiddleware',
    'django_issue_ticca.middleware.ExceptionLoggingMiddleware',
    'django_issue_ticca.middleware.ResponseTimeLoggingMiddleware',
]

They must sit after AuthenticationMiddleware, otherwise hourly user statistics have no user to attribute.

URLs and migrations

# urls.py
path('issue-ticca/', include('django_issue_ticca.urls'))
python manage.py migrate

Moving the mount point is fine — set the app's mount prefix in its settings page to match.

Access key

ISSUE_TICCA = {
    'ACCESS_KEY': 'a-long-random-string',
    # health probes are often called without a signature
    'UNPROTECTED_PATHS': ['/health/'],
}

Verification fails closed: with no key configured the endpoints answer 503 instead of serving incident data. Register the same key in this portal.

Optional tuning

ISSUE_TICCA = {
    'SLOW_RESPONSE_THRESHOLD': 10.0,   # seconds; 0 disables
    'AUTO_RESOLVE_ON_SUCCESS': True,   # close incidents when the URL recovers
    'TRACK_HOURLY_USERS': True,
    'HOURLY_STATS_RETENTION_DAYS': 7,

    # subsystem checks (absent = 'not_configured', never fatal)
    'REDIS_URL': 'redis://localhost:6379/0',
    'CELERY_APP': 'myproject.celery.app',
}

Optional: DRF logging

REST_FRAMEWORK = {
    'EXCEPTION_HANDLER':
        'django_issue_ticca.tracking.exceptions.issue_ticca_exception_handler',
}

DRF turns exceptions into responses before Django sees them, so this handler is what gets them into the incident log. Only 5xx responses are recorded.

Track your own exceptions

from django_issue_ticca.exceptions import TrackedException

try:
    third_party.call()
except Exception as exc:
    TrackedException.capture(exc)
    raise

Each incident is a single row with a call counter: the first failure inserts it, later ones increment calls_before_closure, and it closes when the URL succeeds again. That counter is what escalates a system ticket to critical here.

Register it here

Name, access key, base URL, optional theme colour:

Add an app See the endpoint contract