Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
124 commits
Select commit Hold shift + click to select a range
7722e42
Add authentication features and user dashboard
Zingzy Aug 15, 2025
d95d066
Enhance logout functionality and cookie management
Zingzy Aug 15, 2025
5d9d973
Refactor HTML templates to use Jinja2 blocks for better maintainability
Zingzy Aug 15, 2025
896b629
Implement JWT configuration and enhance authentication utilities
Zingzy Aug 15, 2025
e6e7608
Refactor authentication modal and styles for improved accessibility a…
Zingzy Aug 15, 2025
b09d28f
Add v2 URL handling and API versioning
Zingzy Aug 16, 2025
203e02f
Enhance URL shortening functionality and improve frontend interactions
Zingzy Aug 16, 2025
6c65d7c
Add API key management and enhance dashboard features
Zingzy Aug 16, 2025
bd7f765
Refactor dashboard and API keys template for improved layout and styling
Zingzy Aug 16, 2025
f164e12
Refactor authentication and token management for improved security an…
Zingzy Aug 16, 2025
253cf57
Update environment configuration, enhance Flask app secret management…
Zingzy Aug 16, 2025
c0f37ae
Add key reveal modal and enhance dashboard key creation experience
Zingzy Aug 16, 2025
25804bf
Enhance navbar with profile dropdown and mobile profile menu
Zingzy Aug 16, 2025
1af388e
Refactor URL shortening API to use ShortenRequestBuilder for improved…
Zingzy Aug 17, 2025
bdfa4c0
Add new URL import and enhance key scopes for improved functionality
Zingzy Aug 17, 2025
5ff1f71
format with ruff
Zingzy Aug 17, 2025
be6d81a
Enhance dashboard layout and styling, add legacy URL shortening route…
Zingzy Aug 17, 2025
1e0f9b3
Refactor dashboard and connection messages for improved clarity and c…
Zingzy Aug 17, 2025
b515649
Implement segmented controls in dashboard for improved filtering options
Zingzy Aug 17, 2025
b07200e
Enhance dashboard functionality and layout with new routes and improv…
Zingzy Aug 17, 2025
016ea92
Fix the segmented button positioning
Zingzy Aug 18, 2025
6f6f120
Fix the icon positioning for dropdown menus in the options dropdown
Zingzy Aug 18, 2025
c3f39ab
fix: table header showing even when there is no key to display
Zingzy Aug 18, 2025
df8542c
Add new URL management API endpoints and refactor builder classes to …
Zingzy Aug 19, 2025
38614c8
Update GitHub Actions workflow to trigger on all branches instead of …
Zingzy Aug 19, 2025
633902d
Enhance dashboard link management with new URL modal and status badges
Zingzy Aug 19, 2025
9a8781d
Add new URL Creation modal
Zingzy Aug 20, 2025
dd2cd82
Enhance link management UI with QR code functionality and improved co…
Zingzy Aug 20, 2025
52dbf63
Enhance success modal with QR code interactions and confetti effect; …
Zingzy Aug 20, 2025
9aec8bb
Remove unnessary files and fix minor UI bugs
Zingzy Aug 20, 2025
7f8a803
Add two-tier permissions selector with access level options and detai…
Zingzy Aug 20, 2025
a9d095c
Integrate Tippy.js for enhanced tooltip functionality in the dashboar…
Zingzy Aug 20, 2025
5f0d07e
Add new redirection system for v2 URLs with backward compatibility wi…
Zingzy Aug 24, 2025
2567fc8
Invalidate cache on any URL update; Format files with ruff
Zingzy Aug 24, 2025
2891420
feat: Add statistics endpoint and related functionality
Zingzy Aug 26, 2025
fd1fa4b
feat: Implement Statistics Dashboard with interactive charts and cust…
Zingzy Aug 29, 2025
1aecfac
Add advanced date range picker and integrate with statistics dashboard
Zingzy Aug 29, 2025
341a762
feat: Enhance statistics dashboard with auto-refresh functionality an…
Zingzy Aug 29, 2025
9a42640
fix: Adjust country chart styling for improved visibility and layout
Zingzy Aug 29, 2025
e919b9b
feat: Enhance statistics dashboard styling with new card layout and b…
Zingzy Aug 29, 2025
0c5b0a3
feat: Add table view functionality to statistics dashboard with fade …
Zingzy Aug 30, 2025
cb55dae
fix: statistics page header; custom time-range not sending proper tim…
Zingzy Aug 30, 2025
eb4cd06
feat: Implement mobile header and sidebar functionality with responsi…
Zingzy Aug 30, 2025
a02cf11
fix: Enable stacked charts for comparison data option in statistics d…
Zingzy Aug 30, 2025
30e95a0
feat: Update click handling and formatting for last click timestamps;…
Zingzy Aug 30, 2025
204e483
feat: Add experimental full-width styles for statistics charts and up…
Zingzy Aug 31, 2025
da2f5a1
fix: Cap future dates in StatsQueryBuilder and validate date range in…
Zingzy Sep 1, 2025
4b44277
style: Adjust navbar padding and width, refine chart container margin…
Zingzy Sep 1, 2025
e2c9f02
feat: Enhance bot detection and city retrieval in redirector; update …
Zingzy Sep 2, 2025
57d988b
Enable block-bots by default for all new short links
Zingzy Sep 2, 2025
b9e6403
fix: block_bots not returned via links API; add new badge for block_bots
Zingzy Sep 2, 2025
5f7b797
feat: Sanitize referrer domain in handle_v2_click to enhance security…
Zingzy Sep 2, 2025
7fcbb52
feat: Add country name mapping in StatisticsDashboard and enhance cou…
Zingzy Sep 2, 2025
1874ec6
feat: Implement dynamic time bucketing for analytics; enhance time ag…
Zingzy Sep 2, 2025
fa3a578
lint using ruff
Zingzy Sep 2, 2025
be5347c
fix: Update timeseries bucket, bucketing 1 hour interval in hourly wi…
Zingzy Sep 2, 2025
087f426
feat: Implement filter system in StatisticsDashboard with multi-selec…
Zingzy Sep 3, 2025
6de7124
refactor: Revamp filter system in StatisticsDashboard with a new drop…
Zingzy Sep 3, 2025
352e6fd
feat: Add subtle crossfade transitions for filter view changes in Sta…
Zingzy Sep 3, 2025
ed4003c
filter ux update and debug logs cleanup
Zingzy Sep 3, 2025
de211a3
feat: Update statistics dashboard filters and queries; enhance filter…
Zingzy Sep 3, 2025
e9fc2fd
feat: Enhance chart data processing in StatisticsDashboard; implement…
Zingzy Sep 3, 2025
a14ecac
feat: Implement API key management enhancements; add rate limiting, a…
Zingzy Sep 4, 2025
15e53dd
feat: Enhance StatisticsDashboard with interactive chart filtering; a…
Zingzy Sep 4, 2025
69cec7e
reduce code redundancy and increase code reusability
Zingzy Sep 4, 2025
f5ce915
Enhance dashboard styling and update chart colors
Zingzy Sep 4, 2025
dfd56d9
feat: Add average redirection time to statistics dashboard; update AP…
Zingzy Sep 4, 2025
0d2c3d3
lint using ruff
Zingzy Sep 4, 2025
e50c95e
feat: Enhance StatsQueryBuilder to handle "Direct" referrer filtering…
Zingzy Sep 4, 2025
4202fd1
format using uv
Zingzy Sep 4, 2025
272fe57
style: Update dashboard CSS for improved dropdown and button aestheti…
Zingzy Sep 4, 2025
9ece334
feat: Increase API key creation rate limit from 3 to 5 per hour; upda…
Zingzy Sep 4, 2025
012d86c
style: Update modal title section for success state; combine delete a…
Zingzy Sep 4, 2025
7657de5
feat: Enhance date parsing to support additional relative time format…
Zingzy Sep 5, 2025
e70d5f7
feat: Update API key creation limit to 5 per hour; enhance success mo…
Zingzy Sep 5, 2025
46d53c1
feat: Implement OAuth integration with Google and enhance user dashboard
Zingzy Sep 9, 2025
7d72e4c
fix: change cookie secure mode to Lax from Strict for smoother oAuth UX
Zingzy Sep 9, 2025
387c66f
Enhance user profile handling and UI improvements
Zingzy Sep 9, 2025
1b19093
feat: Enhance authentication modal and error handling; update navbar …
Zingzy Sep 9, 2025
762766a
feat: Implement comprehensive password validation and strength indica…
Zingzy Sep 9, 2025
6979a84
feat: Add GitHub OAuth integration and update UI for account linking
Zingzy Sep 10, 2025
4df2b7d
feat: Implement Discord OAuth login and account linking functionality
Zingzy Sep 10, 2025
844a806
feat: Add profile picture selection and update functionality in settings
Zingzy Sep 10, 2025
f8d6a5b
feat: Enhance OAuth redirect URL generation with environment variable…
Zingzy Sep 11, 2025
44b235c
feat: Update Docker configuration for MongoDB and Redis integration, …
Zingzy Sep 14, 2025
bcae06b
refactor: unify redirector error handling with RedirectorError hierarchy
Zingzy Oct 21, 2025
6438afe
feat: require OAuth provider email to match account before linking
Zingzy Nov 6, 2025
3af058f
docs: update humans.txt
Zingzy Nov 6, 2025
e504536
style(oauth): add trailing commas to email-mismatch response dicts fo…
Zingzy Nov 6, 2025
160bf17
style(dashboard): improve mobile responsiveness and overflow for keys…
Zingzy Nov 6, 2025
cee15a0
refactor(dashboard): optimize the dashboard for mobile devices; stan…
Zingzy Nov 6, 2025
deeac79
feat(stats): add timezone support for output formatting; update API a…
Zingzy Nov 8, 2025
ab8dd7e
feat(stats): update stats API to remove url_id scope; enhance filters…
Zingzy Nov 8, 2025
3ee57db
feat(limiter): implement rate limiting for API endpoints; add key fun…
Zingzy Nov 8, 2025
1dbfa26
feat(keys): add loading spinner and improve key creation error handli…
Zingzy Nov 8, 2025
31a6b29
refactor(dashboard): format rate limit decorator for consistency; upd…
Zingzy Nov 8, 2025
e5dee69
fix(auth_modal): adjust modal width for improved mobile responsivenes…
Zingzy Nov 8, 2025
f7aac47
Merge branch 'main' into login-system
Zingzy Nov 10, 2025
beae1d8
chore(workflows): update actions/checkout and actions/setup-python to…
Zingzy Nov 10, 2025
05641a8
feat(auth): handle duplicate email registration error; return appropr…
Zingzy Nov 10, 2025
47ca173
Refactor code structure for improved readability and maintainability
Zingzy Nov 10, 2025
a73db48
fix(auth_redirects): add missing line breaks for improved readability…
Zingzy Nov 10, 2025
8e074e9
feat(branding): update logo images and adjust navbar/sidebar referenc…
Zingzy Nov 10, 2025
eb4cce7
fix(api): correct redirect URL in api_route function
Zingzy Nov 10, 2025
95fc343
feat(api): enhance API documentation and add new endpoints for managi…
Zingzy Nov 10, 2025
ca63044
feat(export): add export functionality for URL click statistics in mu…
Zingzy Nov 11, 2025
0417ad7
feat(export): implement export functionality with dropdown for multip…
Zingzy Nov 11, 2025
97a5c39
feat(billing): add billing page with subscription details and styles;…
Zingzy Nov 11, 2025
dffb3af
feat(sentry): integrate Sentry for error tracking and performance mon…
Zingzy Nov 11, 2025
1b5f6bd
feat(logging): Implement structured logging across the application
Zingzy Nov 11, 2025
2fb50b2
refactor: remove unused imports from limiter, redirector, log_context…
Zingzy Nov 11, 2025
56eea78
chore: remove logging implementation plan document
Zingzy Nov 11, 2025
3273286
feat(metrics): enhance metrics endpoint to aggregate data from v1 and…
Zingzy Nov 11, 2025
fb1acf2
feat(navbar): enhance mobile and desktop navigation with GitHub stars…
Zingzy Nov 15, 2025
7249d9b
feat: Implement email verification and password reset functionality
Zingzy Nov 15, 2025
08b3e4a
Add email templates for verification and welcome messages, and create…
Zingzy Nov 15, 2025
6dbee0a
Lint using ruff
Zingzy Nov 15, 2025
238afdd
feat: Enhance configuration and documentation, improve error handling…
Zingzy Nov 16, 2025
604873e
fix(report): improve readability of URL existence check in report fun…
Zingzy Nov 16, 2025
3c473d0
feat(auth): add legal notice to authentication modal with links to Te…
Zingzy Nov 16, 2025
f221f5b
Add V2 announcement modal and associated assets
Zingzy Nov 18, 2025
6e9a4ce
feat(v2-announcement): add new 3D icons for features and update emoji…
Zingzy Nov 18, 2025
39fa849
feat(preload): add image preloading for feature tooltips and improve …
Zingzy Nov 18, 2025
5ffea41
fix(datetime): handle timezone conversion for datetime parsing and fo…
Zingzy Nov 18, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 95 additions & 3 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,104 @@ REDIS_URI="redis://localhost:6379"
REDIS_URI_DEV="redis://localhost:6379"
REDIS_TTL_SECONDS=3600 # 1 hour

