eas-cli 16.27.0 → 16.30.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.
Files changed (357) hide show
  1. package/README.md +97 -94
  2. package/build/analytics/AnalyticsManager.js +4 -4
  3. package/build/analytics/common.js +1 -2
  4. package/build/api.js +5 -5
  5. package/build/branch/delete.d.ts +5 -0
  6. package/build/branch/delete.js +23 -0
  7. package/build/branch/queries.js +5 -5
  8. package/build/branch/utils.js +2 -2
  9. package/build/build/android/build.js +3 -4
  10. package/build/build/android/graphql.js +1 -2
  11. package/build/build/android/prepareJob.js +1 -2
  12. package/build/build/android/syncProjectConfiguration.js +2 -3
  13. package/build/build/android/version.js +6 -6
  14. package/build/build/build.js +3 -4
  15. package/build/build/configure.js +4 -5
  16. package/build/build/context.d.ts +1 -0
  17. package/build/build/createContext.js +2 -2
  18. package/build/build/evaluateConfigWithEnvVarsAsync.js +1 -2
  19. package/build/build/graphql.js +7 -7
  20. package/build/build/ios/build.js +2 -3
  21. package/build/build/ios/credentials.js +2 -3
  22. package/build/build/ios/graphql.js +2 -3
  23. package/build/build/ios/prepareJob.js +2 -3
  24. package/build/build/ios/syncProjectConfiguration.js +1 -2
  25. package/build/build/ios/version.js +10 -10
  26. package/build/build/local.js +2 -2
  27. package/build/build/metadata.js +3 -4
  28. package/build/build/queries.js +4 -4
  29. package/build/build/runBuildAndSubmit.js +12 -3
  30. package/build/build/utils/appJson.js +2 -3
  31. package/build/build/utils/credentials.js +1 -2
  32. package/build/build/utils/devClient.js +1 -2
  33. package/build/build/utils/formatBuild.js +2 -3
  34. package/build/build/utils/printBuildInfo.js +4 -5
  35. package/build/build/utils/repository.js +8 -9
  36. package/build/build/utils/resourceClass.js +1 -2
  37. package/build/build/utils/url.js +8 -9
  38. package/build/build/utils/version.js +2 -3
  39. package/build/build/validate.js +3 -4
  40. package/build/channel/branch-mapping.js +24 -24
  41. package/build/channel/delete.d.ts +5 -0
  42. package/build/channel/delete.js +23 -0
  43. package/build/channel/print-utils.js +2 -3
  44. package/build/channel/queries.js +8 -8
  45. package/build/channel/utils.js +1 -2
  46. package/build/commandUtils/builds.js +3 -4
  47. package/build/commandUtils/context/contextUtils/createGraphqlClient.js +1 -2
  48. package/build/commandUtils/context/contextUtils/findProjectDirAndVerifyProjectSetupAsync.js +2 -3
  49. package/build/commandUtils/context/contextUtils/getProjectIdAsync.js +3 -4
  50. package/build/commandUtils/context/contextUtils/loadServerSideEnvironmentVariablesAsync.js +1 -2
  51. package/build/commandUtils/experienceParser.d.ts +6 -0
  52. package/build/commandUtils/experienceParser.js +42 -0
  53. package/build/commandUtils/new/commands.js +3 -4
  54. package/build/commandUtils/new/configs.js +11 -9
  55. package/build/commandUtils/new/projectFiles.js +6 -7
  56. package/build/commandUtils/new/utils.js +1 -2
  57. package/build/commandUtils/projectNameValidation.d.ts +8 -0
  58. package/build/commandUtils/projectNameValidation.js +30 -0
  59. package/build/commandUtils/workflow/buildProfileUtils.js +12 -13
  60. package/build/commandUtils/workflow/creation.js +5 -5
  61. package/build/commandUtils/workflow/fetchLogs.js +2 -3
  62. package/build/commandUtils/workflow/inputs.js +5 -5
  63. package/build/commandUtils/workflow/stateMachine.js +7 -7
  64. package/build/commandUtils/workflow/utils.js +12 -12
  65. package/build/commandUtils/workflow/validation.js +4 -5
  66. package/build/commands/branch/delete.js +6 -20
  67. package/build/commands/build/cancel.js +1 -2
  68. package/build/commands/build/delete.js +1 -2
  69. package/build/commands/build/index.js +1 -10
  70. package/build/commands/channel/delete.js +7 -23
  71. package/build/commands/channel/edit.js +1 -2
  72. package/build/commands/channel/pause.js +1 -2
  73. package/build/commands/channel/resume.js +1 -2
  74. package/build/commands/deploy/index.js +1 -1
  75. package/build/commands/project/init.js +3 -1
  76. package/build/commands/project/new.js +3 -4
  77. package/build/commands/update/index.d.ts +8 -0
  78. package/build/commands/update/index.js +39 -2
  79. package/build/commands/update/list.d.ts +3 -0
  80. package/build/commands/update/list.js +30 -1
  81. package/build/commands/update/revert-update-rollout.js +1 -2
  82. package/build/credentials/android/actions/BuildCredentialsUtils.js +6 -7
  83. package/build/credentials/android/api/GraphqlClient.js +21 -21
  84. package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.d.ts +2 -2
  85. package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.d.ts +5 -5
  86. package/build/credentials/android/utils/googleServiceAccountKey.js +4 -4
  87. package/build/credentials/android/utils/keystore.js +2 -3
  88. package/build/credentials/android/utils/keystoreNew.js +3 -4
  89. package/build/credentials/android/utils/printCredentials.js +3 -4
  90. package/build/credentials/credentialsJson/read.js +3 -4
  91. package/build/credentials/credentialsJson/update.js +2 -3
  92. package/build/credentials/credentialsJson/utils.js +2 -3
  93. package/build/credentials/ios/actions/AppleTeamFormatting.js +1 -2
  94. package/build/credentials/ios/actions/AppleTeamUtils.js +1 -2
  95. package/build/credentials/ios/actions/AscApiKeyUtils.js +10 -10
  96. package/build/credentials/ios/actions/BuildCredentialsUtils.js +7 -8
  97. package/build/credentials/ios/actions/DeviceUtils.js +2 -3
  98. package/build/credentials/ios/actions/DistributionCertificateUtils.js +4 -5
  99. package/build/credentials/ios/actions/ProvisioningProfileUtils.js +2 -3
  100. package/build/credentials/ios/actions/PushKeyUtils.js +5 -6
  101. package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +2 -2
  102. package/build/credentials/ios/actions/SetUpTargetBuildCredentials.js +6 -2
  103. package/build/credentials/ios/api/GraphqlClient.js +24 -25
  104. package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.d.ts +5 -5
  105. package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.d.ts +8 -8
  106. package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.d.ts +5 -5
  107. package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.d.ts +5 -5
  108. package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.d.ts +1 -1
  109. package/build/credentials/ios/appstore/AppStoreApi.d.ts +0 -2
  110. package/build/credentials/ios/appstore/Credentials.js +4 -5
  111. package/build/credentials/ios/appstore/Credentials.types.d.ts +0 -1
  112. package/build/credentials/ios/appstore/CredentialsUtils.js +6 -7
  113. package/build/credentials/ios/appstore/ascApiKey.d.ts +0 -1
  114. package/build/credentials/ios/appstore/ascApiKey.js +6 -7
  115. package/build/credentials/ios/appstore/authenticate.d.ts +0 -1
  116. package/build/credentials/ios/appstore/authenticate.js +4 -5
  117. package/build/credentials/ios/appstore/authenticateTypes.d.ts +0 -1
  118. package/build/credentials/ios/appstore/bundleId.d.ts +0 -1
  119. package/build/credentials/ios/appstore/bundleId.js +2 -3
  120. package/build/credentials/ios/appstore/bundleIdCapabilities.d.ts +0 -1
  121. package/build/credentials/ios/appstore/bundleIdCapabilities.js +3 -3
  122. package/build/credentials/ios/appstore/capabilityIdentifiers.d.ts +0 -1
  123. package/build/credentials/ios/appstore/capabilityIdentifiers.js +1 -2
  124. package/build/credentials/ios/appstore/capabilityList.d.ts +0 -1
  125. package/build/credentials/ios/appstore/contractMessages.d.ts +0 -1
  126. package/build/credentials/ios/appstore/contractMessages.js +2 -3
  127. package/build/credentials/ios/appstore/distributionCertificate.d.ts +0 -1
  128. package/build/credentials/ios/appstore/distributionCertificate.js +7 -7
  129. package/build/credentials/ios/appstore/ensureAppExists.d.ts +6 -1
  130. package/build/credentials/ios/appstore/ensureAppExists.js +55 -18
  131. package/build/credentials/ios/appstore/ensureTestFlightGroup.d.ts +0 -1
  132. package/build/credentials/ios/appstore/ensureTestFlightGroup.js +1 -2
  133. package/build/credentials/ios/appstore/keychain.js +4 -4
  134. package/build/credentials/ios/appstore/provisioningProfile.d.ts +0 -1
  135. package/build/credentials/ios/appstore/provisioningProfile.js +5 -5
  136. package/build/credentials/ios/appstore/provisioningProfileAdhoc.d.ts +0 -1
  137. package/build/credentials/ios/appstore/provisioningProfileAdhoc.js +1 -2
  138. package/build/credentials/ios/appstore/pushKey.js +4 -4
  139. package/build/credentials/ios/appstore/resolveCredentials.d.ts +0 -1
  140. package/build/credentials/ios/appstore/resolveCredentials.js +6 -7
  141. package/build/credentials/ios/credentials.d.ts +0 -1
  142. package/build/credentials/ios/credentials.js +2 -2
  143. package/build/credentials/ios/utils/authType.d.ts +0 -1
  144. package/build/credentials/ios/utils/authType.js +1 -2
  145. package/build/credentials/ios/utils/convertHTMLToASCII.js +1 -2
  146. package/build/credentials/ios/utils/p12Certificate.d.ts +0 -1
  147. package/build/credentials/ios/utils/p12Certificate.js +3 -4
  148. package/build/credentials/ios/utils/printCredentials.js +3 -4
  149. package/build/credentials/ios/utils/provisioningProfile.js +5 -6
  150. package/build/credentials/ios/validators/validateAscApiKey.js +2 -3
  151. package/build/credentials/ios/validators/validateDistributionCertificate.js +1 -2
  152. package/build/credentials/ios/validators/validateProvisioningProfile.js +1 -2
  153. package/build/credentials/ios/validators/validatePushKey.js +1 -2
  154. package/build/credentials/manager/IosActions.js +4 -4
  155. package/build/credentials/manager/SelectPlatform.js +1 -1
  156. package/build/credentials/utils/promptForCredentials.js +3 -4
  157. package/build/devices/actions/create/currentMachineMethod.js +1 -2
  158. package/build/devices/actions/create/developerPortalMethod.d.ts +0 -1
  159. package/build/devices/actions/create/developerPortalMethod.js +2 -3
  160. package/build/devices/actions/create/inputMethod.js +1 -2
  161. package/build/devices/actions/create/registrationUrlMethod.js +1 -2
  162. package/build/devices/actions/create/utils.js +4 -5
  163. package/build/devices/context.js +1 -2
  164. package/build/devices/queries.js +4 -4
  165. package/build/devices/udids.js +2 -3
  166. package/build/devices/utils/formatDevice.js +2 -3
  167. package/build/fetch.d.ts +0 -1
  168. package/build/fetch.js +1 -1
  169. package/build/fingerprint/cli.js +3 -4
  170. package/build/fingerprint/diff.js +1 -2
  171. package/build/fingerprint/types.d.ts +0 -1
  172. package/build/fingerprint/utils.js +4 -5
  173. package/build/graphql/client.js +2 -2
  174. package/build/graphql/generated.d.ts +331 -103
  175. package/build/graphql/generated.js +45 -3
  176. package/build/graphql/mutations/PublishMutation.d.ts +2 -2
  177. package/build/graphql/queries/AccountUsageQuery.d.ts +1 -1
  178. package/build/graphql/queries/AppVersionQuery.d.ts +1 -1
  179. package/build/graphql/queries/BackgroundJobReceiptQuery.d.ts +1 -1
  180. package/build/graphql/queries/BranchQuery.d.ts +3 -3
  181. package/build/graphql/queries/BuildQuery.d.ts +3 -3
  182. package/build/graphql/queries/ChannelQuery.d.ts +2 -2
  183. package/build/graphql/queries/ChannelQuery.js +2 -2
  184. package/build/graphql/queries/EnvironmentVariablesQuery.d.ts +12 -12
  185. package/build/graphql/queries/FingerprintQuery.d.ts +6 -6
  186. package/build/graphql/queries/PublishQuery.d.ts +1 -1
  187. package/build/graphql/queries/SubmissionQuery.d.ts +1 -1
  188. package/build/graphql/queries/UserQuery.d.ts +1 -1
  189. package/build/graphql/queries/WorkflowJobQuery.d.ts +2 -2
  190. package/build/graphql/queries/WorkflowRunQuery.d.ts +4 -4
  191. package/build/graphql/types/AppPlatform.js +2 -3
  192. package/build/log.js +2 -3
  193. package/build/metadata/apple/config/reader.d.ts +0 -1
  194. package/build/metadata/apple/config/writer.d.ts +0 -1
  195. package/build/metadata/apple/data.d.ts +0 -1
  196. package/build/metadata/apple/tasks/age-rating.d.ts +0 -1
  197. package/build/metadata/apple/tasks/age-rating.js +0 -1
  198. package/build/metadata/apple/tasks/app-info.d.ts +0 -1
  199. package/build/metadata/apple/tasks/app-info.js +15 -4
  200. package/build/metadata/apple/tasks/app-review-detail.d.ts +0 -1
  201. package/build/metadata/apple/tasks/app-review-detail.js +0 -1
  202. package/build/metadata/apple/tasks/app-version.d.ts +0 -1
  203. package/build/metadata/apple/tasks/app-version.js +15 -3
  204. package/build/metadata/apple/tasks/index.js +1 -2
  205. package/build/metadata/apple/types.d.ts +0 -1
  206. package/build/metadata/auth.d.ts +0 -1
  207. package/build/metadata/auth.js +1 -2
  208. package/build/metadata/config/resolve.js +4 -5
  209. package/build/metadata/config/validate.js +1 -2
  210. package/build/metadata/download.js +1 -2
  211. package/build/metadata/errors.js +3 -3
  212. package/build/metadata/upload.js +1 -2
  213. package/build/metadata/utils/ajv.js +2 -3
  214. package/build/metadata/utils/asc.d.ts +0 -1
  215. package/build/metadata/utils/date.js +1 -2
  216. package/build/metadata/utils/log.js +1 -2
  217. package/build/metadata/utils/retry.js +2 -3
  218. package/build/metadata/utils/telemetry.d.ts +0 -1
  219. package/build/metadata/utils/telemetry.js +2 -3
  220. package/build/onboarding/git.js +3 -4
  221. package/build/onboarding/installDependencies.js +3 -3
  222. package/build/onboarding/runCommand.js +1 -2
  223. package/build/ora.js +1 -2
  224. package/build/platform.d.ts +1 -0
  225. package/build/platform.js +28 -10
  226. package/build/project/android/applicationId.js +6 -6
  227. package/build/project/android/gradle.js +1 -2
  228. package/build/project/android/gradleUtils.js +4 -4
  229. package/build/project/android/versions.js +3 -3
  230. package/build/project/applicationIdentifier.js +1 -2
  231. package/build/project/customBuildConfig.js +3 -4
  232. package/build/project/expoConfig.js +5 -6
  233. package/build/project/expoSdk.js +1 -2
  234. package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.js +2 -3
  235. package/build/project/ios/bundleIdentifier.js +6 -6
  236. package/build/project/ios/entitlements.js +2 -3
  237. package/build/project/ios/exemptEncryption.js +1 -2
  238. package/build/project/ios/scheme.js +2 -3
  239. package/build/project/ios/target.d.ts +0 -1
  240. package/build/project/ios/target.js +8 -9
  241. package/build/project/ios/versions.js +3 -3
  242. package/build/project/maybeUploadAssetMapAsync.js +1 -2
  243. package/build/project/maybeUploadFingerprintAsync.js +1 -2
  244. package/build/project/metroConfig.js +1 -2
  245. package/build/project/projectUtils.js +15 -16
  246. package/build/project/publish.d.ts +15 -2
  247. package/build/project/publish.js +56 -29
  248. package/build/project/remoteVersionSource.js +6 -6
  249. package/build/project/resolveRuntimeVersionAsync.js +2 -3
  250. package/build/project/uploadAccountScopedFileAsync.js +1 -2
  251. package/build/project/uploadAccountScopedProjectSourceAsync.js +1 -2
  252. package/build/project/workflow.js +3 -4
  253. package/build/prompts.js +5 -6
  254. package/build/rollout/branch-mapping.js +14 -15
  255. package/build/rollout/utils.js +5 -6
  256. package/build/run/android/aapt.js +2 -3
  257. package/build/run/android/adb.js +8 -9
  258. package/build/run/android/emulator.js +6 -6
  259. package/build/run/android/run.js +1 -2
  260. package/build/run/android/sdk.d.ts +0 -1
  261. package/build/run/android/sdk.js +2 -2
  262. package/build/run/android/systemRequirements.js +1 -2
  263. package/build/run/ios/run.js +1 -2
  264. package/build/run/ios/simctl.js +1 -2
  265. package/build/run/ios/simulator.js +9 -10
  266. package/build/run/ios/systemRequirements.js +1 -2
  267. package/build/run/ios/xcode.js +5 -5
  268. package/build/run/ios/xcrun.js +3 -4
  269. package/build/run/run.js +2 -3
  270. package/build/run/utils.js +1 -2
  271. package/build/submit/ArchiveSource.js +3 -3
  272. package/build/submit/android/ServiceAccountSource.js +4 -4
  273. package/build/submit/commons.js +2 -3
  274. package/build/submit/context.js +1 -2
  275. package/build/submit/ios/AppProduce.js +1 -2
  276. package/build/submit/ios/AppSpecificPasswordSource.js +3 -3
  277. package/build/submit/ios/AscApiKeySource.js +4 -4
  278. package/build/submit/ios/utils/language.js +1 -2
  279. package/build/submit/submit.js +3 -4
  280. package/build/submit/utils/builds.js +1 -2
  281. package/build/submit/utils/errors.js +1 -2
  282. package/build/submit/utils/files.js +2 -3
  283. package/build/submit/utils/logs.js +1 -2
  284. package/build/submit/utils/summary.js +2 -3
  285. package/build/submit/utils/urls.js +2 -3
  286. package/build/submit/utils/wait.js +2 -3
  287. package/build/update/android/UpdatesModule.js +2 -3
  288. package/build/update/configure.js +4 -4
  289. package/build/update/delete.js +1 -2
  290. package/build/update/getBranchFromChannelNameAndCreateAndLinkIfNotExistsAsync.js +1 -2
  291. package/build/update/ios/UpdatesModule.js +2 -3
  292. package/build/update/queries.d.ts +5 -3
  293. package/build/update/queries.js +12 -9
  294. package/build/update/republish.js +5 -6
  295. package/build/update/roll-back-to-embedded.js +1 -2
  296. package/build/update/utils.js +15 -15
  297. package/build/uploads.js +3 -4
  298. package/build/user/User.js +2 -3
  299. package/build/user/actions.js +1 -2
  300. package/build/user/expoSsoLauncher.js +1 -2
  301. package/build/user/fetchSessionSecretAndSsoUser.js +1 -2
  302. package/build/user/fetchSessionSecretAndUser.js +1 -2
  303. package/build/user/fetchUser.js +1 -2
  304. package/build/utils/code-signing.d.ts +0 -1
  305. package/build/utils/code-signing.js +7 -8
  306. package/build/utils/date.js +1 -2
  307. package/build/utils/download.js +2 -3
  308. package/build/utils/expoCli.js +4 -4
  309. package/build/utils/expoUpdatesCli.js +2 -2
  310. package/build/utils/expodash/areSetsEqual.js +1 -1
  311. package/build/utils/expodash/capitalize.js +1 -1
  312. package/build/utils/expodash/chunk.js +1 -1
  313. package/build/utils/expodash/differenceBy.js +1 -1
  314. package/build/utils/expodash/filter.js +1 -2
  315. package/build/utils/expodash/groupBy.js +1 -1
  316. package/build/utils/expodash/intersection.js +1 -1
  317. package/build/utils/expodash/mapMapAsync.js +1 -1
  318. package/build/utils/expodash/memoize.js +1 -2
  319. package/build/utils/expodash/pick.js +1 -1
  320. package/build/utils/expodash/sortBy.js +1 -1
  321. package/build/utils/expodash/uniq.js +1 -1
  322. package/build/utils/expodash/uniqBy.js +1 -1
  323. package/build/utils/expodash/zipObject.js +1 -1
  324. package/build/utils/files.js +2 -3
  325. package/build/utils/formatFields.js +1 -1
  326. package/build/utils/image.js +3 -3
  327. package/build/utils/json.js +2 -3
  328. package/build/utils/plist.d.ts +0 -1
  329. package/build/utils/plist.js +3 -4
  330. package/build/utils/pollForBackgroundJobReceiptAsync.js +2 -2
  331. package/build/utils/profiles.js +3 -4
  332. package/build/utils/progress.js +1 -2
  333. package/build/utils/promise.js +1 -2
  334. package/build/utils/prompts.js +8 -9
  335. package/build/utils/queries.js +2 -3
  336. package/build/utils/relay.js +4 -4
  337. package/build/utils/statuspageService.js +1 -2
  338. package/build/utils/timer.js +4 -5
  339. package/build/utils/usage/checkForOverages.js +4 -6
  340. package/build/utils/variableUtils.js +4 -5
  341. package/build/vcs/clients/git.js +1 -2
  342. package/build/vcs/git.js +5 -6
  343. package/build/vcs/index.js +1 -2
  344. package/build/vcs/local.js +2 -2
  345. package/build/webhooks/formatWebhook.js +1 -2
  346. package/build/webhooks/input.js +3 -4
  347. package/build/worker/assets.d.ts +0 -1
  348. package/build/worker/assets.js +6 -7
  349. package/build/worker/deployment.js +8 -9
  350. package/build/worker/mutations.d.ts +1 -1
  351. package/build/worker/queries.d.ts +4 -4
  352. package/build/worker/upload.d.ts +0 -2
  353. package/build/worker/upload.js +5 -6
  354. package/build/worker/utils/logs.js +5 -5
  355. package/build/worker/utils/multipart.js +3 -3
  356. package/oclif.manifest.json +35 -1
  357. package/package.json +13 -11
