When uploading an application to App Center, Jenkins outputs a message similar to this:

      File found: XXX
      Creating an upload resource.
      Create upload resource successful.
      Uploading app to resource.
      Upload app to resource successful.
      Committing resource.
      Committing resource successful.
      Distributing resource.
      Distributing resource successful.

       It would be very handful to have the final URL to quickly retrieve the release in the AppCenter web interface : 

      Distributing resource successful
      Resource available at: https://appcenter.ms/orgs/<organisation_name>/apps/<application_name>/distribute/releases/<release_number>

       


      Assumption:  The message Distributing resource successful is printed in the execute function of the java/io/jenkins/plugins/appcenter/task/internal/DistributeResourceTask class which seems to contain the upload URL.

          [JENKINS-59931] Print URL of uploaded resource

          Mez Pahlan added a comment -

          Hi kvalentinchareyre sorry for the late reply. I've been looking through the API docs and there isn't an API that give you want you want unfortunately.

          After we have uploaded the resource and committed it we get back an object that contains a release url from this API. This unfortunately looks like: v0.1/apps/{owner_name}/{app_name}/releases/{release_id}. Notice this is only an endpoint and not the actual url - it is missing the schema and the host and the first part of it is wrong. I don't want to start guessing what this might be for various users so don't think it is appropriate to infer anything from this unless we can find an official API from Microsoft.

          Having said that, if you call that release url as a GET request you get a rather large object back that does contain a direct download url. It looks like it doesn't take you to the download page with the information about the build (release notes, hashes, etc) but will allow you to download the file from AppCenter directly. I can see about exposing that as some sort of build status badge or similar. Would you want me to look into that?

          Mez Pahlan added a comment - Hi kvalentinchareyre sorry for the late reply. I've been looking through the API docs and there isn't an API that give you want you want unfortunately. After we have uploaded the resource and committed it we get back an object that contains a release url from this API . This unfortunately looks like: v0.1/apps/{owner_name}/{app_name}/releases/{release_id }. Notice this is only an endpoint and not the actual url - it is missing the schema and the host and the first part of it is wrong. I don't want to start guessing what this might be for various users so don't think it is appropriate to infer anything from this unless we can find an official API from Microsoft. Having said that, if you call that release url as a GET request you get a rather large object back that does contain a direct download url. It looks like it doesn't take you to the download page with the information about the build (release notes, hashes, etc) but will allow you to download the file from AppCenter directly. I can see about exposing that as some sort of build status badge or similar. Would you want me to look into that?

          Valentin Chareyre added a comment - - edited

          Hello mezpahlan

          Thank you for your response.

          I've been looking through the API docs and there isn't an API that give you want you want unfortunately

          That's unfortunate.... Maybe it's something you can ask to the Microsoft team?

           

          Having said that, if you call that release url as a GET request you get a rather large object back that does contain a direct download url. It looks like it doesn't take you to the download page with the information about the build (release notes, hashes, etc) but will allow you to download the file from AppCenter directly. I can see about exposing that as some sort of build status badge or similar. Would you want me to look into that?

           
          That would be very nice of you. But don't bother too much.

          Valentin Chareyre added a comment - - edited Hello mezpahlan Thank you for your response. I've been looking through the API docs and there isn't an API that give you want you want unfortunately That's unfortunate.... Maybe it's something you can ask to the Microsoft team?   Having said that, if you call that release url as a GET request you get a rather large object back that  does  contain a direct download url. It looks like it doesn't take you to the download page with the information about the build (release notes, hashes, etc) but will allow you to download the file from AppCenter directly. I can see about exposing that as some sort of build status badge or similar. Would you want me to look into that?   That would be very nice of you. But don't bother too much.

            Unassigned Unassigned
            kvalentinchareyre Valentin Chareyre
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: