Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

⚡ Ultra-fast, infinite cloud storage using Telegram infrastructure & Edge Redirection. Supports Images, GIFs & Videos with a Bot integration, Developer API, and Premium Glassmorphic UI

License

Notifications You must be signed in to change notification settings

GeekLuffy/PixEdge

Repository files navigation

⚡ PixEdge: Ultra-Fast Edge Media Hosting

Next.js Upstash Telegram License: MIT

PixEdge is a professional-grade, open-source image hosting platform designed for speed and infinite scalability. It leverages the Telegram Bot API as a decentralized storage backend and Upstash Redis for high-performance metadata management, delivering Media directly through edge redirection.


🚀 Key Features

  • 📦 Messaging-Backbone Storage: Unlimited, free, and decentralized storage powered by Telegram infrastructure.
  • 🏎️ Edge Content Delivery: Uses high-speed redirection (302) to minimize server bandwidth and maximize delivery speed.
  • 🛠️ Developer-First API: Fully versioned REST API (/api/v1) for programmatic uploads and metadata retrieval.
  • 💎 Premium UX/UI: A stunning, glassmorphic dark-mode interface built with Framer Motion and Outfit typography.
  • 🔗 Custom Vanity URLs: Support for custom file names and human-readable slugs.
  • 📊 Real-time Analytics: Built-in view counters and metadata tracking (size, format, timestamp).
  • 📱 QR Integration: Instant QR code generation for every uploaded asset.

🛠️ Tech Stack


🔌 Developer API (v1)

PixEdge is built with a developer-first approach. You can programmatically upload images and retrieve metadata using our versioned REST API.

1. Upload Media

Endpoint: POST /api/v1/upload
Content-Type: multipart/form-data

Parameter Type Required Description
file File Yes The image file to upload.
customId String No Custom vanity slug for the link.

Example Request (cURL):

curl -X POST https://your-pixedge.com/api/v1/upload \
 -F "file=@/path/to/image.jpg" \
 -F "customId=my-awesome-link"

2. Get Image Metadata

Endpoint: GET /api/v1/info/[id]

Example Response:

{
 "success": true,
 "data": {
 "id": "my-awesome-link",
 "url": "https://pixedge.link/i/my-awesome-link",
 "views": 42,
 "created_at": 1705500000000,
 "metadata": {
 "size": 102400,
 "type": "image/jpeg"
 }
 }
}

🤝 Open Source & Contributions

PixEdge is Open Source and built for the community! We are actively looking for collaborators and contributors to make this the ultimate image hosting solution.

How to Collaborate:

  1. Fork the repository and experiment with new features.
  2. Open an Issue if you find bugs or have feature requests.
  3. Submit Pull Requests for UI improvements, API enhancements, or documentation.
  4. Join the Discussion: Help us shape the future of edge-based messaging storage.

⚙️ Getting Started

1. Prerequisites

  • A Telegram Bot Token (From @BotFather)
  • A Telegram Chat ID (Use @userinfobot)
  • An Upstash Redis account (Free tier is perfect)

2. Environment Variables

Create a .env.local file:

TELEGRAM_BOT_TOKEN=your_token
TELEGRAM_CHAT_ID=your_id
UPSTASH_REDIS_REST_URL=your_url
UPSTASH_REDIS_REST_TOKEN=your_token
NEXT_PUBLIC_BASE_URL=https://your-deployment.com

3. One-Click Deploy

Deploy with Vercel


🤖 Telegram Bot Integration

PixEdge includes a built-in Telegram Bot for direct uploads from your messaging app.

Setting up the Webhook

Once you deploy PixEdge to Vercel (or any public URL), you must link your bot to the webhook endpoint. Visit the following URL in your browser:

https://api.telegram.org/bot<YOUR_BOT_TOKEN>/setWebhook?url=https://your-domain.com/api/webhook/telegram

Bot Commands

  • /start : Show the welcome message.
  • /upload or /tgm : Upload an image.
  • /help : Shows the instructions.

Features

  • Direct Upload: Send any Media or File (as image/video) to the bot for an instant link.
  • Reply to Upload: Reply to any existing image in a chat with /upload or /tgm to host it on PixEdge.
  • DB Tracking: Every upload is forwarded to your storage channel with a caption identifying the user (Name + ID or @Username).

📖 Project Structure & Architecture

graph LR
 User --> API[Next.js API]
 API --> Redis[Upstash Redis]
 API --> Telegram[Telegram CDN]
 Redis -- "Metadata" --> API
 Telegram -- "File ID" --> API
Loading

telegram-storage image-hosting cdn edge-computing telegraph upstash nextjs redis-database open-source serverless fast-upload decentralized-storage developer-api


🌐 Community & Support

Stay updated with the latest features and get support for PixEdge:


📜 License

Distributed under the MIT License. Feel free to use, modify, and distribute as you wish!


Made with ❤️ by Geekluffy

About

⚡ Ultra-fast, infinite cloud storage using Telegram infrastructure & Edge Redirection. Supports Images, GIFs & Videos with a Bot integration, Developer API, and Premium Glassmorphic UI

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /