native-update 3.1.1 → 3.1.3

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.
Files changed (203) hide show
  1. package/AI-INTEGRATION-GUIDE.md +98 -63
  2. package/Readme.md +89 -120
  3. package/android/src/main/java/com/aoneahsan/nativeupdate/LiveUpdatePlugin.kt +88 -12
  4. package/android/src/main/java/com/aoneahsan/nativeupdate/NativeUpdatePlugin.kt +45 -18
  5. package/cli/package.json +2 -2
  6. package/dist/esm/definitions.d.ts +8 -0
  7. package/dist/esm/plugin.js +16 -2
  8. package/dist/plugin.cjs.js +1 -1
  9. package/dist/plugin.esm.js +1 -1
  10. package/dist/plugin.js +2 -2
  11. package/docs/CHANGELOG.md +108 -0
  12. package/docs/KNOWN_LIMITATIONS.md +2 -2
  13. package/docs/MIGRATION.md +1 -1
  14. package/ios/Plugin/LiveUpdate/LiveUpdatePlugin.swift +64 -8
  15. package/ios/Plugin/NativeUpdatePlugin.swift +39 -13
  16. package/package.json +8 -3
  17. package/docs/AGENTS.md +0 -47
  18. package/docs/APP_REVIEW_GUIDE.md +0 -768
  19. package/docs/BUNDLE_SIGNING.md +0 -277
  20. package/docs/CLAUDE.md +0 -110
  21. package/docs/COMPREHENSIVE_AUDIT_REPORT.md +0 -526
  22. package/docs/DEPLOY_NOTES.md +0 -117
  23. package/docs/EXAMPLE_APPS_SIMPLIFICATION_PLAN.md +0 -384
  24. package/docs/EXAMPLE_APPS_SIMPLIFICATION_TRACKER.md +0 -390
  25. package/docs/LIVE_UPDATES_GUIDE.md +0 -675
  26. package/docs/MANUAL-TASKS.md +0 -30
  27. package/docs/MARKETING_WEBSITE_TRACKER.md +0 -677
  28. package/docs/NATIVE_UPDATES_GUIDE.md +0 -695
  29. package/docs/PACKAGES.md +0 -167
  30. package/docs/PERFORMANCE.md +0 -110
  31. package/docs/PROJECT_COMPLETION_TRACKER.md +0 -411
  32. package/docs/QUICK_START.md +0 -595
  33. package/docs/README.md +0 -130
  34. package/docs/REMAINING_FEATURES.md +0 -192
  35. package/docs/ROADMAP.md +0 -295
  36. package/docs/SECURITY-IF-REPO-PUBLIC.md +0 -232
  37. package/docs/SECURITY.md +0 -356
  38. package/docs/TESTING_REQUIREMENTS.md +0 -201
  39. package/docs/ai-knowledge-base/00-project-profile.md +0 -38
  40. package/docs/ai-knowledge-base/01-features.md +0 -46
  41. package/docs/ai-knowledge-base/02-routes.md +0 -72
  42. package/docs/ai-knowledge-base/03-tech-stack.md +0 -57
  43. package/docs/ai-knowledge-base/README.md +0 -23
  44. package/docs/analytics-tracking.md +0 -37
  45. package/docs/api/API.md +0 -558
  46. package/docs/api/FEATURES.md +0 -414
  47. package/docs/api/app-review-api.md +0 -239
  48. package/docs/api/app-update-api.md +0 -154
  49. package/docs/api/background-update-api.md +0 -170
  50. package/docs/api/events-api.md +0 -323
  51. package/docs/api/live-update-api.md +0 -258
  52. package/docs/archive/MARKETING_WEBSITE_PLAN.md +0 -659
  53. package/docs/background-updates.md +0 -392
  54. package/docs/capacitor-official-plugins.md +0 -46
  55. package/docs/capawesome-plugins.md +0 -29
  56. package/docs/cli-reference.md +0 -321
  57. package/docs/deployment/HOSTINGER_DEPLOY.md +0 -370
  58. package/docs/deployment/PRODUCTION-DEPLOY-CHECKLIST.md +0 -184
  59. package/docs/docs-site/plan.md +0 -201
  60. package/docs/docs-site/scope.md +0 -127
  61. package/docs/docs-site/tracker.json +0 -235
  62. package/docs/error-handling-tracking.md +0 -37
  63. package/docs/examples/advanced-scenarios.md +0 -394
  64. package/docs/examples/android-manifest-example.xml +0 -77
  65. package/docs/examples/basic-usage.md +0 -206
  66. package/docs/examples/node-express-backend-example.md +0 -28
  67. package/docs/examples/react-capacitor-example.md +0 -29
  68. package/docs/features/app-reviews.md +0 -975
  69. package/docs/features/app-updates.md +0 -785
  70. package/docs/features/e2e-full-verification/00-overview.md +0 -99
  71. package/docs/features/e2e-full-verification/00-tracker.json +0 -284
  72. package/docs/features/e2e-full-verification/phase01-backend-schema-fixes.md +0 -183
  73. package/docs/features/e2e-full-verification/phase02-test-auth.md +0 -176
  74. package/docs/features/e2e-full-verification/phase03-api-test-coverage.md +0 -63
  75. package/docs/features/e2e-full-verification/phase04-frontend-package-contract-audit.md +0 -73
  76. package/docs/features/e2e-full-verification/phase05-browser-e2e-matrix.md +0 -69
  77. package/docs/features/e2e-full-verification/phase06-deploy-prod-smoke.md +0 -51
  78. package/docs/features/e2e-full-verification/results/phase01-drift-report.md +0 -50
  79. package/docs/features/e2e-full-verification/results/phase03-coverage-matrix.md +0 -215
  80. package/docs/features/e2e-full-verification/results/phase04-frontend-contract.md +0 -139
  81. package/docs/features/e2e-full-verification/results/phase05-e2e-results.md +0 -99
  82. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-01-dashboard.png +0 -0
  83. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-02-signup.png +0 -0
  84. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-03-settings-persisted.png +0 -0
  85. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-04a-app-created.png +0 -0
  86. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-04b-duplicate-bundle-422.png +0 -0
  87. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-05-plan-limit-403.png +0 -0
  88. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-08a-upload-graceful-fail.png +0 -0
  89. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-08b-builds-list.png +0 -0
  90. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-10-rollout-25pct.png +0 -0
  91. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-11-analytics.png +0 -0
  92. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-12-drive-disconnected.png +0 -0
  93. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-13-pricing.png +0 -0
  94. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-14-isolation-403.png +0 -0
  95. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-15a-admin-overview.png +0 -0
  96. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-15b-regular-user-admin-redirect.png +0 -0
  97. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-16a-delete-dialog.png +0 -0
  98. package/docs/features/e2e-full-verification/results/phase05-evidence/e2e-17-mobile-375.png +0 -0
  99. package/docs/features/e2e-full-verification/results/route-list.json +0 -1
  100. package/docs/features/laravel-nova-backend/ASSESSMENT-SUMMARY.md +0 -96
  101. package/docs/features/laravel-nova-backend/IMPLEMENTATION-PLAN.md +0 -504
  102. package/docs/features/laravel-nova-backend/progress-tracker.json +0 -184
  103. package/docs/features/live-updates.md +0 -642
  104. package/docs/features/queues-and-emails/00-overview.md +0 -41
  105. package/docs/features/queues-and-emails/00-tracker.json +0 -99
  106. package/docs/features/queues-and-emails/phase01-foundation.md +0 -15
  107. package/docs/features/queues-and-emails/phase02-queued-jobs.md +0 -19
  108. package/docs/features/queues-and-emails/phase03-transactional-emails.md +0 -16
  109. package/docs/features/queues-and-emails/phase04-quota-ops.md +0 -17
  110. package/docs/features/queues-and-emails/phase05-async-build-processing-DECISION.md +0 -16
  111. package/docs/features/queues-and-emails/phase06-verify-deploy.md +0 -17
  112. package/docs/getting-started/configuration.md +0 -469
  113. package/docs/getting-started/installation.md +0 -300
  114. package/docs/getting-started/quick-start.md +0 -430
  115. package/docs/guides/BACKEND_TEMPLATES_GUIDE.md +0 -183
  116. package/docs/guides/admin-panel.md +0 -268
  117. package/docs/guides/channel-management.md +0 -343
  118. package/docs/guides/dashboard-guide.md +0 -365
  119. package/docs/guides/deployment-guide.md +0 -335
  120. package/docs/guides/end-to-end-workflow.md +0 -491
  121. package/docs/guides/key-management.md +0 -284
  122. package/docs/guides/migration-from-codepush.md +0 -145
  123. package/docs/guides/security-best-practices.md +0 -1057
  124. package/docs/guides/testing-guide.md +0 -346
  125. package/docs/guides/troubleshooting.md +0 -482
  126. package/docs/package-audit.md +0 -41
  127. package/docs/plans/PLANNING_COMPLETE_SUMMARY.md +0 -361
  128. package/docs/plans/TASK_1_ANDROID_EXAMPLE_APP.md +0 -401
  129. package/docs/plans/TASK_2_API_ENDPOINTS.md +0 -856
  130. package/docs/plans/TASK_2_DASHBOARD_UI_UX.md +0 -820
  131. package/docs/plans/TASK_2_DATABASE_SCHEMA.md +0 -704
  132. package/docs/plans/TASK_2_GOOGLE_DRIVE_INTEGRATION.md +0 -646
  133. package/docs/plans/TASK_2_SAAS_ARCHITECTURE.md +0 -587
  134. package/docs/plans/TASK_2_USER_AUTHENTICATION.md +0 -600
  135. package/docs/play-store/ASO-METADATA.md +0 -5
  136. package/docs/play-store/DATA-SAFETY.md +0 -5
  137. package/docs/play-store/DECLARATIONS.md +0 -5
  138. package/docs/play-store/README.md +0 -27
  139. package/docs/play-store/RELEASE-NOTES.md +0 -99
  140. package/docs/play-store/RELEASE-STEPS.md +0 -6
  141. package/docs/play-store/STORE-LISTING.md +0 -7
  142. package/docs/play-store/SUBMISSION-CHECKLIST.md +0 -5
  143. package/docs/production-readiness.md +0 -475
  144. package/docs/project-audit/2026-05-16/00-FINALIZATION-PLAN.md +0 -123
  145. package/docs/project-audit/2026-05-16/01-BATCH-PLAN.md +0 -227
  146. package/docs/project-audit/2026-05-16/02-AUDIT-FINDINGS.md +0 -144
  147. package/docs/project-audit/2026-05-16/sessions/batch-01.md +0 -42
  148. package/docs/project-audit/2026-05-16/sessions/batch-02.md +0 -74
  149. package/docs/project-audit/2026-05-16/sessions/batch-03.md +0 -71
  150. package/docs/project-audit/2026-05-16/sessions/batch-04.md +0 -88
  151. package/docs/project-audit/2026-05-16/sessions/batch-05.md +0 -63
  152. package/docs/project-audit/2026-05-16/sessions/batch-06.md +0 -103
  153. package/docs/project-audit/2026-05-16/sessions/batch-07.md +0 -61
  154. package/docs/project-audit/2026-05-16/sessions/batch-08.md +0 -101
  155. package/docs/project-audit/2026-05-16/sessions/batch-09.md +0 -105
  156. package/docs/project-audit/2026-05-16/sessions/batch-10.md +0 -102
  157. package/docs/project-audit/AUDIT-HISTORY.md +0 -74
  158. package/docs/project-audit/BATCH-PLAN.md +0 -168
  159. package/docs/project-audit/MARKETING-WEBSITE-FINDINGS-2026-05-11.md +0 -73
  160. package/docs/project-audit/PRODUCTION-READINESS-AUDIT-2026-05-08.md +0 -275
  161. package/docs/project-finalization/00-tracker.json +0 -60
  162. package/docs/project-knowledge-base/01-system-overview.md +0 -227
  163. package/docs/project-knowledge-base/02-routes-pages-forms-users.md +0 -352
  164. package/docs/project-knowledge-base/03-tech-stack-modules-services.md +0 -379
  165. package/docs/project-knowledge-base/04-data-models-integrations.md +0 -244
  166. package/docs/project-knowledge-base/05-docs-corpus-inventory.md +0 -256
  167. package/docs/project-knowledge-base/06-operations-testing-legal-content.md +0 -208
  168. package/docs/project-knowledge-base/README.md +0 -103
  169. package/docs/project-profiles/native-update-capacitor-update-platform-project-profile-last-updated-2026-05-19.md +0 -81
  170. package/docs/reports/AUDIT_SUMMARY_2025-12-26.md +0 -203
  171. package/docs/reports/CLAUDE-CODE-COMPLETION-PROMPT.md +0 -403
  172. package/docs/reports/CLAUDE_CODE_PROMPT.md +0 -29
  173. package/docs/reports/CODEBASE_STATUS_REPORT.md +0 -272
  174. package/docs/reports/COMPLETE_VERIFICATION.md +0 -106
  175. package/docs/reports/COMPREHENSIVE-PROJECT-AUDIT-2026-02-24.md +0 -747
  176. package/docs/reports/EVENT_FLOW_VERIFICATION.md +0 -80
  177. package/docs/reports/EXAMPLE_APPS_SIMPLIFICATION_COMPLETE.md +0 -369
  178. package/docs/reports/FINAL_STATUS.md +0 -122
  179. package/docs/reports/FINAL_VERIFICATION_CHECKLIST.md +0 -425
  180. package/docs/reports/MARKETING_WEBSITE_COMPLETE.md +0 -466
  181. package/docs/reports/PACKAGE_COMPLETENESS_REPORT.md +0 -130
  182. package/docs/reports/PRODUCTION_STATUS.md +0 -115
  183. package/docs/reports/PROJECT_RESTRUCTURE_2025-12-27.md +0 -287
  184. package/docs/reports/PROJECT_RESTRUCTURE_FINAL_SUMMARY.md +0 -464
  185. package/docs/reports/PUBLISHING_VERIFICATION.md +0 -144
  186. package/docs/reports/RELEASE_READY_SUMMARY.md +0 -99
  187. package/docs/reports/claude-completion.json +0 -241
  188. package/docs/rules-tracker.md +0 -102
  189. package/docs/security/PRE-LAUNCH-PENTEST-CHECKLIST.md +0 -116
  190. package/docs/security/certificate-pinning.md +0 -122
  191. package/docs/seo-aeo-rules.json +0 -3043
  192. package/docs/social-media-marketing/README.md +0 -81
  193. package/docs/social-media-marketing/posts-batch-01.md +0 -613
  194. package/docs/social-media-marketing/posts-batch-02.md +0 -528
  195. package/docs/social-media-marketing/whatsapp-messages-batch-01.md +0 -458
  196. package/docs/social-media-marketing/whatsapp-status-batch-01.md +0 -355
  197. package/docs/tracking/IMPLEMENTATION_TRACKER.md +0 -303
  198. package/docs/tracking/capacitor-rollout-note-2026-03-01.md +0 -21
  199. package/docs/tracking/completion-tracker-2026-02-24.json +0 -174
  200. package/docs/tracking/finalization-2026-05-16-tracker.json +0 -346
  201. package/docs/tracking/full-audit-tracker.json +0 -121
  202. package/docs/tracking/production-readiness-audit-tracker.json +0 -429
  203. package/docs/tracking/seo-checklist-tracker.json +0 -333
@@ -1,365 +0,0 @@
1
- # Dashboard User Guide
2
-
3
- Complete guide to using the Native Update Dashboard at [nativeupdate.aoneahsan.com](https://nativeupdate.aoneahsan.com).
4
-
5
- ## Getting Started
6
-
7
- ### 1. Create an Account
8
-
9
- 1. Visit [nativeupdate.aoneahsan.com](https://nativeupdate.aoneahsan.com)
10
- 2. Click **Get Started** or **Sign Up**
11
- 3. Sign in with your Google account
12
- 4. You'll be redirected to the dashboard
13
-
14
- ### 2. Connect Google Drive
15
-
16
- Before uploading builds, connect your Google Drive for storage:
17
-
18
- 1. Go to **Dashboard > Google Drive**
19
- 2. Click **Connect Google Drive**
20
- 3. Authorize the application
21
- 4. Your builds will be stored in a dedicated folder
22
-
23
- ## Dashboard Overview
24
-
25
- ### Navigation
26
-
27
- The dashboard sidebar contains:
28
-
29
- | Section | Description |
30
- |---------|-------------|
31
- | **Overview** | Dashboard home with stats |
32
- | **Apps** | Manage your applications |
33
- | **Builds** | View and manage all builds |
34
- | **Upload** | Upload new builds |
35
- | **Rollouts** | Manage gradual rollouts |
36
- | **Analytics** | View update metrics |
37
- | **Google Drive** | Manage storage connection |
38
- | **Configuration** | Get integration code snippets |
39
- | **Settings** | Account settings |
40
-
41
- ## Managing Apps
42
-
43
- ### Creating an App
44
-
45
- 1. Go to **Dashboard > Apps**
46
- 2. Click **Create App**
47
- 3. Fill in the details:
48
- - **App Name**: Display name (e.g., "My Awesome App")
49
- - **Package ID**: Unique identifier (e.g., `com.example.myapp`)
50
- - **Description**: Brief description
51
- - **Platforms**: Select iOS, Android, and/or Web
52
- 4. Click **Create App**
53
-
54
- ### App Details Page
55
-
56
- Click on any app to view:
57
-
58
- - **Overview Cards**: Total builds, active users, platforms, last build date
59
- - **Channels**: Production, staging, development settings
60
- - **Active Rollouts**: Current rollout status
61
- - **Recent Builds**: Latest builds for this app
62
-
63
- ### Configuring Channels
64
-
65
- Each app has three channels with configurable settings:
66
-
67
- 1. In the app details page, find the **Channels** section
68
- 2. Click **Configure** on any channel
69
- 3. Adjust settings:
70
- - **Enabled**: Turn channel on/off
71
- - **Auto Update**: Automatically install updates
72
- - **Update Strategy**: immediate/background/manual
73
- - **Require User Consent**: Ask before installing
74
- - **Min Version**: Minimum required app version
75
-
76
- ## Uploading Builds
77
-
78
- ### Upload Process
79
-
80
- 1. Go to **Dashboard > Upload**
81
- 2. **Select App**: Choose from your registered apps
82
- 3. **Select Channel**: production, staging, or development
83
- 4. **Select Platform**: iOS, Android, or Web
84
- 5. **Upload File**: Drag and drop or click to select
85
- - Supported formats: `.zip`, `.apk`, `.ipa`
86
- 6. **Enter Version Info**:
87
- - **Version**: Semantic version (e.g., 1.2.3)
88
- - **Build Number**: Incremental build number
89
- - **Release Notes**: What's new in this version
90
- - **Release Type**: major/minor/patch/hotfix
91
- - **Pre-release**: Check if this is a beta/alpha
92
-
93
- 7. Click **Upload Build**
94
-
95
- ### Build Requirements
96
-
97
- | Platform | File Type | Contents |
98
- |----------|-----------|----------|
99
- | Web | `.zip` | Built web assets (dist/www folder) |
100
- | Android | `.apk` or `.zip` | APK or web assets |
101
- | iOS | `.ipa` or `.zip` | IPA or web assets |
102
-
103
- ### Upload Progress
104
-
105
- The upload page shows:
106
- - Upload progress percentage
107
- - File validation status
108
- - Checksum generation
109
- - Google Drive upload status
110
-
111
- ## Managing Builds
112
-
113
- ### Builds List
114
-
115
- Go to **Dashboard > Builds** to see all builds:
116
-
117
- - **Version**: Build version (clickable for details)
118
- - **App**: Associated application
119
- - **Channel**: Deployment channel
120
- - **Platform**: Target platform
121
- - **Status**: active/processing/failed/archived
122
- - **Size**: File size
123
- - **Uploaded**: Upload date/time
124
-
125
- ### Build Detail Page
126
-
127
- Click on a version to view complete build information:
128
-
129
- **Stats Cards**:
130
- - Downloads: Total download count
131
- - Installs: Successful installations
132
- - Rollbacks: Reverted updates
133
- - Errors: Failed installations
134
-
135
- **Build Information**:
136
- - Version, build number, version code
137
- - Channel, platform, release type
138
- - Pre-release status
139
-
140
- **File Details**:
141
- - File name, size, type, MIME type
142
- - Checksum (SHA-256)
143
- - Signature (if signed)
144
-
145
- **Release Notes**:
146
- - Full release notes text
147
-
148
- **Upload Information**:
149
- - Upload timestamp
150
- - Uploader email
151
- - Upload duration
152
-
153
- ### Build Actions
154
-
155
- - **Download**: Download the build file from Google Drive
156
- - **Delete**: Remove the build (with confirmation)
157
-
158
- ## Rollouts
159
-
160
- ### Creating a Rollout
161
-
162
- 1. Go to **Dashboard > Rollouts**
163
- 2. Click **Create Rollout**
164
- 3. Select app and channel
165
- 4. Set initial percentage (e.g., 10%)
166
- 5. Click **Start Rollout**
167
-
168
- ### Managing Rollouts
169
-
170
- For active rollouts, you can:
171
-
172
- - **Increase Percentage**: Gradually roll out to more users
173
- - **Pause**: Stop the rollout temporarily
174
- - **Resume**: Continue a paused rollout
175
- - **Complete**: Set to 100% to finish rollout
176
-
177
- ### Rollout Status
178
-
179
- | Status | Description |
180
- |--------|-------------|
181
- | Active | Rollout is in progress |
182
- | Paused | Rollout is temporarily stopped |
183
- | Completed | Rollout reached 100% |
184
-
185
- ## Analytics
186
-
187
- ### Overview Metrics
188
-
189
- The Analytics page shows:
190
-
191
- - **Total Downloads**: All-time download count
192
- - **Total Installs**: Successful installations
193
- - **Success Rate**: Install/download ratio
194
- - **Active Users**: Currently active users
195
-
196
- ### Per-App Analytics
197
-
198
- Select an app to view:
199
-
200
- - Download trends over time
201
- - Install success rates
202
- - Error rates
203
- - Rollback statistics
204
- - Channel-specific metrics
205
-
206
- ## Configuration
207
-
208
- ### Getting Integration Code
209
-
210
- 1. Go to **Dashboard > Configuration**
211
- 2. Select your app from the dropdown
212
- 3. Copy the configuration for your platform:
213
-
214
- **iOS (Info.plist)**:
215
- ```xml
216
- <key>NativeUpdateConfig</key>
217
- <dict>
218
- <key>appId</key>
219
- <string>com.example.myapp</string>
220
- <key>updateUrl</key>
221
- <string>https://nativeupdate.aoneahsan.com/api/updates</string>
222
- <key>channel</key>
223
- <string>production</string>
224
- </dict>
225
- ```
226
-
227
- **Android (AndroidManifest.xml)**:
228
- ```xml
229
- <meta-data
230
- android:name="com.aoneahsan.nativeupdate.appId"
231
- android:value="com.example.myapp" />
232
- <meta-data
233
- android:name="com.aoneahsan.nativeupdate.updateUrl"
234
- android:value="https://nativeupdate.aoneahsan.com/api/updates" />
235
- ```
236
-
237
- **Capacitor (capacitor.config.ts)**:
238
- ```typescript
239
- plugins: {
240
- NativeUpdate: {
241
- appId: 'com.example.myapp',
242
- updateUrl: 'https://nativeupdate.aoneahsan.com/api/updates',
243
- channel: 'production',
244
- }
245
- }
246
- ```
247
-
248
- **JavaScript/TypeScript**:
249
- ```typescript
250
- import { NativeUpdate } from 'native-update';
251
-
252
- await NativeUpdate.configure({
253
- updateUrl: 'https://nativeupdate.aoneahsan.com/api/updates',
254
- });
255
- ```
256
-
257
- ## Settings
258
-
259
- ### Account Settings
260
-
261
- Go to **Dashboard > Settings** to manage:
262
-
263
- - **Profile**: Display name, email, photo
264
- - **Preferences**:
265
- - Email notifications
266
- - Update notifications
267
- - Theme (light/dark/auto)
268
- - Language
269
-
270
- ### Plan Information
271
-
272
- View your current plan:
273
-
274
- - **Beta**: Free tier with full features
275
- - **Pro**: Enhanced limits and support
276
- - **Enterprise**: Custom solutions
277
-
278
- ## Common Workflows
279
-
280
- ### First-Time Setup
281
-
282
- 1. Sign up and connect Google Drive
283
- 2. Create your first app
284
- 3. Configure channel settings
285
- 4. Copy integration code to your app
286
- 5. Build and upload your first version
287
- 6. Test on development channel
288
- 7. Promote to staging, then production
289
-
290
- ### Deploying an Update
291
-
292
- 1. Make changes to your app code
293
- 2. Build: `yarn build` or `npm run build`
294
- 3. Go to Dashboard > Upload
295
- 4. Select app, channel, and platform
296
- 5. Upload the build file
297
- 6. Add version and release notes
298
- 7. Monitor in Analytics
299
-
300
- ### Emergency Hotfix
301
-
302
- 1. Fix the critical issue in code
303
- 2. Build immediately
304
- 3. Upload to production channel
305
- 4. Set release type to "hotfix"
306
- 5. Create immediate rollout (100%)
307
- 6. Monitor for issues
308
-
309
- ### Rolling Back
310
-
311
- 1. Go to Dashboard > Builds
312
- 2. Find the previous stable version
313
- 3. Create a new rollout for that version
314
- 4. Or: The plugin automatically rolls back on crash
315
-
316
- ## Troubleshooting
317
-
318
- ### Upload Failed
319
-
320
- - **Check file size**: Max 500MB per upload
321
- - **Check file format**: Must be .zip, .apk, or .ipa
322
- - **Check Google Drive**: Ensure connected and has space
323
- - **Check network**: Stable connection required
324
-
325
- ### Build Not Appearing on Device
326
-
327
- 1. Verify build is uploaded to correct channel
328
- 2. Check device is configured for same channel
329
- 3. Force sync: Call `NativeUpdate.sync()`
330
- 4. Check app version compatibility
331
-
332
- ### Google Drive Disconnected
333
-
334
- 1. Go to Dashboard > Google Drive
335
- 2. Click **Reconnect**
336
- 3. Re-authorize the application
337
-
338
- ### Analytics Not Updating
339
-
340
- - Allow 15-30 minutes for data processing
341
- - Ensure devices have network connectivity
342
- - Check that events are being sent from app
343
-
344
- ## API Endpoint
345
-
346
- The dashboard uses this API endpoint for updates:
347
-
348
- ```
349
- https://nativeupdate.aoneahsan.com/api/updates
350
- ```
351
-
352
- Use this URL in your app configuration.
353
-
354
- ## Support
355
-
356
- - **Email**: aoneahsan@gmail.com
357
- - **Documentation**: [docs folder](https://nativeupdate.aoneahsan.com/docs)
358
- - **Website**: [nativeupdate.aoneahsan.com](https://nativeupdate.aoneahsan.com)
359
-
360
- ## Related Documentation
361
-
362
- - [Channel Management](https://nativeupdate.aoneahsan.com/docs/guides/channel-management)
363
- - [Quick Start Guide](https://nativeupdate.aoneahsan.com/docs/getting-started/quick-start)
364
- - [Configuration Guide](https://nativeupdate.aoneahsan.com/docs/getting-started/configuration)
365
- - [End-to-End Workflow](https://nativeupdate.aoneahsan.com/docs/guides/end-to-end-workflow)
@@ -1,335 +0,0 @@
1
- # Deployment Guide
2
-
3
- This guide covers deploying the Capacitor Native Update plugin to production.
4
-
5
- ## Prerequisites
6
-
7
- - Capacitor Native Update plugin configured
8
- - Update server deployed
9
- - SSL certificates configured
10
- - CDN setup (optional but recommended)
11
-
12
- ## Server Deployment
13
-
14
- ### 1. Environment Setup
15
-
16
- ```bash
17
- # Clone production backend
18
- cd production-backend
19
-
20
- # Install dependencies
21
- yarn install
22
-
23
- # Set environment variables
24
- cp .env.example .env
25
- # Edit .env with production values
26
- ```
27
-
28
- ### 2. Database Setup
29
-
30
- ```bash
31
- # Initialize production database
32
- yarn db:init
33
-
34
- # For PostgreSQL (recommended for production)
35
- # Update DB_PATH in .env to PostgreSQL connection string
36
- ```
37
-
38
- ### 3. Security Configuration
39
-
40
- ```env
41
- # .env production settings
42
- NODE_ENV=production
43
- JWT_SECRET=<generate-strong-secret>
44
- ADMIN_PASSWORD=<strong-password>
45
-
46
- # Enable HTTPS only
47
- ALLOWED_ORIGINS=https://your-app.com,capacitor://localhost
48
-
49
- # Rate limiting
50
- RATE_LIMIT_WINDOW=15
51
- RATE_LIMIT_MAX=100
52
- ```
53
-
54
- ### 4. Deploy to Cloud
55
-
56
- #### Option A: Docker Deployment
57
-
58
- ```dockerfile
59
- # Dockerfile
60
- FROM node:20-alpine
61
- WORKDIR /app
62
- COPY package*.json ./
63
- RUN npm ci --only=production
64
- COPY . .
65
- EXPOSE 3000
66
- CMD ["npm", "start"]
67
- ```
68
-
69
- ```bash
70
- # Build and run
71
- docker build -t update-server .
72
- docker run -p 3000:3000 update-server
73
- ```
74
-
75
- #### Option B: PM2 Deployment
76
-
77
- ```bash
78
- # Install PM2
79
- yarn install -g pm2
80
-
81
- # Start server
82
- pm2 start src/index.js --name update-server
83
-
84
- # Save PM2 config
85
- pm2 save
86
- pm2 startup
87
- ```
88
-
89
- ## App Configuration
90
-
91
- ### 1. Production Keys
92
-
93
- ```bash
94
- # Generate RSA keys for production
95
- npx native-update keys generate --type rsa --size 4096
96
-
97
- # This creates:
98
- # - private-[timestamp].pem (keep secure on CI/CD server)
99
- # - public-[timestamp].pem (embed in app)
100
- ```
101
-
102
- ### 2. Configure Plugin
103
-
104
- ```typescript
105
- await NativeUpdate.configure({
106
- serverUrl: 'https://updates.your-domain.com',
107
- publicKey: PRODUCTION_PUBLIC_KEY,
108
- channel: 'production',
109
- autoCheck: true,
110
- checkInterval: 3600000, // 1 hour
111
- });
112
- ```
113
-
114
- ## CDN Setup
115
-
116
- ### 1. CloudFront Configuration
117
-
118
- ```json
119
- {
120
- "Origins": [{
121
- "DomainName": "update-server.your-domain.com",
122
- "OriginPath": "/api/bundles"
123
- }],
124
- "DefaultCacheBehavior": {
125
- "TargetOriginId": "update-bundles",
126
- "ViewerProtocolPolicy": "https-only",
127
- "CachePolicyId": "658327ea-f89e-4fab-a63d-7e88639e58f6"
128
- }
129
- }
130
- ```
131
-
132
- ### 2. Update Server Config
133
-
134
- ```javascript
135
- // Return CDN URLs for bundles
136
- const cdnUrl = process.env.CDN_URL;
137
- bundle.downloadUrl = `${cdnUrl}/${bundle.id}`;
138
- ```
139
-
140
- ## Monitoring Setup
141
-
142
- ### 1. Application Monitoring
143
-
144
- ```bash
145
- # Install monitoring dependencies
146
- yarn install @opentelemetry/api @opentelemetry/sdk-node
147
-
148
- # Configure in server
149
- const { NodeSDK } = require('@opentelemetry/sdk-node');
150
- const sdk = new NodeSDK();
151
- sdk.start();
152
- ```
153
-
154
- ### 2. Health Checks
155
-
156
- ```bash
157
- # Monitor endpoints
158
- curl https://updates.your-domain.com/api/health
159
- curl https://updates.your-domain.com/api/health/detailed
160
- ```
161
-
162
- ### 3. Alerts Configuration
163
-
164
- ```yaml
165
- # CloudWatch alarms example
166
- HighErrorRate:
167
- MetricName: 4XXError
168
- Threshold: 10
169
- Period: 300
170
-
171
- ServerDown:
172
- MetricName: HealthCheck
173
- Threshold: 1
174
- Period: 60
175
- ```
176
-
177
- ## Release Process
178
-
179
- ### 1. Create Update Bundle
180
-
181
- ```bash
182
- # Build your app
183
- yarn build
184
-
185
- # Create bundle
186
- npx native-update bundle create ./www
187
-
188
- # Sign bundle
189
- npx native-update bundle sign bundle.zip --key private-key.pem
190
- ```
191
-
192
- ### 2. Upload to Server
193
-
194
- ```bash
195
- # Create update record
196
- curl -X POST https://updates.your-domain.com/api/updates/create \
197
- -H "Authorization: Bearer $TOKEN" \
198
- -H "Content-Type: application/json" \
199
- -d '{
200
- "appId": "com.your.app",
201
- "platform": "web",
202
- "version": "1.1.0",
203
- "channel": "production",
204
- "description": "Bug fixes and improvements"
205
- }'
206
-
207
- # Upload bundle
208
- curl -X POST https://updates.your-domain.com/api/bundles/upload/$UPDATE_ID \
209
- -H "Authorization: Bearer $TOKEN" \
210
- -F "bundle=@bundle.zip" \
211
- -F "signature=@bundle.sig"
212
- ```
213
-
214
- ### 3. Gradual Rollout
215
-
216
- ```bash
217
- # Start with 10% rollout
218
- curl -X PUT https://updates.your-domain.com/api/updates/$UPDATE_ID \
219
- -H "Authorization: Bearer $TOKEN" \
220
- -H "Content-Type: application/json" \
221
- -d '{"rolloutPercentage": 10}'
222
-
223
- # Monitor metrics, then increase
224
- # 10% -> 25% -> 50% -> 100%
225
- ```
226
-
227
- ## Security Checklist
228
-
229
- - [ ] HTTPS enforced on all endpoints
230
- - [ ] API authentication configured
231
- - [ ] Rate limiting enabled
232
- - [ ] CORS properly configured
233
- - [ ] Bundle signatures verified
234
- - [ ] SSL certificates valid
235
- - [ ] Secrets stored securely
236
- - [ ] Database backups configured
237
- - [ ] Access logs enabled
238
- - [ ] Security headers configured
239
-
240
- ## Performance Optimization
241
-
242
- ### 1. Enable Compression
243
-
244
- ```javascript
245
- // Already included in production server
246
- app.use(compression());
247
- ```
248
-
249
- ### 2. Database Indexing
250
-
251
- ```sql
252
- -- Ensure indexes exist
253
- CREATE INDEX idx_updates_lookup
254
- ON updates(app_id, platform, channel, enabled);
255
- ```
256
-
257
- ### 3. Bundle Optimization
258
-
259
- ```bash
260
- # Compress bundles before upload
261
- zip -r -9 bundle.zip www/
262
-
263
- # Consider differential updates
264
- # Only include changed files
265
- ```
266
-
267
- ## Backup Strategy
268
-
269
- ### 1. Database Backups
270
-
271
- ```bash
272
- # Daily backups
273
- 0 2 * * * pg_dump update_db > backup_$(date +\%Y\%m\%d).sql
274
-
275
- # Keep 30 days of backups
276
- find ./backups -name "*.sql" -mtime +30 -delete
277
- ```
278
-
279
- ### 2. Bundle Storage
280
-
281
- ```bash
282
- # Sync bundles to S3
283
- aws s3 sync ./storage/bundles s3://your-backup-bucket/bundles
284
- ```
285
-
286
- ## Troubleshooting
287
-
288
- ### Common Issues
289
-
290
- 1. **SSL Certificate Errors**
291
- - Verify certificate chain
292
- - Check certificate expiration
293
- - Ensure proper domain configuration
294
-
295
- 2. **CORS Issues**
296
- - Add app origin to ALLOWED_ORIGINS
297
- - Check preflight requests
298
-
299
- 3. **Download Failures**
300
- - Check CDN configuration
301
- - Verify bundle permissions
302
- - Monitor server logs
303
-
304
- ### Debug Mode
305
-
306
- ```typescript
307
- // Enable debug logging in production
308
- NativeUpdate.configure({
309
- debug: process.env.NODE_ENV !== 'production',
310
- serverUrl: 'https://updates.your-domain.com',
311
- });
312
- ```
313
-
314
- ## Maintenance
315
-
316
- ### Regular Tasks
317
-
318
- - [ ] Weekly: Check server health
319
- - [ ] Monthly: Review analytics
320
- - [ ] Monthly: Clean old bundles
321
- - [ ] Quarterly: Update dependencies
322
- - [ ] Yearly: Rotate certificates
323
-
324
- ### Update Server
325
-
326
- ```bash
327
- # Update dependencies
328
- npm update
329
-
330
- # Restart server
331
- pm2 restart update-server
332
-
333
- # Check logs
334
- pm2 logs update-server
335
- ```