Spaces:
Sleeping
Sleeping
Download test_cookies.py from hashir-qt/tasklert-api: direct link, hf CLI and curl.
- Browser
- Download file 586 Bytes
-
https://huggingface.co/spaces/hashir-qt/tasklert-api/resolve/main/test_cookies.py
- Command line
-
hf download hf://spaces/hashir-qt/tasklert-api/test_cookies.py
-
curl -L -o test_cookies.py https://huggingface.co/spaces/hashir-qt/tasklert-api/resolve/main/test_cookies.py
586 Bytes
| # Quick test to see what Better Auth cookies look like | |
| import asyncio | |
| import httpx | |
| async def test(): | |
| # Try to get session from Better Auth | |
| client = httpx.AsyncClient() | |
| try: | |
| # This should fail but show us the response | |
| response = await client.get( | |
| "http://localhost:3000/api/auth/get-session", | |
| timeout=5.0 | |
| ) | |
| print(f"Status: {response.status_code}") | |
| print(f"Response: {response.text[:500]}") | |
| except Exception as e: | |
| print(f"Error: {e}") | |
| finally: | |
| await client.aclose() | |
| asyncio.run(test()) | |