{"id":30785209,"url":"https://github.com/codedealer/imgur-upload","last_synced_at":"2025-10-04T11:13:46.073Z","repository":{"id":310915892,"uuid":"1019788116","full_name":"codedealer/imgur-upload","owner":"codedealer","description":null,"archived":false,"fork":false,"pushed_at":"2025-08-28T23:09:58.000Z","size":138,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-05T11:45:46.649Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://imgur-upload-six.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codedealer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-14T21:54:54.000Z","updated_at":"2025-08-28T23:10:02.000Z","dependencies_parsed_at":"2025-08-21T02:35:10.455Z","dependency_job_id":"ed89a978-80d7-4c4d-8eb4-c95b95475097","html_url":"https://github.com/codedealer/imgur-upload","commit_stats":null,"previous_names":["codedealer/imgur-upload"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/codedealer/imgur-upload","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codedealer%2Fimgur-upload","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codedealer%2Fimgur-upload/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codedealer%2Fimgur-upload/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codedealer%2Fimgur-upload/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codedealer","download_url":"https://codeload.github.com/codedealer/imgur-upload/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codedealer%2Fimgur-upload/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278302563,"owners_count":25964527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-09-05T11:28:10.874Z","updated_at":"2025-10-04T11:13:46.068Z","avatar_url":"https://github.com/codedealer.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Imgur Upload Utility\n\nA command-line tool for uploading videos to Imgur and re-uploading from existing Imgur URLs.\n\n## Setup\n\n1. **IWhen `GC_PROXY` and `PROXY_SECRET` are set, all upload and delete requests will be routed through your secured proxy server.\n\n### Proxy Features\n\n- **Health check endpoint:** `GET /health`\n- **Upload proxy:** `POST /api/3/image` (with auth)\n- **Delete proxy:** `DELETE /api/3/image/[deleteHash]` (with auth)\n- **Request logging:** Tracks uploads and deletes with client ID\n- **Serverless auto-scaling:** Handles traffic spikes automatically\n- **Free tier friendly:** Generous usage limits, scales to zero when unusedendencies:**\n   ```bash\n   pnpm install\n   ```\n\n2. **Build the project:**\n   ```bash\n   pnpm run build\n   ```\n\n3. **Create desktop shortcuts (optional):**\n   ```bash\n   setup_shortcuts.bat\n   ```\n\n## Usage Methods\n\n### Method 1: Batch Files (Recommended)\n\n#### For uploading local files:\n- **Drag \u0026 Drop:** Drag video files onto `upload_files.bat`\n- **Command line:** `upload_files.bat video1.mp4 video2.mov metadata.json`\n\n#### For re-uploading from Imgur URLs:\n- **Interactive mode:** Double-click `reupload_files.bat` and paste URLs when prompted\n  - Paste multiple URLs separated by spaces or on separate lines\n  - Press Enter on an empty line to start processing\n- **Command line:** `reupload_files.bat https://imgur.com/abc123 https://i.imgur.com/def456.mp4`\n\n### Method 2: Direct Node.js\n\n```bash\n# Upload local files\npnpm start video1.mp4 video2.mov\n\n# Reupload from URLs\npnpm start https://imgur.com/abc123 https://i.imgur.com/def456.mp4\n```\n\n### Method 3: Development Mode\n\n```bash\n# Upload local files\npnpm dev video1.mp4 video2.mov\n\n# Reupload from URLs\npnpm dev https://imgur.com/abc123 https://i.imgur.com/def456.mp4\n```\n\n## Configuration\n\nThe application uses different environment files:\n\n- **Development:** `.env` (project root)\n- **Production:** `.env.production` → copied to `dist/.env` during build\n\n### Environment Variables\n\n```bash\nCLIENT_ID=your_imgur_client_id\nCLIENT_SECRET=your_imgur_client_secret\nUPLOAD_TIMEOUT=60000\nTEST_MODE=false\nVERIFY_UPLOAD=false\nMAX_FILE_SIZE_MB=200\nCONCURRENT_UPLOADS=1\nHTTPS_PROXY=http://127.0.0.1:8080  # Optional\nGC_PROXY=https://your-proxy-service.vercel.app  # Optional Vercel serverless proxy\nPROXY_SECRET=your_generated_secret_key  # Required when using GC_PROXY\n```\n\n## Vercel Serverless Proxy\n\nThis project includes a Vercel serverless proxy that can be deployed to handle API requests on your behalf. This is useful for:\n\n- Centralized API credential management\n- Request logging and monitoring\n- Avoiding direct API calls from your local machine\n- Secured access with authorization tokens\n- **Free deployment** with generous usage limits\n\n### Deployment Options\n\n#### Option 1: GitHub Actions (Recommended - No local tools required)\n\n1. **Fork this repository** to your GitHub account\n\n2. **Set up Vercel secrets** in your GitHub repository:\n   - Go to Settings → Secrets and variables → Actions\n   - Add `VERCEL_TOKEN` with your Vercel API token ([get it here](https://vercel.com/account/tokens))\n   - Add `VERCEL_ORG_ID` with your Vercel organization ID\n   - Add `VERCEL_PROJECT_ID` with your Vercel project ID (create project first on Vercel)\n\n3. **Deploy via GitHub Actions**:\n   - Go to Actions tab in your repository\n   - Run \"Deploy Imgur Proxy to Vercel\" workflow\n   - The workflow will auto-generate a proxy secret\n\n4. **Configure your client**:\n   ```bash\n   set GC_PROXY=https://your-project.vercel.app\n   set PROXY_SECRET=the_generated_secret_from_workflow\n   ```\n\n#### Option 2: Local Deployment (Requires Vercel CLI)\n\n1. **Install Vercel CLI:**\n   ```bash\n   npm install -g vercel\n   ```\n\n2. **Deploy the proxy:**\n   ```bash\n   cd proxy\n   vercel --prod\n   ```\n\n3. **Set environment variables:**\n   ```bash\n   vercel env add PROXY_SECRET production your_secret_here\n   ```\n\n4. **Configure your client:**\n   ```bash\n   export GC_PROXY=https://your-project.vercel.app\n   export PROXY_SECRET=your_proxy_secret\n   ```### Proxy Security\n\nThe proxy server uses an authorization token (`PROXY_SECRET`) to prevent unauthorized access:\n\n- **Auto-generated**: A random 64-character hex string is generated during deployment\n- **Custom**: You can provide your own secret during GitHub Actions deployment\n- **Required**: All requests to the proxy must include `X-Proxy-Auth` header with the secret\n\nWhen `GC_PROXY` and `PROXY_SECRET` are set, all upload and delete requests will be routed through your secured proxy server.\n\n### Proxy Features\n\n- **Health check endpoint:** `GET /health`\n- **Upload proxy:** `POST /3/image` (with auth)\n- **Delete proxy:** `DELETE /3/image/:deleteHash` (with auth)\n- **Request logging:** Tracks uploads and deletes with client ID\n- **Auto-scaling:** Handles traffic spikes automatically\n- **Low resource usage:** Only 256Mi RAM, scales to zero when unused## Features\n\n### Upload Mode\n- Upload local video files to Imgur\n- Support for metadata JSON files\n- Progress tracking with visual progress bars\n- Automatic file verification\n- Deletion management interface\n\n### Reupload Mode\n- Download videos from Imgur URLs\n- Re-upload to get new Imgur links\n- Support for both direct links (`i.imgur.com`) and post links (`imgur.com`)\n- Automatic format detection and fallback\n- Concurrent downloads with rate limiting\n\n## File Structure\n\n```\nimgur-upload/\n├── src/                    # TypeScript source code\n├── dist/                   # Compiled JavaScript + .env\n├── upload_files.bat        # Batch file for uploading\n├── reupload_files.bat      # Batch file for re-uploading\n├── setup_shortcuts.bat     # Creates desktop shortcuts\n├── .env                    # Development environment\n├── .env.production         # Production environment\n└── package.json\n```\n\n## Troubleshooting\n\n1. **\"Node.js not found\":** Install Node.js from https://nodejs.org/\n2. **\"dist/index.js not found\":** Run `pnpm run build`\n3. **\"dist/.env not found\":** Run `pnpm run build` (copies .env.production)\n4. **Rate limiting (429 errors):** Reduce `CONCURRENT_UPLOADS` or add delays\n\n## Building Binary\n\nTo create a standalone executable:\n\n```bash\npnpm run package\n```\n\nThis creates a binary in the `bin/` folder that doesn't require Node.js installation.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodedealer%2Fimgur-upload","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodedealer%2Fimgur-upload","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodedealer%2Fimgur-upload/lists"}