# Flash configs
SECRET_KEY=""
# Sentry configuration (error tracking & performance monitoring)
SENTRY_DSN="" # Leave empty to disable Sentry
SENTRY_SEND_PII="false" # Send user emails/IPs (consider GDPR implications)
SENTRY_TRACES_SAMPLE_RATE=0.1 # % of transactions to capture (1.0 in dev, 0.05-0.1 in prod to reduce costs)
SENTRY_PROFILE_SAMPLE_RATE=0.05 # % of profiling sessions to capture (1.0 in dev, 0.01-0.05 in prod, very expensive)

# Flask configs
FLASK_SECRET_KEY="" # To generate: import os; print(os.urandom(32))
HOST_URI="127.0.0.1:8000"
SHORTEN_API_RATE_LIMIT_PER_HOUR=100
ENV="development" # change to "production" in production

# Logging Configuration
LOG_LEVEL=DEBUG # DEBUG, INFO, WARNING, ERROR, CRITICAL
LOG_FORMAT=console # json (prod) or console (dev)

# Sampling Rates (0.0 to 1.0)
SAMPLE_RATE_REDIRECT=0.05 # 5% of URL redirects
SAMPLE_RATE_STATS=0.20 # 20% of stats queries
SAMPLE_RATE_CACHE=0.01 # 1% of cache operations
SAMPLE_RATE_EXPORT=0.80 # 80% of exports

# Configs for the contact and report forms
CONTACT_WEBHOOK=""
URL_REPORT_WEBHOOK=""
HCAPTCHA_SECRET=""
HCAPTCHA_SECRET=""

# JWT configs
JWT_ISSUER=
JWT_AUDIENCE=
ACCESS_TOKEN_TTL_SECONDS=3600
REFRESH_TOKEN_TTL_SECONDS=2592000
COOKIE_SECURE="false" # false: for local dev, true: for production
JWT_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n.....\n-----END PRIVATE KEY-----"
JWT_PUBLIC_KEY="-----BEGIN PUBLIC KEY-----\n.....\n-----END PUBLIC KEY-----"
JWT_SECRET=""

# To generate these private key run this commands:
# openssl genpkey -algorithm RSA -pkeyopt rsa_keygen_bits:2048 -out jwt_private_key.pem

# for public key:
# openssl rsa -pubout -in jwt_private_key.pem -out jwt_public_key.pem

# for JWT_SECRET (if not using RSA keys):
# import os; print(os.urandom(32).hex())
# Use JWT_SECRET only if you are not using RSA keys (JWT_PRIVATE_KEY and JWT_PUBLIC_KEY)

# OAuth configs

# Google OAuth
# How to generate these keys:
# 1. Go to https://console.cloud.google.com/apis/credentials
# 2. Create a new project (if you don't have one)
# 3. Enable the Google+ API
# 4. Configure OAuth consent screen (make sure to add http://localhost:8000 and http://127.0.0.1:8000)
# 5. Create OAuth 2.0 Client IDs and get the client ID and client secret
# 6. Set the authorized redirect URIs / Redirect URIs to:
# http://localhost:8000/oauth/google/callback (for local dev)
# http://127.0.0.1:8000/oauth/google/callback (for local dev)
# http://your-production-domain.com/oauth/google/callback (for production)
GOOGLE_OAUTH_CLIENT_ID=""
GOOGLE_OAUTH_CLIENT_SECRET=""
GOOGLE_OAUTH_REDIRECT_URI="http://127.0.0.1:8000/oauth/google/callback"

