From 008a57ad3d68849ccc50f4008baf82b6c92f9bea Mon Sep 17 00:00:00 2001 From: PlayFab SDK Team Date: Mon, 25 Nov 2024 21:10:30 +0000 Subject: [PATCH] https://docs.microsoft.com/en-us/gaming/playfab/release-notes/#241122 --- PlayFabSdk/Scripts/PlayFab/PlayFab.js | 6 ++-- PlayFabSdk/Scripts/PlayFab/PlayFabClient.js | 17 +++++++++++ PlayFabSdk/Scripts/PlayFab/PlayFabServer.js | 17 +++++++++++ .../Scripts/typings/PlayFab/PlayFabAdmin.d.ts | 4 +++ .../typings/PlayFab/PlayFabClient.d.ts | 25 ++++++++++++++++ .../typings/PlayFab/PlayFabMultiplayer.d.ts | 4 ++- .../typings/PlayFab/PlayFabServer.d.ts | 29 +++++++++++++++++++ PlayFabSdk/package-lock.json | 4 +-- PlayFabSdk/package.json | 2 +- 9 files changed, 101 insertions(+), 7 deletions(-) diff --git a/PlayFabSdk/Scripts/PlayFab/PlayFab.js b/PlayFabSdk/Scripts/PlayFab/PlayFab.js index 62741549..b943e293 100644 --- a/PlayFabSdk/Scripts/PlayFab/PlayFab.js +++ b/PlayFabSdk/Scripts/PlayFab/PlayFab.js @@ -3,8 +3,8 @@ var url = require("url"); var https = require("https"); -exports.sdk_version = "2.165.241108"; -exports.buildIdentifier = "adobuild_nodesdk_114"; +exports.sdk_version = "2.166.241122"; +exports.buildIdentifier = "adobuild_nodesdk_8"; var settings = (exports.settings = { productionUrl: ".playfabapi.com", @@ -19,7 +19,7 @@ var _internalSettings = (exports._internalSettings = { entityToken: null, sessionTicket: null, requestGetParams: { - sdk: "JavaScriptSDK-2.165.241108", + sdk: "JavaScriptSDK-2.166.241122", }, }); diff --git a/PlayFabSdk/Scripts/PlayFab/PlayFabClient.js b/PlayFabSdk/Scripts/PlayFab/PlayFabClient.js index d8f95c8a..b99fd8d2 100644 --- a/PlayFabSdk/Scripts/PlayFab/PlayFabClient.js +++ b/PlayFabSdk/Scripts/PlayFab/PlayFabClient.js @@ -960,6 +960,23 @@ exports.GetPlayFabIDsFromSteamIDs = function (request, callback) { ); }; +exports.GetPlayFabIDsFromSteamNames = function (request, callback) { + if (PlayFab._internalSettings.sessionTicket == null) { + throw "Must be logged in to call this method"; + } + PlayFab.MakeRequest( + PlayFab.GetServerUrl() + "/Client/GetPlayFabIDsFromSteamNames", + request, + "X-Authorization", + PlayFab._internalSettings.sessionTicket, + function (error, result) { + if (callback != null) { + callback(error, result); + } + }, + ); +}; + exports.GetPlayFabIDsFromTwitchIDs = function (request, callback) { if (PlayFab._internalSettings.sessionTicket == null) { throw "Must be logged in to call this method"; diff --git a/PlayFabSdk/Scripts/PlayFab/PlayFabServer.js b/PlayFabSdk/Scripts/PlayFab/PlayFabServer.js index 038e5598..6990eb57 100644 --- a/PlayFabSdk/Scripts/PlayFab/PlayFabServer.js +++ b/PlayFabSdk/Scripts/PlayFab/PlayFabServer.js @@ -820,6 +820,23 @@ exports.GetPlayFabIDsFromSteamIDs = function (request, callback) { ); }; +exports.GetPlayFabIDsFromSteamNames = function (request, callback) { + if (PlayFab.settings.developerSecretKey == null) { + throw "Must have PlayFab.settings.DeveloperSecretKey set to call this method"; + } + PlayFab.MakeRequest( + PlayFab.GetServerUrl() + "/Server/GetPlayFabIDsFromSteamNames", + request, + "X-SecretKey", + PlayFab.settings.developerSecretKey, + function (error, result) { + if (callback != null) { + callback(error, result); + } + }, + ); +}; + exports.GetPlayFabIDsFromTwitchIDs = function (request, callback) { if (PlayFab.settings.developerSecretKey == null) { throw "Must have PlayFab.settings.DeveloperSecretKey set to call this method"; diff --git a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabAdmin.d.ts b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabAdmin.d.ts index 2d6f4048..4598c3d8 100644 --- a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabAdmin.d.ts +++ b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabAdmin.d.ts @@ -2541,6 +2541,8 @@ declare module PlayFabAdminModels { | "StatisticColumnLengthMismatch" | "InvalidExternalEntityId" | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" | "MatchmakingEntityInvalid" | "MatchmakingPlayerAttributesInvalid" | "MatchmakingQueueNotFound" @@ -2820,6 +2822,8 @@ declare module PlayFabAdminModels { | "GameSaveFileNotUploaded" | "GameSaveBadRequest" | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" | "StateShareForbidden" | "StateShareTitleNotInFlight" | "StateShareStateNotFound" diff --git a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabClient.d.ts b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabClient.d.ts index 75774c61..f6eea1ff 100644 --- a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabClient.d.ts +++ b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabClient.d.ts @@ -386,6 +386,13 @@ declare module PlayFabClientModule { request: PlayFabClientModels.GetPlayFabIDsFromSteamIDsRequest | null, callback: PlayFabModule.ApiCallback | null, ): void; + // Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are persona + // names. + // https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromsteamnames + GetPlayFabIDsFromSteamNames( + request: PlayFabClientModels.GetPlayFabIDsFromSteamNamesRequest | null, + callback: PlayFabModule.ApiCallback | null, + ): void; // Retrieves the unique PlayFab identifiers for the given set of Twitch identifiers. The Twitch identifiers are the IDs for // the user accounts, available as "_id" from the Twitch API methods (ex: // https://github.com/justintv/Twitch-API/blob/master/v3_resources/users.md#get-usersuser). @@ -2688,6 +2695,17 @@ declare module PlayFabClientModels { Data?: SteamPlayFabIdPair[]; } + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { + // Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 2,000 in + // length. + SteamNames: string[]; + } + + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + // Mapping of Steam identifiers to PlayFab identifiers. + Data?: SteamNamePlayFabIdPair[]; + } + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { // Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot // exceed 2,000 in length. @@ -4233,6 +4251,13 @@ declare module PlayFabClientModels { Version: number; } + export interface SteamNamePlayFabIdPair { + // Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. + PlayFabId?: string; + // Unique Steam identifier for a user, also known as Steam persona name. + SteamName?: string; + } + export interface SteamPlayFabIdPair { // Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. PlayFabId?: string; diff --git a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabMultiplayer.d.ts b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabMultiplayer.d.ts index 6f46c698..0843c7e0 100644 --- a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabMultiplayer.d.ts +++ b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabMultiplayer.d.ts @@ -603,7 +603,9 @@ declare module PlayFabMultiplayerModels { | "CentralIndia" | "UaeNorth" | "UkSouth" - | "SwedenCentral"; + | "SwedenCentral" + | "CanadaCentral" + | "MexicoCentral"; type AzureVmFamily = "A" diff --git a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabServer.d.ts b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabServer.d.ts index df27f1f0..bfeb28d0 100644 --- a/PlayFabSdk/Scripts/typings/PlayFab/PlayFabServer.d.ts +++ b/PlayFabSdk/Scripts/typings/PlayFab/PlayFabServer.d.ts @@ -327,6 +327,13 @@ declare module PlayFabServerModule { request: PlayFabServerModels.GetPlayFabIDsFromSteamIDsRequest | null, callback: PlayFabModule.ApiCallback | null, ): void; + // Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are persona + // names. + // https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromsteamnames + GetPlayFabIDsFromSteamNames( + request: PlayFabServerModels.GetPlayFabIDsFromSteamNamesRequest | null, + callback: PlayFabModule.ApiCallback | null, + ): void; // Retrieves the unique PlayFab identifiers for the given set of Twitch identifiers. The Twitch identifiers are the IDs for // the user accounts, available as "_id" from the Twitch API methods (ex: // https://github.com/justintv/Twitch-API/blob/master/v3_resources/users.md#get-usersuser). @@ -2437,6 +2444,8 @@ declare module PlayFabServerModels { | "StatisticColumnLengthMismatch" | "InvalidExternalEntityId" | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" | "MatchmakingEntityInvalid" | "MatchmakingPlayerAttributesInvalid" | "MatchmakingQueueNotFound" @@ -2716,6 +2725,8 @@ declare module PlayFabServerModels { | "GameSaveFileNotUploaded" | "GameSaveBadRequest" | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" | "StateShareForbidden" | "StateShareTitleNotInFlight" | "StateShareStateNotFound" @@ -3250,6 +3261,17 @@ declare module PlayFabServerModels { Data?: SteamPlayFabIdPair[]; } + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { + // Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 2,000 in + // length. + SteamNames: string[]; + } + + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + // Mapping of Steam identifiers to PlayFab identifiers. + Data?: SteamNamePlayFabIdPair[]; + } + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { // Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot // exceed 2,000 in length. @@ -4545,6 +4567,13 @@ declare module PlayFabServerModels { Version: number; } + export interface SteamNamePlayFabIdPair { + // Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. + PlayFabId?: string; + // Unique Steam identifier for a user, also known as Steam persona name. + SteamName?: string; + } + export interface SteamPlayFabIdPair { // Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. PlayFabId?: string; diff --git a/PlayFabSdk/package-lock.json b/PlayFabSdk/package-lock.json index 902cf42d..16a8fc73 100644 --- a/PlayFabSdk/package-lock.json +++ b/PlayFabSdk/package-lock.json @@ -1,12 +1,12 @@ { "name": "playfab-sdk", - "version": "2.165.241108", + "version": "2.166.241122", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "playfab-sdk", - "version": "2.165.241108", + "version": "2.166.241122", "license": "Apache-2.0", "devDependencies": { "@types/node": "^9.6.55", diff --git a/PlayFabSdk/package.json b/PlayFabSdk/package.json index 66934deb..c4dfd16c 100644 --- a/PlayFabSdk/package.json +++ b/PlayFabSdk/package.json @@ -1,6 +1,6 @@ { "name": "playfab-sdk", - "version": "2.165.241108", + "version": "2.166.241122", "description": "Playfab SDK for node.js applications", "license": "Apache-2.0", "devDependencies": {