@capawesome/capacitor-live-update 6.8.0 → 7.0.0-dev.2633ff2.1765953041

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 (54) hide show
  1. package/CapawesomeCapacitorLiveUpdate.podspec +3 -3
  2. package/Package.swift +32 -0
  3. package/README.md +438 -86
  4. package/android/build.gradle +12 -12
  5. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/LiveUpdate.java +754 -279
  6. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/LiveUpdateConfig.java +29 -27
  7. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/LiveUpdateHttpClient.java +40 -7
  8. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/LiveUpdatePlugin.java +210 -67
  9. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/LiveUpdatePreferences.java +52 -3
  10. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/api/GetLatestBundleResponse.java +11 -2
  11. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/events/DownloadBundleProgressEvent.java +32 -0
  12. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/{results/GetBundleResult.java → events/NextBundleSetEvent.java} +9 -7
  13. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/options/SetConfigOptions.java +19 -0
  14. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/options/SyncOptions.java +4 -0
  15. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/FetchLatestBundleResult.java +8 -0
  16. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/GetBlockedBundlesResult.java +27 -0
  17. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/GetConfigResult.java +40 -0
  18. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/GetDownloadedBundlesResult.java +27 -0
  19. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/IsSyncingResult.java +26 -0
  20. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/results/ReadyResult.java +32 -0
  21. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/interfaces/DownloadProgressCallback.java +5 -0
  22. package/dist/docs.json +597 -102
  23. package/dist/esm/definitions.d.ts +338 -39
  24. package/dist/esm/definitions.js.map +1 -1
  25. package/dist/esm/index.js +1 -1
  26. package/dist/esm/index.js.map +1 -1
  27. package/dist/esm/web.d.ts +9 -2
  28. package/dist/esm/web.js +21 -0
  29. package/dist/esm/web.js.map +1 -1
  30. package/dist/plugin.cjs.js +22 -3
  31. package/dist/plugin.cjs.js.map +1 -1
  32. package/dist/plugin.js +22 -3
  33. package/dist/plugin.js.map +1 -1
  34. package/ios/Plugin/Classes/Events/DownloadBundleProgressEvent.swift +25 -0
  35. package/ios/Plugin/Classes/{Results/GetBundleResult.swift → Events/NextBundleSetEvent.swift} +3 -3
  36. package/ios/Plugin/Classes/Options/SetConfigOptions.swift +14 -0
  37. package/ios/Plugin/Classes/Options/SyncOptions.swift +4 -0
  38. package/ios/Plugin/Classes/Results/{FetchLatestBundle.swift → FetchLatestBundleResult.swift} +6 -1
  39. package/ios/Plugin/Classes/Results/GetBlockedBundlesResult.swift +16 -0
  40. package/ios/Plugin/Classes/Results/GetConfigResult.swift +19 -0
  41. package/ios/Plugin/Classes/Results/GetDownloadedBundlesResult.swift +16 -0
  42. package/ios/Plugin/Classes/Results/IsSyncingResult.swift +16 -0
  43. package/ios/Plugin/Classes/Results/ReadyResult.swift +22 -0
  44. package/ios/Plugin/LiveUpdate.swift +365 -149
  45. package/ios/Plugin/LiveUpdateConfig.swift +4 -4
  46. package/ios/Plugin/LiveUpdateHttpClient.swift +10 -4
  47. package/ios/Plugin/LiveUpdatePlugin.swift +136 -34
  48. package/ios/Plugin/LiveUpdatePreferences.swift +54 -12
  49. package/ios/Plugin/Protocols/Api/GetLatestBundleResponse.swift +1 -0
  50. package/package.json +19 -20
  51. package/android/src/main/java/io/capawesome/capacitorjs/plugins/liveupdate/classes/options/SetBundleOptions.java +0 -18
  52. package/ios/Plugin/Classes/Options/SetBundleOptions.swift +0 -14
  53. package/ios/Plugin/LiveUpdatePlugin.h +0 -10
  54. package/ios/Plugin/LiveUpdatePlugin.m +0 -27
package/dist/docs.json CHANGED
@@ -5,6 +5,21 @@
5
5
  "docs": "",
6
6
  "tags": [],
