kappmaker 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +545 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +195 -0
- package/dist/cli.js.map +1 -0
- package/dist/commands/adapty-setup.d.ts +2 -0
- package/dist/commands/adapty-setup.js +240 -0
- package/dist/commands/adapty-setup.js.map +1 -0
- package/dist/commands/config.d.ts +12 -0
- package/dist/commands/config.js +230 -0
- package/dist/commands/config.js.map +1 -0
- package/dist/commands/create-appstore-app.d.ts +2 -0
- package/dist/commands/create-appstore-app.js +261 -0
- package/dist/commands/create-appstore-app.js.map +1 -0
- package/dist/commands/create-logo.d.ts +2 -0
- package/dist/commands/create-logo.js +93 -0
- package/dist/commands/create-logo.js.map +1 -0
- package/dist/commands/create.d.ts +2 -0
- package/dist/commands/create.js +143 -0
- package/dist/commands/create.js.map +1 -0
- package/dist/commands/enhance.d.ts +2 -0
- package/dist/commands/enhance.js +55 -0
- package/dist/commands/enhance.js.map +1 -0
- package/dist/commands/generate-screenshots.d.ts +2 -0
- package/dist/commands/generate-screenshots.js +174 -0
- package/dist/commands/generate-screenshots.js.map +1 -0
- package/dist/commands/remove-bg.d.ts +2 -0
- package/dist/commands/remove-bg.js +41 -0
- package/dist/commands/remove-bg.js.map +1 -0
- package/dist/commands/split.d.ts +2 -0
- package/dist/commands/split.js +37 -0
- package/dist/commands/split.js.map +1 -0
- package/dist/commands/translate-screenshots.d.ts +2 -0
- package/dist/commands/translate-screenshots.js +224 -0
- package/dist/commands/translate-screenshots.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -0
- package/dist/services/adapty.service.d.ts +26 -0
- package/dist/services/adapty.service.js +230 -0
- package/dist/services/adapty.service.js.map +1 -0
- package/dist/services/asc-monetization.service.d.ts +3 -0
- package/dist/services/asc-monetization.service.js +223 -0
- package/dist/services/asc-monetization.service.js.map +1 -0
- package/dist/services/asc.service.d.ts +14 -0
- package/dist/services/asc.service.js +321 -0
- package/dist/services/asc.service.js.map +1 -0
- package/dist/services/fal.service.d.ts +15 -0
- package/dist/services/fal.service.js +236 -0
- package/dist/services/fal.service.js.map +1 -0
- package/dist/services/fastlane.service.d.ts +2 -0
- package/dist/services/fastlane.service.js +32 -0
- package/dist/services/fastlane.service.js.map +1 -0
- package/dist/services/firebase.service.d.ts +7 -0
- package/dist/services/firebase.service.js +176 -0
- package/dist/services/firebase.service.js.map +1 -0
- package/dist/services/git.service.d.ts +3 -0
- package/dist/services/git.service.js +13 -0
- package/dist/services/git.service.js.map +1 -0
- package/dist/services/gradle.service.d.ts +4 -0
- package/dist/services/gradle.service.js +31 -0
- package/dist/services/gradle.service.js.map +1 -0
- package/dist/services/ios.service.d.ts +1 -0
- package/dist/services/ios.service.js +9 -0
- package/dist/services/ios.service.js.map +1 -0
- package/dist/services/logo.service.d.ts +12 -0
- package/dist/services/logo.service.js +168 -0
- package/dist/services/logo.service.js.map +1 -0
- package/dist/services/openai.service.d.ts +2 -0
- package/dist/services/openai.service.js +42 -0
- package/dist/services/openai.service.js.map +1 -0
- package/dist/services/screenshot-styles.d.ts +1 -0
- package/dist/services/screenshot-styles.js +1050 -0
- package/dist/services/screenshot-styles.js.map +1 -0
- package/dist/services/screenshot.service.d.ts +14 -0
- package/dist/services/screenshot.service.js +136 -0
- package/dist/services/screenshot.service.js.map +1 -0
- package/dist/templates/adapty-config.json +50 -0
- package/dist/templates/appstore-config.json +188 -0
- package/dist/types/adapty.d.ts +38 -0
- package/dist/types/adapty.js +2 -0
- package/dist/types/adapty.js.map +1 -0
- package/dist/types/appstore.d.ts +150 -0
- package/dist/types/appstore.js +2 -0
- package/dist/types/appstore.js.map +1 -0
- package/dist/types/index.d.ts +80 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/utils/config.d.ts +18 -0
- package/dist/utils/config.js +107 -0
- package/dist/utils/config.js.map +1 -0
- package/dist/utils/exec.d.ts +17 -0
- package/dist/utils/exec.js +62 -0
- package/dist/utils/exec.js.map +1 -0
- package/dist/utils/logger.d.ts +10 -0
- package/dist/utils/logger.js +29 -0
- package/dist/utils/logger.js.map +1 -0
- package/dist/utils/prompt.d.ts +2 -0
- package/dist/utils/prompt.js +26 -0
- package/dist/utils/prompt.js.map +1 -0
- package/dist/utils/validator.d.ts +2 -0
- package/dist/utils/validator.js +93 -0
- package/dist/utils/validator.js.map +1 -0
- package/package.json +35 -0
package/README.md
ADDED
|
@@ -0,0 +1,545 @@
|
|
|
1
|
+
# KAppMaker CLI
|
|
2
|
+
|
|
3
|
+
CLI tool for automating mobile app bootstrapping for the KAppMaker platform. Handles everything from template cloning and Firebase setup to App Store Connect configuration, Adapty subscriptions, AI logo generation, and Android release builds.
|
|
4
|
+
|
|
5
|
+
## Commands Overview
|
|
6
|
+
|
|
7
|
+
| Command | Description |
|
|
8
|
+
|---------|-------------|
|
|
9
|
+
| [`kappmaker create <app-name>`](#create-app-name) | Full end-to-end app setup (Firebase, logo, App Store, Adapty, release build) |
|
|
10
|
+
| [`kappmaker create-logo`](#create-logo) | Generate an app logo with AI (fal.ai) |
|
|
11
|
+
| [`kappmaker create-appstore-app`](#create-appstore-app) | Set up an app on App Store Connect (metadata, subscriptions, privacy) |
|
|
12
|
+
| [`kappmaker adapty setup`](#adapty-setup) | Set up Adapty products, paywalls, and placements |
|
|
13
|
+
| [`kappmaker image-split <image>`](#image-split-source) | Split a grid image into individual tiles |
|
|
14
|
+
| [`kappmaker image-remove-bg <image>`](#image-remove-bg-source) | Remove background from an image (fal.ai) |
|
|
15
|
+
| [`kappmaker image-enhance <image>`](#image-enhance-source) | Upscale and enhance image quality (fal.ai) |
|
|
16
|
+
| [`kappmaker translate-screenshots [dir]`](#translate-screenshots-source-dir) | Translate screenshots to multiple locales (fal.ai) |
|
|
17
|
+
| [`kappmaker generate-screenshots`](#generate-screenshots) | Generate marketing screenshots with AI (OpenAI + fal.ai) |
|
|
18
|
+
| [`kappmaker config`](#config) | Manage CLI settings, API keys, and global defaults |
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## Prerequisites
|
|
23
|
+
|
|
24
|
+
- **Node.js** >= 20
|
|
25
|
+
- **Git**
|
|
26
|
+
- **Firebase CLI** — `npm install -g firebase-tools`
|
|
27
|
+
- **CocoaPods** — `sudo gem install cocoapods`
|
|
28
|
+
- **Fastlane** — via Bundler in the template repo
|
|
29
|
+
- **Android SDK** — installed at `~/Library/Android/sdk` (configurable)
|
|
30
|
+
- **asc CLI** (optional, for App Store Connect) — `brew install asc`
|
|
31
|
+
- **Adapty CLI** (optional, for Adapty setup) — `npm install -g adapty`
|
|
32
|
+
|
|
33
|
+
## External Services & API Keys
|
|
34
|
+
|
|
35
|
+
The CLI integrates with several external services for AI image generation, app store management, and subscription setup. All keys are stored locally at `~/.config/kappmaker/config.json`.
|
|
36
|
+
|
|
37
|
+
### fal.ai — AI Image Generation
|
|
38
|
+
|
|
39
|
+
**Used for:** Logo generation, background removal, image enhancement, screenshot translation, and screenshot generation.
|
|
40
|
+
|
|
41
|
+
**How to get your key:**
|
|
42
|
+
1. Sign up at [fal.ai](https://fal.ai)
|
|
43
|
+
2. Go to [Dashboard > Keys](https://fal.ai/dashboard/keys) and create an API key
|
|
44
|
+
3. `kappmaker config set falApiKey <your-key>`
|
|
45
|
+
|
|
46
|
+
### ImgBB — Image Hosting
|
|
47
|
+
|
|
48
|
+
**Used for:** Temporarily hosting reference images when generating or translating screenshots (fal.ai needs a public URL to process images).
|
|
49
|
+
|
|
50
|
+
**How to get your key:**
|
|
51
|
+
1. Sign up at [imgbb.com](https://imgbb.com)
|
|
52
|
+
2. Go to [api.imgbb.com](https://api.imgbb.com/) and get your free API key
|
|
53
|
+
3. `kappmaker config set imgbbApiKey <your-key>`
|
|
54
|
+
|
|
55
|
+
### OpenAI — Prompt Generation
|
|
56
|
+
|
|
57
|
+
**Used for:** Generating detailed screenshot specifications from a short app description (uses GPT-4.1). Only needed for the `generate-screenshots` command.
|
|
58
|
+
|
|
59
|
+
**How to get your key:**
|
|
60
|
+
1. Sign up at [platform.openai.com](https://platform.openai.com)
|
|
61
|
+
2. Go to [API Keys](https://platform.openai.com/api-keys) and create a new key
|
|
62
|
+
3. `kappmaker config set openaiApiKey <your-key>`
|
|
63
|
+
|
|
64
|
+
### App Store Connect CLI (asc) — iOS App Management
|
|
65
|
+
|
|
66
|
+
**Used for:** Creating apps, setting metadata, categories, subscriptions, privacy declarations, and review info on App Store Connect.
|
|
67
|
+
|
|
68
|
+
**How to set up:**
|
|
69
|
+
1. Install: `brew install asc`
|
|
70
|
+
2. Generate an API key at [App Store Connect > Users and Access > Integrations > API](https://appstoreconnect.apple.com/access/integrations/api) (Admin role, download the `.p8` file immediately)
|
|
71
|
+
3. Configure:
|
|
72
|
+
```bash
|
|
73
|
+
kappmaker config set ascKeyId <your-key-id>
|
|
74
|
+
kappmaker config set ascIssuerId <your-issuer-id>
|
|
75
|
+
kappmaker config set ascPrivateKeyPath /path/to/AuthKey.p8
|
|
76
|
+
kappmaker config set appleId your@email.com
|
|
77
|
+
```
|
|
78
|
+
Or run `kappmaker config appstore-defaults --init` for interactive setup.
|
|
79
|
+
|
|
80
|
+
### Adapty CLI — Subscription Management
|
|
81
|
+
|
|
82
|
+
**Used for:** Setting up in-app subscription products, paywalls, and placements across iOS and Android via Adapty's backend.
|
|
83
|
+
|
|
84
|
+
**How to set up:**
|
|
85
|
+
1. Install: `npm install -g adapty`
|
|
86
|
+
2. Log in: `adapty auth login` (opens browser for authentication)
|
|
87
|
+
3. Run: `kappmaker adapty setup`
|
|
88
|
+
|
|
89
|
+
### Firebase CLI — Backend Setup
|
|
90
|
+
|
|
91
|
+
**Used for:** Creating Firebase projects, registering Android/iOS apps, downloading SDK config files (`google-services.json`, `GoogleService-Info.plist`), and enabling anonymous authentication.
|
|
92
|
+
|
|
93
|
+
**How to set up:**
|
|
94
|
+
1. Install: `npm install -g firebase-tools`
|
|
95
|
+
2. The `create` command handles login and project creation interactively.
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## Installation
|
|
100
|
+
|
|
101
|
+
```bash
|
|
102
|
+
npm install -g kappmaker
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
Then use it anywhere:
|
|
106
|
+
|
|
107
|
+
```bash
|
|
108
|
+
kappmaker create <AppName>
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### Development
|
|
112
|
+
|
|
113
|
+
```bash
|
|
114
|
+
npm install
|
|
115
|
+
npx tsx src/index.ts create <AppName>
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## `create <app-name>`
|
|
121
|
+
|
|
122
|
+
Full end-to-end app bootstrapping. Creates a new KAppMaker app from the template and optionally sets up everything needed to publish.
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
kappmaker create Remimi
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
**What it does (13 steps):**
|
|
129
|
+
|
|
130
|
+
| Step | Action | Details |
|
|
131
|
+
|------|--------|---------|
|
|
132
|
+
| 1 | Clone template | Clones into `<AppName>-All/` (prompts to overwrite if exists) |
|
|
133
|
+
| 2 | Firebase login | Opens browser for authentication |
|
|
134
|
+
| 3 | Create Firebase project | `<appname>-app` (skips if exists) |
|
|
135
|
+
| 4 | Create Firebase apps | Android + iOS apps (reuses existing if found) |
|
|
136
|
+
| 5 | Enable anonymous auth | Via Identity Toolkit REST API (warns on failure) |
|
|
137
|
+
| 6 | Download SDK configs | `google-services.json` + `GoogleService-Info.plist` |
|
|
138
|
+
| 7 | Logo generation | *Optional* — AI logo + automatic background removal |
|
|
139
|
+
| 8 | App Store Connect | *Optional* — full app setup (metadata, subs, privacy) |
|
|
140
|
+
| 9 | Adapty setup | *Optional* — products, paywalls, placements |
|
|
141
|
+
| 10 | Gradle refactor | Sets app name + application ID; asks whether to also rename the package name (default: yes) |
|
|
142
|
+
| 11 | Build environment | Creates `local.properties`, installs CocoaPods |
|
|
143
|
+
| 12 | Git remotes | Renames origin to upstream |
|
|
144
|
+
| 13 | Android release build | Fastlane build, prints AAB path for Google Play upload |
|
|
145
|
+
|
|
146
|
+
**Options:**
|
|
147
|
+
|
|
148
|
+
| Flag | Description | Default |
|
|
149
|
+
|------|-------------|---------|
|
|
150
|
+
| `--template-repo <url>` | Template repository URL | KAppMaker template |
|
|
151
|
+
| `--organization <org>` | Organization for Fastlane signing | App name (configurable) |
|
|
152
|
+
|
|
153
|
+
---
|
|
154
|
+
|
|
155
|
+
## `create-logo`
|
|
156
|
+
|
|
157
|
+
Generates an app logo using fal.ai's nano-banana-2 model.
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
kappmaker create-logo
|
|
161
|
+
kappmaker create-logo --output ./custom/path/logo.png
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
**Flow:**
|
|
165
|
+
1. Prompts for app idea / description
|
|
166
|
+
2. Generates a 4x4 grid of 16 logo variations (2K, 1:1)
|
|
167
|
+
3. Opens grid in Preview.app for review
|
|
168
|
+
4. Pick a logo (1-16) or R to regenerate — optional: `5 --zoom 1.1 --gap 3`
|
|
169
|
+
5. Extracts chosen logo at 512x512
|
|
170
|
+
|
|
171
|
+
**Output:** `Assets/app_logo.png` + `Assets/logo_variations.png`
|
|
172
|
+
|
|
173
|
+
Requires: `kappmaker config set falApiKey <your-key>`
|
|
174
|
+
|
|
175
|
+
| Flag | Description | Default |
|
|
176
|
+
|------|-------------|---------|
|
|
177
|
+
| `--output <path>` | Custom output path | `Assets/app_logo.png` |
|
|
178
|
+
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
## `create-appstore-app`
|
|
182
|
+
|
|
183
|
+
Creates and fully configures an app on App Store Connect using the [asc CLI](https://github.com/rudrankriyam/App-Store-Connect-CLI).
|
|
184
|
+
|
|
185
|
+
```bash
|
|
186
|
+
kappmaker create-appstore-app
|
|
187
|
+
kappmaker create-appstore-app --config ./my-config.json
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
### First-time setup
|
|
191
|
+
|
|
192
|
+
1. **Generate an API key** at [App Store Connect > Users and Access > Integrations > API](https://appstoreconnect.apple.com/access/integrations/api) — Admin access, download the `.p8` file immediately
|
|
193
|
+
2. **Run one-time setup:**
|
|
194
|
+
```bash
|
|
195
|
+
kappmaker config appstore-defaults --init
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
### What it does (13 steps)
|
|
199
|
+
|
|
200
|
+
1. Validate asc CLI and authentication
|
|
201
|
+
2. Load config (from file or interactive prompts)
|
|
202
|
+
3. Register Bundle ID
|
|
203
|
+
4. Find or create app
|
|
204
|
+
5. Set content rights
|
|
205
|
+
6. Create app version (1.0.0)
|
|
206
|
+
7. Set categories
|
|
207
|
+
8. Set age rating
|
|
208
|
+
9. Update localizations
|
|
209
|
+
10. Set pricing, availability, and subscriptions
|
|
210
|
+
11. Set privacy data usages
|
|
211
|
+
12. Set encryption declarations
|
|
212
|
+
13. Set review contact details
|
|
213
|
+
|
|
214
|
+
### Config resolution
|
|
215
|
+
|
|
216
|
+
Layers are deep-merged (later overrides earlier):
|
|
217
|
+
|
|
218
|
+
1. **Built-in template** — age rating, privacy, encryption, subscriptions
|
|
219
|
+
2. **Global defaults** (`~/.config/kappmaker/appstore-defaults.json`) — review contact, copyright
|
|
220
|
+
3. **Local config** (`./Assets/appstore-config.json` or `--config`)
|
|
221
|
+
4. **Interactive prompts** — only for fields still empty
|
|
222
|
+
|
|
223
|
+
### Default subscriptions
|
|
224
|
+
|
|
225
|
+
| Subscription | Period | Price | Product ID |
|
|
226
|
+
|-------------|--------|-------|------------|
|
|
227
|
+
| Weekly Premium | `ONE_WEEK` | $6.99 | `{appname}.premium.weekly.v1.699.v1` |
|
|
228
|
+
| Yearly Premium | `ONE_YEAR` | $29.99 | `{appname}.premium.yearly.v1.2999.v1` |
|
|
229
|
+
|
|
230
|
+
Auto-generated naming: group `{appname}.premium.v1`, ref name `{AppName} Premium Weekly v1 (6.99)`.
|
|
231
|
+
|
|
232
|
+
### Default privacy
|
|
233
|
+
|
|
234
|
+
| Data Category | Purpose | Protection |
|
|
235
|
+
|--------------|---------|------------|
|
|
236
|
+
| User ID | App Functionality | Linked to You |
|
|
237
|
+
| Device ID | App Functionality | Linked to You |
|
|
238
|
+
| Crash Data | Analytics | Not Linked to You |
|
|
239
|
+
| Performance Data | Analytics | Not Linked to You |
|
|
240
|
+
| Other Diagnostic Data | Analytics | Not Linked to You |
|
|
241
|
+
| Other Usage Data | Analytics | Not Linked to You |
|
|
242
|
+
| Product Interaction | Analytics | Not Linked to You |
|
|
243
|
+
|
|
244
|
+
During interactive setup, the CLI asks if the app accesses user content (AI image/video wrapper). If yes, adds Photos or Videos + Other User Content (both App Functionality / Not Linked to You).
|
|
245
|
+
|
|
246
|
+
| Flag | Description | Default |
|
|
247
|
+
|------|-------------|---------|
|
|
248
|
+
| `--config <path>` | Path to JSON config file | `./Assets/appstore-config.json` |
|
|
249
|
+
|
|
250
|
+
---
|
|
251
|
+
|
|
252
|
+
## `adapty setup`
|
|
253
|
+
|
|
254
|
+
Sets up Adapty subscription products, paywalls, and placements using the [Adapty CLI](https://github.com/adaptyteam/adapty-cli).
|
|
255
|
+
|
|
256
|
+
```bash
|
|
257
|
+
kappmaker adapty setup
|
|
258
|
+
kappmaker adapty setup --config ./my-config.json
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
**Prerequisites:** Install (`npm install -g adapty`) and log in (`adapty auth login`).
|
|
262
|
+
|
|
263
|
+
### What it does (8 steps)
|
|
264
|
+
|
|
265
|
+
1. Validate CLI and authentication
|
|
266
|
+
2. Load config (from file or interactive prompts)
|
|
267
|
+
3. Find or create app (iOS + Android)
|
|
268
|
+
4. Create "Premium" access level
|
|
269
|
+
5. Create products
|
|
270
|
+
6. Create paywalls (linking products)
|
|
271
|
+
7. Create placements (linking paywalls)
|
|
272
|
+
|
|
273
|
+
### Default products
|
|
274
|
+
|
|
275
|
+
| Product | Period | Price | iOS Product ID | Android Base Plan ID |
|
|
276
|
+
|---------|--------|-------|----------------|---------------------|
|
|
277
|
+
| Weekly Premium | `weekly` | $6.99 | `{appname}.premium.weekly.v1.699.v1` | `autorenew-weekly-price-v1` |
|
|
278
|
+
| Yearly Premium | `annual` | $29.99 | `{appname}.premium.yearly.v1.2999.v1` | `autorenew-yearly-price-v1` |
|
|
279
|
+
|
|
280
|
+
iOS product IDs match the App Store Connect format so they align across both systems.
|
|
281
|
+
|
|
282
|
+
### Default paywalls and placements
|
|
283
|
+
|
|
284
|
+
| Paywall | Products | Placement | Developer ID |
|
|
285
|
+
|---------|----------|-----------|-------------|
|
|
286
|
+
| Default Paywall | Weekly + Yearly | Default | `default` |
|
|
287
|
+
| Onboarding Paywall | Weekly + Yearly | Onboarding | `onboarding` |
|
|
288
|
+
|
|
289
|
+
| Flag | Description | Default |
|
|
290
|
+
|------|-------------|---------|
|
|
291
|
+
| `--config <path>` | Path to JSON config file | `./Assets/adapty-config.json` |
|
|
292
|
+
|
|
293
|
+
---
|
|
294
|
+
|
|
295
|
+
## Image Tools
|
|
296
|
+
|
|
297
|
+
AI-powered image commands. Require a fal.ai API key: `kappmaker config set falApiKey <your-key>`
|
|
298
|
+
|
|
299
|
+
### `image-split <source>`
|
|
300
|
+
|
|
301
|
+
Splits a grid image into individual tiles.
|
|
302
|
+
|
|
303
|
+
```bash
|
|
304
|
+
kappmaker image-split grid.png --rows 4 --cols 4 --zoom 1.1 --gap 3
|
|
305
|
+
kappmaker image-split grid.png --keep 1,5 # Keep only tiles 1 and 5
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
| Flag | Description | Default |
|
|
309
|
+
|------|-------------|---------|
|
|
310
|
+
| `--rows <n>` | Number of rows | `4` |
|
|
311
|
+
| `--cols <n>` | Number of columns | `4` |
|
|
312
|
+
| `--zoom <factor>` | Zoom factor to crop edges | `1.07` |
|
|
313
|
+
| `--gap <pixels>` | Gap pixels at each tile edge | `0` |
|
|
314
|
+
| `--width <pixels>` | Output tile width | `512` |
|
|
315
|
+
| `--height <pixels>` | Output tile height | `512` |
|
|
316
|
+
| `--output-dir <path>` | Directory to save tiles | `.` |
|
|
317
|
+
| `--keep <indices>` | Comma-separated tile indices to keep | All |
|
|
318
|
+
|
|
319
|
+
### `image-remove-bg <source>`
|
|
320
|
+
|
|
321
|
+
Removes background using fal.ai bria model. Outputs PNG with transparency.
|
|
322
|
+
|
|
323
|
+
```bash
|
|
324
|
+
kappmaker image-remove-bg logo.png
|
|
325
|
+
kappmaker image-remove-bg photo.jpg --output clean.png
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
| Flag | Description | Default |
|
|
329
|
+
|------|-------------|---------|
|
|
330
|
+
| `--output <path>` | Custom output path | `<filename>_no_bg.png` |
|
|
331
|
+
|
|
332
|
+
### `image-enhance <source>`
|
|
333
|
+
|
|
334
|
+
Upscales and improves image quality using fal.ai nano-banana-2 edit model.
|
|
335
|
+
|
|
336
|
+
```bash
|
|
337
|
+
kappmaker image-enhance logo.png
|
|
338
|
+
kappmaker image-enhance photo.jpg --output improved.png
|
|
339
|
+
```
|
|
340
|
+
|
|
341
|
+
| Flag | Description | Default |
|
|
342
|
+
|------|-------------|---------|
|
|
343
|
+
| `--output <path>` | Custom output path | `<filename>_enhanced.png` |
|
|
344
|
+
|
|
345
|
+
---
|
|
346
|
+
|
|
347
|
+
## `translate-screenshots [source-dir]`
|
|
348
|
+
|
|
349
|
+
Translates app screenshots into multiple locales using fal.ai and saves to Fastlane distribution directories.
|
|
350
|
+
|
|
351
|
+
```bash
|
|
352
|
+
kappmaker translate-screenshots # Uses default: MobileApp/distribution/.../en-US
|
|
353
|
+
kappmaker translate-screenshots ./screenshots/en-US # Custom source dir
|
|
354
|
+
kappmaker translate-screenshots ./screenshots/en-US --locales de-DE ja-JP # Specific locales
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
**Flow:**
|
|
358
|
+
1. Combines source images into a 2x4 grid
|
|
359
|
+
2. Submits grid to fal.ai for each locale (all in parallel)
|
|
360
|
+
3. Downloads translated grids, splits back into individual screenshots
|
|
361
|
+
4. Saves to Fastlane iOS/Android directory structure
|
|
362
|
+
|
|
363
|
+
**Output auto-detection:** If source is inside a distribution structure, the root is detected automatically. Otherwise defaults to `./MobileApp/distribution`.
|
|
364
|
+
|
|
365
|
+
| Flag | Description | Default |
|
|
366
|
+
|------|-------------|---------|
|
|
367
|
+
| `--output <path>` | Distribution directory root | Auto-detected |
|
|
368
|
+
| `--locales <codes...>` | Target locale codes (space-separated) or `all` | All 48 locales |
|
|
369
|
+
| `--rows <n>` | Grid rows | `2` |
|
|
370
|
+
| `--cols <n>` | Grid columns | `4` |
|
|
371
|
+
| `--resolution <res>` | AI resolution (`1K`, `2K`, `4K`) | `2K` |
|
|
372
|
+
| `--poll-interval <seconds>` | Seconds between status checks | `10` |
|
|
373
|
+
|
|
374
|
+
<details>
|
|
375
|
+
<summary>Supported locales (48 total)</summary>
|
|
376
|
+
|
|
377
|
+
| Play Store | App Store | | Play Store | App Store |
|
|
378
|
+
|------------|-----------|---|------------|-----------|
|
|
379
|
+
| `ar` | `ar-SA` | | `lt-LT` | — |
|
|
380
|
+
| `bg-BG` | — | | `lv-LV` | — |
|
|
381
|
+
| `bn-BD` | — | | `ms` | `ms` |
|
|
382
|
+
| `ca` | `ca` | | `nl-NL` | `nl-NL` |
|
|
383
|
+
| `cs-CZ` | `cs` | | `no-NO` | `no` |
|
|
384
|
+
| `da-DK` | `da` | | `pl-PL` | `pl` |
|
|
385
|
+
| `de-DE` | `de-DE` | | `pt-BR` | `pt-BR` |
|
|
386
|
+
| `el-GR` | `el` | | `pt-PT` | `pt-PT` |
|
|
387
|
+
| `en-AU` | `en-AU` | | `ro` | `ro` |
|
|
388
|
+
| `en-GB` | `en-GB` | | `ru-RU` | `ru` |
|
|
389
|
+
| `es-ES` | `es-ES` | | `sk` | `sk` |
|
|
390
|
+
| `es-419` | `es-MX` | | `sl-SI` | — |
|
|
391
|
+
| `et-EE` | — | | `sr` | — |
|
|
392
|
+
| `fi-FI` | `fi` | | `sv-SE` | `sv` |
|
|
393
|
+
| `fil` | — | | `sw` | — |
|
|
394
|
+
| `fr-FR` | `fr-FR` | | `ta-IN` | — |
|
|
395
|
+
| `fr-CA` | `fr-CA` | | `te-IN` | — |
|
|
396
|
+
| `he-IL` | `he` | | `th` | `th` |
|
|
397
|
+
| `hi-IN` | `hi` | | `tr-TR` | `tr` |
|
|
398
|
+
| `hr` | `hr` | | `uk` | `uk` |
|
|
399
|
+
| `hu-HU` | `hu` | | `vi` | `vi` |
|
|
400
|
+
| `id` | `id` | | `zh-CN` | `zh-Hans` |
|
|
401
|
+
| `it-IT` | `it` | | `zh-TW` | `zh-Hant` |
|
|
402
|
+
| `ja-JP` | `ja` | | | |
|
|
403
|
+
| `ko-KR` | `ko` | | | |
|
|
404
|
+
|
|
405
|
+
Locales marked with **—** are Android-only (no App Store equivalent).
|
|
406
|
+
|
|
407
|
+
</details>
|
|
408
|
+
|
|
409
|
+
---
|
|
410
|
+
|
|
411
|
+
## `generate-screenshots`
|
|
412
|
+
|
|
413
|
+
Generates marketing screenshots using OpenAI (prompt generation) + fal.ai (image generation).
|
|
414
|
+
|
|
415
|
+
```bash
|
|
416
|
+
kappmaker generate-screenshots --prompt "A fitness tracking app with workout plans"
|
|
417
|
+
kappmaker generate-screenshots --prompt "A meditation app" --input ./my-screenshots
|
|
418
|
+
kappmaker generate-screenshots --prompt "A recipe app" --style 3 --resolution 4K
|
|
419
|
+
```
|
|
420
|
+
|
|
421
|
+
**Flow:**
|
|
422
|
+
1. OpenAI (GPT-4.1) generates a detailed screenshot specification from your description
|
|
423
|
+
2. fal.ai generates a grid of 8 screenshots (`nano-banana-2`, or `nano-banana-2/edit` with reference images)
|
|
424
|
+
3. Grid is split into individual screenshots
|
|
425
|
+
|
|
426
|
+
**Output:** `Assets/screenshots/appstore/` + `Assets/screenshots/playstore/` (+ Fastlane dirs if `MobileApp/distribution` exists)
|
|
427
|
+
|
|
428
|
+
Requires: `falApiKey`, `openaiApiKey`, and `imgbbApiKey` (if using reference images)
|
|
429
|
+
|
|
430
|
+
| Flag | Description | Default |
|
|
431
|
+
|------|-------------|---------|
|
|
432
|
+
| `--prompt <text>` | App description (required) | — |
|
|
433
|
+
| `--input <dir>` | Reference screenshot directory | Auto-detect `Assets/screenshots` |
|
|
434
|
+
| `--style <id>` | Style preset (1-8) | `1` |
|
|
435
|
+
| `--output <dir>` | Output base directory | `Assets/screenshots` |
|
|
436
|
+
| `--resolution <res>` | AI resolution (`1K`, `2K`, `4K`) | `2K` |
|
|
437
|
+
|
|
438
|
+
<details>
|
|
439
|
+
<summary>Screenshot styles (1-8)</summary>
|
|
440
|
+
|
|
441
|
+
| Style | Description |
|
|
442
|
+
|-------|-------------|
|
|
443
|
+
| `1` | Rich multi-device marketing (bold text, shadows & reflections) |
|
|
444
|
+
| `2` | Minimal Apple-style (single centered device, clean whitespace) |
|
|
445
|
+
| `3` | SaaS conversion-focused (feature bullet callouts) |
|
|
446
|
+
| `4` | Bold geometric color blocks (vibrant split backgrounds) |
|
|
447
|
+
| `5` | Full-bleed UI, no device frames (edge-to-edge with blur overlay) |
|
|
448
|
+
| `6` | Cinematic depth (layered devices, depth-of-field) |
|
|
449
|
+
| `7` | Editorial lifestyle (soft neutral backgrounds, serif type) |
|
|
450
|
+
| `8` | Floating product reveal (Apple keynote aesthetic) |
|
|
451
|
+
|
|
452
|
+
</details>
|
|
453
|
+
|
|
454
|
+
---
|
|
455
|
+
|
|
456
|
+
## `config`
|
|
457
|
+
|
|
458
|
+
Manage CLI configuration stored at `~/.config/kappmaker/config.json`.
|
|
459
|
+
|
|
460
|
+
```bash
|
|
461
|
+
kappmaker config init # Interactive setup
|
|
462
|
+
kappmaker config list # Show all values
|
|
463
|
+
kappmaker config set <key> <value> # Set a value
|
|
464
|
+
kappmaker config get <key> # Get a value
|
|
465
|
+
kappmaker config path # Show config file path
|
|
466
|
+
kappmaker config appstore-defaults # View App Store defaults
|
|
467
|
+
kappmaker config appstore-defaults --init # Set up API key + review contact
|
|
468
|
+
kappmaker config appstore-defaults --save ./config.json # Save as global defaults
|
|
469
|
+
kappmaker config adapty-defaults # View Adapty defaults
|
|
470
|
+
kappmaker config adapty-defaults --save ./config.json # Save as global defaults
|
|
471
|
+
```
|
|
472
|
+
|
|
473
|
+
### Config keys
|
|
474
|
+
|
|
475
|
+
| Key | Description | Default |
|
|
476
|
+
|-----|-------------|---------|
|
|
477
|
+
| `templateRepo` | Template repository Git URL | KAppMaker template |
|
|
478
|
+
| `bundleIdPrefix` | Bundle/package ID prefix (e.g., `com.measify`) | `com.<appname>` |
|
|
479
|
+
| `androidSdkPath` | Android SDK location | `~/Library/Android/sdk` |
|
|
480
|
+
| `organization` | Organization for Fastlane signing | App name |
|
|
481
|
+
| `falApiKey` | fal.ai API key | — |
|
|
482
|
+
| `imgbbApiKey` | imgbb API key ([api.imgbb.com](https://api.imgbb.com/)) | — |
|
|
483
|
+
| `openaiApiKey` | OpenAI API key | — |
|
|
484
|
+
| `ascAuthName` | ASC keychain credential name | `KAppMaker` |
|
|
485
|
+
| `ascKeyId` | App Store Connect API Key ID | — |
|
|
486
|
+
| `ascIssuerId` | App Store Connect Issuer ID | — |
|
|
487
|
+
| `ascPrivateKeyPath` | Path to `.p8` private key | — |
|
|
488
|
+
| `appleId` | Apple ID email (for privacy setup) | — |
|
|
489
|
+
|
|
490
|
+
### Global defaults
|
|
491
|
+
|
|
492
|
+
| File | Used by | Manage with |
|
|
493
|
+
|------|---------|-------------|
|
|
494
|
+
| `~/.config/kappmaker/appstore-defaults.json` | `create-appstore-app` | `config appstore-defaults` |
|
|
495
|
+
| `~/.config/kappmaker/adapty-defaults.json` | `adapty setup` | `config adapty-defaults` |
|
|
496
|
+
|
|
497
|
+
Global defaults are merged as a base layer so shared settings (review contact, privacy, subscriptions, etc.) don't need to be re-entered per app.
|
|
498
|
+
|
|
499
|
+
---
|
|
500
|
+
|
|
501
|
+
## Project Structure
|
|
502
|
+
|
|
503
|
+
```
|
|
504
|
+
src/
|
|
505
|
+
index.ts # Entry point
|
|
506
|
+
cli.ts # Command registration (Commander.js)
|
|
507
|
+
commands/
|
|
508
|
+
create.ts # Full app setup (13-step orchestrator)
|
|
509
|
+
create-logo.ts # AI logo generation
|
|
510
|
+
create-appstore-app.ts # App Store Connect setup (13-step orchestrator)
|
|
511
|
+
adapty-setup.ts # Adapty setup (8-step orchestrator)
|
|
512
|
+
split.ts # Grid image splitter
|
|
513
|
+
remove-bg.ts # Background removal
|
|
514
|
+
enhance.ts # Image quality enhancement
|
|
515
|
+
translate-screenshots.ts # Screenshot translation
|
|
516
|
+
generate-screenshots.ts # AI screenshot generation
|
|
517
|
+
config.ts # Config management
|
|
518
|
+
services/
|
|
519
|
+
firebase.service.ts # Firebase CLI wrapper + anonymous auth
|
|
520
|
+
fal.service.ts # fal.ai API (generation, translation, screenshots)
|
|
521
|
+
openai.service.ts # OpenAI API (prompt generation)
|
|
522
|
+
asc.service.ts # App Store Connect CLI wrapper
|
|
523
|
+
asc-monetization.service.ts # ASC pricing, subscriptions, IAP
|
|
524
|
+
adapty.service.ts # Adapty CLI wrapper
|
|
525
|
+
git.service.ts # Git operations
|
|
526
|
+
gradle.service.ts # Gradle build operations
|
|
527
|
+
ios.service.ts # CocoaPods setup
|
|
528
|
+
fastlane.service.ts # Fastlane build + AAB finder
|
|
529
|
+
logo.service.ts # Logo prompt builder + image extraction
|
|
530
|
+
screenshot.service.ts # Screenshot grid operations + Fastlane output
|
|
531
|
+
screenshot-styles.ts # Screenshot style prompts (8 styles)
|
|
532
|
+
utils/
|
|
533
|
+
logger.ts # Chalk-based logging
|
|
534
|
+
exec.ts # Command execution (execa + ora)
|
|
535
|
+
validator.ts # Dependency and input validation
|
|
536
|
+
config.ts # User config management
|
|
537
|
+
prompt.ts # Interactive prompts
|
|
538
|
+
templates/
|
|
539
|
+
appstore-config.json # Default App Store Connect config
|
|
540
|
+
adapty-config.json # Default Adapty config
|
|
541
|
+
types/
|
|
542
|
+
index.ts # Shared interfaces
|
|
543
|
+
appstore.ts # App Store Connect types
|
|
544
|
+
adapty.ts # Adapty types
|
|
545
|
+
```
|
package/dist/cli.d.ts
ADDED