Compare commits
2 Commits
f60002d98e
...
e124f05e7b
Author | SHA1 | Date | |
---|---|---|---|
e124f05e7b | |||
![]() |
dda39532d6 |
@ -115,13 +115,13 @@ Organic Bananas
|
|||||||
# OAuth Settings
|
# OAuth Settings
|
||||||
GOOGLE_CLIENT_ID: str = ""
|
GOOGLE_CLIENT_ID: str = ""
|
||||||
GOOGLE_CLIENT_SECRET: str = ""
|
GOOGLE_CLIENT_SECRET: str = ""
|
||||||
GOOGLE_REDIRECT_URI: str = "http://localhost:8000/auth/google/callback"
|
GOOGLE_REDIRECT_URI: str = "http://localhost:8000/api/v1/auth/google/callback"
|
||||||
|
|
||||||
APPLE_CLIENT_ID: str = ""
|
APPLE_CLIENT_ID: str = ""
|
||||||
APPLE_TEAM_ID: str = ""
|
APPLE_TEAM_ID: str = ""
|
||||||
APPLE_KEY_ID: str = ""
|
APPLE_KEY_ID: str = ""
|
||||||
APPLE_PRIVATE_KEY: str = ""
|
APPLE_PRIVATE_KEY: str = ""
|
||||||
APPLE_REDIRECT_URI: str = "http://localhost:8000/auth/apple/callback"
|
APPLE_REDIRECT_URI: str = "http://localhost:8000/api/v1/auth/apple/callback"
|
||||||
|
|
||||||
# Session Settings
|
# Session Settings
|
||||||
SESSION_SECRET_KEY: str = "your-session-secret-key" # Change this in production
|
SESSION_SECRET_KEY: str = "your-session-secret-key" # Change this in production
|
||||||
|
@ -154,6 +154,9 @@ async def refresh_jwt_token(
|
|||||||
)
|
)
|
||||||
|
|
||||||
# --- Include API Routers ---
|
# --- Include API Routers ---
|
||||||
|
# Include OAuth routes first (no auth required)
|
||||||
|
app.include_router(oauth_router, prefix="/auth", tags=["auth"])
|
||||||
|
|
||||||
# Include FastAPI-Users routes
|
# Include FastAPI-Users routes
|
||||||
app.include_router(
|
app.include_router(
|
||||||
fastapi_users.get_auth_router(auth_backend),
|
fastapi_users.get_auth_router(auth_backend),
|
||||||
@ -181,14 +184,8 @@ app.include_router(
|
|||||||
tags=["users"],
|
tags=["users"],
|
||||||
)
|
)
|
||||||
|
|
||||||
# Include OAuth routes
|
|
||||||
# app.include_router(oauth_router, prefix="/auth", tags=["auth"])
|
|
||||||
|
|
||||||
# Include your API router
|
# Include your API router
|
||||||
app.include_router(api_router, prefix=settings.API_PREFIX)
|
app.include_router(api_router, prefix=settings.API_PREFIX)
|
||||||
|
|
||||||
# Include OAuth routes under the main API prefix
|
|
||||||
app.include_router(oauth_router, prefix=f"{settings.API_PREFIX}/auth", tags=["auth"])
|
|
||||||
# --- End Include API Routers ---
|
# --- End Include API Routers ---
|
||||||
|
|
||||||
# Health check endpoint
|
# Health check endpoint
|
||||||
|
@ -39,7 +39,7 @@ import { useRouter } from 'vue-router';
|
|||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|
||||||
const handleGoogleLogin = () => {
|
const handleGoogleLogin = () => {
|
||||||
window.location.href = '/api/v1/auth/google/login';
|
window.location.href = '/auth/google/login';
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleAppleLogin = () => {
|
const handleAppleLogin = () => {
|
||||||
|
Loading…
Reference in New Issue
Block a user