From 1af1c964f3fbfaaf236dbf98194988c58ead5e6f Mon Sep 17 00:00:00 2001 From: Hyo Date: Wed, 11 Feb 2026 16:59:57 +0900 Subject: [PATCH 1/6] docs: improve SEO, AEO, and introduction page SEO/AEO Improvements: - Add Schema.org JSON-LD structured data to SEO component - Add og:type, og:image, og:site_name, twitter:card meta tags - Add AI crawler guidance to robots.txt (GPTBot, Claude-Web, etc.) - Add llms.txt link references to index.html - Update sitemap.xml lastmod dates to 2026-02-11 - Expand keywords in index.html Introduction Page Enhancements: - Add compelling hero section with headline "Stop Rewriting IAP Code" - Add stats badges (4K+ Combined Stars, 5+ Framework Libraries) - Add CTA buttons (Get Started, View on GitHub) - Add key benefits cards (1x Learn Once, 0 Runtime Errors, 100% Platform Features) - Add visual problem section with color-coded pain point cards - Add solution section with feature grid and ecosystem diagram - Add supported platforms grid (iOS/macOS/Vision Pro, Android, Meta Quest) - Add implementations list with all 5 framework libraries - Remove duplicate "Why Teams Choose" section Home Page: - Update hero subtitle with clearer value proposition - Add matching stats badges Other Pages: - Add SEO component to 404 page - Improve keywords for tutorials, sponsors, languages pages - Add godot-iap to languages description Co-Authored-By: Claude Opus 4.5 --- packages/docs/index.html | 26 +- packages/docs/public/robots.txt | 17 +- packages/docs/public/sitemap.xml | 46 +- packages/docs/src/components/SEO.tsx | 48 +- packages/docs/src/pages/404.tsx | 26 +- .../docs/src/pages/docs/android-setup.tsx | 4 +- packages/docs/src/pages/docs/apis/index.tsx | 4 +- packages/docs/src/pages/docs/ecosystem.tsx | 3 +- packages/docs/src/pages/docs/errors.tsx | 4 +- packages/docs/src/pages/docs/events.tsx | 4 +- .../docs/src/pages/docs/horizon-setup.tsx | 4 +- packages/docs/src/pages/docs/types/index.tsx | 4 +- packages/docs/src/pages/home.tsx | 65 +- packages/docs/src/pages/introduction.tsx | 1030 ++++++++++++++--- packages/docs/src/pages/languages.tsx | 4 +- packages/docs/src/pages/sponsors.tsx | 3 +- packages/docs/src/pages/tutorials.tsx | 4 +- 17 files changed, 1102 insertions(+), 194 deletions(-) diff --git a/packages/docs/index.html b/packages/docs/index.html index e571854e..3275b3d3 100644 --- a/packages/docs/index.html +++ b/packages/docs/index.html @@ -10,7 +10,7 @@ OpenIAP - Unified Specification for In-App Purchases - + @@ -35,6 +35,10 @@ + + + + diff --git a/packages/docs/public/robots.txt b/packages/docs/public/robots.txt index f92e563a..d20157d0 100644 --- a/packages/docs/public/robots.txt +++ b/packages/docs/public/robots.txt @@ -1,4 +1,19 @@ User-agent: * Allow: / -Sitemap: https://openiap.dev/sitemap.xml \ No newline at end of file +Sitemap: https://openiap.dev/sitemap.xml + +# AI Assistants / LLM Crawlers +# Reference: https://llmstxt.org/ +User-agent: GPTBot +User-agent: ChatGPT-User +User-agent: Claude-Web +User-agent: Anthropic-AI +User-agent: PerplexityBot +User-agent: Google-Extended +Allow: /llms.txt +Allow: /llms-full.txt + +# LLM context files for AI assistants +# llms.txt: https://openiap.dev/llms.txt (concise overview) +# llms-full.txt: https://openiap.dev/llms-full.txt (detailed reference) \ No newline at end of file diff --git a/packages/docs/public/sitemap.xml b/packages/docs/public/sitemap.xml index 9dd1d9cd..83953621 100644 --- a/packages/docs/public/sitemap.xml +++ b/packages/docs/public/sitemap.xml @@ -2,31 +2,31 @@ https://openiap.dev/ - 2025-11-26 + 2026-02-11 weekly 1.0 https://openiap.dev/introduction - 2025-11-26 + 2026-02-11 weekly 0.9 https://openiap.dev/languages - 2025-11-26 + 2026-02-11 monthly 0.8 https://openiap.dev/tutorials - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/sponsors - 2025-11-26 + 2026-02-11 monthly 0.7 @@ -34,43 +34,43 @@ https://openiap.dev/docs/ecosystem - 2025-11-26 + 2026-02-11 weekly 0.9 https://openiap.dev/docs/lifecycle - 2025-11-26 + 2026-02-11 weekly 0.9 https://openiap.dev/docs/lifecycle/subscription - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/docs/types - 2025-11-26 + 2026-02-11 weekly 0.9 https://openiap.dev/docs/apis - 2025-11-26 + 2026-02-11 weekly 0.9 https://openiap.dev/docs/events - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/docs/errors - 2025-11-26 + 2026-02-11 monthly 0.7 @@ -78,19 +78,19 @@ https://openiap.dev/docs/ios-setup - 2025-11-26 + 2026-02-11 monthly 0.8 https://openiap.dev/docs/android-setup - 2025-11-26 + 2026-02-11 monthly 0.8 https://openiap.dev/docs/horizon-setup - 2025-11-26 + 2026-02-11 monthly 0.7 @@ -98,31 +98,31 @@ https://openiap.dev/docs/features/purchase - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/docs/features/subscription - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/docs/features/offer-code-redemption - 2025-11-26 + 2026-02-11 monthly 0.7 https://openiap.dev/docs/features/external-purchase - 2025-11-26 + 2026-02-11 weekly 0.8 https://openiap.dev/docs/features/subscription-upgrade-downgrade - 2025-11-26 + 2026-02-11 monthly 0.7 @@ -130,19 +130,19 @@ https://openiap.dev/docs/updates/announcements - 2025-11-26 + 2026-02-11 weekly 0.7 https://openiap.dev/docs/updates/notes - 2025-11-26 + 2026-02-11 weekly 0.7 https://openiap.dev/docs/updates/versions - 2025-11-26 + 2026-02-11 weekly 0.7 diff --git a/packages/docs/src/components/SEO.tsx b/packages/docs/src/components/SEO.tsx index cbaaa022..e1b8256b 100644 --- a/packages/docs/src/components/SEO.tsx +++ b/packages/docs/src/components/SEO.tsx @@ -5,17 +5,49 @@ interface SEOProps { description?: string; path?: string; keywords?: string; + type?: 'website' | 'article'; + image?: string; } const BASE_URL = 'https://openiap.dev'; const DEFAULT_TITLE = 'OpenIAP - Unified Specification for In-App Purchases'; const DEFAULT_DESCRIPTION = 'OpenIAP is a unified specification for in-app purchases across platforms, frameworks, and emerging technologies. Standardizing IAP implementations to reduce fragmentation.'; +const DEFAULT_IMAGE = '/og-image.png'; -function SEO({ title, description, path = '', keywords }: SEOProps) { +function SEO({ + title, + description, + path = '', + keywords, + type = 'website', + image, +}: SEOProps) { const pageTitle = title ? `${title} | OpenIAP` : DEFAULT_TITLE; const pageDescription = description || DEFAULT_DESCRIPTION; const canonicalUrl = `${BASE_URL}${path}`; + const imageUrl = `${BASE_URL}${image || DEFAULT_IMAGE}`; + + // Schema.org structured data for SoftwareApplication + const schemaOrg = { + '@context': 'https://schema.org', + '@type': 'SoftwareApplication', + name: 'OpenIAP', + description: pageDescription, + url: canonicalUrl, + applicationCategory: 'DeveloperApplication', + operatingSystem: 'iOS, Android, visionOS, Horizon OS', + offers: { + '@type': 'Offer', + price: '0', + priceCurrency: 'USD', + }, + author: { + '@type': 'Organization', + name: 'OpenIAP', + url: BASE_URL, + }, + }; return ( @@ -26,14 +58,22 @@ function SEO({ title, description, path = '', keywords }: SEOProps) { {/* Open Graph */} + + + {/* Twitter */} - - - + + + + + + + {/* Schema.org JSON-LD */} + ); } diff --git a/packages/docs/src/pages/404.tsx b/packages/docs/src/pages/404.tsx index 3f582c68..80929e22 100644 --- a/packages/docs/src/pages/404.tsx +++ b/packages/docs/src/pages/404.tsx @@ -1,6 +1,7 @@ import { Link } from 'react-router-dom'; import { Home, ArrowLeft } from 'lucide-react'; import { useEffect, useState } from 'react'; +import SEO from '../components/SEO'; export default function NotFound() { const [isDark, setIsDark] = useState(false); @@ -22,15 +23,21 @@ export default function NotFound() { }, []); return ( -
+ <> + +
+ ); } diff --git a/packages/docs/src/pages/docs/android-setup.tsx b/packages/docs/src/pages/docs/android-setup.tsx index 927ddd22..fd5dbce7 100644 --- a/packages/docs/src/pages/docs/android-setup.tsx +++ b/packages/docs/src/pages/docs/android-setup.tsx @@ -5,9 +5,9 @@ function AndroidSetup() {

Android Setup Guide

diff --git a/packages/docs/src/pages/docs/apis/index.tsx b/packages/docs/src/pages/docs/apis/index.tsx index 69751437..ad26903e 100644 --- a/packages/docs/src/pages/docs/apis/index.tsx +++ b/packages/docs/src/pages/docs/apis/index.tsx @@ -98,9 +98,9 @@ function APIsIndex() {

APIs

diff --git a/packages/docs/src/pages/docs/ecosystem.tsx b/packages/docs/src/pages/docs/ecosystem.tsx index 8590f12b..27c32161 100644 --- a/packages/docs/src/pages/docs/ecosystem.tsx +++ b/packages/docs/src/pages/docs/ecosystem.tsx @@ -10,8 +10,9 @@ function Ecosystem() {

Ecosystem

diff --git a/packages/docs/src/pages/docs/errors.tsx b/packages/docs/src/pages/docs/errors.tsx index 512d997f..567fdea7 100644 --- a/packages/docs/src/pages/docs/errors.tsx +++ b/packages/docs/src/pages/docs/errors.tsx @@ -12,9 +12,9 @@ function Errors() {

Error Codes

diff --git a/packages/docs/src/pages/docs/events.tsx b/packages/docs/src/pages/docs/events.tsx index bb7d4f0d..c7f7cf6c 100644 --- a/packages/docs/src/pages/docs/events.tsx +++ b/packages/docs/src/pages/docs/events.tsx @@ -12,9 +12,9 @@ function Events() {

Events

diff --git a/packages/docs/src/pages/docs/horizon-setup.tsx b/packages/docs/src/pages/docs/horizon-setup.tsx index b6d8c442..96c8fcde 100644 --- a/packages/docs/src/pages/docs/horizon-setup.tsx +++ b/packages/docs/src/pages/docs/horizon-setup.tsx @@ -6,9 +6,9 @@ function HorizonSetup() {

Horizon OS Setup Guide

diff --git a/packages/docs/src/pages/docs/types/index.tsx b/packages/docs/src/pages/docs/types/index.tsx index 74e392f9..03e9c464 100644 --- a/packages/docs/src/pages/docs/types/index.tsx +++ b/packages/docs/src/pages/docs/types/index.tsx @@ -231,9 +231,9 @@ function TypesIndex() {

- +

- Unifying fragmented IAP implementations across platforms, - frameworks, and emerging technologies + Stop rewriting IAP code for every platform. One API for iOS, + Android, Vision Pro, and Meta Quest.

+ {/* Quick Stats */} +
+ +
+ 4K+ +
+
+ Combined Stars +
+
+
+
+ 5+ +
+
+ Framework Libraries +
+
+
Get Started diff --git a/packages/docs/src/pages/introduction.tsx b/packages/docs/src/pages/introduction.tsx index 7e116300..e412f423 100644 --- a/packages/docs/src/pages/introduction.tsx +++ b/packages/docs/src/pages/introduction.tsx @@ -1,3 +1,4 @@ +import { Link } from 'react-router-dom'; import SEO from '../components/SEO'; function Introduction() { @@ -5,167 +6,928 @@ function Introduction() {
-

Introduction to OpenIAP

+ {/* Hero Section */} +
+

+ Stop Rewriting IAP Code +
+ + For Every Platform + +

+

+ OpenIAP is the unified specification for in-app + purchases. Write once, ship to iOS, Android, Vision Pro, and Meta + Quest with type-safe, consistent APIs. +

+ + {/* Quick Stats */} +
+ +
+ 4K+ +
+
+ Combined Stars +
+
+
+
+ 5+ +
+
+ Framework Libraries +
+
+
+ {/* CTA Buttons */} +
+ + Get Started + + + View on GitHub + +
+
+ + {/* Key Benefits - Visual Cards */}
-

What is OpenIAP?

-

- OpenIAP is an open specification that standardizes in-app purchase - implementations across diverse platforms and frameworks. As the IAP - ecosystem becomes increasingly fragmented with new platforms - (StoreKit 2, Android Billing v8, Vision Pro, Horizon OS) and - frameworks (React Native, Flutter, KMP), OpenIAP provides a unified - specification that reduces complexity and ensures consistency. -

+
+
+
+ 1x +
+

+ Learn Once +

+

+ Master one API instead of learning different patterns for iOS, + Android, and every framework +

+
+
+
+ 0 +
+

+ Runtime Errors +

+

+ Type-safe generated code catches mistakes at compile time, not + in production +

+
+
+
+ 100% +
+

+ Platform Features +

+

+ Full access to StoreKit 2 and Play Billing v8 - no features + hidden or abstracted away +

+
+
+ {/* Core Modules Visual */}
-

The Problem

-

- Every new platform and framework creates its own IAP implementation. - Library maintainers independently design APIs, leading to fragmented - specifications. Developers must learn different APIs for each - platform, increasing complexity and errors. As new technologies - emerge - XR platforms, cross-platform frameworks, and emerging - payment systems - this fragmentation only grows worse. -

+

Native Modules

- In the AI coding era, this fragmentation becomes even more - problematic. AI assistants struggle to generate consistent code when - every library has different patterns, making IAP implementation - unnecessarily complex and error-prone. + OpenIAP provides{' '} + production-ready native modules that power all + framework implementations. Built on{' '} + + StoreKit 2 + {' '} + and{' '} + + Play Billing v8 + + .

+
-

Our Solution

- -

Unified APIs

-

- OpenIAP defines standard methods like initConnection(),{' '} - fetchProducts(),requestPurchase(), and{' '} - finishTransaction() that work consistently across all - platforms. Library maintainers implement these standard APIs, - ensuring developers have a consistent experience. +

The IAP Fragmentation Problem

+
+

+ Every IAP library reinvents the wheel.{' '} + Different method names.{' '} + Different event patterns.{' '} + Different type definitions. Switching frameworks + means relearning everything. AI assistants can't help because no + two libraries work the same way. +

+
+
+
+ Wasted Time +

+ Learning new APIs for each framework +

+
+
+ Production Bugs +

+ Inconsistent type handling across platforms +

+
+
+ Duplicated Effort +

+ Maintainers solving same problems independently +

+
+
+

+ And it's getting worse. New platforms like{' '} + + Vision Pro + {' '} + and Horizon OS mean more APIs + to learn, more fragmentation to manage.

+
-

Standard Events

-

- Event handling is standardized with patterns like{' '} - purchaseUpdatedListener and - purchaseErrorListener. No more platform-specific event - names or handling patterns - just consistent, predictable events - across all implementations. +

+

The OpenIAP Solution

+

+ One specification. One API. Every platform.

-

Unified Types

-

- Common data structures like Product,{' '} - Purchase, and PurchaseError - are defined once and used everywhere. This ensures type safety and - reduces the cognitive load on developers switching between - platforms. -

-
+ {/* Ecosystem Diagram */} +
+ + OpenIAP Ecosystem - Native modules power framework implementations + +

+ View full ecosystem diagram → +

+
-
-

Why Now?

-
    -
  • - Platform Explosion: iOS StoreKit 2, Android - Billing v8, and new XR platforms are creating more fragmentation - than ever -
  • -
  • - Framework Diversity: React Native, Flutter, - Kotlin Multiplatform, and emerging frameworks each need IAP - support -
  • -
  • - AI Coding Era: Standardized APIs are crucial for - AI assistants to generate reliable, consistent IAP code -
  • -
  • - Developer Experience: Reducing cognitive load by - providing one specification to learn instead of dozens -
  • -
  • - Community Collaboration: Library maintainers can - focus on implementation quality rather than API design -
  • -
+ {/* Feature Grid */} +
+
+

+ Unified API +

+

+ Standard methods like{' '} + + initConnection() + + ,{' '} + + fetchProducts() + + , and{' '} + + requestPurchase() + {' '} + work identically everywhere. +

+
+ +
+

+ Generated Types +

+

+ From one GraphQL schema, generate native types for Swift, + Kotlin, TypeScript, Dart, and GDScript.{' '} + Download → +

+
+ +
+

+ Platform-Aware +

+

+ Clear naming:{' '} + + Product + {' '} + for shared,{' '} + + ProductIOS + + / + + ProductAndroid + {' '} + for platform-specific. +

+
+ +
+

+ AI-Ready +

+

+ Standardized APIs mean AI assistants generate reliable, + predictable IAP code across all frameworks. +

+
+
-

Who's Using OpenIAP?

-

- Leading IAP libraries are already implementing the OpenIAP - specification: -

-
+ + + 🤖 +
+ Android +
- flutter_inapp_purchase - - : - {' '} - Flutter implementation - -
  • - - +
  • + + + 🎮 +
    + Meta Quest +
    - kmp-iap - - : - {' '} - Kotlin Multiplatform implementation - - + Horizon OS +
    +
    + +
    +
    + +
    +

    Implementations

    - These libraries demonstrate that OpenIAP's unified approach works in - practice, providing consistent APIs while leveraging - platform-specific capabilities. + Production-ready libraries implementing the OpenIAP specification: +

    + +

    + View all implementations →

    + +
    +

    Get Started

    +
    + + 📚 API Reference + + + 📦 Type Definitions + + + 🎓 Tutorials + +
    +
    ); diff --git a/packages/docs/src/pages/languages.tsx b/packages/docs/src/pages/languages.tsx index 56662b16..c714ad25 100644 --- a/packages/docs/src/pages/languages.tsx +++ b/packages/docs/src/pages/languages.tsx @@ -6,9 +6,9 @@ function Languages() {

    OpenIAP Implementations

    diff --git a/packages/docs/src/pages/sponsors.tsx b/packages/docs/src/pages/sponsors.tsx index 268de961..b86128b0 100644 --- a/packages/docs/src/pages/sponsors.tsx +++ b/packages/docs/src/pages/sponsors.tsx @@ -6,8 +6,9 @@ function Sponsors() {

    Support OpenIAP

    diff --git a/packages/docs/src/pages/tutorials.tsx b/packages/docs/src/pages/tutorials.tsx index 28574669..249c224a 100644 --- a/packages/docs/src/pages/tutorials.tsx +++ b/packages/docs/src/pages/tutorials.tsx @@ -9,9 +9,9 @@ function Tutorials() {

    Tutorials

    From 9f336c0dde9dc32cb42d4619d85571ca316074ca Mon Sep 17 00:00:00 2001 From: Hyo Date: Wed, 11 Feb 2026 17:05:38 +0900 Subject: [PATCH 2/6] docs: refactor introduction to technical style, add marketing to home - Rewrite introduction.tsx as "Why OpenIAP" with technical documentation style - Architecture diagram and code generation explanation - API design with naming conventions table - Type safety examples with code blocks - Purchase flow code example - Platform support and framework implementation tables - Add marketing benefits section to home.tsx - 1x Learn Once, 0 Runtime Errors, 100% Platform Features cards Co-Authored-By: Claude Opus 4.5 --- packages/docs/src/pages/home.tsx | 118 ++ packages/docs/src/pages/introduction.tsx | 1355 ++++++++++------------ 2 files changed, 733 insertions(+), 740 deletions(-) diff --git a/packages/docs/src/pages/home.tsx b/packages/docs/src/pages/home.tsx index 51338ee6..32defdff 100644 --- a/packages/docs/src/pages/home.tsx +++ b/packages/docs/src/pages/home.tsx @@ -200,6 +200,124 @@ function Home() {
    + {/* Key Benefits */} +
    +
    +
    +
    +
    + 1x +
    +

    + Learn Once +

    +

    + Master one API instead of learning different patterns for iOS, + Android, and every framework +

    +
    +
    +
    + 0 +
    +

    + Runtime Errors +

    +

    + Type-safe generated code catches mistakes at compile time, not + in production +

    +
    +
    +
    + 100% +
    +

    + Platform Features +

    +

    + Full access to StoreKit 2 and Play Billing v8 — no features + hidden or abstracted away +

    +
    +
    +
    +
    +

    The Problem We're Solving

    diff --git a/packages/docs/src/pages/introduction.tsx b/packages/docs/src/pages/introduction.tsx index e412f423..3f05abe7 100644 --- a/packages/docs/src/pages/introduction.tsx +++ b/packages/docs/src/pages/introduction.tsx @@ -5,271 +5,227 @@ function Introduction() { return (
    - {/* Hero Section */} -
    Why OpenIAP +

    -

    - Stop Rewriting IAP Code -
    - - For Every Platform - -

    -

    - OpenIAP is the unified specification for in-app - purchases. Write once, ship to iOS, Android, Vision Pro, and Meta - Quest with type-safe, consistent APIs. -

    + OpenIAP is a unified specification for in-app purchases across iOS, + Android, and XR platforms. One GraphQL schema generates type-safe + native code for Swift, Kotlin, TypeScript, Dart, and GDScript. +

    - {/* Quick Stats */} -
    +

    The Problem

    +

    + In-app purchase implementations are fragmented across platforms and + frameworks. Each library defines its own API surface, type + definitions, and event patterns. This creates several challenges: +

    +
      +
    • + Inconsistent APIs — Method names, parameter + structures, and return types differ between{' '} + react-native-iap, flutter_inapp_purchase + , and other libraries +
    • +
    • + Duplicated effort — Library maintainers + independently solve the same problems (transaction handling, error + codes, subscription lifecycle) +
    • +
    • + Platform drift — When Apple adds StoreKit 2 + features or Google updates Play Billing, each library implements + changes differently +
    • +
    • + AI limitations — AI assistants cannot generate + reliable IAP code because no two libraries work the same way +
    • +
    +

    + New platforms like{' '} -

    -
    - Combined Stars -
    -
    -
    -
    - 5+ -
    -
    - Framework Libraries -
    -
    -
    + Vision Pro + {' '} + and Horizon OS compound this + fragmentation. +

    +
    - {/* CTA Buttons */} -
    +

    The Solution

    +

    + OpenIAP provides a single source of truth for IAP implementations. + The specification defines: +

    +
    -
    +
  • + Unified API methods —{' '} + + initConnection() + + ,{' '} + + fetchProducts() + + ,{' '} + + requestPurchase() + + ,{' '} + + finishTransaction() + +
  • +
  • + Shared type definitions —{' '} + + Product + + ,{' '} + + Purchase + + ,{' '} + + SubscriptionPeriod + + ,{' '} + + PurchaseError + +
  • +
  • + Standard event patterns —{' '} + + purchaseUpdatedListener + + ,{' '} + + purchaseErrorListener + +
  • +
  • + Platform-aware naming — Cross-platform types use + no suffix, platform-specific use IOS/ + Android suffix +
  • + + - {/* Key Benefits - Visual Cards */} + {/* Architecture */}
    +

    Architecture

    +

    + OpenIAP uses a schema-driven approach. A single GraphQL schema + defines all types and operations, which are then generated into + native code for each target platform. +

    +
    -
    -
    - 1x -
    -

    - Learn Once -

    -

    - Master one API instead of learning different patterns for iOS, - Android, and every framework -

    -
    -
    -
    - 0 -
    -

    - Runtime Errors -

    -

    + OpenIAP Architecture - GraphQL schema generates native modules - Type-safe generated code catches mistakes at compile time, not - in production -

    -
    -
    + +

    -

    - 100% -
    -

    - Platform Features -

    -

    - Full access to StoreKit 2 and Play Billing v8 - no features - hidden or abstracted away -

    -
    + View ecosystem documentation → +

    -
    - {/* Core Modules Visual */} -
    -

    Native Modules

    -

    - OpenIAP provides{' '} - production-ready native modules that power all - framework implementations. Built on{' '} +

    Code Generation

    +

    + The{' '} - StoreKit 2 + openiap-gql {' '} - and{' '} - - Play Billing v8 - - . + package contains the GraphQL schema and generators. Running{' '} + bun run generate produces: +

    +
    +
    +              {`packages/apple/Sources/Models/Types.swift    # Swift types
    +packages/google/openiap/src/main/Types.kt    # Kotlin types
    +src/generated/types.ts                       # TypeScript types
    +src/generated/types.dart                     # Dart types
    +src/generated/types.gd                       # GDScript types`}
    +            
    +
    + +

    Native Modules

    +

    + Two native modules implement the specification on top of platform + APIs:

    + {/* API Design */}
    -

    The IAP Fragmentation Problem

    +

    API Design

    + +

    Naming Conventions

    +

    + OpenIAP uses consistent naming across all implementations: +

    -

    - Every IAP library reinvents the wheel.{' '} - Different method names.{' '} - Different event patterns.{' '} - Different type definitions. Switching frameworks - means relearning everything. AI assistants can't help because no - two libraries work the same way. -

    -
    -
    -
    - Wasted Time -

    - Learning new APIs for each framework -

    -
    -
    - Production Bugs -

    - Inconsistent type handling across platforms -

    -
    -
    - Duplicated Effort -

    - Maintainers solving same problems independently -

    -
    + + + Scope + Pattern + Example + + + + + Cross-platform + + functionName + + + fetchProducts(), requestPurchase() + + + + iOS-only + + functionNameIOS + + + syncIOS(), getStorefrontIOS() + + + + Android-only + + functionNameAndroid + + + acknowledgePurchaseAndroid() + + + +
    -

    - And it's getting worse. New platforms like{' '} - - Vision Pro - {' '} - and Horizon OS mean more APIs - to learn, more fragmentation to manage. -

    -
    -
    -

    The OpenIAP Solution

    -

    - One specification. One API. Every platform. +

    Type Safety

    +

    + Generated types ensure compile-time safety. Platform-specific fields + use suffixes to prevent accidental cross-platform usage:

    - - {/* Ecosystem Diagram */}
    - - OpenIAP Ecosystem - Native modules power framework implementations - -

    - View full ecosystem diagram → -

    +
    +              {`// Cross-platform fields (no suffix)
    +interface Product {
    +  id: string;
    +  title: string;
    +  price: string;
    +  priceAmount: number;
    +  currency: string;
    +}
    +
    +// Platform-specific fields (with suffix)
    +interface Purchase {
    +  productId: string;
    +  transactionId: string;
    +  // iOS-specific
    +  originalTransactionIdIOS?: string;
    +  // Android-specific
    +  purchaseTokenAndroid?: string;
    +  orderIdAndroid?: string;
    +}`}
    +            
    +
    - {/* Feature Grid */} + {/* Purchase Flow */} +
    +

    Purchase Flow

    +

    + The standard purchase flow works identically across all OpenIAP + implementations: +

    -
    -

    - Unified API -

    -

    - Standard methods like{' '} - - initConnection() - - ,{' '} - - fetchProducts() - - , and{' '} - - requestPurchase() - {' '} - work identically everywhere. -

    -
    +
    +              {`// 1. Initialize connection
    +await initConnection();
     
    -            
    -

    - Generated Types -

    -

    - From one GraphQL schema, generate native types for Swift, - Kotlin, TypeScript, Dart, and GDScript.{' '} - Download → -

    -
    +// 2. Set up listeners (event-based, not promise-based) +const subscription = purchaseUpdatedListener(async (purchase) => { + // 3. Verify on your server + const verified = await verifyPurchase(purchase); -
    -

    - Platform-Aware -

    -

    - Clear naming:{' '} - - Product - {' '} - for shared,{' '} - - ProductIOS - - / - - ProductAndroid - {' '} - for platform-specific. -

    -
    + // 4. Grant entitlement + if (verified) { + await grantAccess(purchase.productId); + } -
    -

    - AI-Ready -

    -

    - Standardized APIs mean AI assistants generate reliable, - predictable IAP code across all frameworks. -

    -
    + // 5. Acknowledge the purchase + // Android: auto-refunds after 3 days if not acknowledged + await finishTransaction(purchase, isConsumable); +}); + +// 6. Fetch products +const products = await fetchProducts({ + products: [ + { id: 'com.app.premium', type: 'inapp' }, + { id: 'com.app.monthly', type: 'subs' }, + ], +}); + +// 7. Request purchase (result comes via listener) +await requestPurchase({ + request: { + apple: { sku: 'com.app.premium' }, + google: { skus: ['com.app.premium'] }, + }, + type: 'inapp', +}); + +// 8. Cleanup on unmount +subscription.remove(); +await endConnection();`} +
    +

    + See Purchase Lifecycle for + detailed flow documentation. +

    + {/* Supported Platforms */}

    Supported Platforms

    - - 🍎 -
    - iOS / macOS / Vision Pro -
    - StoreKit 2 -
    -
    -
    - - 🤖 -
    - Android -
    + - Play Billing v8 -
    -
    -
    - Platform + Billing API + Min Version + + + + + iOS + + + StoreKit 2 + + + iOS 15.0+ + + + macOS + StoreKit 2 + macOS 12.0+ + + + visionOS + StoreKit 2 + visionOS 1.0+ + + + Android + + + Play Billing v8 + + + API 21+ (5.0) + + + Meta Quest + + Horizon OS + + Quest 2+ + + + +
    +
    + + {/* Framework Implementations */} +
    +

    Framework Implementations

    +

    + Production-ready libraries implementing the OpenIAP specification: +

    +
    + - 🎮 -
    - Meta Quest -
    +
    - Horizon OS - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    LibraryFrameworkBridge
    + + react-native-iap + + React Native + + Nitro Modules + +
    + + expo-iap + + Expo + + Expo Modules + +
    + + flutter_inapp_purchase + + Flutter + + Pigeon + +
    + + kmp-iap + + + Kotlin Multiplatform + + + K/N Interop + +
    + + godot-iap + + Godot 4.x + + GDExtension + +
    +

    + View all implementations → +

    + {/* Getting Started */}
    -

    Implementations

    -

    - Production-ready libraries implementing the OpenIAP specification: +

    Getting Started

    +

    + Choose your framework to get started:

    -

    - View all implementations → -

    -
    - -
    -

    Get Started

    -
    - - 📚 API Reference - - - 📦 Type Definitions - - - 🎓 Tutorials
    From 3e9672be2345eb5221a80f0a6afcbff538d54f94 Mon Sep 17 00:00:00 2001 From: Hyo Date: Wed, 11 Feb 2026 17:15:39 +0900 Subject: [PATCH 3/6] docs: improve readability and update XR status - Increase font sizes in introduction page for better readability - Remove WIP tag from XR-Compatible (Horizon OS, Vision Pro supported) - Update code block font size to 0.9375rem Co-Authored-By: Claude Opus 4.5 --- packages/docs/src/pages/home.tsx | 26 ++++--- packages/docs/src/pages/introduction.tsx | 86 ++++++++++-------------- packages/docs/src/styles/code.css | 6 +- 3 files changed, 50 insertions(+), 68 deletions(-) diff --git a/packages/docs/src/pages/home.tsx b/packages/docs/src/pages/home.tsx index 32defdff..7411015c 100644 --- a/packages/docs/src/pages/home.tsx +++ b/packages/docs/src/pages/home.tsx @@ -203,6 +203,15 @@ function Home() { {/* Key Benefits */}
    +

    + Why Developers Choose OpenIAP +

    +

    + Build revenue-generating features faster with less code +

    -

    - XR-Compatible{' '} - - (WIP) - -

    +

    XR-Compatible

    - Horizon OS, Android XR, Vision Pro - new realities need - purchases. OpenIAP is ready for the spatial computing era. + Horizon OS and Vision Pro supported. Android XR coming soon. + OpenIAP is ready for the spatial computing era.

    diff --git a/packages/docs/src/pages/introduction.tsx b/packages/docs/src/pages/introduction.tsx index 3f05abe7..017bf4d0 100644 --- a/packages/docs/src/pages/introduction.tsx +++ b/packages/docs/src/pages/introduction.tsx @@ -1,5 +1,6 @@ import { Link } from 'react-router-dom'; import SEO from '../components/SEO'; +import CodeBlock from '../components/CodeBlock'; function Introduction() { return ( @@ -29,13 +30,14 @@ function Introduction() { {/* The Problem */}

    The Problem

    -

    +

    In-app purchase implementations are fragmented across platforms and frameworks. Each library defines its own API surface, type definitions, and event patterns. This creates several challenges:

    -

    +

    New platforms like{' '}

    The Solution

    -

    +

    OpenIAP provides a single source of truth for IAP implementations. The specification defines:

      Architecture

      -

      +

      OpenIAP uses a schema-driven approach. A single GraphQL schema defines all types and operations, which are then generated into native code for each target platform. @@ -182,7 +185,7 @@ function Introduction() {

    Code Generation

    -

    +

    The{' '}

    Native Modules

    -

    +

    Two native modules implement the specification on top of platform APIs:

    @@ -247,7 +250,7 @@ src/generated/types.gd # GDScript types`}

    @@ -281,7 +284,7 @@ src/generated/types.gd # GDScript types`}

    @@ -304,7 +307,7 @@ src/generated/types.gd # GDScript types`}

    API Design

    Naming Conventions

    -

    +

    OpenIAP uses consistent naming across all implementations:

    @@ -365,24 +368,12 @@ src/generated/types.gd # GDScript types`}

    Type Safety

    -

    +

    Generated types ensure compile-time safety. Platform-specific fields use suffixes to prevent accidental cross-platform usage:

    -
    -
    -              {`// Cross-platform fields (no suffix)
    +          
    +            {`// Cross-platform fields (no suffix)
     interface Product {
       id: string;
       title: string;
    @@ -401,31 +392,18 @@ interface Purchase {
       purchaseTokenAndroid?: string;
       orderIdAndroid?: string;
     }`}
    -            
    -
    + {/* Purchase Flow */}

    Purchase Flow

    -

    +

    The standard purchase flow works identically across all OpenIAP implementations:

    -
    -
    -              {`// 1. Initialize connection
    +          
    +            {`// 1. Initialize connection
     await initConnection();
     
     // 2. Set up listeners (event-based, not promise-based)
    @@ -463,9 +441,15 @@ await requestPurchase({
     // 8. Cleanup on unmount
     subscription.remove();
     await endConnection();`}
    -            
    -
    -

    + +

    See Purchase Lifecycle for detailed flow documentation.

    @@ -484,7 +468,7 @@ await endConnection();`} style={{ width: '100%', borderCollapse: 'collapse', - fontSize: '0.875rem', + fontSize: '1rem', }} > @@ -551,7 +535,7 @@ await endConnection();`} {/* Framework Implementations */}

    Framework Implementations

    -

    +

    Production-ready libraries implementing the OpenIAP specification:

    @@ -690,7 +674,7 @@ await endConnection();`}
    -

    +

    View all implementations →

    @@ -698,7 +682,7 @@ await endConnection();`} {/* Getting Started */}

    Getting Started

    -

    +

    Choose your framework to get started:

    Date: Wed, 11 Feb 2026 17:19:57 +0900 Subject: [PATCH 4/6] fix: address PR review comments - robots.txt: add Allow: / for AI crawlers to access full site - SEO.tsx: make JSON-LD schema conditional (only home/introduction) - home.tsx: update Combined Stars link to /languages page - introduction.tsx: add width/height to ecosystem image for CLS - introduction.tsx: fix nested anchor elements (invalid HTML) Co-Authored-By: Claude Opus 4.5 --- packages/docs/public/robots.txt | 1 + packages/docs/src/components/SEO.tsx | 6 +++- packages/docs/src/pages/home.tsx | 10 +++---- packages/docs/src/pages/introduction.tsx | 38 ++++++++++++++---------- 4 files changed, 33 insertions(+), 22 deletions(-) diff --git a/packages/docs/public/robots.txt b/packages/docs/public/robots.txt index d20157d0..20ded555 100644 --- a/packages/docs/public/robots.txt +++ b/packages/docs/public/robots.txt @@ -11,6 +11,7 @@ User-agent: Claude-Web User-agent: Anthropic-AI User-agent: PerplexityBot User-agent: Google-Extended +Allow: / Allow: /llms.txt Allow: /llms-full.txt diff --git a/packages/docs/src/components/SEO.tsx b/packages/docs/src/components/SEO.tsx index e1b8256b..c38cd752 100644 --- a/packages/docs/src/components/SEO.tsx +++ b/packages/docs/src/components/SEO.tsx @@ -7,6 +7,7 @@ interface SEOProps { keywords?: string; type?: 'website' | 'article'; image?: string; + includeAppSchema?: boolean; } const BASE_URL = 'https://openiap.dev'; @@ -22,6 +23,7 @@ function SEO({ keywords, type = 'website', image, + includeAppSchema = false, }: SEOProps) { const pageTitle = title ? `${title} | OpenIAP` : DEFAULT_TITLE; const pageDescription = description || DEFAULT_DESCRIPTION; @@ -73,7 +75,9 @@ function SEO({ {/* Schema.org JSON-LD */} - + {includeAppSchema && ( + + )} ); } diff --git a/packages/docs/src/pages/home.tsx b/packages/docs/src/pages/home.tsx index 7411015c..2f4bd6ee 100644 --- a/packages/docs/src/pages/home.tsx +++ b/packages/docs/src/pages/home.tsx @@ -12,6 +12,7 @@ function Home() { description="OpenIAP standardizes in-app purchases across iOS, Android, React Native, Flutter, Kotlin Multiplatform, and Godot. One API, every platform. StoreKit 2, Google Play Billing, Vision Pro, Horizon OS." path="/" keywords="in-app purchase, IAP, StoreKit 2, Google Play Billing, React Native IAP, Flutter IAP, Kotlin Multiplatform, cross-platform payments, mobile monetization" + includeAppSchema />
    From 668c1311ad5d4b15f6c2a19a8f4452bff79c0f06 Mon Sep 17 00:00:00 2001 From: Hyo Date: Wed, 11 Feb 2026 17:31:40 +0900 Subject: [PATCH 5/6] refactor(docs): extract inline styles to CSS classes - Move Quick Stats and Key Benefits styles from home.tsx to home.css - Move all inline styles from introduction.tsx to pages.css - Add new CSS classes: intro-lead, intro-text, intro-list, intro-table, native-module-grid, getting-started-grid, etc. - Reduce inline styles for better maintainability Co-Authored-By: Claude Opus 4.5 --- packages/docs/src/pages/home.tsx | 178 ++------- packages/docs/src/pages/introduction.tsx | 451 ++++++----------------- packages/docs/src/styles/home.css | 69 +++- packages/docs/src/styles/pages.css | 149 ++++++++ 4 files changed, 355 insertions(+), 492 deletions(-) diff --git a/packages/docs/src/pages/home.tsx b/packages/docs/src/pages/home.tsx index 2f4bd6ee..c6bbb07f 100644 --- a/packages/docs/src/pages/home.tsx +++ b/packages/docs/src/pages/home.tsx @@ -49,56 +49,15 @@ function Home() { Android, Vision Pro, and Meta Quest.

    {/* Quick Stats */} -
    - -
    - {/* Aggregate stars across ecosystem repos - update periodically */} - 4K+ -
    -
    - Combined Stars -
    +
    + + {/* Aggregate stars across ecosystem repos - update periodically */} +
    4K+
    +
    Combined Stars
    -
    -
    - 5+ -
    -
    - Framework Libraries -
    +
    +
    5+
    +
    Framework Libraries
    @@ -203,122 +162,31 @@ function Home() { {/* Key Benefits */}
    -

    - Why Developers Choose OpenIAP -

    -

    +

    Why Developers Choose OpenIAP

    +

    Build revenue-generating features faster with less code

    -
    -
    -
    - 1x -
    -

    - Learn Once -

    -

    +

    +
    +
    1x
    +

    Learn Once

    +

    Master one API instead of learning different patterns for iOS, Android, and every framework

    -
    -
    - 0 -
    -

    - Runtime Errors -

    -

    +

    +
    0
    +

    Runtime Errors

    +

    Type-safe generated code catches mistakes at compile time, not in production

    -
    -
    - 100% -
    -

    - Platform Features -

    -

    +

    +
    100%
    +

    Platform Features

    +

    Full access to StoreKit 2 and Play Billing v8 — no features hidden or abstracted away

    diff --git a/packages/docs/src/pages/introduction.tsx b/packages/docs/src/pages/introduction.tsx index 039fbd60..fabb56a0 100644 --- a/packages/docs/src/pages/introduction.tsx +++ b/packages/docs/src/pages/introduction.tsx @@ -15,14 +15,7 @@ function Introduction() {
    {/* Title */}

    Why OpenIAP

    -

    +

    OpenIAP is a unified specification for in-app purchases across iOS, Android, and XR platforms. One GraphQL schema generates type-safe native code for Swift, Kotlin, TypeScript, Dart, and GDScript. @@ -31,41 +24,34 @@ function Introduction() { {/* The Problem */}

    The Problem

    -

    +

    In-app purchase implementations are fragmented across platforms and frameworks. Each library defines its own API surface, type definitions, and event patterns. This creates several challenges:

    -