7
7
  "methods": [
8
+ {
9
+ "name": "clearBlockedBundles",
10
+ "signature": "() => Promise<void>",
11
+ "parameters": [],
12
+ "returns": "Promise<void>",
13
+ "tags": [
14
+ {
15
+ "name": "since",
16
+ "text": "7.4.0"
17
+ }
18
+ ],
19
+ "docs": "Clear all blocked bundles from the blocked list.\n\nThis removes all bundle identifiers that were automatically blocked\ndue to rollbacks when `autoBlockRolledBackBundles` is enabled.\n\nOnly available on Android and iOS.",
20
+ "complexTypes": [],
21
+ "slug": "clearblockedbundles"
22
+ },
8
23
  {
9
24
  "name": "deleteBundle",
10
25
  "signature": "(options: DeleteBundleOptions) => Promise<void>",
@@ -76,25 +91,21 @@
76
91
  "slug": "fetchlatestbundle"
77
92
  },
78
93
  {
79
- "name": "getBundle",
80
- "signature": "() => Promise<GetBundleResult>",
94
+ "name": "getBlockedBundles",
95
+ "signature": "() => Promise<GetBlockedBundlesResult>",
81
96
  "parameters": [],
82
- "returns": "Promise<GetBundleResult>",
97
+ "returns": "Promise<GetBlockedBundlesResult>",
83
98
  "tags": [
84
99
  {
85
100
  "name": "since",
86
- "text": "5.0.0"
87
- },
88
- {
89
- "name": "deprecated",
90
- "text": "Use `getCurrentBundle()` instead."
101
+ "text": "7.4.0"
91
102
  }
92
103
  ],
93
- "docs": "Get the active bundle identifier.\n\nOnly available on Android and iOS.",
104
+ "docs": "Get all blocked bundle identifiers.\n\nReturns the list of bundle identifiers that were automatically blocked\ndue to rollbacks when `autoBlockRolledBackBundles` is enabled.\n\nOnly available on Android and iOS.",
94
105
  "complexTypes": [
95
- "GetBundleResult"
106
+ "GetBlockedBundlesResult"
96
107
  ],
97
- "slug": "getbundle"
108
+ "slug": "getblockedbundles"
98
109
  },
99
110
  {
100
111
  "name": "getBundles",
@@ -105,6 +116,10 @@
105
116
  {
106
117
  "name": "since",
107
118
  "text": "5.0.0"
119
+ },
120
+ {
121
+ "name": "deprecated",
122
+ "text": "Use `getDownloadedBundles()` instead."
108
123
  }
109
124
  ],
110
125
  "docs": "Get all identifiers of bundles that have been downloaded.\n\nOnly available on Android and iOS.",
@@ -130,6 +145,40 @@
130
145
  ],
131
146
  "slug": "getchannel"
132
147
  },
148
+ {
149
+ "name": "getConfig",
150
+ "signature": "() => Promise<GetConfigResult>",
151
+ "parameters": [],
152
+ "returns": "Promise<GetConfigResult>",
153
+ "tags": [
154
+ {
155
+ "name": "since",
156
+ "text": "7.4.0"
157
+ }
158
+ ],
159
+ "docs": "Get the runtime configuration.\n\nReturns the current plugin configuration including any runtime\noverrides set via `setConfig()`.\n\nOnly available on Android and iOS.",
160
+ "complexTypes": [
161
+ "GetConfigResult"
162
+ ],
163
+ "slug": "getconfig"
164
+ },
165
+ {
166
+ "name": "getDownloadedBundles",
167
+ "signature": "() => Promise<GetDownloadedBundlesResult>",
168
+ "parameters": [],
169
+ "returns": "Promise<GetDownloadedBundlesResult>",
170
+ "tags": [
171
+ {
172
+ "name": "since",
173
+ "text": "7.4.0"
174
+ }
175
+ ],
176
+ "docs": "Get all identifiers of bundles that have been downloaded.\n\nOnly available on Android and iOS.",
177
+ "complexTypes": [
178
+ "GetDownloadedBundlesResult"
179
+ ],
180
+ "slug": "getdownloadedbundles"
181
+ },
133
182
  {
134
183
  "name": "getCurrentBundle",
135
184
  "signature": "() => Promise<GetCurrentBundleResult>",
@@ -181,6 +230,23 @@
181
230
  ],
182
231
  "slug": "getdeviceid"
183
232
  },
233
+ {
234
+ "name": "isSyncing",
235
+ "signature": "() => Promise<IsSyncingResult>",
236
+ "parameters": [],
237
+ "returns": "Promise<IsSyncingResult>",
238
+ "tags": [
239
+ {
240
+ "name": "since",
241
+ "text": "7.4.0"
242
+ }
243
+ ],
244
+ "docs": "Check whether a sync operation is currently in progress.\n\nOnly available on Android and iOS.",
245
+ "complexTypes": [
246
+ "IsSyncingResult"
247
+ ],
248
+ "slug": "issyncing"
249
+ },
184
250
  {
185
251
  "name": "getNextBundle",
186
252
  "signature": "() => Promise<GetNextBundleResult>",
@@ -209,7 +275,7 @@
209
275
  "text": "5.0.0"
210
276
  }
211
277
  ],
212
- "docs": "Get the version code of the app.\n\nOnly available on Android and iOS.",
278
+ "docs": "Get the version code of the app.\n\nOn **Android**, this is the `versionCode` from the `android/app/build.gradle` file.\nOn **iOS**, this is the `CFBundleVersion` from the `Info.plist` file.\n\nOnly available on Android and iOS.",
213
279
  "complexTypes": [
214
280
  "GetVersionCodeResult"
215
281
  ],
@@ -226,7 +292,7 @@
226
292
  "text": "5.0.0"
227
293
  }
228
294
  ],
229
- "docs": "Get the version name of the app.\n\nOnly available on Android and iOS.",
295
+ "docs": "Get the version name of the app.\n\nOn **Android**, this is the `versionName` from the `android/app/build.gradle` file.\nOn **iOS**, this is the `CFBundleShortVersionString` from the `Info.plist` file.\n\nOnly available on Android and iOS.",
230
296
  "complexTypes": [
231
297
  "GetVersionNameResult"
232
298
  ],
@@ -234,9 +300,9 @@
234
300
  },
