THE ORIONIS API
Build with clarity.
Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.
class documentation
class ForgotPasswordController(BaseController): (source)
Handle the built-in password-reset request endpoints.
| Static Method | _private |
Mark a response as private and prevent reset URL referrers. |
| Async Method | _form |
Render the reset form without exposing password values. |
| Async Method | _send |
Notify the account owner after the password reset commits. |
| Async Method | _send |
Issue and deliver a reset link after the response. |
| Async Method | index |
Render the forgot-password page. |
| Async Method | reset |
Reset the password without flashing credentials or tokens. |
| Async Method | send |
Queue a password-reset message without revealing account existence. |
| Async Method | show |
Display a reset form for an unconsumed link. |
| Constant | SENT |
Confirmation shown after a password-reset request, regardless of whether the account exists. |
Mark a response as private and prevent reset URL referrers.
| Parameters | |
result:orionis.http.Response | Response whose security headers are updated. |
| Returns | |
orionis.http.Response | The same response with privacy and indexing headers applied. |
async def _form(self, email:
str, token: str, *, valid: bool, errors: dict[ str, str] | ValidationException | None = None) -> HTMLResponse:
(source)
¶
Render the reset form without exposing password values.
| Parameters | |
email:str | Email value retained only when the link is valid. |
token:str | Reset token retained only when the link is valid. |
valid:bool | Whether the reset link passed token validation. |
errors:dict[str, str] | ValidationException | None, optional | Validation errors to display on the form. |
| Returns | |
orionis.http.HTMLResponse | Private reset form response with optional validation errors. |
Issue and deliver a reset link after the response.
| Parameters | |
email:str | Email address submitted for password recovery. |
basestr | Application base URL used to construct the link. |
broker:orionis.auth.passwords.broker.PasswordBroker | Service that issues the reset token and loads the account. |
| Returns | |
None | Completes after delivery or when no matching account is found. |
Render the forgot-password page.
| Returns | |
orionis.http.HTMLResponse | Rendered forgot-password page response. |
Reset the password without flashing credentials or tokens.
| Parameters | |
request:orionis.http.Request | Current HTTP request containing the reset form payload. |
broker:orionis.auth.passwords.broker.PasswordBroker | Service that validates and consumes the reset token. |
| Returns | |
orionis.http.Response | Reset form response for invalid input, or a private login redirect after a successful reset. |
async def sendResetLinkEmail(self, payload:
ForgotPasswordSchema, request: Request, broker: PasswordBroker) -> HttpResponse:
(source)
¶
Queue a password-reset message without revealing account existence.
| Parameters | |
payload:orionis.http.default.schemas.forgot_password.ForgotPasswordSchema | Validated email address submitted by the requester. |
request:orionis.http.Request | Current HTTP request used to build the reset URL. |
broker:orionis.auth.passwords.broker.PasswordBroker | Service that issues and validates reset tokens. |
| Returns | |
orionis.http.Response | Private redirect response returned before account lookup. |
Display a reset form for an unconsumed link.
| Parameters | |
request:orionis.http.Request | Current HTTP request containing the email and token query values. |
broker:orionis.auth.passwords.broker.PasswordBroker | Service that validates the reset token. |
| Returns | |
orionis.http.HTMLResponse | Reset form response with the link validity state. |