New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[spaceship] Use new app store statuses to filter app versions and app infos #21895
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
1fd7cb9
[spaceship] Use new app store statuses to filter app versions and app…
lucgrabowski 0f80209
[spaceship] Filter app infos using state attribute
lucgrabowski ae9a560
Remove developer removed from state from filter
lucgrabowski 8eb33e4
Add PROCESSING_FOR_DISTRIBUTION to filter live app store versions
lucgrabowski 69ad376
Update submit_for_review_spec to use app_version_state
lucgrabowski 5f326b7
Renaming attribute in docs
lucgrabowski 801e94c
Add attribute to fixtures
lucgrabowski af26024
Add a fixture and test for app info
lucgrabowski File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
137 changes: 137 additions & 0 deletions
137
spaceship/spec/connect_api/fixtures/tunes/app_infos.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
{ | ||
"data": [ | ||
{ | ||
"type": "appInfos", | ||
"id": "1111-11111", | ||
"attributes": { | ||
"appStoreState": "READY_FOR_SALE", | ||
"state": "READY_FOR_DISTRIBUTION", | ||
"appStoreAgeRating": "FOUR_PLUS", | ||
"brazilAgeRating": "L", | ||
"brazilAgeRatingV2": "SELF_RATED_L", | ||
"kidsAgeBand": null | ||
}, | ||
"relationships": { | ||
"ageRatingDeclaration": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/ageRatingDeclaration", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/ageRatingDeclaration" | ||
} | ||
}, | ||
"appInfoLocalizations": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/appInfoLocalizations", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/appInfoLocalizations" | ||
} | ||
}, | ||
"primaryCategory": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/primaryCategory", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/primaryCategory" | ||
} | ||
}, | ||
"primarySubcategoryOne": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/primarySubcategoryOne", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/primarySubcategoryOne" | ||
} | ||
}, | ||
"primarySubcategoryTwo": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/primarySubcategoryTwo", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/primarySubcategoryTwo" | ||
} | ||
}, | ||
"secondaryCategory": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/secondaryCategory", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/secondaryCategory" | ||
} | ||
}, | ||
"secondarySubcategoryOne": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/secondarySubcategoryOne", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/secondarySubcategoryOne" | ||
} | ||
}, | ||
"secondarySubcategoryTwo": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/relationships/secondarySubcategoryTwo", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111/secondarySubcategoryTwo" | ||
} | ||
} | ||
}, | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-11111" | ||
} | ||
}, | ||
{ | ||
"type": "appInfos", | ||
"id": "1111-2222", | ||
"attributes": { | ||
"appStoreState": "PREPARE_FOR_SUBMISSION", | ||
"state": "PREPARE_FOR_SUBMISSION", | ||
"appStoreAgeRating": "FOUR_PLUS", | ||
"brazilAgeRating": "L", | ||
"brazilAgeRatingV2": "SELF_RATED_L", | ||
"kidsAgeBand": null | ||
}, | ||
"relationships": { | ||
"ageRatingDeclaration": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/ageRatingDeclaration", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/ageRatingDeclaration" | ||
} | ||
}, | ||
"appInfoLocalizations": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/appInfoLocalizations", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/appInfoLocalizations" | ||
} | ||
}, | ||
"primaryCategory": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/primaryCategory", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/primaryCategory" | ||
} | ||
}, | ||
"primarySubcategoryOne": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/primarySubcategoryOne", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/primarySubcategoryOne" | ||
} | ||
}, | ||
"primarySubcategoryTwo": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/primarySubcategoryTwo", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/primarySubcategoryTwo" | ||
} | ||
}, | ||
"secondaryCategory": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/secondaryCategory", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/secondaryCategory" | ||
} | ||
}, | ||
"secondarySubcategoryOne": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/secondarySubcategoryOne", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/secondarySubcategoryOne" | ||
} | ||
}, | ||
"secondarySubcategoryTwo": { | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/relationships/secondarySubcategoryTwo", | ||
"related": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222/secondarySubcategoryTwo" | ||
} | ||
} | ||
}, | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/appInfos/1111-2222" | ||
} | ||
} | ||
], | ||
"links": { | ||
"self": "https://appstoreconnect.apple.com/iris/v1/apps/123456789/appInfos" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had expected to see
app_version_state
here. Are these 2 fields identical / duplicated in the returned data?Also
appVersionState
doesn't appear in the fixture data. Could we refresh the fixture data as well, to make it more up to date with real life data returned from the API? It would make it easier to review the code. ThanksThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added
appVersionState
values to fixtures in a new commit. A fixture forAppInfo
is not present yet and should be added to code.And about the state.
Those fields are not identical.
app_version_state
is an attribute ofAppStoreVersion
.Filtering of
AppInfo
needs to be done based onstate
.In the opan api spec,
AppInfo
doesn't have an app version state, but it hasstate
with less values, e.g. there is no PENDING_APPLE_RELEASE or PENDING_DEVELOPER_RELEASE, but there is simply PENDING_RELEASEFor reference:
https://developer.apple.com/documentation/appstoreconnectapi/list_all_app_store_versions_for_an_app
https://developer.apple.com/documentation/appstoreconnectapi/appstoreversion/attributes
appStoreState
:ACCEPTED, DEVELOPER_REMOVED_FROM_SALE, DEVELOPER_REJECTED, IN_REVIEW, INVALID_BINARY, METADATA_REJECTED, PENDING_APPLE_RELEASE, PENDING_CONTRACT, PENDING_DEVELOPER_RELEASE, PREPARE_FOR_SUBMISSION, PREORDER_READY_FOR_SALE, PROCESSING_FOR_APP_STORE, READY_FOR_REVIEW, READY_FOR_SALE, REJECTED, REMOVED_FROM_SALE, WAITING_FOR_EXPORT_COMPLIANCE, WAITING_FOR_REVIEW, REPLACED_WITH_NEW_VERSION, NOT_APPLICABLE
appVersionState
:ACCEPTED, DEVELOPER_REJECTED, IN_REVIEW, INVALID_BINARY, METADATA_REJECTED, PENDING_APPLE_RELEASE, PENDING_DEVELOPER_RELEASE, PREPARE_FOR_SUBMISSION, PROCESSING_FOR_DISTRIBUTION, READY_FOR_DISTRIBUTION, READY_FOR_REVIEW, REJECTED, REPLACED_WITH_NEW_VERSION, WAITING_FOR_EXPORT_COMPLIANCE, WAITING_FOR_REVIEW
https://developer.apple.com/documentation/appstoreconnectapi/appinfo/attributes
appStoreState
state
:ACCEPTED, DEVELOPER_REJECTED, IN_REVIEW, PENDING_RELEASE, PREPARE_FOR_SUBMISSION, READY_FOR_DISTRIBUTION, READY_FOR_REVIEW, REJECTED, REPLACED_WITH_NEW_INFO, WAITING_FOR_REVIEW
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added a fixture for
AppInfo
.