Skip to content

feat(metadata): support App Store review attachment#3595

Draft
EvanBacon wants to merge 2 commits intomainfrom
@bacon/metadata-review-attachment
Draft

feat(metadata): support App Store review attachment#3595
EvanBacon wants to merge 2 commits intomainfrom
@bacon/metadata-review-attachment

Conversation

@EvanBacon
Copy link
Copy Markdown
Contributor

@EvanBacon EvanBacon commented Apr 9, 2026

Summary

  • Adds an attachment field to the review block of the Apple metadata config so users can declare a single file (e.g. demo instructions PDF) to share with the App Store review team alongside contact + demo account info. The JSON schema, TypeScript types, reader and writer all gain first-class attachment support.
  • On push, the file is uploaded via AppStoreReviewDetail.uploadAttachmentAsync. Existing attachments are compared by MD5 against the local file (matching the screenshot sync's checksum-based skip logic), and re-uploaded only when the content has changed. Stale attachments are deleted before the new one is uploaded.
  • On pull, when the remote review detail has an attachment, the expected file path is recorded in the config under store/apple/review-attachment/<fileName>. No placeholder file is created on disk — the user is informed they need to place the file manually.

Known limitation: pull cannot download review attachments

This is a confirmed App Store Connect API limitation — see expo/third-party#146 for the full investigation.

The ASC OpenAPI spec confirms that AppStoreReviewAttachment only exposes fileName, fileSize, sourceFileChecksum, uploadOperations, and assetDeliveryState. There is no imageAsset, no assetToken, and no download URL. This is unlike AppScreenshot which has imageAsset.templateUrl for downloading.

Push works fully: upload, checksum comparison, and delete/replace all function correctly.
Pull records metadata only: the attachment path is written to the config so the round-trip (metadata:pull -> metadata:push) preserves the entry, but the actual file bytes cannot be fetched. An informational message explains this to the user during pull.

Test plan

  • yarn workspace eas-cli test for metadata/apple/(config|tasks/__tests__/app-review-detail) — all tests pass
  • Lint passes
  • Manual: eas metadata:pull against an app with an existing review attachment records the path and prints an informational message explaining the ASC limitation
  • Manual: eas metadata:push after placing a file at the configured path uploads it and replaces any stale attachment
  • Manual: re-running eas metadata:push with no file changes skips the re-upload (checksum match)

🤖 Generated with Claude Code

Adds an `attachment` field to the `review` block of the Apple metadata
config so users can ship a single file (e.g. demo instructions PDF) to
the App Store review team alongside contact + demo account info. Push
uploads the file via `AppStoreReviewDetail.uploadAttachmentAsync` and
skips re-uploading when the local MD5 matches the existing attachment.
Pull records the existing attachment's filename under
`store/apple/review-attachment/` (App Store Connect does not currently
expose a download URL for review attachments, so we cannot fetch the
bytes back).

Removes the `// TODO: add attachment` comments in
`apple/config/reader.ts` and `apple/config/writer.ts`.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

Subscribed to pull request

File Patterns Mentions
**/* @douglowder
packages/eas-cli/schema/** @byCedric
packages/eas-cli/src/metadata/** @byCedric

Generated by CodeMention

@EvanBacon EvanBacon marked this pull request as draft April 10, 2026 00:12
…SC limitation

The App Store Connect API does not expose a download URL for review
attachments (unlike AppScreenshot which has imageAsset.templateUrl).
This is a confirmed API limitation (expo/third-party#146), not a gap
in our implementation.

Changes:
- Remove directory/placeholder file creation during pull — only record
  the path in config for round-trip support
- Replace terse warning with informational message explaining WHY
  download is not possible and what the user should do
- Add code comment referencing the investigation (expo/third-party#146)
- Add test verifying no directory is created on disk during pull

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

❌ It looks like a changelog entry is missing for this PR. Add it manually to CHANGELOG.md.
⏩ If this PR doesn't require a changelog entry, such as if it's an internal change that doesn't affect the user experience, you can add the "no changelog" label to the PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant