Post

Replies

Boosts

Views

Activity

Reply to Xcode Cloud API - documentation
I think you need to look thru all the scmGitReferences to find the branch one from previous run for your branch. It looks like    "canonicalName": "refs/heads/stage" for my branch stage. {  "data": {   "type": "scmGitReferences",   "id": "6ce1ce69-c00b-46d1-8453-887f23b8JJHS",   "attributes": {    "name": "stage",    "canonicalName": "refs/heads/stage",    "isDeleted": false,    "kind": "BRANCH"   },   "links": {    "self": "https://api.appstoreconnect.apple.com/v1/scmGitReferences/6ce1ce69-c00b-46d1-8453-887f23b8JJHS"   }  },  "included": {} } This works for me {       "sourceBranchOrTag": {         "data": {          "type": "scmGitReferences",          "id": "6ce1ce69-c00b-46d1-8453-887f23b8JJHS"         }       },       workflow: {         data: {           type: "ciWorkflows",           id: `${branch === 'stage' ? stageWorkflow : prodWorkflow}`         }       }     }; How did I get the IDs? Start with your workflow:   const gitRef = await readAll('https://api.appstoreconnect.apple.com/v1/ciWorkflows/59D98329-2C36-4A9D-A657-B32EJUNK/relationships/repository');  console.log(JSON.stringify(gitRef, null, 2)); Then look at gitReferences:  const gitrepo = await readAll('https://api.appstoreconnect.apple.com/v1/scmRepositories/02604932-197a-48a0-b182-fa78f97JUNK/relationships/gitReferences');  console.log(JSON.stringify(gitrepo, null, 2)); then find the right one -- to see in detail:  const reference = await readAll('https://api.appstoreconnect.apple.com/v1/scmGitReferences/6ce1ce69-c00b-46d1-8453-887f23b8JJHS');  console.log(JSON.stringify(reference, null, 2));
Jan ’23
Reply to Xcode cloud and multiple bundle ids?
You can do this with the API. First, change your bundle in Xcode, and click the Cloud to authenticate. Create the workflow on the bundle id. Then you can switch your Xcode back to old bundle. Then just use the App Store Connect web site to manage it. Then to kick it off your pipeline (bitbucket or Azure Pipeline) can trigger the start on a branch using the appstoreconnectapi - start build number.
Jan ’23
Reply to Xcode Cloud API
OK I figured it out. Use: https://api.appstoreconnect.apple.com/v1/ciProducts/<ID>/buildRuns number - is the build Number. BUT! Sorts are not documented on this, so - how do I sort by number newest to oldest? Something like ?sort=number desc ??
Jan ’23
Reply to SFSafariViewController not loading web pages on Xcode 16 Simulator with iOS 18
In React Native I added config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = "arm64" Unsure why. I will remove that line and see if I can build.
Topic: Safari & Web SubTopic: General Tags:
Replies
Boosts
Views
Activity
Dec ’24
Reply to Xcode Cloud "The bundle version must be higher than the previously uploaded version."
I want to manage the build number m myself. I am happy to call an API to set it before I run the Xcode Cloud build. Or setting a flag to tell Xcode Cloud to use my build number! How do we et around this?
Replies
Boosts
Views
Activity
Feb ’24
Reply to App Store API for Xcode Cloud
+1
Replies
Boosts
Views
Activity
Nov ’23
Reply to Xcode Cloud API
Bump ! Does Apple monitor these discussions forums?
Replies
Boosts
Views
Activity
Apr ’23
Reply to Xcode Cloud API
Can we get a feature for this? SetBuild Number from API
Replies
Boosts
Views
Activity
Apr ’23
Reply to Xcode cloud and multiple bundle ids?
+1 how do we bundle different bundle Ids in XCODE CLOUD?
Replies
Boosts
Views
Activity
Jan ’23
Reply to How do we reset build number to 1 with Xcode Cloud
We need an API call in appstoreconnectapi to set build number - since we have 2 bundles and want the build numbers to be coordinated. Why do we have 2 bundles? Since we want STAGE to be testable in Testflight and PROD to be testable in Testflight. And we want to distinguish them and not get confused.
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode Cloud API - documentation
I think you need to look thru all the scmGitReferences to find the branch one from previous run for your branch. It looks like    "canonicalName": "refs/heads/stage" for my branch stage. {  "data": {   "type": "scmGitReferences",   "id": "6ce1ce69-c00b-46d1-8453-887f23b8JJHS",   "attributes": {    "name": "stage",    "canonicalName": "refs/heads/stage",    "isDeleted": false,    "kind": "BRANCH"   },   "links": {    "self": "https://api.appstoreconnect.apple.com/v1/scmGitReferences/6ce1ce69-c00b-46d1-8453-887f23b8JJHS"   }  },  "included": {} } This works for me {       "sourceBranchOrTag": {         "data": {          "type": "scmGitReferences",          "id": "6ce1ce69-c00b-46d1-8453-887f23b8JJHS"         }       },       workflow: {         data: {           type: "ciWorkflows",           id: `${branch === 'stage' ? stageWorkflow : prodWorkflow}`         }       }     }; How did I get the IDs? Start with your workflow:   const gitRef = await readAll('https://api.appstoreconnect.apple.com/v1/ciWorkflows/59D98329-2C36-4A9D-A657-B32EJUNK/relationships/repository');  console.log(JSON.stringify(gitRef, null, 2)); Then look at gitReferences:  const gitrepo = await readAll('https://api.appstoreconnect.apple.com/v1/scmRepositories/02604932-197a-48a0-b182-fa78f97JUNK/relationships/gitReferences');  console.log(JSON.stringify(gitrepo, null, 2)); then find the right one -- to see in detail:  const reference = await readAll('https://api.appstoreconnect.apple.com/v1/scmGitReferences/6ce1ce69-c00b-46d1-8453-887f23b8JJHS');  console.log(JSON.stringify(reference, null, 2));
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode cloud and multiple bundle ids?
You can do this with the API. First, change your bundle in Xcode, and click the Cloud to authenticate. Create the workflow on the bundle id. Then you can switch your Xcode back to old bundle. Then just use the App Store Connect web site to manage it. Then to kick it off your pipeline (bitbucket or Azure Pipeline) can trigger the start on a branch using the appstoreconnectapi - start build number.
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode Cloud API
OK I figured it out. Use: https://api.appstoreconnect.apple.com/v1/ciProducts/<ID>/buildRuns number - is the build Number. BUT! Sorts are not documented on this, so - how do I sort by number newest to oldest? Something like ?sort=number desc ??
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode Cloud API
The results come back as: data[].attributes.number and there are data[].attributes.startedDate etc...
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode Cloud Build programmatic access
You can do this - because the api for app store connect supports submitting a build. https://developer.apple.com/documentation/appstoreconnectapi/start_a_build The feature we need is ability to set env variables and build number programmatically.
Replies
Boosts
Views
Activity
Jan ’23
Reply to Xcode cloud and multiple bundle ids?
Yeah I am also testing adding to ios/ci_scripts/ci_post_clone.sh  A way to change the bundle ID, and will report back. Set the bundle ID Setup Xcode in Cloud See if ios/ci_scripts/ci_post_clone.sh  will work to switch it
Replies
Boosts
Views
Activity
Jan ’23