# GitHub OAuth
# How to generate these keys:
# 1. Go to https://github.com/settings/developers
# 2. Create a new OAuth App (Not GitHub App !important)
# 3. Set the homepage URL to http://127.0.0.1:8000 or http://localhost:8000 for local dev
# 4. Set the authorization callback URI to http://127.0.0.1:8000/oauth/github/callback
# For production, set it to http://your-production-domain.com/oauth/github/callback
# 5. Make sure, where this app can be installed, "Any account" is selected
# 6. click on "Generate a new Client Secret" to get the client secret
GITHUB_OAUTH_CLIENT_ID=""
GITHUB_OAUTH_CLIENT_SECRET=""
GITHUB_OAUTH_REDIRECT_URI="http://127.0.0.1:8000/oauth/github/callback"


# Discord OAuth
# How to generate these keys:
# 1. Go to https://discord.com/developers/applications
# 2. Create a new application
# 3. Go to OAuth2 section and add a redirect URI:
# http://localhost:8000/oauth/discord/callback (for local dev)
# http://your-production-domain.com/oauth/discord/callback (for production)
# 4. In the scopes section, select "identify" and "email"
DISCORD_OAUTH_CLIENT_ID=""
DISCORD_OAUTH_CLIENT_SECRET=""
DISCORD_OAUTH_REDIRECT_URI="http://127.0.0.1:8000/oauth/discord/callback"

