LinkSwift — Multi-cloud direct-link fetcher and download helper
LinkSwift is a userscript that fetches direct cloud links via public APIs and integrates multiple downloaders, suited for advanced users needing cross-cloud bulk downloads.
GitHub hmjz100/LinkSwift Updated 2025-11-03 Branch main Stars 8.5K Forks 408
JavaScript userscript cloud storage download tool multi-cloud direct links download manager integration

💡 Deep Analysis

6
What concrete pain points in cloud drive downloads does LinkSwift solve and how does it implement these features?

Core Analysis

Project Positioning: LinkSwift aims to unify download direct-link retrieval across multiple cloud drives in the browser and enable one-click push to external downloaders, streamlining bulk/folder download workflows and improving web-based download efficiency.

Technical Analysis

  • Implementation: Implemented as a userscript (Tampermonkey/GreasyFork) injecting UI and logic at document-start. It uses per-provider adapters to parse page context and call official public APIs (e.g., AccessToken-based) to obtain direct links.
  • Advantages: Using official APIs reduces reverse-engineering risk; light front-end deployment allows fast patches for provider changes; supports multiple downloader protocols (RPC/HTTP/Blob/iframe) for high compatibility.
  • Feature Coverage: One-click/bulk copy of links, folder download support (e.g., Baidu), push to Aria2/BitComet/IDM/AB Download Manager, UI theming and dark mode.

Practical Recommendations

  1. Install Source: Use the README-recommended official sources (GitHub/Gitee/OpenUserJS/ScriptCat) to get timely updates and fixes.
  2. Auth Management: Prefer official auth flows (AccessToken); when encountering 9019 errors or link failures, refresh authorization on the provider page.
  3. Test Before Push: Test RPC/auth in settings to avoid duplicate tasks or failed pushes.

Caveats

  • LinkSwift does not bypass provider rate limits or paid restrictions; any unrestricted links are due to provider policy changes.
  • The tool depends on provider APIs and page structure—provider updates may temporarily break features until patched.

Important Notice: Verify cloud provider terms before large-scale automated downloads to avoid misuse.

Summary: LinkSwift effectively addresses the browser-based difficulty of obtaining direct links and bulk/push operations, well-suited for advanced users leveraging external downloaders.

85.0%
Why is LinkSwift implemented as a userscript (Tampermonkey) instead of a browser extension or standalone app? What are the pros and cons of this architecture?

Core Analysis

Design Choice: LinkSwift is implemented as a userscript (Tampermonkey/GreasyFork) rather than a browser extension or standalone app, primarily for rapid iteration, low deployment friction, and cross-browser compatibility.

Technical Features and Advantages

  • Fast publishing and fixes: Userscripts bypass extension store review cycles, enabling quick patches when provider pages/APIs change (as indicated by frequent changelog entries).
  • Lightweight and portable: A single .user.js file can be loaded by multiple script managers on major desktop browsers, lowering deployment cost.
  • Provider-adapter design: Per-provider adapters allow independent fixes for a provider without large refactors.

Limitations and Risks

  • Limited permissions: Userscripts rely on the script manager’s permissions and cannot access some low-level browser APIs or system resources like a full extension could.
  • Update & trust concerns: Users must install from trusted sources; third-party distributions may introduce risks. Enterprise/compliance scenarios may not accept scripts without clear licensing.
  • Long-term stability & distribution: Extensions benefit from store signing/versioning; userscripts rely on the maintainer and mirror services (ghproxy/jsdelivr) for consistent distribution.

Practical Advice

  1. For individual/advanced users who want quick access and accept short maintenance windows, a userscript is appropriate.
  2. For stricter permission needs, enterprise deployment, or longer-term stability, consider porting critical components into a browser extension or background service, reusing the provider-adapter logic.

Important Notice: When using userscripts, install from README-recommended sources and monitor changelogs to reduce disruption risk.

Summary: The userscript approach gives LinkSwift speed and low friction but has foreseeable limits in permission depth, compliance, and enterprise distribution.

85.0%
What are the security and compliance implications of LinkSwift switching from BDUSS to AccessToken, and what should users be aware of?

Core Analysis

Core Issue: LinkSwift moved from BDUSS to AccessToken, an important change that improves security and compatibility, but users must still be cautious about practical implications.

Technical Analysis

  • Why it’s safer: BDUSS are often long-lived cookie credentials with high risk if leaked. AccessTokens are typically short-lived and refreshed through official flows, aligning with least-privilege and ephemeral credential best practices.
  • Compliance benefits: Using official auth flows and public APIs helps avoid legal issues associated with reverse-engineering private endpoints.
  • Residual risks: The script operates in the browser context; if the script or its distribution source is compromised, tokens could still be exposed. Also, RPC/auth for downloaders must be securely stored.

Practical Recommendations

  1. Trusted sources: Install only from README-recommended official sources and monitor release notes for changes.
  2. Refresh auth: If direct-link retrieval fails (e.g., error 9019), refresh authorization on the provider page to renew AccessToken.
  3. Secure RPC tokens: Use minimum privilege tokens for Aria2/other RPC and avoid exposing full credentials in public environments.

Caveats

  • Although LinkSwift uses public APIs, it runs in the browser and local tokens can still be at risk if installed from untrusted mirrors.
  • In enterprise/compliance scenarios, the lack of a clear license (license Unknown) should be evaluated for legal risk.

Important Notice: Do not install userscripts from untrusted mirrors to prevent token or script tampering.

Summary: Moving to AccessToken is a meaningful security improvement, but proper installation and credential management practices are required to mitigate remaining risks.

85.0%
What common issues arise when pushing files or folders from cloud drives to Aria2 and similar downloaders, and how to troubleshoot and optimize the workflow?

Core Analysis

Core Issue: When pushing links from the browser to Aria2/IDM, the most common issues arise from RPC configuration/authentication errors, script duplicate injections causing duplicate tasks, and invalid direct links or expired authorization.

Technical Analysis

  • RPC/Auth problems: Aria2 requires RPC enabled and CORS/valid token; otherwise connections fail with 401/403. The README’s RPC test feature indicates these are common.
  • Duplicate sends/injection conflicts: The changelog repeatedly references fixes for duplicated sends, often caused by multiple bindings in the script lifecycle.
  • Direct-link or auth expiry: Expired AccessTokens prevent valid link retrieval, causing pushed tasks to fail or be empty.

Troubleshooting Steps (Practical)

  1. Test RPC: Use the script’s RPC test in settings to verify URL, port and token respond correctly.
  2. Check console & logs: Look for CORS, 401, or 500 errors that point to auth or cross-origin issues.
  3. Validate direct links: Copy a link and test it in a new tab or with curl to ensure accessibility before push.
  4. Check duplicate bindings: If duplicates occur, update the script or adjust injection settings to avoid multiple bindings.

Optimization Tips

  1. Enable dedup/idempotent push logic if supported, or dedupe on the downloader side.
  2. Use minimal-privilege RPC tokens and restrict IPs when possible.
  3. Push large batches in segments to avoid transient auth/connection overloads.
  4. Keep the script updated to receive fixes for repeated-sends and API changes.

Important Notice: Testing and saving a valid RPC/auth configuration in settings prevents many failed or duplicate tasks.

Summary: Systematically verify RPC, direct-link validity, and script injection state; use dedup and batching to mitigate push failures and duplicates.

85.0%
What are LinkSwift's applicability and limitations for bulk/folder downloads, and what provider-specific differences should users be aware of?

Core Analysis

Core Issue: LinkSwift’s ability to handle bulk/folder downloads depends on provider API capabilities, user permissions, and downloader throughput limits.

Technical Analysis

  • API dependency: If a provider exposes folder listing or bulk direct-link endpoints (e.g., Baidu to some extent), LinkSwift can aggregate links for batch copy/push. If not, the script cannot retrieve restricted file lists.
  • Permission & share limits: Private files or unapproved share pages may not allow complete link retrieval via AccessToken, resulting in partial lists.
  • Performance bounds: Pushing thousands of small files or many large files at once may trigger provider rate limits or downloader concurrency bottlenecks, leading to failures or throttling.

Usage Recommendations

  1. Confirm permissions: Ensure you have access to the full folder listing before attempting batch operations.
  2. Batching: For many files, push in batches (e.g., 50–200 links per batch) to reduce concurrent load and failure rates.
  3. Downloader concurrency control: Tune Aria2/other downloader concurrency/connection settings to avoid provider throttling or anti-abuse triggers.
  4. Keep script updated: Provider API changes can break folder enumeration—update promptly.

Caveats

  • LinkSwift does not bypass provider quotas or paid restrictions; if the provider limits folder/parallel downloads, the tool cannot circumvent this.
  • For providers lacking folder enumeration, prepare a download manifest in the provider UI or use the official client instead.

Important Notice: Test with small batches first to verify link completeness and downloader settings before large-scale jobs.

Summary: LinkSwift is effective for bulk downloads when provider APIs and permissions allow; where APIs or permissions are limited, use batching, concurrency control, or provider-side manifests to achieve reliable results.

85.0%
Installation and maintenance: How to choose installation sources, manage updates, and what are emergency steps when the script breaks?

Core Analysis

Core Issue: Script availability heavily depends on trusted installation sources and timely updates. Provider UI/API changes require rapid maintenance to keep functionality intact.

Technical Analysis

  • Multi-source publishing: The project is published on GitHub/Gitee/OpenUserJS/ScriptCat; README recommends official sources to ensure timely and complete updates.
  • Update cadence: Frequent changelog entries indicate that rapid patching is essential for stability.
  • Fallback/mirroring: Using ghproxy/jsdelivr mirrors can improve availability but requires attention to sync and security.

Practical Advice (Install & Maintain)

  1. Source choice: Prefer the official GitHub or Gitee repo, then OpenUserJS/ScriptCat. Avoid copying scripts from unknown third-party sites.
  2. Enable updates: Use automatic updates in your script manager or periodically check release notes; manually update for urgent fixes.
  3. Local backups: Keep local copies of stable script versions for rollback.
  4. Emergency steps when broken:
    - a. Switch to the official repo or a trusted mirror (ghproxy/jsdelivr);
    - b. Roll back to a local stable copy;
    - c. Collect console/network logs and open an Issue in the repo;
    - d. For critical work, temporarily use the official client or manually copy links as a fallback.

Caveats

  • Do not use unverified third-party bundles or mirrors—they may contain malicious changes.
  • In enterprise contexts, evaluate legal/compliance risks due to the unknown license.

Important Notice: Staying synced with the official repo and having rollback/mirroring procedures minimizes disruption when the script breaks.

Summary: Reliable installation sources and rapid update practices are essential to keep LinkSwift functional amid provider changes. Keep rollbacks and logs ready to accelerate fixes.

85.0%

✨ Highlights

  • Supports direct-link fetching for eight major cloud providers with UI enhancements
  • Relatively detailed changelog with frequent updates
  • Single maintainer and repository license not clearly declared
  • Heavily depends on cloud providers' public APIs; API/page changes can easily break functionality

🔧 Engineering

  • Fetches direct links via providers' public APIs, covering eight clouds including Baidu, Aliyun and Quark
  • Integrates download push (Aria2/BitComet/AB Download etc.) and supports copying/exporting links

⚠️ Risks

  • Repo metadata shows no contributors or releases and license is unspecified, introducing uncertainty for use and integration
  • Functionality depends on third-party APIs and page structures; provider policy or API changes can cause short-term breakage

👥 For who?

  • Targeted at advanced browser users and download enthusiasts familiar with Tampermonkey/Greasemonkey
  • Suitable for scenarios requiring cross-cloud bulk direct-link retrieval and integration with local/remote downloaders