235
301
  {
236
302
  "name": "ready",
237
- "signature": "() => Promise<void>",
303
+ "signature": "() => Promise<ReadyResult>",
238
304
  "parameters": [],
239
- "returns": "Promise<void>",
305
+ "returns": "Promise<ReadyResult>",
240
306
  "tags": [
241
307
  {
242
308
  "name": "since",
@@ -244,7 +310,9 @@
244
310
  }
245
311
  ],
246
312
  "docs": "Notify the plugin that the app is ready to use and no rollback is needed.\n\n**Attention**: This method should be called as soon as the app is ready to use\nto prevent the app from being reset to the default bundle.\n\nOnly available on Android and iOS.",
247
- "complexTypes": [],
313
+ "complexTypes": [
314
+ "ReadyResult"
315
+ ],
248
316
  "slug": "ready"
249
317
  },
250
318
  {
@@ -278,13 +346,28 @@
278
346
  "slug": "reset"
279
347
  },
280
348
  {
281
- "name": "setBundle",
282
- "signature": "(options: SetBundleOptions) => Promise<void>",
349
+ "name": "resetConfig",
350
+ "signature": "() => Promise<void>",
351
+ "parameters": [],
352
+ "returns": "Promise<void>",
353
+ "tags": [
354
+ {
355
+ "name": "since",
356
+ "text": "7.4.0"
357
+ }
358
+ ],
359
+ "docs": "Reset the runtime configuration to the values from the Capacitor config file.\n\nThis clears any runtime configuration set via `setConfig()`.\nThe changes take effect immediately.\n\nOnly available on Android and iOS.",
360
+ "complexTypes": [],
361
+ "slug": "resetconfig"
362
+ },
363
+ {
364
+ "name": "setChannel",
365
+ "signature": "(options: SetChannelOptions) => Promise<void>",
283
366
  "parameters": [
284
367
  {
285
368
  "name": "options",
286
369
  "docs": "",
287
- "type": "SetBundleOptions"
370
+ "type": "SetChannelOptions"
288
371
  }
289
372
  ],
290
373
  "returns": "Promise<void>",
@@ -292,40 +375,36 @@
292
375
  {
293
376
  "name": "since",
294
377
  "text": "5.0.0"
295
- },
296
- {
297
- "name": "deprecated",
298
- "text": "Use `setNextBundle()` instead."
299
378
  }
300
379
  ],
301
- "docs": "Set the next bundle to use for the app.\n\nCall `reload()` or restart the app to apply the changes.\n\nOnly available on Android and iOS.",
380
+ "docs": "Set the channel to use for the update.\n\nOnly available on Android and iOS.",
302
381
  "complexTypes": [
303
- "SetBundleOptions"
382
+ "SetChannelOptions"
304
383
  ],
305
- "slug": "setbundle"
384
+ "slug": "setchannel"
306
385
  },
307
386
  {
308
- "name": "setChannel",
309
- "signature": "(options: SetChannelOptions) => Promise<void>",
387
+ "name": "setConfig",
388
+ "signature": "(options: SetConfigOptions) => Promise<void>",
310
389
  "parameters": [
311
390
  {
312
391
  "name": "options",
313
392
  "docs": "",
314
- "type": "SetChannelOptions"
393
+ "type": "SetConfigOptions"
315
394
  }
316
395
  ],
317
396
  "returns": "Promise<void>",
318
397
  "tags": [
319
398
  {
320
399
  "name": "since",
321
- "text": "5.0.0"
400
+ "text": "7.4.0"
322
401
  }
323
402
  ],
324
- "docs": "Set the channel to use for the update.\n\nOnly available on Android and iOS.",
403
+ "docs": "Set the runtime configuration.\n\nThis allows updating plugin configuration options at runtime.\nThe changes are persisted across app restarts and take effect immediately.\n\n**Important:** Runtime configuration is automatically reset to default values\nwhenever the native app is updated to a new version. This ensures that\nconfiguration from previous versions doesn't persist after an app update.\n\nOnly available on Android and iOS.",
325
404
  "complexTypes": [
326
- "SetChannelOptions"
405
+ "SetConfigOptions"
327
406
  ],
328
- "slug": "setchannel"
407
+ "slug": "setconfig"
329
408
  },
330
409
  {
331
410
  "name": "setCustomId",
@@ -396,6 +475,108 @@
396
475
  "SyncOptions"
397
476
  ],
398
477
  "slug": "sync"
478
+ },
479
+ {
480
+ "name": "addListener",
481
+ "signature": "(eventName: 'downloadBundleProgress', listenerFunc: DownloadBundleProgressListener) => Promise<PluginListenerHandle>",
482
+ "parameters": [
483
+ {
484
+ "name": "eventName",
485
+ "docs": "",
486
+ "type": "'downloadBundleProgress'"
487
+ },
488
+ {
489
+ "name": "listenerFunc",
490
+ "docs": "",
491
+ "type": "DownloadBundleProgressListener"
492
+ }
493
+ ],
494
+ "returns": "Promise<PluginListenerHandle>",
495
+ "tags": [
496
+ {
497
+ "name": "since",
498
+ "text": "7.0.0"
499
+ }
500
+ ],
501
+ "docs": "Listen for the download progress of a bundle.\n\nOnly available on Android and iOS.",
502
+ "complexTypes": [
503
+ "PluginListenerHandle",
504
+ "DownloadBundleProgressListener"
505
+ ],
506
+ "slug": "addlistenerdownloadbundleprogress-"
507
+ },
508
+ {
509
+ "name": "addListener",
510
+ "signature": "(eventName: 'nextBundleSet', listenerFunc: NextBundleSetListener) => Promise<PluginListenerHandle>",
511
+ "parameters": [
512
+ {
513
+ "name": "eventName",
514
+ "docs": "",
515
+ "type": "'nextBundleSet'"
516
+ },
517
+ {
518
+ "name": "listenerFunc",
519
+ "docs": "",
520
+ "type": "NextBundleSetListener"
521
+ }
522
+ ],
523
+ "returns": "Promise<PluginListenerHandle>",
524
+ "tags": [
525
+ {
526
+ "name": "since",
527
+ "text": "7.3.0"
528
+ }
529
+ ],
530
+ "docs": "Listen for when a bundle is set as the next bundle.\n\nThis event is triggered whenever a bundle is set to be used on the next app restart,\neither through automatic updates or manual calls to `setNextBundle()`.\n\nOnly available on Android and iOS.",
531
+ "complexTypes": [
532
+ "PluginListenerHandle",
533
+ "NextBundleSetListener"
534
+ ],
535
+ "slug": "addlistenernextbundleset-"
536
+ },
537
+ {
538
+ "name": "addListener",
539
+ "signature": "(eventName: 'reloaded', listenerFunc: ReloadedListener) => Promise<PluginListenerHandle>",
540
+ "parameters": [
541
+ {
542
+ "name": "eventName",
543
+ "docs": "",
544
+ "type": "'reloaded'"
545
+ },
546
+ {
547
+ "name": "listenerFunc",
548
+ "docs": "",
549
+ "type": "ReloadedListener"
550
+ }
551
+ ],
552
+ "returns": "Promise<PluginListenerHandle>",
553
+ "tags": [
554
+ {
555
+ "name": "since",
556
+ "text": "7.4.0"
557
+ }
558
+ ],
559
+ "docs": "Listen for when the app is reloaded.\n\nThis event is triggered after the `reload()` method is called\nand the app has been reloaded.\n\n**Note:** To verify whether an update was successfully applied after a reload,\nuse the `ready()` method instead. The `ready()` method provides detailed information\nabout the current bundle, previous bundle, and whether a rollback occurred.\n\nOnly available on Android and iOS.",
560
+ "complexTypes": [
561
+ "PluginListenerHandle",
562
+ "ReloadedListener"
563
+ ],
564
+ "slug": "addlistenerreloaded-"
565
+ },
566
+ {
567
+ "name": "removeAllListeners",
568
+ "signature": "() => Promise<void>",
569
+ "parameters": [],
570
+ "returns": "Promise<void>",
571
+ "tags": [
572
+ {
573
+ "name": "since",
574
+ "text": "7.2.0"
575
+ }
576
+ ],
577
+ "docs": "Remove all listeners for this plugin.",
578
+ "complexTypes": [],
579
+ "slug": "removealllisteners"
399
580
  }
400
581
  ],
401
582
  "properties": []
@@ -470,7 +651,7 @@
470
651
  "name": "example"
471
652
  }
472
653
  ],
473
- "docs": "The unique identifier of the bundle.",
654
+ "docs": "The unique identifier of the bundle.\n\n**Attention**: The value `public` is reserved and cannot be used as a bundle identifier.",
474
655
  "complexTypes": [],
475
656
  "type": "string"
476
657
  },
@@ -478,7 +659,7 @@
478
659
  "name": "checksum",
479
660
  "tags": [
480
661
  {
481
- "text": "6.1.0",
662
+ "text": "7.1.0",
482
663
  "name": "since"
483
664
  }
484
665
  ],
@@ -490,7 +671,7 @@
490
671
  "name": "signature",
491
672
  "tags": [
492
673
  {
493
- "text": "6.8.0",
674
+ "text": "7.1.0",
494
675
  "name": "since"
495
676
  }
496
677
  ],
@@ -510,7 +691,7 @@
510
691
  "name": "example"
511
692
  }
512
693
  ],
513
- "docs": "The URL of the bundle to download.\n\nFor the `zip` artifact type, the URL must point to a ZIP file.\nFor the `manifest` artifact type, the URL serves as the base URL\nto download the individual files. For example, if the URL is\n`https://example.com/download`, the plugin will download the file\nwith the href `index.html` from `https://example.com/download?href=index.html`.\n\nTo **verify the integrity** of the file, the server must return\na `X-Checksum` header with the SHA-256 hash in base64 format.\n\nTo **verify the signature** of the file, the server must return\na `X-Signature` header with the signed SHA-256 hash in base64 format.",
694
+ "docs": "The URL of the bundle to download.\n\nFor the `zip` artifact type, the URL must point to a ZIP file.\nFor the `manifest` artifact type, the URL serves as the base URL\nto download the individual files. For example, if the URL is\n`https://example.com/download`, the plugin will download the file\nwith the href `index.html` from `https://example.com/download?href=index.html`.\n\nTo **verify the integrity** of the file, the server should return\na `X-Checksum` header with the SHA-256 hash in base64 format.\n\nTo **verify the signature** of the file, the server should return\na `X-Signature` header with the signed SHA-256 hash in base64 format.",
514
695
  "complexTypes": [],
515
696
  "type": "string"
516
697
  }
@@ -556,7 +737,7 @@
556
737
  "name": "checksum",
557
738
  "tags": [
558
739
  {
559
- "text": "6.8.0",
740
+ "text": "7.1.0",
560
741
  "name": "since"
561
742
  }
562
743
  ],
@@ -564,6 +745,22 @@
564
745
  "complexTypes": [],
565
746
  "type": "string | undefined"
566
747
  },
748
+ {
749
+ "name": "customProperties",
750
+ "tags": [
751
+ {
752
+ "text": "7.0.0",
753
+ "name": "since"
754
+ },
755
+ {
756
+ "text": "{ \"key\": \"value\" }",
757
+ "name": "example"
758
+ }
759
+ ],
760
+ "docs": "Custom properties that are associated with the latest bundle.",
761
+ "complexTypes": [],
762
+ "type": "{ [key: string]: string; } | undefined"
763
+ },
567
764
  {
568
765
  "name": "downloadUrl",
569
766
  "tags": [
@@ -580,7 +777,7 @@
580
777
  "name": "signature",
581
778
  "tags": [
582
779
  {
583
- "text": "6.8.0",
780
+ "text": "7.1.0",
584
781
  "name": "since"
585
782
  }
586
783
  ],
@@ -617,32 +814,28 @@
617
814
  ]
618
815
  },
619
816
  {
620
- "name": "GetBundleResult",
621
- "slug": "getbundleresult",
817
+ "name": "GetBlockedBundlesResult",
818
+ "slug": "getblockedbundlesresult",
622
819
  "docs": "",
623
820
  "tags": [
624
821
  {
625
- "text": "5.0.0",
822
+ "text": "7.4.0",
626
823
  "name": "since"
627
824
  }
628
825
  ],
629
826
  "methods": [],
630
827
  "properties": [
631
828
  {
632
- "name": "bundleId",
829
+ "name": "bundleIds",
633
830
  "tags": [
634
831
  {
635
- "text": "5.0.0",
832
+ "text": "7.4.0",
636
833
  "name": "since"
637
- },
638
- {
639
- "text": "'1.0.0'",
640
- "name": "example"
641
834
  }
642
835
  ],
643
- "docs": "The unique identifier of the active bundle.\n\nIf `null`, the default bundle is being used.",
836
+ "docs": "An array of unique identifiers of all blocked bundles.",
644
837
  "complexTypes": [],
645
- "type": "string | null"
838
+ "type": "string[]"
646
839
  }
647
840
  ]
648
841
  },
@@ -702,6 +895,78 @@
702
895
  }
703
896
  ]
704
897
  },
898
+ {
899
+ "name": "GetConfigResult",
900
+ "slug": "getconfigresult",
901
+ "docs": "",
902
+ "tags": [
903
+ {
904
+ "text": "7.4.0",
905
+ "name": "since"
906
+ }
907
+ ],
908
+ "methods": [],
909
+ "properties": [
910
+ {
911
+ "name": "appId",
912
+ "tags": [
913
+ {
914
+ "text": "7.4.0",
915
+ "name": "since"
916
+ },
917
+ {
918
+ "text": "'6e351b4f-69a7-415e-a057-4567df7ffe94'",
919
+ "name": "example"
920
+ }
921
+ ],
922
+ "docs": "The app ID used to identify the app.\n\nIf `null`, no app ID is configured.",
923
+ "complexTypes": [],
924
+ "type": "string | null"
925
+ },
926
+ {
927
+ "name": "autoUpdateStrategy",
928
+ "tags": [
929
+ {
930
+ "text": "7.4.0",
931
+ "name": "since"
932
+ },
933
+ {
934
+ "text": "'background'",
935
+ "name": "example"
936
+ }
937
+ ],
938
+ "docs": "The auto-update strategy for live updates.",
939
+ "complexTypes": [],
940
+ "type": "'none' | 'background'"
941
+ }
942
+ ]
943
+ },
944
+ {
945
+ "name": "GetDownloadedBundlesResult",
946
+ "slug": "getdownloadedbundlesresult",
947
+ "docs": "",
948
+ "tags": [
949
+ {
950
+ "text": "7.4.0",
951
+ "name": "since"
952
+ }
953
+ ],
954
+ "methods": [],
955
+ "properties": [
956
+ {
957
+ "name": "bundleIds",
958
+ "tags": [
959
+ {
960
+ "text": "7.4.0",
961
+ "name": "since"
962
+ }
963
+ ],
964
+ "docs": "An array of unique identifiers of all downloaded bundles.",
965
+ "complexTypes": [],
966
+ "type": "string[]"
967
+ }
968
+ ]
969
+ },
705
970
  {
706
971
  "name": "GetCurrentBundleResult",
707
972
  "slug": "getcurrentbundleresult",
@@ -788,6 +1053,32 @@
788
1053
  }
789
1054
  ]
790
1055
  },
1056
+ {
1057
+ "name": "IsSyncingResult",
1058
+ "slug": "issyncingresult",
1059
+ "docs": "",
1060
+ "tags": [
1061
+ {
1062
+ "text": "7.4.0",
1063
+ "name": "since"
1064
+ }
1065
+ ],
1066
+ "methods": [],
1067
+ "properties": [
1068
+ {
1069
+ "name": "syncing",
1070
+ "tags": [
1071
+ {
1072
+ "text": "7.4.0",
1073
+ "name": "since"
1074
+ }
1075
+ ],
1076
+ "docs": "Whether a sync operation is currently in progress.",
1077
+ "complexTypes": [],
1078
+ "type": "boolean"
1079
+ }
1080
+ ]
1081
+ },
791
1082
  {
792
1083
  "name": "GetNextBundleResult",
793
1084
  "slug": "getnextbundleresult",
@@ -875,32 +1166,52 @@
875
1166
  ]
876
1167
  },
877
1168
  {
878
- "name": "SetBundleOptions",
879
- "slug": "setbundleoptions",
1169
+ "name": "ReadyResult",
1170
+ "slug": "readyresult",
880
1171
  "docs": "",
881
1172
  "tags": [
882
1173
  {
883
- "text": "5.0.0",
1174
+ "text": "7.0.0",
884
1175
  "name": "since"
885
1176
  }
886
1177
  ],
887
1178
  "methods": [],
888
1179
  "properties": [
889
1180
  {
890
- "name": "bundleId",
1181
+ "name": "previousBundleId",
891
1182
  "tags": [
892
1183
  {
893
- "text": "5.0.0",
1184
+ "text": "7.0.0",
894
1185
  "name": "since"
895
- },
1186
+ }
1187
+ ],
1188
+ "docs": "The identifier of the previous bundle used.\n\nIf `null`, the default bundle was used.",
1189
+ "complexTypes": [],
1190
+ "type": "string | null"
1191
+ },
1192
+ {
1193
+ "name": "currentBundleId",
1194
+ "tags": [
896
1195
  {
897
- "text": "'1.0.0'",
898
- "name": "example"
1196
+ "text": "7.0.0",
1197
+ "name": "since"
899
1198
  }
900
1199
  ],
901
- "docs": "The unique identifier of the bundle to use.",
1200
+ "docs": "The identifier of the current bundle used.\n\nIf `null`, the default bundle is being used.",
902
1201
  "complexTypes": [],
903
- "type": "string"
1202
+ "type": "string | null"
1203
+ },
1204
+ {
1205
+ "name": "rollback",
1206
+ "tags": [
1207
+ {
1208
+ "text": "7.0.0",
1209
+ "name": "since"
1210
+ }
1211
+ ],
1212
+ "docs": "Whether or not the app was reset to the default bundle.",
1213
+ "complexTypes": [],
1214
+ "type": "boolean"
904
1215
  }
905
1216
  ]
906
1217
  },
@@ -930,6 +1241,36 @@
930
1241
  }
931
1242
  ]
932
1243
  },
1244
+ {
1245
+ "name": "SetConfigOptions",
1246
+ "slug": "setconfigoptions",
1247
+ "docs": "",
1248
+ "tags": [
1249
+ {
1250
+ "text": "7.4.0",
1251
+ "name": "since"
1252
+ }
1253
+ ],
1254
+ "methods": [],
1255
+ "properties": [
1256
+ {
1257
+ "name": "appId",
1258
+ "tags": [
1259
+ {
1260
+ "text": "7.4.0",
1261
+ "name": "since"
1262
+ },
1263
+ {
1264
+ "text": "'6e351b4f-69a7-415e-a057-4567df7ffe94'",
1265
+ "name": "example"
1266
+ }
1267
+ ],
1268
+ "docs": "The app ID used to identify the app.\n\nSet `null` to reset to the value from the Capacitor config file.",
1269
+ "complexTypes": [],
1270
+ "type": "string | null | undefined"
1271
+ }
1272
+ ]
1273
+ },
933
1274
  {
934
1275
  "name": "SetCustomIdOptions",
935
1276
  "slug": "setcustomidoptions",
@@ -1037,10 +1378,160 @@
1037
1378
  "type": "string | undefined"
1038
1379
  }
1039
1380
  ]
1381
+ },
1382
+ {
1383
+ "name": "PluginListenerHandle",
1384
+ "slug": "pluginlistenerhandle",
1385
+ "docs": "",
1386
+ "tags": [],
1387
+ "methods": [],
1388
+ "properties": [
1389
+ {
1390
+ "name": "remove",
1391
+ "tags": [],
1392
+ "docs": "",
1393
+ "complexTypes": [],
1394
+ "type": "() => Promise<void>"
1395
+ }
1396
+ ]
1397
+ },
1398
+ {
1399
+ "name": "DownloadBundleProgressEvent",
1400
+ "slug": "downloadbundleprogressevent",
1401
+ "docs": "Event that is triggered when the download progress of a bundle changes.",
1402
+ "tags": [
1403
+ {
1404
+ "text": "7.0.0",
1405
+ "name": "since"
1406
+ }
1407
+ ],
1408
+ "methods": [],
1409
+ "properties": [
1410
+ {
1411
+ "name": "bundleId",
1412
+ "tags": [
1413
+ {
1414
+ "text": "7.0.0",
1415
+ "name": "since"
1416
+ }
1417
+ ],
1418
+ "docs": "The unique identifier of the bundle that is being downloaded.",
1419
+ "complexTypes": [],
1420
+ "type": "string"
1421
+ },
1422
+ {
1423
+ "name": "downloadedBytes",
1424
+ "tags": [
1425
+ {
1426
+ "text": "7.0.0",
1427
+ "name": "since"
1428
+ }
1429
+ ],
1430
+ "docs": "The number of bytes that have been downloaded.",
1431
+ "complexTypes": [],
1432
+ "type": "number"
1433
+ },
1434
+ {
1435
+ "name": "progress",
1436
+ "tags": [
1437
+ {
1438
+ "text": "7.0.0",
1439
+ "name": "since"
1440
+ },
1441
+ {
1442
+ "text": "0.5",
1443
+ "name": "example"
1444
+ }
1445
+ ],
1446
+ "docs": "The progress of the download in percent as a value between `0` and `1`.",
1447
+ "complexTypes": [],
1448
+ "type": "number"
1449
+ },
1450
+ {
1451
+ "name": "totalBytes",
1452
+ "tags": [
1453
+ {
1454
+ "text": "7.0.0",
1455
+ "name": "since"
1456
+ }
1457
+ ],
1458
+ "docs": "The total number of bytes to download.",
1459
+ "complexTypes": [],
1460
+ "type": "number"
1461
+ }
1462
+ ]
1463
+ },
1464
+ {
1465
+ "name": "NextBundleSetEvent",
1466
+ "slug": "nextbundlesetevent",
1467
+ "docs": "Event that is triggered when a bundle is set as the next bundle.",
1468
+ "tags": [
1469
+ {
1470
+ "text": "7.3.0",
1471
+ "name": "since"
1472
+ }
1473
+ ],
1474
+ "methods": [],
1475
+ "properties": [
1476
+ {
1477
+ "name": "bundleId",
1478
+ "tags": [
1479
+ {
1480
+ "text": "7.3.0",
1481
+ "name": "since"
1482
+ },
1483
+ {
1484
+ "text": "'1.0.0'",
1485
+ "name": "example"
1486
+ }
1487
+ ],
1488
+ "docs": "The unique identifier of the bundle that is set as the next bundle.\n\nIf `null`, the default bundle will be used.",
1489
+ "complexTypes": [],
1490
+ "type": "string | null"
1491
+ }
1492
+ ]
1040
1493
  }
1041
1494
  ],
1042
1495
  "enums": [],
1043
- "typeAliases": [],
1496
+ "typeAliases": [
1497
+ {
1498
+ "name": "DownloadBundleProgressListener",
1499
+ "slug": "downloadbundleprogresslistener",
1500
+ "docs": "Listener for the download progress of a bundle.",
1501
+ "types": [
1502
+ {
1503
+ "text": "(event: DownloadBundleProgressEvent): void",
1504
+ "complexTypes": [
1505
+ "DownloadBundleProgressEvent"
1506
+ ]
1507
+ }
1508
+ ]
1509
+ },
1510
+ {
1511
+ "name": "NextBundleSetListener",
1512
+ "slug": "nextbundlesetlistener",
1513
+ "docs": "Listener for when a bundle is set as the next bundle.",
1514
+ "types": [
1515
+ {
1516
+ "text": "(event: NextBundleSetEvent): void",
1517
+ "complexTypes": [
1518
+ "NextBundleSetEvent"
1519
+ ]
1520
+ }
1521
+ ]
1522
+ },
1523
+ {
1524
+ "name": "ReloadedListener",
1525
+ "slug": "reloadedlistener",
1526
+ "docs": "Listener for when the app is reloaded.",
1527
+ "types": [
1528
+ {
1529
+ "text": "(): void",
1530
+ "complexTypes": []
1531
+ }
1532
+ ]
1533
+ }
1534
+ ],
1044
1535
  "pluginConfigs": [
1045
1536
  {
1046
1537
  "name": "LiveUpdate",
@@ -1058,15 +1549,15 @@
1058
1549
  "name": "example"
1059
1550
  }
1060
1551
  ],
1061
- "docs": "The app ID is used to identify the app when using [Capawesome Cloud](https://capawesome.io/cloud).\n\nThis is **NOT** the same as the app identifier (e.g. `com.example.app`).\nThis is a unique identifier generated by Capawesome Cloud (e.g. `6e351b4f-69a7-415e-a057-4567df7ffe94`).",
1552
+ "docs": "The app ID is used to identify the app when using [Capawesome Cloud](https://capawesome.io/cloud/).\n\nThis is **NOT** the same as the app identifier (e.g. `com.example.app`).\nThis is a unique identifier generated by Capawesome Cloud (e.g. `6e351b4f-69a7-415e-a057-4567df7ffe94`).",
1062
1553
  "complexTypes": [],
1063
1554
  "type": "string | undefined"
1064
1555
  },
1065
1556
  {
1066
- "name": "autoDeleteBundles",
1557
+ "name": "autoBlockRolledBackBundles",
1067
1558
  "tags": [
1068
1559
  {
1069
- "text": "5.0.0",
1560
+ "text": "7.3.0",
1070
1561
  "name": "since"
1071
1562
  },
1072
1563
  {
@@ -1074,81 +1565,77 @@
1074
1565
  "name": "default"
1075
1566
  }
1076
1567
  ],
1077
- "docs": "Whether or not to automatically delete unused bundles.\n\nWhen enabled, the plugin will automatically delete unused bundles after calling `ready()`.",
1568
+ "docs": "Whether or not to automatically block bundles that have been rolled back.\n\nWhen enabled, the plugin will automatically block bundles that caused a rollback\n(up to 100 bundles). When the limit is reached, the oldest blocked bundle is unblocked.\nBlocked bundles will be skipped in future sync operations.\n\n**Attention**: This option has no effect if `readyTimeout` is set to `0`.\n\nOnly available on Android and iOS.",
1078
1569
  "complexTypes": [],
1079
1570
  "type": "boolean | undefined"
1080
1571
  },
