isaced / appstore-connect-sdk

A TypeScript module for Node.js that interacts with the App Store Connect API, providing support for all APIs based on OpenAPI specification.
MIT License
25 stars 7 forks source link

Builds of an App #5

Closed chessbyte closed 1 year ago

chessbyte commented 1 year ago

I found my app with the following code:

  const client = new AppStoreConnectAPI({
      issuerId: issuerId,
      privateKeyId: keyId,
      privateKey: privateKey,
  });

  const apps = await client.call(AppsApi).appsGetCollection();
  const app = apps.data.find((app) => app.id === appId);

How can I get the builds associated with the app or, more generally, how can I follow any of the relationships in the app object?

chessbyte commented 1 year ago

Figured out how to do it

const appBuilds = await client.call(AppsApi).appsBuildsGetToManyRelated({ id: appId });