# ZeptoMail Configuration (for transactional emails)
# How to get these credentials:
# 1. Sign up at https://www.zoho.com/zeptomail/
# 2. Add and verify your domain (DKIM + CNAME records)
# 3. Create a Mail Agent
# 4. Go to SMTP/API section and copy your Send Mail Token
# 5. Set ZEPTO_API_TOKEN to the token value
ZEPTO_API_TOKEN=""
ZEPTO_FROM_EMAIL="noreply@your-domain.com"
ZEPTO_FROM_NAME="Your App Name"
APP_URL="http://127.0.0.1:8000"
4 changes: 2 additions & 2 deletions .github/workflows/api_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up Python
uses: actions/setup-python@v5
uses: actions/setup-python@v6
with:
python-version: 3.12

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/github-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Check Code Formatting
on:
push:
branches:
- main
- '*'
paths-ignore:
- '**/*.md'
- '**/*.rst'
Expand All @@ -21,10 +21,10 @@ jobs:

steps:
- name: Checkout Repository
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up Python
uses: actions/setup-python@v5
uses: actions/setup-python@v6
with:
python-version: 3.12

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/minify.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: check out the repository
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: replace js and css files with minified ones
uses: nizarmah/auto-minify@v3
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ celerybeat.pid

# Environments
.env
.env.staging
.venv
env/
venv/
Expand Down Expand Up @@ -183,4 +184,6 @@ todo.md

# Local API Testings
k6-tests/
local_test_db/
local_test_db/

.DS_Store
54 changes: 47 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,23 @@

# ⚑ Introduction

**spoo.me** is a free, open-source service for shortening URLs. It offers URL statistics, a free API, and customization options. You can create custom `slugs`, add `password protection`, and manage `link lifespans`.
**spoo.me** is a free, open-source service for shortening URLs. It offers comprehensive URL statistics, a free API, and extensive customization options. You can create and manage your URLs, generate API keys, create custom `slugs`, add `password protection`, and manage `link lifespans`.

# πŸ”₯ Features

- `Custom Slugs` - Create custom slugs for your URLs 🎯
- `Emoji Slugs` - Use emojis as slugs for your URLs πŸ˜ƒ
- `Password Protection` - Protect your URLs with a password πŸ”’
- `Link Max Clicks` - Set a maximum number of clicks for your URLs πŸ“ˆ
- `URL Statistics` - View detailed statistics for your URLs πŸ“Š
- `URL Statistics` - View detailed statistics for your URLs with advanced analytics πŸ“Š
- `BOT Tracking` - Track bot clicks on your URLs πŸ€–
- `API` - A free and open-sourced API for URL shortening and statistics πŸ› οΈ
- `Export Click Data` - Export click data as a CSV, JSON, XLSX, or XML file πŸ“€
- `Dashboard` - Manage all your URLs and view analytics in one place πŸ“±
- `API Keys` - Generate API keys for programmatic access with rate limiting πŸ”‘
- `Open Source` - spoo.me is open-sourced and free to use πŸ“–
- `Absolutely Free` - No hidden costs, no premium plans, no limitations πŸ’Έ
- `No Registration` - No need to register an account to use spoo.me πŸ“
- `No Registration Required` - Create short URLs without an account πŸ“
- `Self Hosting` - You can host spoo.me on your own server 🏠

# πŸ“Œ Endpoints
Expand Down Expand Up @@ -107,11 +109,30 @@ mv .env.example .env
MONGODB_URI=<your_MONGODB_URI>
CONTACT_WEBHOOK=<valid_webhook_URI>
URL_REPORT_WEBHOOK=<valid_webhook_URI>

