Skip to content

feat: Add OTP login endpoints and service abstraction#233

Closed
dsowinski2 wants to merge 2 commits into
mainfrom
feat/add-otp-login
Closed

feat: Add OTP login endpoints and service abstraction#233
dsowinski2 wants to merge 2 commits into
mainfrom
feat/add-otp-login

Conversation

@dsowinski2
Copy link
Copy Markdown
Contributor

@dsowinski2 dsowinski2 commented Nov 20, 2025

This PR adds endpoints to handle General OTP login and base service.

In future we should switch to using cookies with auth token for both auth methods, let me know what you think I can take care of it as we are currently doing stuff connected with auth.

@dsowinski2 dsowinski2 self-assigned this Nov 20, 2025
return Response({}, status=403)


class OTPCallbackView(APIView):
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't really see any use case for an one time password login flow besides our demo server - why is that in the core of the server?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought if we can enable it on FE(It points to specific endpoints) it will be consistent to have that also implemented by default on BE side, so we have clear messages even if it's not configured. But, if you think that's redundant I can move it away from this repo. Please let me know

const navigate = useNavigate();
const [errorMessage, setErrorMessage] = useState<string | null>(null);
const onClick = () => {
window.location.href = `${import.meta.env.VITE_API_BASE}/api/auth/otp/start`
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a bit confused - is that SSO or OTP? These are two different concepts

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's OTP, I need to change old button label if that's what you mean.

@dsowinski2 dsowinski2 marked this pull request as draft January 29, 2026 11:47
@dsowinski2
Copy link
Copy Markdown
Contributor Author

This issue has different PR: #296

@dsowinski2 dsowinski2 closed this Feb 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants