This script collects status and metric data of app from AppStore Connect and dispatches them to the notifiers(LINE, Slack, or CSV files even).
- Support collecting status of both App and TestFlight build
- Support collecting metric datas from Apps
- Share status change via Slack and LINE(or any customize notifier)
- Supoprt to configure mutiple notifiers for multiple Apps and TestFilght builds
- Generate CSV report for metric datas
- Pure TypeScript and no fastlane required.
Create config.json
(refer to config.json.example
) and configure API, apps, and notifiers.
This script supports two type of API.
- Refer to Creating API Keys for App Store Connect API to generate a private key.
- Fill the
API
section inconfig.json
.
"API": {
"type": "api/app-store-connect-api",
"constructor": [ "issuer_id", "key_id", "private_key_file_path" ]
},
Iris API is used in AppStore Connect web site and is unoffical.
Fill the API
section config.json
.
"API": {
"type": "api/iris-connect-api",
"constructor": [ "username", "password" ]
},
This script supports three type of notifiers and all notifiers are configured in notifiers
section in `config.json.
You can config multiple notifiers but they much have different names.
Console notifier logs all the changed in console.
{
"name": "Sample Console Notifier",
"class": "notifier/console-notifier",
"constructor": []
},
Slack notifier sends app status changes to a specific channel of slack.
{
"name": "Sample Slack Notifier",
"class": "notifier/slack-notifier",
"constructor": [ "slack_token", "slack_channel_name" ]
}
LINE notifier sends app status changes via LINE Notify.
{
"name": "Sample LINE Notifier",
"class": "notifier/line-notifier",
"constructor": [ "line_notify_token" ]
},
CSV notifier collects app metric data and generate CSV files from them.
{
"name": "Sample CSV Notifier",
"class": "notifier/csv-notifier",
"constructor": [ "directory of CSV files" ]
}
Apps are configured in apps
section of config.json
.
App config needs a bundleId
and a list of notifier names.
{
"bundleId": "app_bundle",
"notifiers": ["Notifier Name 1", "Notifier Name 2"]
},
TestFlights are configured in testflight
section of config.json
.
The parameters of TestFlight build are the same as App
.
{
"bundleId": "app_bundle",
"notifiers": ["Notifier Name 1", "Notifier Name 2"]
},
This script can schedule update jobs.
The schedule is configured in schedule
section of config.json
. The parameter applies the syntax of cron job.
Example: The config below will run update every minute.
"schedule": "0 * * * * *"
npm start update
npm start migrate
npm start schedule
pm2 start process.json
You may want to run pm2 save
to save the status.
You can make any custom notifier to meet your needs.
The notifier interface is defined in src/notifier/notifier.ts
.
export interface Notifier {
notify(appVersion: AppVersion): Promise<void>
notifyTestFlightBuild(build: TestFlightBuild): Promise<void>
}
You can create a new notifier class that implements this interface and export it as default (example).
Then configure it in config.json
like below:
{
"notifiers": [
{
"name": "Awesome Notifier",
"class": "awesome-class-here",
"constructor": [ "all-the-arguments-for-constructor" ]
},
...
],
...
}