1081
1572
  {
1082
- "name": "defaultChannel",
1573
+ "name": "autoDeleteBundles",
1083
1574
  "tags": [
1084
1575
  {
1085
- "text": "6.3.0",
1576
+ "text": "5.0.0",
1086
1577
  "name": "since"
1087
1578
  },
1088
1579
  {
1089
- "text": "'production'",
1090
- "name": "example"
1580
+ "text": "false",
1581
+ "name": "default"
1091
1582
  }
1092
1583
  ],
1093
- "docs": "The default channel of the app.",
1584
+ "docs": "Whether or not to automatically delete unused bundles.\n\nWhen enabled, the plugin will automatically delete unused bundles after calling `ready()`.",
1094
1585
  "complexTypes": [],
1095
- "type": "string | undefined"
1586
+ "type": "boolean | undefined"
1096
1587
  },
1097
1588
  {
1098
- "name": "enabled",
1589
+ "name": "autoUpdateStrategy",
1099
1590
  "tags": [
1100
1591
  {
1101
- "text": "5.0.0",
1592
+ "text": "7.3.0",
1102
1593
  "name": "since"
1103
1594
  },
1104
1595
  {
1105
- "text": "true",
1596
+ "text": "'none'",
1106
1597
  "name": "default"
1598
+ },
1599
+ {
1600
+ "text": "'background'",
1601
+ "name": "example"
1107
1602
  }
1108
1603
  ],
1109
- "docs": "Whether or not the plugin is enabled.",
1604
+ "docs": "The auto-update strategy for live updates.\n\n- `none`: Live updates will not be applied automatically.\n- `background`: Live updates will be automatically downloaded\nand applied in the background at app startup and when the app resumes\n(if the last check was more than 15 minutes ago).\n\nOnly available on Android and iOS.",
1110
1605
  "complexTypes": [],
1111
- "type": "boolean | undefined"
1606
+ "type": "'none' | 'background' | undefined"
1112
1607
  },
1113
1608
  {
1114
- "name": "httpTimeout",
1609
+ "name": "defaultChannel",
1115
1610
  "tags": [
1116
1611
  {
1117
- "text": "6.4.0",
1612
+ "text": "6.3.0",
1118
1613
  "name": "since"
1119
1614
  },
1120
1615
  {
1121
- "text": "60000",
1122
- "name": "default"
1616
+ "text": "'production'",
1617
+ "name": "example"
1123
1618
  }
1124
1619
  ],
1125
- "docs": "The timeout in milliseconds for HTTP requests.",
1620
+ "docs": "The default channel of the app.",
1126
1621
  "complexTypes": [],
1127
- "type": "number | undefined"
1622
+ "type": "string | undefined"
1128
1623
  },
1129
1624
  {
1130
- "name": "location",
1625
+ "name": "httpTimeout",
1131
1626
  "tags": [
1132
1627
  {
1133
- "text": "6.2.0",
1628
+ "text": "6.4.0",
1134
1629
  "name": "since"
1135
1630
  },
1136
1631
  {
1137
- "text": "'us'",
1632
+ "text": "60000",
1138
1633
  "name": "default"
1139
- },
1140
- {
1141
- "text": "'eu'",
1142
- "name": "example"
1143
- },
1144
- {
1145
- "text": "This option will be removed in the future.",
1146
- "name": "deprecated"
1147
1634
  }
1148
1635
  ],
1149
- "docs": "The location of the server to use when using [Capawesome Cloud](https://capawesome.io/cloud).",
1636
+ "docs": "The timeout in milliseconds for HTTP requests.",
1150
1637
  "complexTypes": [],
1151
- "type": "'us' | 'eu' | undefined"
1638
+ "type": "number | undefined"
1152
1639
  },
1153
1640
  {
1154
1641
  "name": "publicKey",
@@ -1174,29 +1661,37 @@
1174
1661
  "name": "since"
1175
1662
  },
1176
1663
  {
1177
- "text": "10000",
1664
+ "text": "0",
1178
1665
  "name": "default"
1666
+ },
1667
+ {
1668
+ "text": "10000",
1669
+ "name": "example"
1179
1670
  }
1180
1671
  ],
1181
- "docs": "The timeout in milliseconds to wait for the app to be ready before resetting to the default bundle.",
1672
+ "docs": "The timeout in milliseconds to wait for the app to be ready\nbefore resetting to the default bundle.\n\nIt is strongly **recommended** to configure this option (e.g. `10000` ms)\nso that the plugin can roll back to the default bundle in case of problems.\nIf configured, the plugin will wait for the app to call the `ready()`\nmethod before resetting to the default bundle.\n\nSet to `0` to disable the timeout.",
1182
1673
  "complexTypes": [],
1183
1674
  "type": "number | undefined"
1184
1675
  },
1185
1676
  {
1186
- "name": "resetOnUpdate",
1677
+ "name": "serverDomain",
1187
1678
  "tags": [
1188
1679
  {
1189
- "text": "5.0.0",
1680
+ "text": "7.0.0",
1190
1681
  "name": "since"
1191
1682
  },
1192
1683
  {
1193
- "text": "true",
1684
+ "text": "'api.cloud.capawesome.io'",
1194
1685
  "name": "default"
1686
+ },
1687
+ {
1688
+ "text": "'api.cloud.capawesome.eu'",
1689
+ "name": "example"
1195
1690
  }
1196
1691
  ],
1197
- "docs": "Whether or not the app should be reset to the default bundle during an update.",
1692
+ "docs": "The API domain of the [Capawesome Cloud](https://cloud.capawesome.io) server **without** scheme or path.",
1198
1693
  "complexTypes": [],
1199
- "type": "boolean | undefined"
1694
+ "type": "string | undefined"
1200
1695
  }
1201
1696
  ],
1202
1697
  "docs": ""