Share via

How can I download a package flight bundle programmatically?

Diogo Costa Maranhao Rodrigues 120 Reputation points
2026-03-24T13:30:26.6633333+00:00

I'm developing a Packaged Windows Service which is available on the Microsoft Store. Now I need to download the package flight bundle associated with the current logged account to perform a installation/update. How can I implement this?

  1. Running in LocalSystem context from service.
  2. Avoid StoreContext or AppInstallManager Solutions.
Windows development | WinUI
0 comments No comments

Answer accepted by question author
  1. Nancy Vo (WICLOUD CORPORATION) 2,805 Reputation points Microsoft External Staff Moderator
    2026-03-25T07:02:27.03+00:00

    Hi @Diogo Costa Maranhao Rodrigues ,

    Thanks for your question.

    There is no direct API that lets a LocalSystem service download a user-specific flight bundle on its own. The Store flight bundle is tied to the signed-in user’s Microsoft account, so StoreContext only works from code that runs in a real user session.

    I recommend this solution:

    1. Keep your service running as LocalSystem for background processing.
    2. When an update is needed, have the service trigger a helper process running in the logged-in user’s context.
    3. The helper process can then use StoreContext or AppInstallManager to:
      • Check for updates.
      • Request download and installation via the Microsoft Store.

    This ensures the operation runs with the correct user identity and remains within the supported platform model.

    I hope this addresses your question. If this response was helpful, please consider following the guidance to provide feedback


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.