A Ruby interface to the App Store Connect API
This project has been a significant part of my professional life, and I am grateful for the community that has grown around it. Unfortunately, due to ongoing personal constraints, I am no longer able to actively maintain this repository.
- New feature development is paused indefinitely.
- Issues and pull requests may not receive timely review.
- Security fixes and dependency updates cannot be guaranteed.
The repository will remain public and available under its existing license, but it should be considered unmaintained unless new maintainers step forward.
If you or your organization rely on this project and are willing to take on long-term stewardship, I would welcome the opportunity to transition ownership.
Please open an issue with the title:
Maintainer Interest: <your name or organization>
and include:
- Your GitHub profile
- Relevant experience with Ruby and this project
- Your expectations and goals for the project
To everyone who has contributed, opened issues, written documentation, or built software on top of this code — thank you. This community has been the most rewarding part of the project.
— Kyle Decot
Add this line to your application's Gemfile:
gem 'app_store_connect'And then execute:
$ bundleOr install it yourself as:
$ gem install app_store_connectAppStoreConnect.config = {
issuer_id: 'issuer_id',
key_id: 'key_id',
private_key: File.read(File.new("/Path/AuthKey.p8"))
}
app_store_connect = AppStoreConnect::Client.new
app_store_connect.apps
app_store_connect.app(id: '1234')
app_store_connect.builds(id: '1234')app_store_connect.create_bundle_id(
name: 'Example',
identifier: 'com.kyledecot.Example',
platform: 'IOS'
) app_store_connect.sales_reports(
filter: {
report_type: 'SALES',
report_sub_type: 'SUMMARY',
frequency: 'DAILY',
vendor_number: '123456'
}
)devices = app_store_connect.devices
puts JSON.pretty_generate(devices)created_device = app_store_connect.create_device(
name: 'name',
platform: 'IOS',
udid: 'udid'
)
puts JSON.pretty_generate(created_device)app_store_connect.update_app_store_version(
id: '<app-store-version-id>',
version_string: '1.0'
)app_store_connect.update_app_store_version_build(
id: '<app-store-version-id>',
build_id: '<build-id>'
)app_store_connect.create_review_submission_item(
relationships: {
reviewSubmission: {
data: {
id: '<review-submission-id>',
type: 'reviewSubmissions'
}
},
appStoreVersion: {
data: {
id: '<app-store-version-id>',
type: 'appStoreVersions'
}
}
}
)app_store_connect.create_in_app_purchase_price_schedule(
relationships: {
manual_prices: {
data: [
{
type: 'inAppPurchasePrices',
id: '${price1}'
}
]
},
in_app_purchase: {
data: {
type: 'inAppPurchases',
id: '<in-app-purchase-id>'
}
}
},
included: [
{
type: 'inAppPurchasePrices',
id: '${price1}',
attributes: {
startDate: nil
},
relationships: {
inAppPurchaseV2: {
data: {
type: 'inAppPurchases',
id: '<in-app-purchase-id>'
}
},
inAppPurchasePricePoint: {
data: {
type: 'inAppPurchasePricePoints',
id: '<price-point-id>'
}
}
}
}
]
)app_store_connect.add_build_beta_groups(
id: '<build-id>',
data: [{id: '<beta-group-id>'}]
)
app_store_connect.delete_build_beta_groups(
id: '<build-id>',
data: [{id: '<beta-group-id>'}]
)It's function key from schema.json file.
() is mean: you have mapped to http_body_type in file schema.json
http_body_type have a value type. Based on this value, we can find the definition of the relevant configuration in the source code of ruby.
app_store_connect.in_app_purchase(id: 123, include: 'appStoreReviewScreenshot,pricePoints')app_store_connect.in_app_purchase(id: 123, fields: 'name,productId')After checking out the repo, run bundle install to install dependencies. Then, run rake spec to run the tests. You can also run rake console for an interactive prompt that will allow you to experiment.
Bug reports and pull requests are welcome on GitHub at https://github.com/kyledecot/app_store_connect.
The gem is available as open source under the terms of the MIT License.
