Authorize service-to-service calls and report every request from Flask, Django or any WSGI app. pip install end-point-blank-py and wrap your app.
Published on PyPI.
pip install end-point-blank-py
Use the client ID and secret of an application environment you created in EndPointBlank.
import os
import end_point_blank as epb
from end_point_blank.middleware.report_interaction import ReportInteractionMiddleware
epb.configure(
client_id=os.environ["ENDPOINTBLANK_CLIENT_ID"],
client_secret=os.environ["ENDPOINTBLANK_CLIENT_SECRET"],
app_name="orders-service",
environment="production",
)
app.wsgi_app = ReportInteractionMiddleware(app.wsgi_app)
The middleware reports every request and response that passes through the wrapped app, and sends unhandled exceptions as error reports.
from end_point_blank.flask import authorized
@app.route("/orders")
@authorized
def list_orders():
...
authorized checks the caller against your grants before the view runs. A refusal raises UnauthorizedError carrying intake's status: 401 when the credential was not accepted, 403 when no grant covers the endpoint.
The README covers every setting: masking rules, the authorization cache, authorizing outbound calls and the management API client. The quickstart walks through creating the application and credentials this page assumes.
Deprecate and retire versions without breaking customers.
Scoped, rotatable credentials for service-to-service calls.
Every call between services, searchable and reassembled.
Know which client is failing, before they tell you.
Invite client organizations and grant them API packages.
Sign up in under a minute. No credit card, no sales call.