# OAuth Configuration (Optional - for social login features)
GOOGLE_CLIENT_ID=<your_google_client_id>
GOOGLE_CLIENT_SECRET=<your_google_client_secret>
GITHUB_CLIENT_ID=<your_github_client_id>
GITHUB_CLIENT_SECRET=<your_github_client_secret>
DISCORD_CLIENT_ID=<your_discord_client_id>
DISCORD_CLIENT_SECRET=<your_discord_client_secret>

# JWT Secret Keys (Required for authentication)
JWT_SECRET_KEY=<your_jwt_secret_key>
JWT_REFRESH_SECRET_KEY=<your_jwt_refresh_secret_key>

# Email Configuration (Optional - for email verification)
ZOHO_MAIL_USERNAME=<your_email_address>
ZOHO_MAIL_PASSWORD=<your_email_password>
```

> [!NOTE]
> With this method, you can either use a cloud service like [MongoDB Atlas](https://www.mongodb.com/cloud/atlas) to store the data remotely or you can use a local MongoDB instance.
> If you want to use a local MongoDB instance, your MongoDB URI would be `mongodb://localhost:27017/`.
> - OAuth credentials are optional. Users can still register with email/password if OAuth is not configured.
> - JWT secret keys should be long, random strings. You can generate them using `openssl rand -hex 32`.
> - Email configuration is optional but recommended for email verification features.
> - With this method, you can either use a cloud service like [MongoDB Atlas](https://www.mongodb.com/cloud/atlas) to store the data remotely or you can use a local MongoDB instance.
> - If you want to use a local MongoDB instance, your MongoDB URI would be `mongodb://localhost:27017/`.

### πŸš€ Starting the server

Expand Down Expand Up @@ -165,10 +186,29 @@ mv .env.example .env
MONGODB_URI=<your_MONGODB_URI>
CONTACT_WEBHOOK=<valid_webhook_URI>
URL_REPORT_WEBHOOK=<valid_webhook_URI>

# OAuth Configuration (Optional - for social login features)
GOOGLE_CLIENT_ID=<your_google_client_id>
GOOGLE_CLIENT_SECRET=<your_google_client_secret>
GITHUB_CLIENT_ID=<your_github_client_id>
GITHUB_CLIENT_SECRET=<your_github_client_secret>
DISCORD_CLIENT_ID=<your_discord_client_id>
DISCORD_CLIENT_SECRET=<your_discord_client_secret>

# JWT Secret Keys (Required for authentication)
JWT_SECRET_KEY=<your_jwt_secret_key>
JWT_REFRESH_SECRET_KEY=<your_jwt_refresh_secret_key>

# Email Configuration (Optional - for email verification)
ZOHO_MAIL_USERNAME=<your_email_address>
ZOHO_MAIL_PASSWORD=<your_email_password>
```

> [!NOTE]
> If you installed MongoDB locally, your MongoDB URI would be `mongodb://localhost:27017/` or if you are using MongoDB Atlas, you can find your MongoDB URI in the **Connect** tab of your cluster.
> - OAuth credentials are optional. Users can still register with email/password if OAuth is not configured.
> - JWT secret keys should be long, random strings. You can generate them using `openssl rand -hex 32`.
> - Email configuration is optional but recommended for email verification features.
> - If you installed MongoDB locally, your MongoDB URI would be `mongodb://localhost:27017/` or if you are using MongoDB Atlas, you can find your MongoDB URI in the **Connect** tab of your cluster.

### πŸš€ Starting the server

Expand Down Expand Up @@ -226,7 +266,7 @@ Open your browser and go to `http://localhost:8000` to access the **spoo.me** UR
<h6 align="center">
<img src="https://spoo.me/static/images/favicon.png" height=30 title="Spoo.me Copyright">
<br>
Β© spoo.me . 2024
Β© spoo.me . 2025

All Rights Reserved</h6>

Expand Down
2 changes: 2 additions & 0 deletions api/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Namespace for API versions

13 changes: 13 additions & 0 deletions api/v1/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from flask import Blueprint


api_v1 = Blueprint("api_v1", __name__, url_prefix="/api/v1")


# Import endpoints to register their routes on api_v1
from . import shorten # noqa: E402,F401
from . import keys # noqa: E402,F401
from . import urls # noqa: E402,F401
from . import management # noqa: E402,F401
from . import stats # noqa: E402,F401
from . import exports # noqa: E402,F401
Loading
Loading