Skip to main content

django-suap-auth

PyPI Version Python CI and PyPI Deploy Python Versions Django Versions License: MIT Tests pre-commit Coverage

Backend de autenticação OAuth2 do Django para SUAP (Sistema Unificado de Administração Pública), o sistema de gestão acadêmica do IFRN, hospedado em suap.ifrn.edu.br.

Instalação

uv add django-suap-auth
# ou com pip:
# pip install django-suap-auth

Início Rápido

# settings.py
INSTALLED_APPS = [
    # ...
    "django_suap_auth",
]

AUTHENTICATION_BACKENDS = [
    "django_suap_auth.backends.SuapAuthBackend",
    "django.contrib.auth.backends.ModelBackend",
]

SUAP_AUTH = {
    "CLIENT_ID": "your-client-id",
    "CLIENT_SECRET": "your-client-secret",
    "REDIRECT_URI": "https://yourapp.example.com/auth/suap/callback/",
    "SCOPES": ["identificacao", "email"],  # opcional
}
LOGIN_REDIRECT_URL = "/dashboard/"
LOGIN_URL = "/login/"
# urls.py
from django.urls import path, include

urlpatterns = [
    # Fluxo OAuth2 padrão
    path("auth/suap/", include("django_suap_auth.urls")),
    # Entrypoints JWT do SUAP (/api/token/pair, /api/token/refresh, /api/token/verify) (opcional)
    path("api/token/", include("django_suap_auth.jwt_urls")),
    ...,
]
<!-- template -->
<a href="{% url 'suap_auth:login' %}">Login com SUAP</a>

Escopos Disponíveis

Escopo Descrição
identificacao Identificação básica (matricula, nome, campus)
email Endereço de email
documentos_pessoais Documentos pessoais (CPF, RG)
dados_academicos Dados acadêmicos (curso, notas, situação)
dados_pessoais Dados pessoais (data de nascimento, nacionalidade)
reitoria Dados de nível institucional

Documentação

Documentação completa disponível no diretório docs/ e nas GitHub Pages do projeto.

Licença

MIT © 2026 kelsoncm

Metadata

Release files for django-suap-auth 1.5.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-suap-auth 1.5.3
File Size Uploaded
django_suap_auth-1.5.3.tar.gz 47.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-suap-auth 1.5.3
File Interpreter ABI Platform
django_suap_auth-1.5.3-py3-none-any.whl Python 3 none any Details

Total release size: 106.7 kB

Release files / django_suap_auth-1.5.3.tar.gz

Download URL django_suap_auth-1.5.3.tar.gz
Size 47.3 kB
Tags Source
SHA-256 checksum
How to use checksums
221812d9a6b6544e9218a5db826cb96992c8536adeea611b475043db38ab7711
BLAKE2b-256 checksum
How to use checksums
6ef01b26773c3f816c176a6545ff1c0e38508f1e99fb90f4de3cc6bf18a665ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 27, 2026.

Transparency log

Release files / django_suap_auth-1.5.3-py3-none-any.whl

Download URL django_suap_auth-1.5.3-py3-none-any.whl
Size 59.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
239437c0ff2ae7b803d6e1f9f88711d471f68beedcd3bf8f032c1e751453d140
BLAKE2b-256 checksum
How to use checksums
98acfe608ac14f16da92e21aeacdee1fb577e4a8651deb47874ef5b7b79b1812
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 27, 2026.

Transparency log

Release history Release notifications | RSS feed

1.8.9

2 release files

1.8.8

2 release files

1.8.7

2 release files

1.8.6

2 release files

1.8.5

2 release files

1.8.4

2 release files

1.8.3

2 release files

1.8.2

2 release files

1.8.1

2 release files

1.8.0

2 release files

1.7.1

2 release files

1.7.0

2 release files

1.6.0

2 release files

This release

1.5.3 This release

2 release files

1.5.2

2 release files

1.5.1

2 release files

1.5.0

2 release files

1.4.0

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page