@@ -7,9 +7,9 @@ export declare const AppleDistributionCertificateQuery: {
7
7
  }): Promise<AppleDistributionCertificateFragment | null>;
8
8
  getAllForAccountAsync(graphqlClient: ExpoGraphqlClient, accountName: string): Promise<AppleDistributionCertificateFragment[]>;
9
9
  getAllForAccountPaginatedAsync(graphqlClient: ExpoGraphqlClient, accountName: string, { after, first, before, last, }: {
10
- after?: string | undefined;
11
- first?: number | undefined;
12
- before?: string | undefined;
13
- last?: number | undefined;
14
- }): Promise<AppleDistributionCertificatesPaginatedByAccountQuery['account']['byName']['appleDistributionCertificatesPaginated']>;
10
+ after?: string;
11
+ first?: number;
12
+ before?: string;
13
+ last?: number;
14
+ }): Promise<AppleDistributionCertificatesPaginatedByAccountQuery["account"]["byName"]["appleDistributionCertificatesPaginated"]>;
15
15
  };
@@ -3,9 +3,9 @@ import { ApplePushKeyFragment, ApplePushKeysPaginatedByAccountQuery } from '../.
3
3
  export declare const ApplePushKeyQuery: {
4
4
  getAllForAccountAsync(graphqlClient: ExpoGraphqlClient, accountName: string): Promise<ApplePushKeyFragment[]>;
5
5
  getAllForAccountPaginatedAsync(graphqlClient: ExpoGraphqlClient, accountName: string, { after, first, before, last, }: {
6
- after?: string | undefined;
7
- first?: number | undefined;
8
- before?: string | undefined;
9
- last?: number | undefined;
10
- }): Promise<ApplePushKeysPaginatedByAccountQuery['account']['byName']['applePushKeysPaginated']>;
6
+ after?: string;
7
+ first?: number;
8
+ before?: string;
9
+ last?: number;
10
+ }): Promise<ApplePushKeysPaginatedByAccountQuery["account"]["byName"]["applePushKeysPaginated"]>;
11
11
  };
@@ -3,7 +3,7 @@ import { CommonIosAppCredentialsFragment, IosDistributionType } from '../../../.
3
3
  export declare const IosAppCredentialsQuery: {
4
4
  withBuildCredentialsByAppIdentifierIdAsync(graphqlClient: ExpoGraphqlClient, projectFullName: string, { appleAppIdentifierId, iosDistributionType, }: {
5
5
  appleAppIdentifierId: string;
6
- iosDistributionType?: IosDistributionType | undefined;
6
+ iosDistributionType?: IosDistributionType;
7
7
  }): Promise<CommonIosAppCredentialsFragment | null>;
8
8
  withCommonFieldsByAppIdentifierIdAsync(graphqlClient: ExpoGraphqlClient, projectFullName: string, { appleAppIdentifierId, }: {
9
9
  appleAppIdentifierId: string;
@@ -1,5 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
3
1
  import { ProfileType } from '@expo/app-store';
4
2
  import { AscApiKey, AscApiKeyInfo, DistributionCertificate, DistributionCertificateStoreInfo, ProvisioningProfile, ProvisioningProfileStoreInfo, PushKey, PushKeyStoreInfo } from './Credentials.types';
5
3
  import { Options as AuthenticateOptions } from './authenticate';
@@ -1,6 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isPushKey = exports.formatPushKey = exports.isDistributionCertificate = exports.formatDistributionCertificate = void 0;
3
+ exports.formatDistributionCertificate = formatDistributionCertificate;
4
+ exports.isDistributionCertificate = isDistributionCertificate;
5
+ exports.formatPushKey = formatPushKey;
6
+ exports.isPushKey = isPushKey;
4
7
  const tslib_1 = require("tslib");
5
8
  const dateformat_1 = tslib_1.__importDefault(require("dateformat"));
6
9
  function formatDistributionCertificate({ name, id, status, expires, created, ownerName, }) {
@@ -8,7 +11,6 @@ function formatDistributionCertificate({ name, id, status, expires, created, own
8
11
  const createdDate = formatTimestamp(created);
9
12
  return `${name} (${status}) - ID: ${id} - expires: ${expiresDate} (created: ${createdDate}) - owner: ${ownerName}`;
10
13
  }
11
- exports.formatDistributionCertificate = formatDistributionCertificate;
12
14
  function isDistributionCertificate(val) {
13
15
  return (val.certP12 &&
14
16
  typeof val.certP12 === 'string' &&
@@ -17,11 +19,9 @@ function isDistributionCertificate(val) {
17
19
  val.teamId &&
18
20
  typeof val.teamId === 'string');
19
21
  }
20
- exports.isDistributionCertificate = isDistributionCertificate;
21
22
  function formatPushKey({ id, name }) {
22
23
  return `${name} - ID: ${id}`;
23
24
  }
24
- exports.formatPushKey = formatPushKey;
25
25
  function isPushKey(obj) {
26
26
  return (obj.apnsKeyP8 &&
27
27
  typeof obj.apnsKeyP8 === 'string' &&
@@ -30,7 +30,6 @@ function isPushKey(obj) {
30
30
  obj.teamId &&
31
31
  typeof obj.teamId === 'string');
32
32
  }
33
- exports.isPushKey = isPushKey;
34
33
  function formatTimestamp(timestamp) {
35
34
  return (0, dateformat_1.default)(new Date(timestamp * 1000));
36
35
  }
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { UserRole } from '@expo/apple-utils';
3
2
  export interface DistributionCertificateStoreInfo {
4
3
  id: string;
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getValidCertSerialNumbers = exports.sortCertificatesByExpiryDesc = exports.filterRevokedDistributionCerts = exports.filterRevokedDistributionCertsFromEasServers = exports.filterRevokedAndUntrackedPushKeysFromEasServersAsync = exports.filterRevokedAndUntrackedPushKeysAsync = void 0;
3
+ exports.filterRevokedAndUntrackedPushKeysAsync = filterRevokedAndUntrackedPushKeysAsync;
4
+ exports.filterRevokedAndUntrackedPushKeysFromEasServersAsync = filterRevokedAndUntrackedPushKeysFromEasServersAsync;
5
+ exports.filterRevokedDistributionCertsFromEasServers = filterRevokedDistributionCertsFromEasServers;
6
+ exports.filterRevokedDistributionCerts = filterRevokedDistributionCerts;
7
+ exports.sortCertificatesByExpiryDesc = sortCertificatesByExpiryDesc;
8
+ exports.getValidCertSerialNumbers = getValidCertSerialNumbers;
4
9
  /**
5
10
  * Edge case: Uploaded push keys rely on the user to provide the keyIdentifier, which could be incorrect
6
11
  * It is possible an uploaded key could have a valid p8 but invalid identifier, making it impossible for us to
@@ -13,7 +18,6 @@ async function filterRevokedAndUntrackedPushKeysAsync(pushKeys, pushInfoFromAppl
13
18
  return validKeyIdsOnAppleServer.includes(pushKey.apnsKeyId);
14
19
  });
15
20
  }
16
- exports.filterRevokedAndUntrackedPushKeysAsync = filterRevokedAndUntrackedPushKeysAsync;
17
21
  /**
18
22
  * Edge case: Uploaded push keys rely on the user to provide the keyIdentifier, which could be incorrect
19
23
  * It is possible an uploaded key could have a valid p8 but invalid identifier, making it impossible for us to
@@ -26,7 +30,6 @@ async function filterRevokedAndUntrackedPushKeysFromEasServersAsync(pushKeys, pu
26
30
  return validKeyIdsOnAppleServer.includes(pushKey.keyIdentifier);
27
31
  });
28
32
  }
29
- exports.filterRevokedAndUntrackedPushKeysFromEasServersAsync = filterRevokedAndUntrackedPushKeysFromEasServersAsync;
30
33
  function filterRevokedDistributionCertsFromEasServers(distributionCerts, certInfoFromApple) {
31
34
  if (distributionCerts.length === 0) {
32
35
  return [];
@@ -39,7 +42,6 @@ function filterRevokedDistributionCertsFromEasServers(distributionCerts, certInf
39
42
  .map(cert => cert.serialNumber);
40
43
  return distributionCerts.filter(cert => validCertSerialsOnAppleServer.includes(cert.serialNumber));
41
44
  }
42
- exports.filterRevokedDistributionCertsFromEasServers = filterRevokedDistributionCertsFromEasServers;
43
45
  function filterRevokedDistributionCerts(distributionCerts, certInfoFromApple) {
44
46
  if (distributionCerts.length === 0) {
45
47
  return [];
@@ -58,7 +60,6 @@ function filterRevokedDistributionCerts(distributionCerts, certInfoFromApple) {
58
60
  });
59
61
  return validDistributionCerts;
60
62
  }
61
- exports.filterRevokedDistributionCerts = filterRevokedDistributionCerts;
62
63
  function sortCertificatesByExpiryDesc(certInfoFromApple, distributionCerts) {
63
64
  return distributionCerts.sort((certA, certB) => {
64
65
  const certAInfo = certInfoFromApple.find(cert => cert.id === certA.certId);
@@ -68,7 +69,6 @@ function sortCertificatesByExpiryDesc(certInfoFromApple, distributionCerts) {
68
69
  return certBExpiry - certAExpiry;
69
70
  });
70
71
  }
71
- exports.sortCertificatesByExpiryDesc = sortCertificatesByExpiryDesc;
72
72
  function getValidCertSerialNumbers(certInfoFromApple) {
73
73
  return certInfoFromApple
74
74
  .filter(
@@ -76,4 +76,3 @@ function getValidCertSerialNumbers(certInfoFromApple) {
76
76
  cert => cert.expires > Math.floor(Date.now() / 1000))
77
77
  .map(cert => cert.serialNumber);
78
78
  }
79
- exports.getValidCertSerialNumbers = getValidCertSerialNumbers;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { ApiKey, ApiKeyProps } from '@expo/apple-utils';
3
2
  import { AscApiKey, AscApiKeyInfo } from './Credentials.types';
4
3
  import { AuthCtx, UserAuthCtx } from './authenticateTypes';
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getAscApiKeyInfo = exports.revokeAscApiKeyAsync = exports.createAscApiKeyAsync = exports.downloadWithRetryAsync = exports.getAscApiKeyAsync = exports.listAscApiKeysAsync = void 0;
3
+ exports.listAscApiKeysAsync = listAscApiKeysAsync;
4
+ exports.getAscApiKeyAsync = getAscApiKeyAsync;
5
+ exports.downloadWithRetryAsync = downloadWithRetryAsync;
6
+ exports.createAscApiKeyAsync = createAscApiKeyAsync;
7
+ exports.revokeAscApiKeyAsync = revokeAscApiKeyAsync;
8
+ exports.getAscApiKeyInfo = getAscApiKeyInfo;
4
9
  const tslib_1 = require("tslib");
5
10
  const apple_utils_1 = require("@expo/apple-utils");
6
11
  const promise_retry_1 = tslib_1.__importDefault(require("promise-retry"));
@@ -25,7 +30,6 @@ async function listAscApiKeysAsync(userAuthCtx) {
25
30
  throw error;
26
31
  }
27
32
  }
28
- exports.listAscApiKeysAsync = listAscApiKeysAsync;
29
33
  /**
30
34
  * Get an App Store Connect API Key.
31
35
  * **Does not support App Store Connect API (CI).**
@@ -49,7 +53,6 @@ async function getAscApiKeyAsync(userAuthCtx, keyId) {
49
53
  throw error;
50
54
  }
51
55
  }
52
- exports.getAscApiKeyAsync = getAscApiKeyAsync;
53
56
  /**
54
57
  * There is a bug in Apple's infrastructure that does not propagate newly created objects for a
55
58
  * while. If the key has not propagated and you try to download it, Apple will error saying that
@@ -97,7 +100,6 @@ async function downloadWithRetryAsync(analytics, key, { minTimeout = 1000, retri
97
100
  throw e;
98
101
  }
99
102
  }
100
- exports.downloadWithRetryAsync = downloadWithRetryAsync;
101
103
  /**
102
104
  * Create an App Store Connect API Key.
103
105
  * **Does not support App Store Connect API (CI).**
@@ -138,7 +140,6 @@ async function createAscApiKeyAsync(analytics, userAuthCtx, { nickname, allAppsV
138
140
  throw err;
139
141
  }
140
142
  }
141
- exports.createAscApiKeyAsync = createAscApiKeyAsync;
142
143
  /**
143
144
  * Revoke an App Store Connect API Key.
144
145
  * **Does not support App Store Connect API (CI).**
@@ -158,7 +159,6 @@ async function revokeAscApiKeyAsync(userAuthCtx, keyId) {
158
159
  throw error;
159
160
  }
160
161
  }
161
- exports.revokeAscApiKeyAsync = revokeAscApiKeyAsync;
162
162
  function getAscApiKeyInfo(apiKey, authCtx) {
163
163
  return {
164
164
  name: apiKey.attributes.nickname,
@@ -170,4 +170,3 @@ function getAscApiKeyInfo(apiKey, authCtx) {
170
170
  isRevoked: !!apiKey.attributes.revokingDate,
171
171
  };
172
172
  }
173
- exports.getAscApiKeyInfo = getAscApiKeyInfo;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { RequestContext, Session } from '@expo/apple-utils';
3
2
  import { AppleTeamType, AuthCtx, AuthenticationMode, UserAuthCtx } from './authenticateTypes';
4
3
  import { MinimalAscApiKey } from '../credentials';
@@ -1,6 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.authenticateAsync = exports.getRequestContext = exports.assertUserAuthCtx = exports.isUserAuthCtx = void 0;
3
+ exports.isUserAuthCtx = isUserAuthCtx;
4
+ exports.assertUserAuthCtx = assertUserAuthCtx;
5
+ exports.getRequestContext = getRequestContext;
6
+ exports.authenticateAsync = authenticateAsync;
4
7
  const tslib_1 = require("tslib");
5
8
  const apple_utils_1 = require("@expo/apple-utils");
6
9
  const assert_1 = tslib_1.__importDefault(require("assert"));
@@ -14,19 +17,16 @@ const APPLE_IN_HOUSE_TEAM_TYPE = 'in-house';
14
17
  function isUserAuthCtx(authCtx) {
15
18
  return !!authCtx && typeof authCtx.appleId === 'string';
16
19
  }
17
- exports.isUserAuthCtx = isUserAuthCtx;
18
20
  function assertUserAuthCtx(authCtx) {
19
21
  if (isUserAuthCtx(authCtx)) {
20
22
  return authCtx;
21
23
  }
22
24
  throw new Error('Expected user authentication context (login/password).');
23
25
  }
24
- exports.assertUserAuthCtx = assertUserAuthCtx;
25
26
  function getRequestContext(authCtx) {
26
27
  (0, assert_1.default)(authCtx.authState?.context, 'Apple request context must be defined');
27
28
  return authCtx.authState.context;
28
29
  }
29
- exports.getRequestContext = getRequestContext;
30
30
  async function loginAsync(userCredentials = {}, options) {
31
31
  // First try login with cookies JSON
32
32
  if (userCredentials.cookies) {
@@ -101,7 +101,6 @@ async function authenticateAsync(options = {}) {
101
101
  return await authenticateAsUserAsync(options);
102
102
  }
103
103
  }
104
- exports.authenticateAsync = authenticateAsync;
105
104
  async function authenticateWithApiKeyAsync(options = {}) {
106
105
  // Resolve the user credentials, optimizing for password-less login.
107
106
  const ascApiKey = await (0, resolveCredentials_1.resolveAscApiKeyAsync)(options.ascApiKey);
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { Session } from '@expo/apple-utils';
3
2
  import { MinimalAscApiKey } from '../credentials';
4
3
  export declare enum AuthenticationMode {
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { BundleId, Profile, RequestContext } from '@expo/apple-utils';
3
2
  export declare function getProfilesForBundleIdAsync(context: RequestContext, bundleIdentifier: string): Promise<Profile[]>;
4
3
  export declare function getBundleIdForIdentifierAsync(context: RequestContext, bundleIdentifier: string): Promise<BundleId>;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getBundleIdForIdentifierAsync = exports.getProfilesForBundleIdAsync = void 0;
3
+ exports.getProfilesForBundleIdAsync = getProfilesForBundleIdAsync;
4
+ exports.getBundleIdForIdentifierAsync = getBundleIdForIdentifierAsync;
4
5
  const apple_utils_1 = require("@expo/apple-utils");
5
6
  async function getProfilesForBundleIdDangerousAsync(context, bundleIdentifier) {
6
7
  const bundleId = await apple_utils_1.BundleId.findAsync(context, { identifier: bundleIdentifier });
@@ -31,7 +32,6 @@ async function getProfilesForBundleIdAsync(context, bundleIdentifier) {
31
32
  }));
32
33
  return profiles.filter(profile => validProfileIds.has(profile.id));
33
34
  }
34
- exports.getProfilesForBundleIdAsync = getProfilesForBundleIdAsync;
35
35
  async function getBundleIdForIdentifierAsync(context, bundleIdentifier) {
36
36
  const bundleId = await apple_utils_1.BundleId.findAsync(context, { identifier: bundleIdentifier });
37
37
  if (!bundleId) {
@@ -39,4 +39,3 @@ async function getBundleIdForIdentifierAsync(context, bundleIdentifier) {
39
39
  }
40
40
  return bundleId;
41
41
  }
42
- exports.getBundleIdForIdentifierAsync = getBundleIdForIdentifierAsync;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { BundleId } from '@expo/apple-utils';
3
2
  import { JSONObject } from '@expo/json-file';
4
3
  import { CapabilityClassifier } from './capabilityList';
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.assertValidOptions = exports.syncCapabilitiesForEntitlementsAsync = exports.EXPO_NO_CAPABILITY_SYNC = void 0;
3
+ exports.EXPO_NO_CAPABILITY_SYNC = void 0;
4
+ exports.syncCapabilitiesForEntitlementsAsync = syncCapabilitiesForEntitlementsAsync;
5
+ exports.assertValidOptions = assertValidOptions;
4
6
  const tslib_1 = require("tslib");
5
7
  const apple_utils_1 = require("@expo/apple-utils");
6
8
  const getenv_1 = tslib_1.__importDefault(require("getenv"));
@@ -49,7 +51,6 @@ async function syncCapabilitiesForEntitlementsAsync(bundleId, entitlements = {},
49
51
  }
50
52
  return { enabled: enabledCapabilityNames, disabled: disabledCapabilityNames };
51
53
  }
52
- exports.syncCapabilitiesForEntitlementsAsync = syncCapabilitiesForEntitlementsAsync;
53
54
  function getCapabilitiesToEnable(currentRemoteCapabilities, entitlements, additionalOptions) {
54
55
  const enabledCapabilityNames = [];
55
56
  const request = [];
@@ -99,7 +100,6 @@ function assertValidOptions(classifier, value) {
99
100
  throw new Error(`iOS entitlement "${classifier.entitlement}" has invalid value "${value}".${reason}`);
100
101
  }
101
102
  }
102
- exports.assertValidOptions = assertValidOptions;
103
103
  function getCapabilitiesToDisable(bundleId, currentCapabilities, request, entitlements) {
104
104
  if (log_1.default.isDebug) {
105
105
  log_1.default.log(`Existing to disable: `, currentCapabilities.map(({ id }) => id));
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { BundleId } from '@expo/apple-utils';
3
2
  import { JSONObject } from '@expo/json-file';
4
3
  /**
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.syncCapabilityIdentifiersForEntitlementsAsync = void 0;
3
+ exports.syncCapabilityIdentifiersForEntitlementsAsync = syncCapabilityIdentifiersForEntitlementsAsync;
4
4
  const tslib_1 = require("tslib");
5
5
  const apple_utils_1 = require("@expo/apple-utils");
6
6
  const bundleIdCapabilities_1 = require("./bundleIdCapabilities");
@@ -107,4 +107,3 @@ async function syncCapabilityIdentifiersForEntitlementsAsync(bundleId, entitleme
107
107
  }
108
108
  return { created: createdIds, linked: linkedIds };
109
109
  }
110
- exports.syncCapabilityIdentifiersForEntitlementsAsync = syncCapabilityIdentifiersForEntitlementsAsync;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { BundleIdCapability, CapabilityType, MerchantId } from '@expo/apple-utils';
3
2
  import { JSONObject, JSONValue } from '@expo/json-file';
4
3
  declare const skipOp: {
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { ITCAgreements, RequestContext } from '@expo/apple-utils';
3
2
  import type { Ora } from '../../../ora';
4
3
  export declare function formatContractMessage(message: ITCAgreements.ITCContractMessage): string;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.assertContractMessagesAsync = exports.formatContractMessage = void 0;
3
+ exports.formatContractMessage = formatContractMessage;
4
+ exports.assertContractMessagesAsync = assertContractMessagesAsync;
4
5
  const tslib_1 = require("tslib");
5
6
  const apple_utils_1 = require("@expo/apple-utils");
6
7
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
@@ -71,7 +72,6 @@ function formatContractMessage(message) {
71
72
  rootUrl,
72
73
  });
73
74
  }
74
- exports.formatContractMessage = formatContractMessage;
75
75
  /**
76
76
  * **Does not support App Store Connect API (CI).**
77
77
  */
@@ -99,4 +99,3 @@ async function assertContractMessagesAsync(context, spinner) {
99
99
  }
100
100
  }
101
101
  }
102
- exports.assertContractMessagesAsync = assertContractMessagesAsync;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { Certificate, RequestContext } from '@expo/apple-utils';
3
2
  import { DistributionCertificate, DistributionCertificateStoreInfo } from './Credentials.types';
4
3
  import { AuthCtx } from './authenticateTypes';
@@ -1,6 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.revokeDistributionCertificateAsync = exports.createDistributionCertificateAsync = exports.listDistributionCertificatesAsync = exports.transformCertificate = exports.getDistributionCertificateAsync = exports.getCertificateBySerialNumberAsync = exports.AppleTooManyCertsError = void 0;
3
+ exports.AppleTooManyCertsError = void 0;
4
+ exports.getCertificateBySerialNumberAsync = getCertificateBySerialNumberAsync;
5
+ exports.getDistributionCertificateAsync = getDistributionCertificateAsync;
6
+ exports.transformCertificate = transformCertificate;
7
+ exports.listDistributionCertificatesAsync = listDistributionCertificatesAsync;
8
+ exports.createDistributionCertificateAsync = createDistributionCertificateAsync;
9
+ exports.revokeDistributionCertificateAsync = revokeDistributionCertificateAsync;
4
10
  const apple_utils_1 = require("@expo/apple-utils");
5
11
  const authenticate_1 = require("./authenticate");
6
12
  const ora_1 = require("../../../ora");
@@ -14,7 +20,6 @@ async function getCertificateBySerialNumberAsync(context, serialNumber) {
14
20
  }
15
21
  return cert;
16
22
  }
17
- exports.getCertificateBySerialNumberAsync = getCertificateBySerialNumberAsync;
18
23
  async function getDistributionCertificateAsync(context, serialNumber) {
19
24
  // At most, this returns 2 values.
20
25
  const certificates = await apple_utils_1.Certificate.getAsync(context, {
@@ -26,7 +31,6 @@ async function getDistributionCertificateAsync(context, serialNumber) {
26
31
  });
27
32
  return (certificates.find(certificate => certificate.attributes.serialNumber === serialNumber) ?? null);
28
33
  }
29
- exports.getDistributionCertificateAsync = getDistributionCertificateAsync;
30
34
  function transformCertificate(cert) {
31
35
  return {
32
36
  id: cert.id,
@@ -39,7 +43,6 @@ function transformCertificate(cert) {
39
43
  serialNumber: cert.attributes.serialNumber,
40
44
  };
41
45
  }
42
- exports.transformCertificate = transformCertificate;
43
46
  async function listDistributionCertificatesAsync(authCtx) {
44
47
  const spinner = (0, ora_1.ora)(`Fetching Apple distribution certificates`).start();
45
48
  try {
@@ -63,7 +66,6 @@ async function listDistributionCertificatesAsync(authCtx) {
63
66
  throw error;
64
67
  }
65
68
  }
66
- exports.listDistributionCertificatesAsync = listDistributionCertificatesAsync;
67
69
  /**
68
70
  * Run from `eas credentials` -> iOS -> Add new Distribution Certificate
69
71
  */
@@ -94,7 +96,6 @@ async function createDistributionCertificateAsync(authCtx) {
94
96
  throw error;
95
97
  }
96
98
  }
97
- exports.createDistributionCertificateAsync = createDistributionCertificateAsync;
98
99
  async function revokeDistributionCertificateAsync(authCtx, ids) {
99
100
  const name = `Apple distribution certificate${ids?.length === 1 ? '' : 's'}`;
100
101
  const spinner = (0, ora_1.ora)(`Revoking ${name}`).start();
@@ -108,4 +109,3 @@ async function revokeDistributionCertificateAsync(authCtx, ids) {
108
109
  throw error;
109
110
  }
110
111
  }
111
- exports.revokeDistributionCertificateAsync = revokeDistributionCertificateAsync;
@@ -1,10 +1,15 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { App, BundleId, RequestContext } from '@expo/apple-utils';
3
2
  import { JSONObject } from '@expo/json-file';
4
3
  import { AuthCtx, UserAuthCtx } from './authenticateTypes';
5
4
  export interface IosCapabilitiesOptions {
6
5
  entitlements: JSONObject;
7
6
  usesBroadcastPushNotifications: boolean;
7
+ /**
8
+ * The bundle identifier of the parent app. Required for App Clips.
9
+ * App Clips are detected by the presence of the
10
+ * `com.apple.developer.parent-application-identifiers` entitlement.
11
+ */
12
+ parentBundleIdentifier?: string;
8
13
  }
9
14
  export interface AppLookupParams {
10
15
  accountName: string;
@@ -1,6 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isAppleError = exports.createAppAsync = exports.ensureAppExistsAsync = exports.syncCapabilityIdentifiersAsync = exports.syncCapabilitiesAsync = exports.ensureBundleIdExistsWithNameAsync = exports.ensureBundleIdExistsAsync = void 0;
3
+ exports.ensureBundleIdExistsAsync = ensureBundleIdExistsAsync;
4
+ exports.ensureBundleIdExistsWithNameAsync = ensureBundleIdExistsWithNameAsync;
5
+ exports.syncCapabilitiesAsync = syncCapabilitiesAsync;
6
+ exports.syncCapabilityIdentifiersAsync = syncCapabilityIdentifiersAsync;
7
+ exports.ensureAppExistsAsync = ensureAppExistsAsync;
8
+ exports.createAppAsync = createAppAsync;
9
+ exports.isAppleError = isAppleError;
4
10
  const tslib_1 = require("tslib");
5
11
  const apple_utils_1 = require("@expo/apple-utils");
6
12
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
@@ -11,36 +17,53 @@ const capabilityIdentifiers_1 = require("./capabilityIdentifiers");
11
17
  const contractMessages_1 = require("./contractMessages");
12
18
  const log_1 = tslib_1.__importDefault(require("../../../log"));
13
19
  const ora_1 = require("../../../ora");
20
+ /**
21
+ * The entitlement key that indicates a target is an App Clip.
22
+ * When present, the target requires special bundle ID registration with a parent app relationship.
23
+ */
24
+ const APP_CLIP_PARENT_APPLICATION_IDENTIFIERS_ENTITLEMENT = 'com.apple.developer.parent-application-identifiers';
14
25
  async function ensureBundleIdExistsAsync(authCtx, { accountName, projectName, bundleIdentifier }, options) {
15
26
  await ensureBundleIdExistsWithNameAsync(authCtx, {
16
27
  name: `@${accountName}/${projectName}`,
17
28
  bundleIdentifier,
18
29
  }, options);
19
30
  }
20
- exports.ensureBundleIdExistsAsync = ensureBundleIdExistsAsync;
21
31
  async function ensureBundleIdExistsWithNameAsync(authCtx, { name, bundleIdentifier }, options) {
22
32
  const context = (0, authenticate_1.getRequestContext)(authCtx);
23
- const spinner = (0, ora_1.ora)(`Linking bundle identifier ${chalk_1.default.dim(bundleIdentifier)}`).start();
33
+ // Detect App Clips by the presence of the parent-application-identifiers entitlement
34
+ const isAppClip = Boolean(options?.entitlements?.[APP_CLIP_PARENT_APPLICATION_IDENTIFIERS_ENTITLEMENT]);
35
+ const typeLabel = isAppClip ? 'App Clip bundle identifier' : 'bundle identifier';
36
+ const spinner = (0, ora_1.ora)(`Linking ${typeLabel} ${chalk_1.default.dim(bundleIdentifier)}`).start();
24
37
  let bundleId;
25
38
  try {
26
39
  // Get the bundle id
27
40
  bundleId = await apple_utils_1.BundleId.findAsync(context, { identifier: bundleIdentifier });
28
41
  if (!bundleId) {
29
- spinner.text = `Registering bundle identifier ${chalk_1.default.dim(bundleIdentifier)}`;
30
- // If it doesn't exist, create it
31
- bundleId = await apple_utils_1.BundleId.createAsync(context, {
32
- name,
33
- identifier: bundleIdentifier,
34
- });
42
+ spinner.text = `Registering ${typeLabel} ${chalk_1.default.dim(bundleIdentifier)}`;
43
+ if (isAppClip && options?.parentBundleIdentifier) {
44
+ // App Clips require the parent bundle ID's opaque ID
45
+ bundleId = await createAppClipBundleIdAsync(context, {
46
+ name,
47
+ bundleIdentifier,
48
+ parentBundleIdentifier: options.parentBundleIdentifier,
49
+ });
50
+ }
51
+ else {
52
+ // If it doesn't exist, create it
53
+ bundleId = await apple_utils_1.BundleId.createAsync(context, {
54
+ name,
55
+ identifier: bundleIdentifier,
56
+ });
57
+ }
35
58
  }
36
- spinner.succeed(`Bundle identifier registered ${chalk_1.default.dim(bundleIdentifier)}`);
59
+ spinner.succeed(`${isAppClip ? 'App Clip bundle' : 'Bundle'} identifier registered ${chalk_1.default.dim(bundleIdentifier)}`);
37
60
  }
38
61
  catch (err) {
39
62
  if (err.message.match(/An App ID with Identifier '(.*)' is not available/)) {
40
- spinner.fail(`The bundle identifier ${chalk_1.default.bold(bundleIdentifier)} is not available to team "${authCtx.team.name}" (${authCtx.team.id}), change it in your app config and try again.`);
63
+ spinner.fail(`The ${typeLabel} ${chalk_1.default.bold(bundleIdentifier)} is not available to team "${authCtx.team.name}" (${authCtx.team.id}), change it in your app config and try again.`);
41
64
  }
42
65
  else {
43
- spinner.fail(`Failed to register bundle identifier ${chalk_1.default.dim(bundleIdentifier)}`);
66
+ spinner.fail(`Failed to register ${typeLabel} ${chalk_1.default.dim(bundleIdentifier)}`);
44
67
  // Assert contract errors for easier resolution when the user has an expired developer account.
45
68
  if (err.message.match(/forbidden for security reasons/) ||
46
69
  // Unable to process request - PLA Update available - You currently don't have access to this membership resource. To resolve this issue, agree to the latest Program License Agreement in your developer account.
@@ -59,7 +82,26 @@ async function ensureBundleIdExistsWithNameAsync(authCtx, { name, bundleIdentifi
59
82
  await syncCapabilitiesAsync(bundleId, options);
60
83
  }
61
84
  }
62
- exports.ensureBundleIdExistsWithNameAsync = ensureBundleIdExistsWithNameAsync;
85
+ /**
86
+ * Creates an App Clip bundle identifier.
87
+ * App Clips require the parent bundle ID's opaque ID for registration.
88
+ */
89
+ async function createAppClipBundleIdAsync(context, { name, bundleIdentifier, parentBundleIdentifier, }) {
90
+ // First, find the parent bundle ID to get its opaque ID
91
+ const parentBundleId = await apple_utils_1.BundleId.findAsync(context, {
92
+ identifier: parentBundleIdentifier,
93
+ });
94
+ if (!parentBundleId) {
95
+ throw new Error(`Cannot create App Clip bundle identifier "${bundleIdentifier}" because the parent bundle identifier "${parentBundleIdentifier}" is not registered. ` +
96
+ `Please ensure the parent app's bundle identifier is registered first.`);
97
+ }
98
+ // Create the App Clip bundle ID with the parent relationship
99
+ return await apple_utils_1.BundleId.createAppClipAsync(context, {
100
+ name,
101
+ identifier: bundleIdentifier,
102
+ parentBundleIdId: parentBundleId.id,
103
+ });
104
+ }
63
105
  async function syncCapabilitiesAsync(bundleId, { entitlements, ...rest }) {
64
106
  const spinner = (0, ora_1.ora)(`Syncing capabilities`).start();
65
107
  // Stop spinning in debug mode so we can print other information
@@ -80,7 +122,6 @@ async function syncCapabilitiesAsync(bundleId, { entitlements, ...rest }) {
80
122
  // Always run this after syncing the capabilities...
81
123
  await syncCapabilityIdentifiersAsync(bundleId, { entitlements, ...rest });
82
124
  }
83
- exports.syncCapabilitiesAsync = syncCapabilitiesAsync;
84
125
  const buildMessage = (title, items) => items.length ? `${title}: ${items.join(', ')}` : '';
85
126
  async function syncCapabilityIdentifiersAsync(bundleId, { entitlements }) {
86
127
  const spinner = (0, ora_1.ora)(`Syncing capabilities identifiers`).start();
@@ -100,7 +141,6 @@ async function syncCapabilityIdentifiersAsync(bundleId, { entitlements }) {
100
141
  throw err;
101
142
  }
102
143
  }
103
- exports.syncCapabilityIdentifiersAsync = syncCapabilityIdentifiersAsync;
104
144
  async function ensureAppExistsAsync(userAuthCtx, { name, language, companyName, bundleIdentifier, sku, }) {
105
145
  const context = (0, authenticate_1.getRequestContext)(userAuthCtx);
106
146
  const spinner = (0, ora_1.ora)(`Linking to App Store Connect ${chalk_1.default.dim(bundleIdentifier)}`).start();
@@ -137,7 +177,6 @@ async function ensureAppExistsAsync(userAuthCtx, { name, language, companyName,
137
177
  spinner.succeed(`Prepared App Store Connect for ${chalk_1.default.bold(name)} ${chalk_1.default.dim(bundleIdentifier)}`);
138
178
  return app;
139
179
  }
140
- exports.ensureAppExistsAsync = ensureAppExistsAsync;
141
180
  function sanitizeName(name) {
142
181
  return (name
143
182
  // Replace emojis with a `-`
@@ -203,8 +242,6 @@ async function createAppAsync(context, props, retryCount = 0) {
203
242
  throw error;
204
243
  }
205
244
  }
206
- exports.createAppAsync = createAppAsync;
207
245
  function isAppleError(error) {
208
246
  return 'data' in error && 'errors' in error.data && Array.isArray(error.data.errors);
209
247
  }
210
- exports.isAppleError = isAppleError;
@@ -1,4 +1,3 @@
1
- /// <reference types="@expo/apple-utils/ts-declarations/expo__app-store" />
2
1
  import { App } from '@expo/apple-utils';
3
2
  /**
4
3
  * Ensure a TestFlight internal group with access to all builds exists for the app and has all admin users invited to it.
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ensureTestFlightGroupExistsAsync = void 0;
3
+ exports.ensureTestFlightGroupExistsAsync = ensureTestFlightGroupExistsAsync;
4
4
  const tslib_1 = require("tslib");
5
5
  const apple_utils_1 = require("@expo/apple-utils");
6
6
  const ensureAppExists_1 = require("./ensureAppExists");
@@ -36,7 +36,6 @@ async function ensureTestFlightGroupExistsAsync(app) {
36
36
  const admins = users.filter(user => user.attributes.roles?.includes(apple_utils_1.UserRole.ADMIN));
37
37
  await addAllUsersToInternalGroupAsync(group, admins);
38
38
  }
39
- exports.ensureTestFlightGroupExistsAsync = ensureTestFlightGroupExistsAsync;
40
39
  async function ensureInternalGroupAsync({ groups, app, }) {
41
40
  let betaGroup = groups.find(group => group.attributes.name === AUTO_GROUP_NAME);
42
41
  if (!betaGroup) {