Skip to content

Commit

Permalink
Merge pull request #6 from n-thumann/add_free_to_play_support
Browse files Browse the repository at this point in the history
Add support for Free to Play users
  • Loading branch information
n-thumann authored Jul 30, 2023
2 parents f005ac2 + b3bd61f commit d9fe363
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ You can also select a different region - preferably far away from your actual lo
## How it works

This extension overwrites the [`fetch`](https://developer.mozilla.org/en-US/docs/Web/API/fetch) method to intercept requests to the Xbox servers.
When loading [xbox.com/play](https://www.xbox.com/play), a POST request is made to `https://xgpuweb.gssv-play-prod.xboxlive.com/v2/login/user`.
When loading [xbox.com/play](https://www.xbox.com/play), a POST request is made to `https://xgpuweb.gssv-play-prod.xboxlive.com/v2/login/user` for Game Pass Ultimate users or `https://xgpuwebf2p.gssv...` for Free to Play users.
The response contains a list of all regions with one of them marked as the default region (shortened):

```json
Expand Down
2 changes: 1 addition & 1 deletion src/content/interceptors/regionInterceptor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class RegionInterceptor implements Interceptor {
method: "POST",
// @ts-ignore: URLPattern is not known to Typescript yet
urlPattern: new URLPattern(
"https://xgpuweb.gssv-play-prod.xboxlive.com/v2/login/user",
"https://xgpuweb(f2p)?.gssv-play-prod.xboxlive.com/v2/login/user",
),
};

Expand Down

0 comments on commit d9fe363

Please sign in to comment.