$npx -y skills add hanamizuki/solopreneur --skill gplay-ppp-pricingSet region-specific pricing for subscriptions and in-app purchases using purchasing power parity (PPP). Use when adjusting prices by country or implementing localized pricing strategies on Google Play.
| 1 | # PPP Pricing (Per-Region Pricing) |
| 2 | |
| 3 | Use this skill to set different prices for different countries based on purchasing power parity or custom pricing strategies. |
| 4 | |
| 5 | ## Preconditions |
| 6 | - Ensure credentials are set (`gplay auth login --service-account` or `GPLAY_SERVICE_ACCOUNT` env var). |
| 7 | - Use `GPLAY_PACKAGE` or pass `--package` explicitly. |
| 8 | - Know your base region (usually US) and base price. |
| 9 | |
| 10 | ## Critical: Required flags |
| 11 | |
| 12 | When updating subscriptions or one-time products that modify pricing, you **must** provide: |
| 13 | |
| 14 | - **`--regions-version`**: Required by the Google Play API when updating regional pricing. Use the **latest** version. If you don't know the current version, send any value (e.g., `"2022/02"`) — the API error will tell you the latest (e.g., `latest value is ExternalRegionLaunchVersionId{versionId=2025/03}`). Then retry with the correct version. |
| 15 | - **`--update-mask "basePlans"`**: Required for subscription updates. Without it, the API returns: "update_mask must contain at least one path." |
| 16 | - For one-time products, use `--update-mask "purchaseOptions"`. |
| 17 | |
| 18 | ## Critical: Preserve all existing regions (fetch-then-merge) |
| 19 | |
| 20 | **The Google Play API rejects updates that remove existing regional configs.** If a subscription already has 173 regions configured and you send only 30 PPP regions, the API returns: "Regional configs were removed from the base plan: BM, BO, CI..." |
| 21 | |
| 22 | **Always follow the fetch-then-merge pattern:** |
| 23 | 1. Fetch the current product to get ALL existing regional configs |
| 24 | 2. Override only the PPP target regions with your calculated prices |
| 25 | 3. Send the complete merged list (all original regions + PPP overrides) |
| 26 | |
| 27 | This also applies to: |
| 28 | - **`otherRegionsConfig`** for subscriptions — if it was previously set on a base plan, it **must** be included in the update JSON. |
| 29 | - **`newRegionsConfig`** for one-time product purchase options — if it was previously set (with `usdPrice`, `eurPrice`, and `availability`), it **must** be included. Omitting it causes: "Cannot remove currency for new regions once it has been added: EUR." |
| 30 | |
| 31 | ## Critical: Currency codes come from Google Play, not from assumptions |
| 32 | |
| 33 | **Do NOT hardcode currency-to-region mappings.** Currency codes vary depending on the `--regions-version` value (e.g., Bulgaria BG uses BGN in older versions but EUR in newer versions after eurozone adoption). |
| 34 | |
| 35 | **Always use the currency codes from the fetched existing regional configs.** For PPP target regions where you override the price, use the currency from the multiplier table below. For all other regions, preserve the existing currency exactly as returned by Google Play. |
| 36 | |
| 37 | ## PPP Multiplier Table |
| 38 | |
| 39 | Apply these multipliers to the base USD price. Round all results to `.99` endings (e.g., \$4.73 → \$4.99, ₹249.37 → ₹249.99). |
| 40 | |
| 41 | ### Tier 1 — Full Price (1.0x–1.1x) |
| 42 | | Region | Code | Multiplier | Currency | |
| 43 | |--------|------|-----------|----------| |
| 44 | | United States | US | 1.0x | USD | |
| 45 | | United Kingdom | GB | 1.0x | GBP | |
| 46 | | Germany | DE | 1.0x | EUR | |
| 47 | | Australia | AU | 1.0x | AUD | |
| 48 | | Switzerland | CH | 1.1x | CHF | |
| 49 | | Canada | CA | 1.0x | CAD | |
| 50 | | Netherlands | NL | 1.0x | EUR | |
| 51 | | Sweden | SE | 1.0x | SEK | |
| 52 | | Norway | NO | 1.05x | NOK | |
| 53 | | Denmark | DK | 1.0x | DKK | |
| 54 | |
| 55 | ### Tier 2 — Medium (0.6x–0.8x) |
| 56 | | Region | Code | Multiplier | Currency | |
| 57 | |--------|------|-----------|----------| |
| 58 | | France | FR | 0.8x | EUR | |
| 59 | | Spain | ES | 0.7x | EUR | |
| 60 | | Italy | IT | 0.7x | EUR | |
| 61 | | Japan | JP | 0.8x | JPY | |
| 62 | | South Korea | KR | 0.7x | KRW | |
| 63 | | Poland | PL | 0.6x | PLN | |
| 64 | | Portugal | PT | 0.7x | EUR | |
| 65 | | Czech Republic | CZ | 0.6x | CZK | |
| 66 | | Greece | GR | 0.65x | EUR | |
| 67 | | Chile | CL | 0.6x | CLP | |
| 68 | | Saudi Arabia | SA | 0.8x | SAR | |
| 69 | | UAE | AE | 0.8x | AED | |
| 70 | |
| 71 | ### Tier 3 — Low (0.3x–0.5x) |
| 72 | | Region | Code | Multiplier | Currency | |
| 73 | |--------|------|-----------|----------| |
| 74 | | India | IN | 0.3x | INR | |
| 75 | | Brazil | BR | 0.5x | BRL | |
| 76 | | Mexico | MX | 0.45x | MXN | |
| 77 | | Indonesia | ID | 0.3x | IDR | |
| 78 | | Turkey | TR | 0.35x | TRY | |
| 79 | | Vietnam | VN | 0.3x | VND | |
| 80 | | Philippines | PH | 0.35x | PHP | |
| 81 | | Egypt | EG | 0.3x | EGP | |
| 82 | | Colombia | CO | 0.4x | COP | |
| 83 | | Argentina | AR | 0.3x | ARS | |
| 84 | | Nigeria | NG | 0.3x | NGN | |
| 85 | | Pakistan | PK | 0.25x | PKR | |
| 86 | | Thailand | TH | 0.4x | THB | |
| 87 | | Malaysia | MY | 0.45x | MYR | |
| 88 | | South Africa | ZA | 0.4x | ZAR | |
| 89 | | Ukraine | UA | 0.3x | UAH | |
| 90 | |
| 91 | ## Workflow: Set PPP-Based IAP Pricing (legacy `inappproducts` API) |
| 92 | |
| 93 | Use this workflow for legacy managed products created via `gplay iap`. These use the `priceMicros`/`currency` format. |
| 94 | |
| 95 | ### 1. List in-app products |
| 96 | ```bash |
| 97 | gplay iap list --package "PACKAGE" |
| 98 | ``` |
| 99 | |
| 100 | ### 2. Get current product details |
| 101 | ```bash |
| 102 | gplay iap get --package "PACKAGE" --sku "SKU" |
| 103 | ``` |
| 104 | Note the current `defaultPrice` as your base price, and **save all existing `prices` entries**. |
| 105 | |
| 106 | ### 3. Build |