PawchiveAPI

The `PawchiveAPI` class provides a simple and efficient way to interact with the Pawchive API.

These are versions of this script where the code was updated. Show all versions.

  • v1.0.4a 14. 08. 2026
  • v1.0.4 14. 08. 2026
  • v1.0.4 14. 08. 2026

    Version 1.0.4

    • CORS Policy Bypass (GM_xmlhttpRequest): Migrated from standard fetch() to GM_xmlhttpRequest alongside the @connect pawchive.pw permission to successfully bypass CORS restrictions and allow seamless cross-origin data fetching.
    • UnsafeWindow Support: Integrated @grant unsafeWindow and implemented explicit exports to both unsafeWindow and window, ensuring stable global accessibility and smooth debugging via the browser console within the Tampermonkey sandbox.
    • Smart Response Parser: Added an automated response detection mechanism that parses JSON when available while gracefully falling back to plain text (such as raw string responses like "custom"), eliminating unexpected parsing errors.
  • v1.0.1 14. 08. 2026

    Version 1.0.1

    • Global Scope Export: Added explicit exports to globalThis, window.PawchiveAPI, and window.pawchiveAPI to ensure the class can be accessed seamlessly across different scopes.
    • Improved Compatibility: Full support for importing via Tampermonkey @require directives or dynamic script loaders without scope isolation blocks.
    • IIFE Refactoring: Removed the inner IIFE block structure that previously trapped the class definition, allowing direct global instantiation.
    • Bilingual Documentation: Enhanced code comments with clear English and Thai descriptions for easier maintenance and development.
  • v1.0.0 14. 08. 2026