On Xbox (or PC) console: Detecting programmatically, in-title (title's client code) when your local user sent an invite, via the Xbox console shell?

Sze, Ben 0 Reputation points
2026-10-29T18:55:50.9366667+00:00

Is there any system event callback for Detecting programmatically, in-title (title's client code) when your local user sent an invite, via the Xbox console shell?

As well, who the user sent the invite to?

Windows for home | Windows 11 | Gaming
0 comments No comments

4 answers

Sort by: Most helpful
  1. Carl-L 24,820 Reputation points Microsoft External Staff Moderator
    2026-11-05T13:41:05.9+00:00

    Hello Sze, Ben,

    Thanks for replying.

    Your assessment is correct, MPA does not expose an RTA subscription/event mechanism for invite activity. Multiplayer Activity (MPA) feature surface covers setting/getting activities, sending invites, and recent players, but doesn't document an RTA event. It still exists as an Xbox services technology, but not all actions will expose RTA.


    If the answer is helpful, please click "Yes". If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Was this answer helpful?

    0 comments No comments

  2. Carl-L 24,820 Reputation points Microsoft External Staff Moderator
    2026-11-03T10:05:42.7933333+00:00

    Hello Sze, Ben,

    Welcome to Microsoft Q&A forum.

    As far as I know, there is no Event callback for that. Usually, the invitation will be sent by the game or apps, which usually system events won't log. Just want to make sure, what are you trying to find out about it?

    I'm waiting for your reply.

    Was this answer helpful?


  3. Sze, Ben 0 Reputation points
    2026-10-29T19:20:39.51+00:00

    a system toastie pops up about your invite successfully sent, but in the gdk title code, can it deterct that too?

    Was this answer helpful?

    0 comments No comments

  4. AI answer

    2026-10-29T18:56:41.8+00:00

    There is no documented title callback that reports when the local user sends an invite directly through the Xbox shell or identifies the recipients; if the title must know the recipients, it must own the send flow and retain their XUIDs.

    Shell and title-callable Xbox UI

    Xbox supports invites initiated through the shell or directly by the title.^1^

    For the Multiplayer Activity title-callable UI:

    1. Set the title’s current multiplayer activity.
    2. Call XGameUiShowMultiplayerActivityGameInviteAsync.
    3. Handle completion with XGameUiShowMultiplayerActivityGameInviteResult.

    The result is only an HRESULT; its documented signature has no output containing selected recipient XUIDs.^2^ Consequently, completion can tell the title that the UI operation completed or failed, but it does not disclose who the player selected. The UI API receives only the requesting local user.^3^

    auto async = std::make_unique<XAsyncBlock>();
    async->queue = queue;
    async->callback = [](XAsyncBlock* block)
    {
        std::unique_ptr<XAsyncBlock> cleanup{block};
        HRESULT hr = XGameUiShowMultiplayerActivityGameInviteResult(block);
        // hr reports operation success/failure; no recipient XUIDs are returned.
    };
    
    HRESULT hr = XGameUiShowMultiplayerActivityGameInviteAsync(
        async.get(), requestingUser);
    
    if (SUCCEEDED(hr))
        async.release();
    

    A successful result should therefore not be treated as an enumerable “invite sent to these users” event.

    When recipient identity is required

    Implement the selection in the title and send to known XUIDs. Depending on the multiplayer stack:

    • Multiplayer Activity (MPA): call XblMultiplayerActivitySendInvitesAsync with the XUID array after setting the current activity.
    • Multiplayer Manager: call XblMultiplayerManagerLobbySessionInviteUsers.
    • REST Multiplayer Activity API: send POST /titles/{titleId}/invites with invitedUsers; a successful operation returns 204 No Content.^4^

    For example, with Multiplayer Manager, the title already owns the recipient list:

    uint64_t recipients[] =
    {
        selectedPlayerXuid
    };
    
    HRESULT hr = XblMultiplayerManagerLobbySessionInviteUsers(
        xblUserHandle,
        recipients,
        std::size(recipients),
        nullptr,   // ContextStringId
        nullptr);  // CustomActivationContext
    

    The custom-UI flow explicitly accepts the selected players’ Xbox Live User IDs, allowing the title to record both the local sender and intended recipients when initiating the operation.^5^

    Do not confuse this with invite acceptance

    XGameInviteRegisterForEvent is a recipient-side acceptance notification, not a sender-side “invite sent” callback. It fires when an invited player accepts; its URI can contain the invited user, sender, and connection string.^6^

    Therefore:

    • Invite sent from the console shell: no documented in-title send event or recipient list.
    • Invite picker launched by the title: asynchronous completion is available, but no selected-recipient result.
    • Invite sent through title-controlled APIs: the title knows the recipients because it supplies their XUIDs.
    • Invite accepted by a recipient: an acceptance callback is available and contains sender/recipient information.

    References

    1. Invites overview
    2. XGameUiShowMultiplayerActivityGameInviteResult
    3. XGameUiShowMultiplayerActivityGameInviteAsync
    4. Send Invite
    5. Sends game invites using the Xbox platform invite title-callable UI (TCUI) by calling XblMultiplayerManagerLobbySessionInviteFriends with a custom activation co...
    6. Registers a callback to handle accepted multiplayer invites, parsing the invite URI to extract invited user, sender, and connection string information, and unre...
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer 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.