diff --git a/.arcconfig b/.arcconfig deleted file mode 100644 index e8806779..00000000 --- a/.arcconfig +++ /dev/null @@ -1,3 +0,0 @@ -{ - "phabricator.uri" : "https://phab.playfabdev.com/" -} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 4f74d1ce..78689f33 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +**/*[Tt]estTitleData.json* + bin/ obj/ .vs/ diff --git a/JavaScriptJobTemplate.yml b/JavaScriptJobTemplate.yml new file mode 100644 index 00000000..731e03c9 --- /dev/null +++ b/JavaScriptJobTemplate.yml @@ -0,0 +1,58 @@ +# JOB LEVEL TEMPLATE: +# Used to build JavaScript +# Reusable +# Meant to be run from the single JavaScriptTemplate pipeline (default), or +# from a multi-pipeline such as publishing (should specify alternate params) + +parameters: +- name: ApiSpecSource + displayName: ApiSpecSource + type: string + default: -apiSpecGitUrl https://raw.githubusercontent.com/PlayFab/API_Specs/master/ +- name: CommitMessage + displayName: CommitMessage + type: string + default: Automated build from ADO Pipeline +- name: GitDestBranch + displayName: GitDestBranch + type: string + default: doNotCommit +- name: GitJSetupBranch + displayName: GitJSetupBranch + type: string + default: master +- name: GitSdkGenBranch + displayName: GitSdkGenBranch + type: string + default: master +- name: isVersioned + displayName: isVersioned + type: boolean + default: false +- name: expectedNumApiGroups + displayName: expectedNumApiGroups + type: number + default: 14 +- name: SelfTemplateResource + displayName: SelfTemplateResource + type: string + default: self + +jobs: +- job: JavaScriptJobTemplate + steps: + - bash: echo JavaScriptJobTemplate +- job: JavaScriptTemplate + pool: + vmImage: 'windows-latest' + steps: + - template: JavaScriptStepTemplate.yml + parameters: + ApiSpecSource: ${{ parameters.ApiSpecSource }} + CommitMessage: ${{ parameters.CommitMessage }} + GitDestBranch: ${{ parameters.GitDestBranch }} + GitJSetupBranch: ${{ parameters.GitJSetupBranch }} + GitSdkGenBranch: ${{ parameters.GitSdkGenBranch }} + isVersioned: ${{ parameters.isVersioned }} + expectedNumApiGroups: ${{ parameters.expectedNumApiGroups }} + SelfTemplateResource: ${{ parameters.SelfTemplateResource }} diff --git a/JavaScriptResourceTemplate.yml b/JavaScriptResourceTemplate.yml new file mode 100644 index 00000000..0c0328c6 --- /dev/null +++ b/JavaScriptResourceTemplate.yml @@ -0,0 +1,30 @@ +# TOP LEVEL TEMPLATE: +# Can only be used to run the single JavaScriptTemplate pipeline. +# Why: Resources can only be defined once. +# This determines the resources available to all "jobs" and "steps" no matter which templates are loaded after this +# If resources is ever defined again, it'll break so badly that the pipeline won't even parse + +resources: + repositories: + - repository: JenkinsSdkSetupScripts + type: github + endpoint: GitHub_PlayFab + name: PlayFab/JenkinsSdkSetupScripts + - repository: API_Specs + type: github + endpoint: GitHub_PlayFab + name: PlayFab/API_Specs + - repository: SdkGenerator + type: github + endpoint: GitHub_PlayFab + name: PlayFab/SdkGenerator + - repository: JavaScriptSDK + endpoint: GitHub_PlayFab + type: github + name: PlayFab/JavaScriptSDK + +jobs: +- job: JavaScriptResourceTemplate + steps: + - bash: echo JavaScriptResourceTemplate +- template: JavaScriptJobTemplate.yml diff --git a/JavaScriptStepTemplate.yml b/JavaScriptStepTemplate.yml new file mode 100644 index 00000000..72dbaa6d --- /dev/null +++ b/JavaScriptStepTemplate.yml @@ -0,0 +1,96 @@ +# STEPS LEVEL TEMPLATE: +# Used to build JavaScript +# Reusable +# Used to "hide" the additional variables specific to this SDK which shouldn't be set from a higher level, or +# shared from a multi-build pipeline like a publish + +parameters: +- name: ApiSpecSource + displayName: ApiSpecSource + type: string + default: -apiSpecGitUrl https://raw.githubusercontent.com/PlayFab/API_Specs/master/ +- name: CommitMessage + displayName: CommitMessage + type: string + default: Automated build from ADO Pipeline +- name: GitDestBranch + displayName: GitDestBranch + type: string + default: doNotCommit +- name: SdkName + displayName: SdkName + type: string + default: JavaScriptSDK +- name: GitJSetupBranch + displayName: GitJSetupBranch + type: string + default: master +- name: GitSdkGenBranch + displayName: GitSdkGenBranch + type: string + default: master +- name: isVersioned + displayName: isVersioned + type: boolean + default: false +- name: expectedNumApiGroups + displayName: expectedNumApiGroups + type: number + default: 14 +- name: SelfTemplateResource + displayName: SelfTemplateResource + type: string + default: self + +steps: +- checkout: JenkinsSdkSetupScripts + clean: true + path: s +- checkout: API_Specs + clean: true + path: s/API_Specs +- checkout: SdkGenerator + clean: true + path: s/SdkGenerator +- checkout: ${{ parameters.SelfTemplateResource }} + clean: true + submodules: true + path: s/sdks/JavaScriptSDK + persistCredentials: true +- bash: | + set -e + + echo alias the ADO variables into local variables + ApiSpecSource="${{ parameters.ApiSpecSource }}" + CommitMessage="${{ parameters.CommitMessage }}" + GitDestBranch="${{ parameters.GitDestBranch }}" + SdkName="${{ parameters.SdkName }}" + WORKSPACE=$(pwd -W) + # Hack attempt to get WORKSPACE into a sub-environment + export WORKSPACE="$WORKSPACE" + + echo === load util.sh to find msbuild === + . "$WORKSPACE/JenkinsSdkSetupScripts/JenkinsScripts/Pipeline/util.sh" + + . "$WORKSPACE/JenkinsSdkSetupScripts/JenkinsScripts/Pipeline/testInit.sh" + + cd "$WORKSPACE/SDKGenerator/SDKBuildScripts" + export PF_TEST_TITLE_DATA_JSON="$WORKSPACE\JenkinsSdkSetupScripts\Creds\testTitleData.json" + . ./shared_build.sh + + echo === Build the JavaScript Project === + Find2019MsBuild || Find2017MsBuild + "$MSBUILD_EXE" "$WORKSPACE\\sdks\\$SdkName\\PlayFabTestingExample\\PlayFabApiTest.sln" //restore //t:Rebuild + + if [ $isVersioned = true ] ; + then + echo === publish if necessary === + cd "$WORKSPACE/sdks/$SdkName/PlayFabSdk" + npm publish + fi + displayName: 'Build/Test/Report' +- task: PublishTestResults@2 + inputs: + testResultsFormat: 'JUnit' + testResultsFiles: '*.xml' + testRunTitle: JavaScriptTemplate diff --git a/PlayFabSdk/package.json b/PlayFabSdk/package.json new file mode 100644 index 00000000..817f859b --- /dev/null +++ b/PlayFabSdk/package.json @@ -0,0 +1,10 @@ +{ + "name": "playfab-web-sdk", + "version": "1.222.260922", + "description": "Playfab SDK for JS client applications", + "license": "Apache-2.0", + "repository": { + "type": "git", + "url": "https://github.com/playfab/JavaScriptSDK" + } +} diff --git a/PlayFabSdk/readme.md b/PlayFabSdk/readme.md new file mode 100644 index 00000000..113deb94 --- /dev/null +++ b/PlayFabSdk/readme.md @@ -0,0 +1,65 @@ +# JavaScriptSDK README + + +## 1. Overview: + +JavaScriptSDK for the Client API of PlayFab + +This SDK can alternatively be used via our CDN. Additional details can be found [here](https://blog.playfab.com/blog/playfab-now-serving-javascript-sdk-via-cdn). + +If you want to start coding right away, check out our [JavaScript Getting Started Guide](JavaScriptGettingStarted.md) + + +## 2. Prerequisites: + +* Users should be very familiar with the topics covered in our [getting started guide](https://api.playfab.com/docs/general-getting-started). + +To connect to the PlayFab service, your machine must be running TLS v1.2 or better. +* For Windows, this means Windows 7 and above +* [Official Microsoft Documentation](https://msdn.microsoft.com/en-us/library/windows/desktop/aa380516%28v=vs.85%29.aspx) +* [Support for SSL/TLS protocols on Windows](http://blogs.msdn.com/b/kaushal/archive/2011/10/02/support-for-ssl-tls-protocols-on-windows.aspx) + + +## 3. Example Project (UNDER CONSTRUCTION) + +The Example project is being revised for the upcoming 1.0 release + +This sdk includes an optional example project that is used by PlayFab to verify sdk features are fully functional. + +Please read about the testTitleData.json format, and purpose here: +* [testTitleData.md](https://github.com/PlayFab/SDKGenerator/blob/master/JenkinsConsoleUtility/testTitleData.md) must be created and placed in the root of the example (beside index.html & PlayFabApiTest.ts), and must be named "testTitleData.json" + + +## 4. Troubleshooting: + +For a complete list of available APIs, check out the [online documentation](http://api.playfab.com/Documentation/). + +#### Contact Us +We love to hear from our developer community! +Do you have ideas on how we can make our products and services better? + +Our Developer Success Team can assist with answering any questions as well as process any feedback you have about PlayFab services. + +[Forums, Support and Knowledge Base](https://community.playfab.com/index.html) + +## 7. NPM support: +You may install JavaScript SDK with npm by running : + +`npm install playfab-web-sdk` + +Notice that it will install web JavaScript package as opposed to `npm install playfab` which will install NodeJS SDK. + +While npm is generally used for server side packages, you may use one of popular build tools to mix NPM installed packages into your clientside JS codebase. Consider Babel, Webpack, Gulp or Grunt for different approaches to building and automation. + +## 6. Acknowledgements + + [dylanh724](https://www.github.com/dylanh724) - The previous tutorial before the current [Getting Started Guide](JavaScriptGettingStarted.md) + + +## 7. Copyright and Licensing Information: + + Apache License -- + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + Full details available within the LICENSE file. \ No newline at end of file diff --git a/PlayFabSdk/src/PlayFab/PlayFabAddonApi.js b/PlayFabSdk/src/PlayFab/PlayFabAddonApi.js new file mode 100644 index 00000000..24cba57f --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabAddonApi.js @@ -0,0 +1,371 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.AddonApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + ConfigurePSNEventStreams: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/ConfigurePSNEventStreams", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdatePSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdatePSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeletePSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeletePSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetPSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetPSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabAddonSDK = PlayFab.AddonApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabAdminApi.js b/PlayFabSdk/src/PlayFab/PlayFabAdminApi.js index 4206df24..b543d7be 100644 --- a/PlayFabSdk/src/PlayFab/PlayFabAdminApi.js +++ b/PlayFabSdk/src/PlayFab/PlayFabAdminApi.js @@ -6,655 +6,734 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" } + }, - xhr.onerror = function () { - if (callback == null) - return; + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); + if (!authValue) throw authError; } - - xhr.send(requestBody); + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.AdminApi = { - - GetPolicy: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPolicy", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - UpdatePolicy: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdatePolicy", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AbortTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AbortTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - BanUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/BanUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddLocalizedNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddLocalizedNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserAccountInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserAccountInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddPlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddPlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeAllBansForUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeAllBansForUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + BanUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/BanUsers", request, "X-SecretKey", callback, customData, extraHeaders); }, - SendAccountRecoveryEmail: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SendAccountRecoveryEmail", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CheckLimitedEditionItemAvailability: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CheckLimitedEditionItemAvailability", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateActionsOnPlayersInSegmentTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateActionsOnPlayersInSegmentTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserTitleDisplayName: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserTitleDisplayName", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateCloudScriptTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateCloudScriptTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreatePlayerStatisticDefinition: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreatePlayerStatisticDefinition", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateInsightsScheduledScalingTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateInsightsScheduledScalingTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateIPBan", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetDataReport: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetDataReport", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticDefinitions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerStatisticDefinitions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreatePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreatePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerStatisticVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreatePlayerStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreatePlayerStatisticDefinition", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteContent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteContent", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMasterPlayerAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMasterPlayerAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMasterPlayerEventData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMasterPlayerEventData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMembershipSubscription: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMembershipSubscription", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - IncrementPlayerStatisticVersion: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/IncrementPlayerStatisticVersion", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayer", request, "X-SecretKey", callback, customData, extraHeaders); }, - RefundPurchase: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RefundPurchase", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetUserStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetUserStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResolvePurchaseDispute: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResolvePurchaseDispute", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdatePlayerStatisticDefinition: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdatePlayerStatisticDefinition", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteStore: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteStore", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTitle", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTitleDataOverride: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTitleDataOverride", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportMasterPlayerData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ExportMasterPlayerData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportPlayersInSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ExportPlayersInSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetActionsOnPlayersInSegmentTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetActionsOnPlayersInSegmentTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddNews: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddNews", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetAllSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteStore: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteStore", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptRevision: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptRevision", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetContentList", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentUploadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetContentUploadUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetDataReport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetDataReport", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetIPBansForIP: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetIPBansForIP", request, "X-SecretKey", callback, customData, extraHeaders); }, - ListVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ListVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetIPBansForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetIPBansForTitle", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemoveVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayedTitleList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayedTitleList", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerCustomProperty", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerIdFromAuthToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerIdFromAuthToken", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerProfile", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetupPushNotification: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetupPushNotification", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSharedSecrets: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerSharedSecrets", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerStatisticDefinitions", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerStatisticVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerTags", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GrantItemsToUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeInventoryItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeInventoryItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentExport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegmentExport", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SubtractUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentPlayerCount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegmentPlayerCount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetMatchmakerGameInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetMatchmakerGameInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetMatchmakerGameModes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetMatchmakerGameModes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyMatchmakerGameModes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ModifyMatchmakerGameModes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTaskInstances: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTaskInstances", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTasks: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTasks", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetServerBuildInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetServerBuildInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserAccountInfo", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetServerBuildUploadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetServerBuildUploadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserData", request, "X-SecretKey", callback, customData, extraHeaders); }, - ListServerBuilds: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ListServerBuilds", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserInventory", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ModifyServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemoveServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GrantItemsToUsers", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + IncrementLimitedEditionItemAvailability: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/IncrementLimitedEditionItemAvailability", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptRevision: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + IncrementPlayerStatisticVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/IncrementPlayerStatisticVersion", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptRevision", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ListOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListPlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ListVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublishedRevision: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RefundPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RefundPurchase", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetPublishedRevision", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemovePlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RemovePlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCloudScript: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemoveVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RemoveVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateCloudScript", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ResetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteContent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ResetPassword: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetPassword", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteContent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ResetUserStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetUserStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentList: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ResolvePurchaseDispute: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResolvePurchaseDispute", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetContentList", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeAllBansForUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeAllBansForUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentUploadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetContentUploadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeInventoryItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeInventoryItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeInventoryItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeIPBan", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddPlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RunTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RunTask", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddPlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SendAccountRecoveryEmail", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllActionGroups: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetAllActionGroups", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetMembershipOverride: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetMembershipOverride", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPlayerSecret", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetAllSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetPublishedRevision: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPublishedRevision", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayersInSegment: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayersInSegment", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetTitleDataAndOverrides: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleDataAndOverrides", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetupPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetupPushNotification", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemovePlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SubtractUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemovePlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateBans", request, "X-SecretKey", callback, customData, extraHeaders); }, - AbortTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AbortTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateCloudScript", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateActionsOnPlayersInSegmentTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateIPBan", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreateActionsOnPlayersInSegmentTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateCloudScriptTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreateCloudScriptTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerStatisticDefinition", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetActionsOnPlayersInSegmentTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetActionsOnPlayersInSegmentTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTaskInstances: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTaskInstances", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTasks: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTasks", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RunTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RunTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserTitleDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserTitleDisplayName", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ValidateApiPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ValidateApiPolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, + }; var PlayFabAdminSDK = PlayFab.AdminApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabAuthenticationApi.js b/PlayFabSdk/src/PlayFab/PlayFabAuthenticationApi.js new file mode 100644 index 00000000..8ac1c155 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabAuthenticationApi.js @@ -0,0 +1,278 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.AuthenticationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AuthenticateGameServerWithCustomId: function (request, callback, customData, extraHeaders) { + var overloadCallback = function (result, error) { + if (result != null && result.data.EntityToken != null && result.data.EntityToken.EntityToken != null) + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/GameServerIdentity/AuthenticateGameServerWithCustomId", request, "X-EntityToken", overloadCallback, customData, extraHeaders); + }, + + Delete: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/GameServerIdentity/Delete", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityToken: function (request, callback, customData, extraHeaders) { + var authKey = null; var authValue = null; + if (!authKey && PlayFab._internalSettings.sessionTicket) { var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey="X-Authorization"); authKey = authInfo.authKey, authValue = authInfo.authValue; } + if (!authKey && PlayFab.settings.developerSecretKey) { var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey="X-SecretKey"); authKey = authInfo.authKey, authValue = authInfo.authValue; } + var overloadCallback = function (result, error) { + if (result != null && result.data.EntityToken != null) + PlayFab._internalSettings.entityToken = result.data.EntityToken; + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/Authentication/GetEntityToken", request, authKey, overloadCallback, customData, extraHeaders); + }, + + ValidateEntityToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Authentication/ValidateEntityToken", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabAuthenticationSDK = PlayFab.AuthenticationApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabClientApi.js b/PlayFabSdk/src/PlayFab/PlayFabClientApi.js index f36d32f8..f66af485 100644 --- a/PlayFabSdk/src/PlayFab/PlayFabClientApi.js +++ b/PlayFabSdk/src/PlayFab/PlayFabClientApi.js @@ -6,996 +6,1375 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, - xhr.onerror = function () { - if (callback == null) - return; + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - xhr.send(requestBody); + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.ClientApi = { IsClientLoggedIn: function () { return PlayFab._internalSettings.sessionTicket != null && PlayFab._internalSettings.sessionTicket.length > 0; }, - - GetPhotonAuthenticationToken: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPhotonAuthenticationToken", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - GetWindowsHelloChallenge: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetWindowsHelloChallenge", request, null, null, callback); + AcceptTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AcceptTrade", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkWindowsHello: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkWindowsHello", request, null, null, callback); + AddFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddFriend", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithAndroidDeviceID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithAndroidDeviceID", request, null, null, overloadCallback); + AddGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddGenericID", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithCustomID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithCustomID", request, null, null, overloadCallback); + AddOrUpdateContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddOrUpdateContactEmail", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithEmailAddress: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithEmailAddress", request, null, null, overloadCallback); + AddSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddSharedGroupMembers", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithFacebook: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithFacebook", request, null, null, overloadCallback); + AddUsernamePassword: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddUsernamePassword", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithGameCenter: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithGameCenter", request, null, null, overloadCallback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddUserVirtualCurrency", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithGoogleAccount: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithGoogleAccount", request, null, null, overloadCallback); + AndroidDevicePushNotificationRegistration: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AndroidDevicePushNotificationRegistration", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithIOSDeviceID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithIOSDeviceID", request, null, null, overloadCallback); + AttributeInstall: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AttributeInstall", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithKongregate: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithKongregate", request, null, null, overloadCallback); + CancelTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/CancelTrade", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithPlayFab: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithPlayFab", request, null, null, overloadCallback); + ConfirmPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConfirmPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithSteam: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithSteam", request, null, null, overloadCallback); + ConsumeItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeItem", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithTwitch: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithTwitch", request, null, null, overloadCallback); + ConsumeMicrosoftStoreEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeMicrosoftStoreEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithWindowsHello: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithWindowsHello", request, null, null, overloadCallback); + ConsumePS5Entitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumePS5Entitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterPlayFabUser: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterPlayFabUser", request, null, null, overloadCallback); + ConsumePSNEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumePSNEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterWithWindowsHello: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterWithWindowsHello", request, null, null, overloadCallback); + ConsumeXboxEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeXboxEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkWindowsHello: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkWindowsHello", request, null, null, callback); + CreateSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/CreateSharedGroup", request, "X-Authorization", callback, customData, extraHeaders); }, - AddGenericID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddGenericID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/DeletePlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); }, - AddUsernamePassword: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddUsernamePassword", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ExecuteCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ExecuteCloudScript", request, "X-Authorization", callback, customData, extraHeaders); }, - GetAccountInfo: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetAccountInfo", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAccountInfo", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerCombinedInfo: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerCombinedInfo", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAdPlacements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAdPlacements", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromFacebookIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromFacebookIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAllUsersCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAllUsersCharacters", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGameCenterIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGameCenterIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCatalogItems", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGenericIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGenericIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGoogleIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGoogleIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterInventory", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromKongregateIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromKongregateIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromSteamIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromSteamIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromTwitchIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromTwitchIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkAndroidDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkAndroidDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetContentDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetContentDownloadUrl", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkCustomID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkCustomID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkFacebookAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkFacebookAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendLeaderboardAroundPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendLeaderboardAroundPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkGameCenterAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkGameCenterAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendsList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendsList", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkGoogleAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkGoogleAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkIOSDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkIOSDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardAroundCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardAroundCharacter", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkKongregate: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkKongregate", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardAroundPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardAroundPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkSteamAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkSteamAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardForUserCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardForUserCharacters", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkTwitch: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkTwitch", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPaymentToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPaymentToken", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveGenericID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveGenericID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPhotonAuthenticationToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPhotonAuthenticationToken", request, "X-Authorization", callback, customData, extraHeaders); }, - ReportPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ReportPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerCombinedInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerCombinedInfo", request, "X-Authorization", callback, customData, extraHeaders); }, - SendAccountRecoveryEmail: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SendAccountRecoveryEmail", request, null, null, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerCustomProperty", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkAndroidDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkAndroidDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerProfile", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkCustomID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkCustomID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerSegments", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkFacebookAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkFacebookAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkGameCenterAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkGameCenterAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerStatisticVersions", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkGoogleAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkGoogleAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerTags", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkIOSDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkIOSDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerTrades: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerTrades", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkKongregate: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkKongregate", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromBattleNetAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromBattleNetAccountIds", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkSteamAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkSteamAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromFacebookIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromFacebookIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkTwitch: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkTwitch", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromFacebookInstantGamesIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromFacebookInstantGamesIds", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateAvatarUrl: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateAvatarUrl", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGameCenterIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGameCenterIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserTitleDisplayName: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserTitleDisplayName", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGenericIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGenericIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGoogleIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGoogleIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendLeaderboardAroundPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendLeaderboardAroundPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGooglePlayGamesPlayerIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGooglePlayGamesPlayerIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromKongregateIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromKongregateIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardAroundPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardAroundPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromNintendoServiceAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromNintendoServiceAccountIds", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromNintendoSwitchDeviceIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromNintendoSwitchDeviceIds", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerStatisticVersions", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromOpenIdSubjectIdentifiers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromOpenIdSubjectIdentifiers", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromPSNAccountIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromPSNAccountIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromPSNOnlineIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromPSNOnlineIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserPublisherReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromSteamIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromSteamIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromSteamNames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromSteamNames", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdatePlayerStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdatePlayerStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromTwitchIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromTwitchIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromXboxLiveIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPublisherData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCatalogItems", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetSharedGroupData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetStoreItems: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetStoreItems", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetStoreItems", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTime: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTime", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTime: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTime", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTitleData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitleData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTitleNews: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTitleNews", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitleNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitleNews", request, "X-Authorization", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddUserVirtualCurrency", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitlePublicKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitlePublicKey", request, null, callback, customData, extraHeaders); }, - ConfirmPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ConfirmPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTradeStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTradeStatus", request, "X-Authorization", callback, customData, extraHeaders); }, - ConsumeItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ConsumeItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterInventory: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterInventory", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserInventory", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserPublisherData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserInventory", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserPublisherReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - PayForPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/PayForPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - PurchaseItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/PurchaseItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GrantCharacterToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GrantCharacterToUser", request, "X-Authorization", callback, customData, extraHeaders); }, - RedeemCoupon: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RedeemCoupon", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkAndroidDeviceID", request, "X-Authorization", callback, customData, extraHeaders); }, - StartPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkApple", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/StartPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkBattleNetAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkCustomID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SubtractUserVirtualCurrency", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkFacebookAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlockContainerInstance: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkFacebookInstantGamesId", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlockContainerInstance", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGameCenterAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlockContainerItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkGoogleAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGoogleAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlockContainerItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkGooglePlayGamesServicesAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGooglePlayGamesServicesAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - AddFriend: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkIOSDeviceID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddFriend", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkKongregate", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendsList: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkNintendoServiceAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendsList", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkNintendoSwitchDeviceId", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveFriend: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkOpenIdConnect: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkOpenIdConnect", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveFriend", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkPSNAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - SetFriendTags: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkSteamAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkSteamAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SetFriendTags", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkTwitch", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterForIOSPushNotification: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkXboxAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterForIOSPushNotification", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ListPlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); }, - RestoreIOSPurchases: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithAndroidDeviceID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithAndroidDeviceID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RestoreIOSPurchases", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithApple: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithApple", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - ValidateIOSReceipt: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithBattleNet: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithBattleNet", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateIOSReceipt", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithCustomID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithCustomID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - GetCurrentGames: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithEmailAddress: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithEmailAddress", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCurrentGames", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithFacebook: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithFacebook", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - GetGameServerRegions: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithFacebookInstantGamesId", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetGameServerRegions", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithGameCenter: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGameCenter", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - Matchmake: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithGoogleAccount: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGoogleAccount", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/Matchmake", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithGooglePlayGamesServices: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGooglePlayGamesServices", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - StartGame: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithIOSDeviceID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithIOSDeviceID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/StartGame", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithKongregate: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithKongregate", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - AndroidDevicePushNotificationRegistration: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithNintendoServiceAccount", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AndroidDevicePushNotificationRegistration", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithNintendoSwitchDeviceId", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - ValidateGooglePlayPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithOpenIdConnect: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithOpenIdConnect", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateGooglePlayPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithPlayFab: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithPlayFab", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WriteCharacterEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithPSN: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithPSN", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WriteCharacterEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithSteam: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithSteam", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WritePlayerEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithTwitch: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithTwitch", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WritePlayerEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithXbox: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithXbox", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WriteTitleEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + OpenTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/OpenTrade", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WriteTitleEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + PayForPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/PayForPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - AddSharedGroupMembers: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + PurchaseItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/PurchaseItem", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddSharedGroupMembers", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RedeemCoupon: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RedeemCoupon", request, "X-Authorization", callback, customData, extraHeaders); }, - CreateSharedGroup: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RefreshPSNAuthToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RefreshPSNAuthToken", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/CreateSharedGroup", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RegisterForIOSPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RegisterForIOSPushNotification", request, "X-Authorization", callback, customData, extraHeaders); }, - GetSharedGroupData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RegisterPlayFabUser: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RegisterPlayFabUser", request, null, overloadCallback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetSharedGroupData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RemoveContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveContactEmail", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveSharedGroupMembers: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RemoveFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveFriend", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveSharedGroupMembers", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RemoveGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveGenericID", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateSharedGroupData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RemoveSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveSharedGroupMembers", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateSharedGroupData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ReportAdActivity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportAdActivity", request, "X-Authorization", callback, customData, extraHeaders); }, - ExecuteCloudScript: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ReportDeviceInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportDeviceInfo", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ExecuteCloudScript", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ReportPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - GetContentDownloadUrl: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RestoreIOSPurchases: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RestoreIOSPurchases", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetContentDownloadUrl", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RewardAdActivity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RewardAdActivity", request, "X-Authorization", callback, customData, extraHeaders); }, - GetAllUsersCharacters: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SendAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SendAccountRecoveryEmail", request, null, callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetAllUsersCharacters", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + SetFriendTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SetFriendTags", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SetPlayerSecret", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + StartPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/StartPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SubtractUserVirtualCurrency", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkAndroidDeviceID", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardAroundCharacter: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkApple", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardAroundCharacter", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkBattleNetAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardForUserCharacters: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkCustomID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardForUserCharacters", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkFacebookAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GrantCharacterToUser: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkFacebookInstantGamesId", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GrantCharacterToUser", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGameCenterAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateCharacterStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkGoogleAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGoogleAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateCharacterStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkGooglePlayGamesServicesAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGooglePlayGamesServicesAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkIOSDeviceID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkKongregate", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkNintendoServiceAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkNintendoSwitchDeviceId", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateCharacterData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkOpenIdConnect: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkOpenIdConnect", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateCharacterData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkPSNAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - ValidateAmazonIAPReceipt: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkSteamAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkSteamAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateAmazonIAPReceipt", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkTwitch", request, "X-Authorization", callback, customData, extraHeaders); }, - AcceptTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkXboxAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AcceptTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlockContainerInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlockContainerInstance", request, "X-Authorization", callback, customData, extraHeaders); }, - CancelTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlockContainerItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlockContainerItem", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/CancelTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateAvatarUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateAvatarUrl", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerTrades: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateCharacterData", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerTrades", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateCharacterStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTradeStatus: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdatePlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTradeStatus", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdatePlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdatePlayerStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - OpenTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateSharedGroupData", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/OpenTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserData", request, "X-Authorization", callback, customData, extraHeaders); }, - AttributeInstall: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserPublisherData", request, "X-Authorization", callback, customData, extraHeaders); + }, - var overloadCallback = function (result, error) { - // Modify advertisingIdType: Prevents us from sending the id multiple times, and allows automated tests to determine id was sent successfully - PlayFab.settings.advertisingIdType += "_Successful"; + UpdateUserTitleDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserTitleDisplayName", request, "X-Authorization", callback, customData, extraHeaders); + }, - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AttributeInstall", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, overloadCallback); + ValidateAmazonIAPReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateAmazonIAPReceipt", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ValidateGooglePlayPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateGooglePlayPurchase", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerSegments", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ValidateIOSReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateIOSReceipt", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ValidateWindowsStoreReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateWindowsStoreReceipt", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerTags", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + WriteCharacterEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WriteCharacterEvent", request, "X-Authorization", callback, customData, extraHeaders); }, - ValidateWindowsStoreReceipt: function (request, callback) { + WritePlayerEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WritePlayerEvent", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateWindowsStoreReceipt", request, null, null, callback); + WriteTitleEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WriteTitleEvent", request, "X-Authorization", callback, customData, extraHeaders); }, - _MultiStepClientLogin: function (needsAttribution) { - if (needsAttribution && !PlayFab.settings.disableAdvertising && PlayFab.settings.advertisingIdType !== null && PlayFab.settings.advertisingIdValue !== null) { - var request = {}; - if (PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_IDFA) - request.Idfa = PlayFab.settings.advertisingIdValue; - else if (PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_ANDROID_ID) - request.Adid = PlayFab.settings.advertisingIdValue; - else - return; - PlayFab.ClientApi.AttributeInstall(request, null); - } - } }; var PlayFabClientSDK = PlayFab.ClientApi; + +PlayFab.RegisterWithPhaser = function() { + if ( typeof Phaser === "undefined" || typeof Phaser.Plugin === "undefined" ) + return; + + Phaser.Plugin.PlayFab = function (game, parent) { + Phaser.Plugin.call(this, game, parent); + }; + Phaser.Plugin.PlayFab.prototype = Object.create(Phaser.Plugin.prototype); + Phaser.Plugin.PlayFab.prototype.constructor = Phaser.Plugin.PlayFab; + Phaser.Plugin.PlayFab.prototype.PlayFab = PlayFab; + Phaser.Plugin.PlayFab.prototype.settings = PlayFab.settings; + Phaser.Plugin.PlayFab.prototype.ClientApi = PlayFab.ClientApi; +}; +PlayFab.RegisterWithPhaser(); + diff --git a/PlayFabSdk/src/PlayFab/PlayFabCloudScriptApi.js b/PlayFabSdk/src/PlayFab/PlayFabCloudScriptApi.js new file mode 100644 index 00000000..17c11b0f --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabCloudScriptApi.js @@ -0,0 +1,307 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.CloudScriptApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + ExecuteEntityCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ExecuteEntityCloudScript", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ExecuteFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/GetFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListEventHubFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListEventHubFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListHttpFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListHttpFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListQueuedFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListQueuedFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForEntityTriggeredAction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForEntityTriggeredAction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForFunctionExecution: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForFunctionExecution", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForPlayerTriggeredAction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForPlayerTriggeredAction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForScheduledTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForScheduledTask", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterEventHubFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterEventHubFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterHttpFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterHttpFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterQueuedFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterQueuedFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnregisterFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/UnregisterFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabCloudScriptSDK = PlayFab.CloudScriptApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabDataApi.js b/PlayFabSdk/src/PlayFab/PlayFabDataApi.js new file mode 100644 index 00000000..49e60dfc --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabDataApi.js @@ -0,0 +1,275 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.DataApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AbortFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/AbortFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/DeleteFiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FinalizeFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/FinalizeFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/GetFiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetObjects: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Object/GetObjects", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InitiateFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/InitiateFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetObjects: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Object/SetObjects", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabDataSDK = PlayFab.DataApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabEconomyApi.js b/PlayFabSdk/src/PlayFab/PlayFabEconomyApi.js new file mode 100644 index 00000000..013d5ea7 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabEconomyApi.js @@ -0,0 +1,431 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.EconomyApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AddInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/AddInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/CreateDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateUploadUrls: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/CreateUploadUrls", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteEntityItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/DeleteEntityItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteInventoryCollection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/DeleteInventoryCollection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/DeleteInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/DeleteItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteInventoryOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/ExecuteInventoryOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteTransferOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/ExecuteTransferOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetCatalogConfig: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetCatalogConfig", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDraftItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetDraftItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityDraftItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetEntityDraftItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityItemReview: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetEntityItemReview", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryCollectionIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryCollectionIds", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryOperationStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryOperationStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemContainers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemContainers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemModerationState: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemModerationState", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemPublishStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemPublishStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemReviewSummary: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemReviewSummary", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTransactionHistory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetTransactionHistory", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PublishDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/PublishDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PurchaseInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/PurchaseInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemAppleAppStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemAppleAppStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemAppleAppStoreWithJwsInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemAppleAppStoreWithJwsInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemGooglePlayInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemGooglePlayInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemMicrosoftStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemMicrosoftStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemNintendoEShopInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemNintendoEShopInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemPlayStationStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemPlayStationStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemSteamInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemSteamInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReportItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReportItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReportItemReview: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReportItemReview", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReviewItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReviewItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SearchItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SearchItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetItemModerationState: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SetItemModerationState", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubmitItemReviewVote: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SubmitItemReviewVote", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubtractInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/SubtractInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + TakedownItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/TakedownItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + TransferInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/TransferInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateCatalogConfig: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/UpdateCatalogConfig", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/UpdateDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/UpdateInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabEconomySDK = PlayFab.EconomyApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabEventsApi.js b/PlayFabSdk/src/PlayFab/PlayFabEventsApi.js new file mode 100644 index 00000000..c8ed22b3 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabEventsApi.js @@ -0,0 +1,295 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.EventsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/CreateTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/DeleteDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/DeleteTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/GetDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/GetTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListDataConnections: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/ListDataConnections", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListTelemetryKeys: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/ListTelemetryKeys", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDataConnectionActive: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetDataConnectionActive", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetTelemetryKeyActive: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetTelemetryKeyActive", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + WriteEvents: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/WriteEvents", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + WriteTelemetryEvents: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/WriteTelemetryEvents", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabEventsSDK = PlayFab.EventsApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabExperimentationApi.js b/PlayFabSdk/src/PlayFab/PlayFabExperimentationApi.js new file mode 100644 index 00000000..06fe7806 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabExperimentationApi.js @@ -0,0 +1,299 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ExperimentationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/CreateExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/CreateExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/DeleteExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/DeleteExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExclusionGroups: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExclusionGroups", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExclusionGroupTraffic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExclusionGroupTraffic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExperiments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExperiments", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLatestScorecard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetLatestScorecard", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTreatmentAssignment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetTreatmentAssignment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + StartExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/StartExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + StopExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/StopExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/UpdateExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/UpdateExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabExperimentationSDK = PlayFab.ExperimentationApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabGroupsApi.js b/PlayFabSdk/src/PlayFab/PlayFabGroupsApi.js new file mode 100644 index 00000000..5ff17e41 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabGroupsApi.js @@ -0,0 +1,347 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.GroupsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AcceptGroupApplication: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AcceptGroupApplication", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + AcceptGroupInvitation: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AcceptGroupInvitation", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + AddMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AddMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ApplyToGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ApplyToGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + BlockEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/BlockEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ChangeMemberRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ChangeMemberRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/CreateGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/CreateRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/DeleteGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/DeleteRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/GetGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InviteToGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/InviteToGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IsMember: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/IsMember", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupApplications: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupApplications", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupBlocks: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupBlocks", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupInvitations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupInvitations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMembership: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListMembership", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMembershipOpportunities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListMembershipOpportunities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveGroupApplication: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveGroupApplication", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveGroupInvitation: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveGroupInvitation", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnblockEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UnblockEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UpdateGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UpdateRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabGroupsSDK = PlayFab.GroupsApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabInsightsApi.js b/PlayFabSdk/src/PlayFab/PlayFabInsightsApi.js new file mode 100644 index 00000000..4751a9f5 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabInsightsApi.js @@ -0,0 +1,271 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.InsightsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetDetails: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetDetails", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLimits: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetLimits", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetOperationStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetOperationStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetPendingOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetPendingOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetPerformance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/SetPerformance", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetStorageRetention: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/SetStorageRetention", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabInsightsSDK = PlayFab.InsightsApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabLocalizationApi.js b/PlayFabSdk/src/PlayFab/PlayFabLocalizationApi.js new file mode 100644 index 00000000..f2b8672f --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabLocalizationApi.js @@ -0,0 +1,251 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.LocalizationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetLanguageList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Locale/GetLanguageList", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabLocalizationSDK = PlayFab.LocalizationApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabMatchmakerApi.js b/PlayFabSdk/src/PlayFab/PlayFabMatchmakerApi.js deleted file mode 100644 index dd1e6a0e..00000000 --- a/PlayFabSdk/src/PlayFab/PlayFabMatchmakerApi.js +++ /dev/null @@ -1,138 +0,0 @@ -/// - -var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; - -if(!PlayFab.settings) { - PlayFab.settings = { - titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) - developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" - } -} - -if(!PlayFab._internalSettings) { - PlayFab._internalSettings = { - sessionTicket: null, - productionServerUrl: ".playfabapi.com", - - GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; - }, - - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; - - if (data == null) - data = {}; - - var startTime = new Date(); - var requestBody = JSON.stringify(data); - - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); - - xhr.setRequestHeader('Content-Type', 'application/json'); - - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); - - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); - - xhr.onloadend = function () { - if (callback == null) - return; - - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } - - result.CallBackTimeMS = new Date() - startTime; - - if (result.code === 200) - callback(result, null); - else - callback(null, result); - } - - xhr.onerror = function () { - if (callback == null) - return; - - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } - - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } - - xhr.send(requestBody); - } - } -} - -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; - -PlayFab.MatchmakerApi = { - - AuthUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/AuthUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - PlayerJoined: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/PlayerJoined", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - PlayerLeft: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/PlayerLeft", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - StartGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/StartGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - UserInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/UserInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, -}; - -var PlayFabMatchmakerSDK = PlayFab.MatchmakerApi; diff --git a/PlayFabSdk/src/PlayFab/PlayFabMultiplayerApi.js b/PlayFabSdk/src/PlayFab/PlayFabMultiplayerApi.js new file mode 100644 index 00000000..d92785ef --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabMultiplayerApi.js @@ -0,0 +1,595 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.MultiplayerApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CancelAllMatchmakingTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelAllMatchmakingTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelAllServerBackfillTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelAllServerBackfillTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithCustomContainer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithCustomContainer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithManagedContainer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithManagedContainer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithProcessBasedServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithProcessBasedServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/CreateLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateRemoteUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateRemoteUser", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateServerMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateServerMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateTitleMultiplayerServersQuotaChange: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateTitleMultiplayerServersQuotaChange", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteAsset: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteAsset", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuild: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuild", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuildRegion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuildRegion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteCertificate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteCertificate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteContainerImageRepository: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteContainerImageRepository", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/DeleteLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteRemoteUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteRemoteUser", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteSecret", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + EnableMultiplayerServersForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/EnableMultiplayerServersForTitle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FindFriendLobbies: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/FindFriendLobbies", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FindLobbies: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/FindLobbies", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetAssetDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetAssetDownloadUrl", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetAssetUploadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetAssetUploadUrl", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetBuild: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetBuild", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetContainerRegistryCredentials: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetContainerRegistryCredentials", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/GetLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerServerDetails: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerServerDetails", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerServerLogs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerServerLogs", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerSessionLogsBySessionId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerSessionLogsBySessionId", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetQueueStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetQueueStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetRemoteLoginEndpoint: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetRemoteLoginEndpoint", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleEnabledForMultiplayerServersStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleEnabledForMultiplayerServersStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleMultiplayerServersQuotaChange: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleMultiplayerServersQuotaChange", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleMultiplayerServersQuotas: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleMultiplayerServersQuotas", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InviteToLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/InviteToLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinArrangedLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinArrangedLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/JoinMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + LeaveLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/LeaveLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + LeaveLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/LeaveLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListArchivedMultiplayerServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListArchivedMultiplayerServers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListAssetSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListAssetSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListBuildAliases: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListBuildAliases", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListBuildSummariesV2: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListBuildSummariesV2", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListCertificateSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListCertificateSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListContainerImages: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListContainerImages", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListContainerImageTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListContainerImageTags", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMatchmakingQueues: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListMatchmakingQueues", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMatchmakingTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListMatchmakingTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMultiplayerServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListMultiplayerServers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListPartyQosServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListPartyQosServers", request, null, callback, customData, extraHeaders); + }, + + ListQosServersForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListQosServersForTitle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListSecretSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListSecretSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListServerBackfillTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListServerBackfillTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListTitleMultiplayerServersQuotaChanges: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListTitleMultiplayerServersQuotaChanges", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListVirtualMachineSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListVirtualMachineSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/RemoveMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMember: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/RemoveMember", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RequestMultiplayerServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/RequestMultiplayerServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RequestPartyService: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Party/RequestPartyService", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RolloverContainerRegistryCredentials: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/RolloverContainerRegistryCredentials", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/SetMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ShutdownMultiplayerServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ShutdownMultiplayerServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubscribeToLobbyResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/SubscribeToLobbyResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubscribeToMatchmakingResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/SubscribeToMatchmakingResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnsubscribeFromLobbyResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UnsubscribeFromLobbyResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnsubscribeFromMatchmakingResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/UnsubscribeFromMatchmakingResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UntagContainerImage: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UntagContainerImage", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildName", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildRegion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildRegion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildRegions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildRegions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UpdateLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UpdateLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UploadCertificate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UploadCertificate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UploadSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UploadSecret", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabMultiplayerSDK = PlayFab.MultiplayerApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabProfilesApi.js b/PlayFabSdk/src/PlayFab/PlayFabProfilesApi.js new file mode 100644 index 00000000..5a1ec15d --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabProfilesApi.js @@ -0,0 +1,283 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ProfilesApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetGlobalPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetGlobalPolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetProfile", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetProfiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetProfiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitlePlayersFromMasterPlayerAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetTitlePlayersFromMasterPlayerAccountIds", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitlePlayersFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetTitlePlayersFromXboxLiveIDs", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetDisplayName", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetGlobalPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetGlobalPolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetProfileLanguage: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetProfileLanguage", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetProfilePolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetProfilePolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabProfilesSDK = PlayFab.ProfilesApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabProgressionApi.js b/PlayFabSdk/src/PlayFab/PlayFabProgressionApi.js new file mode 100644 index 00000000..479bc913 --- /dev/null +++ b/PlayFabSdk/src/PlayFab/PlayFabProgressionApi.js @@ -0,0 +1,343 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ProgressionApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/CreateLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/CreateStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/DeleteLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLeaderboardEntries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/DeleteLeaderboardEntries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/DeleteStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/DeleteStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFriendLeaderboardForEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetFriendLeaderboardForEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboard", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardAroundEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardAroundEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardForEntities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardForEntities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatisticsForEntities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatisticsForEntities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IncrementLeaderboardVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/IncrementLeaderboardVersion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IncrementStatisticVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/IncrementStatisticVersion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListLeaderboardDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/ListLeaderboardDefinitions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListStatisticDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/ListStatisticDefinitions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnlinkAggregationSourceFromStatistic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UnlinkAggregationSourceFromStatistic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnlinkLeaderboardFromStatistic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UnlinkLeaderboardFromStatistic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UpdateLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLeaderboardEntries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UpdateLeaderboardEntries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UpdateStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UpdateStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabProgressionSDK = PlayFab.ProgressionApi; + diff --git a/PlayFabSdk/src/PlayFab/PlayFabServerApi.js b/PlayFabSdk/src/PlayFab/PlayFabServerApi.js index 8b42722b..a0f01589 100644 --- a/PlayFabSdk/src/PlayFab/PlayFabServerApi.js +++ b/PlayFabSdk/src/PlayFab/PlayFabServerApi.js @@ -6,745 +6,890 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, - xhr.onerror = function () { - if (callback == null) - return; + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - xhr.send(requestBody); + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.ServerApi = { - - AuthenticateSessionTicket: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AuthenticateSessionTicket", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - BanUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/BanUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddCharacterVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddCharacterVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayFabIDsFromFacebookIDs: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayFabIDsFromFacebookIDs", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddFriend", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayFabIDsFromSteamIDs: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayFabIDsFromSteamIDs", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddGenericID", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserAccountInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserAccountInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddOrUpdateContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddOrUpdateContactEmail", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddPlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddPlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeAllBansForUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeAllBansForUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddSharedGroupMembers", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - SendPushNotification: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SendPushNotification", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AuthenticateSessionTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AuthenticateSessionTicket", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateAvatarUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateAvatarUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AwardSteamAchievement: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AwardSteamAchievement", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + BanUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/BanUsers", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ConsumeItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ConsumeItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetFriendLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetFriendLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/CreateSharedGroup", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteCharacterFromUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeleteCharacterFromUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardAroundUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardAroundUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePlayer", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerCombinedInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerCombinedInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePushNotificationTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePushNotificationTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerStatisticVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeleteSharedGroup", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + EvaluateRandomResultTable: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/EvaluateRandomResultTable", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExecuteCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ExecuteCloudScript", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportPlayersInSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ExportPlayersInSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetAllSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllUsersCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetAllUsersCharacters", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdatePlayerStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdatePlayerStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterInventory", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetContentDownloadUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetFriendLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetFriendLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetFriendsList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetFriendsList", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTime: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTime", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardAroundCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardAroundCharacter", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardAroundUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardAroundUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleNews: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleNews", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardForUserCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardForUserCharacters", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCombinedInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerCombinedInfo", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerCustomProperty", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerProfile", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddCharacterVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddCharacterVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - ConsumeItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ConsumeItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerStatisticVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - EvaluateRandomResultTable: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/EvaluateRandomResultTable", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerTags", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromBattleNetAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromBattleNetAccountIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromFacebookIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromFacebookIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromFacebookInstantGamesIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromFacebookInstantGamesIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromGenericIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromGenericIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromNintendoServiceAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromNintendoServiceAccountIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromNintendoSwitchDeviceIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromNintendoSwitchDeviceIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyItemUses: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ModifyItemUses", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromOpenIdSubjectIdentifiers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromOpenIdSubjectIdentifiers", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToCharacterFromCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromPSNAccountIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromPSNAccountIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToCharacterFromCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromPSNOnlineIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromPSNOnlineIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToCharacterFromUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromServerCustomIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromServerCustomIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToCharacterFromUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromSteamIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromSteamIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToUserFromCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromSteamNames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromSteamNames", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToUserFromCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromTwitchIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromTwitchIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - RedeemCoupon: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromXboxLiveIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RedeemCoupon", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - ReportPlayer: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ReportPlayer", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentExport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSegmentExport", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeInventoryItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetSegmentPlayerCount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSegmentPlayerCount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeInventoryItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetServerCustomIDsFromPlayFabIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetServerCustomIDsFromPlayFabIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractCharacterVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSharedGroupData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SubtractCharacterVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTime: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTime", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SubtractUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UnlockContainerInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UnlockContainerInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - UnlockContainerItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserAccountInfo", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UnlockContainerItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserBans", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInventoryItemCustomData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserInventoryItemCustomData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddFriend: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserInventory", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddFriend", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetFriendsList: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetFriendsList", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveFriend: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemoveFriend", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GrantCharacterToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantCharacterToUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetFriendTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetFriendTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GrantItemsToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeregisterGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToUsers", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeregisterGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkBattleNetAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - NotifyMatchmakerPlayerLeft: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoServiceAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/NotifyMatchmakerPlayerLeft", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkNintendoServiceAccountSubject: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoServiceAccountSubject", request, "X-SecretKey", callback, customData, extraHeaders); }, - RedeemMatchmakerTicket: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoSwitchDeviceId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RedeemMatchmakerTicket", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkPSNAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - RefreshGameServerInstanceHeartbeat: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkPSNId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkPSNId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RefreshGameServerInstanceHeartbeat", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); }, - RegisterGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkSteamId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RegisterGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkTwitchAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkTwitchAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkXboxAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkXboxId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkXboxId", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceState: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ListPlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceState", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithAndroidDeviceID", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithBattleNet: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithBattleNet", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithCustomID", request, "X-SecretKey", callback, customData, extraHeaders); }, - AwardSteamAchievement: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithIOSDeviceID", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AwardSteamAchievement", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithPSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithPSN", request, "X-SecretKey", callback, customData, extraHeaders); }, - WriteCharacterEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WriteCharacterEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithSteamId", request, "X-SecretKey", callback, customData, extraHeaders); }, - WritePlayerEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithTwitch", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WritePlayerEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithXbox: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithXbox", request, "X-SecretKey", callback, customData, extraHeaders); }, - WriteTitleEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithXboxId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithXboxId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WriteTitleEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ModifyItemUses: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ModifyItemUses", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddSharedGroupMembers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + MoveItemToCharacterFromCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToCharacterFromCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddSharedGroupMembers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + MoveItemToCharacterFromUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToCharacterFromUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateSharedGroup: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + MoveItemToUserFromCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToUserFromCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/CreateSharedGroup", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RedeemCoupon: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RedeemCoupon", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteSharedGroup: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemoveFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveFriend", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteSharedGroup", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemoveGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveGenericID", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetSharedGroupData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemovePlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemovePlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetSharedGroupData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemoveSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveSharedGroupMembers", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveSharedGroupMembers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ReportPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ReportPlayer", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemoveSharedGroupMembers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeAllBansForUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeAllBansForUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateSharedGroupData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateSharedGroupData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeInventoryItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeInventoryItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - ExecuteCloudScript: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeInventoryItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ExecuteCloudScript", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SavePushNotificationTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SavePushNotificationTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentDownloadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SendCustomAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendCustomAccountRecoveryEmail", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetContentDownloadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendEmailFromTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendEmailFromTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteCharacterFromUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SendPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendPushNotification", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteCharacterFromUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendPushNotificationFromTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendPushNotificationFromTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllUsersCharacters: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetFriendTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetFriendTags", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllUsersCharacters", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetPlayerSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SubtractCharacterVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SubtractCharacterVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardAroundCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SubtractUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardAroundCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkApple", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardForUserCharacters: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkBattleNetAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardForUserCharacters", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkFacebookAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantCharacterToUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkFacebookInstantGamesId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantCharacterToUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkGameCenterAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkNintendoServiceAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkNintendoSwitchDeviceId", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkPSNAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkSteamId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkTwitchAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkTwitchAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkXboxAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlockContainerInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlockContainerInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlockContainerItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlockContainerItem", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateAvatarUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateAvatarUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCharacterInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddPlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddPlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdatePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllActionGroups: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdatePlayerStatistics", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllActionGroups", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateSharedGroupData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserInventoryItemCustomData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserInventoryItemCustomData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayersInSegment: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayersInSegment", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + WriteCharacterEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WriteCharacterEvent", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemovePlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + WritePlayerEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WritePlayerEvent", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemovePlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + WriteTitleEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WriteTitleEvent", request, "X-SecretKey", callback, customData, extraHeaders); }, + }; var PlayFabServerSDK = PlayFab.ServerApi; + diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabAddonApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabAddonApi.d.ts new file mode 100644 index 00000000..6ec1a36a --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabAddonApi.d.ts @@ -0,0 +1,758 @@ +/// + +declare module PlayFabAddonModule { + export interface IPlayFabAddon { + ForgetAllCredentials(): void; + + /** + * Configures PSN event streams for an existing PSN addon on a title, without requiring a full addon upsert. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/configurepsneventstreams + */ + ConfigurePSNEventStreams(request: PlayFabAddonModels.ConfigurePSNEventStreamsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Apple addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdateapple + */ + CreateOrUpdateApple(request: PlayFabAddonModels.CreateOrUpdateAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Facebook addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatefacebook + */ + CreateOrUpdateFacebook(request: PlayFabAddonModels.CreateOrUpdateFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Facebook Instant Games addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatefacebookinstantgames + */ + CreateOrUpdateFacebookInstantGames(request: PlayFabAddonModels.CreateOrUpdateFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Google addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdategoogle + */ + CreateOrUpdateGoogle(request: PlayFabAddonModels.CreateOrUpdateGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Kongregate addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatekongregate + */ + CreateOrUpdateKongregate(request: PlayFabAddonModels.CreateOrUpdateKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Nintendo addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatenintendo + */ + CreateOrUpdateNintendo(request: PlayFabAddonModels.CreateOrUpdateNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the PSN addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatepsn + */ + CreateOrUpdatePSN(request: PlayFabAddonModels.CreateOrUpdatePSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Steam addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatesteam + */ + CreateOrUpdateSteam(request: PlayFabAddonModels.CreateOrUpdateSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the ToxMod addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatetoxmod + */ + CreateOrUpdateToxMod(request: PlayFabAddonModels.CreateOrUpdateToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Twitch addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatetwitch + */ + CreateOrUpdateTwitch(request: PlayFabAddonModels.CreateOrUpdateTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Apple addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deleteapple + */ + DeleteApple(request: PlayFabAddonModels.DeleteAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Facebook addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletefacebook + */ + DeleteFacebook(request: PlayFabAddonModels.DeleteFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Facebook addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletefacebookinstantgames + */ + DeleteFacebookInstantGames(request: PlayFabAddonModels.DeleteFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Google addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletegoogle + */ + DeleteGoogle(request: PlayFabAddonModels.DeleteGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Kongregate addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletekongregate + */ + DeleteKongregate(request: PlayFabAddonModels.DeleteKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Nintendo addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletenintendo + */ + DeleteNintendo(request: PlayFabAddonModels.DeleteNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the PSN addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletepsn + */ + DeletePSN(request: PlayFabAddonModels.DeletePSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Steam addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletesteam + */ + DeleteSteam(request: PlayFabAddonModels.DeleteSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the ToxMod addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletetoxmod + */ + DeleteToxMod(request: PlayFabAddonModels.DeleteToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Twitch addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletetwitch + */ + DeleteTwitch(request: PlayFabAddonModels.DeleteTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Apple addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getapple + */ + GetApple(request: PlayFabAddonModels.GetAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Facebook addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getfacebook + */ + GetFacebook(request: PlayFabAddonModels.GetFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Facebook Instant Games addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getfacebookinstantgames + */ + GetFacebookInstantGames(request: PlayFabAddonModels.GetFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Google addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getgoogle + */ + GetGoogle(request: PlayFabAddonModels.GetGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Kongregate addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getkongregate + */ + GetKongregate(request: PlayFabAddonModels.GetKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Nintendo addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getnintendo + */ + GetNintendo(request: PlayFabAddonModels.GetNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the PSN addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getpsn + */ + GetPSN(request: PlayFabAddonModels.GetPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Steam addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getsteam + */ + GetSteam(request: PlayFabAddonModels.GetSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the ToxMod addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/gettoxmod + */ + GetToxMod(request: PlayFabAddonModels.GetToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Twitch addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/gettwitch + */ + GetTwitch(request: PlayFabAddonModels.GetTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabAddonModels { + export interface ConfigurePSNEventStreamsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Title name obtained after setting a back server for PS5. Used for clawback event listeners. */ + TitleName?: string; + + } + + export interface ConfigurePSNEventStreamsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Allow validation of receipts from the Apple production environment. Required for app releases. */ + AllowProduction?: boolean; + /** Allow validation of receipts from the Apple sandbox environment. Typically used while testing. */ + AllowSandbox?: boolean; + /** iOS App Bundle ID obtained after setting up your app in the App Store. */ + AppBundleId: string; + /** AppId obtained after setting up your app in the App Store. */ + AppId?: string; + /** iOS App Shared Secret obtained after setting up your app in the App Store. */ + AppSharedSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Ignore expiration date for identity tokens. Be aware that when set to true this can invalidate expired tokens in the + * case where Apple rotates their signing keys. + */ + IgnoreExpirationDate?: boolean; + /** IssuerId obtained after setting up your app in the App Store. */ + IssuerId?: string; + /** KeyId obtained after setting up your app in the App Store. */ + KeyId?: string; + /** PrivateKey obtained after setting up your app in the App Store. */ + PrivateKey?: string; + /** Require secure authentication only for this app. */ + RequireSecureAuthentication?: boolean; + + } + + export interface CreateOrUpdateAppleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Facebook App ID obtained after setting up your app in Facebook Instant Games. */ + AppID: string; + /** Facebook App Secret obtained after setting up your app in Facebook Instant Games. */ + AppSecret: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Facebook App ID obtained after setting up your app in Facebook. */ + AppID: string; + /** Facebook App Secret obtained after setting up your app in Facebook. */ + AppSecret: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Email address for purchase dispute notifications. */ + NotificationEmail: string; + + } + + export interface CreateOrUpdateFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Google App License Key obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppLicenseKey?: string; + /** + * Google App Package ID obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppPackageID?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Google OAuth Client ID obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientID?: string; + /** + * Google OAuth Client Secret obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientSecret?: string; + /** + * Authorized Redirect Uri obtained through the Google Developer Console. This currently defaults to + * https://oauth.playfab.com/oauth2/google. If you are authenticating players via browser, please update this to your own + * domain. + */ + OAuthCustomRedirectUri?: string; + /** Needed to enable pending purchase handling and subscription processing. */ + ServiceAccountKey?: string; + + } + + export interface CreateOrUpdateGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Kongregate Secret API Key obtained after setting up your game in your Kongregate developer account. */ + SecretAPIKey: string; + + } + + export interface CreateOrUpdateKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Nintendo Switch Application ID, without the "0x" prefix. */ + ApplicationID?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** List of Nintendo Environments, currently supporting up to 4. Needs Catalog enabled. */ + Environments?: NintendoEnvironment[]; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** List of Nintendo Subscription Environments, currently supporting up to 4. Needs Catalog enabled. */ + SubscriptionEnvironments?: NintendoEnvironment[]; + + } + + export interface CreateOrUpdateNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdatePSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Client ID obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientID?: string; + /** Client secret obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Client ID obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientID?: string; + /** + * Client secret obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientSecret?: string; + + } + + export interface CreateOrUpdatePSNResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Application ID obtained after setting up your app in Valve's developer portal. */ + ApplicationId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Enforce usage of AzurePlayFab identity in user authentication tickets. */ + EnforceServiceSpecificTickets?: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Sercet Key obtained after setting up your app in Valve's developer portal. */ + SecretKey: string; + /** Use Steam Payments sandbox endpoint for test transactions. */ + UseSandbox?: boolean; + + } + + export interface CreateOrUpdateSteamResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Account ID obtained after creating your ToxMod developer account. */ + AccountId: string; + /** Account Key obtained after creating your ToxMod developer account. */ + AccountKey: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Whether ToxMod Addon is Enabled by Title. */ + Enabled: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateToxModResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Client ID obtained after creating your Twitch developer account. */ + ClientID?: string; + /** Client Secret obtained after creating your Twitch developer account. */ + ClientSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteAppleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeletePSNResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteSteamResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteToxModResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface GetAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetAppleResponse extends PlayFabModule.IPlayFabResultCommon { + /** iOS App Bundle ID obtained after setting up your app in the App Store. */ + AppBundleId?: string; + /** Addon status. */ + Created: boolean; + /** Ignore expiration date for identity tokens. */ + IgnoreExpirationDate?: boolean; + /** Require secure authentication only for this app. */ + RequireSecureAuthentication?: boolean; + + } + + export interface GetFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + /** Facebook App ID obtained after setting up your app in Facebook Instant Games. */ + AppID?: string; + /** Addon status. */ + Created: boolean; + + } + + export interface GetFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + /** Facebook App ID obtained after setting up your app in Facebook. */ + AppID?: string; + /** Addon status. */ + Created: boolean; + /** Email address for purchase dispute notifications. */ + NotificationEmail?: string; + + } + + export interface GetGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * Google App Package ID obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppPackageID?: string; + /** Addon status. */ + Created: boolean; + /** + * Google OAuth Client ID obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientID?: string; + /** + * Authorized Redirect Uri obtained through the Google Developer Console. This currently defaults to + * https://oauth.playfab.com/oauth2/google. If you are authenticating players via browser, please update this to your own + * domain. + */ + OauthCustomRedirectUri?: string; + + } + + export interface GetKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + /** Addon status. */ + Created: boolean; + + } + + export interface GetNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + /** Nintendo Switch Application ID, without the "0x" prefix. */ + ApplicationID?: string; + /** Addon status. */ + Created: boolean; + /** List of Nintendo Environments, currently supporting up to 4. */ + Environments?: NintendoEnvironment[]; + /** List of Nintendo Subscription Environments associated to a secondary AppId, currently supporting up to 4. */ + SecondarySubscriptionEnvironments?: NintendoEnvironment[]; + /** List of Nintendo Subscription Environments, currently supporting up to 4. */ + SubscriptionEnvironments?: NintendoEnvironment[]; + + } + + export interface GetPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetPSNResponse extends PlayFabModule.IPlayFabResultCommon { + /** Client ID obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientID?: string; + /** Addon status. */ + Created: boolean; + /** + * Client ID obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientID?: string; + + } + + export interface GetSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetSteamResponse extends PlayFabModule.IPlayFabResultCommon { + /** Application ID obtained after setting up your game in Valve's developer portal. */ + ApplicationId?: string; + /** Addon status. */ + Created: boolean; + /** Enforce usage of AzurePlayFab identity in user authentication tickets. */ + EnforceServiceSpecificTickets?: boolean; + /** Use Steam Payments sandbox endpoint for test transactions. */ + UseSandbox?: boolean; + + } + + export interface GetToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetToxModResponse extends PlayFabModule.IPlayFabResultCommon { + /** Account ID obtained after creating your Twitch developer account. */ + AccountId?: string; + /** Account Key obtained after creating your Twitch developer account. */ + AccountKey?: string; + /** Addon status. */ + Created: boolean; + /** Whether the ToxMod Addon is enabled by the title. */ + Enabled: boolean; + + } + + export interface GetTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + /** Client ID obtained after creating your Twitch developer account. */ + ClientID?: string; + /** Addon status. */ + Created: boolean; + + } + + export interface NintendoEnvironment { + /** Client ID for the Nintendo Environment. */ + ClientID?: string; + /** Client Secret for the Nintendo Environment. */ + ClientSecret?: string; + /** ID for the Nintendo Environment. */ + ID?: string; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabAdminApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabAdminApi.d.ts index 1ce76ba8..46869cef 100644 --- a/PlayFabSdk/src/Typings/PlayFab/PlayFabAdminApi.d.ts +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabAdminApi.d.ts @@ -2,1090 +2,1175 @@ declare module PlayFabAdminModule { export interface IPlayFabAdmin { + ForgetAllCredentials(): void; + /** - / Gets the requested policy. - / https://api.playfab.com/Documentation/Admin/method/GetPolicy + * Abort an ongoing task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/aborttaskinstance */ - GetPolicy(request: PlayFabAdminModels.GetPolicyRequest, callback: PlayFabModule.ApiCallback): void; + AbortTaskInstance(request: PlayFabAdminModels.AbortTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Changes a policy for a title - / https://api.playfab.com/Documentation/Admin/method/UpdatePolicy + * Update news item to include localized version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addlocalizednews */ - UpdatePolicy(request: PlayFabAdminModels.UpdatePolicyRequest, callback: PlayFabModule.ApiCallback): void; + AddLocalizedNews(request: PlayFabAdminModels.AddLocalizedNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Bans users by PlayFab ID with optional IP address, or MAC address for the provided game. - / https://api.playfab.com/Documentation/Admin/method/BanUsers + * Adds a new news item to the title's news feed + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addnews */ - BanUsers(request: PlayFabAdminModels.BanUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddNews(request: PlayFabAdminModels.AddNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the relevant details for a specified user, based upon a match against a supplied unique identifier - / https://api.playfab.com/Documentation/Admin/method/GetUserAccountInfo + * Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/addplayertag */ - GetUserAccountInfo(request: PlayFabAdminModels.LookupUserAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + AddPlayerTag(request: PlayFabAdminModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all bans for a user. - / https://api.playfab.com/Documentation/Admin/method/GetUserBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/adduservirtualcurrency */ - GetUserBans(request: PlayFabAdminModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback): void; + AddUserVirtualCurrency(request: PlayFabAdminModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Resets all title-specific information about a particular account, including user data, virtual currency balances, inventory, purchase history, and statistics - / https://api.playfab.com/Documentation/Admin/method/ResetUsers + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds one or more virtual currencies to the set defined for the title. Virtual Currencies have a maximum + * value of 2,147,483,647 when granted to a player. Any value over that will be discarded. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addvirtualcurrencytypes */ - ResetUsers(request: PlayFabAdminModels.ResetUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddVirtualCurrencyTypes(request: PlayFabAdminModels.AddVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans for a user. - / https://api.playfab.com/Documentation/Admin/method/RevokeAllBansForUser + * Bans users by PlayFab ID with optional IP address for the provided game. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/banusers */ - RevokeAllBansForUser(request: PlayFabAdminModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback): void; + BanUsers(request: PlayFabAdminModels.BanUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans specified with BanId. - / https://api.playfab.com/Documentation/Admin/method/RevokeBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Checks the global count for the limited edition item. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/checklimitededitionitemavailability */ - RevokeBans(request: PlayFabAdminModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback): void; + CheckLimitedEditionItemAvailability(request: PlayFabAdminModels.CheckLimitedEditionItemAvailabilityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Forces an email to be sent to the registered email address for the specified account, with a link allowing the user to change the password - / https://api.playfab.com/Documentation/Admin/method/SendAccountRecoveryEmail + * Create an ActionsOnPlayersInSegment task, which iterates through all players in a segment to execute action. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createactionsonplayersinsegmenttask */ - SendAccountRecoveryEmail(request: PlayFabAdminModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback): void; + CreateActionsOnPlayersInSegmentTask(request: PlayFabAdminModels.CreateActionsOnPlayerSegmentTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates information of a list of existing bans specified with Ban Ids. - / https://api.playfab.com/Documentation/Admin/method/UpdateBans + * Create a CloudScript task, which can run a CloudScript on a schedule. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createcloudscripttask */ - UpdateBans(request: PlayFabAdminModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback): void; + CreateCloudScriptTask(request: PlayFabAdminModels.CreateCloudScriptTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title specific display name for a user - / https://api.playfab.com/Documentation/Admin/method/UpdateUserTitleDisplayName + * Create a Insights Scheduled Scaling task, which can scale Insights Performance Units on a schedule + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createinsightsscheduledscalingtask */ - UpdateUserTitleDisplayName(request: PlayFabAdminModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback): void; + CreateInsightsScheduledScalingTask(request: PlayFabAdminModels.CreateInsightsScheduledScalingTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a new player statistic configuration to the title, optionally allowing the developer to specify a reset interval and an aggregation method. - / https://api.playfab.com/Documentation/Admin/method/CreatePlayerStatisticDefinition + * Bans an IP address or CIDR range for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/createipban */ - CreatePlayerStatisticDefinition(request: PlayFabAdminModels.CreatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback): void; + CreateIPBan(request: PlayFabAdminModels.CreateIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the users for the provided game. Deletes custom data, all account linkages, and statistics. This method does not remove the player's event history, login history, inventory items, nor virtual currencies. - / https://api.playfab.com/Documentation/Admin/method/DeleteUsers + * Registers a relationship between a title and an Open ID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/createopenidconnection */ - DeleteUsers(request: PlayFabAdminModels.DeleteUsersRequest, callback: PlayFabModule.ApiCallback): void; + CreateOpenIdConnection(request: PlayFabAdminModels.CreateOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a download URL for the requested report - / https://api.playfab.com/Documentation/Admin/method/GetDataReport + * Creates a new Player Shared Secret Key. It may take up to 5 minutes for this key to become generally available after + * this API returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/createplayersharedsecret */ - GetDataReport(request: PlayFabAdminModels.GetDataReportRequest, callback: PlayFabModule.ApiCallback): void; + CreatePlayerSharedSecret(request: PlayFabAdminModels.CreatePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the configuration information for all player statistics defined in the title, regardless of whether they have a reset interval. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerStatisticDefinitions + * Adds a new player statistic configuration to the title, optionally allowing the developer to specify a reset interval + * and an aggregation method. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/createplayerstatisticdefinition */ - GetPlayerStatisticDefinitions(request: PlayFabAdminModels.GetPlayerStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback): void; + CreatePlayerStatisticDefinition(request: PlayFabAdminModels.CreatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerStatisticVersions + * Creates a new player segment by defining the conditions on player properties. Also, create actions to target the player + * segments for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/createsegment */ - GetPlayerStatisticVersions(request: PlayFabAdminModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + CreateSegment(request: PlayFabAdminModels.CreateSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserData + * Delete a content file from the title. When deleting a file that does not exist, it returns success. + * https://docs.microsoft.com/rest/api/playfab/admin/content/deletecontent */ - GetUserData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteContent(request: PlayFabAdminModels.DeleteContentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserInternalData + * Removes a master player account entirely from all titles and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemasterplayeraccount */ - GetUserInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMasterPlayerAccount(request: PlayFabAdminModels.DeleteMasterPlayerAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherData + * Deletes PlayStream and telemetry event data associated with the master player account from PlayFab storage + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemasterplayereventdata */ - GetUserPublisherData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMasterPlayerEventData(request: PlayFabAdminModels.DeleteMasterPlayerEventDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherInternalData + * Deletes a player's subscription + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemembershipsubscription */ - GetUserPublisherInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMembershipSubscription(request: PlayFabAdminModels.DeleteMembershipSubscriptionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherReadOnlyData + * Removes a relationship between a title and an OpenID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/deleteopenidconnection */ - GetUserPublisherReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteOpenIdConnection(request: PlayFabAdminModels.DeleteOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserReadOnlyData + * Removes a user's player account from a title and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deleteplayer */ - GetUserReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayer(request: PlayFabAdminModels.DeletePlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Resets the indicated statistic, removing all player entries for it and backing up the old values. - / https://api.playfab.com/Documentation/Admin/method/IncrementPlayerStatisticVersion + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/deleteplayercustomproperties */ - IncrementPlayerStatisticVersion(request: PlayFabAdminModels.IncrementPlayerStatisticVersionRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerCustomProperties(request: PlayFabAdminModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to process an order refund through the original real money payment provider. - / https://api.playfab.com/Documentation/Admin/method/RefundPurchase + * Deletes an existing Player Shared Secret Key. It may take up to 5 minutes for this delete to be reflected after this API + * returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/deleteplayersharedsecret */ - RefundPurchase(request: PlayFabAdminModels.RefundPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerSharedSecret(request: PlayFabAdminModels.DeletePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completely removes all statistics for the specified user, for the current game - / https://api.playfab.com/Documentation/Admin/method/ResetUserStatistics + * Deletes an existing player segment and its associated action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/deletesegment */ - ResetUserStatistics(request: PlayFabAdminModels.ResetUserStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + DeleteSegment(request: PlayFabAdminModels.DeleteSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to resolve a dispute with the original order's payment provider. - / https://api.playfab.com/Documentation/Admin/method/ResolvePurchaseDispute + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Deletes an existing virtual item store + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/deletestore */ - ResolvePurchaseDispute(request: PlayFabAdminModels.ResolvePurchaseDisputeRequest, callback: PlayFabModule.ApiCallback): void; + DeleteStore(request: PlayFabAdminModels.DeleteStoreRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates a player statistic configuration for the title, optionally allowing the developer to specify a reset interval. - / https://api.playfab.com/Documentation/Admin/method/UpdatePlayerStatisticDefinition + * Delete a task. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/deletetask */ - UpdatePlayerStatisticDefinition(request: PlayFabAdminModels.UpdatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTask(request: PlayFabAdminModels.DeleteTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserData + * Permanently deletes a title and all associated configuration + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletetitle */ - UpdateUserData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTitle(request: PlayFabAdminModels.DeleteTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserInternalData + * Deletes a specified set of title data overrides. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/deletetitledataoverride */ - UpdateUserInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTitleDataOverride(request: PlayFabAdminModels.DeleteTitleDataOverrideRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherData + * Exports all associated data of a master player account + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/exportmasterplayerdata */ - UpdateUserPublisherData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportMasterPlayerData(request: PlayFabAdminModels.ExportMasterPlayerDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherInternalData + * Starts an export for the player profiles in a segment. This API creates a snapshot of all the player profiles which + * match the segment definition at the time of the API call. Profiles which change while an export is in progress will not + * be reflected in the results. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/exportplayersinsegment */ - UpdateUserPublisherInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportPlayersInSegment(request: PlayFabAdminModels.ExportPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherReadOnlyData + * Get information about a ActionsOnPlayersInSegment task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/getactionsonplayersinsegmenttaskinstance */ - UpdateUserPublisherReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetActionsOnPlayersInSegmentTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserReadOnlyData + * Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as + * ExportPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not + * change. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getallsegments */ - UpdateUserReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllSegments(request: PlayFabAdminModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a new news item to the title's news feed - / https://api.playfab.com/Documentation/Admin/method/AddNews + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getcatalogitems */ - AddNews(request: PlayFabAdminModels.AddNewsRequest, callback: PlayFabModule.ApiCallback): void; + GetCatalogItems(request: PlayFabAdminModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds one or more virtual currencies to the set defined for the title. Virtual Currencies have a maximum value of 2,147,483,647 when granted to a player. Any value over that will be discarded. - / https://api.playfab.com/Documentation/Admin/method/AddVirtualCurrencyTypes + * Gets the contents and information of a specific Cloud Script revision. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/getcloudscriptrevision */ - AddVirtualCurrencyTypes(request: PlayFabAdminModels.AddVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptRevision(request: PlayFabAdminModels.GetCloudScriptRevisionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes an existing virtual item store - / https://api.playfab.com/Documentation/Admin/method/DeleteStore + * Get detail information about a CloudScript task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/getcloudscripttaskinstance */ - DeleteStore(request: PlayFabAdminModels.DeleteStoreRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Admin/method/GetCatalogItems + * Lists all the current cloud script versions. For each version, information about the current published and latest + * revisions is also listed. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/getcloudscriptversions */ - GetCatalogItems(request: PlayFabAdminModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptVersions(request: PlayFabAdminModels.GetCloudScriptVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Admin/method/GetPublisherData + * List all contents of the title and get statistics such as size + * https://docs.microsoft.com/rest/api/playfab/admin/content/getcontentlist */ - GetPublisherData(request: PlayFabAdminModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetContentList(request: PlayFabAdminModels.GetContentListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the random drop table configuration for the title - / https://api.playfab.com/Documentation/Admin/method/GetRandomResultTables + * Retrieves the pre-signed URL for uploading a content file. A subsequent HTTP PUT to the returned URL uploads the + * content. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN + * rates apply. + * https://docs.microsoft.com/rest/api/playfab/admin/content/getcontentuploadurl */ - GetRandomResultTables(request: PlayFabAdminModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetContentUploadUrl(request: PlayFabAdminModels.GetContentUploadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the set of items defined for the specified store, including all prices defined - / https://api.playfab.com/Documentation/Admin/method/GetStoreItems + * Retrieves a download URL for the requested report + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getdatareport */ - GetStoreItems(request: PlayFabAdminModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetDataReport(request: PlayFabAdminModels.GetDataReportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings which can be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetTitleData + * Gets all IP bans that apply to a specific IP address. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getipbansforip */ - GetTitleData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetIPBansForIP(request: PlayFabAdminModels.GetIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings which cannot be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetTitleInternalData + * Gets all IP bans for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getipbansfortitle */ - GetTitleInternalData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetIPBansForTitle(request: PlayFabAdminModels.GetAllIPBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retuns the list of all defined virtual currencies for the title - / https://api.playfab.com/Documentation/Admin/method/ListVirtualCurrencyTypes + * Get the list of titles that the player has played + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayedtitlelist */ - ListVirtualCurrencyTypes(request: PlayFabAdminModels.ListVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayedTitleList(request: PlayFabAdminModels.GetPlayedTitleListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes one or more virtual currencies from the set defined for the title. - / https://api.playfab.com/Documentation/Admin/method/RemoveVirtualCurrencyTypes + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayercustomproperty */ - RemoveVirtualCurrencyTypes(request: PlayFabAdminModels.RemoveVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCustomProperty(request: PlayFabAdminModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates the catalog configuration of all virtual goods for the specified catalog version - / https://api.playfab.com/Documentation/Admin/method/SetCatalogItems + * Gets a player's ID from an auth token. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayeridfromauthtoken */ - SetCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerIdFromAuthToken(request: PlayFabAdminModels.GetPlayerIdFromAuthTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets all the items in one virtual store - / https://api.playfab.com/Documentation/Admin/method/SetStoreItems + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayerprofile */ - SetStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerProfile(request: PlayFabAdminModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the key-value store of custom title settings which can be read by the client - / https://api.playfab.com/Documentation/Admin/method/SetTitleData + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getplayersegments */ - SetTitleData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSegments(request: PlayFabAdminModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings which cannot be read by the client - / https://api.playfab.com/Documentation/Admin/method/SetTitleInternalData + * Returns all Player Shared Secret Keys including disabled and expired. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/getplayersharedsecrets */ - SetTitleInternalData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSharedSecrets(request: PlayFabAdminModels.GetPlayerSharedSecretsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the Amazon Resource Name (ARN) for iOS and Android push notifications. Documentation on the exact restrictions can be found at: http://docs.aws.amazon.com/sns/latest/api/API_CreatePlatformApplication.html. Currently, Amazon device Messaging is not supported. - / https://api.playfab.com/Documentation/Admin/method/SetupPushNotification + * Retrieves the configuration information for all player statistics defined in the title, regardless of whether they have + * a reset interval. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayerstatisticdefinitions */ - SetupPushNotification(request: PlayFabAdminModels.SetupPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticDefinitions(request: PlayFabAdminModels.GetPlayerStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the catalog configuration for virtual goods in the specified catalog version - / https://api.playfab.com/Documentation/Admin/method/UpdateCatalogItems + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayerstatisticversions */ - UpdateCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticVersions(request: PlayFabAdminModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the random drop table configuration for the title - / https://api.playfab.com/Documentation/Admin/method/UpdateRandomResultTables + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getplayertags */ - UpdateRandomResultTables(request: PlayFabAdminModels.UpdateRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerTags(request: PlayFabAdminModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates an existing virtual item store with new or modified items - / https://api.playfab.com/Documentation/Admin/method/UpdateStoreItems + * Gets the requested policy. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/getpolicy */ - UpdateStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPolicy(request: PlayFabAdminModels.GetPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Admin/method/AddUserVirtualCurrency + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getpublisherdata */ - AddUserVirtualCurrency(request: PlayFabAdminModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabAdminModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Admin/method/GetUserInventory + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the random drop table configuration for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getrandomresulttables */ - GetUserInventory(request: PlayFabAdminModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetRandomResultTables(request: PlayFabAdminModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user inventories - / https://api.playfab.com/Documentation/Admin/method/GrantItemsToUsers + * Retrieves the result of an export started by ExportPlayersInSegment API. If the ExportPlayersInSegment is successful and + * complete, this API returns the IndexUrl from which the index file can be downloaded. The index file has a list of urls + * from which the files containing the player profile data can be downloaded. Otherwise, it returns the current 'State' of + * the export + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getsegmentexport */ - GrantItemsToUsers(request: PlayFabAdminModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentExport(request: PlayFabAdminModels.GetPlayersInSegmentExportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revokes access to an item in a user's inventory - / https://api.playfab.com/Documentation/Admin/method/RevokeInventoryItem + * Returns the total number of players in a given segment. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getsegmentplayercount */ - RevokeInventoryItem(request: PlayFabAdminModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentPlayerCount(request: PlayFabAdminModels.GetSegmentPlayerCountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Admin/method/SubtractUserVirtualCurrency + * Get detail information of a segment and its associated definition(s) and action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/getsegments */ - SubtractUserVirtualCurrency(request: PlayFabAdminModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetSegments(request: PlayFabAdminModels.GetSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details for a specific completed session, including links to standard out and standard error logs - / https://api.playfab.com/Documentation/Admin/method/GetMatchmakerGameInfo + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getstoreitems */ - GetMatchmakerGameInfo(request: PlayFabAdminModels.GetMatchmakerGameInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabAdminModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of defined game modes for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/GetMatchmakerGameModes + * Query for task instances by task, status, or time range. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/gettaskinstances */ - GetMatchmakerGameModes(request: PlayFabAdminModels.GetMatchmakerGameModesRequest, callback: PlayFabModule.ApiCallback): void; + GetTaskInstances(request: PlayFabAdminModels.GetTaskInstancesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the game server mode details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/ModifyMatchmakerGameModes + * Get definition information on a specified task or all tasks within a title. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/gettasks */ - ModifyMatchmakerGameModes(request: PlayFabAdminModels.ModifyMatchmakerGameModesRequest, callback: PlayFabModule.ApiCallback): void; + GetTasks(request: PlayFabAdminModels.GetTasksRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the game server executable specified (previously uploaded - see GetServerBuildUploadUrl) to the set of those a client is permitted to request in a call to StartGame - / https://api.playfab.com/Documentation/Admin/method/AddServerBuild + * Retrieves the key-value store of custom title settings which can be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/gettitledata */ - AddServerBuild(request: PlayFabAdminModels.AddServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the build details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/GetServerBuildInfo + * Retrieves the key-value store of custom title settings which cannot be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/gettitleinternaldata */ - GetServerBuildInfo(request: PlayFabAdminModels.GetServerBuildInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleInternalData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the pre-authorized URL for uploading a game server package containing a build (does not enable the build for use - see AddServerBuild) - / https://api.playfab.com/Documentation/Admin/method/GetServerBuildUploadUrl + * Retrieves the relevant details for a specified user, based upon a match against a supplied unique identifier + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getuseraccountinfo */ - GetServerBuildUploadUrl(request: PlayFabAdminModels.GetServerBuildUploadURLRequest, callback: PlayFabModule.ApiCallback): void; + GetUserAccountInfo(request: PlayFabAdminModels.LookupUserAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the build details for all game server executables which are currently defined for the title - / https://api.playfab.com/Documentation/Admin/method/ListServerBuilds + * Gets all bans for a user. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getuserbans */ - ListServerBuilds(request: PlayFabAdminModels.ListBuildsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserBans(request: PlayFabAdminModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the build details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/ModifyServerBuild + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserdata */ - ModifyServerBuild(request: PlayFabAdminModels.ModifyServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the game server executable specified from the set of those a client is permitted to request in a call to StartGame - / https://api.playfab.com/Documentation/Admin/method/RemoveServerBuild + * Retrieves the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserinternaldata */ - RemoveServerBuild(request: PlayFabAdminModels.RemoveServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Admin/method/SetPublisherData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/getuserinventory */ - SetPublisherData(request: PlayFabAdminModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabAdminModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets the contents and information of a specific Cloud Script revision. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptRevision + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherdata */ - GetCloudScriptRevision(request: PlayFabAdminModels.GetCloudScriptRevisionRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all the current cloud script versions. For each version, information about the current published and latest revisions is also listed. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptVersions + * Retrieves the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherinternaldata */ - GetCloudScriptVersions(request: PlayFabAdminModels.GetCloudScriptVersionsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the currently published revision of a title Cloud Script - / https://api.playfab.com/Documentation/Admin/method/SetPublishedRevision + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherreadonlydata */ - SetPublishedRevision(request: PlayFabAdminModels.SetPublishedRevisionRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates a new Cloud Script revision and uploads source code to it. Note that at this time, only one file should be submitted in the revision. - / https://api.playfab.com/Documentation/Admin/method/UpdateCloudScript + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserreadonlydata */ - UpdateCloudScript(request: PlayFabAdminModels.UpdateCloudScriptRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Delete a content file from the title - / https://api.playfab.com/Documentation/Admin/method/DeleteContent + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user inventories + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/grantitemstousers */ - DeleteContent(request: PlayFabAdminModels.DeleteContentRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUsers(request: PlayFabAdminModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all contents of the title and get statistics such as size - / https://api.playfab.com/Documentation/Admin/method/GetContentList + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increases the global count for the given scarce resource. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/incrementlimitededitionitemavailability */ - GetContentList(request: PlayFabAdminModels.GetContentListRequest, callback: PlayFabModule.ApiCallback): void; + IncrementLimitedEditionItemAvailability(request: PlayFabAdminModels.IncrementLimitedEditionItemAvailabilityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the pre-signed URL for uploading a content file. A subsequent HTTP PUT to the returned URL uploads the content. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Admin/method/GetContentUploadUrl + * Resets the indicated statistic, removing all player entries for it and backing up the old values. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/incrementplayerstatisticversion */ - GetContentUploadUrl(request: PlayFabAdminModels.GetContentUploadUrlRequest, callback: PlayFabModule.ApiCallback): void; + IncrementPlayerStatisticVersion(request: PlayFabAdminModels.IncrementPlayerStatisticVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completely removes all statistics for the specified character, for the current game - / https://api.playfab.com/Documentation/Admin/method/ResetCharacterStatistics + * Retrieves a list of all Open ID Connect providers registered to a title. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/listopenidconnection */ - ResetCharacterStatistics(request: PlayFabAdminModels.ResetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + ListOpenIdConnection(request: PlayFabAdminModels.ListOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Admin/method/AddPlayerTag + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/listplayercustomproperties */ - AddPlayerTag(request: PlayFabAdminModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabAdminModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieve a list of all PlayStream actions groups. - / https://api.playfab.com/Documentation/Admin/method/GetAllActionGroups + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retuns the list of all defined virtual currencies for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/listvirtualcurrencytypes */ - GetAllActionGroups(request: PlayFabAdminModels.GetAllActionGroupsRequest, callback: PlayFabModule.ApiCallback): void; + ListVirtualCurrencyTypes(request: PlayFabAdminModels.ListVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as GetPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not change. - / https://api.playfab.com/Documentation/Admin/method/GetAllSegments + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Attempts to process an order refund through the original real money payment provider. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/refundpurchase */ - GetAllSegments(request: PlayFabAdminModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + RefundPurchase(request: PlayFabAdminModels.RefundPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerSegments + * Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/removeplayertag */ - GetPlayerSegments(request: PlayFabAdminModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + RemovePlayerTag(request: PlayFabAdminModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Allows for paging through all players in a given segment. This API creates a snapshot of all player profiles that match the segment definition at the time of its creation and lives through the Total Seconds to Live, refreshing its life span on each subsequent use of the Continuation Token. Profiles that change during the course of paging will not be reflected in the results. AB Test segments are currently not supported by this operation. - / https://api.playfab.com/Documentation/Admin/method/GetPlayersInSegment + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Removes one or more virtual currencies from the set defined for the title. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/removevirtualcurrencytypes */ - GetPlayersInSegment(request: PlayFabAdminModels.GetPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback): void; + RemoveVirtualCurrencyTypes(request: PlayFabAdminModels.RemoveVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerTags + * Completely removes all statistics for the specified character, for the current game + * https://docs.microsoft.com/rest/api/playfab/admin/characters/resetcharacterstatistics */ - GetPlayerTags(request: PlayFabAdminModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + ResetCharacterStatistics(request: PlayFabAdminModels.ResetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Admin/method/RemovePlayerTag + * Reset a player's password for a given title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/resetpassword */ - RemovePlayerTag(request: PlayFabAdminModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + ResetPassword(request: PlayFabAdminModels.ResetPasswordRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Abort an ongoing task instance. - / https://api.playfab.com/Documentation/Admin/method/AbortTaskInstance + * Completely removes all statistics for the specified user, for the current game + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/resetuserstatistics */ - AbortTaskInstance(request: PlayFabAdminModels.AbortTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + ResetUserStatistics(request: PlayFabAdminModels.ResetUserStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Create an ActionsOnPlayersInSegment task, which iterates through all players in a segment to execute action. - / https://api.playfab.com/Documentation/Admin/method/CreateActionsOnPlayersInSegmentTask + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Attempts to resolve a dispute with the original order's payment provider. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/resolvepurchasedispute */ - CreateActionsOnPlayersInSegmentTask(request: PlayFabAdminModels.CreateActionsOnPlayerSegmentTaskRequest, callback: PlayFabModule.ApiCallback): void; + ResolvePurchaseDispute(request: PlayFabAdminModels.ResolvePurchaseDisputeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Create a CloudScript task, which can run a CloudScript on a schedule. - / https://api.playfab.com/Documentation/Admin/method/CreateCloudScriptTask + * Revoke all active bans for a user. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokeallbansforuser */ - CreateCloudScriptTask(request: PlayFabAdminModels.CreateCloudScriptTaskRequest, callback: PlayFabModule.ApiCallback): void; + RevokeAllBansForUser(request: PlayFabAdminModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Delete a task. - / https://api.playfab.com/Documentation/Admin/method/DeleteTask + * Revoke all active bans specified with BanId. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokebans */ - DeleteTask(request: PlayFabAdminModels.DeleteTaskRequest, callback: PlayFabModule.ApiCallback): void; + RevokeBans(request: PlayFabAdminModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get information about a ActionsOnPlayersInSegment task instance. - / https://api.playfab.com/Documentation/Admin/method/GetActionsOnPlayersInSegmentTaskInstance + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access to an item in a user's inventory + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/revokeinventoryitem */ - GetActionsOnPlayersInSegmentTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + RevokeInventoryItem(request: PlayFabAdminModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get detail information about a CloudScript task instance. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptTaskInstance + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access for up to 25 items across multiple users and characters. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/revokeinventoryitems */ - GetCloudScriptTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + RevokeInventoryItems(request: PlayFabAdminModels.RevokeInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Query for task instances by task, status, or time range. - / https://api.playfab.com/Documentation/Admin/method/GetTaskInstances + * Revokes an active IP ban. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokeipban */ - GetTaskInstances(request: PlayFabAdminModels.GetTaskInstancesRequest, callback: PlayFabModule.ApiCallback): void; + RevokeIPBan(request: PlayFabAdminModels.RevokeIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get definition information on a specified task or all tasks within a title. - / https://api.playfab.com/Documentation/Admin/method/GetTasks + * Run a task immediately regardless of its schedule. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/runtask */ - GetTasks(request: PlayFabAdminModels.GetTasksRequest, callback: PlayFabModule.ApiCallback): void; + RunTask(request: PlayFabAdminModels.RunTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Run a task immediately regardless of its schedule. - / https://api.playfab.com/Documentation/Admin/method/RunTask + * Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to + * change the password.If an account recovery email template ID is provided, an email using the custom email template will + * be used. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/sendaccountrecoveryemail */ - RunTask(request: PlayFabAdminModels.RunTaskRequest, callback: PlayFabModule.ApiCallback): void; + SendAccountRecoveryEmail(request: PlayFabAdminModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update an existing task. - / https://api.playfab.com/Documentation/Admin/method/UpdateTask + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Creates the catalog configuration of all virtual goods for the specified catalog version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setcatalogitems */ - UpdateTask(request: PlayFabAdminModels.UpdateTaskRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabAdminModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AbortTaskInstanceRequest - */ - export interface AbortTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + SetCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of a task instance that is being aborted. + * Sets the override expiration for a membership subscription + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/setmembershipoverride */ - TaskInstanceId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ActionsOnPlayersInSegmentTaskParameter - */ - export interface ActionsOnPlayersInSegmentTaskParameter { + SetMembershipOverride(request: PlayFabAdminModels.SetMembershipOverrideRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the segment to perform actions on. + * Sets or resets the player's secret. Player secrets are used to sign API requests. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/setplayersecret */ - SegmentId: string; + SetPlayerSecret(request: PlayFabAdminModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the action to perform on each player in segment. + * Sets the currently published revision of a title Cloud Script + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/setpublishedrevision */ - ActionId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ActionsOnPlayersInSegmentTaskSummary - */ - export interface ActionsOnPlayersInSegmentTaskSummary { + SetPublishedRevision(request: PlayFabAdminModels.SetPublishedRevisionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the task instance. + * Updates the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/admin/shared-group-data/setpublisherdata */ - TaskInstanceId?: string; + SetPublisherData(request: PlayFabAdminModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Identifier of the task this instance belongs to. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Sets all the items in one virtual store + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setstoreitems */ - TaskIdentifier?: NameIdentifier; + SetStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task started. + * Creates and updates the key-value store of custom title settings which can be read by the client. For example, a + * developer could choose to store values which modify the user experience, such as enemy spawn rates, weapon strengths, + * movement speeds, etc. This allows a developer to update the title without the need to create, test, and ship a new + * build. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitledata */ - StartedAt: string; + SetTitleData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task completed. + * Set and delete key-value pairs in a title data override instance. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitledataandoverrides */ - CompletedAt?: string; + SetTitleDataAndOverrides(request: PlayFabAdminModels.SetTitleDataAndOverridesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Current status of the task instance. + * Updates the key-value store of custom title settings which cannot be read by the client. These values can be used to + * tweak settings used by game servers and Cloud Scripts without the need to update and re-deploy. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitleinternaldata */ - Status?: string; + SetTitleInternalData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Progress represented as percentage. + * Sets the Amazon Resource Name (ARN) for iOS and Android push notifications. Documentation on the exact restrictions can + * be found at: http://docs.aws.amazon.com/sns/latest/api/API_CreatePlatformApplication.html. Currently, Amazon device + * Messaging is not supported. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setuppushnotification */ - PercentComplete?: number; + SetupPushNotification(request: PlayFabAdminModels.SetupPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Estimated time remaining in seconds. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/subtractuservirtualcurrency */ - EstimatedSecondsRemaining?: number; + SubtractUserVirtualCurrency(request: PlayFabAdminModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / If manually scheduled, ID of user who scheduled the task. + * Updates information of a list of existing bans specified with Ban Ids. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updatebans */ - ScheduledByUserId?: string; + UpdateBans(request: PlayFabAdminModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Error message for last processing attempt, if an error occured. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the catalog configuration for virtual goods in the specified catalog version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updatecatalogitems */ - ErrorMessage?: string; + UpdateCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Flag indicating if the error was fatal, if false job will be retried. + * Creates a new Cloud Script revision and uploads source code to it. Note that at this time, only one file should be + * submitted in the revision. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/updatecloudscript */ - ErrorWasFatal?: boolean; + UpdateCloudScript(request: PlayFabAdminModels.UpdateCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total players in segment when task was started. + * Updates an existing IP ban. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updateipban */ - TotalPlayersInSegment?: number; + UpdateIPBan(request: PlayFabAdminModels.UpdateIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total number of players that have had the actions applied to. + * Modifies data and credentials for an existing relationship between a title and an Open ID Connect provider + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updateopenidconnection */ - TotalPlayersProcessed?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AdCampaignAttribution - */ - export interface AdCampaignAttribution { + UpdateOpenIdConnection(request: PlayFabAdminModels.UpdateOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateplayercustomproperties */ - Platform?: string; + UpdatePlayerCustomProperties(request: PlayFabAdminModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Updates a existing Player Shared Secret Key. It may take up to 5 minutes for this update to become generally available + * after this API returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updateplayersharedsecret */ - CampaignId?: string; + UpdatePlayerSharedSecret(request: PlayFabAdminModels.UpdatePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Updates a player statistic configuration for the title, optionally allowing the developer to specify a reset interval. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateplayerstatisticdefinition */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddNewsRequest - */ - export interface AddNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdatePlayerStatisticDefinition(request: PlayFabAdminModels.UpdatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Time this news was published. If not set, defaults to now. + * Changes a policy for a title + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updatepolicy */ - Timestamp?: string; + UpdatePolicy(request: PlayFabAdminModels.UpdatePolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Title (headline) of the news item + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the random drop table configuration for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updaterandomresulttables */ - Title: string; + UpdateRandomResultTables(request: PlayFabAdminModels.UpdateRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Body text of the news + * Updates an existing player segment and its associated definition(s) and action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/updatesegment */ - Body: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddNewsResult - */ - export interface AddNewsResult extends PlayFabModule.IPlayFabResultCommon { + UpdateSegment(request: PlayFabAdminModels.UpdateSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique id of the new news item + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates an existing virtual item store with new or modified items + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updatestoreitems */ - NewsId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddPlayerTagRequest - */ - export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdateStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Update an existing task. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/updatetask */ - PlayFabId: string; + UpdateTask(request: PlayFabAdminModels.UpdateTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique tag for player profile. + * Updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserdata */ - TagName: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddPlayerTagResult - */ - export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddServerBuildRequest - */ - export interface AddServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdateUserData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / unique identifier for the build executable + * Updates the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserinternaldata */ - BuildId: string; + UpdateUserInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / appended to the end of the command line when starting game servers + * Updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherdata */ - CommandLineTemplate?: string; + UpdateUserPublisherData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / path to the game server executable. Defaults to gameserver.exe + * Updates the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherinternaldata */ - ExecutablePath?: string; + UpdateUserPublisherInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / server host regions in which this build should be running and available + * Updates the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherreadonlydata */ - ActiveRegions?: string[]; + UpdateUserPublisherReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / developer comment(s) for this build + * Updates the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserreadonlydata */ - Comment?: string; + UpdateUserReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / maximum number of game server instances that can run on a single host machine + * Updates the title specific display name for a user + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updateusertitledisplayname */ - MaxGamesPerHost: number; + UpdateUserTitleDisplayName(request: PlayFabAdminModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) + * Validates the result of a policy update without persisting it. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/validateapipolicy */ - MinFreeGameSlots: number; + ValidateApiPolicy(request: PlayFabAdminModels.ValidateApiPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } +} - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddServerBuildResult - */ - export interface AddServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ - Comment?: string; - /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / the current status of the build validation and processing steps - */ +declare module PlayFabAdminModels { + export interface AbortTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of a task instance that is being aborted. */ + TaskInstanceId: string; + + } + + export interface Action { + /** Action content to add inventory item v2 */ + AddInventoryItemV2Content?: AddInventoryItemV2Content; + /** Action content to ban player */ + BanPlayerContent?: BanPlayerContent; + /** Action content to delete inventory item v2 */ + DeleteInventoryItemV2Content?: DeleteInventoryItemV2Content; + /** Action content to delete player */ + DeletePlayerContent?: DeletePlayerContent; + /** Action content to execute cloud script */ + ExecuteCloudScriptContent?: ExecuteCloudScriptContent; + /** Action content to execute azure function */ + ExecuteFunctionContent?: ExecuteFunctionContent; + /** Action content to grant item */ + GrantItemContent?: GrantItemContent; + /** Action content to grant virtual currency */ + GrantVirtualCurrencyContent?: GrantVirtualCurrencyContent; + /** Action content to increment player statistic */ + IncrementPlayerStatisticContent?: IncrementPlayerStatisticContent; + /** Action content to send push notification */ + PushNotificationContent?: PushNotificationContent; + /** Action content to send email */ + SendEmailContent?: SendEmailContent; + /** Action content to subtract inventory item v2 */ + SubtractInventoryItemV2Content?: SubtractInventoryItemV2Content; + + } + + export interface ActionsOnPlayersInSegmentTaskParameter { + /** List of actions to perform on each player in a segment. Each action object can contain only one action type. */ + Actions?: Action[]; + /** ID of the segment to perform actions on. */ + SegmentId: string; + + } + + export interface ActionsOnPlayersInSegmentTaskSummary { + /** UTC timestamp when the task completed. */ + CompletedAt?: string; + /** Error message for last processing attempt, if an error occured. */ + ErrorMessage?: string; + /** Flag indicating if the error was fatal, if false job will be retried. */ + ErrorWasFatal?: boolean; + /** Estimated time remaining in seconds. */ + EstimatedSecondsRemaining?: number; + /** Progress represented as percentage. */ + PercentComplete?: number; + /** If manually scheduled, ID of user who scheduled the task. */ + ScheduledByUserId?: string; + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; + /** Total players in segment when task was started. */ + TotalPlayersInSegment?: number; + /** Total number of players that have had the actions applied to. */ + TotalPlayersProcessed?: number; + + } + + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + export interface AdCampaignSegmentFilter { + /** Campaign id. */ + CampaignId?: string; + /** Campaign source. */ + CampaignSource?: string; + /** Campaign comparison. */ + Comparison?: string; + + } + + export interface AddInventoryItemsV2SegmentAction { + /** Amount of the item to be granted to a player */ + Amount?: number; + /** The collection id for where the item will be granted in the player inventory */ + CollectionId?: string; + /** The duration in seconds of the subscription to be granted to a player */ + DurationInSeconds?: number; + /** The id of item to be granted to the player */ + ItemId?: string; + /** The stack id for where the item will be granted in the player inventory */ + StackId?: string; + + } + + export interface AddInventoryItemV2Content { + /** Amount of the item to be granted to a player */ + Amount?: number; + /** The collection id for where the item will be granted in the player inventory */ + CollectionId?: string; + /** The duration in seconds of the subscription to be granted to a player */ + DurationInSeconds?: number; + /** The id of item to be granted to the player */ + ItemId?: string; + /** The stack id for where the item will be granted in the player inventory */ + StackId?: string; + + } + + export interface AddLocalizedNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Localized body text of the news. */ + Body: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Language of the news item. */ + Language: string; + /** Unique id of the updated news item. */ + NewsId: string; + /** Localized title (headline) of the news item. */ + Title: string; + + } + + export interface AddLocalizedNewsResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface AddNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Default body text of the news. */ + Body: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional status for the new news item. If not set, defaults to Published. */ Status?: string; + /** Time this news was published. If not set, defaults to now. */ + Timestamp?: string; + /** Default title (headline) of the news item. */ + Title: string; + + } + + export interface AddNewsResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique id of the new news item */ + NewsId?: string; + + } + + export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique tag for player profile. */ + TagName: string; + + } + + export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / PlayFab unique identifier of the user whose virtual currency balance is to be increased. + * Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). + * Any increase over this value will be discarded. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be increased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be incremented. - */ + /** Name of the virtual currency which is to be incremented. */ VirtualCurrency: string; - /** - / Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddVirtualCurrencyTypesRequest - */ export interface AddVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / List of virtual currencies and their initial deposits (the amount a user is granted when signing in for the first time) to the title + * List of virtual currencies and their initial deposits (the amount a user is granted when signing in for the first time) + * to the title */ VirtualCurrencies: VirtualCurrencyData[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanInfo - */ + export interface AllPlayersSegmentFilter { + + } + + export interface ApiCondition { + /** Require that API calls contain an RSA encrypted payload or signed headers. */ + HasSignatureOrEncryption?: string; + + } + + type AuthTokenType = "Email" + + export interface BanInfo { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / The unique Ban Id associated with this ban. - */ + /** The active state of this ban. Expired bans may still have this value set to true but they will have no effect. */ + Active: boolean; + /** The unique Ban Id associated with this ban. */ BanId?: string; - /** - / The IP address on which the ban was applied. May affect multiple players. - */ - IPAddress?: string; - /** - / The MAC address on which the ban was applied. May affect multiple players. - */ - MACAddress?: string; - /** - / The time when this ban was applied. - */ + /** The time when this ban was applied. */ Created?: string; - /** - / The time when this ban expires. Permanent bans do not have expiration date. - */ + /** The time when this ban expires. Permanent bans do not have expiration date. */ Expires?: string; - /** - / The reason why this ban was applied. - */ + /** The IP address on which the ban was applied. May affect multiple players. */ + IPAddress?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** The reason why this ban was applied. */ Reason?: string; - /** - / The active state of this ban. Expired bans may still have this value set to true but they will have no effect. - */ - Active: boolean; + /** The family type of the user that is included in the ban. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanRequest - */ - export interface BanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / IP address to be banned. May affect multiple players. - */ + export interface BanPlayerContent { + /** Duration(in hours) to ban a player. If not provided, the player will be banned permanently. */ + BanDurationHours?: number; + /** Reason to ban a player */ + BanReason?: string; + + } + + export interface BanPlayerSegmentAction { + /** Ban hours duration. */ + BanHours?: number; + /** Reason for ban. */ + ReasonForBan?: string; + + } + + export interface BanRequest { + /** The duration in hours for the ban. Leave this blank for a permanent ban. */ + DurationInHours?: number; + /** IP address to be banned. May affect multiple players. */ IPAddress?: string; - /** - / MAC address to be banned. May affect multiple players. - */ - MACAddress?: string; - /** - / The reason for this ban. Maximum 140 characters. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The reason for this ban. Maximum 140 characters. */ Reason?: string; - /** - / The duration in hours for the ban. Leave this blank for a permanent ban. - */ - DurationInHours?: number; + /** The family type of the user that should be included in the ban if applicable. May affect multiple players. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanUsersRequest - */ export interface BanUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of ban requests to be applied. Maximum 100. - */ + /** List of ban requests to be applied. Maximum 100. */ Bans: BanRequest[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanUsersResult - */ export interface BanUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were applied - */ + /** Information on the bans that were applied */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BlankResult - */ export interface BlankResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItem - */ export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - CustomData?: string; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the consumable properties (number of uses, timeout) for the item - */ - Consumable?: CatalogItemConsumableInfo; - /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API - */ - Container?: CatalogItemContainerInfo; - /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies - */ - Bundle?: CatalogItemBundleInfo; - /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ UsagePeriod?: number; /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ UsagePeriodGroup?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemContainerInfo - */ export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ KeyItemId?: string; /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptFile - */ + export interface CheckLimitedEditionItemAvailabilityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Which catalog is being updated. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The item to check for. */ + ItemId: string; + + } + + export interface CheckLimitedEditionItemAvailabilityResult extends PlayFabModule.IPlayFabResultCommon { + /** The amount of the specified resource remaining. */ + Amount: number; + + } + + export interface ChurnPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; + + } + + type ChurnRiskLevel = "NoData" + + | "LowRisk" + | "MediumRisk" + | "HighRisk"; + export interface CloudScriptFile { + /** Contents of the Cloud Script javascript. Must be string-escaped javascript. */ + FileContents: string; /** - / Name of the javascript file. These names are not used internally by the server, they are only for developer organizational purposes. + * Name of the javascript file. These names are not used internally by the server, they are only for developer + * organizational purposes. */ Filename: string; - /** - / Contents of the Cloud Script javascript. Must be string-escaped javascript. - */ - FileContents: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptTaskParameter - */ export interface CloudScriptTaskParameter { - /** - / Name of the CloudScript function to execute. - */ - FunctionName?: string; - /** - / Argument to pass to the CloudScript function. - */ + /** Argument to pass to the CloudScript function. */ Argument?: any; + /** Name of the CloudScript function to execute. */ + FunctionName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptTaskSummary - */ export interface CloudScriptTaskSummary { - /** - / ID of the task instance. - */ - TaskInstanceId?: string; - /** - / Identifier of the task this instance belongs to. - */ - TaskIdentifier?: NameIdentifier; - /** - / UTC timestamp when the task started. - */ - StartedAt: string; - /** - / UTC timestamp when the task completed. - */ + /** UTC timestamp when the task completed. */ CompletedAt?: string; - /** - / Current status of the task instance. - */ - Status?: string; - /** - / Progress represented as percentage. - */ - PercentComplete?: number; - /** - / Estimated time remaining in seconds. - */ + /** Estimated time remaining in seconds. */ EstimatedSecondsRemaining?: number; - /** - / If manually scheduled, ID of user who scheduled the task. - */ - ScheduledByUserId?: string; - /** - / Result of CloudScript execution - */ + /** Progress represented as percentage. */ + PercentComplete?: number; + /** Result of CloudScript execution */ Result?: ExecuteCloudScriptResult; + /** If manually scheduled, ID of user who scheduled the task. */ + ScheduledByUserId?: string; + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptVersionStatus - */ export interface CloudScriptVersionStatus { - /** - / Version number - */ - Version: number; - /** - / Published code revision for this Cloud Script version - */ - PublishedRevision: number; - /** - / Most recent revision for this Cloud Script version - */ + /** Most recent revision for this Cloud Script version */ LatestRevision: number; + /** Published code revision for this Cloud Script version */ + PublishedRevision: number; + /** Version number */ + Version: number; + + } + + type Conditionals = "Any" + + | "True" + | "False"; + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ContentInfo - */ export interface ContentInfo { - /** - / Key of the content - */ + /** Key of the content */ Key?: string; - /** - / Size of the content in bytes - */ - Size: number; - /** - / Last modified time - */ + /** Last modified time */ LastModified: string; + /** Size of the content in bytes */ + Size: number; } type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1333,104 +1418,153 @@ declare module PlayFabAdminModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateActionsOnPlayerSegmentTaskRequest - */ export interface CreateActionsOnPlayerSegmentTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ - Name: string; - /** - / Description the task - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ - Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ IsActive: boolean; - /** - / Task details related to segment and action - */ + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** Task details related to segment and action */ Parameter: ActionsOnPlayersInSegmentTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateCloudScriptTaskRequest - */ export interface CreateCloudScriptTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ + Description?: string; + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ Name: string; - /** - / Description the task - */ + /** Task details related to CloudScript */ + Parameter: CloudScriptTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; + + } + + export interface CreateInsightsScheduledScalingTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** Task details related to Insights Scaling */ + Parameter: InsightsScalingTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ Schedule?: string; + + } + + export interface CreateIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. + * The UTC date and time when the IP ban expires. Leave this blank for a permanent ban. Must be later than the current time + * and no more than 100 years in the future. */ - IsActive: boolean; + Expires?: string; + /** The IP address to be banned. */ + IPAddress: string; + /** The reason for the IP ban. Maximum 140 characters. */ + Reason?: string; + + } + + export interface CreateIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was created */ + IPBanData?: IPBanInfo; + + } + + export interface CreateOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The client ID given by the ID provider. */ + ClientId: string; + /** The client secret given by the ID provider. */ + ClientSecret: string; + /** A name for the connection that identifies it within the title. */ + ConnectionId: string; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; /** - / Task details related to CloudScript + * The discovery document URL to read issuer information from. This must be the absolute URL to the JSON OpenId + * Configuration document and must be accessible from the internet. If you don't know it, try your issuer URL followed by + * "/.well-known/openid-configuration". For example, if the issuer is https://example.com, try + * https://example.com/.well-known/openid-configuration */ - Parameter: CloudScriptTaskParameter; + IssuerDiscoveryUrl?: string; + /** Manually specified information for an OpenID Connect issuer. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; + + } + + export interface CreatePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Friendly name for this key */ + FriendlyName?: string; + + } + + export interface CreatePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SecretKey?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreatePlayerStatisticDefinitionRequest - */ export interface CreatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName: string; - /** - / interval at which the values of the statistic for all players are reset (resets begin at the next interval boundary) - */ + /** interval at which the values of the statistic for all players are reset (resets begin at the next interval boundary) */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreatePlayerStatisticDefinitionResult - */ export interface CreatePlayerStatisticDefinitionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / created statistic definition - */ + /** created statistic definition */ Statistic?: PlayerStatisticDefinition; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateTaskResult - */ + export interface CreateSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment model with all of the segment properties data. */ + SegmentModel: SegmentModel; + + } + + export interface CreateSegmentResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** Segment id. */ + SegmentId?: string; + + } + export interface CreateTaskResult extends PlayFabModule.IPlayFabResultCommon { - /** - / ID of the task - */ + /** ID of the task */ TaskId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1593,1271 +1727,2214 @@ declare module PlayFabAdminModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteContentRequest - */ + export interface CustomPropertyBooleanSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property boolean value. */ + PropertyValue: boolean; + + } + + export interface CustomPropertyDateTimeSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property datetime value. */ + PropertyValue: string; + + } + + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; + + } + + export interface CustomPropertyNumericSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property numeric value. */ + PropertyValue: number; + + } + + export interface CustomPropertyStringSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property string value. */ + PropertyValue?: string; + + } + export interface DeleteContentRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to be deleted - */ + /** Key of the content item to be deleted */ Key: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteStoreRequest - */ - export interface DeleteStoreRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version of the store to delete. If null, uses the default catalog. - */ - CatalogVersion?: string; - /** - / unqiue identifier for the store which is to be deleted - */ - StoreId: string; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteStoreResult - */ - export interface DeleteStoreResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteInventoryItemsV2SegmentAction { + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteTaskRequest - */ - export interface DeleteTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specify either the task ID or the name of task to be deleted. - */ - Identifier?: NameIdentifier; + export interface DeleteInventoryItemV2Content { + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteUsersRequest - */ - export interface DeleteUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabIds: string[]; + export interface DeleteMasterPlayerAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Developer created string to identify a user without PlayFab ID */ + MetaData?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface DeleteMasterPlayerAccountResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * A notification email with this job receipt Id will be sent to the title notification email address when deletion is + * complete. */ - TitleId: string; + JobReceiptId?: string; + /** List of titles from which the player's data will be deleted. */ + TitleIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteUsersResult - */ - export interface DeleteUsersResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteMasterPlayerEventDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - type EffectType = "Allow" - | "Deny"; + export interface DeleteMasterPlayerEventDataResult extends PlayFabModule.IPlayFabResultCommon { + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.EmptyResult - */ - export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteMembershipSubscriptionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the membership to apply the override expiration date to. */ + MembershipId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Id of the subscription that should be deleted from the membership. */ + SubscriptionId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ExecuteCloudScriptResult - */ - export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ - FunctionName?: string; - /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any - */ - FunctionResult?: any; - /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. - */ - Logs?: LogStatement[]; - ExecutionTimeSeconds: number; - /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. - */ - ProcessorTimeSeconds: number; - MemoryConsumedBytes: number; - /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; + export interface DeleteMembershipSubscriptionResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** unique name of the connection */ + ConnectionId: string; + + } + + export interface DeletePlayerContent { + + } + + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Number of external HTTP requests issued by the CloudScript function + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - HttpRequestsIssued: number; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; + /** PlayFab unique identifier of the user whose properties were deleted. */ + PlayFabId?: string; /** - / Information about the error, if any, that occured during execution + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Error?: ScriptExecutionError; + PropertiesVersion: number; + + } + + export interface DeletePlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface DeletePlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePlayerSegmentAction { + + } + + export interface DeletePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The shared secret key to delete */ + SecretKey?: string; + + } + + export interface DeletePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePlayerStatisticSegmentAction { + /** Statistic name. */ + StatisticName?: string; + + } + + export interface DeleteSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment id. */ + SegmentId: string; + + } + + export interface DeleteSegmentsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + + } + + export interface DeleteStoreRequest extends PlayFabModule.IPlayFabRequestCommon { + /** catalog version of the store to delete. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unqiue identifier for the store which is to be deleted */ + StoreId: string; + + } + + export interface DeleteStoreResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specify either the task ID or the name of task to be deleted. */ + Identifier?: NameIdentifier; + + } + + export interface DeleteTitleDataOverrideRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Name of the override. */ + OverrideLabel: string; + + } + + export interface DeleteTitleDataOverrideResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface DeleteTitleResult extends PlayFabModule.IPlayFabResultCommon { + + } + + type EffectType = "Allow" + + | "Deny"; + + export interface EmailNotificationSegmentAction { + /** Email template id. */ + EmailTemplateId?: string; + /** Email template name. */ + EmailTemplateName?: string; + + } + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; } - type GameBuildStatus = "Available" - | "Validating" - | "InvalidBuildPackage" - | "Processing" - | "FailedToProcess"; + export interface ExecuteAzureFunctionSegmentAction { + /** Azure function. */ + AzureFunction?: string; + /** Azure function parameter. */ + FunctionParameter?: any; + /** Generate play stream event. */ + GenerateFunctionExecutedEvents: boolean; + + } + + export interface ExecuteCloudScriptContent { + /** Arguments(JSON) to be passed into the cloudscript method */ + CloudScriptMethodArguments: string; + /** Cloudscript method name */ + CloudScriptMethodName: string; + /** Publish cloudscript results as playstream event */ + PublishResultsToPlayStream: boolean; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GameModeInfo - */ - export interface GameModeInfo { + export interface ExecuteCloudScriptResult { + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / specific game mode type + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - Gamemode: string; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / minimum user count required for this Game Server Instance to continue (usually 1) + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ - MinPlayerCount: number; + Logs?: LogStatement[]; /** - / maximum user count a specific Game Server Instance can support + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - MaxPlayerCount: number; + LogsTooLarge?: boolean; + MemoryConsumedBytes: number; /** - / whether to start as an open session, meaning that players can matchmake into it (defaults to true) + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - StartOpen?: boolean; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetActionGroupResult - */ - export interface GetActionGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Action Group name - */ - Name: string; + export interface ExecuteCloudScriptSegmentAction { + /** Cloud script function. */ + CloudScriptFunction?: string; + /** Generate play stream event. */ + CloudScriptPublishResultsToPlayStream: boolean; + /** Cloud script function parameter. */ + FunctionParameter?: any; + /** Cloud script function parameter json text. */ + FunctionParameterJson?: string; + + } + + export interface ExecuteFunctionContent { + /** Arguments(JSON) to be passed into the cloudscript azure function */ + CloudScriptFunctionArguments: string; + /** Cloudscript azure function name */ + CloudScriptFunctionName: string; + /** Publish results from executing the azure function as playstream event */ + PublishResultsToPlayStream: boolean; + + } + + export interface ExportMasterPlayerDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface ExportMasterPlayerDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Action Group ID + * An email with this job receipt Id containing the export download link will be sent to the title notification email + * address when the export is complete. */ - Id?: string; + JobReceiptId?: string; + + } + + export interface ExportPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the requested segment. */ + SegmentId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetActionsOnPlayersInSegmentTaskInstanceResult - */ + export interface ExportPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId?: string; + /** Unique identifier of the requested Segment. */ + SegmentId?: string; + + } + + export interface FirstLoginDateSegmentFilter { + /** First player login date comparison. */ + Comparison?: string; + /** First player login date. */ + LogInDate: string; + + } + + export interface FirstLoginTimespanSegmentFilter { + /** First player login duration comparison. */ + Comparison?: string; + /** First player login duration. */ + DurationInMinutes: number; + + } + + type GenericErrorCodes = "Success" + + | "UnkownError" + | "InvalidParams" + | "AccountNotFound" + | "AccountBanned" + | "InvalidUsernameOrPassword" + | "InvalidTitleId" + | "InvalidEmailAddress" + | "EmailAddressNotAvailable" + | "InvalidUsername" + | "InvalidPassword" + | "UsernameNotAvailable" + | "InvalidSteamTicket" + | "AccountAlreadyLinked" + | "LinkedAccountAlreadyClaimed" + | "InvalidFacebookToken" + | "AccountNotLinked" + | "FailedByPaymentProvider" + | "CouponCodeNotFound" + | "InvalidContainerItem" + | "ContainerNotOwned" + | "KeyNotOwned" + | "InvalidItemIdInTable" + | "InvalidReceipt" + | "ReceiptAlreadyUsed" + | "ReceiptCancelled" + | "GameNotFound" + | "GameModeNotFound" + | "InvalidGoogleToken" + | "UserIsNotPartOfDeveloper" + | "InvalidTitleForDeveloper" + | "TitleNameConflicts" + | "UserisNotValid" + | "ValueAlreadyExists" + | "BuildNotFound" + | "PlayerNotInGame" + | "InvalidTicket" + | "InvalidDeveloper" + | "InvalidOrderInfo" + | "RegistrationIncomplete" + | "InvalidPlatform" + | "UnknownError" + | "SteamApplicationNotOwned" + | "WrongSteamAccount" + | "TitleNotActivated" + | "RegistrationSessionNotFound" + | "NoSuchMod" + | "FileNotFound" + | "DuplicateEmail" + | "ItemNotFound" + | "ItemNotOwned" + | "ItemNotRecycleable" + | "ItemNotAffordable" + | "InvalidVirtualCurrency" + | "WrongVirtualCurrency" + | "WrongPrice" + | "NonPositiveValue" + | "InvalidRegion" + | "RegionAtCapacity" + | "ServerFailedToStart" + | "NameNotAvailable" + | "InsufficientFunds" + | "InvalidDeviceID" + | "InvalidPushNotificationToken" + | "NoRemainingUses" + | "InvalidPaymentProvider" + | "PurchaseInitializationFailure" + | "DuplicateUsername" + | "InvalidBuyerInfo" + | "NoGameModeParamsSet" + | "BodyTooLarge" + | "ReservedWordInBody" + | "InvalidTypeInBody" + | "InvalidRequest" + | "ReservedEventName" + | "InvalidUserStatistics" + | "NotAuthenticated" + | "StreamAlreadyExists" + | "ErrorCreatingStream" + | "StreamNotFound" + | "InvalidAccount" + | "PurchaseDoesNotExist" + | "InvalidPurchaseTransactionStatus" + | "APINotEnabledForGameClientAccess" + | "NoPushNotificationARNForTitle" + | "BuildAlreadyExists" + | "BuildPackageDoesNotExist" + | "CustomAnalyticsEventsNotEnabledForTitle" + | "InvalidSharedGroupId" + | "NotAuthorized" + | "MissingTitleGoogleProperties" + | "InvalidItemProperties" + | "InvalidPSNAuthCode" + | "InvalidItemId" + | "PushNotEnabledForAccount" + | "PushServiceError" + | "ReceiptDoesNotContainInAppItems" + | "ReceiptContainsMultipleInAppItems" + | "InvalidBundleID" + | "JavascriptException" + | "InvalidSessionTicket" + | "UnableToConnectToDatabase" + | "InternalServerError" + | "InvalidReportDate" + | "DatabaseThroughputExceeded" + | "InvalidGameTicket" + | "ExpiredGameTicket" + | "GameTicketDoesNotMatchLobby" + | "LinkedDeviceAlreadyClaimed" + | "DeviceAlreadyLinked" + | "DeviceNotLinked" + | "PartialFailure" + | "PublisherNotSet" + | "ServiceUnavailable" + | "VersionNotFound" + | "RevisionNotFound" + | "InvalidPublisherId" + | "DownstreamServiceUnavailable" + | "APINotIncludedInTitleUsageTier" + | "DAULimitExceeded" + | "APIRequestLimitExceeded" + | "InvalidAPIEndpoint" + | "BuildNotAvailable" + | "ConcurrentEditError" + | "ContentNotFound" + | "CharacterNotFound" + | "CloudScriptNotFound" + | "ContentQuotaExceeded" + | "InvalidCharacterStatistics" + | "PhotonNotEnabledForTitle" + | "PhotonApplicationNotFound" + | "PhotonApplicationNotAssociatedWithTitle" + | "InvalidEmailOrPassword" + | "FacebookAPIError" + | "InvalidContentType" + | "KeyLengthExceeded" + | "DataLengthExceeded" + | "TooManyKeys" + | "FreeTierCannotHaveVirtualCurrency" + | "MissingAmazonSharedKey" + | "AmazonValidationError" + | "InvalidPSNIssuerId" + | "PSNInaccessible" + | "ExpiredAuthToken" + | "FailedToGetEntitlements" + | "FailedToConsumeEntitlement" + | "TradeAcceptingUserNotAllowed" + | "TradeInventoryItemIsAssignedToCharacter" + | "TradeInventoryItemIsBundle" + | "TradeStatusNotValidForCancelling" + | "TradeStatusNotValidForAccepting" + | "TradeDoesNotExist" + | "TradeCancelled" + | "TradeAlreadyFilled" + | "TradeWaitForStatusTimeout" + | "TradeInventoryItemExpired" + | "TradeMissingOfferedAndAcceptedItems" + | "TradeAcceptedItemIsBundle" + | "TradeAcceptedItemIsStackable" + | "TradeInventoryItemInvalidStatus" + | "TradeAcceptedCatalogItemInvalid" + | "TradeAllowedUsersInvalid" + | "TradeInventoryItemDoesNotExist" + | "TradeInventoryItemIsConsumed" + | "TradeInventoryItemIsStackable" + | "TradeAcceptedItemsMismatch" + | "InvalidKongregateToken" + | "FeatureNotConfiguredForTitle" + | "NoMatchingCatalogItemForReceipt" + | "InvalidCurrencyCode" + | "NoRealMoneyPriceForCatalogItem" + | "TradeInventoryItemIsNotTradable" + | "TradeAcceptedCatalogItemIsNotTradable" + | "UsersAlreadyFriends" + | "LinkedIdentifierAlreadyClaimed" + | "CustomIdNotLinked" + | "TotalDataSizeExceeded" + | "DeleteKeyConflict" + | "InvalidXboxLiveToken" + | "ExpiredXboxLiveToken" + | "ResettableStatisticVersionRequired" + | "NotAuthorizedByTitle" + | "NoPartnerEnabled" + | "InvalidPartnerResponse" + | "APINotEnabledForGameServerAccess" + | "StatisticNotFound" + | "StatisticNameConflict" + | "StatisticVersionClosedForWrites" + | "StatisticVersionInvalid" + | "APIClientRequestRateLimitExceeded" + | "InvalidJSONContent" + | "InvalidDropTable" + | "StatisticVersionAlreadyIncrementedForScheduledInterval" + | "StatisticCountLimitExceeded" + | "StatisticVersionIncrementRateExceeded" + | "ContainerKeyInvalid" + | "CloudScriptExecutionTimeLimitExceeded" + | "NoWritePermissionsForEvent" + | "CloudScriptFunctionArgumentSizeExceeded" + | "CloudScriptAPIRequestCountExceeded" + | "CloudScriptAPIRequestError" + | "CloudScriptHTTPRequestError" + | "InsufficientGuildRole" + | "GuildNotFound" + | "OverLimit" + | "EventNotFound" + | "InvalidEventField" + | "InvalidEventName" + | "CatalogNotConfigured" + | "OperationNotSupportedForPlatform" + | "SegmentNotFound" + | "StoreNotFound" + | "InvalidStatisticName" + | "TitleNotQualifiedForLimit" + | "InvalidServiceLimitLevel" + | "ServiceLimitLevelInTransition" + | "CouponAlreadyRedeemed" + | "GameServerBuildSizeLimitExceeded" + | "GameServerBuildCountLimitExceeded" + | "VirtualCurrencyCountLimitExceeded" + | "VirtualCurrencyCodeExists" + | "TitleNewsItemCountLimitExceeded" + | "InvalidTwitchToken" + | "TwitchResponseError" + | "ProfaneDisplayName" + | "UserAlreadyAdded" + | "InvalidVirtualCurrencyCode" + | "VirtualCurrencyCannotBeDeleted" + | "IdentifierAlreadyClaimed" + | "IdentifierNotLinked" + | "InvalidContinuationToken" + | "ExpiredContinuationToken" + | "InvalidSegment" + | "InvalidSessionId" + | "SessionLogNotFound" + | "InvalidSearchTerm" + | "TwoFactorAuthenticationTokenRequired" + | "GameServerHostCountLimitExceeded" + | "PlayerTagCountLimitExceeded" + | "RequestAlreadyRunning" + | "ActionGroupNotFound" + | "MaximumSegmentBulkActionJobsRunning" + | "NoActionsOnPlayersInSegmentJob" + | "DuplicateStatisticName" + | "ScheduledTaskNameConflict" + | "ScheduledTaskCreateConflict" + | "InvalidScheduledTaskName" + | "InvalidTaskSchedule" + | "SteamNotEnabledForTitle" + | "LimitNotAnUpgradeOption" + | "NoSecretKeyEnabledForCloudScript" + | "TaskNotFound" + | "TaskInstanceNotFound" + | "InvalidIdentityProviderId" + | "MisconfiguredIdentityProvider" + | "InvalidScheduledTaskType" + | "BillingInformationRequired" + | "LimitedEditionItemUnavailable" + | "InvalidAdPlacementAndReward" + | "AllAdPlacementViewsAlreadyConsumed" + | "GoogleOAuthNotConfiguredForTitle" + | "GoogleOAuthError" + | "UserNotFriend" + | "InvalidSignature" + | "InvalidPublicKey" + | "GoogleOAuthNoIdTokenIncludedInResponse" + | "StatisticUpdateInProgress" + | "LeaderboardVersionNotAvailable" + | "StatisticAlreadyHasPrizeTable" + | "PrizeTableHasOverlappingRanks" + | "PrizeTableHasMissingRanks" + | "PrizeTableRankStartsAtZero" + | "InvalidStatistic" + | "ExpressionParseFailure" + | "ExpressionInvokeFailure" + | "ExpressionTooLong" + | "DataUpdateRateExceeded" + | "RestrictedEmailDomain" + | "EncryptionKeyDisabled" + | "EncryptionKeyMissing" + | "EncryptionKeyBroken" + | "NoSharedSecretKeyConfigured" + | "SecretKeyNotFound" + | "PlayerSecretAlreadyConfigured" + | "APIRequestsDisabledForTitle" + | "InvalidSharedSecretKey" + | "PrizeTableHasNoRanks" + | "ProfileDoesNotExist" + | "ContentS3OriginBucketNotConfigured" + | "InvalidEnvironmentForReceipt" + | "EncryptedRequestNotAllowed" + | "SignedRequestNotAllowed" + | "RequestViewConstraintParamsNotAllowed" + | "BadPartnerConfiguration" + | "XboxBPCertificateFailure" + | "XboxXASSExchangeFailure" + | "InvalidEntityId" + | "StatisticValueAggregationOverflow" + | "EmailMessageFromAddressIsMissing" + | "EmailMessageToAddressIsMissing" + | "SmtpServerAuthenticationError" + | "SmtpServerLimitExceeded" + | "SmtpServerInsufficientStorage" + | "SmtpServerCommunicationError" + | "SmtpServerGeneralFailure" + | "EmailClientTimeout" + | "EmailClientCanceledTask" + | "EmailTemplateMissing" + | "InvalidHostForTitleId" + | "EmailConfirmationTokenDoesNotExist" + | "EmailConfirmationTokenExpired" + | "AccountDeleted" + | "PlayerSecretNotConfigured" + | "InvalidSignatureTime" + | "NoContactEmailAddressFound" + | "InvalidAuthToken" + | "AuthTokenDoesNotExist" + | "AuthTokenExpired" + | "AuthTokenAlreadyUsedToResetPassword" + | "MembershipNameTooLong" + | "MembershipNotFound" + | "GoogleServiceAccountInvalid" + | "GoogleServiceAccountParseFailure" + | "EntityTokenMissing" + | "EntityTokenInvalid" + | "EntityTokenExpired" + | "EntityTokenRevoked" + | "InvalidProductForSubscription" + | "XboxInaccessible" + | "SubscriptionAlreadyTaken" + | "SmtpAddonNotEnabled" + | "APIConcurrentRequestLimitExceeded" + | "XboxRejectedXSTSExchangeRequest" + | "VariableNotDefined" + | "TemplateVersionNotDefined" + | "FileTooLarge" + | "TitleDeleted" + | "TitleContainsUserAccounts" + | "TitleDeletionPlayerCleanupFailure" + | "EntityFileOperationPending" + | "NoEntityFileOperationPending" + | "EntityProfileVersionMismatch" + | "TemplateVersionTooOld" + | "MembershipDefinitionInUse" + | "PaymentPageNotConfigured" + | "FailedLoginAttemptRateLimitExceeded" + | "EntityBlockedByGroup" + | "RoleDoesNotExist" + | "EntityIsAlreadyMember" + | "DuplicateRoleId" + | "GroupInvitationNotFound" + | "GroupApplicationNotFound" + | "OutstandingInvitationAcceptedInstead" + | "OutstandingApplicationAcceptedInstead" + | "RoleIsGroupDefaultMember" + | "RoleIsGroupAdmin" + | "RoleNameNotAvailable" + | "GroupNameNotAvailable" + | "EmailReportAlreadySent" + | "EmailReportRecipientBlacklisted" + | "EventNamespaceNotAllowed" + | "EventEntityNotAllowed" + | "InvalidEntityType" + | "NullTokenResultFromAad" + | "InvalidTokenResultFromAad" + | "NoValidCertificateForAad" + | "InvalidCertificateForAad" + | "DuplicateDropTableId" + | "MultiplayerServerError" + | "MultiplayerServerTooManyRequests" + | "MultiplayerServerNoContent" + | "MultiplayerServerBadRequest" + | "MultiplayerServerUnauthorized" + | "MultiplayerServerForbidden" + | "MultiplayerServerNotFound" + | "MultiplayerServerConflict" + | "MultiplayerServerInternalServerError" + | "MultiplayerServerUnavailable" + | "ExplicitContentDetected" + | "PIIContentDetected" + | "InvalidScheduledTaskParameter" + | "PerEntityEventRateLimitExceeded" + | "TitleDefaultLanguageNotSet" + | "EmailTemplateMissingDefaultVersion" + | "FacebookInstantGamesIdNotLinked" + | "InvalidFacebookInstantGamesSignature" + | "FacebookInstantGamesAuthNotConfiguredForTitle" + | "EntityProfileConstraintValidationFailed" + | "TelemetryIngestionKeyPending" + | "TelemetryIngestionKeyNotFound" + | "StatisticChildNameInvalid" + | "DataIntegrityError" + | "VirtualCurrencyCannotBeSetToOlderVersion" + | "VirtualCurrencyMustBeWithinIntegerRange" + | "EmailTemplateInvalidSyntax" + | "EmailTemplateMissingCallback" + | "PushNotificationTemplateInvalidPayload" + | "InvalidLocalizedPushNotificationLanguage" + | "MissingLocalizedPushNotificationMessage" + | "PushNotificationTemplateMissingPlatformPayload" + | "PushNotificationTemplatePayloadContainsInvalidJson" + | "PushNotificationTemplateContainsInvalidIosPayload" + | "PushNotificationTemplateContainsInvalidAndroidPayload" + | "PushNotificationTemplateIosPayloadMissingNotificationBody" + | "PushNotificationTemplateAndroidPayloadMissingNotificationBody" + | "PushNotificationTemplateNotFound" + | "PushNotificationTemplateMissingDefaultVersion" + | "PushNotificationTemplateInvalidSyntax" + | "PushNotificationTemplateNoCustomPayloadForV1" + | "NoLeaderboardForStatistic" + | "TitleNewsMissingDefaultLanguage" + | "TitleNewsNotFound" + | "TitleNewsDuplicateLanguage" + | "TitleNewsMissingTitleOrBody" + | "TitleNewsInvalidLanguage" + | "EmailRecipientBlacklisted" + | "InvalidGameCenterAuthRequest" + | "GameCenterAuthenticationFailed" + | "CannotEnablePartiesForTitle" + | "PartyError" + | "PartyRequests" + | "PartyNoContent" + | "PartyBadRequest" + | "PartyUnauthorized" + | "PartyForbidden" + | "PartyNotFound" + | "PartyConflict" + | "PartyInternalServerError" + | "PartyUnavailable" + | "PartyTooManyRequests" + | "PushNotificationTemplateMissingName" + | "CannotEnableMultiplayerServersForTitle" + | "WriteAttemptedDuringExport" + | "MultiplayerServerTitleQuotaCoresExceeded" + | "AutomationRuleNotFound" + | "EntityAPIKeyLimitExceeded" + | "EntityAPIKeyNotFound" + | "EntityAPIKeyOrSecretInvalid" + | "EconomyServiceUnavailable" + | "EconomyServiceInternalError" + | "QueryRateLimitExceeded" + | "EntityAPIKeyCreationDisabledForEntity" + | "ForbiddenByEntityPolicy" + | "UpdateInventoryRateLimitExceeded" + | "StudioCreationRateLimited" + | "StudioCreationInProgress" + | "DuplicateStudioName" + | "StudioNotFound" + | "StudioDeleted" + | "StudioDeactivated" + | "StudioActivated" + | "TitleCreationRateLimited" + | "TitleCreationInProgress" + | "DuplicateTitleName" + | "TitleActivationRateLimited" + | "TitleActivationInProgress" + | "TitleDeactivated" + | "TitleActivated" + | "CloudScriptAzureFunctionsExecutionTimeLimitExceeded" + | "CloudScriptAzureFunctionsArgumentSizeExceeded" + | "CloudScriptAzureFunctionsReturnSizeExceeded" + | "CloudScriptAzureFunctionsHTTPRequestError" + | "VirtualCurrencyBetaGetError" + | "VirtualCurrencyBetaCreateError" + | "VirtualCurrencyBetaInitialDepositSaveError" + | "VirtualCurrencyBetaSaveError" + | "VirtualCurrencyBetaDeleteError" + | "VirtualCurrencyBetaRestoreError" + | "VirtualCurrencyBetaSaveConflict" + | "VirtualCurrencyBetaUpdateError" + | "InsightsManagementDatabaseNotFound" + | "InsightsManagementOperationNotFound" + | "InsightsManagementErrorPendingOperationExists" + | "InsightsManagementSetPerformanceLevelInvalidParameter" + | "InsightsManagementSetStorageRetentionInvalidParameter" + | "InsightsManagementGetStorageUsageInvalidParameter" + | "InsightsManagementGetOperationStatusInvalidParameter" + | "DuplicatePurchaseTransactionId" + | "EvaluationModePlayerCountExceeded" + | "CloudScriptFunctionNameSizeExceeded" + | "PaidInsightsFeaturesNotEnabled" + | "CloudScriptAzureFunctionsQueueRequestError" + | "EvaluationModeTitleCountExceeded" + | "InsightsManagementTitleNotInFlight" + | "LimitNotFound" + | "LimitNotAvailableViaAPI" + | "InsightsManagementSetStorageRetentionBelowMinimum" + | "InsightsManagementSetStorageRetentionAboveMaximum" + | "AppleNotEnabledForTitle" + | "InsightsManagementNewActiveEventExportLimitInvalid" + | "InsightsManagementSetPerformanceRateLimited" + | "PartyRequestsThrottledFromRateLimiter" + | "XboxServiceTooManyRequests" + | "NintendoSwitchNotEnabledForTitle" + | "RequestMultiplayerServersThrottledFromRateLimiter" + | "TitleDataOverrideNotFound" + | "DuplicateKeys" + | "WasNotCreatedWithCloudRoot" + | "LegacyMultiplayerServersDeprecated" + | "VirtualCurrencyCurrentlyUnavailable" + | "SteamUserNotFound" + | "ElasticSearchOperationFailed" + | "NotImplemented" + | "PublisherNotFound" + | "PublisherDeleted" + | "ApiDisabledForMigration" + | "ResourceNameUpdateNotAllowed" + | "ApiNotEnabledForTitle" + | "DuplicateTitleNameForPublisher" + | "AzureTitleCreationInProgress" + | "TitleConstraintsPublisherDeletion" + | "InvalidPlayerAccountPoolId" + | "PlayerAccountPoolNotFound" + | "PlayerAccountPoolDeleted" + | "TitleCleanupInProgress" + | "AzureResourceConcurrentOperationInProgress" + | "TitlePublisherUpdateNotAllowed" + | "AzureResourceManagerNotSupportedInStamp" + | "ApiNotIncludedInAzurePlayFabFeatureSet" + | "GoogleServiceAccountFailedAuth" + | "GoogleAPIServiceUnavailable" + | "GoogleAPIServiceUnknownError" + | "NoValidIdentityForAad" + | "PlayerIdentityLinkNotFound" + | "PhotonApplicationIdAlreadyInUse" + | "CloudScriptUnableToDeleteProductionRevision" + | "CustomIdNotFound" + | "AutomationInvalidInput" + | "AutomationInvalidRuleName" + | "AutomationRuleAlreadyExists" + | "AutomationRuleLimitExceeded" + | "InvalidGooglePlayGamesServerAuthCode" + | "PlayStreamConnectionFailed" + | "InvalidEventContents" + | "InsightsV1Deprecated" + | "AnalysisSubscriptionNotFound" + | "AnalysisSubscriptionFailed" + | "AnalysisSubscriptionFoundAlready" + | "AnalysisSubscriptionManagementInvalidInput" + | "InvalidGameCenterId" + | "InvalidNintendoSwitchAccountId" + | "EntityAPIKeysNotSupported" + | "IpAddressBanned" + | "EntityLineageBanned" + | "NamespaceMismatch" + | "InvalidServiceConfiguration" + | "InvalidNamespaceMismatch" + | "LeaderboardColumnLengthMismatch" + | "InvalidStatisticScore" + | "LeaderboardColumnsNotSpecified" + | "LeaderboardMaxSizeTooLarge" + | "InvalidAttributeStatisticsSpecified" + | "LeaderboardNotFound" + | "TokenSigningKeyNotFound" + | "LeaderboardNameConflict" + | "LinkedStatisticColumnMismatch" + | "NoLinkedStatisticToLeaderboard" + | "StatDefinitionAlreadyLinkedToLeaderboard" + | "LinkingStatsNotAllowedForEntityType" + | "LeaderboardCountLimitExceeded" + | "LeaderboardSizeLimitExceeded" + | "LeaderboardDefinitionModificationNotAllowedWhileLinked" + | "StatisticDefinitionModificationNotAllowedWhileLinked" + | "LeaderboardUpdateNotAllowedWhileLinked" + | "CloudScriptAzureFunctionsEventHubRequestError" + | "ExternalEntityNotAllowedForTier" + | "InvalidBaseTimeForInterval" + | "EntityTypeMismatchWithStatDefinition" + | "SpecifiedVersionLeaderboardNotFound" + | "LeaderboardColumnLengthMismatchWithStatDefinition" + | "DuplicateColumnNameFound" + | "LinkedStatisticColumnNotFound" + | "LinkedStatisticColumnRequired" + | "MultipleLinkedStatisticsNotAllowed" + | "DuplicateLinkedStatisticColumnNameFound" + | "AggregationTypeNotAllowedForMultiColumnStatistic" + | "MaxQueryableVersionsValueNotAllowedForTier" + | "StatisticDefinitionHasNullOrEmptyVersionConfiguration" + | "StatisticColumnLengthMismatch" + | "InvalidExternalEntityId" + | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" + | "ResetIntervalCannotBeModified" + | "VersionIncrementRateExceeded" + | "InvalidSteamUsername" + | "InvalidVersionResetForLinkedLeaderboard" + | "BattleNetNotEnabledForTitle" + | "ReportNotProcessed" + | "DataNotAvailable" + | "InvalidReportName" + | "ResourceNotModified" + | "StudioCreationLimitExceeded" + | "StudioDeletionInitiated" + | "ProductDisabledForTitle" + | "PreconditionFailed" + | "CannotEnableAnonymousPlayerCreation" + | "ParentCustomerAccountNotFound" + | "AccountLinkedToABannedPlayer" + | "AzureSubscriptionNotEligibleForLinking" + | "EntityIsNotAMember" + | "IPAddressNotFound" + | "PSNNextGenNotConfiguredForTitle" + | "InvalidNintendoIssuer" + | "MatchmakingEntityInvalid" + | "MatchmakingPlayerAttributesInvalid" + | "MatchmakingQueueNotFound" + | "MatchmakingMatchNotFound" + | "MatchmakingTicketNotFound" + | "MatchmakingAlreadyJoinedTicket" + | "MatchmakingTicketAlreadyCompleted" + | "MatchmakingQueueConfigInvalid" + | "MatchmakingMemberProfileInvalid" + | "NintendoSwitchDeviceIdNotLinked" + | "MatchmakingNotEnabled" + | "MatchmakingPlayerAttributesTooLarge" + | "MatchmakingNumberOfPlayersInTicketTooLarge" + | "MatchmakingAttributeInvalid" + | "MatchmakingPlayerHasNotJoinedTicket" + | "MatchmakingRateLimitExceeded" + | "MatchmakingTicketMembershipLimitExceeded" + | "MatchmakingUnauthorized" + | "MatchmakingQueueLimitExceeded" + | "MatchmakingRequestTypeMismatch" + | "MatchmakingBadRequest" + | "PubSubFeatureNotEnabledForTitle" + | "PubSubTooManyRequests" + | "PubSubConnectionNotFoundForEntity" + | "PubSubConnectionHandleInvalid" + | "PubSubSubscriptionLimitExceeded" + | "TitleConfigNotFound" + | "TitleConfigUpdateConflict" + | "TitleConfigSerializationError" + | "CatalogApiNotImplemented" + | "CatalogEntityInvalid" + | "CatalogTitleIdMissing" + | "CatalogPlayerIdMissing" + | "CatalogClientIdentityInvalid" + | "CatalogOneOrMoreFilesInvalid" + | "CatalogItemMetadataInvalid" + | "CatalogItemIdInvalid" + | "CatalogSearchParameterInvalid" + | "CatalogFeatureDisabled" + | "CatalogConfigInvalid" + | "CatalogItemTypeInvalid" + | "CatalogBadRequest" + | "CatalogTooManyRequests" + | "InvalidCatalogItemConfiguration" + | "LegacyEconomyDisabled" + | "ExportInvalidStatusUpdate" + | "ExportInvalidPrefix" + | "ExportBlobContainerDoesNotExist" + | "ExportNotFound" + | "ExportCouldNotUpdate" + | "ExportInvalidStorageType" + | "ExportAmazonBucketDoesNotExist" + | "ExportInvalidBlobStorage" + | "ExportKustoException" + | "ExportKustoConnectionFailed" + | "ExportUnknownError" + | "ExportCantEditPendingExport" + | "ExportLimitExports" + | "ExportLimitEvents" + | "ExportInvalidPartitionStatusModification" + | "ExportCouldNotCreate" + | "ExportNoBackingDatabaseFound" + | "ExportCouldNotDelete" + | "ExportCannotDetermineEventQuery" + | "ExportInvalidQuerySchemaModification" + | "ExportQuerySchemaMissingRequiredColumns" + | "ExportCannotParseQuery" + | "ExportControlCommandsNotAllowed" + | "ExportQueryMissingTableReference" + | "ExportInsightsV1Deprecated" + | "ExplorerBasicInvalidQueryName" + | "ExplorerBasicInvalidQueryDescription" + | "ExplorerBasicInvalidQueryConditions" + | "ExplorerBasicInvalidQueryStartDate" + | "ExplorerBasicInvalidQueryEndDate" + | "ExplorerBasicInvalidQueryGroupBy" + | "ExplorerBasicInvalidQueryAggregateType" + | "ExplorerBasicInvalidQueryAggregateProperty" + | "ExplorerBasicLoadQueriesError" + | "ExplorerBasicLoadQueryError" + | "ExplorerBasicCreateQueryError" + | "ExplorerBasicDeleteQueryError" + | "ExplorerBasicUpdateQueryError" + | "ExplorerBasicSavedQueriesLimit" + | "ExplorerBasicSavedQueryNotFound" + | "TenantShardMapperShardNotFound" + | "TitleNotEnabledForParty" + | "PartyVersionNotFound" + | "MultiplayerServerBuildReferencedByMatchmakingQueue" + | "MultiplayerServerBuildReferencedByBuildAlias" + | "MultiplayerServerBuildAliasReferencedByMatchmakingQueue" + | "PartySerializationError" + | "ExperimentationExperimentStopped" + | "ExperimentationExperimentRunning" + | "ExperimentationExperimentNotFound" + | "ExperimentationExperimentNeverStarted" + | "ExperimentationExperimentDeleted" + | "ExperimentationClientTimeout" + | "ExperimentationInvalidVariantConfiguration" + | "ExperimentationInvalidVariableConfiguration" + | "ExperimentInvalidId" + | "ExperimentationNoScorecard" + | "ExperimentationTreatmentAssignmentFailed" + | "ExperimentationTreatmentAssignmentDisabled" + | "ExperimentationInvalidDuration" + | "ExperimentationMaxExperimentsReached" + | "ExperimentationExperimentSchedulingInProgress" + | "ExperimentationInvalidEndDate" + | "ExperimentationInvalidStartDate" + | "ExperimentationMaxDurationExceeded" + | "ExperimentationExclusionGroupNotFound" + | "ExperimentationExclusionGroupInsufficientCapacity" + | "ExperimentationExclusionGroupCannotDelete" + | "ExperimentationExclusionGroupInvalidTrafficAllocation" + | "ExperimentationExclusionGroupInvalidName" + | "ExperimentationLegacyExperimentInvalidOperation" + | "ExperimentationExperimentStopFailed" + | "ExperimentationExperimentDeleteFailed" + | "ExperimentationExperimentStartFailed" + | "MaxActionDepthExceeded" + | "TitleNotOnUpdatedPricingPlan" + | "SegmentManagementTitleNotInFlight" + | "SegmentManagementNoExpressionTree" + | "SegmentManagementTriggerActionCountOverLimit" + | "SegmentManagementSegmentCountOverLimit" + | "SegmentManagementInvalidSegmentId" + | "SegmentManagementInvalidInput" + | "SegmentManagementInvalidSegmentName" + | "DeleteSegmentRateLimitExceeded" + | "CreateSegmentRateLimitExceeded" + | "UpdateSegmentRateLimitExceeded" + | "GetSegmentsRateLimitExceeded" + | "AsyncExportNotInFlight" + | "AsyncExportNotFound" + | "AsyncExportRateLimitExceeded" + | "AnalyticsSegmentCountOverLimit" + | "GetSegmentPlayerCountNotInFlight" + | "GetSegmentPlayerCountRateLimitExceeded" + | "SnapshotNotFound" + | "InventoryApiNotImplemented" + | "InventoryCollectionDeletionDisallowed" + | "LobbyDoesNotExist" + | "LobbyRateLimitExceeded" + | "LobbyPlayerAlreadyJoined" + | "LobbyNotJoinable" + | "LobbyMemberCannotRejoin" + | "LobbyCurrentPlayersMoreThanMaxPlayers" + | "LobbyPlayerNotPresent" + | "LobbyBadRequest" + | "LobbyPlayerMaxLobbyLimitExceeded" + | "LobbyNewOwnerMustBeConnected" + | "LobbyCurrentOwnerStillConnected" + | "LobbyMemberIsNotOwner" + | "LobbyServerMismatch" + | "LobbyServerNotFound" + | "LobbyDifferentServerAlreadyJoined" + | "LobbyServerAlreadyJoined" + | "LobbyIsNotClientOwned" + | "LobbyDoesNotUseConnections" + | "EventSamplingInvalidRatio" + | "EventSamplingInvalidEventNamespace" + | "EventSamplingInvalidEventName" + | "EventSamplingRatioNotFound" + | "TelemetryKeyNotFound" + | "TelemetryKeyInvalidName" + | "TelemetryKeyAlreadyExists" + | "TelemetryKeyInvalid" + | "TelemetryKeyCountOverLimit" + | "TelemetryKeyDeactivated" + | "TelemetryKeyLongInsightsRetentionNotAllowed" + | "EventSinkConnectionInvalid" + | "EventSinkConnectionUnauthorized" + | "EventSinkRegionInvalid" + | "EventSinkLimitExceeded" + | "EventSinkSasTokenInvalid" + | "EventSinkNotFound" + | "EventSinkNameInvalid" + | "EventSinkSasTokenPermissionInvalid" + | "EventSinkSecretInvalid" + | "EventSinkTenantNotFound" + | "EventSinkAadNotFound" + | "EventSinkDatabaseNotFound" + | "EventSinkTitleUnauthorized" + | "EventSinkInsufficientRoleAssignment" + | "EventSinkContainerNotFound" + | "EventSinkTenantIdInvalid" + | "EventSinkResourceMisconfigured" + | "EventSinkAccessDenied" + | "EventSinkWriteConflict" + | "EventSinkResourceNotFound" + | "EventSinkResourceFeatureNotSupported" + | "EventSinkBucketNameInvalid" + | "EventSinkResourceUnavailable" + | "OperationCanceled" + | "InvalidDisplayNameRandomSuffixLength" + | "AllowNonUniquePlayerDisplayNamesDisableNotAllowed" + | "PartitionedEventInvalid" + | "PartitionedEventCountOverLimit" + | "ManageEventNamespaceInvalid" + | "ManageEventNameInvalid" + | "ManagedEventNotFound" + | "ManageEventsInvalidRatio" + | "ManagedEventInvalid" + | "PlayerCustomPropertiesPropertyNameTooLong" + | "PlayerCustomPropertiesPropertyNameIsInvalid" + | "PlayerCustomPropertiesStringPropertyValueTooLong" + | "PlayerCustomPropertiesValueIsInvalidType" + | "PlayerCustomPropertiesVersionMismatch" + | "PlayerCustomPropertiesPropertyCountTooHigh" + | "PlayerCustomPropertiesDuplicatePropertyName" + | "PlayerCustomPropertiesPropertyDoesNotExist" + | "AddonAlreadyExists" + | "AddonDoesntExist" + | "TrueSkillUnauthorized" + | "TrueSkillInvalidTitleId" + | "TrueSkillInvalidScenarioId" + | "TrueSkillInvalidModelId" + | "TrueSkillInvalidModelName" + | "TrueSkillInvalidPlayerIds" + | "TrueSkillInvalidEntityKey" + | "TrueSkillInvalidConditionKey" + | "TrueSkillInvalidConditionValue" + | "TrueSkillInvalidConditionAffinityWeight" + | "TrueSkillInvalidEventName" + | "TrueSkillMatchResultCreated" + | "TrueSkillMatchResultAlreadySubmitted" + | "TrueSkillBadPlayerIdInMatchResult" + | "TrueSkillInvalidBotIdInMatchResult" + | "TrueSkillDuplicatePlayerInMatchResult" + | "TrueSkillNoPlayerInMatchResultTeam" + | "TrueSkillPlayersInMatchResultExceedingLimit" + | "TrueSkillInvalidPreMatchPartyInMatchResult" + | "TrueSkillInvalidTimestampInMatchResult" + | "TrueSkillStartTimeMissingInMatchResult" + | "TrueSkillEndTimeMissingInMatchResult" + | "TrueSkillInvalidPlayerSecondsPlayedInMatchResult" + | "TrueSkillNoTeamInMatchResult" + | "TrueSkillNotEnoughTeamsInMatchResult" + | "TrueSkillInvalidRanksInMatchResult" + | "TrueSkillNoWinnerInMatchResult" + | "TrueSkillMissingRequiredCondition" + | "TrueSkillMissingRequiredEvent" + | "TrueSkillUnknownEventName" + | "TrueSkillInvalidEventCount" + | "TrueSkillUnknownConditionKey" + | "TrueSkillUnknownConditionValue" + | "TrueSkillScenarioConfigDoesNotExist" + | "TrueSkillUnknownModelId" + | "TrueSkillNoModelInScenario" + | "TrueSkillNotSupportedForTitle" + | "TrueSkillModelIsNotActive" + | "TrueSkillUnauthorizedToQueryOtherPlayerSkills" + | "TrueSkillInvalidMaxIterations" + | "TrueSkillEndTimeBeforeStartTime" + | "TrueSkillInvalidJobId" + | "TrueSkillInvalidMetadataId" + | "TrueSkillMissingBuildVerison" + | "TrueSkillJobAlreadyExists" + | "TrueSkillJobNotFound" + | "TrueSkillOperationCanceled" + | "TrueSkillActiveModelLimitExceeded" + | "TrueSkillTotalModelLimitExceeded" + | "TrueSkillUnknownInitialModelId" + | "TrueSkillUnauthorizedForJob" + | "TrueSkillInvalidScenarioName" + | "TrueSkillConditionStateIsRequired" + | "TrueSkillEventStateIsRequired" + | "TrueSkillDuplicateEvent" + | "TrueSkillDuplicateCondition" + | "TrueSkillInvalidAnomalyThreshold" + | "TrueSkillConditionKeyLimitExceeded" + | "TrueSkillConditionValuePerKeyLimitExceeded" + | "TrueSkillInvalidTimestamp" + | "TrueSkillEventLimitExceeded" + | "TrueSkillInvalidPlayers" + | "TrueSkillTrueSkillPlayerNull" + | "TrueSkillInvalidPlayerId" + | "TrueSkillInvalidSquadSize" + | "TrueSkillConditionSetNotInModel" + | "TrueSkillModelStateInvalidForOperation" + | "TrueSkillScenarioContainsActiveModel" + | "TrueSkillInvalidConditionRank" + | "TrueSkillTotalScenarioLimitExceeded" + | "TrueSkillInvalidConditionsList" + | "GameSaveManifestNotFound" + | "GameSaveManifestVersionAlreadyExists" + | "GameSaveConflictUpdatingManifest" + | "GameSaveManifestUpdatesNotAllowed" + | "GameSaveFileAlreadyExists" + | "GameSaveManifestVersionNotFinalized" + | "GameSaveUnknownFileInManifest" + | "GameSaveFileExceededReportedSize" + | "GameSaveFileNotUploaded" + | "GameSaveBadRequest" + | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" + | "GameSaveBaseVersionNotAvailable" + | "GameSaveManifestVersionQuarantined" + | "GameSaveManifestUploadProgressUpdateNotAllowed" + | "GameSaveNotFinalizedManifestNotEligibleAsKnownGood" + | "GameSaveNoUpdatesRequested" + | "GameSaveTitleDoesNotExist" + | "GameSaveOperationNotAllowedForTitle" + | "GameSaveManifestFilesLimitExceeded" + | "GameSaveManifestDescriptionUpdateNotAllowed" + | "GameSaveTitleConfigNotFound" + | "GameSaveTitleAlreadyOnboarded" + | "GameSaveServiceNotEnabledForTitle" + | "GameSaveServiceOnboardingPending" + | "GameSaveManifestNotEligibleAsConflictingVersion" + | "GameSaveServiceUnavailable" + | "GameSaveConflict" + | "GameSaveManifestNotEligibleForRollback" + | "GameSaveTitleClientAnonymousAccountCreationNotDisabled" + | "GameSaveTitleConfigNoUpdatesRequested" + | "GameSavePlayerNotEligibleForTransfer" + | "GameSaveAlreadyAutoRolledBack" + | "GameSaveManifestNotEligibleForRestore" + | "GameSaveManifestArchived" + | "StateShareForbidden" + | "StateShareTitleNotInFlight" + | "StateShareStateNotFound" + | "StateShareLinkNotFound" + | "StateShareStateRedemptionLimitExceeded" + | "StateShareStateRedemptionLimitNotUpdated" + | "StateShareCreatedStatesLimitExceeded" + | "StateShareIdMissingOrMalformed" + | "PlayerCreationDisabled" + | "AccountAlreadyExists" + | "TagInvalid" + | "TagTooLong" + | "StatisticColumnAggregationMismatch" + | "StatisticResetIntervalMismatch" + | "VersionConfigurationCannotBeSpecifiedForLinkedStat" + | "VersionConfigurationIsRequired" + | "InvalidEntityTypeForAggregation" + | "MultiLevelAggregationNotAllowed" + | "AggregationTypeNotAllowedForLinkedStat" + | "OperationDeniedDueToDefinitionPolicy" + | "StatisticUpdateNotAllowedWhileLinked" + | "UnsupportedEntityType" + | "EntityTypeSpecifiedRequiresAggregationSource" + | "PlayFabErrorEventNotSupportedForEntityType" + | "MetadataLengthExceeded" + | "MaxQueryableVersionsExceeded" + | "StatisticVersionIncrementNotAllowedWhileLinked" + | "StoreMetricsRequestInvalidInput" + | "StoreMetricsErrorRetrievingMetrics"; + export interface GetActionsOnPlayersInSegmentTaskInstanceResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Status summary of the actions-on-players-in-segment task instance - */ - Summary?: ActionsOnPlayersInSegmentTaskSummary; - /** - / Parameter of this task instance - */ + /** Parameter of this task instance */ Parameter?: ActionsOnPlayersInSegmentTaskParameter; + /** Status summary of the actions-on-players-in-segment task instance */ + Summary?: ActionsOnPlayersInSegmentTaskSummary; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllActionGroupsRequest - */ - export interface GetAllActionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetAllIPBansRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllActionGroupsResult - */ - export interface GetAllActionGroupsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of Action Groups. - */ - ActionGroups: GetActionGroupResult[]; + export interface GetAllIPBansResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on all IP bans */ + IPBanData?: IPBanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllSegmentsRequest - */ export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllSegmentsResult - */ export interface GetAllSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments for this title. - */ + /** Array of segments for this title. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCatalogItemsRequest - */ export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptRevisionRequest - */ export interface GetCloudScriptRevisionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Version number. If left null, defaults to the latest version - */ - Version?: number; - /** - / Revision number. If left null, defaults to the latest revision - */ + /** Revision number. If left null, defaults to the latest revision */ Revision?: number; + /** Version number. If left null, defaults to the latest version */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptRevisionResult - */ export interface GetCloudScriptRevisionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Version number. - */ - Version: number; - /** - / Revision number. - */ - Revision: number; - /** - / Time this revision was created - */ + /** Time this revision was created */ CreatedAt: string; - /** - / List of Cloud Script files in this revision. - */ + /** List of Cloud Script files in this revision. */ Files?: CloudScriptFile[]; - /** - / True if this is the currently published revision - */ + /** True if this is the currently published revision */ IsPublished: boolean; + /** Revision number. */ + Revision: number; + /** Version number. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptTaskInstanceResult - */ export interface GetCloudScriptTaskInstanceResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Status summary of the CloudScript task instance - */ - Summary?: CloudScriptTaskSummary; - /** - / Parameter of this task instance - */ + /** Parameter of this task instance */ Parameter?: CloudScriptTaskParameter; + /** Status summary of the CloudScript task instance */ + Summary?: CloudScriptTaskSummary; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptVersionsRequest - */ export interface GetCloudScriptVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptVersionsResult - */ export interface GetCloudScriptVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of versions - */ + /** List of versions */ Versions?: CloudScriptVersionStatus[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentListRequest - */ export interface GetContentListRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Limits the response to keys that begin with the specified prefix. You can use prefixes to list contents under a folder, or for a specified version, etc. + * Limits the response to keys that begin with the specified prefix. You can use prefixes to list contents under a folder, + * or for a specified version, etc. */ Prefix?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentListResult - */ export interface GetContentListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Number of content items returned. We currently have a maximum of 1000 items limit. - */ + /** List of content items. */ + Contents?: ContentInfo[]; + /** Number of content items returned. We currently have a maximum of 1000 items limit. */ ItemCount: number; - /** - / The total size of listed contents in bytes. - */ + /** The total size of listed contents in bytes. */ TotalSize: number; - /** - / List of content items. - */ - Contents?: ContentInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentUploadUrlRequest - */ export interface GetContentUploadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Key of the content item to upload, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. + * A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when + * uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. */ ContentType?: string; + /** Key of the content item to upload, usually formatted as a path, e.g. images/a.png */ + Key: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentUploadUrlResult - */ export interface GetContentUploadUrlResult extends PlayFabModule.IPlayFabResultCommon { /** - / URL for uploading content via HTTP PUT method. The URL will expire in 1 hour. + * URL for uploading content via HTTP PUT method. The URL requires the 'x-ms-blob-type' header to have the value + * 'BlockBlob'. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetDataReportRequest - */ export interface GetDataReportRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Report name - */ + /** Reporting year (UTC) */ + Day: number; + /** Reporting month (UTC) */ + Month: number; + /** Report name */ ReportName: string; - /** - / Reporting year (UTC) - */ + /** Reporting year (UTC) */ Year: number; - /** - / Reporting month (UTC) - */ - Month: number; - /** - / Reporting year (UTC) - */ - Day: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetDataReportResult - */ export interface GetDataReportResult extends PlayFabModule.IPlayFabResultCommon { /** - / The URL where the requested report can be downloaded. + * The URL where the requested report can be downloaded. This can be any PlayFab generated reports. The full list of + * reports can be found at: https://docs.microsoft.com/en-us/gaming/playfab/features/analytics/reports/quickstart. */ DownloadUrl?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameInfoRequest - */ - export interface GetMatchmakerGameInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the lobby for which info is being requested - */ - LobbyId: string; + export interface GetIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The IP address of the ban to retrieve information on. */ + IPAddress: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameInfoResult - */ - export interface GetMatchmakerGameInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier of the lobby - */ - LobbyId?: string; - /** - / unique identifier of the Game Server Instance for this lobby - */ - TitleId?: string; - /** - / time when the Game Server Instance was created - */ - StartTime: string; - /** - / time when Game Server Instance is currently scheduled to end - */ - EndTime?: string; - /** - / game mode for this Game Server Instance - */ - Mode?: string; - /** - / version identifier of the game server executable binary being run - */ - BuildVersion?: string; - /** - / region in which the Game Server Instance is running - */ - Region?: string; - /** - / array of unique PlayFab identifiers for users currently connected to this Game Server Instance - */ - Players?: string[]; - /** - / IP address for this Game Server Instance - */ - ServerAddress?: string; - /** - / communication port for this Game Server Instance - */ - ServerPort: number; + export interface GetIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban */ + IPBanData?: IPBanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameModesRequest - */ - export interface GetMatchmakerGameModesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / previously uploaded build version for which game modes are being requested - */ - BuildVersion: string; + export interface GetPlayedTitleListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameModesResult - */ - export interface GetMatchmakerGameModesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of game modes available for the specified build - */ - GameModes?: GameModeInfo[]; + export interface GetPlayedTitleListResult extends PlayFabModule.IPlayFabResultCommon { + /** List of titles the player has played */ + TitleIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerSegmentsResult - */ - export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments the requested player currently belongs to. - */ - Segments?: GetSegmentResult[]; + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Specific property name to search for in the player's properties. */ + PropertyName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersInSegmentRequest - */ - export interface GetPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for this segment. - */ - SegmentId: string; - /** - / Number of seconds to keep the continuation token active. After token expiration it is not possible to continue paging results. Default is 300 (5 minutes). Maximum is 1,800 (30 minutes). - */ - SecondsToLive?: number; - /** - / Maximum number of profiles to load. Default is 1,000. Maximum is 10,000. - */ - MaxBatchSize?: number; + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; /** - / Continuation token if retrieving subsequent pages of results. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - ContinuationToken?: string; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersInSegmentResult - */ - export interface GetPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Count of profiles matching this segment. - */ - ProfilesInSegment: number; - /** - / Continuation token to use to retrieve subsequent pages of results. If token returns null there are no more results. - */ - ContinuationToken?: string; + export interface GetPlayerIdFromAuthTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The auth token of the player requesting the password reset. */ + Token: string; + /** The type of auth token of the player requesting the password reset. */ + TokenType: string; + + } + + export interface GetPlayerIdFromAuthTokenResult extends PlayFabModule.IPlayFabResultCommon { + /** The player ID from the token passed in */ + PlayFabId?: string; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / Array of player profiles in this segment. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - PlayerProfiles?: PlayerProfile[]; + ProfileConstraints?: PlayerProfileViewConstraints; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersSegmentsRequest - */ - export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - PlayFabId: string; + PlayerProfile?: PlayerProfileModel; + + } + + export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of segments the requested player currently belongs to. */ + Segments?: GetSegmentResult[]; + + } + + export interface GetPlayerSharedSecretsRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface GetPlayerSharedSecretsResult extends PlayFabModule.IPlayFabResultCommon { + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SharedSecrets?: SharedSecret[]; + + } + + export interface GetPlayersInSegmentExportRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId: string; + + } + + export interface GetPlayersInSegmentExportResponse extends PlayFabModule.IPlayFabResultCommon { + /** Url from which the index file can be downloaded. */ + IndexUrl?: string; + /** Shows the current status of the export */ + State?: string; + + } + + export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticDefinitionsRequest - */ export interface GetPlayerStatisticDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticDefinitionsResult - */ export interface GetPlayerStatisticDefinitionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / the player statistic definitions for the title - */ + /** the player statistic definitions for the title */ Statistics?: PlayerStatisticDefinition[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticVersionsRequest - */ export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticVersionsResult - */ export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ + /** version change history of the statistic */ StatisticVersions?: PlayerStatisticVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerTagsRequest - */ export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Optional namespace to filter results by - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerTagsResult - */ export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ + /** Canonical tags (including namespace and tag's name) for the requested user */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPolicyRequest - */ export interface GetPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / The name of the policy to read. Only supported name is 'ApiPolicy'. + * The name of the policy to read. Only 'ApiPolicy' is supported. This parameter is optional and defaults to 'ApiPolicy' if + * omitted. */ PolicyName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPolicyResponse - */ export interface GetPolicyResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the policy read. - */ + /** The UTC date and time when the policy was last updated. Null if the policy has never been customized. */ + LastUpdated?: string; + /** The name of the policy read. */ PolicyName?: string; - /** - / The statements in the requested policy. - */ + /** Policy version. */ + PolicyVersion: number; + /** The statements in the requested policy. */ Statements?: PermissionStatement[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPublisherDataRequest - */ export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ Keys: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPublisherDataResult - */ export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetRandomResultTablesRequest - */ export interface GetRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to fetch tables from. Use default catalog version if null - */ + /** catalog version to fetch tables from. Use default catalog version if null */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetRandomResultTablesResult - */ export interface GetRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of random result tables currently available - */ + /** array of random result tables currently available */ Tables?: { [key: string]: RandomResultTableListing }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ - Id: string; - /** - / Segment name. - */ - Name?: string; - /** - / Identifier of the segments AB Test, if it is attached to one. - */ - ABTestParent?: string; + export interface GetSegmentPlayerCountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the requested segment. */ + SegmentId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildInfoRequest - */ - export interface GetServerBuildInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable for which information is being requested - */ - BuildId: string; + export interface GetSegmentPlayerCountResult extends PlayFabModule.IPlayFabResultCommon { + /** Count of profiles matching this segment. */ + ProfilesInSegment: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildInfoResult - */ - export interface GetServerBuildInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / developer comment(s) for this build - */ - Comment?: string; - /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / the current status of the build validation and processing steps - */ - Status?: string; - /** - / error message, if any, about this build - */ - ErrorMessage?: string; + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ + Id: string; + /** Segment name. */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildUploadURLRequest - */ - export interface GetServerBuildUploadURLRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the game server build to upload - */ - BuildId: string; + export interface GetSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment ids to filter title segments. */ + SegmentIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildUploadURLResult - */ - export interface GetServerBuildUploadURLResult extends PlayFabModule.IPlayFabResultCommon { - /** - / pre-authorized URL for uploading the game server build package - */ - URL?: string; + export interface GetSegmentsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** List of title segments. */ + Segments?: SegmentModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetStoreItemsRequest - */ export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to store items from. Use default catalog version if null - */ + /** Catalog version to store items from. Use default catalog version if null */ CatalogVersion?: string; - /** - / Unqiue identifier for the store which is being requested. - */ + /** Unqiue identifier for the store which is being requested. */ StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetStoreItemsResult - */ export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased from this store. - */ - Store?: StoreItem[]; - /** - / How the store was last updated (Admin or a third party). - */ - Source?: string; - /** - / The base catalog that this store is a part of. - */ + /** The base catalog that this store is a part of. */ CatalogVersion?: string; - /** - / The ID of this store. - */ - StoreId?: string; - /** - / Additional data about the store. - */ + /** Additional data about the store. */ MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstanceRequest - */ export interface GetTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / ID of the requested task instance. - */ + /** ID of the requested task instance. */ TaskInstanceId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstancesRequest - */ export interface GetTaskInstancesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name or ID of the task whose instances are being queried. If not specified, return all task instances that satisfy conditions set by other filters. - */ - TaskIdentifier?: NameIdentifier; - /** - / Optional filter for task instances that are of a specific status. - */ - StatusFilter?: string; - /** - / Optional range-from filter for task instances' StartedAt timestamp. - */ + /** Optional range-from filter for task instances' StartedAt timestamp. */ StartedAtRangeFrom?: string; + /** Optional range-to filter for task instances' StartedAt timestamp. */ + StartedAtRangeTo?: string; + /** Optional filter for task instances that are of a specific status. */ + StatusFilter?: string; /** - / Optional range-to filter for task instances' StartedAt timestamp. + * Name or ID of the task whose instances are being queried. If not specified, return all task instances that satisfy + * conditions set by other filters. */ - StartedAtRangeTo?: string; + TaskIdentifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstancesResult - */ export interface GetTaskInstancesResult extends PlayFabModule.IPlayFabResultCommon { /** - / Basic status summaries of the queried task instances. Empty If no task instances meets the filter criteria. To get detailed status summary, use Get*TaskInstance API according to task type (e.g. GetActionsOnPlayersInSegmentTaskInstance). + * Basic status summaries of the queried task instances. Empty If no task instances meets the filter criteria. To get + * detailed status summary, use Get*TaskInstance API according to task type (e.g. + * GetActionsOnPlayersInSegmentTaskInstance). */ Summaries?: TaskInstanceBasicSummary[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTasksRequest - */ export interface GetTasksRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Provide either the task ID or the task name to get a specific task. If not specified, return all defined tasks. - */ + /** Provide either the task ID or the task name to get a specific task. If not specified, return all defined tasks. */ Identifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTasksResult - */ export interface GetTasksResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Result tasks. Empty if there is no task found. - */ + /** Result tasks. Empty if there is no task found. */ Tasks?: ScheduledTask[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTitleDataRequest - */ export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Specific keys to search for in the title data (leave null to get all keys) + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - Keys?: string[]; + OverrideLabel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTitleDataResult - */ export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserBansRequest - */ export interface GetUserBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserBansResult - */ export interface GetUserBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the bans - */ + /** Information about the bans */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { + /** User specific data for this title. */ + Data?: { [key: string]: UserDataRecord }; /** - / PlayFab unique identifier of the user whose custom data is being returned. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; - /** - / User specific data for this title. - */ - Data?: { [key: string]: UserDataRecord }; + /** PlayFab unique identifier of the user whose custom data is being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantedItemInstance - */ export interface GrantedItemInstance { + /** Game specific comment associated with this instance when it was added to the user inventory. */ + Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ + BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Result of this operation. - */ - Result: boolean; - /** - / Unique identifier for the inventory item, as defined in the catalog. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ + DisplayName?: string; + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ + /** Unique item identifier for this specific instance of the item. */ ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Timestamp for when this instance was purchased. */ PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ + /** Total number of remaining uses, if this is a consumable item. */ RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Result of this operation. */ + Result: boolean; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface GrantItemContent { + /** The catalog version of the item to be granted to the player */ + CatalogVersion?: string; + /** The id of item to be granted to the player */ + ItemId?: string; + /** Quantity of the item to be granted to a player */ + ItemQuantity: number; + + } + + export interface GrantItemSegmentAction { + /** Item catalog id. */ + CatelogId?: string; + /** Item id. */ + ItemId?: string; + /** Item quantity. */ + Quantity: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantItemsToUsersRequest - */ export interface GrantItemsToUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Array of items to grant and the users to whom the items are to be granted. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to grant and the users to whom the items are to be granted. */ ItemGrants: ItemGrant[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantItemsToUsersResult - */ export interface GrantItemsToUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.IncrementPlayerStatisticVersionRequest - */ - export interface IncrementPlayerStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ - StatisticName?: string; + export interface GrantVirtualCurrencyContent { + /** Amount of currency to be granted to a player */ + CurrencyAmount: number; + /** Code of the currency to be granted to a player */ + CurrencyCode: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.IncrementPlayerStatisticVersionResult - */ - export interface IncrementPlayerStatisticVersionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ - StatisticVersion?: PlayerStatisticVersion; + export interface GrantVirtualCurrencySegmentAction { + /** Virtual currency amount. */ + Amount: number; + /** Virtual currency code. */ + CurrencyCode?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ItemGrant - */ - export interface ItemGrant { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the catalog item to be granted to the user. - */ + export interface IncrementLimitedEditionItemAvailabilityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Amount to increase availability by. */ + Amount: number; + /** Which catalog is being updated. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The item which needs more availability. */ ItemId: string; - /** - / String detailing any additional information concerning this operation. - */ - Annotation?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface IncrementLimitedEditionItemAvailabilityResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface IncrementPlayerStatisticContent { + /** Amount(in whole number) to increase the player statistic by */ + StatisticChangeBy: number; + /** Name of the player statistic to be incremented */ + StatisticName: string; + + } + + export interface IncrementPlayerStatisticSegmentAction { + /** Increment value. */ + IncrementValue: number; + /** Statistic name. */ + StatisticName?: string; + + } + + export interface IncrementPlayerStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ + StatisticName?: string; + + } + + export interface IncrementPlayerStatisticVersionResult extends PlayFabModule.IPlayFabResultCommon { + /** version change history of the statistic */ + StatisticVersion?: PlayerStatisticVersion; + + } + + export interface InsightsScalingTaskParameter { + /** Insights Performance Level to scale to. */ + Level: number; + + } + + export interface IPBanInfo { + /** The active state of this ban. */ + Active: boolean; + /** PlayFab Developer ID of who issued the ban. Null if ban issued via Title Secret Key. */ + BannedByDeveloperId?: string; + /** The time when this IP ban was applied. */ + Created?: string; + /** The time when this ban expires. Permanent bans do not have expiration date. */ + Expires?: string; + /** The IP address on which the ban was applied. */ + IPAddress?: string; + /** The reason why this IP ban was applied. */ + Reason?: string; + + } + + export interface ItemGrant { + /** String detailing any additional information concerning this operation. */ + Annotation?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; + /** Unique identifier of the catalog item to be granted to the user. */ + ItemId: string; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface LastLoginDateSegmentFilter { + /** Last player login date comparison. */ + Comparison?: string; + /** Last player login date. */ + LogInDate: string; + + } + + export interface LastLoginTimespanSegmentFilter { + /** Last player login duration comparison. */ + Comparison?: string; + /** Last player login duration. */ + DurationInMinutes: number; + + } + + export interface LinkedPlatformAccountModel { + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ + Platform?: string; + /** Unique account identifier of the user on the platform */ + PlatformUserId?: string; + /** Linked account username of the user on the platform, if available */ + Username?: string; + + } + + export interface LinkedUserAccountHasEmailSegmentFilter { + /** Login provider comparison. */ + Comparison?: string; + /** Login provider. */ + LoginProvider?: string; + + } + + export interface LinkedUserAccountSegmentFilter { + /** Login provider. */ + LoginProvider?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListBuildsRequest - */ - export interface ListBuildsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface ListOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListBuildsResult - */ - export interface ListBuildsResult extends PlayFabModule.IPlayFabResultCommon { + export interface ListOpenIdConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of Open ID Connections */ + Connections?: OpenIdConnection[]; + + } + + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / array of uploaded game server builds + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Builds?: GetServerBuildInfoResult[]; + PropertiesVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListVirtualCurrencyTypesRequest - */ export interface ListVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListVirtualCurrencyTypesResult - */ export interface ListVirtualCurrencyTypesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of virtual currency names defined for this title - */ + /** List of virtual currency names defined for this title */ VirtualCurrencies?: VirtualCurrencyData[]; } + export interface LocationModel { + /** City name. */ + City?: string; + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ + Latitude?: number; + /** Longitude coordinate of the geographic location. */ + Longitude?: number; + + } + + export interface LocationSegmentFilter { + /** Segment country code. */ + CountryCode?: string; + + } + type LoginIdentityProvider = "Unknown" + | "PlayFab" | "Custom" | "GameCenter" @@ -2870,1677 +3947,2079 @@ declare module PlayFabAdminModels { | "IOSDevice" | "AndroidDevice" | "Twitch" - | "WindowsHello"; + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LogStatement - */ export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ Level?: string; Message?: string; - /** - / Optional object accompanying the message as contextual information - */ - Data?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LookupUserAccountInfoRequest - */ export interface LookupUserAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / User email address attached to their account - */ + /** User email address attached to their account */ Email?: string; - /** - / PlayFab username for the account (3-20 characters) - */ - Username?: string; - /** - / Title specific username to match against existing user accounts - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Title specific username to match against existing user accounts */ TitleDisplayName?: string; + /** PlayFab username for the account (3-20 characters) */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LookupUserAccountInfoResult - */ export interface LookupUserAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User info for the user matching the request - */ + /** User info for the user matching the request */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyMatchmakerGameModesRequest - */ - export interface ModifyMatchmakerGameModesRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / previously uploaded build version for which game modes are being specified + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - BuildVersion: string; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; + + } + + export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / array of game modes (Note: this will replace all game modes for the indicated build version) + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ - GameModes: GameModeInfo[]; + BalanceChange: number; + /** User currency was subtracted from. */ + PlayFabId?: string; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyMatchmakerGameModesResult - */ - export interface ModifyMatchmakerGameModesResult extends PlayFabModule.IPlayFabResultCommon { + export interface NameIdentifier { + /** Id Identifier, if present */ + Id?: string; + /** Name Identifier, if present */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyServerBuildRequest - */ - export interface ModifyServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable to be updated - */ - BuildId: string; - /** - / new timestamp - */ - Timestamp?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ - Comment?: string; + type NewsStatus = "None" + + | "Unpublished" + | "Published" + | "Archived"; + + export interface OpenIdConnection { + /** The client ID given by the ID provider. */ + ClientId?: string; + /** The client secret given by the ID provider. */ + ClientSecret?: string; + /** A name for the connection to identify it within the title. */ + ConnectionId?: string; + /** Shows if data about the connection will be loaded from the issuer's discovery document */ + DiscoverConfiguration: boolean; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; + /** Information for an OpenID Connect provider. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyServerBuildResult - */ - export interface ModifyServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ + export interface OpenIdIssuerInformation { + /** Authorization endpoint URL to direct users to for signin. */ + AuthorizationUrl: string; + /** The URL of the issuer of the tokens. This must match the exact URL of the issuer field in tokens. */ + Issuer: string; + /** JSON Web Key Set for validating the signature of tokens. */ + JsonWebKeySet: any; + /** Token endpoint URL for code verification. */ + TokenUrl: string; + + } + + export interface PermissionStatement { + /** The action this statement effects. May only be '*'. This parameter is optional and defaults to '*' if omitted. */ + Action?: string; + /** Additional conditions to be applied for API Resources. */ + ApiConditions?: ApiCondition; + /** A comment about the statement. Intended solely for bookkeeping and debugging. */ Comment?: string; + /** The effect this statement will have. It could be either Allow or Deny */ + Effect: string; /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * The principal this statement will effect. May be '*' to match all callers, or a JSON object targeting a specific entity + * type, e.g. {"title_player_account":"*"} for players or {"master_player_account":"*"} for master player accounts. */ - TitleId?: string; + Principal: string; /** - / the current status of the build validation and processing steps + * The resource this statements effects. The only supported resources look like 'pfrn:api--*' for all apis, or + * 'pfrn:api--/Client/ConfirmPurchase' for specific apis. */ - Status?: string; + Resource: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyUserVirtualCurrencyResult - */ - export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User currency was subtracted from. - */ - PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface PlayerChurnPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.NameIdentifier - */ - export interface NameIdentifier { - Name?: string; - Id?: string; + export interface PlayerChurnPredictionTimeSegmentFilter { + /** Comparison */ + Comparison?: string; + /** DurationInDays */ + DurationInDays: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PermissionStatement - */ - export interface PermissionStatement { - /** - / The resource this statements effects. The only supported resources look like 'pfrn:api--*' for all apis, or 'pfrn:api--/Client/ConfirmPurchase' for specific apis. - */ - Resource: string; - /** - / The action this statement effects. The only supported action is 'Execute'. - */ - Action: string; - /** - / The effect this statement will have. It could be either Allow or Deny - */ - Effect: string; - /** - / The principal this statement will effect. The only supported principal is '*'. - */ - Principal: string; - /** - / A comment about the statement. Intended solely for bookeeping and debugging. - */ - Comment?: string; + export interface PlayerChurnPreviousPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerLinkedAccount - */ - export interface PlayerLinkedAccount { - /** - / Authentication platform - */ - Platform?: string; - /** - / Platform user identifier - */ - PlatformUserId?: string; + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Linked account's username + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ - Username?: string; + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Linked account's email + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ - Email?: string; + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ + ShowBannedUntil: boolean; + /** Whether to show campaign attributions. Defaults to false */ + ShowCampaignAttributions: boolean; + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ + ShowLinkedAccounts: boolean; + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ + ShowTotalValueToDateInUsd: boolean; + /** Whether to show the values to date. Defaults to false */ + ShowValuesToDate: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerLocation - */ - export interface PlayerLocation { - /** - / The two-character continent code for this location - */ - ContinentCode: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode: string; - /** - / City of the player's geographic location. - */ - City?: string; - /** - / Latitude coordinate of the player's geographic location. - */ - Latitude?: number; - /** - / Longitude coordinate of the player's geographic location. - */ - Longitude?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerProfile - */ - export interface PlayerProfile { - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Player record created - */ - Created?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / Banned until UTC Date. If permanent ban this is set for 20 years after the original ban date. - */ - BannedUntil?: string; - /** - / Image URL of the player's avatar. - */ - AvatarUrl?: string; - /** - / Dictionary of player's statistics using only the latest version's value - */ - Statistics?: { [key: string]: number }; - /** - / A sum of player's total purchases in USD across all currencies. - */ - TotalValueToDateInUSD?: number; - /** - / Dictionary of player's total purchases by currency. - */ - ValuesToDate?: { [key: string]: number }; - /** - / List of player's tags for segmentation. - */ - Tags?: string[]; - /** - / Dictionary of player's locations by type. - */ - Locations?: { [key: string]: PlayerLocation }; - /** - / Dictionary of player's virtual currency balances - */ - VirtualCurrencyBalances?: { [key: string]: number }; - /** - / Array of ad campaigns player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttribution[]; - /** - / Array of configured push notification end points - */ - PushNotificationRegistrations?: PushNotificationRegistration[]; - /** - / Array of third party accounts linked to this player - */ - LinkedAccounts?: PlayerLinkedAccount[]; - /** - / Array of player statistics - */ - PlayerStatistics?: PlayerStatistic[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatistic - */ - export interface PlayerStatistic { - /** - / Statistic ID - */ - Id?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - StatisticVersion: number; - /** - / Current statistic value - */ - StatisticValue: number; - /** - / Statistic name - */ - Name?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatisticDefinition - */ export interface PlayerStatisticDefinition { - /** - / unique name of the statistic - */ - StatisticName?: string; - /** - / current active version of the statistic, incremented each time the statistic resets - */ + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** current active version of the statistic, incremented each time the statistic resets */ CurrentVersion: number; - /** - / interval at which the values of the statistic for all players are reset automatically - */ + /** unique name of the statistic */ + StatisticName?: string; + /** interval at which the values of the statistic for all players are reset automatically */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatisticVersion - */ export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ - StatisticName?: string; - /** - / version of the statistic - */ - Version: number; - /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ + /** time when the statistic version became active */ ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval - */ - ScheduledDeactivationTime?: string; - /** - / time when the statistic version became inactive due to statistic version incrementing - */ + /** URL for the downloadable archive of player statistic values, if available */ + ArchiveDownloadUrl?: string; + /** time when the statistic version became inactive due to statistic version incrementing */ DeactivationTime?: string; - /** - / status of the process of saving player statistic values of the previous version to a downloadable archive - */ - ArchivalStatus?: string; - /** - / status of the statistic version - */ + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ + StatisticName?: string; + /** status of the statistic version */ Status?: string; + /** version of the statistic */ + Version: number; + + } + + export interface PolicyDiffSummary { + /** Number of new statements that would be added. */ + StatementsAdded: number; + /** Number of existing statements that would be removed. Only applicable when OverwritePolicy is true. */ + StatementsRemoved: number; /** - / URL for the downloadable archive of player statistic values, if available + * Number of existing statements that would be replaced by functionally equivalent incoming statements (e.g., same + * resource/effect/principal but different comment). */ - ArchiveDownloadUrl?: string; + StatementsReplaced: number; + /** Number of existing statements that would remain unchanged. */ + StatementsUnchanged: number; + /** Total number of statements in the resulting policy. */ + TotalResultingStatements: number; + + } + + export interface PushNotificationContent { + /** Text of message to send. */ + Message?: string; + /** Id of the push notification template. */ + PushNotificationTemplateId?: string; + /** Subject of message to send (may not be displayed in all platforms) */ + Subject?: string; } type PushNotificationPlatform = "ApplePushNotificationService" + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PushNotificationRegistration - */ - export interface PushNotificationRegistration { - /** - / Push notification platform - */ - Platform?: string; - /** - / Notification configured endpoint - */ + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; + + } + + export interface PushNotificationSegmentAction { + /** Push notification template id. */ + PushNotificationTemplateId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RandomResultTable - */ + export interface PushNotificationSegmentFilter { + /** Push notification device platform. */ + PushNotificationDevicePlatform?: string; + + } + + type PushSetupPlatform = "GCM" + + | "APNS" + | "APNS_SANDBOX"; + export interface RandomResultTable { - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ + /** Child nodes that indicate what kind of drop table item this actually is. */ Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RandomResultTableListing - */ export interface RandomResultTableListing { - /** - / Catalog version this table is associated with - */ + /** Catalog version this table is associated with */ CatalogVersion?: string; - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ + /** Child nodes that indicate what kind of drop table item this actually is. */ Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RefundPurchaseRequest - */ export interface RefundPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique order ID for the purchase in question. - */ + /** Unique order ID for the purchase in question. */ OrderId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / Reason for refund. In the case of Facebook this must match one of their refund or dispute resolution enums (See: https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) + * The Reason parameter should correspond with the payment providers reason field, if they require one such as Facebook. In + * the case of Facebook this must match one of their refund or dispute resolution enums (See: + * https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) */ Reason?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RefundPurchaseResponse - */ export interface RefundPurchaseResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The order's updated purchase status. - */ + /** The order's updated purchase status. */ PurchaseStatus?: string; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemovePlayerTagRequest - */ export interface RemovePlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemovePlayerTagResult - */ export interface RemovePlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveServerBuildRequest - */ - export interface RemoveServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable to be removed - */ - BuildId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveServerBuildResult - */ - export interface RemoveServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveVirtualCurrencyTypesRequest - */ export interface RemoveVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of virtual currencies to delete - */ + /** List of virtual currencies to delete */ VirtualCurrencies: VirtualCurrencyData[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetCharacterStatisticsRequest - */ export interface ResetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetCharacterStatisticsResult - */ export interface ResetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUsersRequest - */ - export interface ResetUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of users to reset - */ - Users: UserCredentials[]; + export interface ResetPasswordRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new password for the player. */ + Password: string; + /** The token of the player requesting the password reset. */ + Token: string; + + } + + export interface ResetPasswordResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUserStatisticsRequest - */ export interface ResetUserStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUserStatisticsResult - */ export interface ResetUserStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } type ResolutionOutcome = "Revoke" + | "Reinstate" | "Manual"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResolvePurchaseDisputeRequest - */ export interface ResolvePurchaseDisputeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique order ID for the purchase in question. */ + OrderId: string; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Enum for the desired purchase result state after notifying the payment provider. Valid values are Revoke, Reinstate and + * Manual. Manual will cause no change to the order state. */ + Outcome: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; /** - / Unique order ID for the purchase in question. - */ - OrderId: string; - /** - / Reason for refund. In the case of Facebook this must match one of their refund or dispute resolution enums (See: https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) + * The Reason parameter should correspond with the payment providers reason field, if they require one such as Facebook. In + * the case of Facebook this must match one of their refund or dispute resolution enums (See: + * https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) */ Reason?: string; - /** - / Enum for the desired purchase result state after notifying the payment provider. Valid values are Revoke, Reinstate and Manual. Manual will cause no change to the order state. - */ - Outcome: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResolvePurchaseDisputeResponse - */ export interface ResolvePurchaseDisputeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The order's updated purchase status. - */ + /** The order's updated purchase status. */ PurchaseStatus?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResultTableNode - */ export interface ResultTableNode { - /** - / Whether this entry in the table is an item or a link to another table - */ - ResultItemType: string; - /** - / Either an ItemId, or the TableId of another random result table - */ + /** Either an ItemId, or the TableId of another random result table */ ResultItem: string; - /** - / How likely this is to be rolled - larger numbers add more weight - */ + /** Whether this entry in the table is an item or a link to another table */ + ResultItemType: string; + /** How likely this is to be rolled - larger numbers add more weight */ Weight: number; } type ResultTableNodeType = "ItemId" + | "TableId"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeAllBansForUserRequest - */ export interface RevokeAllBansForUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeAllBansForUserResult - */ export interface RevokeAllBansForUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked. - */ + /** Information on the bans that were revoked. */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeBansRequest - */ export interface RevokeBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Ids of the bans to be revoked. Maximum 100. - */ + /** Ids of the bans to be revoked. Maximum 100. */ BanIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeBansResult - */ export interface RevokeBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked - */ + /** Information on the bans that were revoked */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeInventoryItemRequest - */ - export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface RevokeInventoryItem { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RevokeInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Array of player items to revoke, between 1 and 25 items. */ + Items: RevokeInventoryItem[]; + + } + + export interface RevokeInventoryItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** Collection of any errors that occurred during processing. */ + Errors?: RevokeItemError[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeInventoryResult - */ export interface RevokeInventoryResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RunTaskRequest - */ + export interface RevokeIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The IP address of the ban to be revoked. */ + IPAddress: string; + + } + + export interface RevokeIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was revoked */ + IPBanData?: IPBanInfo; + + } + + export interface RevokeItemError { + /** Specific error that was encountered. */ + Error?: string; + /** Item information that failed to be revoked. */ + Item?: RevokeInventoryItem; + + } + export interface RunTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Provide either the task ID or the task name to run a task. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Provide either the task ID or the task name to run a task. */ Identifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RunTaskResult - */ export interface RunTaskResult extends PlayFabModule.IPlayFabResultCommon { /** - / ID of the task instance that is started. This can be used in Get*TaskInstance (e.g. GetCloudScriptTaskInstance) API call to retrieve status for the task instance. + * ID of the task instance that is started. This can be used in Get*TaskInstance (e.g. GetCloudScriptTaskInstance) API call + * to retrieve status for the task instance. */ TaskInstanceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ScheduledTask - */ export interface ScheduledTask { + /** Description the task */ + Description?: string; + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** UTC time of last run */ + LastRunTime?: string; + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** UTC time of next run */ + NextRunTime?: string; /** - / ID of the task + * Task parameter. Different types of task have different parameter structure. See each task type's create API + * documentation for the details. */ + Parameter?: any; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; + /** ID of the task */ TaskId?: string; - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ - Name?: string; - /** - / Description the task - */ - Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ - Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ - IsActive: boolean; - /** - / Task type. - */ + /** Task type. */ Type?: string; + + } + + type ScheduledTaskType = "CloudScript" + + | "ActionsOnPlayerSegment" + | "CloudScriptAzureFunctions" + | "InsightsScheduledScaling"; + + export interface ScriptExecutionError { /** - / Task parameter. Different types of task have different parameter structure. See each task type's create API documentation for the details. - */ - Parameter?: any; - /** - / UTC time of last run - */ - LastRunTime?: string; - /** - / UTC time of next run + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ - NextRunTime?: string; + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the script at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface SegmentAndDefinition { + /** Filter property for ad campaign filter. */ + AdCampaignFilter?: AdCampaignSegmentFilter; + /** property for all player filter. */ + AllPlayersFilter?: AllPlayersSegmentFilter; + /** Filter property for player churn risk level. */ + ChurnPredictionFilter?: ChurnPredictionSegmentFilter; + /** Filter property for boolean custom properties. */ + CustomPropertyBooleanFilter?: CustomPropertyBooleanSegmentFilter; + /** Filter property for datetime custom properties. */ + CustomPropertyDateTimeFilter?: CustomPropertyDateTimeSegmentFilter; + /** Filter property for numeric custom properties. */ + CustomPropertyNumericFilter?: CustomPropertyNumericSegmentFilter; + /** Filter property for string custom properties. */ + CustomPropertyStringFilter?: CustomPropertyStringSegmentFilter; + /** Filter property for first login date. */ + FirstLoginDateFilter?: FirstLoginDateSegmentFilter; + /** Filter property for first login timespan. */ + FirstLoginFilter?: FirstLoginTimespanSegmentFilter; + /** Filter property for last login date. */ + LastLoginDateFilter?: LastLoginDateSegmentFilter; + /** Filter property for last login timespan. */ + LastLoginFilter?: LastLoginTimespanSegmentFilter; + /** Filter property for linked in user account. */ + LinkedUserAccountFilter?: LinkedUserAccountSegmentFilter; + /** Filter property for linked in user account has email. */ + LinkedUserAccountHasEmailFilter?: LinkedUserAccountHasEmailSegmentFilter; + /** Filter property for location. */ + LocationFilter?: LocationSegmentFilter; + /** Filter property for current player churn value. */ + PlayerChurnPredictionFilter?: PlayerChurnPredictionSegmentFilter; + /** Filter property for player churn timespan. */ + PlayerChurnPredictionTimeFilter?: PlayerChurnPredictionTimeSegmentFilter; + /** Filter property for previous player churn value. */ + PlayerChurnPreviousPredictionFilter?: PlayerChurnPreviousPredictionSegmentFilter; + /** Filter property for push notification. */ + PushNotificationFilter?: PushNotificationSegmentFilter; + /** Filter property for statistics. */ + StatisticFilter?: StatisticSegmentFilter; + /** Filter property for tags. */ + TagFilter?: TagSegmentFilter; + /** Filter property for total value to date in USD. */ + TotalValueToDateInUSDFilter?: TotalValueToDateInUSDSegmentFilter; + /** Filter property for user origination. */ + UserOriginationFilter?: UserOriginationSegmentFilter; + /** Filter property for value to date. */ + ValueToDateFilter?: ValueToDateSegmentFilter; + /** Filter property for virtual currency. */ + VirtualCurrencyBalanceFilter?: VirtualCurrencyBalanceSegmentFilter; + + } + + type SegmentCountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW"; + + type SegmentCurrency = "AED" + + | "AFN" + | "ALL" + | "AMD" + | "ANG" + | "AOA" + | "ARS" + | "AUD" + | "AWG" + | "AZN" + | "BAM" + | "BBD" + | "BDT" + | "BGN" + | "BHD" + | "BIF" + | "BMD" + | "BND" + | "BOB" + | "BRL" + | "BSD" + | "BTN" + | "BWP" + | "BYR" + | "BZD" + | "CAD" + | "CDF" + | "CHF" + | "CLP" + | "CNY" + | "COP" + | "CRC" + | "CUC" + | "CUP" + | "CVE" + | "CZK" + | "DJF" + | "DKK" + | "DOP" + | "DZD" + | "EGP" + | "ERN" + | "ETB" + | "EUR" + | "FJD" + | "FKP" + | "GBP" + | "GEL" + | "GGP" + | "GHS" + | "GIP" + | "GMD" + | "GNF" + | "GTQ" + | "GYD" + | "HKD" + | "HNL" + | "HRK" + | "HTG" + | "HUF" + | "IDR" + | "ILS" + | "IMP" + | "INR" + | "IQD" + | "IRR" + | "ISK" + | "JEP" + | "JMD" + | "JOD" + | "JPY" + | "KES" + | "KGS" + | "KHR" + | "KMF" + | "KPW" + | "KRW" + | "KWD" + | "KYD" + | "KZT" + | "LAK" + | "LBP" + | "LKR" + | "LRD" + | "LSL" + | "LYD" + | "MAD" + | "MDL" + | "MGA" + | "MKD" + | "MMK" + | "MNT" + | "MOP" + | "MRO" + | "MUR" + | "MVR" + | "MWK" + | "MXN" + | "MYR" + | "MZN" + | "NAD" + | "NGN" + | "NIO" + | "NOK" + | "NPR" + | "NZD" + | "OMR" + | "PAB" + | "PEN" + | "PGK" + | "PHP" + | "PKR" + | "PLN" + | "PYG" + | "QAR" + | "RON" + | "RSD" + | "RUB" + | "RWF" + | "SAR" + | "SBD" + | "SCR" + | "SDG" + | "SEK" + | "SGD" + | "SHP" + | "SLL" + | "SOS" + | "SPL" + | "SRD" + | "STD" + | "SVC" + | "SYP" + | "SZL" + | "THB" + | "TJS" + | "TMT" + | "TND" + | "TOP" + | "TRY" + | "TTD" + | "TVD" + | "TWD" + | "TZS" + | "UAH" + | "UGX" + | "USD" + | "UYU" + | "UZS" + | "VEF" + | "VND" + | "VUV" + | "WST" + | "XAF" + | "XCD" + | "XDR" + | "XOF" + | "XPF" + | "YER" + | "ZAR" + | "ZMW" + | "ZWD"; + + type SegmentFilterComparison = "GreaterThan" + + | "LessThan" + | "EqualTo" + | "NotEqualTo" + | "GreaterThanOrEqual" + | "LessThanOrEqual" + | "Exists" + | "Contains" + | "NotContains"; + + type SegmentLoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames"; + + export interface SegmentModel { + /** Segment description. */ + Description?: string; + /** Segment actions for current entered segment players. */ + EnteredSegmentActions?: SegmentTrigger[]; + /** Segment last updated date time. */ + LastUpdateTime: string; + /** Segment actions for current left segment players. */ + LeftSegmentActions?: SegmentTrigger[]; + /** Segment name. */ + Name?: string; + /** Segment id in hex. */ + SegmentId?: string; + /** Segment or definitions. This includes segment and definitions and filters. */ + SegmentOrDefinitions?: SegmentOrDefinition[]; } - type ScheduledTaskType = "CloudScript" - | "ActionsOnPlayerSegment"; + export interface SegmentOrDefinition { + /** List of segment and definitions. */ + SegmentAndDefinitions?: SegmentAndDefinition[]; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ScriptExecutionError - */ - export interface ScriptExecutionError { - /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError - */ - Error?: string; - /** - / Details about the error - */ - Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ - StackTrace?: string; + } + + type SegmentPushNotificationDevicePlatform = "ApplePushNotificationService" + + | "GoogleCloudMessaging"; + + export interface SegmentTrigger { + /** Add inventory item v2 segment trigger action. */ + AddInventoryItemsV2Action?: AddInventoryItemsV2SegmentAction; + /** Ban player segment trigger action. */ + BanPlayerAction?: BanPlayerSegmentAction; + /** Delete inventory item v2 segment trigger action. */ + DeleteInventoryItemsV2Action?: DeleteInventoryItemsV2SegmentAction; + /** Delete player segment trigger action. */ + DeletePlayerAction?: DeletePlayerSegmentAction; + /** Delete player statistic segment trigger action. */ + DeletePlayerStatisticAction?: DeletePlayerStatisticSegmentAction; + /** Email notification segment trigger action. */ + EmailNotificationAction?: EmailNotificationSegmentAction; + /** Execute azure function segment trigger action. */ + ExecuteAzureFunctionAction?: ExecuteAzureFunctionSegmentAction; + /** Execute cloud script segment trigger action. */ + ExecuteCloudScriptAction?: ExecuteCloudScriptSegmentAction; + /** Grant item segment trigger action. */ + GrantItemAction?: GrantItemSegmentAction; + /** Grant virtual currency segment trigger action. */ + GrantVirtualCurrencyAction?: GrantVirtualCurrencySegmentAction; + /** Increment player statistic segment trigger action. */ + IncrementPlayerStatisticAction?: IncrementPlayerStatisticSegmentAction; + /** Push notification segment trigger action. */ + PushNotificationAction?: PushNotificationSegmentAction; + /** Subtract inventory item v2 segment trigger action. */ + SubtractInventoryItemsV2Action?: SubtractInventoryItemsV2SegmentAction; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SendAccountRecoveryEmailRequest - */ export interface SendAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SendAccountRecoveryEmailResult - */ export interface SendAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublishedRevisionRequest - */ + export interface SendEmailContent { + /** The email template id of the email template to send. */ + EmailTemplateId: string; + + } + + export interface SetMembershipOverrideRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Expiration time for the membership in DateTime format, will override any subscription expirations. */ + ExpirationTime: string; + /** Id of the membership to apply the override expiration date to. */ + MembershipId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface SetMembershipOverrideResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface SetPublishedRevisionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Version number - */ - Version: number; - /** - / Revision to make the current published revision - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Revision to make the current published revision */ Revision: number; + /** Version number */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublishedRevisionResult - */ export interface SetPublishedRevisionResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublisherDataRequest - */ export interface SetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublisherDataResult - */ export interface SetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetTitleDataRequest - */ - export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface SetTitleDataAndOverridesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * List of titleData key-value pairs to set/delete. Use an empty value to delete an existing key; use a non-empty value to + * create/update a key. */ - Key: string; + KeyValues: TitleDataKeyValue[]; + /** Name of the override. */ + OverrideLabel?: string; + + } + + export interface SetTitleDataAndOverridesResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / new value to set. Set to null to remove a value + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ + Key: string; + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetTitleDataResult - */ export interface SetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetupPushNotificationRequest - */ export interface SetupPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / name of the application sending the message (application names must be made up of only uppercase and lowercase ASCII letters, numbers, underscores, hyphens, and periods, and must be between 1 and 256 characters long) - */ - Name: string; - /** - / supported notification platforms are Apple Push Notification Service (APNS and APNS_SANDBOX) for iOS and Google Cloud Messaging (GCM) for Android - */ - Platform: string; - /** - / for APNS, this is the PlatformPrincipal (SSL Certificate) - */ + /** Credential is the Private Key for APNS/APNS_SANDBOX, and the API Key for GCM */ + Credential: string; + /** for APNS, this is the PlatformPrincipal (SSL Certificate) */ Key?: string; + /** This field is deprecated and any usage of this will cause the API to fail. */ + Name?: string; /** - / Credential is the Private Key for APNS/APNS_SANDBOX, and the API Key for GCM + * replace any existing ARN with the newly generated one. If this is set to false, an error will be returned if + * notifications have already setup for this platform. */ - Credential: string; + OverwriteOldARN: boolean; /** - / replace any existing ARN with the newly generated one. If this is set to false, an error will be returned if notifications have already setup for this platform. + * supported notification platforms are Apple Push Notification Service (APNS and APNS_SANDBOX) for iOS and Google Cloud + * Messaging (GCM) for Android */ - OverwriteOldARN: boolean; + Platform: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetupPushNotificationResult - */ export interface SetupPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Amazon Resource Name for the created notification topic. - */ + /** Amazon Resource Name for the created notification topic. */ ARN?: string; } + export interface SharedSecret { + /** Flag to indicate if this key is disabled */ + Disabled: boolean; + /** Friendly name for this key */ + FriendlyName?: string; + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SecretKey?: string; + + } + type SourceType = "Admin" + | "BackEnd" | "GameClient" | "GameServer" - | "Partner"; + | "Partner" + | "Custom" + | "API"; type StatisticAggregationMethod = "Last" + | "Min" | "Max" | "Sum"; + export interface StatisticModel { + /** Statistic name */ + Name?: string; + /** Statistic value */ + Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; + + } + type StatisticResetIntervalOption = "Never" + | "Hour" | "Day" | "Week" | "Month"; + export interface StatisticSegmentFilter { + /** Statistic filter comparison. */ + Comparison?: string; + /** Statistic filter value. */ + FilterValue?: string; + /** Statistic name. */ + Name?: string; + /** Use current version of statistic? */ + UseCurrentVersion?: boolean; + /** Statistic version. */ + Version?: number; + + } + type StatisticVersionArchivalStatus = "NotScheduled" + | "Scheduled" | "Queued" | "InProgress" | "Complete"; type StatisticVersionStatus = "Active" + | "SnapshotPending" | "Snapshot" | "ArchivalPending" | "Archived"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.StoreItem - */ export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the catalog + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ ItemId: string; - /** - / Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Override prices for this item for specific currencies - */ + /** Override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Store specific custom data. The data only exists as part of this store; it is not transferred to item instances - */ - CustomData?: any; - /** - / Intended display position for this item. Note that 0 is the first position - */ - DisplayPosition?: number; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.StoreMarketingModel - */ export interface StoreMarketingModel { - /** - / Display name of a store as it will appear to users. - */ - DisplayName?: string; - /** - / Tagline for a store. - */ + /** Tagline for a store. */ Description?: string; - /** - / Custom data about a store. - */ + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ Metadata?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SubtractUserVirtualCurrencyRequest - */ + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + + export interface SubtractInventoryItemsV2SegmentAction { + /** Amount of the item to removed from the player */ + Amount?: number; + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The duration in seconds to be removed from the subscription in the players inventory */ + DurationInSeconds?: number; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; + + } + + export interface SubtractInventoryItemV2Content { + /** Amount of the item to removed from the player */ + Amount?: number; + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The duration in seconds to be removed from the subscription in the players inventory */ + DurationInSeconds?: number; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; + + } + export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose virtual currency balance is to be decreased. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be decreased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.TaskInstanceBasicSummary - */ + export interface TagModel { + /** Full value of the tag, including namespace */ + TagValue?: string; + + } + + export interface TagSegmentFilter { + /** Tag comparison. */ + Comparison?: string; + /** Tag value. */ + TagValue?: string; + + } + export interface TaskInstanceBasicSummary { - /** - / ID of the task instance. - */ - TaskInstanceId?: string; - /** - / Identifier of the task this instance belongs to. - */ - TaskIdentifier?: NameIdentifier; - /** - / UTC timestamp when the task started. - */ - StartedAt: string; - /** - / UTC timestamp when the task completed. - */ + /** UTC timestamp when the task completed. */ CompletedAt?: string; - /** - / Current status of the task instance. - */ - Status?: string; - /** - / Progress represented as percentage. - */ - PercentComplete?: number; - /** - / Estimated time remaining in seconds. - */ + /** Error message for last processing attempt, if an error occured. */ + ErrorMessage?: string; + /** Estimated time remaining in seconds. */ EstimatedSecondsRemaining?: number; - /** - / If manually scheduled, ID of user who scheduled the task. - */ + /** Progress represented as percentage. */ + PercentComplete?: number; + /** If manually scheduled, ID of user who scheduled the task. */ ScheduledByUserId?: string; - /** - / Type of the task. - */ + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; + /** Type of the task. */ Type?: string; } type TaskInstanceStatus = "Succeeded" + | "Starting" | "InProgress" | "Failed" | "Aborted" - | "Pending"; + | "Stalled"; type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBanRequest - */ - export interface UpdateBanRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface TitleDataKeyValue { /** - / The id of the ban to be updated. + * Key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ + Key?: string; + /** New value to set. Set to null to remove a value */ + Value?: string; + + } + + export interface TotalValueToDateInUSDSegmentFilter { + /** Total value to date USD amount. */ + Amount?: string; + /** Total value to date USD comparison. */ + Comparison?: string; + + } + + export interface UpdateBanRequest { + /** The updated active state for the ban. Null for no change. */ + Active?: boolean; + /** The id of the ban to be updated. */ BanId: string; - /** - / The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. - */ - Reason?: string; - /** - / The updated expiration date for the ban. Null for no change. - */ + /** The updated expiration date for the ban. Null for no change. */ Expires?: string; - /** - / The updated IP address for the ban. Null for no change. - */ + /** The updated IP address for the ban. Null for no change. */ IPAddress?: string; - /** - / The updated MAC address for the ban. Null for no change. - */ - MACAddress?: string; - /** - / Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. - */ + /** Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. */ Permanent?: boolean; - /** - / The updated active state for the ban. Null for no change. - */ - Active?: boolean; + /** The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. */ + Reason?: string; + /** The updated family type of the user that should be included in the ban. Null for no change. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBansRequest - */ export interface UpdateBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of bans to be updated. Maximum 100. - */ + /** List of bans to be updated. Maximum 100. */ Bans: UpdateBanRequest[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBansResult - */ export interface UpdateBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were updated - */ + /** Information on the bans that were updated */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCatalogItemsRequest - */ export interface UpdateCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Which catalog is being updated. If null, uses the default catalog. + * Array of catalog items to be submitted. Note that while CatalogItem has a parameter for CatalogVersion, it is not + * required and ignored in this call. */ + Catalog?: CatalogItem[]; + /** Which catalog is being updated. If null, uses the default catalog. */ CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Should this catalog be set as the default catalog. Defaults to true. If there is currently no default catalog, this will always set it. + * Should this catalog be set as the default catalog. Defaults to true. If there is currently no default catalog, this will + * always set it. */ SetAsDefaultCatalog?: boolean; - /** - / Array of catalog items to be submitted. Note that while CatalogItem has a parameter for CatalogVersion, it is not required and ignored in this call. - */ - Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCatalogItemsResult - */ export interface UpdateCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCloudScriptRequest - */ export interface UpdateCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of Cloud Script files to upload to create the new revision. Must have at least one file. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab user ID of the developer initiating the request. */ + DeveloperPlayFabId?: string; + /** List of Cloud Script files to upload to create the new revision. Must have at least one file. */ Files: CloudScriptFile[]; - /** - / Immediately publish the new revision - */ + /** Immediately publish the new revision */ Publish: boolean; - /** - / PlayFab user ID of the developer initiating the request. - */ - DeveloperPlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCloudScriptResult - */ export interface UpdateCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Cloud Script version updated - */ + /** New revision number created */ + Revision: number; + /** Cloud Script version updated */ Version: number; + + } + + export interface UpdateIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The updated active state for the IP ban. Null for no change. */ + Active?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The updated expiration date for the IP ban. Null for no change. */ + Expires?: string; + /** The IP address of the ban to be updated. */ + IPAddress: string; + /** Whether to make this IP ban permanent. Set to true to make this IP ban permanent. This will not modify Active state. */ + Permanent?: boolean; + /** The updated reason for the IP ban. Maximum 140 characters. Null for no change. */ + Reason?: string; + + } + + export interface UpdateIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was created */ + IPBanData?: IPBanInfo; + + } + + export interface UpdateOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The client ID given by the ID provider. */ + ClientId?: string; + /** The client secret given by the ID provider. */ + ClientSecret?: string; + /** A name for the connection that identifies it within the title. */ + ConnectionId: string; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; + /** The issuer URL or discovery document URL to read issuer information from */ + IssuerDiscoveryUrl?: string; + /** Manually specified information for an OpenID Connect issuer. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; + + } + + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / New revision number created + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. */ - Revision: number; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePlayerStatisticDefinitionRequest - */ - export interface UpdatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties were updated. */ + PlayFabId?: string; /** - / unique name of the statistic + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface UpdatePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Disable or Enable this key */ + Disabled: boolean; + /** Friendly name for this key */ + FriendlyName?: string; + /** The shared secret key to update */ + SecretKey?: string; + + } + + export interface UpdatePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UpdatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** unique name of the statistic */ StatisticName: string; /** - / interval at which the values of the statistic for all players are reset (changes are effective at the next occurance of the new interval boundary) + * interval at which the values of the statistic for all players are reset (changes are effective at the next occurance of + * the new interval boundary) */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePlayerStatisticDefinitionResult - */ export interface UpdatePlayerStatisticDefinitionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / updated statistic definition - */ + /** updated statistic definition */ Statistic?: PlayerStatisticDefinition; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePolicyRequest - */ export interface UpdatePolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to overwrite or append to the existing policy. */ + OverwritePolicy: boolean; /** - / The name of the policy being updated. Only supported name is 'ApiPolicy' - */ - PolicyName: string; - /** - / The new statements to include in the policy. + * The name of the policy being updated. Only 'ApiPolicy' is supported. This parameter is optional and defaults to + * 'ApiPolicy' if omitted. */ + PolicyName?: string; + /** Version of the policy to update. Must be the latest (as returned by GetPolicy). */ + PolicyVersion: number; + /** The new statements to include in the policy. */ Statements: PermissionStatement[]; - /** - / Whether to overwrite or append to the existing policy. - */ - OverwritePolicy: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePolicyResponse - */ export interface UpdatePolicyResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the policy that was updated. - */ + /** The name of the policy that was updated. */ PolicyName?: string; + /** The statements included in the new version of the policy. */ + Statements?: PermissionStatement[]; /** - / The statements included in the new version of the policy. + * Optional warnings about policy statements that may not have the intended effect. For example, resource paths that don't + * match any known API endpoint. The policy update still succeeds when warnings are present. */ - Statements?: PermissionStatement[]; + Warnings?: string[]; + + } + + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateRandomResultTablesRequest - */ export interface UpdateRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / which catalog is being updated. If null, update the current default catalog version - */ + /** which catalog is being updated. If null, update the current default catalog version */ CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / array of random result tables to make available (Note: specifying an existing TableId will result in overwriting that table, while any others will be added to the available set) + * array of random result tables to make available (Note: specifying an existing TableId will result in overwriting that + * table, while any others will be added to the available set) */ Tables?: RandomResultTable[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateRandomResultTablesResult - */ export interface UpdateRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateStoreItemsRequest - */ + export interface UpdateSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment model with all of the segment properties data. */ + SegmentModel: SegmentModel; + + } + + export interface UpdateSegmentResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** Segment id. */ + SegmentId?: string; + + } + export interface UpdateStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version of the store to update. If null, uses the default catalog. - */ + /** Catalog version of the store to update. If null, uses the default catalog. */ CatalogVersion?: string; - /** - / Unique identifier for the store which is to be updated - */ - StoreId: string; - /** - / Additional data about the store - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Additional data about the store */ MarketingData?: StoreMarketingModel; - /** - / Array of store items - references to catalog items, with specific pricing - to be added - */ + /** Array of store items - references to catalog items, with specific pricing - to be added */ Store?: StoreItem[]; + /** Unique identifier for the store which is to be updated */ + StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateStoreItemsResult - */ export interface UpdateStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateTaskRequest - */ export interface UpdateTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specify either the task ID or the name of the task to be updated. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ + Description?: string; + /** Specify either the task ID or the name of the task to be updated. */ Identifier?: NameIdentifier; - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ Name: string; - /** - / Description the task - */ - Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ + /** Parameter object specific to the task type. See each task type's create API documentation for details. */ + Parameter?: any; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ - IsActive: boolean; - /** - / Task type. - */ + /** Task type. */ Type: string; - /** - / Parameter object specific to the task type. See each task type's create API documentation for details. - */ - Parameter?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserInternalDataRequest - */ export interface UpdateUserInternalDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserTitleDisplayNameRequest - */ export interface UpdateUserTitleDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose title specific display name is to be changed - */ - PlayFabId: string; - /** - / new title display name for the user - must be between 3 and 25 characters - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** New title display name for the user - must be between 3 and 25 characters */ DisplayName: string; + /** PlayFab unique identifier of the user whose title specific display name is to be changed */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserTitleDisplayNameResult - */ export interface UpdateUserTitleDisplayNameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / current title display name for the user (this will be the original display name if the rename attempt failed) - */ + /** current title display name for the user (this will be the original display name if the rename attempt failed) */ DisplayName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserCredentials - */ - export interface UserCredentials { - /** - / Username of user to reset - */ - Username: string; + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserCustomIdInfo - */ export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + + type UserFamilyType = "None" + + | "Xbox" + | "Steam"; + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -4557,161 +6036,200 @@ declare module PlayFabAdminModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface UserOriginationSegmentFilter { + /** User login provider. */ + LoginProvider?: string; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.VirtualCurrencyData - */ - export interface VirtualCurrencyData { + export interface ValidateApiPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether the validation should simulate overwriting or appending to the existing policy. */ + OverwritePolicy: boolean; /** - / unique two-character identifier for this currency type (e.g.: "CC") + * The name of the policy to validate. Only 'ApiPolicy' is supported. This parameter is optional and defaults to + * 'ApiPolicy' if omitted. */ - CurrencyCode: string; + PolicyName?: string; + /** Version of the policy to validate against. Must be the latest (as returned by GetPolicy). */ + PolicyVersion: number; + /** The statements to validate. */ + Statements: PermissionStatement[]; + + } + + export interface ValidateApiPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Summary of what would change compared to the current policy. */ + Diff?: PolicyDiffSummary; + /** Whether the proposed policy is valid and would be accepted by UpdatePolicy. */ + IsValid: boolean; + /** The name of the policy validated. */ + PolicyName?: string; + /** Policy version. */ + PolicyVersion: number; + /** The full set of statements that would result from applying this update. */ + ResultingStatements?: PermissionStatement[]; + /** Validation errors that would cause UpdatePolicy to reject this request. Empty if IsValid is true. */ + ValidationErrors?: string[]; + /** Non-blocking warnings about the proposed policy (e.g., near statement limit, duplicate statements). */ + Warnings?: string[]; + + } + + export interface ValueToDateModel { + /** ISO 4217 code of the currency used in the purchases */ + Currency?: string; /** - / friendly name to show in the developer portal, reports, etc. + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ - DisplayName?: string; + TotalValue: number; /** - / amount to automatically grant users upon first login to the title + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ + TotalValueAsDecimal?: string; + + } + + export interface ValueToDateSegmentFilter { + /** Value to date amount. */ + Amount?: string; + /** Value to date comparison. */ + Comparison?: string; + /** Currency using for filter. */ + Currency?: string; + + } + + export interface VirtualCurrencyBalanceSegmentFilter { + /** Total amount. */ + Amount: number; + /** Amount comparison. */ + Comparison?: string; + /** Currency code. */ + CurrencyCode?: string; + + } + + export interface VirtualCurrencyData { + /** unique two-character identifier for this currency type (e.g.: "CC") */ + CurrencyCode: string; + /** friendly name to show in the developer portal, reports, etc. */ + DisplayName?: string; + /** amount to automatically grant users upon first login to the title */ InitialDeposit?: number; - /** - / rate at which the currency automatically be added to over time, in units per day (24 hours) - */ - RechargeRate?: number; - /** - / maximum amount to which the currency will recharge (cannot exceed MaxAmount, but can be less) - */ + /** maximum amount to which the currency will recharge (cannot exceed MaxAmount, but can be less) */ RechargeMax?: number; + /** rate at which the currency automatically be added to over time, in units per day (24 hours) */ + RechargeRate?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabAuthenticationApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabAuthenticationApi.d.ts new file mode 100644 index 00000000..6730e3dc --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabAuthenticationApi.d.ts @@ -0,0 +1,176 @@ +/// + +declare module PlayFabAuthenticationModule { + export interface IPlayFabAuthentication { + ForgetAllCredentials(): void; + + /** + * Create a game_server entity token and return a new or existing game_server entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/authenticategameserverwithcustomid + */ + AuthenticateGameServerWithCustomId(request: PlayFabAuthenticationModels.AuthenticateCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete a game_server entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/delete + */ + Delete(request: PlayFabAuthenticationModels.DeleteRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Method to exchange a legacy AuthenticationTicket or title SecretKey for an Entity Token or to refresh a still valid + * Entity Token. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/getentitytoken + */ + GetEntityToken(request: PlayFabAuthenticationModels.GetEntityTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Method for a server to validate a client provided EntityToken. Only callable by the title entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/validateentitytoken + */ + ValidateEntityToken(request: PlayFabAuthenticationModels.ValidateEntityTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabAuthenticationModels { + export interface AuthenticateCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The customId used to create and retrieve game_server entity tokens. This is unique at the title level. CustomId must be + * between 32 and 100 characters. + */ + CustomId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface AuthenticateCustomIdResult extends PlayFabModule.IPlayFabResultCommon { + /** The token generated used to set X-EntityToken for game_server calls. */ + EntityToken?: EntityTokenResponse; + /** True if the account was newly created on this authentication. */ + NewlyCreated: boolean; + + } + + export interface DeleteRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The game_server entity to be removed. */ + Entity: EntityKey; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLineage { + /** The Character Id of the associated entity. */ + CharacterId?: string; + /** The Group Id of the associated entity. */ + GroupId?: string; + /** The Master Player Account Id of the associated entity. */ + MasterPlayerAccountId?: string; + /** The Namespace Id of the associated entity. */ + NamespaceId?: string; + /** The Title Id of the associated entity. */ + TitleId?: string; + /** The Title Player Account Id of the associated entity. */ + TitlePlayerAccountId?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + + export interface GetEntityTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetEntityTokenResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + + type IdentifiedDeviceType = "Unknown" + + | "XboxOne" + | "Scarlett" + | "WindowsOneCore" + | "WindowsOneCoreMobile" + | "Win32" + | "android" + | "iOS" + | "PlayStation" + | "Nintendo"; + + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface ValidateEntityTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Client EntityToken */ + EntityToken: string; + + } + + export interface ValidateEntityTokenResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The authenticated device for this entity, for the given login */ + IdentifiedDeviceType?: string; + /** The identity provider for this entity, for the given login */ + IdentityProvider?: string; + /** The ID issued by the identity provider, e.g. a XUID on Xbox Live */ + IdentityProviderIssuedId?: string; + /** The lineage of this profile. */ + Lineage?: EntityLineage; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabClientApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabClientApi.d.ts index 5e13abf0..b75e42e4 100644 --- a/PlayFabSdk/src/Typings/PlayFab/PlayFabClientApi.d.ts +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabClientApi.d.ts @@ -4,1235 +4,1504 @@ declare module PlayFabClientModule { export interface IPlayFabClient { IsClientLoggedIn(): boolean; + ForgetAllCredentials(): void; + + /** + * Accepts an open trade (one that has not yet been accepted or cancelled), if the locally signed-in player is in the + * allowed player list for the trade, or it is open to all players. If the call is successful, the offered and accepted + * items will be swapped between the two players' inventories. + * https://docs.microsoft.com/rest/api/playfab/client/trading/accepttrade + */ + AcceptTrade(request: PlayFabClientModels.AcceptTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds the PlayFab user, based upon a match against a supplied unique identifier, to the friend list of the local user. At + * least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/addfriend + */ + AddFriend(request: PlayFabClientModels.AddFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab + * ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as + * authentication credentials, as the intent is that it is easily accessible by other players. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addgenericid + */ + AddGenericID(request: PlayFabClientModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds or updates a contact email to the player's profile. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addorupdatecontactemail + */ + AddOrUpdateContactEmail(request: PlayFabClientModels.AddOrUpdateContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users + * in the group can add new members. Shared Groups are designed for sharing data between a very small number of players, + * please see our guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/addsharedgroupmembers + */ + AddSharedGroupMembers(request: PlayFabClientModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds playfab username/password auth to an existing account created via an anonymous auth method, e.g. automatic device + * ID login. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addusernamepassword + */ + AddUsernamePassword(request: PlayFabClientModels.AddUsernamePasswordRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the user's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/adduservirtualcurrency + */ + AddUserVirtualCurrency(request: PlayFabClientModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers the Android device to receive push notifications + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/androiddevicepushnotificationregistration + */ + AndroidDevicePushNotificationRegistration(request: PlayFabClientModels.AndroidDevicePushNotificationRegistrationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Attributes an install for advertisment. + * https://docs.microsoft.com/rest/api/playfab/client/advertising/attributeinstall + */ + AttributeInstall(request: PlayFabClientModels.AttributeInstallRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancels an open trade (one that has not yet been accepted or cancelled). Note that only the player who created the trade + * can cancel it via this API call, to prevent griefing of the trade system (cancelling trades in order to prevent other + * players from accepting them, for trades that can be claimed by more than one player). + * https://docs.microsoft.com/rest/api/playfab/client/trading/canceltrade + */ + CancelTrade(request: PlayFabClientModels.CancelTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Confirms with the payment provider that the purchase was approved (if applicable) and adjusts inventory and + * virtual currency balances as appropriate + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/confirmpurchase + */ + ConfirmPurchase(request: PlayFabClientModels.ConfirmPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's + * inventory. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/consumeitem + */ + ConsumeItem(request: PlayFabClientModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Grants the player's current entitlements from Microsoft Store's Collection API + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumemicrosoftstoreentitlements + */ + ConsumeMicrosoftStoreEntitlements(request: PlayFabClientModels.ConsumeMicrosoftStoreEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks for any new consumable entitlements. If any are found, they are consumed (if they're consumables) and added as + * PlayFab items + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumeps5entitlements + */ + ConsumePS5Entitlements(request: PlayFabClientModels.ConsumePS5EntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks for any new consumable entitlements. If any are found, they are consumed and added as PlayFab items + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumepsnentitlements + */ + ConsumePSNEntitlements(request: PlayFabClientModels.ConsumePSNEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Grants the player's current entitlements from Xbox Live, consuming all availble items in Xbox and granting them to the + * player's PlayFab inventory. This call is idempotent and will not grant previously granted items to the player. + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumexboxentitlements + */ + ConsumeXboxEntitlements(request: PlayFabClientModels.ConsumeXboxEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the + * group. Upon creation, the current user will be the only member of the group. Shared Groups are designed for sharing data + * between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/createsharedgroup + */ + CreateSharedGroup(request: PlayFabClientModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/deleteplayercustomproperties + */ + DeletePlayerCustomProperties(request: PlayFabClientModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. The + * PlayFab ID is the entity ID of the player's master_player_account entity. + * https://docs.microsoft.com/rest/api/playfab/client/server-side-cloud-script/executecloudscript + */ + ExecuteCloudScript(request: PlayFabClientModels.ExecuteCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the user's PlayFab account details + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getaccountinfo + */ + GetAccountInfo(request: PlayFabClientModels.GetAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Returns a list of ad placements and a reward for each + * https://docs.microsoft.com/rest/api/playfab/client/advertising/getadplacements + */ + GetAdPlacements(request: PlayFabClientModels.GetAdPlacementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be + * evaluated with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/client/characters/getalluserscharacters + */ + GetAllUsersCharacters(request: PlayFabClientModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getcatalogitems + */ + GetCatalogItems(request: PlayFabClientModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title-specific custom data for the character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/getcharacterdata + */ + GetCharacterData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified character's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getcharacterinventory + */ + GetCharacterInventory(request: PlayFabClientModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/characters/getcharacterleaderboard + */ + GetCharacterLeaderboard(request: PlayFabClientModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title-specific custom data for the character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/getcharacterreadonlydata + */ + GetCharacterReadOnlyData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the details of all title-specific statistics for the user + * https://docs.microsoft.com/rest/api/playfab/client/characters/getcharacterstatistics + */ + GetCharacterStatistics(request: PlayFabClientModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned + * URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the + * content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, + * the query to retrieve the data will fail. See this post for more information: + * https://community.playfab.com/hc/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, + * please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. + * https://docs.microsoft.com/rest/api/playfab/client/content/getcontentdownloadurl + */ + GetContentDownloadUrl(request: PlayFabClientModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked friends of the current player for the given statistic, starting from the indicated point in + * the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getfriendleaderboard + */ + GetFriendLeaderboard(request: PlayFabClientModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked friends of the current player for the given statistic, centered on the requested PlayFab + * user. If PlayFabId is empty or null will return currently logged in user. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getfriendleaderboardaroundplayer + */ + GetFriendLeaderboardAroundPlayer(request: PlayFabClientModels.GetFriendLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the current friend list for the local user, constrained to users who have PlayFab accounts. Friends from + * linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/getfriendslist + */ + GetFriendsList(request: PlayFabClientModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getleaderboard + */ + GetLeaderboard(request: PlayFabClientModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked characters for the given statistic, centered on the requested Character ID + * https://docs.microsoft.com/rest/api/playfab/client/characters/getleaderboardaroundcharacter + */ + GetLeaderboardAroundCharacter(request: PlayFabClientModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked users for the given statistic, centered on the requested player. If PlayFabId is empty or + * null will return currently logged in user. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getleaderboardaroundplayer + */ + GetLeaderboardAroundPlayer(request: PlayFabClientModels.GetLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of all of the user's characters for the given statistic. + * https://docs.microsoft.com/rest/api/playfab/client/characters/getleaderboardforusercharacters + */ + GetLeaderboardForUserCharacters(request: PlayFabClientModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ For payments flows where the provider requires playfab (the fulfiller) to initiate the transaction, but the + * client completes the rest of the flow. In the Xsolla case, the token returned here will be passed to Xsolla by the + * client to create a cart. Poll GetPurchase using the returned OrderId once you've completed the payment. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getpaymenttoken + */ + GetPaymentToken(request: PlayFabClientModels.GetPaymentTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a Photon custom authentication token that can be used to securely join the player into a Photon room. See + * https://docs.microsoft.com/gaming/playfab/features/multiplayer/photon/quickstart for more details. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/getphotonauthenticationtoken + */ + GetPhotonAuthenticationToken(request: PlayFabClientModels.GetPhotonAuthenticationTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves all of the user's different kinds of info. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayercombinedinfo + */ + GetPlayerCombinedInfo(request: PlayFabClientModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayercustomproperty + */ + GetPlayerCustomProperty(request: PlayFabClientModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayerprofile + */ + GetPlayerProfile(request: PlayFabClientModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/client/playstream/getplayersegments + */ + GetPlayerSegments(request: PlayFabClientModels.GetPlayerSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the indicated statistics (current version and values for all statistics, if none are specified), for the local + * player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayerstatistics + */ + GetPlayerStatistics(request: PlayFabClientModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayerstatisticversions + */ + GetPlayerStatisticVersions(request: PlayFabClientModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/client/playstream/getplayertags + */ + GetPlayerTags(request: PlayFabClientModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets all trades the player has either opened or accepted, optionally filtered by trade status. + * https://docs.microsoft.com/rest/api/playfab/client/trading/getplayertrades + */ + GetPlayerTrades(request: PlayFabClientModels.GetPlayerTradesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the unique PlayFab identifiers for the given set of Battle.net account identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrombattlenetaccountids + */ + GetPlayFabIDsFromBattleNetAccountIds(request: PlayFabClientModels.GetPlayFabIDsFromBattleNetAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets a Photon custom authentication token that can be used to securely join the player into a Photon room. See https://api.playfab.com/docs/using-photon-with-playfab/ for more details. - / https://api.playfab.com/Documentation/Client/method/GetPhotonAuthenticationToken + * Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromfacebookids */ - GetPhotonAuthenticationToken(request: PlayFabClientModels.GetPhotonAuthenticationTokenRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookIDs(request: PlayFabClientModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests a challenge from the server to be signed by Windows Hello Passport service to authenticate. - / https://api.playfab.com/Documentation/Client/method/GetWindowsHelloChallenge + * Retrieves the unique PlayFab identifiers for the given set of Facebook Instant Game identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromfacebookinstantgamesids */ - GetWindowsHelloChallenge(request: PlayFabClientModels.GetWindowsHelloChallengeRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookInstantGamesIds(request: PlayFabClientModels.GetPlayFabIDsFromFacebookInstantGamesIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Link Windows Hello to the current PlayFab Account - / https://api.playfab.com/Documentation/Client/method/LinkWindowsHello + * Retrieves the unique PlayFab identifiers for the given set of Game Center identifiers (referenced in the Game Center + * Programming Guide as the Player Identifier). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgamecenterids */ - LinkWindowsHello(request: PlayFabClientModels.LinkWindowsHelloAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGameCenterIDs(request: PlayFabClientModels.GetPlayFabIDsFromGameCenterIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithAndroidDeviceID + * Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the generic identifier was + * added to the player account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgenericids */ - LoginWithAndroidDeviceID(request: PlayFabClientModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGenericIDs(request: PlayFabClientModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithCustomID + * Retrieves the unique PlayFab identifiers for the given set of Google identifiers. The Google identifiers are the IDs for + * the user accounts, available as "id" in the Google+ People API calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgoogleids */ - LoginWithCustomID(request: PlayFabClientModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGoogleIDs(request: PlayFabClientModels.GetPlayFabIDsFromGoogleIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithEmailAddress + * Retrieves the unique PlayFab identifiers for the given set of Google Play Games identifiers. The Google Play Games + * identifiers are the IDs for the user accounts, available as "playerId" in the Google Play Games Services - Players API + * calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgoogleplaygamesplayerids */ - LoginWithEmailAddress(request: PlayFabClientModels.LoginWithEmailAddressRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGooglePlayGamesPlayerIDs(request: PlayFabClientModels.GetPlayFabIDsFromGooglePlayGamesPlayerIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Facebook access token, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithFacebook + * Retrieves the unique PlayFab identifiers for the given set of Kongregate identifiers. The Kongregate identifiers are the + * IDs for the user accounts, available as "user_id" from the Kongregate API methods(ex: + * http://developers.kongregate.com/docs/client/getUserId). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromkongregateids */ - LoginWithFacebook(request: PlayFabClientModels.LoginWithFacebookRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromKongregateIDs(request: PlayFabClientModels.GetPlayFabIDsFromKongregateIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using an iOS Game Center player identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithGameCenter + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Service Account identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromnintendoserviceaccountids */ - LoginWithGameCenter(request: PlayFabClientModels.LoginWithGameCenterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoServiceAccountIds(request: PlayFabClientModels.GetPlayFabIDsFromNintendoServiceAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using their Google account credentials - / https://api.playfab.com/Documentation/Client/method/LoginWithGoogleAccount + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Switch Device identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromnintendoswitchdeviceids */ - LoginWithGoogleAccount(request: PlayFabClientModels.LoginWithGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoSwitchDeviceIds(request: PlayFabClientModels.GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using the vendor-specific iOS device identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithIOSDeviceID + * Retrieves the unique PlayFab identifiers for the given set of OpenId subject identifiers. A OpenId identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the OpenId identifier was added + * to the player account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromopenidsubjectidentifiers */ - LoginWithIOSDeviceID(request: PlayFabClientModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromOpenIdSubjectIdentifiers(request: PlayFabClientModels.GetPlayFabIDsFromOpenIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Kongregate player account. - / https://api.playfab.com/Documentation/Client/method/LoginWithKongregate + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrompsnaccountids */ - LoginWithKongregate(request: PlayFabClientModels.LoginWithKongregateRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNAccountIDs(request: PlayFabClientModels.GetPlayFabIDsFromPSNAccountIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls which require an authenticated user. Unlike other login API calls, LoginWithEmailAddress does not permit the creation of new accounts via the CreateAccountFlag. Email accounts must be created using the RegisterPlayFabUser API or added to existing accounts using AddUsernamePassword. - / https://api.playfab.com/Documentation/Client/method/LoginWithPlayFab + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrompsnonlineids */ - LoginWithPlayFab(request: PlayFabClientModels.LoginWithPlayFabRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNOnlineIDs(request: PlayFabClientModels.GetPlayFabIDsFromPSNOnlineIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Steam authentication ticket, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithSteam + * Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile + * IDs for the user accounts, available as SteamId in the Steamworks Community API calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromsteamids */ - LoginWithSteam(request: PlayFabClientModels.LoginWithSteamRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamIDs(request: PlayFabClientModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Twitch access token. - / https://api.playfab.com/Documentation/Client/method/LoginWithTwitch + * 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 */ - LoginWithTwitch(request: PlayFabClientModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamNames(request: PlayFabClientModels.GetPlayFabIDsFromSteamNamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completes the Windows Hello login flow by returning the signed value of the challange from GetWindowsHelloChallenge. Windows Hello has a 2 step client to server authentication scheme. Step one is to request from the server a challenge string. Step two is to request the user sign the string via Windows Hello and then send the signed value back to the server. - / https://api.playfab.com/Documentation/Client/method/LoginWithWindowsHello + * 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). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromtwitchids */ - LoginWithWindowsHello(request: PlayFabClientModels.LoginWithWindowsHelloRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromTwitchIDs(request: PlayFabClientModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers a new Playfab user account, returning a session identifier that can subsequently be used for API calls which require an authenticated user. You must supply either a username or an email address. - / https://api.playfab.com/Documentation/Client/method/RegisterPlayFabUser + * Retrieves the unique PlayFab identifiers for the given set of XboxLive identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromxboxliveids */ - RegisterPlayFabUser(request: PlayFabClientModels.RegisterPlayFabUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromXboxLiveIDs(request: PlayFabClientModels.GetPlayFabIDsFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Register using Windows Hello authentication. Before a user can request a challenge or perform a signin the user must first either register or link a Windows Hello account. - / https://api.playfab.com/Documentation/Client/method/RegisterWithWindowsHello + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getpublisherdata */ - RegisterWithWindowsHello(request: PlayFabClientModels.RegisterWithWindowsHelloRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabClientModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlink Windows Hello from the current PlayFab Account - / https://api.playfab.com/Documentation/Client/method/UnlinkWindowsHello + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves a purchase along with its current PlayFab status. Returns inventory items from the purchase that + * are still active. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getpurchase */ - UnlinkWindowsHello(request: PlayFabClientModels.UnlinkWindowsHelloAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPurchase(request: PlayFabClientModels.GetPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as authentication credentials, as the intent is that it is easily accessible by other players. - / https://api.playfab.com/Documentation/Client/method/AddGenericID + * Retrieves data stored in a shared group object, as well as the list of members in the group. Non-members of the group + * may use this to retrieve group data, including membership, but they will not receive data for keys marked as private. + * Shared Groups are designed for sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/getsharedgroupdata */ - AddGenericID(request: PlayFabClientModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback): void; + GetSharedGroupData(request: PlayFabClientModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds playfab username/password auth to an existing account created via an anonymous auth method, e.g. automatic device ID login. - / https://api.playfab.com/Documentation/Client/method/AddUsernamePassword + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getstoreitems */ - AddUsernamePassword(request: PlayFabClientModels.AddUsernamePasswordRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabClientModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the user's PlayFab account details - / https://api.playfab.com/Documentation/Client/method/GetAccountInfo + * Retrieves the current server time + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettime */ - GetAccountInfo(request: PlayFabClientModels.GetAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTime(request: PlayFabClientModels.GetTimeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves all of the user's different kinds of info. - / https://api.playfab.com/Documentation/Client/method/GetPlayerCombinedInfo + * Retrieves the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettitledata */ - GetPlayerCombinedInfo(request: PlayFabClientModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabClientModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromFacebookIDs + * Retrieves the title news feed, as configured in the developer portal + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettitlenews */ - GetPlayFabIDsFromFacebookIDs(request: PlayFabClientModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleNews(request: PlayFabClientModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Game Center identifiers (referenced in the Game Center Programming Guide as the Player Identifier). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGameCenterIDs + * Returns the title's base 64 encoded RSA CSP blob. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/gettitlepublickey */ - GetPlayFabIDsFromGameCenterIDs(request: PlayFabClientModels.GetPlayFabIDsFromGameCenterIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitlePublicKey(request: PlayFabClientModels.GetTitlePublicKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the service name plus the service-specific ID for the player, as specified by the title when the generic identifier was added to the player account. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGenericIDs + * Gets the current status of an existing trade. + * https://docs.microsoft.com/rest/api/playfab/client/trading/gettradestatus */ - GetPlayFabIDsFromGenericIDs(request: PlayFabClientModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTradeStatus(request: PlayFabClientModels.GetTradeStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Google identifiers. The Google identifiers are the IDs for the user accounts, available as "id" in the Google+ People API calls. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGoogleIDs + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserdata */ - GetPlayFabIDsFromGoogleIDs(request: PlayFabClientModels.GetPlayFabIDsFromGoogleIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Kongregate identifiers. The Kongregate identifiers are the IDs for the user accounts, available as "user_id" from the Kongregate API methods(ex: http://developers.kongregate.com/docs/client/getUserId). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromKongregateIDs + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getuserinventory */ - GetPlayFabIDsFromKongregateIDs(request: PlayFabClientModels.GetPlayFabIDsFromKongregateIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabClientModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile IDs for the user accounts, available as SteamId in the Steamworks Community API calls. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromSteamIDs + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserpublisherdata */ - GetPlayFabIDsFromSteamIDs(request: PlayFabClientModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / 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). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromTwitchIDs + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserpublisherreadonlydata */ - GetPlayFabIDsFromTwitchIDs(request: PlayFabClientModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Android device identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkAndroidDeviceID + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserreadonlydata */ - LinkAndroidDeviceID(request: PlayFabClientModels.LinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the custom identifier, generated by the title, to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkCustomID + * Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated + * with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/client/characters/grantcharactertouser */ - LinkCustomID(request: PlayFabClientModels.LinkCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + GrantCharacterToUser(request: PlayFabClientModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Facebook account associated with the provided Facebook access token to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkFacebookAccount + * Links the Android device identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkandroiddeviceid */ - LinkFacebookAccount(request: PlayFabClientModels.LinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkAndroidDeviceID(request: PlayFabClientModels.LinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Game Center account associated with the provided Game Center ID to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkGameCenterAccount + * Links the Apple account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkapple */ - LinkGameCenterAccount(request: PlayFabClientModels.LinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkApple(request: PlayFabClientModels.LinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the currently signed-in user account to their Google account, using their Google account credentials - / https://api.playfab.com/Documentation/Client/method/LinkGoogleAccount + * Links the Battle.net account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkbattlenetaccount */ - LinkGoogleAccount(request: PlayFabClientModels.LinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkBattleNetAccount(request: PlayFabClientModels.LinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the vendor-specific iOS device identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkIOSDeviceID + * Links the custom identifier, generated by the title, to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkcustomid */ - LinkIOSDeviceID(request: PlayFabClientModels.LinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkCustomID(request: PlayFabClientModels.LinkCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Kongregate identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkKongregate + * Links the Facebook account associated with the provided Facebook access token to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkfacebookaccount */ - LinkKongregate(request: PlayFabClientModels.LinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkFacebookAccount(request: PlayFabClientModels.LinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Steam account associated with the provided Steam authentication ticket to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkSteamAccount + * Links the Facebook Instant Games Id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkfacebookinstantgamesid */ - LinkSteamAccount(request: PlayFabClientModels.LinkSteamAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkFacebookInstantGamesId(request: PlayFabClientModels.LinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Twitch account associated with the token to the user's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/LinkTwitch + * Links the Game Center account associated with the provided Game Center ID to the user's PlayFab account. Logging in with + * a Game Center ID is insecure if you do not include the optional PublicKeyUrl, Salt, Signature, and Timestamp parameters + * in this request. It is recommended you require these parameters on all Game Center calls by going to the Apple Add-ons + * page in the PlayFab Game Manager and enabling the 'Require secure authentication only for this app' option. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgamecenteraccount */ - LinkTwitch(request: PlayFabClientModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkGameCenterAccount(request: PlayFabClientModels.LinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the specified generic service identifier from the player's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/RemoveGenericID + * Links the currently signed-in user account to their Google account, using their Google account credentials + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgoogleaccount */ - RemoveGenericID(request: PlayFabClientModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkGoogleAccount(request: PlayFabClientModels.LinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Submit a report for another player (due to bad bahavior, etc.), so that customer service representatives for the title can take action concerning potentially toxic players. - / https://api.playfab.com/Documentation/Client/method/ReportPlayer + * Links the currently signed-in user account to their Google Play Games account, using their Google Play Games account + * credentials + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgoogleplaygamesservicesaccount */ - ReportPlayer(request: PlayFabClientModels.ReportPlayerClientRequest, callback: PlayFabModule.ApiCallback): void; + LinkGooglePlayGamesServicesAccount(request: PlayFabClientModels.LinkGooglePlayGamesServicesAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to change the password - / https://api.playfab.com/Documentation/Client/method/SendAccountRecoveryEmail + * Links the vendor-specific iOS device identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkiosdeviceid */ - SendAccountRecoveryEmail(request: PlayFabClientModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback): void; + LinkIOSDeviceID(request: PlayFabClientModels.LinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Android device identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkAndroidDeviceID + * Links the Kongregate identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkkongregate */ - UnlinkAndroidDeviceID(request: PlayFabClientModels.UnlinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkKongregate(request: PlayFabClientModels.LinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related custom identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkCustomID + * Links the Nintendo account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linknintendoserviceaccount */ - UnlinkCustomID(request: PlayFabClientModels.UnlinkCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccount(request: PlayFabClientModels.LinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Facebook account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkFacebookAccount + * Links the NintendoSwitchDeviceId to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linknintendoswitchdeviceid */ - UnlinkFacebookAccount(request: PlayFabClientModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoSwitchDeviceId(request: PlayFabClientModels.LinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Game Center account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkGameCenterAccount + * Links an OpenID Connect account to a user's PlayFab account, based on an existing relationship between a title and an + * Open ID Connect provider and the OpenId Connect JWT from that provider. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkopenidconnect */ - UnlinkGameCenterAccount(request: PlayFabClientModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkOpenIdConnect(request: PlayFabClientModels.LinkOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Google account from the user's PlayFab account (https://developers.google.com/android/reference/com/google/android/gms/auth/GoogleAuthUtil#public-methods). - / https://api.playfab.com/Documentation/Client/method/UnlinkGoogleAccount + * Links the PlayStation :tm: Network account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkpsnaccount */ - UnlinkGoogleAccount(request: PlayFabClientModels.UnlinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNAccount(request: PlayFabClientModels.LinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related iOS device identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkIOSDeviceID + * Links the Steam account associated with the provided Steam authentication ticket to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linksteamaccount */ - UnlinkIOSDeviceID(request: PlayFabClientModels.UnlinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkSteamAccount(request: PlayFabClientModels.LinkSteamAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Kongregate identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkKongregate + * Links the Twitch account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linktwitch */ - UnlinkKongregate(request: PlayFabClientModels.UnlinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkTwitch(request: PlayFabClientModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Steam account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkSteamAccount + * Links the Xbox Live account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkxboxaccount */ - UnlinkSteamAccount(request: PlayFabClientModels.UnlinkSteamAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxAccount(request: PlayFabClientModels.LinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Twitch account from the user's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/UnlinkTwitch + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/listplayercustomproperties */ - UnlinkTwitch(request: PlayFabClientModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabClientModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update the avatar URL of the player - / https://api.playfab.com/Documentation/Client/method/UpdateAvatarUrl + * Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithandroiddeviceid */ - UpdateAvatarUrl(request: PlayFabClientModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithAndroidDeviceID(request: PlayFabClientModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title specific display name for the user - / https://api.playfab.com/Documentation/Client/method/UpdateUserTitleDisplayName + * Signs in the user with a Sign in with Apple identity token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithapple */ - UpdateUserTitleDisplayName(request: PlayFabClientModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithApple(request: PlayFabClientModels.LoginWithAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the current player for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetFriendLeaderboard + * Sign in the user with a Battle.net identity token + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithbattlenet */ - GetFriendLeaderboard(request: PlayFabClientModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithBattleNet(request: PlayFabClientModels.LoginWithBattleNetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the current player for the given statistic, centered on the requested PlayFab user. If PlayFabId is empty or null will return currently logged in user. - / https://api.playfab.com/Documentation/Client/method/GetFriendLeaderboardAroundPlayer + * Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithcustomid */ - GetFriendLeaderboardAroundPlayer(request: PlayFabClientModels.GetFriendLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithCustomID(request: PlayFabClientModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetLeaderboard + * Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user. Unlike most other login API calls, LoginWithEmailAddress does not permit the + * creation of new accounts via the CreateAccountFlag. Email addresses may be used to create accounts via + * RegisterPlayFabUser. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithemailaddress */ - GetLeaderboard(request: PlayFabClientModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithEmailAddress(request: PlayFabClientModels.LoginWithEmailAddressRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, centered on the requested player. If PlayFabId is empty or null will return currently logged in user. - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardAroundPlayer + * Signs the user in using a Facebook access token, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithfacebook */ - GetLeaderboardAroundPlayer(request: PlayFabClientModels.GetLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithFacebook(request: PlayFabClientModels.LoginWithFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the indicated statistics (current version and values for all statistics, if none are specified), for the local player. - / https://api.playfab.com/Documentation/Client/method/GetPlayerStatistics + * Signs the user in using a Facebook Instant Games ID, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user. Requires Facebook Instant Games to be configured. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithfacebookinstantgamesid */ - GetPlayerStatistics(request: PlayFabClientModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithFacebookInstantGamesId(request: PlayFabClientModels.LoginWithFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Client/method/GetPlayerStatisticVersions + * Signs the user in using an iOS Game Center player identifier, returning a session identifier that can subsequently be + * used for API calls which require an authenticated user. Logging in with a Game Center ID is insecure if you do not + * include the optional PublicKeyUrl, Salt, Signature, and Timestamp parameters in this request. It is recommended you + * require these parameters on all Game Center calls by going to the Apple Add-ons page in the PlayFab Game Manager and + * enabling the 'Require secure authentication only for this app' option. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgamecenter */ - GetPlayerStatisticVersions(request: PlayFabClientModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGameCenter(request: PlayFabClientModels.LoginWithGameCenterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetUserData + * Signs the user in using their Google account credentials + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgoogleaccount */ - GetUserData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGoogleAccount(request: PlayFabClientModels.LoginWithGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetUserPublisherData + * Signs the user in using their Google Play Games account credentials + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgoogleplaygamesservices */ - GetUserPublisherData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGooglePlayGamesServices(request: PlayFabClientModels.LoginWithGooglePlayGamesServicesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetUserPublisherReadOnlyData + * Signs the user in using the vendor-specific iOS device identifier, returning a session identifier that can subsequently + * be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithiosdeviceid */ - GetUserPublisherReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithIOSDeviceID(request: PlayFabClientModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetUserReadOnlyData + * Signs the user in using a Kongregate player account. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithkongregate */ - GetUserReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithKongregate(request: PlayFabClientModels.LoginWithKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the user. By default, clients are not permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. - / https://api.playfab.com/Documentation/Client/method/UpdatePlayerStatistics + * Signs in the user with a Nintendo service account token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithnintendoserviceaccount */ - UpdatePlayerStatistics(request: PlayFabClientModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithNintendoServiceAccount(request: PlayFabClientModels.LoginWithNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateUserData + * Signs the user in using a Nintendo Switch Device ID, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithnintendoswitchdeviceid */ - UpdateUserData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithNintendoSwitchDeviceId(request: PlayFabClientModels.LoginWithNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateUserPublisherData + * Logs in a user with an Open ID Connect JWT created by an existing relationship between a title and an Open ID Connect + * provider. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithopenidconnect */ - UpdateUserPublisherData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithOpenIdConnect(request: PlayFabClientModels.LoginWithOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Client/method/GetCatalogItems + * Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user. Unlike most other login API calls, LoginWithPlayFab does not permit the creation of + * new accounts via the CreateAccountFlag. Username/Password credentials may be used to create accounts via + * RegisterPlayFabUser, or added to existing accounts using AddUsernamePassword. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithplayfab */ - GetCatalogItems(request: PlayFabClientModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPlayFab(request: PlayFabClientModels.LoginWithPlayFabRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Client/method/GetPublisherData + * Signs the user in using a PlayStation :tm: Network authentication code, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithpsn */ - GetPublisherData(request: PlayFabClientModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPSN(request: PlayFabClientModels.LoginWithPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the set of items defined for the specified store, including all prices defined - / https://api.playfab.com/Documentation/Client/method/GetStoreItems + * Signs the user in using a Steam authentication ticket, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithsteam */ - GetStoreItems(request: PlayFabClientModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithSteam(request: PlayFabClientModels.LoginWithSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current server time - / https://api.playfab.com/Documentation/Client/method/GetTime + * Signs the user in using a Twitch access token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithtwitch */ - GetTime(request: PlayFabClientModels.GetTimeRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithTwitch(request: PlayFabClientModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings - / https://api.playfab.com/Documentation/Client/method/GetTitleData + * Signs the user in using a Xbox Live Token, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithxbox */ - GetTitleData(request: PlayFabClientModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXbox(request: PlayFabClientModels.LoginWithXboxRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title news feed, as configured in the developer portal - / https://api.playfab.com/Documentation/Client/method/GetTitleNews + * Opens a new outstanding trade. Note that a given item instance may only be in one open trade at a time. + * https://docs.microsoft.com/rest/api/playfab/client/trading/opentrade */ - GetTitleNews(request: PlayFabClientModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback): void; + OpenTrade(request: PlayFabClientModels.OpenTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Client/method/AddUserVirtualCurrency + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Selects a payment option for purchase order created via StartPurchase + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/payforpurchase */ - AddUserVirtualCurrency(request: PlayFabClientModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + PayForPurchase(request: PlayFabClientModels.PayForPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Confirms with the payment provider that the purchase was approved (if applicable) and adjusts inventory and virtual currency balances as appropriate - / https://api.playfab.com/Documentation/Client/method/ConfirmPurchase + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Buys a single item with virtual currency. You must specify both the virtual currency to use to purchase, as + * well as what the client believes the price to be. This lets the server fail the purchase if the price has changed. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/purchaseitem */ - ConfirmPurchase(request: PlayFabClientModels.ConfirmPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + PurchaseItem(request: PlayFabClientModels.PurchaseItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's inventory. - / https://api.playfab.com/Documentation/Client/method/ConsumeItem + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the + * Economy->Catalogs tab in the PlayFab Game Manager. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/redeemcoupon */ - ConsumeItem(request: PlayFabClientModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback): void; + RedeemCoupon(request: PlayFabClientModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified character's current inventory of virtual goods - / https://api.playfab.com/Documentation/Client/method/GetCharacterInventory + * Uses the supplied OAuth code to refresh the internally cached player PlayStation :tm: Network auth token + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/refreshpsnauthtoken */ - GetCharacterInventory(request: PlayFabClientModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback): void; + RefreshPSNAuthToken(request: PlayFabClientModels.RefreshPSNAuthTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a completed purchase along with its current PlayFab status. - / https://api.playfab.com/Documentation/Client/method/GetPurchase + * Registers the iOS device to receive push notifications + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/registerforiospushnotification */ - GetPurchase(request: PlayFabClientModels.GetPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RegisterForIOSPushNotification(request: PlayFabClientModels.RegisterForIOSPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Client/method/GetUserInventory + * Registers a new Playfab user account, returning a session identifier that can subsequently be used for API calls which + * require an authenticated user. You must supply a username and an email address. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/registerplayfabuser */ - GetUserInventory(request: PlayFabClientModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + RegisterPlayFabUser(request: PlayFabClientModels.RegisterPlayFabUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Selects a payment option for purchase order created via StartPurchase - / https://api.playfab.com/Documentation/Client/method/PayForPurchase + * Removes a contact email from the player's profile. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/removecontactemail */ - PayForPurchase(request: PlayFabClientModels.PayForPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RemoveContactEmail(request: PlayFabClientModels.RemoveContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Buys a single item with virtual currency. You must specify both the virtual currency to use to purchase, as well as what the client believes the price to be. This lets the server fail the purchase if the price has changed. - / https://api.playfab.com/Documentation/Client/method/PurchaseItem + * Removes a specified user from the friend list of the local user + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/removefriend */ - PurchaseItem(request: PlayFabClientModels.PurchaseItemRequest, callback: PlayFabModule.ApiCallback): void; + RemoveFriend(request: PlayFabClientModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the Economy->Catalogs tab in the PlayFab Game Manager. - / https://api.playfab.com/Documentation/Client/method/RedeemCoupon + * Removes the specified generic service identifier from the player's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/removegenericid */ - RedeemCoupon(request: PlayFabClientModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback): void; + RemoveGenericID(request: PlayFabClientModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates an order for a list of items from the title catalog - / https://api.playfab.com/Documentation/Client/method/StartPurchase + * Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the + * group can remove members. If as a result of the call, zero users remain with access, the group and its associated data + * will be deleted. Shared Groups are designed for sharing data between a very small number of players, please see our + * guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/removesharedgroupmembers */ - StartPurchase(request: PlayFabClientModels.StartPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RemoveSharedGroupMembers(request: PlayFabClientModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Client/method/SubtractUserVirtualCurrency + * Report player's ad activity + * https://docs.microsoft.com/rest/api/playfab/client/advertising/reportadactivity */ - SubtractUserVirtualCurrency(request: PlayFabClientModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + ReportAdActivity(request: PlayFabClientModels.ReportAdActivityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens the specified container, with the specified key (when required), and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Client/method/UnlockContainerInstance + * Write a PlayStream event to describe the provided player device information. This API method is not designed to be + * called directly by developers. Each PlayFab client SDK will eventually report this information automatically. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/reportdeviceinfo */ - UnlockContainerInstance(request: PlayFabClientModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback): void; + ReportDeviceInfo(request: PlayFabClientModels.DeviceInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Searches target inventory for an ItemInstance matching the given CatalogItemId, if necessary unlocks it using an appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Client/method/UnlockContainerItem + * Submit a report for another player (due to bad bahavior, etc.), so that customer service representatives for the title + * can take action concerning potentially toxic players. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/reportplayer */ - UnlockContainerItem(request: PlayFabClientModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback): void; + ReportPlayer(request: PlayFabClientModels.ReportPlayerClientRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the PlayFab user, based upon a match against a supplied unique identifier, to the friend list of the local user. At least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. - / https://api.playfab.com/Documentation/Client/method/AddFriend + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Restores all in-app purchases based on the given restore receipt + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/restoreiospurchases */ - AddFriend(request: PlayFabClientModels.AddFriendRequest, callback: PlayFabModule.ApiCallback): void; + RestoreIOSPurchases(request: PlayFabClientModels.RestoreIOSPurchasesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current friend list for the local user, constrained to users who have PlayFab accounts. Friends from linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. - / https://api.playfab.com/Documentation/Client/method/GetFriendsList + * Reward player's ad activity + * https://docs.microsoft.com/rest/api/playfab/client/advertising/rewardadactivity */ - GetFriendsList(request: PlayFabClientModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback): void; + RewardAdActivity(request: PlayFabClientModels.RewardAdActivityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes a specified user from the friend list of the local user - / https://api.playfab.com/Documentation/Client/method/RemoveFriend + * Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to + * change the password.If an account recovery email template ID is provided, an email using the custom email template will + * be used. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/sendaccountrecoveryemail */ - RemoveFriend(request: PlayFabClientModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback): void; + SendAccountRecoveryEmail(request: PlayFabClientModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the tag list for a specified user in the friend list of the local user - / https://api.playfab.com/Documentation/Client/method/SetFriendTags + * Updates the tag list for a specified user in the friend list of the local user + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/setfriendtags */ - SetFriendTags(request: PlayFabClientModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback): void; + SetFriendTags(request: PlayFabClientModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers the iOS device to receive push notifications - / https://api.playfab.com/Documentation/Client/method/RegisterForIOSPushNotification + * Sets the player's secret if it is not already set. Player secrets are used to sign API requests. To reset a player's + * secret use the Admin or Server API method SetPlayerSecret. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/setplayersecret */ - RegisterForIOSPushNotification(request: PlayFabClientModels.RegisterForIOSPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + SetPlayerSecret(request: PlayFabClientModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Restores all in-app purchases based on the given refresh receipt. - / https://api.playfab.com/Documentation/Client/method/RestoreIOSPurchases + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Creates an order for a list of items from the title catalog + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/startpurchase */ - RestoreIOSPurchases(request: PlayFabClientModels.RestoreIOSPurchasesRequest, callback: PlayFabModule.ApiCallback): void; + StartPurchase(request: PlayFabClientModels.StartPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with the Apple store that the receipt for an iOS in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateIOSReceipt + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the user's balance of the specified virtual currency by the stated amount. It is possible to make + * a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/subtractuservirtualcurrency */ - ValidateIOSReceipt(request: PlayFabClientModels.ValidateIOSReceiptRequest, callback: PlayFabModule.ApiCallback): void; + SubtractUserVirtualCurrency(request: PlayFabClientModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get details about all current running game servers matching the given parameters. - / https://api.playfab.com/Documentation/Client/method/GetCurrentGames + * Unlinks the related Android device identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkandroiddeviceid */ - GetCurrentGames(request: PlayFabClientModels.CurrentGamesRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkAndroidDeviceID(request: PlayFabClientModels.UnlinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get details about the regions hosting game servers matching the given parameters. - / https://api.playfab.com/Documentation/Client/method/GetGameServerRegions + * Unlinks the related Apple account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkapple */ - GetGameServerRegions(request: PlayFabClientModels.GameServerRegionsRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkApple(request: PlayFabClientModels.UnlinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to locate a game session matching the given parameters. If the goal is to match the player into a specific active session, only the LobbyId is required. Otherwise, the BuildVersion, GameMode, and Region are all required parameters. Note that parameters specified in the search are required (they are not weighting factors). If a slot is found in a server instance matching the parameters, the slot will be assigned to that player, removing it from the availabe set. In that case, the information on the game session will be returned, otherwise the Status returned will be GameNotFound. Note that EnableQueue is deprecated at this time. - / https://api.playfab.com/Documentation/Client/method/Matchmake + * Unlinks the related Battle.net account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkbattlenetaccount */ - Matchmake(request: PlayFabClientModels.MatchmakeRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkBattleNetAccount(request: PlayFabClientModels.UnlinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Start a new game server with a given configuration, add the current player and return the connection information. - / https://api.playfab.com/Documentation/Client/method/StartGame + * Unlinks the related custom identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkcustomid */ - StartGame(request: PlayFabClientModels.StartGameRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkCustomID(request: PlayFabClientModels.UnlinkCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers the Android device to receive push notifications - / https://api.playfab.com/Documentation/Client/method/AndroidDevicePushNotificationRegistration + * Unlinks the related Facebook account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkfacebookaccount */ - AndroidDevicePushNotificationRegistration(request: PlayFabClientModels.AndroidDevicePushNotificationRegistrationRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkFacebookAccount(request: PlayFabClientModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates a Google Play purchase and gives the corresponding item to the player. - / https://api.playfab.com/Documentation/Client/method/ValidateGooglePlayPurchase + * Unlinks the related Facebook Instant Game Ids from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkfacebookinstantgamesid */ - ValidateGooglePlayPurchase(request: PlayFabClientModels.ValidateGooglePlayPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkFacebookInstantGamesId(request: PlayFabClientModels.UnlinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a character-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WriteCharacterEvent + * Unlinks the related Game Center account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgamecenteraccount */ - WriteCharacterEvent(request: PlayFabClientModels.WriteClientCharacterEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGameCenterAccount(request: PlayFabClientModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a player-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WritePlayerEvent + * Unlinks the related Google account from the user's PlayFab account + * (https://developers.google.com/android/reference/com/google/android/gms/auth/GoogleAuthUtil#public-methods). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgoogleaccount */ - WritePlayerEvent(request: PlayFabClientModels.WriteClientPlayerEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGoogleAccount(request: PlayFabClientModels.UnlinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a title-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WriteTitleEvent + * Unlinks the related Google Play Games account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgoogleplaygamesservicesaccount */ - WriteTitleEvent(request: PlayFabClientModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGooglePlayGamesServicesAccount(request: PlayFabClientModels.UnlinkGooglePlayGamesServicesAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users in the group can add new members. - / https://api.playfab.com/Documentation/Client/method/AddSharedGroupMembers + * Unlinks the related iOS device identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkiosdeviceid */ - AddSharedGroupMembers(request: PlayFabClientModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkIOSDeviceID(request: PlayFabClientModels.UnlinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the group. Upon creation, the current user will be the only member of the group. - / https://api.playfab.com/Documentation/Client/method/CreateSharedGroup + * Unlinks the related Kongregate identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkkongregate */ - CreateSharedGroup(request: PlayFabClientModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkKongregate(request: PlayFabClientModels.UnlinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves data stored in a shared group object, as well as the list of members in the group. Non-members of the group may use this to retrieve group data, including membership, but they will not receive data for keys marked as private. - / https://api.playfab.com/Documentation/Client/method/GetSharedGroupData + * Unlinks the related Nintendo account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinknintendoserviceaccount */ - GetSharedGroupData(request: PlayFabClientModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkNintendoServiceAccount(request: PlayFabClientModels.UnlinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the group can remove members. If as a result of the call, zero users remain with access, the group and its associated data will be deleted. - / https://api.playfab.com/Documentation/Client/method/RemoveSharedGroupMembers + * Unlinks the related NintendoSwitchDeviceId from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinknintendoswitchdeviceid */ - RemoveSharedGroupMembers(request: PlayFabClientModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkNintendoSwitchDeviceId(request: PlayFabClientModels.UnlinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated or added in this call will be readable by users not in the group. By default, data permissions are set to Private. Regardless of the permission setting, only members of the group can update the data. - / https://api.playfab.com/Documentation/Client/method/UpdateSharedGroupData + * Unlinks an OpenID Connect account from a user's PlayFab account, based on the connection ID of an existing relationship + * between a title and an Open ID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkopenidconnect */ - UpdateSharedGroupData(request: PlayFabClientModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkOpenIdConnect(request: PlayFabClientModels.UnlinkOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. - / https://api.playfab.com/Documentation/Client/method/ExecuteCloudScript + * Unlinks the related PlayStation :tm: Network account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkpsnaccount */ - ExecuteCloudScript(request: PlayFabClientModels.ExecuteCloudScriptRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkPSNAccount(request: PlayFabClientModels.UnlinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, the query to retrieve the data will fail. See this post for more information: https://community.playfab.com/hc/en-us/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Client/method/GetContentDownloadUrl + * Unlinks the related Steam account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinksteamaccount */ - GetContentDownloadUrl(request: PlayFabClientModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkSteamAccount(request: PlayFabClientModels.UnlinkSteamAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Client/method/GetAllUsersCharacters + * Unlinks the related Twitch account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinktwitch */ - GetAllUsersCharacters(request: PlayFabClientModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkTwitch(request: PlayFabClientModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetCharacterLeaderboard + * Unlinks the related Xbox Live account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkxboxaccount */ - GetCharacterLeaderboard(request: PlayFabClientModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkXboxAccount(request: PlayFabClientModels.UnlinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of all title-specific statistics for the user - / https://api.playfab.com/Documentation/Client/method/GetCharacterStatistics + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Opens the specified container, with the specified key (when required), and returns the contents of the + * opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will + * be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/unlockcontainerinstance */ - GetCharacterStatistics(request: PlayFabClientModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + UnlockContainerInstance(request: PlayFabClientModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, centered on the requested Character ID - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardAroundCharacter + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Searches target inventory for an ItemInstance matching the given CatalogItemId, if necessary unlocks it + * using an appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are + * consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/unlockcontaineritem */ - GetLeaderboardAroundCharacter(request: PlayFabClientModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback): void; + UnlockContainerItem(request: PlayFabClientModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of all of the user's characters for the given statistic. - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardForUserCharacters + * Update the avatar URL of the player + * https://docs.microsoft.com/rest/api/playfab/client/account-management/updateavatarurl */ - GetLeaderboardForUserCharacters(request: PlayFabClientModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + UpdateAvatarUrl(request: PlayFabClientModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Client/method/GrantCharacterToUser + * Creates and updates the title-specific custom data for the user's character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/updatecharacterdata */ - GrantCharacterToUser(request: PlayFabClientModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback): void; + UpdateCharacterData(request: PlayFabClientModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the specific character. By default, clients are not permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. - / https://api.playfab.com/Documentation/Client/method/UpdateCharacterStatistics + * Updates the values of the specified title-specific statistics for the specific character. By default, clients are not + * permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. + * https://docs.microsoft.com/rest/api/playfab/client/characters/updatecharacterstatistics */ - UpdateCharacterStatistics(request: PlayFabClientModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + UpdateCharacterStatistics(request: PlayFabClientModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the character which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetCharacterData + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateplayercustomproperties */ - GetCharacterData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdatePlayerCustomProperties(request: PlayFabClientModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the character which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetCharacterReadOnlyData + * Updates the values of the specified title-specific statistics for the user. By default, clients are not permitted to + * update statistics. Developers may override this setting in the Game Manager > Settings > API Features. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateplayerstatistics */ - GetCharacterReadOnlyData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdatePlayerStatistics(request: PlayFabClientModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the title-specific custom data for the user's character which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateCharacterData + * Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated + * or added in this call will be readable by users not in the group. By default, data permissions are set to Private. + * Regardless of the permission setting, only members of the group can update the data. Shared Groups are designed for + * sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/updatesharedgroupdata */ - UpdateCharacterData(request: PlayFabClientModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdateSharedGroupData(request: PlayFabClientModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with Amazon that the receipt for an Amazon App Store in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateAmazonIAPReceipt + * Creates and updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateuserdata */ - ValidateAmazonIAPReceipt(request: PlayFabClientModels.ValidateAmazonReceiptRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Accepts an open trade (one that has not yet been accepted or cancelled), if the locally signed-in player is in the allowed player list for the trade, or it is open to all players. If the call is successful, the offered and accepted items will be swapped between the two players' inventories. - / https://api.playfab.com/Documentation/Client/method/AcceptTrade + * Creates and updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateuserpublisherdata */ - AcceptTrade(request: PlayFabClientModels.AcceptTradeRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserPublisherData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Cancels an open trade (one that has not yet been accepted or cancelled). Note that only the player who created the trade can cancel it via this API call, to prevent griefing of the trade system (cancelling trades in order to prevent other players from accepting them, for trades that can be claimed by more than one player). - / https://api.playfab.com/Documentation/Client/method/CancelTrade + * Updates the title specific display name for the user + * https://docs.microsoft.com/rest/api/playfab/client/account-management/updateusertitledisplayname */ - CancelTrade(request: PlayFabClientModels.CancelTradeRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserTitleDisplayName(request: PlayFabClientModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all trades the player has either opened or accepted, optionally filtered by trade status. - / https://api.playfab.com/Documentation/Client/method/GetPlayerTrades + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with Amazon that the receipt for an Amazon App Store in-app purchase is valid and that it matches + * the purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validateamazoniapreceipt */ - GetPlayerTrades(request: PlayFabClientModels.GetPlayerTradesRequest, callback: PlayFabModule.ApiCallback): void; + ValidateAmazonIAPReceipt(request: PlayFabClientModels.ValidateAmazonReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets the current status of an existing trade. - / https://api.playfab.com/Documentation/Client/method/GetTradeStatus + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates a Google Play purchase and gives the corresponding item to the player. + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validategoogleplaypurchase */ - GetTradeStatus(request: PlayFabClientModels.GetTradeStatusRequest, callback: PlayFabModule.ApiCallback): void; + ValidateGooglePlayPurchase(request: PlayFabClientModels.ValidateGooglePlayPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens a new outstanding trade. Note that a given item instance may only be in one open trade at a time. - / https://api.playfab.com/Documentation/Client/method/OpenTrade + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with the Apple store that the receipt for an iOS in-app purchase is valid and that it matches the + * purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validateiosreceipt */ - OpenTrade(request: PlayFabClientModels.OpenTradeRequest, callback: PlayFabModule.ApiCallback): void; + ValidateIOSReceipt(request: PlayFabClientModels.ValidateIOSReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attributes an install for advertisment. - / https://api.playfab.com/Documentation/Client/method/AttributeInstall + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with Windows that the receipt for an Windows App Store in-app purchase is valid and that it + * matches the purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validatewindowsstorereceipt */ - AttributeInstall(request: PlayFabClientModels.AttributeInstallRequest, callback: PlayFabModule.ApiCallback): void; + ValidateWindowsStoreReceipt(request: PlayFabClientModels.ValidateWindowsReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Client/method/GetPlayerSegments + * Writes a character-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writecharacterevent */ - GetPlayerSegments(request: PlayFabClientModels.GetPlayerSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + WriteCharacterEvent(request: PlayFabClientModels.WriteClientCharacterEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Client/method/GetPlayerTags + * Writes a player-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writeplayerevent */ - GetPlayerTags(request: PlayFabClientModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + WritePlayerEvent(request: PlayFabClientModels.WriteClientPlayerEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with Windows that the receipt for an Windows App Store in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateWindowsStoreReceipt + * Writes a title-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writetitleevent */ - ValidateWindowsStoreReceipt(request: PlayFabClientModels.ValidateWindowsReceiptRequest, callback: PlayFabModule.ApiCallback): void; + WriteTitleEvent(request: PlayFabClientModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } } declare module PlayFabClientModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AcceptTradeRequest - */ export interface AcceptTradeRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Player who opened the trade. + * Items from the accepting player's inventory in exchange for the offered items in the trade. In the case of a gift, this + * will be null. */ + AcceptedInventoryInstanceIds?: string[]; + /** Player who opened the trade. */ OfferingPlayerId: string; - /** - / Trade identifier. - */ + /** Trade identifier. */ TradeId: string; - /** - / Items from the accepting player's or guild's inventory in exchange for the offered items in the trade. In the case of a gift, this will be null. - */ - AcceptedInventoryInstanceIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AcceptTradeResponse - */ export interface AcceptTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Details about trade which was just accepted. - */ + /** Details about trade which was just accepted. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AdCampaignAttributionModel - */ + type AdActivity = "Opened" + + | "Closed" + | "Start" + | "End"; + export interface AdCampaignAttributionModel { - /** - / Attribution network name - */ - Platform?: string; - /** - / Attribution campaign identifier - */ - CampaignId?: string; - /** - / UTC time stamp of attribution - */ + /** UTC time stamp of attribution */ AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddFriendRequest - */ export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the user to attempt to add to the local user's friend list. - */ - FriendPlayFabId?: string; - /** - / PlayFab username of the user to attempt to add to the local user's friend list. - */ - FriendUsername?: string; - /** - / Email address of the user to attempt to add to the local user's friend list. - */ + /** Email address of the user to attempt to add to the local user's friend list. */ FriendEmail?: string; - /** - / Title-specific display name of the user to attempt to add to the local user's friend list. - */ + /** PlayFab identifier of the user to attempt to add to the local user's friend list. */ + FriendPlayFabId?: string; + /** Title-specific display name of the user to attempt to add to the local user's friend list. */ FriendTitleDisplayName?: string; + /** PlayFab username of the user to attempt to add to the local user's friend list. */ + FriendUsername?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddFriendResult - */ export interface AddFriendResult extends PlayFabModule.IPlayFabResultCommon { - /** - / True if the friend request was processed successfully. - */ + /** True if the friend request was processed successfully. */ Created: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddGenericIDRequest - */ export interface AddGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generic service identifier to add to the player account. - */ + /** Generic service identifier to add to the player account. */ GenericId: GenericServiceId; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddGenericIDResult - */ export interface AddGenericIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddSharedGroupMembersRequest - */ + export interface AddOrUpdateContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new contact email to associate with the player. */ + EmailAddress: string; + + } + + export interface AddOrUpdateContactEmailResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface AddSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddSharedGroupMembersResult - */ export interface AddSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUsernamePasswordRequest - */ export interface AddUsernamePasswordRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab username for the account (3-20 characters) - */ - Username: string; - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; - /** - / Password for the PlayFab account (6-100 characters) - */ + /** Password for the PlayFab account (6-100 characters) */ Password: string; + /** PlayFab username for the account (3-20 characters) */ + Username: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUsernamePasswordResult - */ export interface AddUsernamePasswordResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique user name. - */ + /** PlayFab unique user name. */ Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the virtual currency which is to be incremented. - */ - VirtualCurrency: string; - /** - / Amount to be added to the user balance of the specified virtual currency. - */ + /** Amount to be added to the user balance of the specified virtual currency. */ Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the virtual currency which is to be incremented. */ + VirtualCurrency: string; + + } + + export interface AdPlacementDetails { + /** Placement unique ID */ + PlacementId?: string; + /** Placement name */ + PlacementName?: string; + /** If placement has viewing limits indicates how many views are left */ + PlacementViewsRemaining?: number; + /** If placement has viewing limits indicates when they will next reset */ + PlacementViewsResetMinutes?: number; + /** Optional URL to a reward asset */ + RewardAssetUrl?: string; + /** Reward description */ + RewardDescription?: string; + /** Reward unique ID */ + RewardId?: string; + /** Reward name */ + RewardName?: string; + + } + + export interface AdRewardItemGranted { + /** Catalog ID */ + CatalogId?: string; + /** Catalog item display name */ + DisplayName?: string; + /** Inventory instance ID */ + InstanceId?: string; + /** Item ID */ + ItemId?: string; + + } + + export interface AdRewardResults { + /** Array of the items granted to the player */ + GrantedItems?: AdRewardItemGranted[]; + /** Dictionary of virtual currencies that were granted to the player */ + GrantedVirtualCurrencies?: { [key: string]: number }; + /** Dictionary of statistics that were modified for the player */ + IncrementedStatistics?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AndroidDevicePushNotificationRegistrationRequest - */ export interface AndroidDevicePushNotificationRegistrationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Message to display when confirming push notification. */ + ConfirmationMessage?: string; /** - / Registration ID provided by the Google Cloud Messaging service when the title registered to receive push notifications (see the GCM documentation, here: http://developer.android.com/google/gcm/client.html). + * Registration ID provided by the Google Cloud Messaging service when the title registered to receive push notifications + * (see the GCM documentation, here: http://developer.android.com/google/gcm/client.html). */ DeviceToken: string; - /** - / If true, send a test push message immediately after sucessful registration. Defaults to false. - */ + /** If true, send a test push message immediately after sucessful registration. Defaults to false. */ SendPushNotificationConfirmation?: boolean; - /** - / Message to display when confirming push notification. - */ - ConfirmationMessage?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AndroidDevicePushNotificationRegistrationResult - */ export interface AndroidDevicePushNotificationRegistrationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AttributeInstallRequest - */ export interface AttributeInstallRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The IdentifierForAdvertisers for iOS Devices. - */ - Idfa?: string; - /** - / The adid for this device. - */ + /** The adid for this device. */ Adid?: string; + /** The IdentifierForAdvertisers for iOS Devices. */ + Idfa?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AttributeInstallResult - */ export interface AttributeInstallResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CancelTradeRequest - */ + export interface BattleNetAccountPlayFabIdPair { + /** Unique Battle.net account identifier for a user. */ + BattleNetAccountId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Battle.net account identifier. */ + PlayFabId?: string; + + } + export interface CancelTradeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Trade identifier. - */ + /** Trade identifier. */ TradeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CancelTradeResponse - */ export interface CancelTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Details about trade which was just canceled. - */ + /** Details about trade which was just canceled. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CartItem - */ export interface CartItem { - /** - / Unique identifier for the catalog item. - */ - ItemId?: string; - /** - / Class name to which catalog item belongs. - */ + /** Description of the catalog item. */ + Description?: string; + /** Display name for the catalog item. */ + DisplayName?: string; + /** Class name to which catalog item belongs. */ ItemClass?: string; - /** - / Unique instance identifier for this catalog item. - */ + /** Unique identifier for the catalog item. */ + ItemId?: string; + /** Unique instance identifier for this catalog item. */ ItemInstanceId?: string; - /** - / Display name for the catalog item. - */ - DisplayName?: string; - /** - / Description of the catalog item. - */ - Description?: string; - /** - / Cost of the catalog item for each applicable virtual currency. - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Cost of the catalog item for each applicable real world currency. - */ + /** Cost of the catalog item for each applicable real world currency. */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Amount of each applicable virtual currency which will be received as a result of purchasing this catalog item. - */ + /** Amount of each applicable virtual currency which will be received as a result of purchasing this catalog item. */ VCAmount?: { [key: string]: number }; + /** Cost of the catalog item for each applicable virtual currency. */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItem - */ export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data - */ - CustomData?: string; - /** - / defines the consumable properties (number of uses, timeout) for the item + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - Consumable?: CatalogItemConsumableInfo; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ - Container?: CatalogItemContainerInfo; + UsagePeriod?: number; /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies - */ - Bundle?: CatalogItemBundleInfo; - /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) - */ - UsagePeriod?: number; - /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ UsagePeriodGroup?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemContainerInfo - */ export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ KeyItemId?: string; /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterInventory - */ export interface CharacterInventory { - /** - / The id of this character. - */ + /** The id of this character. */ CharacterId?: string; - /** - / The inventory of this character. - */ + /** The inventory of this character. */ Inventory?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterLeaderboardEntry - */ export interface CharacterLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. - */ + /** PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. */ CharacterId?: string; - /** - / Title-specific display name of the character for this leaderboard entry. - */ + /** Title-specific display name of the character for this leaderboard entry. */ CharacterName?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Name of the character class for this entry. - */ + /** Name of the character class for this entry. */ CharacterType?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterResult - */ - export interface CharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The id for this character on this player. - */ + export interface CharacterResult { + /** The id for this character on this player. */ CharacterId?: string; - /** - / The name of this character. - */ + /** The name of this character. */ CharacterName?: string; - /** - / The type-string that was given to this character on creation. - */ + /** The type-string that was given to this character on creation. */ CharacterType?: string; } type CloudScriptRevisionOption = "Live" + | "Latest" | "Specific"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CollectionFilter - */ - export interface CollectionFilter { - /** - / List of Include rules, with any of which if a collection matches, it is included by the filter, unless it is excluded by one of the Exclude rule - */ - Includes?: Container_Dictionary_String_String[]; - /** - / List of Exclude rules, with any of which if a collection matches, it is excluded by the filter. - */ - Excludes?: Container_Dictionary_String_String[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConfirmPurchaseRequest - */ export interface ConfirmPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier returned from StartPurchase. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Purchase order identifier returned from StartPurchase. */ OrderId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConfirmPurchaseResult - */ export interface ConfirmPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ + /** Array of items purchased. */ + Items?: ItemInstance[]; + /** Purchase order identifier. */ OrderId?: string; - /** - / Date and time of the purchase. - */ + /** Date and time of the purchase. */ PurchaseDate: string; - /** - / Array of items purchased. - */ - Items?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConsumeItemRequest - */ export interface ConsumeItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique instance identifier of the item to be consumed. - */ - ItemInstanceId: string; - /** - / Number of uses to consume from the item. - */ - ConsumeCount: number; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Number of uses to consume from the item. */ + ConsumeCount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be consumed. */ + ItemInstanceId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConsumeItemResult - */ export interface ConsumeItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ + /** Unique instance identifier of the item with uses consumed. */ ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ + /** Number of uses remaining on the item. */ RemainingUses: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.Container_Dictionary_String_String - */ - export interface Container_Dictionary_String_String { - /** - / Content of data - */ - Data?: { [key: string]: string }; + export interface ConsumeMicrosoftStoreEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Marketplace specific payload containing details to fetch in app purchase transactions */ + MarketplaceSpecificData: MicrosoftStorePayload; + + } + + export interface ConsumeMicrosoftStoreEntitlementsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ConsumePS5EntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Marketplace specific payload containing details to fetch in app purchase transactions */ + MarketplaceSpecificData: PlayStation5Payload; + + } + + export interface ConsumePS5EntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ConsumePSNEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Which catalog to match granted entitlements against. If null, defaults to title default catalog */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the PlayStation :tm: Network service label to consume entitlements from */ + ServiceLabel: number; + + } + + export interface ConsumePSNEntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of items granted to the player as a result of consuming entitlements. */ + ItemsGranted?: ItemInstance[]; + + } + + export interface ConsumeXboxEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; + + } + + export interface ConsumeXboxEntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; } type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1480,31 +1749,23 @@ declare module PlayFabClientModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CreateSharedGroupRequest - */ export interface CreateSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). - */ + /** Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). */ SharedGroupId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CreateSharedGroupResult - */ export interface CreateSharedGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the shared group. - */ + /** Unique identifier for the shared group. */ SharedGroupId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1667,2081 +1928,1725 @@ declare module PlayFabClientModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CurrentGamesRequest - */ - export interface CurrentGamesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Region to check for Game Server Instances. - */ - Region?: string; - /** - / Build to match against. - */ - BuildVersion?: string; - /** - / Game mode to look for. - */ - GameMode?: string; - /** - / Statistic name to find statistic-based matches. - */ - StatisticName?: string; - /** - / Filter to include and/or exclude Game Server Instances associated with certain tags. - */ - TagFilter?: CollectionFilter; + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CurrentGamesResult - */ - export interface CurrentGamesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of games found - */ - Games?: GameInfo[]; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; + + } + + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / total number of players across all servers + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - PlayerCount: number; + ExpectedPropertiesVersion?: number; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; /** - / number of games running + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - GameCount: number; + PropertiesVersion: number; + + } + + export interface DeviceInfoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Information posted to the PlayStream Event. Currently arbitrary, and specific to the environment sending it. */ + Info?: { [key: string]: any }; + + } + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.EmptyResult - */ export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ExecuteCloudScriptRequest - */ + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + export interface ExecuteCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The name of the CloudScript function to execute - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the CloudScript function to execute */ FunctionName: string; - /** - / Object that is passed in to the function as the first argument - */ + /** Object that is passed in to the function as the first argument */ FunctionParameter?: any; /** - / Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' executes the current live, published revision, and 'Specific' executes the specified revision. The default value is 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. + * Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. */ - RevisionSelection?: string; + GeneratePlayStreamEvent?: boolean; /** - / The specivic revision to execute, when RevisionSelection is set to 'Specific' + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. */ + RevisionSelection?: string; + /** The specivic revision to execute, when RevisionSelection is set to 'Specific' */ SpecificRevision?: number; - /** - / Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. - */ - GeneratePlayStreamEvent?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ExecuteCloudScriptResult - */ export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - FunctionResult?: any; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ Logs?: LogStatement[]; - ExecutionTimeSeconds: number; /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - ProcessorTimeSeconds: number; + LogsTooLarge?: boolean; MemoryConsumedBytes: number; /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; - /** - / Number of external HTTP requests issued by the CloudScript function + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - HttpRequestsIssued: number; - /** - / Information about the error, if any, that occured during execution - */ - Error?: ScriptExecutionError; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FacebookInstantGamesPlayFabIdPair { + /** Unique Facebook Instant Games identifier for a user. */ + FacebookInstantGamesId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook Instant Games identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.FacebookPlayFabIdPair - */ export interface FacebookPlayFabIdPair { - /** - / Unique Facebook identifier for a user. - */ + /** Unique Facebook identifier for a user. */ FacebookId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.FriendInfo - */ export interface FriendInfo { - /** - / PlayFab unique identifier for this friend. - */ + /** Available Facebook information (if the user and connected Facebook friend both have PlayFab Accounts in the same title). */ + FacebookInfo?: UserFacebookInfo; + /** PlayFab unique identifier for this friend. */ FriendPlayFabId?: string; /** - / PlayFab unique username for this friend. - */ - Username?: string; - /** - / Title-specific display name for this friend. - */ - TitleDisplayName?: string; - /** - / Tags which have been associated with this friend. - */ - Tags?: string[]; - /** - / Unique lobby identifier of the Game Server Instance to which this player is currently connected. - */ - CurrentMatchmakerLobbyId?: string; - /** - / Available Facebook information (if the user and PlayFab friend are also connected in Facebook). + * Available Game Center information (if the user and connected Game Center friend both have PlayFab Accounts in the same + * title). */ - FacebookInfo?: UserFacebookInfo; + GameCenterInfo?: UserGameCenterInfo; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; /** - / Available Steam information (if the user and PlayFab friend are also connected in Steam). + * Available PlayStation :tm: Network information, if the user connected PlayStation :tm Network friend both have PlayFab + * Accounts in the same title. */ + PSNInfo?: UserPsnInfo; + /** Available Steam information (if the user and connected Steam friend both have PlayFab Accounts in the same title). */ SteamInfo?: UserSteamInfo; - /** - / Available Game Center information (if the user and PlayFab friend are also connected in Game Center). - */ - GameCenterInfo?: UserGameCenterInfo; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameCenterPlayFabIdPair - */ - export interface GameCenterPlayFabIdPair { - /** - / Unique Game Center identifier for a user. - */ - GameCenterId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Game Center identifier. - */ - PlayFabId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameInfo - */ - export interface GameInfo { - /** - / region to which this server is associated - */ - Region?: string; - /** - / unique lobby identifier for this game server - */ - LobbyID?: string; - /** - / build version this server is running - */ - BuildVersion?: string; - /** - / game mode this server is running - */ - GameMode?: string; - /** - / stastic used to match this game in player statistic matchmaking - */ - StatisticName?: string; - /** - / maximum players this server can support - */ - MaxPlayers?: number; - /** - / array of current player IDs on this server - */ - PlayerUserIds?: string[]; - /** - / duration in seconds this server has been running - */ - RunTime: number; - /** - / game specific string denoting server configuration - */ - GameServerState?: string; - /** - / game session custom data - */ - GameServerData?: string; - /** - / game session tags - */ - Tags?: { [key: string]: string }; - /** - / last heartbeat of the game server instance, used in external game server provider mode - */ - LastHeartbeat?: string; - /** - / IP address of the server - */ - ServerHostname?: string; - /** - / port number to use for non-http communications with the server - */ - ServerPort?: number; - - } - - type GameInstanceState = "Open" - | "Closed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameServerRegionsRequest - */ - export interface GameServerRegionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / version of game server for which stats are being requested - */ - BuildVersion: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; + /** Tags which have been associated with this friend. */ + Tags?: string[]; + /** Title-specific display name for this friend. */ + TitleDisplayName?: string; + /** PlayFab unique username for this friend. */ + Username?: string; + /** Available Xbox information, (if the user and connected Xbox Live friend both have PlayFab Accounts in the same title). */ + XboxInfo?: UserXboxInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameServerRegionsResult - */ - export interface GameServerRegionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of regions found matching the request parameters - */ - Regions?: RegionInfo[]; + export interface GameCenterPlayFabIdPair { + /** Unique Game Center identifier for a user. */ + GameCenterId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Game Center identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GenericPlayFabIdPair - */ export interface GenericPlayFabIdPair { - /** - / Unique generic service identifier for a user. - */ + /** Unique generic service identifier for a user. */ GenericId?: GenericServiceId; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GenericServiceId - */ export interface GenericServiceId { - /** - / Name of the service for which the player has a unique identifier. - */ + /** Name of the service for which the player has a unique identifier. */ ServiceName: string; - /** - / Unique identifier of the player in that service. - */ + /** Unique identifier of the player in that service. */ UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetAccountInfoRequest - */ export interface GetAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** User email address for the account to find (if no Username is specified). */ + Email?: string; /** - / Unique PlayFab identifier of the user whose info is being requested. Optional, defaults to the authenticated user if no other lookup identifier set. + * Unique PlayFab identifier of the user whose info is being requested. Optional, defaults to the authenticated user if no + * other lookup identifier set. */ PlayFabId?: string; /** - / PlayFab Username for the account to find (if no PlayFabId is specified). - */ - Username?: string; - /** - / User email address for the account to find (if no Username is specified). - */ - Email?: string; - /** - / Title-specific username for the account to find (if no Email is set). Note that if the non-unique Title Display Names option is enabled for the title, attempts to look up users by Title Display Name will always return AccountNotFound. + * Title-specific username for the account to find (if no Email is set). Note that if the non-unique Title Display Names + * option is enabled for the title, attempts to look up users by Title Display Name will always return AccountNotFound. */ TitleDisplayName?: string; + /** PlayFab Username for the account to find (if no PlayFabId is specified). */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetAccountInfoResult - */ export interface GetAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account information for the local user. - */ + /** Account information for the local user. */ AccountInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCatalogItemsRequest - */ + export interface GetAdPlacementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The current AppId to use */ + AppId: string; + /** Using the name or unique identifier, filter the result for get a specific placement. */ + Identifier?: NameIdentifier; + + } + + export interface GetAdPlacementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of results */ + AdPlacements?: AdPlacementDetails[]; + + } + export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterDataRequest - */ export interface GetCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterDataResult - */ export interface GetCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / User specific data for this title. - */ + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterInventoryRequest - */ export interface GetCharacterInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Used to limit results to only those from a specific catalog version. - */ + /** Used to limit results to only those from a specific catalog version. */ CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterInventoryResult - */ export interface GetCharacterInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier of the character for this inventory. - */ + /** Unique identifier of the character for this inventory. */ CharacterId?: string; - /** - / Array of inventory items belonging to the character. - */ + /** Array of inventory items belonging to the character. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the character. - */ + /** Array of virtual currency balance(s) belonging to the character. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterLeaderboardRequest - */ export interface GetCharacterLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterLeaderboardResult - */ export interface GetCharacterLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterStatisticsRequest - */ export interface GetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterStatisticsResult - */ export interface GetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested character statistics. - */ + /** The requested character statistics. */ CharacterStatistics?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetContentDownloadUrlRequest - */ export interface GetContentDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to fetch, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. - */ + /** HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. */ HttpMethod?: string; + /** Key of the content item to fetch, usually formatted as a path, e.g. images/a.png */ + Key: string; /** - / True if download through CDN. CDN provides better download bandwidth and time. However, if you want latest, non-cached version of the content, set this to false. Default is true. + * True to download through CDN. CDN provides higher download bandwidth and lower latency. However, if you want the latest, + * non-cached version of the content during development, set this to false. Default is true. */ ThruCDN?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetContentDownloadUrlResult - */ export interface GetContentDownloadUrlResult extends PlayFabModule.IPlayFabResultCommon { - /** - / URL for downloading content via HTTP GET or HEAD method. The URL will expire in 1 hour. - */ + /** URL for downloading content via HTTP GET or HEAD method. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardAroundPlayerRequest - */ export interface GetFriendLeaderboardAroundPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Statistic used to rank players for this leaderboard. - */ - StatisticName: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; - /** - / PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. - */ + /** PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. */ PlayFabId?: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Statistic used to rank players for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardAroundPlayerResult - */ export interface GetFriendLeaderboardAroundPlayerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardRequest - */ export interface GetFriendLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Statistic used to rank friends for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ + StartPosition: number; + /** Statistic used to rank friends for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendsListRequest - */ export interface GetFriendsListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalPlatformFriends?: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. + * If true, include friends from the same namespace even if they have not logged in to the current title. Defaults to + * false. */ - IncludeSteamFriends?: boolean; + NamespaceWide?: boolean; /** - / Indicates whether Facebook friends should be included in the response. Default is true. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - IncludeFacebookFriends?: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. When provided, all Xbox Live + * users the caller is following are included regardless of whether they follow the caller back. + */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendsListResult - */ export interface GetFriendsListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of friends found. - */ + /** Array of friends found. */ Friends?: FriendInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundCharacterRequest - */ export interface GetLeaderboardAroundCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID for a specific character on which to center the leaderboard. - */ + /** Unique PlayFab assigned ID for a specific character on which to center the leaderboard. */ CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundCharacterResult - */ export interface GetLeaderboardAroundCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundPlayerRequest - */ export interface GetLeaderboardAroundPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ + MaxResultsCount?: number; + /** PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. */ PlayFabId?: string; /** - / Statistic used to rank players for this leaderboard. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Statistic used to rank players for this leaderboard. */ StatisticName: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ - MaxResultsCount?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundPlayerResult - */ export interface GetLeaderboardAroundPlayerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardForUsersCharactersRequest - */ export interface GetLeaderboardForUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ + /** Unique identifier for the title-specific statistic for the leaderboard. */ StatisticName: string; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardForUsersCharactersResult - */ export interface GetLeaderboardForUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardRequest - */ export interface GetLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Statistic used to rank players for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ + StartPosition: number; + /** Statistic used to rank players for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardResult - */ export interface GetLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPhotonAuthenticationTokenRequest - */ - export interface GetPhotonAuthenticationTokenRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The Photon applicationId for the game you wish to log into. - */ + export interface GetPaymentTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The name of service to provide the payment token. Allowed Values are: xsolla */ + TokenProvider: string; + + } + + export interface GetPaymentTokenResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab's purchase order identifier. */ + OrderId?: string; + /** The token from provider. */ + ProviderToken?: string; + + } + + export interface GetPhotonAuthenticationTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The Photon applicationId for the game you wish to log into. */ PhotonApplicationId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPhotonAuthenticationTokenResult - */ export interface GetPhotonAuthenticationTokenResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The Photon authentication token for this game-session. - */ + /** The Photon authentication token for this game-session. */ PhotonCustomAuthenticationToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoRequest - */ export interface GetPlayerCombinedInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the user whose data will be returned. If not filled included, we return the data for the calling player. - */ - PlayFabId?: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters: GetPlayerCombinedInfoRequestParams; + /** PlayFabId of the user whose data will be returned. If not filled included, we return the data for the calling player. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoRequestParams - */ export interface GetPlayerCombinedInfoRequestParams { - /** - / Whether to get the player's account Info. Defaults to false - */ + /** Whether to get character inventories. Defaults to false. */ + GetCharacterInventories: boolean; + /** Whether to get the list of characters. Defaults to false. */ + GetCharacterList: boolean; + /** Whether to get player profile. Defaults to false. Has no effect for a new player. */ + GetPlayerProfile: boolean; + /** Whether to get player statistics. Defaults to false. */ + GetPlayerStatistics: boolean; + /** Whether to get title data. Defaults to false. */ + GetTitleData: boolean; + /** Whether to get the player's account Info. Defaults to false */ GetUserAccountInfo: boolean; - /** - / Whether to get the player's inventory. Defaults to false - */ + /** Whether to get the player's custom data. Defaults to false */ + GetUserData: boolean; + /** Whether to get the player's inventory. Defaults to false */ GetUserInventory: boolean; - /** - / Whether to get the player's virtual currency balances. Defaults to false - */ + /** Whether to get the player's read only data. Defaults to false */ + GetUserReadOnlyData: boolean; + /** Whether to get the player's virtual currency balances. Defaults to false */ GetUserVirtualCurrency: boolean; - /** - / Whether to get the player's custom data. Defaults to false - */ - GetUserData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false - */ + /** Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false */ + PlayerStatisticNames?: string[]; + /** Specifies the properties to return from the player profile. Defaults to returning the player's display name. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false */ + TitleDataKeys?: string[]; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false */ UserDataKeys?: string[]; /** - / Whether to get the player's read only data. Defaults to false - */ - GetUserReadOnlyData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is false + * Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is + * false */ UserReadOnlyDataKeys?: string[]; - /** - / Whether to get character inventories. Defaults to false. - */ - GetCharacterInventories: boolean; - /** - / Whether to get the list of characters. Defaults to false. - */ - GetCharacterList: boolean; - /** - / Whether to get title data. Defaults to false. - */ - GetTitleData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false - */ - TitleDataKeys?: string[]; - /** - / Whether to get player statistics. Defaults to false. - */ - GetPlayerStatistics: boolean; - /** - / Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false - */ - PlayerStatisticNames?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoResult - */ export interface GetPlayerCombinedInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Results for requested info. - */ + /** Results for requested info. */ InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoResultPayload - */ export interface GetPlayerCombinedInfoResultPayload { - /** - / Account information for the user. This is always retrieved. - */ + /** Account information for the user. This is always retrieved. */ AccountInfo?: UserAccountInfo; + /** Inventories for each character for the user. */ + CharacterInventories?: CharacterInventory[]; + /** List of characters for the user. */ + CharacterList?: CharacterResult[]; /** - / Array of inventory items in the user's current inventory. - */ - UserInventory?: ItemInstance[]; - /** - / Dictionary of virtual currency balance(s) belonging to the user. - */ - UserVirtualCurrency?: { [key: string]: number }; - /** - / Dictionary of remaining times and timestamps for virtual currencies. - */ - UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; - /** - / User specific custom data. + * The profile of the players. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ + PlayerProfile?: PlayerProfileModel; + /** List of statistics for this player. */ + PlayerStatistics?: StatisticValue[]; + /** Title data for this title. */ + TitleData?: { [key: string]: string | null }; + /** User specific custom data. */ UserData?: { [key: string]: UserDataRecord }; - /** - / The version of the UserData that was returned. - */ + /** The version of the UserData that was returned. */ UserDataVersion: number; - /** - / User specific read-only data. - */ + /** Array of inventory items in the user's current inventory. */ + UserInventory?: ItemInstance[]; + /** User specific read-only data. */ UserReadOnlyData?: { [key: string]: UserDataRecord }; - /** - / The version of the Read-Only UserData that was returned. - */ + /** The version of the Read-Only UserData that was returned. */ UserReadOnlyDataVersion: number; + /** Dictionary of virtual currency balance(s) belonging to the user. */ + UserVirtualCurrency?: { [key: string]: number }; + /** Dictionary of remaining times and timestamps for virtual currencies. */ + UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; + + } + + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific property name to search for in the player's properties. */ + PropertyName: string; + + } + + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { /** - / List of characters for the user. - */ - CharacterList?: CharacterResult[]; - /** - / Inventories for each character for the user. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - CharacterInventories?: CharacterInventory[]; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; /** - / Title data for this title. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - TitleData?: { [key: string]: string }; + ProfileConstraints?: PlayerProfileViewConstraints; + + } + + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / List of statistics for this player. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - PlayerStatistics?: StatisticValue[]; + PlayerProfile?: PlayerProfileModel; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerSegmentsRequest - */ export interface GetPlayerSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerSegmentsResult - */ export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments the requested player currently belongs to. - */ + /** Array of segments the requested player currently belongs to. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticsRequest - */ export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / statistics to return (current version will be returned for each) - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** statistics to return (current version will be returned for each) */ StatisticNames?: string[]; /** - / statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be returned) + * statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be + * returned) */ StatisticNameVersions?: StatisticNameVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticsResult - */ export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User statistics for the requested user. - */ + /** User statistics for the requested user. */ Statistics?: StatisticValue[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticVersionsRequest - */ export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticVersionsResult - */ export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ + /** version change history of the statistic */ StatisticVersions?: PlayerStatisticVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTagsRequest - */ export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Optional namespace to filter results by - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTagsResult - */ export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ + /** Canonical tags (including namespace and tag's name) for the requested user */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTradesRequest - */ export interface GetPlayerTradesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Returns only trades with the given status. If null, returns all trades. - */ + /** Returns only trades with the given status. If null, returns all trades. */ StatusFilter?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTradesResponse - */ export interface GetPlayerTradesResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The trades for this player which are currently available to be accepted. - */ + /** History of trades which this player has accepted. */ + AcceptedTrades?: TradeInfo[]; + /** The trades for this player which are currently available to be accepted. */ OpenedTrades?: TradeInfo[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / History of trades which this player has accepted. + * Array of unique Battle.net account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 10 in length. */ - AcceptedTrades?: TradeInfo[]; + BattleNetAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Battle.net account identifiers to PlayFab identifiers. */ + Data?: BattleNetAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromFacebookIDsRequest - */ export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. + * Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ FacebookIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromFacebookIDsResult - */ export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook identifiers to PlayFab identifiers. */ + Data?: FacebookPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Facebook identifiers to PlayFab identifiers. + * Array of unique Facebook Instant Games identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: FacebookPlayFabIdPair[]; + FacebookInstantGamesIds: string[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook Instant Games identifiers to PlayFab identifiers. */ + Data?: FacebookInstantGamesPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGameCenterIDsRequest - */ export interface GetPlayFabIDsFromGameCenterIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Game Center identifiers (the Player Identifier) for which the title needs to get PlayFab identifiers. + * Array of unique Game Center identifiers (the Player Identifier) for which the title needs to get PlayFab identifiers. + * The array cannot exceed 25 in length. */ GameCenterIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGameCenterIDsResult - */ export interface GetPlayFabIDsFromGameCenterIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Game Center identifiers to PlayFab identifiers. - */ + /** Mapping of Game Center identifiers to PlayFab identifiers. */ Data?: GameCenterPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGenericIDsRequest - */ export interface GetPlayFabIDsFromGenericIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a maximum of 10 in a single request. + * Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a + * maximum of 10 in a single request. */ GenericIDs: GenericServiceId[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGenericIDsResult - */ export interface GetPlayFabIDsFromGenericIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of generic service identifiers to PlayFab identifiers. - */ + /** Mapping of generic service identifiers to PlayFab identifiers. */ Data?: GenericPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGoogleIDsRequest - */ export interface GetPlayFabIDsFromGoogleIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Google identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. + * Array of unique Google identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ GoogleIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGoogleIDsResult - */ export interface GetPlayFabIDsFromGoogleIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Google identifiers to PlayFab identifiers. */ + Data?: GooglePlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromGooglePlayGamesPlayerIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Google identifiers to PlayFab identifiers. + * Array of unique Google Play Games identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. + * The array cannot exceed 25 in length. */ - Data?: GooglePlayFabIdPair[]; + GooglePlayGamesPlayerIDs: string[]; + + } + + export interface GetPlayFabIDsFromGooglePlayGamesPlayerIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Google Play Games identifiers to PlayFab identifiers. */ + Data?: GooglePlayGamesPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromKongregateIDsRequest - */ export interface GetPlayFabIDsFromKongregateIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Kongregate identifiers (Kongregate's user_id) for which the title needs to get PlayFab identifiers. + * Array of unique Kongregate identifiers (Kongregate's user_id) for which the title needs to get PlayFab identifiers. The + * array cannot exceed 25 in length. */ KongregateIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromKongregateIDsResult - */ export interface GetPlayFabIDsFromKongregateIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Kongregate identifiers to PlayFab identifiers. - */ + /** Mapping of Kongregate identifiers to PlayFab identifiers. */ Data?: KongregatePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromSteamIDsRequest - */ - export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromNintendoServiceAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. + * Nintendo NSA issuer URL identifying the environment. When provided, only accounts registered in that environment are + * returned. If null or empty, falls back to the default environment. */ - SteamStringIDs?: string[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromSteamIDsResult - */ - export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + Issuer?: string; /** - / Mapping of Steam identifiers to PlayFab identifiers. + * Array of unique Nintendo Switch Account identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: SteamPlayFabIdPair[]; + NintendoAccountIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromTwitchIDsRequest - */ - export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. - */ - TwitchIds: string[]; + export interface GetPlayFabIDsFromNintendoServiceAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Service Account identifiers to PlayFab identifiers. */ + Data?: NintendoServiceAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromTwitchIDsResult - */ - export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Twitch identifiers to PlayFab identifiers. + * Array of unique Nintendo Switch Device identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: TwitchPlayFabIdPair[]; + NintendoSwitchDeviceIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPublisherDataRequest - */ - export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ - Keys: string[]; + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Device identifiers to PlayFab identifiers. */ + Data?: NintendoSwitchPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPublisherDataResult - */ - export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromOpenIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / a dictionary object of key / value pairs + * Array of unique OpenId Connect identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed + * 10 in length. */ - Data?: { [key: string]: string }; + OpenIdSubjectIdentifiers: OpenIdSubjectIdentifier[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPurchaseRequest - */ - export interface GetPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier. - */ - OrderId: string; + export interface GetPlayFabIDsFromOpenIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of OpenId Connect identifiers to PlayFab identifiers. */ + Data?: OpenIdSubjectIdentifierPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPurchaseResult - */ - export interface GetPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; + export interface GetPlayFabIDsFromPSNAccountIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Payment provider used for transaction (If not VC) + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - PaymentProvider?: string; - /** - / Provider transaction ID (If not VC) - */ - TransactionId?: string; + IssuerId?: number; /** - / PlayFab transaction status + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - TransactionStatus?: string; - /** - / Date and time of the purchase. - */ - PurchaseDate: string; + PSNAccountIDs: string[]; /** - / Array of items purchased. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - Items?: ItemInstance[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ - Id: string; - /** - / Segment name. - */ - Name?: string; - /** - / Identifier of the segments AB Test, if it is attached to one. - */ - ABTestParent?: string; + export interface GetPlayFabIDsFromPSNAccountIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSharedGroupDataRequest - */ - export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromPSNOnlineIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier for the shared group. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - SharedGroupId: string; + IssuerId?: number; /** - / Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array indicates that no keys should be returned). + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Keys?: string[]; + PSNOnlineIDs: string[]; /** - / If true, return the list of all members of the shared group. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - GetMembers?: boolean; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSharedGroupDataResult - */ - export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Data for the requested keys. - */ - Data?: { [key: string]: SharedGroupDataRecord }; - /** - / List of PlayFabId identifiers for the members of this group, if requested. - */ - Members?: string[]; + export interface GetPlayFabIDsFromPSNOnlineIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNOnlinePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetStoreItemsRequest - */ - export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to store items from. Use default catalog version if null - */ - CatalogVersion?: string; + export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unqiue identifier for the store which is being requested. + * Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - StoreId: string; + SteamStringIDs?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetStoreItemsResult - */ - export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased from this store. - */ - Store?: StoreItem[]; - /** - / How the store was last updated (Admin or a third party). - */ - Source?: string; - /** - / The base catalog that this store is a part of. - */ - CatalogVersion?: string; - /** - / The ID of this store. - */ - StoreId?: string; + export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Additional data about the store. + * Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - MarketingData?: StoreMarketingModel; + SteamNames: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTimeRequest - */ - export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamNamePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTimeResult - */ - export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Current server time when the request was received, in UTC + * Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Time: string; + TwitchIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleDataRequest - */ - export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specific keys to search for in the title data (leave null to get all keys) - */ - Keys?: string[]; + export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Twitch identifiers to PlayFab identifiers. */ + Data?: TwitchPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleDataResult - */ - export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The ID of Xbox Live sandbox. */ + Sandbox?: string; /** - / a dictionary object of key / value pairs + * Array of unique Xbox Live account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Data?: { [key: string]: string }; + XboxLiveAccountIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleNewsRequest - */ - export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Limits the results to the last n entries. Defaults to 10 if not set. - */ - Count?: number; + export interface GetPlayFabIDsFromXboxLiveIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Xbox Live identifiers to PlayFab identifiers. */ + Data?: XboxLiveAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleNewsResult - */ - export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ + Keys: string[]; + + } + + export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; + + } + + export interface GetPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Purchase order identifier. */ + OrderId: string; + + } + + export interface GetPurchaseResult extends PlayFabModule.IPlayFabResultCommon { + /** Purchase order identifier. */ + OrderId?: string; + /** Payment provider used for transaction (If not VC) */ + PaymentProvider?: string; + /** Date and time of the purchase. */ + PurchaseDate: string; + /** Provider transaction ID (If not VC) */ + TransactionId?: string; + /** PlayFab transaction status */ + TransactionStatus?: string; + + } + + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ + Id: string; + /** Segment name. */ + Name?: string; + + } + + export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** If true, return the list of all members of the shared group. */ + GetMembers?: boolean; /** - / Array of news items. + * Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array + * indicates that no keys should be returned). */ - News?: TitleNewsItem[]; + Keys?: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTradeStatusRequest - */ - export interface GetTradeStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { + /** Data for the requested keys. */ + Data?: { [key: string]: SharedGroupDataRecord }; + /** List of PlayFabId identifiers for the members of this group, if requested. */ + Members?: string[]; + + } + + export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to store items from. Use default catalog version if null */ + CatalogVersion?: string; + /** Unqiue identifier for the store which is being requested. */ + StoreId: string; + + } + + export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** The base catalog that this store is a part of. */ + CatalogVersion?: string; + /** Additional data about the store. */ + MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; + + } + + export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { + /** Current server time when the request was received, in UTC */ + Time: string; + + } + + export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Player who opened trade. + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - OfferingPlayerId: string; + OverrideLabel?: string; + + } + + export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; + + } + + export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Limits the results to the last n entries. Defaults to 10 if not set. */ + Count?: number; + + } + + export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of news items. */ + News?: TitleNewsItem[]; + + } + + export interface GetTitlePublicKeyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Trade identifier as returned by OpenTradeOffer. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId: string; + /** The shared secret key for this title */ + TitleSharedSecret: string; + + } + + export interface GetTitlePublicKeyResult extends PlayFabModule.IPlayFabResultCommon { + /** Base64 encoded RSA CSP byte array blob containing the title's public RSA key */ + RSAPublicKey?: string; + + } + + export interface GetTradeStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player who opened trade. */ + OfferingPlayerId: string; + /** Trade identifier as returned by OpenTradeOffer. */ TradeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTradeStatusResponse - */ export interface GetTradeStatusResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the requested trade. - */ + /** Information about the requested trade. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Specific keys to search for in the custom data. Leave null to get all keys. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ + IfChangedFromDataVersion?: number; + /** List of unique keys to load from. */ Keys?: string[]; /** - / Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. When specified to a PlayFab id of another player, then this will only return public keys for that account. + * Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. When specified to a + * PlayFab id of another player, then this will only return public keys for that account. */ PlayFabId?: string; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. - */ - IfChangedFromDataVersion?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User specific data for this title. - */ + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetWindowsHelloChallengeRequest - */ - export interface GetWindowsHelloChallengeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId: string; - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetWindowsHelloChallengeResponse - */ - export interface GetWindowsHelloChallengeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Server generated challenge to be signed by the user. - */ - Challenge?: string; + export interface GooglePlayFabIdPair { + /** Unique Google identifier for a user. */ + GoogleId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GooglePlayFabIdPair - */ - export interface GooglePlayFabIdPair { - /** - / Unique Google identifier for a user. - */ - GoogleId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google identifier. - */ + export interface GooglePlayGamesPlayFabIdPair { + /** Unique Google Play Games identifier for a user. */ + GooglePlayGamesPlayerId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google Play Games identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GrantCharacterToUserRequest - */ export interface GrantCharacterToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; + /** Non-unique display name of the character being granted (1-40 characters in length). */ + CharacterName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Catalog item identifier of the item in the user's inventory that corresponds to the character in the catalog to be created. + * Catalog item identifier of the item in the user's inventory that corresponds to the character in the catalog to be + * created. */ ItemId: string; - /** - / Non-unique display name of the character being granted. - */ - CharacterName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GrantCharacterToUserResult - */ export interface GrantCharacterToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier tagged to this character. - */ + /** Unique identifier tagged to this character. */ CharacterId?: string; - /** - / Type of character that was created. - */ + /** Type of character that was created. */ CharacterType?: string; - /** - / Indicates whether this character was created successfully. - */ + /** Indicates whether this character was created successfully. */ Result: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ItemPurchaseRequest - */ - export interface ItemPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique ItemId of the item to purchase. - */ + export interface ItemPurchaseRequest { + /** Title-specific text concerning this purchase. */ + Annotation?: string; + /** Unique ItemId of the item to purchase. */ ItemId: string; - /** - / How many of this item to purchase. - */ + /** How many of this item to purchase. Min 1, maximum 25. */ Quantity: number; - /** - / Title-specific text concerning this purchase. - */ - Annotation?: string; - /** - / Items to be upgraded as a result of this purchase (upgraded items are hidden, as they are "replaced" by the new items). - */ + /** Items to be upgraded as a result of this purchase (upgraded items are hidden, as they are "replaced" by the new items). */ UpgradeFromItems?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.KongregatePlayFabIdPair - */ export interface KongregatePlayFabIdPair { - /** - / Unique Kongregate identifier for a user. - */ + /** Unique Kongregate identifier for a user. */ KongregateId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Kongregate identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Kongregate identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkAndroidDeviceIDRequest - */ export interface LinkAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Android device identifier for the user's device. - */ - AndroidDeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. - */ + /** Specific model of the user's device. */ AndroidDevice?: string; - /** - / If another user is already linked to the device, unlink the other user and re-link. - */ + /** Android device identifier for the user's device. */ + AndroidDeviceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the device, unlink the other user and re-link. */ ForceLink?: boolean; + /** Specific Operating System version for the user's device. */ + OS?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkAndroidDeviceIDResult - */ export interface LinkAndroidDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkCustomIDRequest - */ - export interface LinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Apple account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Custom unique identifier for the user, generated by the title. + * The JSON Web token (JWT) returned by Apple after login. Represented as the identityToken field in the authorization + * credential payload. Used to validate the request and find the user ID (Apple subject) to link with. */ + IdentityToken: string; + + } + + export interface LinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Battle.net account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + + } + + export interface LinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom unique identifier for the user, generated by the title. */ CustomId: string; - /** - / If another user is already linked to the custom ID, unlink the other user and re-link. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the custom ID, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkCustomIDResult - */ export interface LinkCustomIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkedPlatformAccountModel - */ export interface LinkedPlatformAccountModel { - /** - / Authentication platform - */ + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ Platform?: string; - /** - / Unique account identifier of the user on the platform - */ + /** Unique account identifier of the user on the platform */ PlatformUserId?: string; - /** - / Linked account username of the user on the platform, if available - */ + /** Linked account username of the user on the platform, if available */ Username?: string; - /** - / Linked account email of the user on the platform, if available - */ - Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkFacebookAccountRequest - */ export interface LinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier from Facebook for the user. - */ - AccessToken: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + /** Unique identifier from Facebook for the user. */ + AccessToken?: string; + /** Token used for limited login authentication. */ + AuthenticationToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkFacebookAccountResult - */ export interface LinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGameCenterAccountRequest - */ + export interface LinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games signature for the user. */ + FacebookInstantGamesSignature: string; + /** If another user is already linked to the Facebook Instant Games ID, unlink the other user and re-link. */ + ForceLink?: boolean; + + } + + export interface LinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface LinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Game Center identifier for the player account to be linked. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ + ForceLink?: boolean; + /** Game Center identifier for the player account to be linked. */ GameCenterId: string; + /** The URL for the public encryption key that will be used to verify the signature. */ + PublicKeyUrl?: string; + /** A random value used to compute the hash and keep it randomized. */ + Salt?: string; + /** The verification signature of the authentication payload. */ + Signature?: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * The integer representation of date and time that the signature was created on. PlayFab will reject authentication + * signatures not within 10 minutes of the server's current time. */ - ForceLink?: boolean; + Timestamp?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGameCenterAccountResult - */ export interface LinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGoogleAccountRequest - */ export interface LinkGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Server authentication code obtained on the client by calling getServerAuthCode() (https://developers.google.com/identity/sign-in/android/offline-access) from Google Play for the user. - */ - ServerAuthCode?: string; - /** - / OAuth 2.0 access token obtained on the client by calling the getAccessToken() Google client API. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ - AccessToken?: string; + ForceLink?: boolean; /** - / If another user is already linked to the account, unlink the other user and re-link. + * Server authentication code obtained on the client by calling getServerAuthCode() + * (https://developers.google.com/identity/sign-in/android/offline-access) from Google Play for the user. */ - ForceLink?: boolean; + ServerAuthCode?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGoogleAccountResult - */ export interface LinkGoogleAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkIOSDeviceIDRequest - */ - export interface LinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkGooglePlayGamesServicesAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Vendor-specific iOS identifier for the user's device. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ - DeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; + ForceLink?: boolean; /** - / Specific model of the user's device. + * OAuth 2.0 server authentication code obtained on the client by calling the requestServerSideAccess() + * (https://developers.google.com/games/services/android/signin) Google Play Games client API. */ + ServerAuthCode: string; + + } + + export interface LinkGooglePlayGamesServicesAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId: string; + /** Specific model of the user's device. */ DeviceModel?: string; - /** - / If another user is already linked to the device, unlink the other user and re-link. - */ + /** If another user is already linked to the device, unlink the other user and re-link. */ ForceLink?: boolean; + /** Specific Operating System version for the user's device. */ + OS?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkIOSDeviceIDResult - */ export interface LinkIOSDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkKongregateAccountRequest - */ export interface LinkKongregateAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Valid session auth ticket issued by Kongregate */ + AuthTicket: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Numeric user ID assigned by Kongregate */ + KongregateId: string; + + } + + export interface LinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Switch account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Numeric user ID assigned by Kongregate + * The JSON Web token (JWT) returned by Nintendo after login. Used to validate the request and find the user ID (Nintendo + * Switch subject) to link with. */ - KongregateId: string; + IdentityToken: string; + + } + + export interface LinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the Nintendo Switch Device ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId: string; + + } + + export interface LinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific OpenId Connect user, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Valid session auth ticket issued by Kongregate + * The JSON Web token (JWT) returned by the identity provider after login. Represented as the id_token field in the + * identity provider's response. Used to validate the request and find the user ID (OpenID Connect subject) to link with. */ - AuthTicket: string; + IdToken: string; + + } + + export interface LinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Authentication code provided by the PlayStation :tm: Network. */ + AuthCode: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ + AuthVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkKongregateAccountResult - */ - export interface LinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkSteamAccountRequest - */ export interface LinkSteamAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte 0x08 should become "08"). + * Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte + * 0x08 should become "08"). */ SteamTicket: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * True if ticket was generated using ISteamUser::GetAuthTicketForWebAPI() using "AzurePlayFab" as the identity string. + * False if the ticket was generated with ISteamUser::GetAuthSessionTicket(). */ - ForceLink?: boolean; + TicketIsServiceSpecific?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkSteamAccountResult - */ export interface LinkSteamAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkTwitchAccountRequest - */ export interface LinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Valid token issued by Twitch - */ + /** Valid token issued by Twitch */ AccessToken: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkTwitchAccountResult - */ export interface LinkTwitchAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkWindowsHelloAccountRequest - */ - export interface LinkWindowsHelloAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Player's user named used by Windows Hello. - */ - UserName: string; - /** - / PublicKey generated by Windows Hello. - */ - PublicKey: string; - /** - / Device name. - */ - DeviceName?: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + export interface LinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkWindowsHelloAccountResponse - */ - export interface LinkWindowsHelloAccountResponse extends PlayFabModule.IPlayFabResultCommon { + export interface LinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ListUsersCharactersRequest - */ - export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ListUsersCharactersResult - */ export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested list of characters. - */ + /** The requested list of characters. */ Characters?: CharacterResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LocationModel - */ export interface LocationModel { - /** - / The two-character continent code for this location - */ + /** City name. */ + City?: string; + /** The two-character continent code for this location */ ContinentCode?: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ + /** The two-character ISO 3166-1 country code for the country associated with the location */ CountryCode?: string; - /** - / City name. - */ - City?: string; - /** - / Latitude coordinate of the geographic location. - */ + /** Latitude coordinate of the geographic location. */ Latitude?: number; - /** - / Longitude coordinate of the geographic location. - */ + /** Longitude coordinate of the geographic location. */ Longitude?: number; } type LoginIdentityProvider = "Unknown" + | "PlayFab" | "Custom" | "GameCenter" @@ -3754,1568 +3659,1367 @@ declare module PlayFabClientModels { | "IOSDevice" | "AndroidDevice" | "Twitch" - | "WindowsHello"; + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginResult - */ export interface LoginResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique token authorizing the user and game at the server level, for the current session. - */ - SessionTicket?: string; - /** - / Player's unique PlayFabId. - */ - PlayFabId?: string; - /** - / True if the account was newly created on this login. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ + EntityToken?: EntityTokenResponse; + /** Results for requested info. */ + InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue */ + LastLoginTime?: string; + /** True if the master_player_account was newly created on this login. */ NewlyCreated: boolean; - /** - / Settings specific to this user. - */ + /** Player's unique PlayFabId. */ + PlayFabId?: string; + /** Unique token authorizing the user and game at the server level, for the current session. */ + SessionTicket?: string; + /** Settings specific to this user. */ SettingsForUser?: UserSettings; - /** - / The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue - */ - LastLoginTime?: string; - /** - / Results for requested info. - */ - InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The experimentation treatments for this user at the time of login. */ + TreatmentAssignment?: TreatmentAssignment; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithAndroidDeviceIDRequest - */ export interface LoginWithAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific model of the user's device. */ + AndroidDevice?: string; + /** Android device identifier for the user's device. */ + AndroidDeviceId?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; + + } + + export interface LoginWithAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; /** - / Android device identifier for the user's device. - */ - AndroidDeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. + * The JSON Web token (JWT) returned by Apple after login. Represented as the identityToken field in the authorization + * credential payload. If you choose to ignore the expiration date for identity tokens, you will receive an NotAuthorized + * error if Apple rotates the signing key. In this case, users have to login to provide a fresh identity token. */ - AndroidDevice?: string; + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Android device. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId?: string; + + } + + export interface LoginWithBattleNetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithCustomIDRequest - */ export interface LoginWithCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Custom unique identifier for the user, generated by the title. - */ - CustomId: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Custom ID. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** Custom unique identifier for the user, generated by the title. */ + CustomId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithEmailAddressRequest - */ export interface LoginWithEmailAddressRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Email address for the account. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Email address for the account. */ Email: string; - /** - / Password for the PlayFab account (6-100 characters) - */ + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ Password: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithFacebookRequest - */ - export interface LoginWithFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LoginWithFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Facebook Instant Games signature for the user. */ + FacebookInstantGamesSignature: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / Unique identifier from Facebook for the user. - */ - AccessToken: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Facebook account. - */ + + } + + export interface LoginWithFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier from Facebook for the user. */ + AccessToken?: string; + /** Token used for limited login authentication. */ + AuthenticationToken?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithGameCenterRequest - */ export interface LoginWithGameCenterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Unique Game Center player id. - */ - PlayerId: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Game Center id. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Unique Game Center player id. */ + PlayerId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** The URL for the public encryption key that will be used to verify the signature. */ + PublicKeyUrl?: string; + /** A random value used to compute the hash and keep it randomized. */ + Salt?: string; + /** The verification signature of the authentication payload. */ + Signature?: string; + /** + * The integer representation of date and time that the signature was created on. PlayFab will reject authentication + * signatures not within 10 minutes of the server's current time. + */ + Timestamp?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithGoogleAccountRequest - */ export interface LoginWithGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / OAuth 2.0 server authentication code obtained on the client by calling the getServerAuthCode() (https://developers.google.com/identity/sign-in/android/offline-access) Google client API. + * OAuth 2.0 server authentication code obtained on the client by calling the getServerAuthCode() + * (https://developers.google.com/identity/sign-in/android/offline-access) Google client API. */ ServerAuthCode?: string; + /** Optional boolean to opt out of setting the MPA email when creating a Google account, defaults to true. */ + SetEmail?: boolean; /** - / OAuth 2.0 access token obtained on the client by calling the getAccessToken() Google client API. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - AccessToken?: string; + TitleId?: string; + + } + + export interface LoginWithGooglePlayGamesServicesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Google account. + * OAuth 2.0 server authentication code obtained on the client by calling the requestServerSideAccess() + * (https://developers.google.com/games/services/android/signin) Google Play Games client API. */ - CreateAccount?: boolean; + ServerAuthCode?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithIOSDeviceIDRequest - */ export interface LoginWithIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Vendor-specific iOS identifier for the user's device. - */ - DeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId?: string; + /** Specific model of the user's device. */ DeviceModel?: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this iOS device. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - CreateAccount?: boolean; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithKongregateRequest - */ export interface LoginWithKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Token issued by Kongregate's client API for the user. */ + AuthTicket?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Numeric user ID assigned by Kongregate */ + KongregateId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; + + } + + export interface LoginWithNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** The JSON Web token (JWT) returned by Nintendo after login. */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Numeric user ID assigned by Kongregate - */ - KongregateId: string; - /** - / Token issued by Kongregate's client API for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - AuthTicket: string; + TitleId?: string; + + } + + export interface LoginWithNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Kongregate account. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId?: string; + + } + + export interface LoginWithOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; /** - / Flags for which pieces of info to return for the user. + * The JSON Web token (JWT) returned by the identity provider after login. Represented as the id_token field in the + * identity provider's response. */ + IdToken: string; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. + */ + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithPlayFabRequest - */ export interface LoginWithPlayFabRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ + Password: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / PlayFab username for the account. - */ + /** PlayFab username for the account. */ Username: string; + + } + + export interface LoginWithPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code provided by the PlayStation :tm: Network OAuth provider. */ + AuthCode?: string; /** - / Password for the PlayFab account (6-100 characters) + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ - Password: string; + AuthVersion?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithSteamRequest - */ export interface LoginWithSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte 0x08 should become "08"). + * Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte + * 0x08 should become "08"). */ - SteamTicket: string; + SteamTicket?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Steam account. + * True if ticket was generated using ISteamUser::GetAuthTicketForWebAPI() using "AzurePlayFab" as the identity string. + * False if the ticket was generated with ISteamUser::GetAuthSessionTicket(). */ - CreateAccount?: boolean; + TicketIsServiceSpecific?: boolean; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithTwitchRequest - */ export interface LoginWithTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Token issued by Twitch's API for the user. - */ - AccessToken: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Twitch account. - */ + /** Token issued by Twitch's API for the user. */ + AccessToken?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithWindowsHelloRequest - */ - export interface LoginWithWindowsHelloRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LoginWithXboxRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / The signed response from the user for the Challenge. - */ - ChallengeSignature: string; - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; - /** - / Flags for which pieces of info to return for the user. - */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LogStatement - */ export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ Level?: string; Message?: string; - /** - / Optional object accompanying the message as contextual information - */ - Data?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.MatchmakeRequest - */ - export interface MatchmakeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Build version to match against. [Note: Required if LobbyId is not specified] - */ - BuildVersion?: string; - /** - / Region to match make against. [Note: Required if LobbyId is not specified] - */ - Region?: string; - /** - / Game mode to match make against. [Note: Required if LobbyId is not specified] - */ - GameMode?: string; - /** - / Lobby identifier to match make against. This is used to select a specific Game Server Instance. - */ - LobbyId?: string; + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / Player statistic to use in finding a match. May be null for no stat-based matching. + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - StatisticName?: string; - /** - / Character to use for stats based matching. Leave null to use account stats. - */ - CharacterId?: string; - /** - / Start a game session if one with an open slot is not found. Defaults to true. - */ - StartNewIfNoneFound?: boolean; - /** - / Filter to include and/or exclude Game Server Instances associated with certain Tags - */ - TagFilter?: CollectionFilter; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.MatchmakeResult - */ - export interface MatchmakeResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique lobby identifier of the server matched - */ - LobbyID?: string; - /** - / IP address of the server - */ - ServerHostname?: string; - /** - / port number to use for non-http communications with the server - */ - ServerPort?: number; - /** - / server authorization ticket (used by RedeemMatchmakerTicket to validate user insertion into the game) - */ - Ticket?: string; - /** - / timestamp for when the server will expire, if applicable - */ - Expires?: string; - /** - / time in milliseconds the application is configured to wait on matchmaking results - */ - PollWaitTimeMS?: number; + export interface MicrosoftStorePayload { + /** Microsoft store ID key. This is optional. Alternatively you can use XboxToken */ + CollectionsMsIdKey?: string; + /** If collectionsMsIdKey is provided, this will verify the user id in the collectionsMsIdKey is the same. */ + UserId?: string; /** - / result of match making process + * Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). This is + * optional. Alternatively can use CollectionsMsIdKey */ - Status?: string; + XboxToken?: string; } - type MatchmakeStatus = "Complete" - | "Waiting" - | "GameNotFound" - | "NoAvailableSlots" - | "SessionClosed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ModifyUserVirtualCurrencyResult - */ export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / User currency was subtracted from. + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ + BalanceChange: number; + /** User currency was subtracted from. */ PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ + /** Name of the virtual currency which was modified. */ VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.NameIdentifier - */ export interface NameIdentifier { - Name?: string; + /** Id Identifier, if present */ Id?: string; + /** Name Identifier, if present */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.OpenTradeRequest - */ - export interface OpenTradeRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface NintendoServiceAccountPlayFabIdPair { + /** Unique Nintendo Switch Service Account identifier for a user. */ + NintendoServiceAccountId?: string; /** - / Player inventory items offered for trade. If not set, the trade is effectively a gift request + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Service Account + * identifier. */ - OfferedInventoryInstanceIds?: string[]; - /** - / Catalog items accepted for the trade. If not set, the trade is effectively a gift. - */ - RequestedCatalogItemIds?: string[]; + PlayFabId?: string; + + } + + export interface NintendoSwitchPlayFabIdPair { + /** Unique Nintendo Switch Device identifier for a user. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Device identifier. */ + PlayFabId?: string; + + } + + export interface OpenIdSubjectIdentifier { + /** The issuer URL for the OpenId Connect provider, or the override URL if an override exists. */ + Issuer: string; + /** The unique subject identifier within the context of the issuer. */ + Subject: string; + + } + + export interface OpenIdSubjectIdentifierPlayFabIdPair { + /** Unique OpenId Connect identifier for a user. */ + OpenIdSubjectIdentifier?: OpenIdSubjectIdentifier; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the OpenId Connect identifier. */ + PlayFabId?: string; + + } + + export interface OpenTradeRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Players who are allowed to accept the trade. If null, the trade may be accepted by any player. If empty, the trade may not be accepted by any player. + * Players who are allowed to accept the trade. If null, the trade may be accepted by any player. If empty, the trade may + * not be accepted by any player. */ AllowedPlayerIds?: string[]; + /** Player inventory items offered for trade. If not set, the trade is effectively a gift request */ + OfferedInventoryInstanceIds?: string[]; + /** Catalog items accepted for the trade. If not set, the trade is effectively a gift. */ + RequestedCatalogItemIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.OpenTradeResponse - */ export interface OpenTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The information about the trade that was just opened. - */ + /** The information about the trade that was just opened. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PayForPurchaseRequest - */ export interface PayForPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier returned from StartPurchase. - */ + /** Currency to use to fund the purchase. */ + Currency: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Purchase order identifier returned from StartPurchase. */ OrderId: string; - /** - / Payment provider to use to fund the purchase. - */ + /** Payment provider to use to fund the purchase. */ ProviderName: string; - /** - / Currency to use to fund the purchase. - */ - Currency: string; - /** - / Payment provider transaction identifier. Required for Facebook Payments. - */ + /** Payment provider transaction identifier. Required for Facebook Payments. */ ProviderTransactionId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PayForPurchaseResult - */ export interface PayForPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; - /** - / Status of the transaction. - */ - Status?: string; - /** - / Virtual currency cost of the transaction. - */ - VCAmount?: { [key: string]: number }; - /** - / Real world currency for the transaction. - */ - PurchaseCurrency?: string; - /** - / Real world cost of the transaction. - */ - PurchasePrice: number; - /** - / Local credit applied to the transaction (provider specific). - */ + /** Local credit applied to the transaction (provider specific). */ CreditApplied: number; - /** - / Provider used for the transaction. - */ + /** Purchase order identifier. */ + OrderId?: string; + /** Provider used for the transaction. */ ProviderData?: string; - /** - / URL to the purchase provider page that details the purchase. - */ + /** A token generated by the provider to authenticate the request (provider-specific). */ + ProviderToken?: string; + /** URL to the purchase provider page that details the purchase. */ PurchaseConfirmationPageURL?: string; - /** - / Current virtual currency totals for the user. - */ + /** Currency for the transaction, may be a virtual currency or real money. */ + PurchaseCurrency?: string; + /** Cost of the transaction. */ + PurchasePrice: number; + /** Status of the transaction. */ + Status?: string; + /** Virtual currencies granted by the transaction, if any. */ + VCAmount?: { [key: string]: number }; + /** Current virtual currency balances for the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / A token generated by the provider to authenticate the request (provider-specific). - */ - ProviderToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PaymentOption - */ export interface PaymentOption { - /** - / Specific currency to use to fund the purchase. - */ + /** Specific currency to use to fund the purchase. */ Currency?: string; - /** - / Name of the purchase provider for this option. - */ - ProviderName?: string; - /** - / Amount of the specified currency needed for the purchase. - */ + /** Amount of the specified currency needed for the purchase. */ Price: number; - /** - / Amount of existing credit the user has with the provider. - */ + /** Name of the purchase provider for this option. */ + ProviderName?: string; + /** Amount of existing credit the user has with the provider. */ StoreCredit: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerLeaderboardEntry - */ export interface PlayerLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ + /** Title-specific display name of the user for this leaderboard entry. */ DisplayName?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; - /** - / The profile of the user, if requested. - */ + /** The profile of the user, if requested. */ Profile?: PlayerProfileModel; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerProfileModel - */ export interface PlayerProfileModel { - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Player record created - */ + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Player account origination - */ - Origination?: string; - /** - / Last login + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ LastLogin?: string; - /** - / If the player is currently banned, the UTC Date when the ban expires - */ - BannedUntil?: string; - /** - / List of geographic locations where the player has logged-in - */ + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ Locations?: LocationModel[]; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Image URL of the player's avatar - */ - AvatarUrl?: string; - /** - / List of player's tags for segmentation - */ - Tags?: TagModel[]; - /** - / List of configured end points registered for sending the player push notifications - */ + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ PushNotificationRegistrations?: PushNotificationRegistrationModel[]; - /** - / List of third party accounts linked to this player - */ - LinkedAccounts?: LinkedPlatformAccountModel[]; - /** - / List of advertising campaigns the player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttributionModel[]; - /** - / A sum of player's total purchases across all real-money currencies, converted to US Dollars equivalent - */ - TotalValueToDateInUSD?: number; - /** - / List of player's total lifetime real-money purchases by currency - */ - ValuesToDate?: ValueToDateModel[]; - /** - / List of player's virtual currency balances - */ - VirtualCurrencyBalances?: VirtualCurrencyBalanceModel[]; - /** - / List of leaderboard statistic values for the player - */ + /** List of leaderboard statistic values for the player */ Statistics?: StatisticModel[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerProfileViewConstraints - */ - export interface PlayerProfileViewConstraints { - /** - / Whether to show the display name. Defaults to false - */ - ShowDisplayName: boolean; - /** - / Whether to show the created date. Defaults to false - */ - ShowCreated: boolean; - /** - / Whether to show origination. Defaults to false - */ - ShowOrigination: boolean; - /** - / Whether to show the last login time. Defaults to false - */ - ShowLastLogin: boolean; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Whether to show the banned until time. Defaults to false + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ ShowBannedUntil: boolean; - /** - / Whether to show statistics, the most recent version of each stat. Defaults to false - */ - ShowStatistics: boolean; - /** - / Whether to show campaign attributions. Defaults to false - */ + /** Whether to show campaign attributions. Defaults to false */ ShowCampaignAttributions: boolean; - /** - / Whether to show push notification registrations. Defaults to false - */ - ShowPushNotificationRegistrations: boolean; - /** - / Whether to show the linked accounts. Defaults to false - */ + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ ShowLinkedAccounts: boolean; - /** - / Whether to show the total value to date in usd. Defaults to false - */ + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ ShowTotalValueToDateInUsd: boolean; - /** - / Whether to show the values to date. Defaults to false - */ + /** Whether to show the values to date. Defaults to false */ ShowValuesToDate: boolean; - /** - / Whether to show tags. Defaults to false - */ - ShowTags: boolean; - /** - / Whether to show player's locations. Defaults to false - */ - ShowLocations: boolean; - /** - / Whether to show player's avatar URL. Defaults to false - */ - ShowAvatarUrl: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerStatisticVersion - */ export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ + /** time when the statistic version became active */ + ActivationTime: string; + /** time when the statistic version became inactive due to statistic version incrementing */ + DeactivationTime?: string; + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ StatisticName?: string; - /** - / version of the statistic - */ + /** version of the statistic */ Version: number; + + } + + export interface PlayStation5Payload { + /** An optional list of entitlement ids to query against PlayStation :tm: Network */ + Ids?: string[]; + /** Id of the PlayStation :tm: Network service label to consume entitlements from */ + ServiceLabel?: string; + + } + + export interface PSNAccountPlayFabIdPair { /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ - ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - ScheduledDeactivationTime?: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNAccountId?: string; + + } + + export interface PSNOnlinePlayFabIdPair { /** - / time when the statistic version became inactive due to statistic version incrementing + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - DeactivationTime?: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNOnlineId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PurchaseItemRequest - */ export interface PurchaseItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the item to purchase. - */ + /** Catalog version for the items to be purchased (defaults to most recent version. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique identifier of the item to purchase. */ ItemId: string; - /** - / Virtual currency to use to purchase the item. - */ - VirtualCurrency: string; - /** - / Price the client expects to pay for the item (in case a new catalog or store was uploaded, with new prices). - */ + /** Price the client expects to pay for the item (in case a new catalog or store was uploaded, with new prices). */ Price: number; - /** - / Catalog version for the items to be purchased (defaults to most recent version. - */ - CatalogVersion?: string; - /** - / Store to buy this item through. If not set, prices default to those in the catalog. - */ + /** Store to buy this item through. If not set, prices default to those in the catalog. */ StoreId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId?: string; + /** Virtual currency to use to purchase the item. */ + VirtualCurrency: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PurchaseItemResult - */ export interface PurchaseItemResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface PurchaseReceiptFulfillment { + /** Items granted to the player in fulfillment of the validated receipt. */ + FulfilledItems?: ItemInstance[]; /** - / Details for the items purchased. + * Source of the payment price information for the recorded purchase transaction. A value of 'Request' indicates that the + * price specified in the request was used, whereas a value of 'Catalog' indicates that the real-money price of the catalog + * item matching the product ID in the validated receipt transaction and the currency specified in the request (defaulting + * to USD) was used. */ - Items?: ItemInstance[]; + RecordedPriceSource?: string; + /** Currency used to purchase the items (ISO 4217 currency code). */ + RecordedTransactionCurrency?: string; + /** Amount of the stated currency paid for the items, in centesimal units */ + RecordedTransactionTotal?: number; } type PushNotificationPlatform = "ApplePushNotificationService" + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PushNotificationRegistrationModel - */ export interface PushNotificationRegistrationModel { - /** - / Push notification platform - */ - Platform?: string; - /** - / Notification configured endpoint - */ + /** Notification configured endpoint */ NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RedeemCouponRequest - */ export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generated coupon code to redeem. - */ - CouponCode: string; - /** - / Catalog version of the coupon. If null, uses the default catalog - */ + /** Catalog version of the coupon. If null, uses the default catalog */ CatalogVersion?: string; - /** - / Optional identifier for the Character that should receive the item. If null, item is added to the player - */ + /** Optional identifier for the Character that should receive the item. If null, item is added to the player */ CharacterId?: string; + /** Generated coupon code to redeem. */ + CouponCode: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RedeemCouponResult - */ export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Items granted to the player as a result of redeeming the coupon. - */ + /** Items granted to the player as a result of redeeming the coupon. */ GrantedItems?: ItemInstance[]; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegionInfo - */ - export interface RegionInfo { - /** - / unique identifier for the region - */ - Region?: string; - /** - / name of the region - */ - Name?: string; - /** - / indicates whether the server specified is available in this region - */ - Available: boolean; - /** - / url to ping to get roundtrip time - */ - PingUrl?: string; + export interface RefreshPSNAuthTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code returned by PlayStation :tm: Network OAuth system. */ + AuthCode: string; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterForIOSPushNotificationRequest - */ export interface RegisterForIOSPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique token generated by the Apple Push Notification service when the title registered to receive push notifications. - */ + /** Message to display when confirming push notification. */ + ConfirmationMessage?: string; + /** Unique token generated by the Apple Push Notification service when the title registered to receive push notifications. */ DeviceToken: string; - /** - / If true, send a test push message immediately after sucessful registration. Defaults to false. - */ + /** If true, send a test push message immediately after sucessful registration. Defaults to false. */ SendPushNotificationConfirmation?: boolean; - /** - / Message to display when confirming push notification. - */ - ConfirmationMessage?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterForIOSPushNotificationResult - */ export interface RegisterForIOSPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterPlayFabUserRequest - */ export interface RegisterPlayFabUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / PlayFab username for the account (3-20 characters) - */ - Username?: string; - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** An optional parameter for setting the display name for this title (3-25 characters). */ + DisplayName?: string; + /** User email address attached to their account */ Email?: string; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ + Password?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Password for the PlayFab account (6-100 characters) - */ - Password: string; - /** - / An optional parameter that specifies whether both the username and email parameters are required. If true, both parameters are required; if false, the user must supply either the username or email parameter. The default value is true. + * An optional parameter that specifies whether both the username and email parameters are required. If true, both + * parameters are required; if false, the user must supply either the username or email parameter. The default value is + * true. */ RequireBothUsernameAndEmail?: boolean; /** - / An optional parameter for setting the display name for this title. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - DisplayName?: string; + TitleId?: string; + /** PlayFab username for the account (3-20 characters) */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterPlayFabUserResult - */ export interface RegisterPlayFabUserResult extends PlayFabModule.IPlayFabResultCommon { /** - / PlayFab unique identifier for this newly created account. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ + EntityToken?: EntityTokenResponse; + /** PlayFab unique identifier for this newly created account. */ PlayFabId?: string; - /** - / Unique token identifying the user and game at the server level, for the current session. - */ + /** Unique token identifying the user and game at the server level, for the current session. */ SessionTicket?: string; - /** - / PlayFab unique user name. - */ - Username?: string; - /** - / Settings specific to this user. - */ + /** Settings specific to this user. */ SettingsForUser?: UserSettings; + /** PlayFab unique user name. */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterWithWindowsHelloRequest - */ - export interface RegisterWithWindowsHelloRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId: string; - /** - / Player's user named used by Windows Hello. - */ - UserName: string; - /** - / PublicKey generated by Windows Hello. - */ - PublicKey: string; - /** - / Device name. - */ - DeviceName?: string; - /** - / Flags for which pieces of info to return for the user. - */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + export interface RemoveContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface RemoveContactEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveFriendRequest - */ export interface RemoveFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account which is to be removed. - */ + /** PlayFab identifier of the friend account which is to be removed. */ FriendPlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveFriendResult - */ export interface RemoveFriendResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveGenericIDRequest - */ export interface RemoveGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generic service identifier to be removed from the player. - */ + /** Generic service identifier to be removed from the player. */ GenericId: GenericServiceId; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveGenericIDResult - */ export interface RemoveGenericIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveSharedGroupMembersRequest - */ export interface RemoveSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveSharedGroupMembersResult - */ export interface RemoveSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ReportPlayerClientRequest - */ + export interface ReportAdActivityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Type of activity, may be Opened, Closed, Start or End */ + Activity: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique ID of the placement to report for */ + PlacementId: string; + /** Unique ID of the reward the player was offered */ + RewardId: string; + + } + + export interface ReportAdActivityResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface ReportPlayerClientRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab identifier of the reported player. - */ - ReporteeId: string; - /** - / Optional additional comment by reporting player. - */ + /** Optional additional comment by reporting player. */ Comment?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier of the reported player. */ + ReporteeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ReportPlayerClientResult - */ export interface ReportPlayerClientResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Indicates whether this action completed successfully. - */ - Updated: boolean; - /** - / The number of remaining reports which may be filed today. - */ + /** The number of remaining reports which may be filed today. */ SubmissionsRemaining: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RestoreIOSPurchasesRequest - */ export interface RestoreIOSPurchasesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. - */ + /** Catalog version of the restored items. If null, defaults to primary catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ ReceiptData: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RestoreIOSPurchasesResult - */ export interface RestoreIOSPurchasesResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; + + } + + export interface RewardAdActivityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Placement unique ID */ + PlacementId: string; + /** Reward unique ID */ + RewardId: string; + + } + + export interface RewardAdActivityResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayStream Event ID that was generated by this reward (all subsequent events are associated with this event identifier) */ + AdActivityEventId?: string; + /** Debug results from the grants */ + DebugResults?: string[]; + /** Id of the placement the reward was for */ + PlacementId?: string; + /** Name of the placement the reward was for */ + PlacementName?: string; + /** If placement has viewing limits indicates how many views are left */ + PlacementViewsRemaining?: number; + /** If placement has viewing limits indicates when they will next reset */ + PlacementViewsResetMinutes?: number; + /** Reward results */ + RewardResults?: AdRewardResults; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ScriptExecutionError - */ export interface ScriptExecutionError { /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ Error?: string; - /** - / Details about the error - */ + /** Details about the error */ Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ + /** Point during the execution of the script at which the error occurred, if any */ StackTrace?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SendAccountRecoveryEmailRequest - */ export interface SendAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SendAccountRecoveryEmailResult - */ export interface SendAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SetFriendTagsRequest - */ export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account to which the tag(s) should be applied. - */ + /** PlayFab identifier of the friend account to which the tag(s) should be applied. */ FriendPlayFabId: string; - /** - / Array of tags to set on the friend account. - */ + /** Array of tags to set on the friend account. */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SetFriendTagsResult - */ export interface SetFriendTagsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SharedGroupDataRecord - */ - export interface SharedGroupDataRecord { - /** - / Data stored for the specified group data key. - */ - Value?: string; - /** - / Unique PlayFab identifier of the user to last update this value. - */ - LastUpdatedBy?: string; - /** - / Timestamp for when this data was last updated. - */ - LastUpdated: string; - /** - / Indicates whether this data can be read by all users (public) or only members of the group (private). - */ - Permission?: string; - - } - - type SourceType = "Admin" - | "BackEnd" - | "GameClient" - | "GameServer" - | "Partner"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartGameRequest - */ - export interface StartGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / version information for the build of the game server which is to be started - */ - BuildVersion: string; - /** - / the region to associate this server with for match filtering - */ - Region: string; - /** - / the title-defined game mode this server is to be running (defaults to 0 if there is only one mode) - */ - GameMode: string; - /** - / player statistic for others to use in finding this game. May be null for no stat-based matching - */ - StatisticName?: string; - /** - / character to use for stats based matching. Leave null to use account stats - */ - CharacterId?: string; - /** - / custom command line argument when starting game server process - */ - CustomCommandLineData?: string; + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartGameResult - */ - export interface StartGameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for the lobby of the server started - */ - LobbyID?: string; - /** - / server IP address - */ - ServerHostname?: string; - /** - / port on the server to be used for communication - */ - ServerPort?: number; - /** - / unique identifier for the server - */ - Ticket?: string; - /** - / timestamp for when the server should expire, if applicable - */ - Expires?: string; - /** - / password required to log into the server - */ - Password?: string; + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartPurchaseRequest - */ + export interface SharedGroupDataRecord { + /** Timestamp for when this data was last updated. */ + LastUpdated: string; + /** Unique PlayFab identifier of the user to last update this value. */ + LastUpdatedBy?: string; + /** Indicates whether this data can be read by all users (public) or only members of the group (private). */ + Permission?: string; + /** Data stored for the specified group data key. */ + Value?: string; + + } + + type SourceType = "Admin" + + | "BackEnd" + | "GameClient" + | "GameServer" + | "Partner" + | "Custom" + | "API"; + export interface StartPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version for the items to be purchased. Defaults to most recent catalog. - */ + /** Catalog version for the items to be purchased. Defaults to most recent catalog. */ CatalogVersion?: string; - /** - / Store through which to purchase items. If not set, prices will be pulled from the catalog itself. - */ - StoreId?: string; - /** - / Array of items to purchase. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to purchase. */ Items: ItemPurchaseRequest[]; + /** Store through which to purchase items. If not set, prices will be pulled from the catalog itself. */ + StoreId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartPurchaseResult - */ export interface StartPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; - /** - / Cart items to be purchased. - */ + /** Cart items to be purchased. */ Contents?: CartItem[]; - /** - / Available methods by which the user can pay. - */ + /** Purchase order identifier. */ + OrderId?: string; + /** Available methods by which the user can pay. */ PaymentOptions?: PaymentOption[]; - /** - / Current virtual currency totals for the user. - */ + /** Current virtual currency totals for the user. */ VirtualCurrencyBalances?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticModel - */ export interface StatisticModel { - /** - / Statistic name - */ + /** Statistic name */ Name?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - Version: number; - /** - / Statistic value - */ + /** Statistic value */ Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticNameVersion - */ export interface StatisticNameVersion { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; - /** - / the version of the statistic to be returned - */ + /** the version of the statistic to be returned */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticUpdate - */ export interface StatisticUpdate { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; + /** statistic value for the player */ + Value: number; /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when setting the statistic value for the first time. + * for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when + * setting the statistic value for the first time. */ Version?: number; - /** - / statistic value for the player - */ - Value: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticValue - */ export interface StatisticValue { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName?: string; - /** - / statistic value for the player - */ + /** statistic value for the player */ Value: number; - /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded - */ + /** for updates to an existing statistic value for a player, the version of the statistic when it was loaded */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SteamPlayFabIdPair - */ + 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 Steam identifier for a user. - */ - SteamStringId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. - */ + /** 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. */ + SteamStringId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StoreItem - */ export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the catalog + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ ItemId: string; - /** - / Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Override prices for this item for specific currencies - */ + /** Override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Store specific custom data. The data only exists as part of this store; it is not transferred to item instances - */ - CustomData?: any; - /** - / Intended display position for this item. Note that 0 is the first position - */ - DisplayPosition?: number; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StoreMarketingModel - */ export interface StoreMarketingModel { - /** - / Display name of a store as it will appear to users. - */ - DisplayName?: string; - /** - / Tagline for a store. - */ + /** Tagline for a store. */ Description?: string; - /** - / Custom data about a store. - */ + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ Metadata?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SubtractUserVirtualCurrencyRequest - */ + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the virtual currency which is to be decremented. - */ - VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the virtual currency which is to be decremented. */ + VirtualCurrency: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TagModel - */ export interface TagModel { - /** - / Full value of the tag, including namespace - */ + /** Full value of the tag, including namespace */ TagValue?: string; } type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TitleNewsItem - */ export interface TitleNewsItem { - /** - / Date and time when the news items was posted. - */ - Timestamp: string; - /** - / Unique identifier of news item. - */ + /** News item text. */ + Body?: string; + /** Unique identifier of news item. */ NewsId?: string; - /** - / Title of the news item. - */ + /** Date and time when the news item was posted. */ + Timestamp: string; + /** Title of the news item. */ Title?: string; - /** - / News item text. - */ - Body?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TradeInfo - */ export interface TradeInfo { - /** - / Describes the current state of this trade. - */ - Status?: string; - /** - / The identifier for this trade. - */ - TradeId?: string; - /** - / The PlayFabId for the offering player. - */ - OfferingPlayerId?: string; - /** - / The itemInstance Ids that are being offered. - */ - OfferedInventoryInstanceIds?: string[]; - /** - / The catalogItem Ids of the item instances being offered. - */ - OfferedCatalogItemIds?: string[]; - /** - / The catalogItem Ids requested in exchange. - */ - RequestedCatalogItemIds?: string[]; - /** - / An optional list of players allowed to complete this trade. If null, anybody can complete the trade. - */ - AllowedPlayerIds?: string[]; - /** - / The PlayFab ID of the player who accepted the trade. If null, no one has accepted the trade. - */ - AcceptedPlayerId?: string; - /** - / Item instances from the accepting player that are used to fulfill the trade. If null, no one has accepted the trade. - */ + /** Item instances from the accepting player that are used to fulfill the trade. If null, no one has accepted the trade. */ AcceptedInventoryInstanceIds?: string[]; - /** - / The UTC time when this trade was created. - */ - OpenedAt?: string; - /** - / If set, The UTC time when this trade was fulfilled. - */ - FilledAt?: string; - /** - / If set, The UTC time when this trade was canceled. - */ + /** The PlayFab ID of the player who accepted the trade. If null, no one has accepted the trade. */ + AcceptedPlayerId?: string; + /** An optional list of players allowed to complete this trade. If null, anybody can complete the trade. */ + AllowedPlayerIds?: string[]; + /** If set, The UTC time when this trade was canceled. */ CancelledAt?: string; - /** - / If set, The UTC time when this trade was made invalid. - */ + /** If set, The UTC time when this trade was fulfilled. */ + FilledAt?: string; + /** If set, The UTC time when this trade was made invalid. */ InvalidatedAt?: string; + /** The catalogItem Ids of the item instances being offered. */ + OfferedCatalogItemIds?: string[]; + /** The itemInstance Ids that are being offered. */ + OfferedInventoryInstanceIds?: string[]; + /** The PlayFabId for the offering player. */ + OfferingPlayerId?: string; + /** The UTC time when this trade was created. */ + OpenedAt?: string; + /** The catalogItem Ids requested in exchange. */ + RequestedCatalogItemIds?: string[]; + /** Describes the current state of this trade. */ + Status?: string; + /** The identifier for this trade. */ + TradeId?: string; } type TradeStatus = "Invalid" + | "Opening" | "Open" | "Accepting" @@ -5324,6 +5028,7 @@ declare module PlayFabClientModels { | "Cancelled"; type TransactionStatus = "CreateCart" + | "Init" | "Approved" | "Succeeded" @@ -5344,600 +5049,595 @@ declare module PlayFabClientModels { | "Other" | "Failed"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TwitchPlayFabIdPair - */ + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + export interface TwitchPlayFabIdPair { - /** - / Unique Twitch identifier for a user. - */ - TwitchId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. */ PlayFabId?: string; + /** Unique Twitch identifier for a user. */ + TwitchId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkAndroidDeviceIDRequest - */ export interface UnlinkAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Android device identifier for the user's device. If not specified, the most recently signed in Android Device ID will be used. + * Android device identifier for the user's device. If not specified, the most recently signed in Android Device ID will be + * used. */ AndroidDeviceId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkAndroidDeviceIDResult - */ export interface UnlinkAndroidDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkCustomIDRequest - */ + export interface UnlinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + export interface UnlinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Custom unique identifier for the user, generated by the title. If not specified, the most recently signed in Custom ID will be used. + * Custom unique identifier for the user, generated by the title. If not specified, the most recently signed in Custom ID + * will be used. */ CustomId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkCustomIDResult - */ export interface UnlinkCustomIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkFacebookAccountRequest - */ export interface UnlinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkFacebookAccountResult - */ export interface UnlinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGameCenterAccountRequest - */ + export interface UnlinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games identifier for the user. If not specified, the most recently signed in ID will be used. */ + FacebookInstantGamesId?: string; + + } + + export interface UnlinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGameCenterAccountResult - */ export interface UnlinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGoogleAccountRequest - */ export interface UnlinkGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGoogleAccountResult - */ export interface UnlinkGoogleAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkIOSDeviceIDRequest - */ + export interface UnlinkGooglePlayGamesServicesAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkGooglePlayGamesServicesAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Vendor-specific iOS identifier for the user's device. If not specified, the most recently signed in iOS Device ID will be used. + * Vendor-specific iOS identifier for the user's device. If not specified, the most recently signed in iOS Device ID will + * be used. */ DeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkIOSDeviceIDResult - */ export interface UnlinkIOSDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkKongregateAccountRequest - */ export interface UnlinkKongregateAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkKongregateAccountResult - */ export interface UnlinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkSteamAccountRequest - */ + export interface UnlinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Nintendo Switch Device identifier for the user. If not specified, the most recently signed in device ID will be used. */ + NintendoSwitchDeviceId?: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkSteamAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkSteamAccountResult - */ export interface UnlinkSteamAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkTwitchAccountRequest - */ export interface UnlinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Valid token issued by Twitch. Used to specify which twitch account to unlink from the profile. By default it uses the + * one that is present on the profile. + */ + AccessToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkTwitchAccountResult - */ export interface UnlinkTwitchAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkWindowsHelloAccountRequest - */ - export interface UnlinkWindowsHelloAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; + export interface UnlinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkWindowsHelloAccountResponse - */ - export interface UnlinkWindowsHelloAccountResponse extends PlayFabModule.IPlayFabResultCommon { + export interface UnlinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerInstanceRequest - */ export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog + * associated with the item instance. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / ItemInstanceId of the container to unlock. - */ + /** ItemInstanceId of the container to unlock. */ ContainerItemInstanceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this parameter is required. + * ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this + * parameter is required. */ KeyItemInstanceId?: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog associated with the item instance. - */ - CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerItemRequest - */ export interface UnlockContainerItemRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Catalog ItemId of the container type to unlock. - */ - ContainerItemId: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary + * catalog. */ CatalogVersion?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Catalog ItemId of the container type to unlock. */ + ContainerItemId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerItemResult - */ export interface UnlockContainerItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the container unlocked. - */ + /** Items granted to the player as a result of unlocking the container. */ + GrantedItems?: ItemInstance[]; + /** Unique instance identifier of the container unlocked. */ UnlockedItemInstanceId?: string; - /** - / Unique instance identifier of the key used to unlock the container, if applicable. - */ + /** Unique instance identifier of the key used to unlock the container, if applicable. */ UnlockedWithItemInstanceId?: string; - /** - / Items granted to the player as a result of unlocking the container. - */ - GrantedItems?: ItemInstance[]; - /** - / Virtual currency granted to the player as a result of unlocking the container. - */ + /** Virtual currency granted to the player as a result of unlocking the container. */ VirtualCurrency?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateAvatarUrlRequest - */ export interface UpdateAvatarUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / URL of the avatar image. If empty, it removes the existing avatar URL. - */ + /** URL of the avatar image. If empty, it removes the existing avatar URL. */ ImageUrl: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterDataRequest - */ export interface UpdateCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterDataResult - */ export interface UpdateCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterStatisticsRequest - */ export interface UpdateCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Statistics to be updated with the provided values. - */ + /** Statistics to be updated with the provided values, in the Key(string), Value(int) pattern. */ CharacterStatistics?: { [key: string]: number }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterStatisticsResult - */ export interface UpdateCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdatePlayerStatisticsRequest - */ - export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. + */ + ExpectedPropertiesVersion?: number; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; + + } + + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { /** - / Statistics to be updated with the provided values + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Statistics to be updated with the provided values */ Statistics: StatisticUpdate[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdatePlayerStatisticsResult - */ export interface UpdatePlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateSharedGroupDataRequest - */ + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; + + } + export interface UpdateSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys in this request. - */ + /** Permission to be applied to all user data keys in this request. */ Permission?: string; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateSharedGroupDataResult - */ export interface UpdateSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. This is used for requests by one player for information about another player; those requests will only return Public keys. + * Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. This is used + * for requests by one player for information about another player; those requests will only return Public keys. */ Permission?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserTitleDisplayNameRequest - */ export interface UpdateUserTitleDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / New title display name for the user - must be between 3 and 25 characters. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** New title display name for the user - must be between 3 and 25 characters. */ DisplayName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserTitleDisplayNameResult - */ export interface UpdateUserTitleDisplayNameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Current title display name for the user (this will be the original display name if the rename attempt failed). - */ + /** Current title display name for the user (this will be the original display name if the rename attempt failed). */ DisplayName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserCustomIdInfo - */ + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; + + } + export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -5954,371 +5654,295 @@ declare module PlayFabClientModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserSettings - */ export interface UserSettings { - /** - / Boolean for whether this player is eligible for ad tracking. - */ + /** Boolean for whether this player is eligible for gathering device info. */ + GatherDeviceInfo: boolean; + /** Boolean for whether this player should report OnFocus play-time tracking. */ + GatherFocusInfo: boolean; + /** Boolean for whether this player is eligible for ad tracking. */ NeedsAttribution: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateAmazonReceiptRequest - */ export interface ValidateAmazonReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / ReceiptId returned by the Amazon App Store in-app purchase API - */ - ReceiptId: string; - /** - / AmazonId of the user making the purchase as returned by the Amazon App Store in-app purchase API - */ - UserId: string; - /** - / Catalog version to use when granting receipt item. If null, defaults to primary catalog. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ CatalogVersion?: string; - /** - / Currency used for the purchase. - */ - CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** Currency used to pay for the purchase (ISO 4217 currency code). */ + CurrencyCode?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** ReceiptId returned by the Amazon App Store in-app purchase API */ + ReceiptId: string; + /** AmazonId of the user making the purchase as returned by the Amazon App Store in-app purchase API */ + UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateAmazonReceiptResult - */ export interface ValidateAmazonReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateGooglePlayPurchaseRequest - */ export interface ValidateGooglePlayPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Original JSON string returned by the Google Play IAB API. - */ - ReceiptJson: string; - /** - / Signature returned by the Google Play IAB API. - */ - Signature: string; - /** - / Currency used for the purchase. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ + CatalogVersion?: string; + /** Currency used to pay for the purchase (ISO 4217 currency code). */ CurrencyCode?: string; - /** - / Amount of the stated currency paid for the object. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice?: number; + /** Original JSON string returned by the Google Play IAB API. */ + ReceiptJson: string; + /** Signature returned by the Google Play IAB API. */ + Signature: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateGooglePlayPurchaseResult - */ export interface ValidateGooglePlayPurchaseResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateIOSReceiptRequest - */ export interface ValidateIOSReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. - */ - ReceiptData: string; - /** - / Currency used for the purchase. - */ - CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ + CatalogVersion?: string; + /** Currency used to pay for the purchase (ISO 4217 currency code). */ + CurrencyCode?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ + JwsReceiptData?: string; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ + ReceiptData?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateIOSReceiptResult - */ export interface ValidateIOSReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateWindowsReceiptRequest - */ export interface ValidateWindowsReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / XML Receipt returned by the Windows App Store in-app purchase API - */ - Receipt: string; - /** - / Catalog version to use when granting receipt item. If null, defaults to primary catalog. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ CatalogVersion?: string; - /** - / Currency used for the purchase. - */ + /** Currency used to pay for the purchase (ISO 4217 currency code). */ CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** XML Receipt returned by the Windows App Store in-app purchase API */ + Receipt: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateWindowsReceiptResult - */ export interface ValidateWindowsReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValueToDateModel - */ export interface ValueToDateModel { - /** - / ISO 4217 code of the currency used in the purchases - */ + /** ISO 4217 code of the currency used in the purchases */ Currency?: string; /** - / Total value of the purchases in a whole number of 1/100 monetary units. For example 999 indicates nine dollars and ninety-nine cents when Currency is 'USD') + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ TotalValue: number; /** - / Total value of the purchases in a string representation of decimal monetary units (e.g. '9.99' indicates nine dollars and ninety-nine cents when Currency is 'USD')) + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ TotalValueAsDecimal?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.VirtualCurrencyBalanceModel - */ - export interface VirtualCurrencyBalanceModel { - /** - / Name of the virtual currency - */ - Currency?: string; - /** - / Balance of the virtual currency - */ - TotalValue: number; + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteClientCharacterEventRequest - */ export interface WriteClientCharacterEventRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteClientPlayerEventRequest - */ export interface WriteClientPlayerEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteEventResponse - */ export interface WriteEventResponse extends PlayFabModule.IPlayFabResultCommon { /** - / The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to any particular format. + * The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to + * any particular format. */ EventId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteTitleEventRequest - */ export interface WriteTitleEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; + + } + + export interface XboxLiveAccountPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Xbox Live identifier. */ + PlayFabId?: string; + /** Unique Xbox Live identifier for a user. */ + XboxLiveAccountId?: string; } diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabCloudScriptApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabCloudScriptApi.d.ts new file mode 100644 index 00000000..38ac8fc3 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabCloudScriptApi.d.ts @@ -0,0 +1,919 @@ +/// + +declare module PlayFabCloudScriptModule { + export interface IPlayFabCloudScript { + ForgetAllCredentials(): void; + + /** + * Cloud Script is one of PlayFab's most versatile features. It allows client code to request execution of any kind of + * custom server-side functionality you can implement, and it can be used in conjunction with virtually anything. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/executeentitycloudscript + */ + ExecuteEntityCloudScript(request: PlayFabCloudScriptModels.ExecuteEntityCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cloud Script is one of PlayFab's most versatile features. It allows client code to request execution of any kind of + * custom server-side functionality you can implement, and it can be used in conjunction with virtually anything. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/executefunction + */ + ExecuteFunction(request: PlayFabCloudScriptModels.ExecuteFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets registered Azure Functions for a given title id and function name. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/getfunction + */ + GetFunction(request: PlayFabCloudScriptModels.GetFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Event Hub triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listeventhubfunctions + */ + ListEventHubFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listfunctions + */ + ListFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered HTTP triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listhttpfunctions + */ + ListHttpFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Queue triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listqueuedfunctions + */ + ListQueuedFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate an entity PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforentitytriggeredaction + */ + PostFunctionResultForEntityTriggeredAction(request: PlayFabCloudScriptModels.PostFunctionResultForEntityTriggeredActionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate an entity PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforfunctionexecution + */ + PostFunctionResultForFunctionExecution(request: PlayFabCloudScriptModels.PostFunctionResultForFunctionExecutionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate a player PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforplayertriggeredaction + */ + PostFunctionResultForPlayerTriggeredAction(request: PlayFabCloudScriptModels.PostFunctionResultForPlayerTriggeredActionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate a PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforscheduledtask + */ + PostFunctionResultForScheduledTask(request: PlayFabCloudScriptModels.PostFunctionResultForScheduledTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers an event hub triggered Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registereventhubfunction + */ + RegisterEventHubFunction(request: PlayFabCloudScriptModels.RegisterEventHubFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers an HTTP triggered Azure function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registerhttpfunction + */ + RegisterHttpFunction(request: PlayFabCloudScriptModels.RegisterHttpFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers a queue triggered Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registerqueuedfunction + */ + RegisterQueuedFunction(request: PlayFabCloudScriptModels.RegisterQueuedFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unregisters an Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/unregisterfunction + */ + UnregisterFunction(request: PlayFabCloudScriptModels.UnregisterFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabCloudScriptModels { + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + type CloudScriptRevisionOption = "Live" + + | "Latest" + | "Specific"; + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; + + } + + type ContinentCode = "AF" + + | "AN" + | "AS" + | "EU" + | "NA" + | "OC" + | "SA" + | "Unknown"; + + type CountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW" + | "Unknown"; + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EventHubFunctionModel { + /** The connection string for the event hub. */ + ConnectionString?: string; + /** The name of the event hub that triggers the Azure Function. */ + EventHubName?: string; + /** The name the function was registered under. */ + FunctionName?: string; + + } + + export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; + /** + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. + */ + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; + /** + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. + */ + Logs?: LogStatement[]; + /** + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. + */ + LogsTooLarge?: boolean; + MemoryConsumedBytes: number; + /** + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. + */ + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; + + } + + export interface ExecuteEntityCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the CloudScript function to execute */ + FunctionName: string; + /** Object that is passed in to the function as the first argument */ + FunctionParameter?: any; + /** + * Generate a 'entity_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. + */ + GeneratePlayStreamEvent?: boolean; + /** + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpecificRevision parameter is specified, otherwise it is 'Live'. + */ + RevisionSelection?: string; + /** The specific revision to execute, when RevisionSelection is set to 'Specific' */ + SpecificRevision?: number; + + } + + export interface ExecuteFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the CloudScript function to execute */ + FunctionName: string; + /** Object that is passed in to the function as the FunctionArgument field of the FunctionExecutionContext data structure */ + FunctionParameter?: any; + /** + * Generate a 'entity_executed_cloudscript_function' PlayStream event containing the results of the function execution and + * other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. + */ + GeneratePlayStreamEvent?: boolean; + + } + + export interface ExecuteFunctionResult extends PlayFabModule.IPlayFabResultCommon { + /** Error from the CloudScript Azure Function. */ + Error?: FunctionExecutionError; + /** The amount of time the function took to execute */ + ExecutionTimeMilliseconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the function, if any */ + FunctionResult?: any; + /** The size in bytes of the object returned from the function, if any */ + FunctionResultSize?: number; + /** Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. */ + FunctionResultTooLarge?: boolean; + + } + + export interface FunctionExecutionError { + /** + * Error code, such as CloudScriptAzureFunctionsExecutionTimeLimitExceeded, CloudScriptAzureFunctionsArgumentSizeExceeded, + * CloudScriptAzureFunctionsReturnSizeExceeded or CloudScriptAzureFunctionsHTTPRequestError + */ + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the function at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface FunctionModel { + /** The address of the function. */ + FunctionAddress?: string; + /** The name the function was registered under. */ + FunctionName?: string; + /** The trigger type for the function. */ + TriggerType?: string; + + } + + export interface GetFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface GetFunctionResult extends PlayFabModule.IPlayFabResultCommon { + /** The connection string for the storage account containing the queue for a queue trigger Azure Function. */ + ConnectionString?: string; + /** The URL to be invoked to execute an HTTP triggered function. */ + FunctionUrl?: string; + /** The name of the queue for a queue trigger Azure Function. */ + QueueName?: string; + /** The trigger type for the function. */ + TriggerType?: string; + + } + + export interface HttpFunctionModel { + /** The name the function was registered under. */ + FunctionName?: string; + /** The URL of the function. */ + FunctionUrl?: string; + + } + + export interface LinkedPlatformAccountModel { + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ + Platform?: string; + /** Unique account identifier of the user on the platform */ + PlatformUserId?: string; + /** Linked account username of the user on the platform, if available */ + Username?: string; + + } + + export interface ListEventHubFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of EventHub triggered functions that are currently registered for the title. */ + Functions?: EventHubFunctionModel[]; + + } + + export interface ListFunctionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of functions that are currently registered for the title. */ + Functions?: FunctionModel[]; + + } + + export interface ListHttpFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of HTTP triggered functions that are currently registered for the title. */ + Functions?: HttpFunctionModel[]; + + } + + export interface ListQueuedFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of Queue triggered functions that are currently registered for the title. */ + Functions?: QueuedFunctionModel[]; + + } + + export interface LocationModel { + /** City name. */ + City?: string; + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ + Latitude?: number; + /** Longitude coordinate of the geographic location. */ + Longitude?: number; + + } + + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface LogStatement { + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ + Level?: string; + Message?: string; + + } + + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; + /** + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. + */ + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; + + } + + export interface NameIdentifier { + /** Id Identifier, if present */ + Id?: string; + /** Name Identifier, if present */ + Name?: string; + + } + + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; + /** + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. + */ + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; + /** + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. + */ + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayStreamEventEnvelopeModel { + /** The ID of the entity the event is about. */ + EntityId?: string; + /** The type of the entity the event is about. */ + EntityType?: string; + /** Data specific to this event. */ + EventData?: string; + /** The name of the event. */ + EventName?: string; + /** The namespace of the event. */ + EventNamespace?: string; + /** Settings for the event. */ + EventSettings?: string; + + } + + export interface PostFunctionResultForEntityTriggeredActionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + + } + + export interface PostFunctionResultForFunctionExecutionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + + } + + export interface PostFunctionResultForPlayerTriggeredActionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + /** The player profile the function was invoked with. */ + PlayerProfile: PlayerProfileModel; + /** The triggering PlayStream event, if any, that caused the function to be invoked. */ + PlayStreamEventEnvelope?: PlayStreamEventEnvelopeModel; + + } + + export interface PostFunctionResultForScheduledTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The result of the function execution */ + FunctionResult: ExecuteFunctionResult; + /** The id of the scheduled task that invoked the function. */ + ScheduledTaskId: NameIdentifier; + + } + + type PushNotificationPlatform = "ApplePushNotificationService" + + | "GoogleCloudMessaging"; + + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ + NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; + + } + + export interface QueuedFunctionModel { + /** The connection string for the Azure Storage Account that hosts the queue. */ + ConnectionString?: string; + /** The name the function was registered under. */ + FunctionName?: string; + /** The name of the queue that triggers the Azure Function. */ + QueueName?: string; + + } + + export interface RegisterEventHubFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A connection string for the namespace of the event hub for the Azure Function. */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the event hub for the Azure Function. */ + EventHubName: string; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface RegisterHttpFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + /** Full URL for Azure Function that implements the function. */ + FunctionUrl: string; + + } + + export interface RegisterQueuedFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A connection string for the storage account that hosts the queue for the Azure Function. */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + /** The name of the queue for the Azure Function. */ + QueueName: string; + + } + + export interface ScriptExecutionError { + /** + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + */ + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the script at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface StatisticModel { + /** Statistic name */ + Name?: string; + /** Statistic value */ + Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; + + } + + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + + export interface TagModel { + /** Full value of the tag, including namespace */ + TagValue?: string; + + } + + type TriggerType = "HTTP" + + | "Queue" + | "EventHub"; + + export interface UnregisterFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface ValueToDateModel { + /** ISO 4217 code of the currency used in the purchases */ + Currency?: string; + /** + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') + */ + TotalValue: number; + /** + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. + */ + TotalValueAsDecimal?: string; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabDataApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabDataApi.d.ts new file mode 100644 index 00000000..287d8c21 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabDataApi.d.ts @@ -0,0 +1,297 @@ +/// + +declare module PlayFabDataModule { + export interface IPlayFabData { + ForgetAllCredentials(): void; + + /** + * Abort pending file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/abortfileuploads + */ + AbortFileUploads(request: PlayFabDataModels.AbortFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete files on an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/deletefiles + */ + DeleteFiles(request: PlayFabDataModels.DeleteFilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Finalize file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/finalizefileuploads + */ + FinalizeFileUploads(request: PlayFabDataModels.FinalizeFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves file metadata from an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/getfiles + */ + GetFiles(request: PlayFabDataModels.GetFilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves objects from an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/object/getobjects + */ + GetObjects(request: PlayFabDataModels.GetObjectsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Initiates file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/initiatefileuploads + */ + InitiateFileUploads(request: PlayFabDataModels.InitiateFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets objects on an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/object/setobjects + */ + SetObjects(request: PlayFabDataModels.SetObjectsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabDataModels { + export interface AbortFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to have their pending uploads aborted. */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * InitiateFileUploads API or other APIs, you can ensure that the file upload abort operation is performed only if the + * profile has not been updated since you last loaded that version. If the profile for the same entity has been updated, + * the operation will fail with an EntityProfileVersionMismatch error. The conflicting update can be caused by any + * operation that modifies the entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface AbortFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface DeleteFilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be deleted. */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetFiles API or other APIs, you can ensure that the file deletion is performed only if the profile has not been updated + * since you last loaded that version. If the profile for the same entity has been updated, the operation will fail with an + * EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the entity + * profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface DeleteFilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface FinalizeFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be finalized. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + FileNames: string[]; + /** + * Field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * InitiateFileUploads API, you can ensure that the file upload finalization is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion: number; + + } + + export interface FinalizeFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Collection of metadata for the entity's files */ + Metadata?: { [key: string]: GetFileMetadata }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface GetFileMetadata { + /** Checksum value for the file, can be used to check if the file on the server has changed. */ + Checksum?: string; + /** Download URL where the file can be retrieved */ + DownloadUrl?: string; + /** Name of the file */ + FileName?: string; + /** Last UTC time the file was modified */ + LastModified: string; + /** Storage service's reported byte count */ + Size: number; + + } + + export interface GetFilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + + } + + export interface GetFilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Collection of metadata for the entity's files */ + Metadata?: { [key: string]: GetFileMetadata }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface GetObjectsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** + * Determines whether the object will be returned as an escaped JSON string or as a un-escaped JSON object. Default is JSON + * object. + */ + EscapeObject?: boolean; + + } + + export interface GetObjectsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Requested objects that the calling entity has access to */ + Objects?: { [key: string]: ObjectResult }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface InitiateFileUploadMetadata { + /** Name of the file. */ + FileName?: string; + /** Location the data should be sent to via an HTTP PUT operation. */ + UploadUrl?: string; + + } + + export interface InitiateFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be set. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetFiles API or other APIs, you can ensure that the file upload initiation is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface InitiateFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** Collection of file names and upload urls */ + UploadDetails?: InitiateFileUploadMetadata[]; + + } + + export interface ObjectResult { + /** Un-escaped JSON object, if EscapeObject false or default. */ + DataObject?: any; + /** Escaped string JSON body of the object, if EscapeObject is true. */ + EscapedDataObject?: string; + /** Name of the object. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + ObjectName?: string; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface SetObject { + /** + * Body of the object to be saved. If empty and DeleteObject is true object will be deleted if it exists, or no operation + * will occur if it does not exist. Only one of Object or EscapedDataObject fields may be used. + */ + DataObject?: any; + /** Flag to indicate that this object should be deleted. Both DataObject and EscapedDataObject must not be set as well. */ + DeleteObject?: boolean; + /** + * Body of the object to be saved as an escaped JSON string. If empty and DeleteObject is true object will be deleted if it + * exists, or no operation will occur if it does not exist. Only one of DataObject or EscapedDataObject fields may be used. + */ + EscapedDataObject?: string; + /** Name of object. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + ObjectName: string; + + } + + export interface SetObjectInfo { + /** Name of the object */ + ObjectName?: string; + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + export interface SetObjectsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetObjects API or other APIs, you can ensure that the object update is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ExpectedProfileVersion?: number; + /** Collection of objects to set on the profile. */ + Objects: SetObject[]; + + } + + export interface SetObjectsResponse extends PlayFabModule.IPlayFabResultCommon { + /** New version of the entity profile. */ + ProfileVersion: number; + /** New version of the entity profile. */ + SetResults?: SetObjectInfo[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabEconomyApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabEconomyApi.d.ts new file mode 100644 index 00000000..733020c5 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabEconomyApi.d.ts @@ -0,0 +1,2494 @@ +/// + +declare module PlayFabEconomyModule { + export interface IPlayFabEconomy { + ForgetAllCredentials(): void; + + /** + * Add inventory items. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is uncapped. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/addinventoryitems + */ + AddInventoryItems(request: PlayFabEconomyModels.AddInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new item in the working catalog using provided metadata. Note: SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/createdraftitem + */ + CreateDraftItem(request: PlayFabEconomyModels.CreateDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates one or more upload URLs which can be used by the client to upload raw file data. Content URls and uploaded + * content will be garbage collected after 24 hours if not attached to a draft or published item. Detailed pricing info + * around uploading content can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/pricing/meters/catalog-meters + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/createuploadurls + */ + CreateUploadUrls(request: PlayFabEconomyModels.CreateUploadUrlsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes all reviews, helpfulness votes, and ratings submitted by the entity specified. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/deleteentityitemreviews + */ + DeleteEntityItemReviews(request: PlayFabEconomyModels.DeleteEntityItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete an Inventory Collection. More information about Inventory Collections can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/inventory/collections + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/deleteinventorycollection + */ + DeleteInventoryCollection(request: PlayFabEconomyModels.DeleteInventoryCollectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete inventory items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/deleteinventoryitems + */ + DeleteInventoryItems(request: PlayFabEconomyModels.DeleteInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an item from working catalog and all published versions from the public catalog. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/deleteitem + */ + DeleteItem(request: PlayFabEconomyModels.DeleteItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Execute a list of Inventory Operations. A maximum list of 50 operations can be performed by a single request. There is + * also a limit to 300 items that can be modified/added in a single request. For example, adding a bundle with 50 items + * counts as 50 items modified. All operations must be done within a single inventory collection. This API has a reduced + * RPS compared to an individual inventory operation with Player Entities limited to 60 requests in 90 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/executeinventoryoperations + */ + ExecuteInventoryOperations(request: PlayFabEconomyModels.ExecuteInventoryOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Transfer a list of inventory items. A maximum list of 50 operations can be performed by a single request. When the + * response code is 202, one or more operations did not complete within the timeframe of the request. You can identify the + * pending operations by looking for OperationStatus = 'InProgress'. You can check on the operation status at anytime + * within 1 day of the request by passing the TransactionToken to the GetInventoryOperationStatus API. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/executetransferoperations + */ + ExecuteTransferOperations(request: PlayFabEconomyModels.ExecuteTransferOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the configuration for the catalog. Only Title Entities can call this API. There is a limit of 100 requests in 10 + * seconds for this API. More information about the Catalog Config can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/settings + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getcatalogconfig + */ + GetCatalogConfig(request: PlayFabEconomyModels.GetCatalogConfigRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves an item from the working catalog. This item represents the current working state of the item. GetDraftItem + * does not work off a cache of the Catalog and should be used when trying to get recent item updates. However, please note + * that item references data is cached and may take a few moments for changes to propagate. Note: SAS tokens provided are + * valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getdraftitem + */ + GetDraftItem(request: PlayFabEconomyModels.GetDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a paginated list of the items from the draft catalog. Up to 50 IDs can be retrieved in a single request. + * GetDraftItems does not work off a cache of the Catalog and should be used when trying to get recent item updates. Note: + * SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getdraftitems + */ + GetDraftItems(request: PlayFabEconomyModels.GetDraftItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a paginated list of the items from the draft catalog created by the Entity. Up to 50 items can be returned at + * once. You can use continuation tokens to paginate through results that return greater than the limit. + * GetEntityDraftItems does not work off a cache of the Catalog and should be used when trying to get recent item updates. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getentitydraftitems + */ + GetEntityDraftItems(request: PlayFabEconomyModels.GetEntityDraftItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the submitted review for the specified item by the authenticated entity. Individual ratings and reviews data update + * in near real time with delays within a few seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getentityitemreview + */ + GetEntityItemReview(request: PlayFabEconomyModels.GetEntityItemReviewRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get Inventory Collection Ids. Up to 50 Ids can be returned at once (or 250 with response compression enabled). You can + * use continuation tokens to paginate through results that return greater than the limit. It can take a few seconds for + * new collection Ids to show up. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventorycollectionids + */ + GetInventoryCollectionIds(request: PlayFabEconomyModels.GetInventoryCollectionIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get current inventory items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventoryitems + */ + GetInventoryItems(request: PlayFabEconomyModels.GetInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the status of an inventory operation using an OperationToken. You can check on the operation status at anytime + * within 1 day of the request by passing the TransactionToken to the this API. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventoryoperationstatus + */ + GetInventoryOperationStatus(request: PlayFabEconomyModels.GetInventoryOperationStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves an item from the public catalog. GetItem does not work off a cache of the Catalog and should be used when + * trying to get recent item updates. However, please note that item references data is cached and may take a few moments + * for changes to propagate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitem + */ + GetItem(request: PlayFabEconomyModels.GetItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Search for a given item and return a set of bundles and stores containing the item. Up to 50 items can be returned at + * once. You can use continuation tokens to paginate through results that return greater than the limit. This API is + * intended for tooling/automation scenarios and has a reduced RPS with Player Entities limited to 30 requests in 300 + * seconds and Title Entities limited to 100 requests in 10 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemcontainers + */ + GetItemContainers(request: PlayFabEconomyModels.GetItemContainersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the moderation state for an item, including the concern category and string reason. More information about + * moderation states can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/ugc/moderation + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemmoderationstate + */ + GetItemModerationState(request: PlayFabEconomyModels.GetItemModerationStateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of a publish of an item. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitempublishstatus + */ + GetItemPublishStatus(request: PlayFabEconomyModels.GetItemPublishStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a paginated set of reviews associated with the specified item. Individual ratings and reviews data update in near + * real time with delays within a few seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemreviews + */ + GetItemReviews(request: PlayFabEconomyModels.GetItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a summary of all ratings and reviews associated with the specified item. Summary ratings data is cached with update + * data coming within 15 minutes. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemreviewsummary + */ + GetItemReviewSummary(request: PlayFabEconomyModels.GetItemReviewSummaryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves items from the public catalog. Up to 50 items can be returned at once. GetItems does not work off a cache of + * the Catalog and should be used when trying to get recent item updates. However, please note that item references data is + * cached and may take a few moments for changes to propagate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitems + */ + GetItems(request: PlayFabEconomyModels.GetItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get transaction history for a player. Up to 50 Events can be returned at once (or 250 with response compression + * enabled). You can use continuation tokens to paginate through results that return greater than the limit. Getting + * transaction history has a lower RPS limit than getting a Player's inventory with Player Entities having a limit of 30 + * requests in 300 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/gettransactionhistory + */ + GetTransactionHistory(request: PlayFabEconomyModels.GetTransactionHistoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Initiates a publish of an item from the working catalog to the public catalog. You can use the GetItemPublishStatus API + * to track the state of the item publish. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/publishdraftitem + */ + PublishDraftItem(request: PlayFabEconomyModels.PublishDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Purchase an item or bundle. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is + * uncapped. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/purchaseinventoryitems + */ + PurchaseInventoryItems(request: PlayFabEconomyModels.PurchaseInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemappleappstoreinventoryitems + */ + RedeemAppleAppStoreInventoryItems(request: PlayFabEconomyModels.RedeemAppleAppStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemappleappstorewithjwsinventoryitems + */ + RedeemAppleAppStoreWithJwsInventoryItems(request: PlayFabEconomyModels.RedeemAppleAppStoreWithJwsInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemgoogleplayinventoryitems + */ + RedeemGooglePlayInventoryItems(request: PlayFabEconomyModels.RedeemGooglePlayInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items from the Microsoft Store. Supported entitlement types are Developer Manager Consumable and Durable. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemmicrosoftstoreinventoryitems + */ + RedeemMicrosoftStoreInventoryItems(request: PlayFabEconomyModels.RedeemMicrosoftStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemnintendoeshopinventoryitems + */ + RedeemNintendoEShopInventoryItems(request: PlayFabEconomyModels.RedeemNintendoEShopInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemplaystationstoreinventoryitems + */ + RedeemPlayStationStoreInventoryItems(request: PlayFabEconomyModels.RedeemPlayStationStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemsteaminventoryitems + */ + RedeemSteamInventoryItems(request: PlayFabEconomyModels.RedeemSteamInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a report for an item, indicating in what way the item is inappropriate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reportitem + */ + ReportItem(request: PlayFabEconomyModels.ReportItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a report for a review + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reportitemreview + */ + ReportItemReview(request: PlayFabEconomyModels.ReportItemReviewRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates or updates a review for the specified item. More information around the caching surrounding item ratings and + * reviews can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/ratings#ratings-design-and-caching + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reviewitem + */ + ReviewItem(request: PlayFabEconomyModels.ReviewItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Executes a search against the public catalog using the provided search parameters and returns a set of paginated + * results. SearchItems uses a cache of the catalog with item updates taking up to a few minutes to propagate. You should + * use the GetItem API for when trying to immediately get recent item updates. More information about the Search API can be + * found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/searchitems + */ + SearchItems(request: PlayFabEconomyModels.SearchItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the moderation state for an item, including the concern category and string reason. More information about + * moderation states can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/ugc/moderation + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/setitemmoderationstate + */ + SetItemModerationState(request: PlayFabEconomyModels.SetItemModerationStateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a vote for a review, indicating whether the review was helpful or unhelpful. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/submititemreviewvote + */ + SubmitItemReviewVote(request: PlayFabEconomyModels.SubmitItemReviewVoteRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subtract inventory items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/subtractinventoryitems + */ + SubtractInventoryItems(request: PlayFabEconomyModels.SubtractInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a request to takedown one or more reviews. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/takedownitemreviews + */ + TakedownItemReviews(request: PlayFabEconomyModels.TakedownItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Transfer inventory items. When transferring across collections, a 202 response indicates that the transfer did not + * complete within the timeframe of the request. You can identify the pending operations by looking for OperationStatus = + * 'InProgress'. You can check on the operation status at anytime within 1 day of the request by passing the + * TransactionToken to the GetInventoryOperationStatus API. More information about item transfer scenarios can be found + * here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/inventory/?tabs=inventory-game-manager#transfer-inventory-items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/transferinventoryitems + */ + TransferInventoryItems(request: PlayFabEconomyModels.TransferInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the configuration for the catalog. Only Title Entities can call this API. There is a limit of 10 requests in 10 + * seconds for this API. More information about the Catalog Config can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/settings + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/updatecatalogconfig + */ + UpdateCatalogConfig(request: PlayFabEconomyModels.UpdateCatalogConfigRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the metadata for an item in the working catalog. Note: SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/updatedraftitem + */ + UpdateDraftItem(request: PlayFabEconomyModels.UpdateDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update inventory items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/updateinventoryitems + */ + UpdateInventoryItems(request: PlayFabEconomyModels.UpdateInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabEconomyModels { + export interface AddInventoryItemsOperation { + /** The amount to add to the current item amount. */ + Amount?: number; + /** The duration to add to the current item expiration date. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + + } + + export interface AddInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to add for the current item. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The duration to add to the current item expiration date. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + + } + + export interface AddInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface AlternateId { + /** Type of the alternate ID. */ + Type?: string; + /** Value of the alternate ID. */ + Value?: string; + + } + + export interface CatalogAlternateId { + /** Type of the alternate ID. */ + Type?: string; + /** Value of the alternate ID. */ + Value?: string; + + } + + export interface CatalogConfig { + /** A list of player entity keys that will have admin permissions. There is a maximum of 64 entities that can be added. */ + AdminEntities?: EntityKey[]; + /** The set of configuration that only applies to catalog items. */ + Catalog?: CatalogSpecificConfig; + /** A list of deep link formats. Up to 10 can be added. */ + DeepLinkFormats?: DeepLinkFormat[]; + /** + * A list of display properties to index. Up to 5 mappings can be added per Display Property Type. More info on display + * properties can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/content-types-tags-and-properties#displayproperties + */ + DisplayPropertyIndexInfos?: DisplayPropertyIndexInfo[]; + /** The set of configuration that only applies to Files. */ + File?: FileConfig; + /** The set of configuration that only applies to Images. */ + Image?: ImageConfig; + /** Flag defining whether catalog is enabled. */ + IsCatalogEnabled: boolean; + /** + * A list of Platforms that can be applied to catalog items. Each platform can have a maximum character length of 40 and up + * to 128 platforms can be listed. + */ + Platforms?: string[]; + /** The set of configuration that only applies to Ratings and Reviews. */ + Review?: ReviewConfig; + /** A set of player entity keys that are allowed to review content. There is a maximum of 128 entities that can be added. */ + ReviewerEntities?: EntityKey[]; + /** The set of configuration that only applies to user generated contents. */ + UserGeneratedContent?: UserGeneratedContentSpecificConfig; + + } + + export interface CatalogItem { + /** + * The alternate IDs associated with this item. An alternate ID can be set to 'FriendlyId' or any of the supported + * marketplace names. + */ + AlternateIds?: CatalogAlternateId[]; + /** The set of content/files associated with this item. Up to 100 files can be added to an item. */ + Contents?: Content[]; + /** The client-defined type of the item. */ + ContentType?: string; + /** The date and time when this item was created. */ + CreationDate?: string; + /** The ID of the creator of this catalog item. */ + CreatorEntity?: EntityKey; + /** The set of platform specific deep links for this item. */ + DeepLinks?: DeepLink[]; + /** + * The Stack Id that will be used as default for this item in Inventory when an explicit one is not provided. This + * DefaultStackId can be a static stack id or '{guid}', which will generate a unique stack id for the item. If null, + * Inventory's default stack id will be used. + */ + DefaultStackId?: string; + /** + * A dictionary of localized descriptions. Key is language code and localized string is the value. The NEUTRAL locale is + * required. Descriptions have a 10000 character limit per country code. + */ + Description?: { [key: string]: string | null }; + /** + * Game specific properties for display purposes. This is an arbitrary JSON blob. The Display Properties field has a 10000 + * byte limit per item. + */ + DisplayProperties?: any; + /** The user provided version of the item for display purposes. Maximum character length of 50. */ + DisplayVersion?: string; + /** The date of when the item will cease to be available. If not provided then the product will be available indefinitely. */ + EndDate?: string; + /** The current ETag value that can be used for optimistic concurrency in the If-None-Match header. */ + ETag?: string; + /** The unique ID of the item. */ + Id?: string; + /** + * The images associated with this item. Images can be thumbnails or screenshots. Up to 100 images can be added to an item. + * Only .png, .jpg, .gif, and .bmp file types can be uploaded + */ + Images?: Image[]; + /** Indicates if the item is hidden. */ + IsHidden?: boolean; + /** + * The item references associated with this item. For example, the items in a Bundle/Store/Subscription. Every item can + * have up to 50 item references. + */ + ItemReferences?: CatalogItemReference[]; + /** + * A dictionary of localized keywords. Key is language code and localized list of keywords is the value. Keywords have a 50 + * character limit per keyword and up to 32 keywords can be added per country code. + */ + Keywords?: { [key: string]: KeywordSet }; + /** The date and time this item was last updated. */ + LastModifiedDate?: string; + /** The moderation state for this item. */ + Moderation?: ModerationState; + /** The platforms supported by this item. */ + Platforms?: string[]; + /** The prices the item can be purchased for. */ + PriceOptions?: CatalogPriceOptions; + /** Rating summary for this item. */ + Rating?: Rating; + /** The real price the item was purchased for per marketplace. */ + RealMoneyPriceDetails?: RealMoneyPriceDetails; + /** The date of when the item will be available. If not provided then the product will appear immediately. */ + StartDate?: string; + /** Optional details for stores items. */ + StoreDetails?: StoreDetails; + /** The list of tags that are associated with this item. Up to 32 tags can be added to an item. */ + Tags?: string[]; + /** + * A dictionary of localized titles. Key is language code and localized string is the value. The NEUTRAL locale is + * required. Titles have a 512 character limit per country code. + */ + Title?: { [key: string]: string | null }; + /** + * The high-level type of the item. The following item types are supported: bundle, catalogItem, currency, store, ugc, + * subscription. + */ + Type?: string; + + } + + export interface CatalogItemReference { + /** The amount of the catalog item. */ + Amount?: number; + /** The unique ID of the catalog item. */ + Id?: string; + /** The prices the catalog item can be purchased for. */ + PriceOptions?: CatalogPriceOptions; + + } + + export interface CatalogPrice { + /** The amounts of the catalog item price. Each price can have up to 15 item amounts. */ + Amounts?: CatalogPriceAmount[]; + /** The per-unit amount this price can be used to purchase. */ + UnitAmount?: number; + /** The per-unit duration this price can be used to purchase. The maximum duration is 100 years. */ + UnitDurationInSeconds?: number; + + } + + export interface CatalogPriceAmount { + /** The amount of the price. */ + Amount: number; + /** The Item Id of the price. */ + ItemId?: string; + + } + + export interface CatalogPriceAmountOverride { + /** The exact value that should be utilized in the override. */ + FixedValue?: number; + /** The id of the item this override should utilize. */ + ItemId?: string; + /** + * The multiplier that will be applied to the base Catalog value to determine what value should be utilized in the + * override. + */ + Multiplier?: number; + + } + + export interface CatalogPriceOptions { + /** Prices of the catalog item. An item can have up to 15 prices */ + Prices?: CatalogPrice[]; + + } + + export interface CatalogPriceOptionsOverride { + /** The prices utilized in the override. */ + Prices?: CatalogPriceOverride[]; + + } + + export interface CatalogPriceOverride { + /** The currency amounts utilized in the override for a singular price. */ + Amounts?: CatalogPriceAmountOverride[]; + + } + + export interface CatalogSpecificConfig { + /** + * The set of content types that will be used for validation. Each content type can have a maximum character length of 40 + * and up to 128 types can be listed. + */ + ContentTypes?: string[]; + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface CategoryRatingConfig { + /** Name of the category. */ + Name?: string; + + } + + type ConcernCategory = "None" + + | "OffensiveContent" + | "ChildExploitation" + | "MalwareOrVirus" + | "PrivacyConcerns" + | "MisleadingApp" + | "PoorPerformance" + | "ReviewResponse" + | "SpamAdvertising" + | "Profanity"; + + export interface Content { + /** The content unique ID. */ + Id?: string; + /** + * The maximum client version that this content is compatible with. Client Versions can be up to 3 segments separated by + * periods(.) and each segment can have a maximum value of 65535. + */ + MaxClientVersion?: string; + /** + * The minimum client version that this content is compatible with. Client Versions can be up to 3 segments separated by + * periods(.) and each segment can have a maximum value of 65535. + */ + MinClientVersion?: string; + /** + * The list of tags that are associated with this content. Tags must be defined in the Catalog Config before being used in + * content. + */ + Tags?: string[]; + /** The client-defined type of the content. Content Types must be defined in the Catalog Config before being used. */ + Type?: string; + /** The Azure CDN URL for retrieval of the catalog item binary content. */ + Url?: string; + + } + + type CountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW" + | "Unknown"; + + export interface CreateDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Metadata describing the new catalog item to be created. */ + Item?: CatalogItem; + /** Whether the item should be published immediately. This value is optional, defaults to false. */ + Publish: boolean; + + } + + export interface CreateDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Updated metadata describing the catalog item just created. */ + Item?: CatalogItem; + + } + + export interface CreateUploadUrlsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the files to be uploaded by the client. */ + Files?: UploadInfo[]; + + } + + export interface CreateUploadUrlsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of URLs metadata for the files to be uploaded by the client. */ + UploadUrls?: UploadUrlMetadata[]; + + } + + export interface DeepLink { + /** Target platform for this deep link. */ + Platform?: string; + /** The deep link for this platform. */ + Url?: string; + + } + + export interface DeepLinkFormat { + /** The format of the deep link to return. The format should contain '{id}' to represent where the item ID should be placed. */ + Format?: string; + /** The target platform for the deep link. */ + Platform?: string; + + } + + export interface DeleteEntityItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + + } + + export interface DeleteEntityItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteInventoryCollectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The inventory collection id the request applies to. */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity the request is about. Set to the caller by default. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + + } + + export interface DeleteInventoryCollectionResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteInventoryItemsOperation { + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + + } + + export interface DeleteInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + + } + + export interface DeleteInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** ETags are used for concurrency checking when updating resources. */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface DeleteItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface DeleteItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DisplayPropertyIndexInfo { + /** The property name in the 'DisplayProperties' property to be indexed. */ + Name?: string; + /** The type of the property to be indexed. */ + Type?: string; + + } + + type DisplayPropertyType = "None" + + | "QueryDateTime" + | "QueryDouble" + | "QueryString" + | "SearchString"; + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface ExecuteInventoryOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** + * The operations to run transactionally. The operations will be executed in-order sequentially and will succeed or fail as + * a batch. Up to 50 operations can be added. + */ + Operations?: InventoryOperation[]; + + } + + export interface ExecuteInventoryOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of the transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface ExecuteTransferOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The inventory collection id the request is transferring from. (Default="default") */ + GivingCollectionId?: string; + /** The entity the request is transferring from. Set to the caller by default. */ + GivingEntity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** + * The transfer operations to run transactionally. The operations will be executed in-order sequentially and will succeed + * or fail as a batch. Up to 50 operations can be added. + */ + Operations?: TransferInventoryItemsOperation[]; + /** The inventory collection id the request is transferring to. (Default="default") */ + ReceivingCollectionId?: string; + /** The entity the request is transferring to. Set to the caller by default. */ + ReceivingEntity?: EntityKey; + + } + + export interface ExecuteTransferOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources (before transferring from). This value will be empty if + * the operation has not completed yet. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The ids of transactions that occurred as a result of the request's giving action. */ + GivingTransactionIds?: string[]; + /** The Idempotency ID for this request. */ + IdempotencyId?: string; + /** + * The transfer operation status. Possible values are 'InProgress' or 'Completed'. If the operation has completed, the + * response code will be 200. Otherwise, it will be 202. + */ + OperationStatus?: string; + /** + * The token that can be used to get the status of the transfer operation. This will only have a value if OperationStatus + * is 'InProgress'. + */ + OperationToken?: string; + /** + * ETags are used for concurrency checking when updating resources (before transferring to). This value will be empty if + * the operation has not completed yet. + */ + ReceivingETag?: string; + /** The ids of transactions that occurred as a result of the request's receiving action. */ + ReceivingTransactionIds?: string[]; + + } + + export interface FileConfig { + /** + * The set of content types that will be used for validation. Each content type can have a maximum character length of 40 + * and up to 128 types can be listed. + */ + ContentTypes?: string[]; + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface FilterOptions { + /** + * The OData filter utilized. Mutually exclusive with 'IncludeAllItems'. More info about Filter Complexity limits can be + * found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search#limits + */ + Filter?: string; + /** The flag that overrides the filter and allows for returning all catalog items. Mutually exclusive with 'Filter'. */ + IncludeAllItems?: boolean; + + } + + export interface GetCatalogConfigRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetCatalogConfigResponse extends PlayFabModule.IPlayFabResultCommon { + /** The catalog configuration. */ + Config?: CatalogConfig; + + } + + export interface GetDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Full metadata of the catalog item requested. */ + Item?: CatalogItem; + + } + + export interface GetDraftItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** List of item alternate IDs. */ + AlternateIds?: CatalogAlternateId[]; + /** + * An opaque token used to retrieve the next page of items created by the caller, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count?: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** List of Item Ids. */ + Ids?: string[]; + + } + + export interface GetDraftItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** A set of items created by the entity. */ + Items?: CatalogItem[]; + + } + + export interface GetEntityDraftItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * An opaque token used to retrieve the next page of items created by the caller, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * OData Filter to refine the items returned. CatalogItem properties 'type' can be used in the filter. For example: "type + * eq 'ugc'" + */ + Filter?: string; + + } + + export interface GetEntityDraftItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** A set of items created by the entity. */ + Items?: CatalogItem[]; + + } + + export interface GetEntityItemReviewRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetEntityItemReviewResponse extends PlayFabModule.IPlayFabResultCommon { + /** The review the entity submitted for the requested item. */ + Review?: Review; + + } + + export interface GetInventoryCollectionIdsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An opaque token used to retrieve the next page of collection ids, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. The default value is 10 */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity the request is about. Set to the caller by default. */ + Entity?: EntityKey; + + } + + export interface GetInventoryCollectionIdsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested inventory collection ids. */ + CollectionIds?: string[]; + /** An opaque token used to retrieve the next page of collection ids, if any are available. */ + ContinuationToken?: string; + + } + + export interface GetInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** + * An opaque token used to retrieve the next page of items in the inventory, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Maximum page size is 50. The default value is 10 */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * OData Filter to refine the items returned. InventoryItem properties 'type', 'id', and 'stackId' can be used in the + * filter. For example: "type eq 'currency'" + */ + Filter?: string; + + } + + export interface GetInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The requested inventory items. */ + Items?: InventoryItem[]; + + } + + export interface GetInventoryOperationStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The token to get the status of the inventory operation. */ + OperationToken?: string; + + } + + export interface GetInventoryOperationStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** The inventory operation status. */ + OperationStatus?: string; + + } + + export interface GetItemContainersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** + * An opaque token used to retrieve the next page of items in the inventory, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemContainersResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of Bundles and Stores containing the requested items. */ + Containers?: CatalogItem[]; + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + + } + + export interface GetItemModerationStateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemModerationStateResponse extends PlayFabModule.IPlayFabResultCommon { + /** The current moderation state for the requested item. */ + State?: ModerationState; + + } + + export interface GetItemPublishStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemPublishStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** High level status of the published item. */ + Result?: string; + /** Descriptive message about the current status of the publish. */ + StatusMessage?: string; + + } + + export interface GetItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** The item result. */ + Item?: CatalogItem; + + } + + export interface GetItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + /** + * An OData orderBy used to order the results of the query. Possible values are Helpfulness, Rating, and Submitted (For + * example: "Submitted desc") + */ + OrderBy?: string; + + } + + export interface GetItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** The paginated set of results. */ + Reviews?: Review[]; + + } + + export interface GetItemReviewSummaryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemReviewSummaryResponse extends PlayFabModule.IPlayFabResultCommon { + /** The least favorable review for this item. */ + LeastFavorableReview?: Review; + /** The most favorable review for this item. */ + MostFavorableReview?: Review; + /** The summary of ratings associated with this item. */ + Rating?: Rating; + /** The total number of reviews associated with this item. */ + ReviewsCount: number; + + } + + export interface GetItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** List of item alternate IDs. */ + AlternateIds?: CatalogAlternateId[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** List of Item Ids. */ + Ids?: string[]; + + } + + export interface GetItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Metadata of set of items. */ + Items?: CatalogItem[]; + + } + + export interface GetTransactionHistoryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** An opaque token used to retrieve the next page of items, if any are available. Should be null on initial request. */ + ContinuationToken?: string; + /** + * Number of items to retrieve. This value is optional. The default value is 10. The maximum value is 50, or 250 if + * response compression is enabled. + */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * An OData filter used to refine the TransactionHistory. Transaction properties 'timestamp', 'transactionid', 'apiname' + * and 'operationtype' can be used in the filter. Properties 'transactionid', 'apiname', and 'operationtype' cannot be used + * together in a single request. The 'timestamp' property can be combined with 'apiname' or 'operationtype' in a single + * request. For example: "timestamp ge 2023-06-20T23:30Z" or "transactionid eq '10'" or "(timestamp ge 2023-06-20T23:30Z) + * and (apiname eq 'AddInventoryItems')". By default, a 6 month timespan from the current date is used. + */ + Filter?: string; + /** + * An OData orderby to order TransactionHistory results. The only supported values are 'timestamp asc' or 'timestamp desc'. + * Default orderby is 'timestamp asc' + */ + OrderBy?: string; + + } + + export interface GetTransactionHistoryResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. Should be null on initial request. */ + ContinuationToken?: string; + /** The requested inventory transactions. */ + Transactions?: Transaction[]; + + } + + export interface GooglePlayProductPurchase { + /** The Product ID (SKU) of the InApp product purchased from the Google Play store. */ + ProductId?: string; + /** The token provided to the player's device when the product was purchased */ + Token?: string; + + } + + type HelpfulnessVote = "None" + + | "UnHelpful" + | "Helpful"; + + export interface Image { + /** The image unique ID. */ + Id?: string; + /** + * The client-defined tag associated with this image. Tags must be defined in the Catalog Config before being used in + * images + */ + Tag?: string; + /** Images can be defined as either a "thumbnail" or "screenshot". There can only be one "thumbnail" image per item. */ + Type?: string; + /** The URL for retrieval of the image. */ + Url?: string; + + } + + export interface ImageConfig { + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface InitialValues { + /** Game specific properties for display purposes. The Display Properties field has a 1000 byte limit. */ + DisplayProperties?: any; + + } + + export interface InventoryItem { + /** The amount of the item. */ + Amount?: number; + /** + * Game specific properties for display purposes. This is an arbitrary JSON blob. The Display Properties field has a 1000 + * byte limit. + */ + DisplayProperties?: any; + /** Only used for subscriptions. The date of when the item will expire in UTC. */ + ExpirationDate?: string; + /** The id of the item. This should correspond to the item id in the catalog. */ + Id?: string; + /** The stack id of the item. */ + StackId?: string; + /** Only used for subscriptions. The date of when the item started in UTC. */ + StartDate?: string; + /** The type of the item. This should correspond to the item type in the catalog. */ + Type?: string; + + } + + export interface InventoryItemReference { + /** The inventory item alternate id the request applies to. */ + AlternateId?: AlternateId; + /** The inventory item id the request applies to. */ + Id?: string; + /** The inventory stack id the request should redeem to. (Default="default") */ + StackId?: string; + + } + + export interface InventoryOperation { + /** The add operation. */ + Add?: AddInventoryItemsOperation; + /** The delete operation. */ + Delete?: DeleteInventoryItemsOperation; + /** The purchase operation. */ + Purchase?: PurchaseInventoryItemsOperation; + /** The subtract operation. */ + Subtract?: SubtractInventoryItemsOperation; + /** The transfer operation. */ + Transfer?: TransferInventoryItemsOperation; + /** The update operation. */ + Update?: UpdateInventoryItemsOperation; + + } + + export interface KeywordSet { + /** A list of localized keywords. */ + Values?: string[]; + + } + + export interface ModerationState { + /** The date and time this moderation state was last updated. */ + LastModifiedDate?: string; + /** The current stated reason for the associated item being moderated. */ + Reason?: string; + /** The current moderation status for the associated item. */ + Status?: string; + + } + + type ModerationStatus = "Unknown" + + | "AwaitingModeration" + | "Approved" + | "Rejected"; + + export interface Permissions { + /** + * The list of ids of Segments that the a player can be in to purchase from the store. When a value is provided, the player + * must be in at least one of the segments listed for the purchase to be allowed. + */ + SegmentIds?: string[]; + + } + + export interface PublishDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETag of the catalog item to published from the working catalog to the public catalog. Used for optimistic concurrency. + * If the provided ETag does not match the ETag in the current working catalog, the request will be rejected. If not + * provided, the current version of the document in the working catalog will be published. + */ + ETag?: string; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface PublishDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + type PublishResult = "Unknown" + + | "Pending" + | "Succeeded" + | "Failed" + | "Canceled"; + + export interface PurchaseInventoryItemsOperation { + /** The amount to purchase. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the operation should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The duration to purchase. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + /** + * The per-item price the item is expected to be purchased at. This must match a value configured in the Catalog or + * specified Store. + */ + PriceAmounts?: PurchasePriceAmount[]; + /** The id of the Store to purchase the item from. */ + StoreId?: string; + + } + + export interface PurchaseInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to purchase. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. + * (Default=false) + */ + DeleteEmptyStacks: boolean; + /** The duration to purchase. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + /** + * The per-item price the item is expected to be purchased at. This must match a value configured in the Catalog or + * specified Store. + */ + PriceAmounts?: PurchasePriceAmount[]; + /** The id of the Store to purchase the item from. */ + StoreId?: string; + + } + + export interface PurchaseInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface PurchaseOverride { + + } + + export interface PurchaseOverridesInfo { + + } + + export interface PurchasePriceAmount { + /** The amount of the inventory item to use in the purchase . */ + Amount: number; + /** The inventory item id to use in the purchase . */ + ItemId?: string; + /** The inventory stack id the to use in the purchase. Set to "default" by default */ + StackId?: string; + + } + + export interface Rating { + /** The average rating for this item. */ + Average?: number; + /** The total count of 1 star ratings for this item. */ + Count1Star?: number; + /** The total count of 2 star ratings for this item. */ + Count2Star?: number; + /** The total count of 3 star ratings for this item. */ + Count3Star?: number; + /** The total count of 4 star ratings for this item. */ + Count4Star?: number; + /** The total count of 5 star ratings for this item. */ + Count5Star?: number; + /** The total count of ratings for this item. */ + TotalCount?: number; + + } + + export interface RealMoneyPriceDetails { + /** The 'AppleAppStore' price amount per CurrencyCode. 'USD' supported only. */ + AppleAppStorePrices?: { [key: string]: number }; + /** The 'GooglePlay' price amount per CurrencyCode. 'USD' supported only. */ + GooglePlayPrices?: { [key: string]: number }; + /** The 'MicrosoftStore' price amount per CurrencyCode. 'USD' supported only. */ + MicrosoftStorePrices?: { [key: string]: number }; + /** The 'NintendoEShop' price amount per CurrencyCode. 'USD' supported only. */ + NintendoEShopPrices?: { [key: string]: number }; + /** The 'PlayStationStore' price amount per CurrencyCode. 'USD' supported only. */ + PlayStationStorePrices?: { [key: string]: number }; + /** The 'Steam' price amount per CurrencyCode. 'USD' supported only. */ + SteamPrices?: { [key: string]: number }; + + } + + export interface RedeemAppleAppStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The receipt provided by the Apple marketplace upon successful purchase. */ + Receipt?: string; + + } + + export interface RedeemAppleAppStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemAppleAppStoreWithJwsInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The JWS representation of a transaction. */ + JWSTransactions: string[]; + + } + + export interface RedeemAppleAppStoreWithJwsInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemGooglePlayInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The list of purchases to redeem */ + Purchases?: GooglePlayProductPurchase[]; + + } + + export interface RedeemGooglePlayInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemMicrosoftStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * Xbox Token used for delegated business partner authentication. Token provided by the Xbox Live SDK method + * GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). + */ + XboxToken?: string; + + } + + export interface RedeemMicrosoftStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemNintendoEShopInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The Nintendo provided token authorizing redemption */ + NintendoServiceAccountIdToken?: string; + + } + + export interface RedeemNintendoEShopInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemPlayStationStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code returned by PlayStation :tm: Network OAuth system. */ + AuthorizationCode?: string; + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code. */ + RedirectUri?: string; + /** Optional Service Label to pass into the request. */ + ServiceLabel?: string; + + } + + export interface RedeemPlayStationStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemSteamInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + + } + + export interface RedeemSteamInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedemptionFailure { + /** The marketplace failure code. */ + FailureCode?: string; + /** The marketplace error details explaining why the offer failed to redeem. */ + FailureDetails?: string; + /** The Marketplace Alternate ID being redeemed. */ + MarketplaceAlternateId?: string; + /** The transaction id in the external marketplace. */ + MarketplaceTransactionId?: string; + + } + + export interface RedemptionSuccess { + /** The timestamp for when the redeem expired. */ + ExpirationTimestamp?: string; + /** The Marketplace Alternate ID being redeemed. */ + MarketplaceAlternateId?: string; + /** The transaction id in the external marketplace. */ + MarketplaceTransactionId?: string; + /** The timestamp for when the redeem was completed. */ + SuccessTimestamp: string; + + } + + export interface ReportItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** Category of concern for this report. */ + ConcernCategory?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + /** The string reason for this report. */ + Reason?: string; + + } + + export interface ReportItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ReportItemReviewRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID of the item associated with the review. */ + AlternateId?: CatalogAlternateId; + /** The reason this review is being reported. */ + ConcernCategory?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The string ID of the item associated with the review. */ + ItemId?: string; + /** The string reason for this report. */ + Reason?: string; + /** The ID of the review to submit a report for. */ + ReviewId?: string; + + } + + export interface ReportItemReviewResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Review { + /** The star rating associated with each selected category in this review. */ + CategoryRatings?: { [key: string]: number }; + /** The number of negative helpfulness votes for this review. */ + HelpfulNegative: number; + /** The number of positive helpfulness votes for this review. */ + HelpfulPositive: number; + /** Indicates whether the review author has the item installed. */ + IsInstalled: boolean; + /** The ID of the item being reviewed. */ + ItemId?: string; + /** The version of the item being reviewed. */ + ItemVersion?: string; + /** The locale for which this review was submitted in. */ + Locale?: string; + /** Star rating associated with this review. */ + Rating: number; + /** The ID of the author of the review. */ + ReviewerEntity?: EntityKey; + /** The ID of the review. */ + ReviewId?: string; + /** The full text of this review. */ + ReviewText?: string; + /** The date and time this review was last submitted. */ + Submitted: string; + /** The title of this review. */ + Title?: string; + + } + + export interface ReviewConfig { + /** A set of categories that can be applied toward ratings and reviews. */ + CategoryRatings?: CategoryRatingConfig[]; + + } + + export interface ReviewItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + /** The review to submit. */ + Review?: Review; + + } + + export interface ReviewItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ReviewTakedown { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The ID of the item associated with the review to take down. */ + ItemId?: string; + /** The ID of the review to take down. */ + ReviewId?: string; + + } + + export interface SearchItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Maximum page size is 50. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * An OData filter used to refine the search query (For example: "type eq 'ugc'"). More info about Filter Complexity limits + * can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search#limits + */ + Filter?: string; + /** The locale to be returned in the result. */ + Language?: string; + /** An OData orderBy used to order the results of the search query. For example: "rating/average asc" */ + OrderBy?: string; + /** The text to search for. */ + Search?: string; + /** + * An OData select query option used to augment the search results. If not defined, the default search result metadata will + * be returned. + */ + Select?: string; + /** The store to restrict the search request to. */ + Store?: StoreReference; + + } + + export interface SearchItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** The paginated set of results for the search query. */ + Items?: CatalogItem[]; + + } + + export interface SetItemModerationStateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + /** The reason for the moderation state change for the associated item. */ + Reason?: string; + /** The status to set for the associated item. */ + Status?: string; + + } + + export interface SetItemModerationStateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface StoreDetails { + /** The options for the filter in filter-based stores. These options are mutually exclusive with item references. */ + FilterOptions?: FilterOptions; + /** The permissions that control which players can purchase from the store. */ + Permissions?: Permissions; + /** The global prices utilized in the store. These options are mutually exclusive with price options in item references. */ + PriceOptionsOverride?: CatalogPriceOptionsOverride; + + } + + export interface StoreReference { + /** An alternate ID of the store. */ + AlternateId?: CatalogAlternateId; + /** The unique ID of the store. */ + Id?: string; + + } + + export interface SubmitItemReviewVoteRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID of the item associated with the review. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The string ID of the item associated with the review. */ + ItemId?: string; + /** The ID of the review to submit a helpfulness vote for. */ + ReviewId?: string; + /** The helpfulness vote of the review. */ + Vote?: string; + + } + + export interface SubmitItemReviewVoteResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SubtractInventoryItemsOperation { + /** The amount to subtract from the current item amount. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. (Default = + * false). + */ + DeleteEmptyStacks: boolean; + /** The duration to subtract from the current item expiration date. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + + } + + export interface SubtractInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to subtract for the current item. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. + * (Default=false) + */ + DeleteEmptyStacks: boolean; + /** The duration to subtract from the current item expiration date. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + + } + + export interface SubtractInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface TakedownItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The set of reviews to take down. */ + Reviews?: ReviewTakedown[]; + + } + + export interface TakedownItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Transaction { + /** The API call that caused this transaction. */ + ApiName?: string; + /** Additional details about the transaction. Null if it was not a clawback operation. */ + ClawbackDetails?: TransactionClawbackDetails; + /** The custom tags associated with this transactions. */ + CustomTags?: { [key: string]: string | null }; + /** The type of item that the the operation occurred on. */ + ItemType?: string; + /** The operations that occurred. */ + Operations?: TransactionOperation[]; + /** The type of operation that was run. */ + OperationType?: string; + /** Additional details about the transaction. Null if it was not a purchase operation. */ + PurchaseDetails?: TransactionPurchaseDetails; + /** Additional details about the transaction. Null if it was not a redeem operation. */ + RedeemDetails?: TransactionRedeemDetails; + /** The time this transaction occurred in UTC. */ + Timestamp: string; + /** The id of the transaction. This should be treated like an opaque token. */ + TransactionId?: string; + /** Additional details about the transaction. Null if it was not a transfer operation. */ + TransferDetails?: TransactionTransferDetails; + + } + + export interface TransactionClawbackDetails { + /** The id of the clawed back operation. */ + TransactionIdClawedback?: string; + + } + + export interface TransactionOperation { + /** The amount of items in this transaction. */ + Amount?: number; + /** The duration modified in this transaction. */ + DurationInSeconds?: number; + /** The friendly id of the items in this transaction. */ + ItemFriendlyId?: string; + /** The item id of the items in this transaction. */ + ItemId?: string; + /** The type of item that the operation occurred on. */ + ItemType?: string; + /** The stack id of the items in this transaction. */ + StackId?: string; + /** The type of the operation that occurred. */ + Type?: string; + + } + + export interface TransactionPurchaseDetails { + /** The friendly id of the item that was purchased. */ + ItemFriendlyId?: string; + /** The id of the item that was purchased. */ + ItemId?: string; + /** The friendly id of the Store the item was purchased from or null. */ + StoreFriendlyId?: string; + /** The id of the Store the item was purchased from or null. */ + StoreId?: string; + + } + + export interface TransactionRedeemDetails { + /** The marketplace that the offer is being redeemed from. */ + Marketplace?: string; + /** The transaction Id returned from the marketplace. */ + MarketplaceTransactionId?: string; + /** The offer Id of the item being redeemed. */ + OfferId?: string; + + } + + export interface TransactionTransferDetails { + /** The collection id the items were transferred from or null if it was the current collection. */ + GivingCollectionId?: string; + /** The entity the items were transferred from or null if it was the current entity. */ + GivingEntity?: EntityKey; + /** The collection id the items were transferred to or null if it was the current collection. */ + ReceivingCollectionId?: string; + /** The entity the items were transferred to or null if it was the current entity. */ + ReceivingEntity?: EntityKey; + /** The id of the transfer that occurred. */ + TransferId?: string; + + } + + export interface TransferInventoryItemsOperation { + /** The amount to transfer. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the operation should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The inventory item the operation is transferring from. */ + GivingItem?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + /** The inventory item the operation is transferring to. */ + ReceivingItem?: InventoryItemReference; + + } + + export interface TransferInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to transfer . */ + Amount?: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The inventory collection id the request is transferring from. (Default="default") */ + GivingCollectionId?: string; + /** The entity the request is transferring from. Set to the caller by default. */ + GivingEntity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources (before transferring from). More information about using + * ETags can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The inventory item the request is transferring from. */ + GivingItem?: InventoryItemReference; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + /** The inventory collection id the request is transferring to. (Default="default") */ + ReceivingCollectionId?: string; + /** The entity the request is transferring to. Set to the caller by default. */ + ReceivingEntity?: EntityKey; + /** The inventory item the request is transferring to. */ + ReceivingItem?: InventoryItemReference; + + } + + export interface TransferInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources (after transferring from). More information about using + * ETags can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The ids of transactions that occurred as a result of the request's giving action. */ + GivingTransactionIds?: string[]; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** + * The transfer operation status. Possible values are 'InProgress' or 'Completed'. If the operation has completed, the + * response code will be 200. Otherwise, it will be 202. + */ + OperationStatus?: string; + /** + * The token that can be used to get the status of the transfer operation. This will only have a value if OperationStatus + * is 'InProgress'. + */ + OperationToken?: string; + /** The ids of transactions that occurred as a result of the request's receiving action. */ + ReceivingTransactionIds?: string[]; + + } + + export interface UpdateCatalogConfigRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The updated catalog configuration. */ + Config?: CatalogConfig; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateCatalogConfigResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UpdateDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Updated metadata describing the catalog item to be updated. */ + Item?: CatalogItem; + /** Whether the item should be published immediately. This value is optional, defaults to false. */ + Publish: boolean; + + } + + export interface UpdateDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Updated metadata describing the catalog item just updated. */ + Item?: CatalogItem; + + } + + export interface UpdateInventoryItemsOperation { + /** The inventory item to update with the specified values. */ + Item?: InventoryItem; + + } + + export interface UpdateInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item to update with the specified values. */ + Item?: InventoryItem; + + } + + export interface UpdateInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface UploadInfo { + /** Name of the file to be uploaded. */ + FileName?: string; + + } + + export interface UploadUrlMetadata { + /** Name of the file for which this upload URL was requested. */ + FileName?: string; + /** Unique ID for the binary content to be uploaded to the target URL. */ + Id?: string; + /** URL for the binary content to be uploaded to. */ + Url?: string; + + } + + export interface UserGeneratedContentSpecificConfig { + /** The set of content types that will be used for validation. */ + ContentTypes?: string[]; + /** The set of tags that will be used for validation. */ + Tags?: string[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabEventsApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabEventsApi.d.ts new file mode 100644 index 00000000..6bcc412f --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabEventsApi.d.ts @@ -0,0 +1,384 @@ +/// + +declare module PlayFabEventsModule { + export interface IPlayFabEvents { + ForgetAllCredentials(): void; + + /** + * Creates a new telemetry key for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/createtelemetrykey + */ + CreateTelemetryKey(request: PlayFabEventsModels.CreateTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a Data Connection from a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/deletedataconnection + */ + DeleteDataConnection(request: PlayFabEventsModels.DeleteDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a telemetry key configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/deletetelemetrykey + */ + DeleteTelemetryKey(request: PlayFabEventsModels.DeleteTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a single Data Connection associated with a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/getdataconnection + */ + GetDataConnection(request: PlayFabEventsModels.GetDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information about a telemetry key configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/gettelemetrykey + */ + GetTelemetryKey(request: PlayFabEventsModels.GetTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the list of Data Connections associated with a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/listdataconnections + */ + ListDataConnections(request: PlayFabEventsModels.ListDataConnectionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all telemetry keys configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/listtelemetrykeys + */ + ListTelemetryKeys(request: PlayFabEventsModels.ListTelemetryKeysRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates or updates a Data Connection on a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/setdataconnection + */ + SetDataConnection(request: PlayFabEventsModels.SetDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets a Data Connection for the title to either the active or deactivated state. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/setdataconnectionactive + */ + SetDataConnectionActive(request: PlayFabEventsModels.SetDataConnectionActiveRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets a telemetry key to the active or deactivated state. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/settelemetrykeyactive + */ + SetTelemetryKeyActive(request: PlayFabEventsModels.SetTelemetryKeyActiveRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Write batches of entity based events to PlayStream. The namespace of the Event must be 'custom' or start with 'custom.'. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/writeevents + */ + WriteEvents(request: PlayFabEventsModels.WriteEventsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Write batches of entity based events to as Telemetry events (bypass PlayStream). The namespace must be 'custom' or start + * with 'custom.' + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/writetelemetryevents + */ + WriteTelemetryEvents(request: PlayFabEventsModels.WriteEventsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabEventsModels { + export interface CreateTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the new key. Telemetry key names must be unique within the scope of the title. */ + KeyName: string; + + } + + export interface CreateTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details about the newly created telemetry key. */ + NewKeyDetails?: TelemetryKeyDetails; + + } + + export interface DataConnectionAzureBlobSettings { + /** Name of the storage account. */ + AccountName?: string; + /** Name of the container. */ + ContainerName?: string; + /** Azure Entra Tenant Id. */ + TenantId?: string; + + } + + export interface DataConnectionAzureDataExplorerSettings { + /** The URI of the ADX cluster. */ + ClusterUri?: string; + /** The database to write to. */ + Database?: string; + /** The table to write to. */ + Table?: string; + + } + + export interface DataConnectionDetails { + /** Settings of the data connection. */ + ConnectionSettings: DataConnectionSettings; + /** Whether or not the connection is currently active. */ + IsActive: boolean; + /** The name of the data connection. */ + Name: string; + /** Current status of the data connection, if any. */ + Status?: DataConnectionStatusDetails; + /** The type of data connection. */ + Type: string; + + } + + type DataConnectionErrorState = "OK" + + | "Error"; + + export interface DataConnectionFabricKQLSettings { + /** The URI of the Fabric cluster. */ + ClusterUri?: string; + /** The database to write to. */ + Database?: string; + /** The table to write to. */ + Table?: string; + + } + + export interface DataConnectionSettings { + /** Settings if the type of connection is AzureBlobStorage. */ + AzureBlobSettings?: DataConnectionAzureBlobSettings; + /** Settings if the type of connection is AzureDataExplorer. */ + AzureDataExplorerSettings?: DataConnectionAzureDataExplorerSettings; + /** Settings if the type of connection is FabricKQL. */ + AzureFabricKQLSettings?: DataConnectionFabricKQLSettings; + + } + + export interface DataConnectionStatusDetails { + /** The name of the error affecting the data connection, if any. */ + Error?: string; + /** A description of the error affecting the data connection, if any. This may be empty for some errors. */ + ErrorMessage?: string; + /** The most recent time of the error affecting the data connection, if any. */ + MostRecentErrorTime?: string; + /** Indicates if the connection is in a normal state or error state. */ + State?: string; + + } + + type DataConnectionType = "AzureBlobStorage" + + | "AzureDataExplorer" + | "FabricKQL"; + + export interface DeleteDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to delete. */ + Name: string; + + } + + export interface DeleteDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** Indicates whether or not the connection was deleted as part of the request. */ + WasDeleted: boolean; + + } + + export interface DeleteTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to delete. */ + KeyName: string; + + } + + export interface DeleteTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Indicates whether or not the key was deleted. If false, no key with that name existed. */ + WasKeyDeleted: boolean; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EventContents { + /** + * The optional custom tags associated with the event (e.g. build number, external trace identifiers, etc.). Before an + * event is written, this collection and the base request custom tags will be merged, but not overriden. This enables the + * caller to specify static tags and per event tags. + */ + CustomTags?: { [key: string]: string | null }; + /** Entity associated with the event. If null, the event will apply to the calling entity. */ + Entity?: EntityKey; + /** The namespace in which the event is defined. Allowed namespaces can vary by API. */ + EventNamespace: string; + /** The name of this event. */ + Name: string; + /** + * The original unique identifier associated with this event before it was posted to PlayFab. The value might differ from + * the EventId value, which is assigned when the event is received by the server. + */ + OriginalId?: string; + /** + * The time (in UTC) associated with this event when it occurred. If specified, this value is stored in the + * OriginalTimestamp property of the PlayStream event. + */ + OriginalTimestamp?: string; + /** Arbitrary data associated with the event. Only one of Payload or PayloadJSON is allowed. */ + Payload?: any; + /** + * Arbitrary data associated with the event, represented as a JSON serialized string. Only one of Payload or PayloadJSON is + * allowed. + */ + PayloadJSON?: string; + + } + + export interface GetDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to retrieve. */ + Name: string; + + } + + export interface GetDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The details of the queried Data Connection. */ + DataConnection?: DataConnectionDetails; + + } + + export interface GetTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to retrieve. */ + KeyName: string; + + } + + export interface GetTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details about the requested telemetry key. */ + KeyDetails?: TelemetryKeyDetails; + + } + + export interface ListDataConnectionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListDataConnectionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of existing Data Connections. */ + DataConnections?: DataConnectionDetails[]; + + } + + export interface ListTelemetryKeysRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListTelemetryKeysResponse extends PlayFabModule.IPlayFabResultCommon { + /** The telemetry keys configured for the title. */ + KeyDetails?: TelemetryKeyDetails[]; + + } + + export interface SetDataConnectionActiveRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to set the data connection to active (true) or deactivated (false). */ + Active: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to update. */ + Name: string; + + } + + export interface SetDataConnectionActiveResponse extends PlayFabModule.IPlayFabResultCommon { + /** The most current details about the data connection that was to be updated. */ + DataConnection?: DataConnectionDetails; + /** + * Indicates whether or not the data connection was updated. If false, the data connection was already in the desired + * state. + */ + WasUpdated: boolean; + + } + + export interface SetDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Settings of the data connection. */ + ConnectionSettings: DataConnectionSettings; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Whether or not the connection is currently active. */ + IsActive: boolean; + /** The name of the data connection to update or create. */ + Name: string; + /** The type of data connection. */ + Type: string; + + } + + export interface SetDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The details of the Data Connection to be created or updated. */ + DataConnection?: DataConnectionDetails; + + } + + export interface SetTelemetryKeyActiveRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to set the key to active (true) or deactivated (false). */ + Active: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to update. */ + KeyName: string; + + } + + export interface SetTelemetryKeyActiveResponse extends PlayFabModule.IPlayFabResultCommon { + /** The most current details about the telemetry key that was to be updated. */ + KeyDetails?: TelemetryKeyDetails; + /** Indicates whether or not the key was updated. If false, the key was already in the desired state. */ + WasKeyUpdated: boolean; + + } + + export interface TelemetryKeyDetails { + /** When the key was created. */ + CreateTime: string; + /** Whether or not the key is currently active. Deactivated keys cannot be used for telemetry ingestion. */ + IsActive: boolean; + /** The key that can be distributed to clients for use during telemetry ingestion. */ + KeyValue?: string; + /** When the key was last updated. */ + LastUpdateTime: string; + /** The name of the key. Telemetry key names are unique within the scope of the title. */ + Name?: string; + + } + + export interface WriteEventsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The collection of events to write. Up to 200 events can be written per request. */ + Events: EventContents[]; + + } + + export interface WriteEventsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The unique identifiers assigned by the server to the events, in the same order as the events in the request. Only + * returned if FlushToPlayStream option is true. + */ + AssignedEventIds?: string[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabExperimentationApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabExperimentationApi.d.ts new file mode 100644 index 00000000..07e0c851 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabExperimentationApi.d.ts @@ -0,0 +1,446 @@ +/// + +declare module PlayFabExperimentationModule { + export interface IPlayFabExperimentation { + ForgetAllCredentials(): void; + + /** + * Creates a new experiment exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/createexclusiongroup + */ + CreateExclusionGroup(request: PlayFabExperimentationModels.CreateExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/createexperiment + */ + CreateExperiment(request: PlayFabExperimentationModels.CreateExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/deleteexclusiongroup + */ + DeleteExclusionGroup(request: PlayFabExperimentationModels.DeleteExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/deleteexperiment + */ + DeleteExperiment(request: PlayFabExperimentationModels.DeleteExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all exclusion groups for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexclusiongroups + */ + GetExclusionGroups(request: PlayFabExperimentationModels.GetExclusionGroupsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all exclusion groups for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexclusiongrouptraffic + */ + GetExclusionGroupTraffic(request: PlayFabExperimentationModels.GetExclusionGroupTrafficRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all experiments for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexperiments + */ + GetExperiments(request: PlayFabExperimentationModels.GetExperimentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the latest scorecard of the experiment for the title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getlatestscorecard + */ + GetLatestScorecard(request: PlayFabExperimentationModels.GetLatestScorecardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the treatment assignments for a player for every running experiment in the title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/gettreatmentassignment + */ + GetTreatmentAssignment(request: PlayFabExperimentationModels.GetTreatmentAssignmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Starts an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/startexperiment + */ + StartExperiment(request: PlayFabExperimentationModels.StartExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Stops an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/stopexperiment + */ + StopExperiment(request: PlayFabExperimentationModels.StopExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates an existing exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/updateexclusiongroup + */ + UpdateExclusionGroup(request: PlayFabExperimentationModels.UpdateExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/updateexperiment + */ + UpdateExperiment(request: PlayFabExperimentationModels.UpdateExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabExperimentationModels { + type AnalysisTaskState = "Waiting" + + | "ReadyForSubmission" + | "SubmittingToPipeline" + | "Running" + | "Completed" + | "Failed" + | "Canceled"; + + export interface CreateExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the exclusion group. */ + Description?: string; + /** Friendly name of the exclusion group. */ + Name: string; + + } + + export interface CreateExclusionGroupResult extends PlayFabModule.IPlayFabResultCommon { + /** Identifier of the exclusion group. */ + ExclusionGroupId?: string; + + } + + export interface CreateExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the experiment. */ + Description?: string; + /** When experiment should end. */ + EndDate?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Friendly name of the experiment. */ + Name: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start. */ + StartDate: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants: Variant[]; + + } + + export interface CreateExperimentResult extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the new experiment. */ + ExperimentId?: string; + + } + + export interface DeleteExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the exclusion group to delete. */ + ExclusionGroupId: string; + + } + + export interface DeleteExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to delete. */ + ExperimentId: string; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface ExclusionGroupTrafficAllocation { + /** Id of the experiment. */ + ExperimentId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + TrafficAllocation: number; + + } + + export interface Experiment { + /** Description of the experiment. */ + Description?: string; + /** When experiment should end/was ended. */ + EndDate?: string; + /** Id of the exclusion group for this experiment. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Id of the experiment. */ + Id?: string; + /** Friendly name of the experiment. */ + Name?: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start/was started. */ + StartDate: string; + /** State experiment is currently in. */ + State?: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants?: Variant[]; + + } + + export interface ExperimentExclusionGroup { + /** Description of the exclusion group. */ + Description?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Friendly name of the exclusion group. */ + Name?: string; + + } + + type ExperimentState = "New" + + | "Started" + | "Stopped" + | "Deleted"; + + type ExperimentType = "Active" + + | "Snapshot"; + + export interface GetExclusionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetExclusionGroupsResult extends PlayFabModule.IPlayFabResultCommon { + /** List of exclusion groups for the title. */ + ExclusionGroups?: ExperimentExclusionGroup[]; + + } + + export interface GetExclusionGroupTrafficRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the exclusion group. */ + ExclusionGroupId: string; + + } + + export interface GetExclusionGroupTrafficResult extends PlayFabModule.IPlayFabResultCommon { + /** List of traffic allocations for the exclusion group. */ + TrafficAllocations?: ExclusionGroupTrafficAllocation[]; + + } + + export interface GetExperimentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetExperimentsResult extends PlayFabModule.IPlayFabResultCommon { + /** List of experiments for the title. */ + Experiments?: Experiment[]; + + } + + export interface GetLatestScorecardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment. */ + ExperimentId?: string; + + } + + export interface GetLatestScorecardResult extends PlayFabModule.IPlayFabResultCommon { + /** Scorecard for the experiment of the title. */ + Scorecard?: Scorecard; + + } + + export interface GetTreatmentAssignmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetTreatmentAssignmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Treatment assignment for the entity. */ + TreatmentAssignment?: TreatmentAssignment; + + } + + export interface MetricData { + /** The upper bound of the confidence interval for the relative delta (Delta.RelativeValue). */ + ConfidenceIntervalEnd: number; + /** The lower bound of the confidence interval for the relative delta (Delta.RelativeValue). */ + ConfidenceIntervalStart: number; + /** The absolute delta between TreatmentStats.Average and ControlStats.Average. */ + DeltaAbsoluteChange: number; + /** The relative delta ratio between TreatmentStats.Average and ControlStats.Average. */ + DeltaRelativeChange: number; + /** The machine name of the metric. */ + InternalName?: string; + /** Indicates if a movement was detected on that metric. */ + Movement?: string; + /** The readable name of the metric. */ + Name?: string; + /** The expectation that a movement is real */ + PMove: number; + /** The p-value resulting from the statistical test run for this metric */ + PValue: number; + /** The threshold for observing sample ratio mismatch. */ + PValueThreshold: number; + /** Indicates if the movement is statistically significant. */ + StatSigLevel?: string; + /** Observed standard deviation value of the metric. */ + StdDev: number; + /** Observed average value of the metric. */ + Value: number; + + } + + export interface Scorecard { + /** Represents the date the scorecard was generated. */ + DateGenerated?: string; + /** Represents the duration of scorecard analysis. */ + Duration?: string; + /** Represents the number of events processed for the generation of this scorecard */ + EventsProcessed: number; + /** Id of the experiment. */ + ExperimentId?: string; + /** Friendly name of the experiment. */ + ExperimentName?: string; + /** Represents the latest compute job status. */ + LatestJobStatus?: string; + /** Represents the presence of a sample ratio mismatch in the scorecard data. */ + SampleRatioMismatch: boolean; + /** Scorecard containing list of analysis. */ + ScorecardDataRows?: ScorecardDataRow[]; + + } + + export interface ScorecardDataRow { + /** Represents whether the variant is control or not. */ + IsControl: boolean; + /** Data of the analysis with the internal name of the metric as the key and an object of metric data as value. */ + MetricDataRows?: { [key: string]: MetricData }; + /** Represents the player count in the variant. */ + PlayerCount: number; + /** Name of the variant of analysis. */ + VariantName?: string; + + } + + export interface StartExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to start. */ + ExperimentId: string; + + } + + export interface StopExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to stop. */ + ExperimentId: string; + + } + + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + + export interface UpdateExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the exclusion group. */ + Description?: string; + /** The ID of the exclusion group to update. */ + ExclusionGroupId: string; + /** Friendly name of the exclusion group. */ + Name: string; + + } + + export interface UpdateExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the experiment. */ + Description?: string; + /** When experiment should end. */ + EndDate?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Id of the experiment. */ + Id: string; + /** Friendly name of the experiment. */ + Name: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start. */ + StartDate: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants: Variant[]; + + } + + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; + + } + + export interface Variant { + /** Description of the variant. */ + Description?: string; + /** Id of the variant. */ + Id?: string; + /** Specifies if variant is control for experiment. */ + IsControl: boolean; + /** Name of the variant. */ + Name: string; + /** Id of the TitleDataOverride to use with this variant. */ + TitleDataOverrideLabel?: string; + /** Percentage of target audience traffic that will see this variant. */ + TrafficPercentage: number; + /** Variables returned by this variant. */ + Variables?: Variable[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabGroupsApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabGroupsApi.d.ts new file mode 100644 index 00000000..2ef182c1 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabGroupsApi.d.ts @@ -0,0 +1,658 @@ +/// + +declare module PlayFabGroupsModule { + export interface IPlayFabGroups { + ForgetAllCredentials(): void; + + /** + * Accepts an outstanding invitation to to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/acceptgroupapplication + */ + AcceptGroupApplication(request: PlayFabGroupsModels.AcceptGroupApplicationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Accepts an invitation to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/acceptgroupinvitation + */ + AcceptGroupInvitation(request: PlayFabGroupsModels.AcceptGroupInvitationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds members to a group or role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/addmembers + */ + AddMembers(request: PlayFabGroupsModels.AddMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Applies to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/applytogroup + */ + ApplyToGroup(request: PlayFabGroupsModels.ApplyToGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Blocks a list of entities from joining a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/blockentity + */ + BlockEntity(request: PlayFabGroupsModels.BlockEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Changes the role membership of a list of entities from one role to another. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/changememberrole + */ + ChangeMemberRole(request: PlayFabGroupsModels.ChangeMemberRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/creategroup + */ + CreateGroup(request: PlayFabGroupsModels.CreateGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new group role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/createrole + */ + CreateRole(request: PlayFabGroupsModels.CreateGroupRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a group and all roles, invitations, join requests, and blocks associated with it. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/deletegroup + */ + DeleteGroup(request: PlayFabGroupsModels.DeleteGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing role in a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/deleterole + */ + DeleteRole(request: PlayFabGroupsModels.DeleteRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information about a group and its roles + * https://docs.microsoft.com/rest/api/playfab/groups/groups/getgroup + */ + GetGroup(request: PlayFabGroupsModels.GetGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Invites a player to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/invitetogroup + */ + InviteToGroup(request: PlayFabGroupsModels.InviteToGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks to see if an entity is a member of a group or role within the group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/ismember + */ + IsMember(request: PlayFabGroupsModels.IsMemberRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding requests to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupapplications + */ + ListGroupApplications(request: PlayFabGroupsModels.ListGroupApplicationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all entities blocked from joining a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupblocks + */ + ListGroupBlocks(request: PlayFabGroupsModels.ListGroupBlocksRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding invitations for a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupinvitations + */ + ListGroupInvitations(request: PlayFabGroupsModels.ListGroupInvitationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all members for a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupmembers + */ + ListGroupMembers(request: PlayFabGroupsModels.ListGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all groups and roles for an entity + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listmembership + */ + ListMembership(request: PlayFabGroupsModels.ListMembershipRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding invitations and group applications for an entity + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listmembershipopportunities + */ + ListMembershipOpportunities(request: PlayFabGroupsModels.ListMembershipOpportunitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an application to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removegroupapplication + */ + RemoveGroupApplication(request: PlayFabGroupsModels.RemoveGroupApplicationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an invitation join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removegroupinvitation + */ + RemoveGroupInvitation(request: PlayFabGroupsModels.RemoveGroupInvitationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes members from a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removemembers + */ + RemoveMembers(request: PlayFabGroupsModels.RemoveMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unblocks a list of entities from joining a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/unblockentity + */ + UnblockEntity(request: PlayFabGroupsModels.UnblockEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates non-membership data about a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/updategroup + */ + UpdateGroup(request: PlayFabGroupsModels.UpdateGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates metadata about a role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/updaterole + */ + UpdateRole(request: PlayFabGroupsModels.UpdateGroupRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabGroupsModels { + export interface AcceptGroupApplicationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Type of the entity to accept as. Must be the same entity as the claimant or an entity that is a child of the claimant + * entity. + */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface AcceptGroupInvitationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface AddMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** List of entities to add to the group. Only entities of type title_player_account and character may be added to groups. */ + Members: EntityKey[]; + /** + * Optional: The ID of the existing role to add the entities to. If this is not specified, the default member role for the + * group will be used. Role IDs must be between 1 and 64 characters long. + */ + RoleId?: string; + + } + + export interface ApplyToGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional, default true. Automatically accept an outstanding invitation if one exists instead of creating an application */ + AutoAcceptOutstandingInvite?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ApplyToGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** Type of entity that requested membership */ + Entity?: EntityWithLineage; + /** When the application to join will expire and be deleted */ + Expires: string; + /** ID of the group that the entity requesting membership to */ + Group?: EntityKey; + + } + + export interface BlockEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ChangeMemberRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The ID of the role that the entities will become a member of. This must be an existing role. Role IDs must be between 1 + * and 64 characters long. + */ + DestinationRoleId?: string; + /** The identifier of the group */ + Group: EntityKey; + /** + * List of entities to move between roles in the group. All entities in this list must be members of the group and origin + * role. + */ + Members: EntityKey[]; + /** The ID of the role that the entities currently are a member of. Role IDs must be between 1 and 64 characters long. */ + OriginRoleId: string; + + } + + export interface CreateGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the group. This is unique at the title level by default. */ + GroupName: string; + + } + + export interface CreateGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the administrator role for the group. */ + AdminRoleId?: string; + /** The server date and time the group was created. */ + Created: string; + /** The identifier of the group */ + Group: EntityKey; + /** The name of the group. */ + GroupName?: string; + /** The ID of the default member role for the group. */ + MemberRoleId?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles and names that belong to the group. */ + Roles?: { [key: string]: string | null }; + + } + + export interface CreateGroupRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** + * The ID of the role. This must be unique within the group and cannot be changed. Role IDs must be between 1 and 64 + * characters long and are restricted to a-Z, A-Z, 0-9, '(', ')', '_', '-' and '.'. + */ + RoleId: string; + /** + * The name of the role. This must be unique within the group and can be changed later. Role names must be between 1 and + * 100 characters long + */ + RoleName: string; + + } + + export interface CreateGroupRoleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The current version of the group profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** ID for the role */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface DeleteGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of the group or role to remove */ + Group: EntityKey; + + } + + export interface DeleteRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** The ID of the role to delete. Role IDs must be between 1 and 64 characters long. */ + RoleId?: string; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityMemberRole { + /** The list of members in the role */ + Members?: EntityWithLineage[]; + /** The ID of the role. */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface EntityWithLineage { + /** The entity key for the specified entity */ + Key?: EntityKey; + /** Dictionary of entity keys for related entities. Dictionary key is entity type. */ + Lineage?: { [key: string]: EntityKey }; + + } + + export interface GetGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group?: EntityKey; + /** The full name of the group */ + GroupName?: string; + + } + + export interface GetGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the administrator role for the group. */ + AdminRoleId?: string; + /** The server date and time the group was created. */ + Created: string; + /** The identifier of the group */ + Group: EntityKey; + /** The name of the group. */ + GroupName?: string; + /** The ID of the default member role for the group. */ + MemberRoleId?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles and names that belong to the group. */ + Roles?: { [key: string]: string | null }; + + } + + export interface GroupApplication { + /** Type of entity that requested membership */ + Entity?: EntityWithLineage; + /** When the application to join will expire and be deleted */ + Expires: string; + /** ID of the group that the entity requesting membership to */ + Group?: EntityKey; + + } + + export interface GroupBlock { + /** The entity that is blocked */ + Entity?: EntityWithLineage; + /** ID of the group that the entity is blocked from */ + Group: EntityKey; + + } + + export interface GroupInvitation { + /** When the invitation will expire and be deleted */ + Expires: string; + /** The group that the entity invited to */ + Group?: EntityKey; + /** The entity that created the invitation */ + InvitedByEntity?: EntityWithLineage; + /** The entity that is invited */ + InvitedEntity?: EntityWithLineage; + /** ID of the role in the group to assign the user to. */ + RoleId?: string; + + } + + export interface GroupRole { + /** ID for the role */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface GroupWithRoles { + /** ID for the group */ + Group?: EntityKey; + /** The name of the group */ + GroupName?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles within the group */ + Roles?: GroupRole[]; + + } + + export interface InviteToGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional, default true. Automatically accept an application if one exists instead of creating an invitation */ + AutoAcceptOutstandingApplication?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + /** + * Optional. ID of an existing a role in the group to assign the user to. The group's default member role is used if this + * is not specified. Role IDs must be between 1 and 64 characters long. + */ + RoleId?: string; + + } + + export interface InviteToGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** When the invitation will expire and be deleted */ + Expires: string; + /** The group that the entity invited to */ + Group?: EntityKey; + /** The entity that created the invitation */ + InvitedByEntity?: EntityWithLineage; + /** The entity that is invited */ + InvitedEntity?: EntityWithLineage; + /** ID of the role in the group to assign the user to. */ + RoleId?: string; + + } + + export interface IsMemberRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + /** + * Optional: ID of the role to check membership of. Defaults to any role (that is, check to see if the entity is a member + * of the group in any capacity) if not specified. + */ + RoleId?: string; + + } + + export interface IsMemberResponse extends PlayFabModule.IPlayFabResultCommon { + /** A value indicating whether or not the entity is a member. */ + IsMember: boolean; + + } + + export interface ListGroupApplicationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupApplicationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of applications to the group. */ + Applications?: GroupApplication[]; + + } + + export interface ListGroupBlocksRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupBlocksResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list blocked entities. */ + BlockedEntities?: GroupBlock[]; + + } + + export interface ListGroupInvitationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupInvitationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of group invitations. */ + Invitations?: GroupInvitation[]; + + } + + export interface ListGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of the group to list the members and roles for */ + Group: EntityKey; + + } + + export interface ListGroupMembersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of roles and member entity IDs. */ + Members?: EntityMemberRole[]; + + } + + export interface ListMembershipOpportunitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListMembershipOpportunitiesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of group applications. */ + Applications?: GroupApplication[]; + /** The requested list of group invitations. */ + Invitations?: GroupInvitation[]; + + } + + export interface ListMembershipRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListMembershipResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of groups */ + Groups?: GroupWithRoles[]; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface RemoveGroupApplicationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface RemoveGroupInvitationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface RemoveMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** List of entities to remove */ + Members: EntityKey[]; + /** The ID of the role to remove the entities from. */ + RoleId?: string; + + } + + export interface UnblockEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface UpdateGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional: the ID of an existing role to set as the new administrator role for the group */ + AdminRoleId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetGroup API, you can ensure that the group data update is performed only if the group has not been updated since you + * last loaded that version. If the same group has been updated, the requested update will not occur and the returned + * SetResult value will be None. + */ + ExpectedProfileVersion?: number; + /** The identifier of the group */ + Group: EntityKey; + /** Optional: the new name of the group */ + GroupName?: string; + /** Optional: the ID of an existing role to set as the new member role for the group */ + MemberRoleId?: string; + + } + + export interface UpdateGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** New version of the group data. */ + ProfileVersion: number; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + export interface UpdateGroupRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetGroup API, you can ensure that the group role update is performed only if the group has not been updated since you + * last loaded that version. If the same group has been updated, the requested update will not occur and the returned + * SetResult value will be None. + */ + ExpectedProfileVersion?: number; + /** The identifier of the group */ + Group: EntityKey; + /** ID of the role to update. Role IDs must be between 1 and 64 characters long. */ + RoleId?: string; + /** The new name of the role */ + RoleName: string; + + } + + export interface UpdateGroupRoleResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** New version of the role data. */ + ProfileVersion: number; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabInsightsApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabInsightsApi.d.ts new file mode 100644 index 00000000..bdc18b6b --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabInsightsApi.d.ts @@ -0,0 +1,169 @@ +/// + +declare module PlayFabInsightsModule { + export interface IPlayFabInsights { + ForgetAllCredentials(): void; + + /** + * Gets the current values for the Insights performance and data storage retention, list of pending operations, and the + * performance and data storage retention limits. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getdetails + */ + GetDetails(request: PlayFabInsightsModels.InsightsEmptyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the range of allowed values for performance and data storage retention values as well as the submeter details + * for each performance level. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getlimits + */ + GetLimits(request: PlayFabInsightsModels.InsightsEmptyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of a SetPerformance or SetStorageRetention operation. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getoperationstatus + */ + GetOperationStatus(request: PlayFabInsightsModels.InsightsGetOperationStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a list of pending SetPerformance and/or SetStorageRetention operations for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getpendingoperations + */ + GetPendingOperations(request: PlayFabInsightsModels.InsightsGetPendingOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the Insights performance level value for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/setperformance + */ + SetPerformance(request: PlayFabInsightsModels.InsightsSetPerformanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the Insights data storage retention days value for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/setstorageretention + */ + SetStorageRetention(request: PlayFabInsightsModels.InsightsSetStorageRetentionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabInsightsModels { + export interface InsightsEmptyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface InsightsGetDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Amount of data (in MB) currently used by Insights. */ + DataUsageMb: number; + /** Details of any error that occurred while retrieving Insights details. */ + ErrorMessage?: string; + /** Allowed range of values for performance level and data storage retention. */ + Limits?: InsightsGetLimitsResponse; + /** List of pending Insights operations for the title. */ + PendingOperations?: InsightsGetOperationStatusResponse[]; + /** Current Insights performance level setting. */ + PerformanceLevel: number; + /** Current Insights data storage retention value in days. */ + RetentionDays: number; + + } + + export interface InsightsGetLimitsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Default Insights performance level. */ + DefaultPerformanceLevel: number; + /** Default Insights data storage retention days. */ + DefaultStorageRetentionDays: number; + /** Maximum allowed data storage retention days. */ + StorageMaxRetentionDays: number; + /** Minimum allowed data storage retention days. */ + StorageMinRetentionDays: number; + /** List of Insights submeter limits for the allowed performance levels. */ + SubMeters?: InsightsPerformanceLevel[]; + + } + + export interface InsightsGetOperationStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the Insights operation. */ + OperationId?: string; + + } + + export interface InsightsGetOperationStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional message related to the operation details. */ + Message?: string; + /** Time the operation was completed. */ + OperationCompletedTime: string; + /** Id of the Insights operation. */ + OperationId?: string; + /** Time the operation status was last updated. */ + OperationLastUpdated: string; + /** Time the operation started. */ + OperationStartedTime: string; + /** The type of operation, SetPerformance or SetStorageRetention. */ + OperationType?: string; + /** The value requested for the operation. */ + OperationValue: number; + /** Current status of the operation. */ + Status?: string; + + } + + export interface InsightsGetPendingOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The type of pending operations requested, or blank for all operation types. */ + OperationType?: string; + + } + + export interface InsightsGetPendingOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of pending Insights operations. */ + PendingOperations?: InsightsGetOperationStatusResponse[]; + + } + + export interface InsightsOperationResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional message related to the operation details. */ + Message?: string; + /** Id of the Insights operation. */ + OperationId?: string; + /** The type of operation, SetPerformance or SetStorageRetention. */ + OperationType?: string; + + } + + export interface InsightsPerformanceLevel { + /** Number of allowed active event exports. This value is always zero. */ + ActiveEventExports: number; + /** Maximum cache size. */ + CacheSizeMB: number; + /** Maximum number of concurrent queries. */ + Concurrency: number; + /** Number of Insights credits consumed per minute. */ + CreditsPerMinute: number; + /** Maximum events per second. */ + EventsPerSecond: number; + /** Performance level. */ + Level: number; + /** Maximum amount of memory allowed per query. */ + MaxMemoryPerQueryMB: number; + /** Amount of compute power allocated for queries and operations. */ + VirtualCpuCores: number; + + } + + export interface InsightsSetPerformanceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Insights performance level to apply to the title. */ + PerformanceLevel: number; + + } + + export interface InsightsSetStorageRetentionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Insights data storage retention value (in days) to apply to the title. */ + RetentionDays: number; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabLocalizationApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabLocalizationApi.d.ts new file mode 100644 index 00000000..f6dc8f6f --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabLocalizationApi.d.ts @@ -0,0 +1,30 @@ +/// + +declare module PlayFabLocalizationModule { + export interface IPlayFabLocalization { + ForgetAllCredentials(): void; + + /** + * Retrieves the list of allowed languages, only accessible by title entities + * https://docs.microsoft.com/rest/api/playfab/localization/localization/getlanguagelist + */ + GetLanguageList(request: PlayFabLocalizationModels.GetLanguageListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabLocalizationModels { + export interface GetLanguageListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetLanguageListResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of allowed languages, in BCP47 two-letter format */ + LanguageList?: string[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabMatchmakerApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabMatchmakerApi.d.ts deleted file mode 100644 index 81067299..00000000 --- a/PlayFabSdk/src/Typings/PlayFab/PlayFabMatchmakerApi.d.ts +++ /dev/null @@ -1,360 +0,0 @@ -/// - -declare module PlayFabMatchmakerModule { - export interface IPlayFabMatchmaker { - /** - / Validates a user with the PlayFab service - / https://api.playfab.com/Documentation/Matchmaker/method/AuthUser - */ - AuthUser(request: PlayFabMatchmakerModels.AuthUserRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Informs the PlayFab game server hosting service that the indicated user has joined the Game Server Instance specified - / https://api.playfab.com/Documentation/Matchmaker/method/PlayerJoined - */ - PlayerJoined(request: PlayFabMatchmakerModels.PlayerJoinedRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Informs the PlayFab game server hosting service that the indicated user has left the Game Server Instance specified - / https://api.playfab.com/Documentation/Matchmaker/method/PlayerLeft - */ - PlayerLeft(request: PlayFabMatchmakerModels.PlayerLeftRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Instructs the PlayFab game server hosting service to instantiate a new Game Server Instance - / https://api.playfab.com/Documentation/Matchmaker/method/StartGame - */ - StartGame(request: PlayFabMatchmakerModels.StartGameRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Retrieves the relevant details for a specified user, which the external match-making service can then use to compute effective matches - / https://api.playfab.com/Documentation/Matchmaker/method/UserInfo - */ - UserInfo(request: PlayFabMatchmakerModels.UserInfoRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabMatchmakerModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.AuthUserRequest - */ - export interface AuthUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Session Ticket provided by the client. - */ - AuthorizationTicket: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.AuthUserResponse - */ - export interface AuthUserResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Boolean indicating if the user has been authorized to use the external match-making service. - */ - Authorized: boolean; - /** - / PlayFab unique identifier of the account that has been authorized. - */ - PlayFabId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.DeregisterGameRequest - */ - export interface DeregisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the Game Server Instance that is being deregistered. - */ - LobbyId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.DeregisterGameResponse - */ - export interface DeregisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.ItemInstance - */ - export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ - UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ - UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerJoinedRequest - */ - export interface PlayerJoinedRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance the user is joining. - */ - LobbyId: string; - /** - / PlayFab unique identifier for the user joining. - */ - PlayFabId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerJoinedResponse - */ - export interface PlayerJoinedResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerLeftRequest - */ - export interface PlayerLeftRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance the user is leaving. - */ - LobbyId: string; - /** - / PlayFab unique identifier for the user leaving. - */ - PlayFabId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerLeftResponse - */ - export interface PlayerLeftResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.RegisterGameRequest - */ - export interface RegisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / IP address of the Game Server Instance. - */ - ServerHost: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: string; - /** - / Unique identifier of the build running on the Game Server Instance. - */ - Build: string; - /** - / Region in which the Game Server Instance is running. For matchmaking using non-AWS region names, set this to any AWS region and use Tags (below) to specify your custom region. - */ - Region: string; - /** - / Game Mode the Game Server instance is running. Note that this must be defined in the Game Modes tab in the PlayFab Game Manager, along with the Build ID (the same Game Mode can be defined for multiple Build IDs). - */ - GameMode: string; - /** - / Tags for the Game Server Instance - */ - Tags?: { [key: string]: string }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.RegisterGameResponse - */ - export interface RegisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier generated for the Game Server Instance that is registered. - */ - LobbyId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.StartGameRequest - */ - export interface StartGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the previously uploaded build executable which is to be started. - */ - Build: string; - /** - / Region with which to associate the server, for filtering. - */ - Region: string; - /** - / Game mode for this Game Server Instance. - */ - GameMode: string; - /** - / Custom command line argument when starting game server process. - */ - CustomCommandLineData?: string; - /** - / HTTP endpoint URL for receiving game status events, if using an external matchmaker. When the game ends, PlayFab will make a POST request to this URL with the X-SecretKey header set to the value of the game's secret and an application/json body of { "EventName": "game_ended", "GameID": "" }. - */ - ExternalMatchmakerEventEndpoint: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.StartGameResponse - */ - export interface StartGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the game/lobby in the new Game Server Instance. - */ - GameID?: string; - /** - / IP address of the new Game Server Instance. - */ - ServerHostname?: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.UserInfoRequest - */ - export interface UserInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose information is being requested. - */ - PlayFabId: string; - /** - / Minimum catalog version for which data is requested (filters the results to only contain inventory items which have a catalog version of this or higher). - */ - MinCatalogVersion: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.UserInfoResponse - */ - export interface UserInfoResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose information was requested. - */ - PlayFabId?: string; - /** - / PlayFab unique user name. - */ - Username?: string; - /** - / Title specific display name, if set. - */ - TitleDisplayName?: string; - /** - / Array of inventory items in the user's current inventory. - */ - Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ - VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ - VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; - /** - / Boolean indicating whether the user is a developer. - */ - IsDeveloper: boolean; - /** - / Steam unique identifier, if the user has an associated Steam account. - */ - SteamId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.VirtualCurrencyRechargeTime - */ - export interface VirtualCurrencyRechargeTime { - /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. - */ - RechargeMax: number; - - } - - -} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabMultiplayerApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabMultiplayerApi.d.ts new file mode 100644 index 00000000..17112934 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabMultiplayerApi.d.ts @@ -0,0 +1,3802 @@ +/// + +declare module PlayFabMultiplayerModule { + export interface IPlayFabMultiplayer { + ForgetAllCredentials(): void; + + /** + * Cancel all active tickets the player is a member of in a given queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelallmatchmakingticketsforplayer + */ + CancelAllMatchmakingTicketsForPlayer(request: PlayFabMultiplayerModels.CancelAllMatchmakingTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel all active backfill tickets the player is a member of in a given queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelallserverbackfillticketsforplayer + */ + CancelAllServerBackfillTicketsForPlayer(request: PlayFabMultiplayerModels.CancelAllServerBackfillTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel a matchmaking ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelmatchmakingticket + */ + CancelMatchmakingTicket(request: PlayFabMultiplayerModels.CancelMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel a server backfill ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelserverbackfillticket + */ + CancelServerBackfillTicket(request: PlayFabMultiplayerModels.CancelServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildalias + */ + CreateBuildAlias(request: PlayFabMultiplayerModels.CreateBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with a custom container. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithcustomcontainer + */ + CreateBuildWithCustomContainer(request: PlayFabMultiplayerModels.CreateBuildWithCustomContainerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with a managed container. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithmanagedcontainer + */ + CreateBuildWithManagedContainer(request: PlayFabMultiplayerModels.CreateBuildWithManagedContainerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with the server running as a process. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithprocessbasedserver + */ + CreateBuildWithProcessBasedServer(request: PlayFabMultiplayerModels.CreateBuildWithProcessBasedServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/createlobby + */ + CreateLobby(request: PlayFabMultiplayerModels.CreateLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a matchmaking ticket as a client. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/creatematchmakingticket + */ + CreateMatchmakingTicket(request: PlayFabMultiplayerModels.CreateMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a remote user to log on to a VM for a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createremoteuser + */ + CreateRemoteUser(request: PlayFabMultiplayerModels.CreateRemoteUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a backfill matchmaking ticket as a server. A backfill ticket represents an ongoing game. The matchmaking service + * automatically starts matching the backfill ticket against other matchmaking tickets. Backfill tickets cannot match with + * other backfill tickets. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/createserverbackfillticket + */ + CreateServerBackfillTicket(request: PlayFabMultiplayerModels.CreateServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a matchmaking ticket as a server. The matchmaking service automatically starts matching the ticket against other + * matchmaking tickets. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/createservermatchmakingticket + */ + CreateServerMatchmakingTicket(request: PlayFabMultiplayerModels.CreateServerMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a request to change a title's multiplayer server quotas. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createtitlemultiplayerserversquotachange + */ + CreateTitleMultiplayerServersQuotaChange(request: PlayFabMultiplayerModels.CreateTitleMultiplayerServersQuotaChangeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game asset for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deleteasset + */ + DeleteAsset(request: PlayFabMultiplayerModels.DeleteAssetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuild + */ + DeleteBuild(request: PlayFabMultiplayerModels.DeleteBuildRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuildalias + */ + DeleteBuildAlias(request: PlayFabMultiplayerModels.DeleteBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes a multiplayer server build's region. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuildregion + */ + DeleteBuildRegion(request: PlayFabMultiplayerModels.DeleteBuildRegionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game certificate. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletecertificate + */ + DeleteCertificate(request: PlayFabMultiplayerModels.DeleteCertificateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a container image repository. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletecontainerimagerepository + */ + DeleteContainerImageRepository(request: PlayFabMultiplayerModels.DeleteContainerImageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/deletelobby + */ + DeleteLobby(request: PlayFabMultiplayerModels.DeleteLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a remote user to log on to a VM for a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deleteremoteuser + */ + DeleteRemoteUser(request: PlayFabMultiplayerModels.DeleteRemoteUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game secret. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletesecret + */ + DeleteSecret(request: PlayFabMultiplayerModels.DeleteSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Enables the multiplayer server feature for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/enablemultiplayerserversfortitle + */ + EnableMultiplayerServersForTitle(request: PlayFabMultiplayerModels.EnableMultiplayerServersForTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Find lobbies which match certain criteria, and which friends are in. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/findfriendlobbies + */ + FindFriendLobbies(request: PlayFabMultiplayerModels.FindFriendLobbiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Find all the lobbies that match certain criteria. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/findlobbies + */ + FindLobbies(request: PlayFabMultiplayerModels.FindLobbiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a URL that can be used to download the specified asset. A sample pre-authenticated url - + * https://sampleStorageAccount.blob.core.windows.net/gameassets/gameserver.zip?sv=2015-04-05&ss=b&srt=sco&sp=rw&st=startDate&se=endDate&spr=https&sig=sampleSig&api-version=2017-07-29 + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getassetdownloadurl + */ + GetAssetDownloadUrl(request: PlayFabMultiplayerModels.GetAssetDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the URL to upload assets to. A sample pre-authenticated url - + * https://sampleStorageAccount.blob.core.windows.net/gameassets/gameserver.zip?sv=2015-04-05&ss=b&srt=sco&sp=rw&st=startDate&se=endDate&spr=https&sig=sampleSig&api-version=2017-07-29 + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getassetuploadurl + */ + GetAssetUploadUrl(request: PlayFabMultiplayerModels.GetAssetUploadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getbuild + */ + GetBuild(request: PlayFabMultiplayerModels.GetBuildRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getbuildalias + */ + GetBuildAlias(request: PlayFabMultiplayerModels.GetBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the credentials to the container registry. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getcontainerregistrycredentials + */ + GetContainerRegistryCredentials(request: PlayFabMultiplayerModels.GetContainerRegistryCredentialsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/getlobby + */ + GetLobby(request: PlayFabMultiplayerModels.GetLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a match. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getmatch + */ + GetMatch(request: PlayFabMultiplayerModels.GetMatchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Get a matchmaking queue configuration. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/getmatchmakingqueue + */ + GetMatchmakingQueue(request: PlayFabMultiplayerModels.GetMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a matchmaking ticket by ticket Id. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getmatchmakingticket + */ + GetMatchmakingTicket(request: PlayFabMultiplayerModels.GetMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server session details for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayerserverdetails + */ + GetMultiplayerServerDetails(request: PlayFabMultiplayerModels.GetMultiplayerServerDetailsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server logs after a server has terminated. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayerserverlogs + */ + GetMultiplayerServerLogs(request: PlayFabMultiplayerModels.GetMultiplayerServerLogsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server logs after a server has terminated. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayersessionlogsbysessionid + */ + GetMultiplayerSessionLogsBySessionId(request: PlayFabMultiplayerModels.GetMultiplayerSessionLogsBySessionIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the statistics for a queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getqueuestatistics + */ + GetQueueStatistics(request: PlayFabMultiplayerModels.GetQueueStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a remote login endpoint to a VM that is hosting a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getremoteloginendpoint + */ + GetRemoteLoginEndpoint(request: PlayFabMultiplayerModels.GetRemoteLoginEndpointRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a matchmaking backfill ticket by ticket Id. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getserverbackfillticket + */ + GetServerBackfillTicket(request: PlayFabMultiplayerModels.GetServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of whether a title is enabled for the multiplayer server feature. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitleenabledformultiplayerserversstatus + */ + GetTitleEnabledForMultiplayerServersStatus(request: PlayFabMultiplayerModels.GetTitleEnabledForMultiplayerServersStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a title's server quota change request. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitlemultiplayerserversquotachange + */ + GetTitleMultiplayerServersQuotaChange(request: PlayFabMultiplayerModels.GetTitleMultiplayerServersQuotaChangeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the quotas for a title in relation to multiplayer servers. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitlemultiplayerserversquotas + */ + GetTitleMultiplayerServersQuotas(request: PlayFabMultiplayerModels.GetTitleMultiplayerServersQuotasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Send a notification to invite a player to a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/invitetolobby + */ + InviteToLobby(request: PlayFabMultiplayerModels.InviteToLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join an Arranged lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinarrangedlobby + */ + JoinArrangedLobby(request: PlayFabMultiplayerModels.JoinArrangedLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinlobby + */ + JoinLobby(request: PlayFabMultiplayerModels.JoinLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Join a lobby as a server entity. This is restricted to client lobbies which are using connections. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinlobbyasserver + */ + JoinLobbyAsServer(request: PlayFabMultiplayerModels.JoinLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join a matchmaking ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/joinmatchmakingticket + */ + JoinMatchmakingTicket(request: PlayFabMultiplayerModels.JoinMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Leave a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/leavelobby + */ + LeaveLobby(request: PlayFabMultiplayerModels.LeaveLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Request for server to leave a lobby. This is restricted to client owned lobbies which are using connections. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/leavelobbyasserver + */ + LeaveLobbyAsServer(request: PlayFabMultiplayerModels.LeaveLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists archived multiplayer server sessions for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listarchivedmultiplayerservers + */ + ListArchivedMultiplayerServers(request: PlayFabMultiplayerModels.ListMultiplayerServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game assets for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listassetsummaries + */ + ListAssetSummaries(request: PlayFabMultiplayerModels.ListAssetSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists details of all build aliases for a title. Accepts tokens for title and if game client access is enabled, allows + * game client to request list of builds with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listbuildaliases + */ + ListBuildAliases(request: PlayFabMultiplayerModels.ListBuildAliasesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists summarized details of all multiplayer server builds for a title. Accepts tokens for title and if game client + * access is enabled, allows game client to request list of builds with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listbuildsummariesv2 + */ + ListBuildSummariesV2(request: PlayFabMultiplayerModels.ListBuildSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game certificates for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcertificatesummaries + */ + ListCertificateSummaries(request: PlayFabMultiplayerModels.ListCertificateSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists custom container images for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcontainerimages + */ + ListContainerImages(request: PlayFabMultiplayerModels.ListContainerImagesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists the tags for a custom container image. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcontainerimagetags + */ + ListContainerImageTags(request: PlayFabMultiplayerModels.ListContainerImageTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. List all matchmaking queue configs. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/listmatchmakingqueues + */ + ListMatchmakingQueues(request: PlayFabMultiplayerModels.ListMatchmakingQueuesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all matchmaking ticket Ids the user is a member of. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/listmatchmakingticketsforplayer + */ + ListMatchmakingTicketsForPlayer(request: PlayFabMultiplayerModels.ListMatchmakingTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server sessions for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listmultiplayerservers + */ + ListMultiplayerServers(request: PlayFabMultiplayerModels.ListMultiplayerServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists quality of service servers for party. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listpartyqosservers + */ + ListPartyQosServers(request: PlayFabMultiplayerModels.ListPartyQosServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists quality of service servers for the title. By default, servers are only returned for regions where a Multiplayer + * Servers build has been deployed. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listqosserversfortitle + */ + ListQosServersForTitle(request: PlayFabMultiplayerModels.ListQosServersForTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game secrets for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listsecretsummaries + */ + ListSecretSummaries(request: PlayFabMultiplayerModels.ListSecretSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all server backfill ticket Ids the user is a member of. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/listserverbackfillticketsforplayer + */ + ListServerBackfillTicketsForPlayer(request: PlayFabMultiplayerModels.ListServerBackfillTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all server quota change requests for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listtitlemultiplayerserversquotachanges + */ + ListTitleMultiplayerServersQuotaChanges(request: PlayFabMultiplayerModels.ListTitleMultiplayerServersQuotaChangesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists virtual machines for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listvirtualmachinesummaries + */ + ListVirtualMachineSummaries(request: PlayFabMultiplayerModels.ListVirtualMachineSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Remove a matchmaking queue config. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/removematchmakingqueue + */ + RemoveMatchmakingQueue(request: PlayFabMultiplayerModels.RemoveMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Remove a member from a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/removemember + */ + RemoveMember(request: PlayFabMultiplayerModels.RemoveMemberFromLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Request a multiplayer server session. Accepts tokens for title and if game client access is enabled, allows game client + * to request a server with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/requestmultiplayerserver + */ + RequestMultiplayerServer(request: PlayFabMultiplayerModels.RequestMultiplayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Request a party session. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/requestpartyservice + */ + RequestPartyService(request: PlayFabMultiplayerModels.RequestPartyServiceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Rolls over the credentials to the container registry. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/rollovercontainerregistrycredentials + */ + RolloverContainerRegistryCredentials(request: PlayFabMultiplayerModels.RolloverContainerRegistryCredentialsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Create or update a matchmaking queue configuration. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/setmatchmakingqueue + */ + SetMatchmakingQueue(request: PlayFabMultiplayerModels.SetMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Shuts down a multiplayer server session. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/shutdownmultiplayerserver + */ + ShutdownMultiplayerServer(request: PlayFabMultiplayerModels.ShutdownMultiplayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subscribe to lobby resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/subscribetolobbyresource + */ + SubscribeToLobbyResource(request: PlayFabMultiplayerModels.SubscribeToLobbyResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subscribe to match resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/subscribetomatchmakingresource + */ + SubscribeToMatchmakingResource(request: PlayFabMultiplayerModels.SubscribeToMatchResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unsubscribe from lobby notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/unsubscribefromlobbyresource + */ + UnsubscribeFromLobbyResource(request: PlayFabMultiplayerModels.UnsubscribeFromLobbyResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unsubscribe from match resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/unsubscribefrommatchmakingresource + */ + UnsubscribeFromMatchmakingResource(request: PlayFabMultiplayerModels.UnsubscribeFromMatchResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Untags a container image. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/untagcontainerimage + */ + UntagContainerImage(request: PlayFabMultiplayerModels.UntagContainerImageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildalias + */ + UpdateBuildAlias(request: PlayFabMultiplayerModels.UpdateBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's name. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildname + */ + UpdateBuildName(request: PlayFabMultiplayerModels.UpdateBuildNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's region. If the region is not yet created, it will be created + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildregion + */ + UpdateBuildRegion(request: PlayFabMultiplayerModels.UpdateBuildRegionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's regions. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildregions + */ + UpdateBuildRegions(request: PlayFabMultiplayerModels.UpdateBuildRegionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/updatelobby + */ + UpdateLobby(request: PlayFabMultiplayerModels.UpdateLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Update fields related to a joined server in the lobby the server is in. Servers can keep a lobby from expiring + * by being the one to "update" the lobby in some way. Servers have no impact on last member leave/last member disconnect + * behavior. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/updatelobbyasserver + */ + UpdateLobbyAsServer(request: PlayFabMultiplayerModels.UpdateLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Uploads a multiplayer server game certificate. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/uploadcertificate + */ + UploadCertificate(request: PlayFabMultiplayerModels.UploadCertificateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Uploads a multiplayer server game secret. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/uploadsecret + */ + UploadSecret(request: PlayFabMultiplayerModels.UploadSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabMultiplayerModels { + type AccessPolicy = "Public" + + | "Friends" + | "Private"; + + export interface AssetReference { + /** The asset's file name. This is a filename with the .zip, .tar, or .tar.gz extension. */ + FileName?: string; + /** The asset's mount path. */ + MountPath?: string; + + } + + export interface AssetReferenceParams { + /** The asset's file name. */ + FileName: string; + /** The asset's mount path. */ + MountPath?: string; + + } + + export interface AssetSummary { + /** The asset's file name. This is a filename with the .zip, .tar, or .tar.gz extension. */ + FileName?: string; + /** The metadata associated with the asset. */ + Metadata?: { [key: string]: string | null }; + + } + + type AttributeMergeFunction = "Min" + + | "Max" + | "Average"; + + type AttributeNotSpecifiedBehavior = "UseDefault" + + | "MatchAny"; + + type AttributeSource = "User" + + | "PlayerEntity"; + + type AzureRegion = "AustraliaEast" + + | "AustraliaSoutheast" + | "BrazilSouth" + | "CentralUs" + | "EastAsia" + | "EastUs" + | "EastUs2" + | "JapanEast" + | "JapanWest" + | "NorthCentralUs" + | "NorthEurope" + | "SouthCentralUs" + | "SoutheastAsia" + | "WestEurope" + | "WestUs" + | "SouthAfricaNorth" + | "WestCentralUs" + | "KoreaCentral" + | "FranceCentral" + | "WestUs2" + | "CentralIndia" + | "UaeNorth" + | "UkSouth" + | "SwedenCentral" + | "CanadaCentral" + | "MexicoCentral" + | "WestUs3" + | "CanadaEast" + | "UkWest" + | "FranceSouth" + | "SouthIndia" + | "SpainCentral" + | "GermanyWestCentral" + | "ItalyNorth" + | "IndonesiaCentral" + | "ChileCentral" + | "PolandCentral" + | "NewZealandNorth" + | "BrazilSoutheast" + | "NorwayEast" + | "SwitzerlandNorth" + | "MalaysiaWest" + | "IsraelCentral" + | "QatarCentral" + | "UaeCentral" + | "GermanyNorth" + | "AustriaEast" + | "BelgiumCentral" + | "DenmarkEast" + | "SwitzerlandWest" + | "SwedenSouth" + | "NorwayWest" + | "SouthAfricaWest" + | "MalaysiaSouth"; + + type AzureVmFamily = "A" + + | "Av2" + | "Dv2" + | "Dv3" + | "F" + | "Fsv2" + | "Dasv4" + | "Dav4" + | "Dadsv5" + | "Dadsv6" + | "Eav4" + | "Easv4" + | "Ev4" + | "Esv4" + | "Edsv4" + | "Edsv5" + | "Edsv6" + | "Dsv3" + | "Dsv2" + | "NCasT4_v3" + | "Ddv4" + | "Ddsv4" + | "HBv3" + | "Ddv5" + | "Ddsv5" + | "Ddsv6" + | "Fasv6" + | "Fasv7" + | "Fadsv7" + | "Eadsv5" + | "Eadsv6" + | "Eadsv7" + | "Dadsv7" + | "Dpdsv6"; + + type AzureVmSize = "Standard_A1" + + | "Standard_A2" + | "Standard_A3" + | "Standard_A4" + | "Standard_A1_v2" + | "Standard_A2_v2" + | "Standard_A4_v2" + | "Standard_A8_v2" + | "Standard_D1_v2" + | "Standard_D2_v2" + | "Standard_D3_v2" + | "Standard_D4_v2" + | "Standard_D5_v2" + | "Standard_D2_v3" + | "Standard_D4_v3" + | "Standard_D8_v3" + | "Standard_D16_v3" + | "Standard_F1" + | "Standard_F2" + | "Standard_F4" + | "Standard_F8" + | "Standard_F16" + | "Standard_F2s_v2" + | "Standard_F4s_v2" + | "Standard_F8s_v2" + | "Standard_F16s_v2" + | "Standard_F2as_v6" + | "Standard_F4as_v6" + | "Standard_F8as_v6" + | "Standard_F16as_v6" + | "Standard_F2as_v7" + | "Standard_F4as_v7" + | "Standard_F8as_v7" + | "Standard_F16as_v7" + | "Standard_F2ads_v7" + | "Standard_F4ads_v7" + | "Standard_F8ads_v7" + | "Standard_F16ads_v7" + | "Standard_D2as_v4" + | "Standard_D4as_v4" + | "Standard_D8as_v4" + | "Standard_D16as_v4" + | "Standard_D2a_v4" + | "Standard_D4a_v4" + | "Standard_D8a_v4" + | "Standard_D16a_v4" + | "Standard_D2ads_v5" + | "Standard_D4ads_v5" + | "Standard_D8ads_v5" + | "Standard_D16ads_v5" + | "Standard_D2ads_v6" + | "Standard_D4ads_v6" + | "Standard_D8ads_v6" + | "Standard_D16ads_v6" + | "Standard_D2ads_v7" + | "Standard_D4ads_v7" + | "Standard_D8ads_v7" + | "Standard_D16ads_v7" + | "Standard_E2a_v4" + | "Standard_E4a_v4" + | "Standard_E8a_v4" + | "Standard_E16a_v4" + | "Standard_E2as_v4" + | "Standard_E4as_v4" + | "Standard_E8as_v4" + | "Standard_E16as_v4" + | "Standard_E2ads_v5" + | "Standard_E4ads_v5" + | "Standard_E8ads_v5" + | "Standard_E16ads_v5" + | "Standard_E2ads_v6" + | "Standard_E4ads_v6" + | "Standard_E8ads_v6" + | "Standard_E16ads_v6" + | "Standard_E2ads_v7" + | "Standard_E4ads_v7" + | "Standard_E8ads_v7" + | "Standard_E16ads_v7" + | "Standard_E2ds_v4" + | "Standard_E4ds_v4" + | "Standard_E8ds_v4" + | "Standard_E16ds_v4" + | "Standard_E2ds_v5" + | "Standard_E4ds_v5" + | "Standard_E8ds_v5" + | "Standard_E16ds_v5" + | "Standard_E2ds_v6" + | "Standard_E4ds_v6" + | "Standard_E8ds_v6" + | "Standard_E16ds_v6" + | "Standard_D2s_v3" + | "Standard_D4s_v3" + | "Standard_D8s_v3" + | "Standard_D16s_v3" + | "Standard_DS1_v2" + | "Standard_DS2_v2" + | "Standard_DS3_v2" + | "Standard_DS4_v2" + | "Standard_DS5_v2" + | "Standard_NC4as_T4_v3" + | "Standard_D2d_v4" + | "Standard_D4d_v4" + | "Standard_D8d_v4" + | "Standard_D16d_v4" + | "Standard_D2ds_v4" + | "Standard_D4ds_v4" + | "Standard_D8ds_v4" + | "Standard_D16ds_v4" + | "Standard_HB120_16rs_v3" + | "Standard_HB120_32rs_v3" + | "Standard_HB120_64rs_v3" + | "Standard_HB120_96rs_v3" + | "Standard_HB120rs_v3" + | "Standard_D2d_v5" + | "Standard_D4d_v5" + | "Standard_D8d_v5" + | "Standard_D16d_v5" + | "Standard_D32d_v5" + | "Standard_D2ds_v5" + | "Standard_D4ds_v5" + | "Standard_D8ds_v5" + | "Standard_D16ds_v5" + | "Standard_D32ds_v5" + | "Standard_D2ds_v6" + | "Standard_D4ds_v6" + | "Standard_D8ds_v6" + | "Standard_D16ds_v6" + | "Standard_D2pds_v6" + | "Standard_D4pds_v6" + | "Standard_D8pds_v6" + | "Standard_D16pds_v6"; + + export interface BuildAliasDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The guid string alias Id of the alias to be created or updated. */ + AliasId?: string; + /** The alias name. */ + AliasName?: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + + } + + export interface BuildAliasParams { + /** The guid string alias ID to use for the request. */ + AliasId: string; + + } + + export interface BuildRegion { + /** The current multiplayer server stats for the region. */ + CurrentServerStats?: CurrentServerStats; + /** Optional settings to control dynamic adjustment of standby target */ + DynamicStandbySettings?: DynamicStandbySettings; + /** Whether the game assets provided for the build have been replicated to this region. */ + IsAssetReplicationComplete: boolean; + /** The maximum number of multiplayer servers for the region. */ + MaxServers: number; + /** Regional override for the number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm?: number; + /** The build region. */ + Region?: string; + /** Optional settings to set the standby target to specified values during the supplied schedules */ + ScheduledStandbySettings?: ScheduledStandbySettings; + /** The target number of standby multiplayer servers for the region. */ + StandbyServers: number; + /** + * The status of multiplayer servers in the build region. Valid values are - Unknown, Initialized, Deploying, Deployed, + * Unhealthy, Deleting, Deleted. + */ + Status?: string; + /** Regional override for the VM size the build was created on. */ + VmSize?: string; + + } + + export interface BuildRegionParams { + /** Optional settings to control dynamic adjustment of standby target. If not specified, dynamic standby is disabled */ + DynamicStandbySettings?: DynamicStandbySettings; + /** The maximum number of multiplayer servers for the region. */ + MaxServers: number; + /** Regional override for the number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm?: number; + /** The build region. */ + Region: string; + /** Optional settings to set the standby target to specified values during the supplied schedules */ + ScheduledStandbySettings?: ScheduledStandbySettings; + /** The number of standby multiplayer servers for the region. */ + StandbyServers: number; + /** Regional override for the VM size the build was created on. */ + VmSize?: string; + + } + + export interface BuildSelectionCriterion { + /** Dictionary of build ids and their respective weights for distribution of allocation requests. */ + BuildWeightDistribution?: { [key: string]: number }; + + } + + export interface BuildSummary { + /** The guid string build ID of the build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The configuration and status for each region in the build. */ + RegionConfigurations?: BuildRegion[]; + + } + + export interface CancelAllMatchmakingTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the queue from which a player's tickets should be canceled. */ + QueueName: string; + + } + + export interface CancelAllMatchmakingTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CancelAllServerBackfillTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The name of the queue from which a player's backfill tickets should be canceled. */ + QueueName: string; + + } + + export interface CancelAllServerBackfillTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + type CancellationReason = "Requested" + + | "Internal" + | "Timeout"; + + export interface CancelMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue the ticket is in. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CancelMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CancelServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue the ticket is in. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CancelServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Certificate { + /** Base64 encoded string contents of the certificate. */ + Base64EncodedValue: string; + /** A name for the certificate. This is used to reference certificates in build configurations. */ + Name: string; + /** + * If required for your PFX certificate, use this field to provide a password that will be used to install the certificate + * on the container. + */ + Password?: string; + + } + + export interface CertificateSummary { + /** The name of the certificate. */ + Name?: string; + /** The thumbprint for the certificate. */ + Thumbprint?: string; + + } + + export interface ConnectedPlayer { + /** The player ID of the player connected to the multiplayer server. */ + PlayerId?: string; + + } + + type ContainerFlavor = "ManagedWindowsServerCore" + + | "CustomLinux" + | "ManagedWindowsServerCorePreview" + | "Invalid"; + + export interface ContainerImageReference { + /** The container image name. */ + ImageName: string; + /** The container tag. */ + Tag?: string; + + } + + export interface CoreCapacity { + /** The available core capacity for the (Region, VmFamily) */ + Available: number; + /** The AzureRegion */ + Region?: string; + /** The total core capacity for the (Region, VmFamily) */ + Total: number; + /** The AzureVmFamily */ + VmFamily?: string; + + } + + export interface CoreCapacityChange { + /** New quota core limit for the given vm family/region. */ + NewCoreLimit: number; + /** Region to change. */ + Region: string; + /** Virtual machine family to change. */ + VmFamily: string; + + } + + export interface CreateBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The alias name. */ + AliasName: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface CreateBuildWithCustomContainerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The flavor of container to create a build from. */ + ContainerFlavor?: string; + /** The container reference, consisting of the image name and tag. */ + ContainerImageReference?: ContainerImageReference; + /** The container command to run when the multiplayer server has been allocated, including any arguments. */ + ContainerRunCommand?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences?: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** The Linux instrumentation configuration for the build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + + } + + export interface CreateBuildWithCustomContainerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The container command to run when the multiplayer server has been allocated, including any arguments. */ + ContainerRunCommand?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The custom game container image reference information. */ + CustomGameContainerImage?: ContainerImageReference; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** The Linux instrumentation configuration for this build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateBuildWithManagedContainerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The flavor of container to create a build from. */ + ContainerFlavor?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** + * The directory containing the game executable. This would be the start path of the game assets that contain the main game + * server executable. If not provided, a best effort will be made to extract it from the start game command. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for the build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The command to run when the multiplayer server is started, including any arguments. */ + StartMultiplayerServerCommand: string; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + /** The crash dump configuration for the build. */ + WindowsCrashDumpConfiguration?: WindowsCrashDumpConfiguration; + + } + + export interface CreateBuildWithManagedContainerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** + * The directory containing the game executable. This would be the start path of the game assets that contain the main game + * server executable. If not provided, a best effort will be made to extract it from the start game command. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for this build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** The command to run when the multiplayer server has been allocated, including any arguments. */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateBuildWithProcessBasedServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** + * The working directory for the game process. If this is not provided, the working directory will be set based on the + * mount path of the game server executable. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for the Build. Used only if it is a Windows Build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Indicates whether this build will be created using the OS Preview versionPreview OS is recommended for dev builds to + * detect any breaking changes before they are released to retail. Retail builds should set this value to false. + */ + IsOSPreview?: boolean; + /** The Linux instrumentation configuration for the Build. Used only if it is a Linux Build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** + * The command to run when the multiplayer server is started, including any arguments. The path to any executable should be + * relative to the root asset folder when unzipped. + */ + StartMultiplayerServerCommand: string; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + + } + + export interface CreateBuildWithProcessBasedServerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** + * The working directory for the game process. If this is not provided, the working directory will be set based on the + * mount path of the game server executable. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for this build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Indicates whether this build will be created using the OS Preview versionPreview OS is recommended for dev builds to + * detect any breaking changes before they are released to retail. Retail builds should set this value to false. + */ + IsOSPreview?: boolean; + /** The Linux instrumentation configuration for this build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The type of game server being hosted. */ + ServerType?: string; + /** + * The command to run when the multiplayer server is started, including any arguments. The path to any executable is + * relative to the root asset folder when unzipped. + */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby. At most 30 key-value pairs may be stored + * here, keys are limited to 30 characters and values to 1000. The total size of all lobbyData values may not exceed 4096 + * bytes. Keys are case sensitive. + */ + LobbyData?: { [key: string]: string | null }; + /** The maximum number of players allowed in the lobby. The value must be between 2 and 128. */ + MaxPlayers: number; + /** + * The member initially added to the lobby. Client must specify exactly one member, which is the creator's entity and + * member data. Member PubSubConnectionHandle must be null or empty. Game servers must not specify any members. + */ + Members?: Member[]; + /** The lobby owner. Must be the calling entity. */ + Owner: EntityKey; + /** + * The policy for how a new owner is chosen. May be 'Automatic', 'Manual' or 'None'. Can only be specified by clients. If + * client-owned and 'Automatic' - The Lobby service will automatically assign another connected owner when the current + * owner leaves or disconnects. The useConnections property must be true. If client - owned and 'Manual' - Ownership is + * protected as long as the current owner is connected. If the current owner leaves or disconnects any member may set + * themselves as the current owner. The useConnections property must be true. If client-owned and 'None' - Any member can + * set ownership. The useConnections property can be either true or false. + */ + OwnerMigrationPolicy?: string; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Defaults to false if not specified. + * Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner: boolean; + /** + * The public key-value pairs which allow queries to differentiate between lobbies. Queries will refer to these key-value + * pairs in their filter and order by clauses to retrieve lobbies fitting the specified criteria. At most 30 key-value + * pairs may be stored here. Keys are of the format string_key1, string_key2 ... string_key30 for string values, or + * number_key1, number_key2, ... number_key30 for numeric values.Numeric values are floats. Values can be at most 256 + * characters long. The total size of all searchData values may not exceed 1024 bytes. + */ + SearchData?: { [key: string]: string | null }; + /** + * A setting to control whether connections are used. Defaults to true. When true, notifications are sent to subscribed + * players, disconnect detection removes connectionHandles, only owner migration policies using connections are allowed, + * and lobbies must have at least one connected member to be searchable or be a server hosted lobby with a connected + * server. If false, then notifications are not sent, connections are not allowed, and lobbies do not need connections to + * be searchable. + */ + UseConnections: boolean; + + } + + export interface CreateLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** A field which indicates which lobby the user will be joining. */ + ConnectionString: string; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + + } + + export interface CreateMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The User who created this ticket. */ + Creator: MatchmakingPlayer; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** A list of Entity Keys of other users to match with. */ + MembersToMatchWith?: EntityKey[]; + /** The Id of a match queue. */ + QueueName: string; + + } + + export interface CreateMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CreateRemoteUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of to create the remote user for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The expiration time for the remote user created. Defaults to expiring in one day if not specified. */ + ExpirationTime?: string; + /** The region of virtual machine to create the remote user for. */ + Region: string; + /** The username to create the remote user with. */ + Username: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface CreateRemoteUserResponse extends PlayFabModule.IPlayFabResultCommon { + /** The expiration time for the remote user created. */ + ExpirationTime?: string; + /** The generated password for the remote user that was created. */ + Password?: string; + /** The username for the remote user that was created. */ + Username?: string; + + } + + export interface CreateServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The users who will be part of this ticket, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** The Id of a match queue. */ + QueueName: string; + /** The details of the server the members are connected to. */ + ServerDetails?: ServerDetails; + + } + + export interface CreateServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CreateServerMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The users who will be part of this ticket. */ + Members: MatchmakingPlayer[]; + /** The Id of a match queue. */ + QueueName: string; + + } + + export interface CreateTitleMultiplayerServersQuotaChangeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A brief description of the requested changes. */ + ChangeDescription?: string; + /** Changes to make to the titles cores quota. */ + Changes: CoreCapacityChange[]; + /** Email to be contacted by our team about this request. Only required when a request is not approved. */ + ContactEmail?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Additional information about this request that our team can use to better understand the requirements. */ + Notes?: string; + /** When these changes would need to be in effect. Only required when a request is not approved. */ + StartDate?: string; + + } + + export interface CreateTitleMultiplayerServersQuotaChangeResponse extends PlayFabModule.IPlayFabResultCommon { + /** Id of the change request that was created. */ + RequestId?: string; + /** Determines if the request was approved or not. When false, our team is reviewing and may respond within 2 business days. */ + WasApproved: boolean; + + } + + export interface CurrentServerStats { + /** The number of active multiplayer servers. */ + Active: number; + /** The number of multiplayer servers still downloading game resources (such as assets). */ + Propping: number; + /** The number of standingby multiplayer servers. */ + StandingBy: number; + /** The total number of multiplayer servers. */ + Total: number; + + } + + export interface CustomDifferenceRuleExpansion { + /** Manually specify the values to use for each expansion interval (this overrides Difference, Delta, and MaxDifference). */ + DifferenceOverrides: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomRegionSelectionRuleExpansion { + /** Manually specify the maximum latency to use for each expansion interval. */ + MaxLatencyOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomSetIntersectionRuleExpansion { + /** Manually specify the values to use for each expansion interval. */ + MinIntersectionSizeOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomTeamDifferenceRuleExpansion { + /** Manually specify the team difference value to use for each expansion interval. */ + DifferenceOverrides: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomTeamSizeBalanceRuleExpansion { + /** Manually specify the team size difference to use for each expansion interval. */ + DifferenceOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface DeleteAssetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The filename of the asset to delete. */ + FileName: string; + + } + + export interface DeleteBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias ID of the alias to perform the action on. */ + AliasId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface DeleteBuildRegionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The build region to delete. */ + Region: string; + + } + + export interface DeleteBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the build to delete. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface DeleteCertificateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the certificate. */ + Name: string; + + } + + export interface DeleteContainerImageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container image repository we want to delete. */ + ImageName?: string; + + } + + export interface DeleteLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + + } + + export interface DeleteRemoteUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer server where the remote user is to delete. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The region of the multiplayer server where the remote user is to delete. */ + Region: string; + /** The username of the remote user to delete. */ + Username: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface DeleteSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the secret. */ + Name: string; + + } + + export interface DifferenceRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, Difference is ignored. + */ + CustomExpansion?: CustomDifferenceRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). Optional. + */ + DefaultAttributeValue?: number; + /** The allowed difference between any two tickets at the start of matchmaking. */ + Difference: number; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearDifferenceRuleExpansion; + /** How values are treated when there are multiple players in a single ticket. */ + MergeFunction: string; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + type DirectPeerConnectivityOptions = "None" + + | "SamePlatformType" + | "DifferentPlatformType" + | "AnyPlatformType" + | "SameEntityLoginProvider" + | "DifferentEntityLoginProvider" + | "AnyEntityLoginProvider" + | "AnyPlatformTypeAndEntityLoginProvider" + | "OnlyServers"; + + export interface DynamicStandbySettings { + /** + * List of auto standing by trigger values and corresponding standing by multiplier. Defaults to 1.5X at 50%, 3X at 25%, + * and 4X at 5% + */ + DynamicFloorMultiplierThresholds?: DynamicStandbyThreshold[]; + /** When true, dynamic standby will be enabled */ + IsEnabled: boolean; + /** The time it takes to reduce target standing by to configured floor value after an increase. Defaults to 30 minutes */ + RampDownSeconds?: number; + + } + + export interface DynamicStandbyThreshold { + /** When the trigger threshold is reached, multiply by this value */ + Multiplier: number; + /** The multiplier will be applied when the actual standby divided by target standby floor is less than this value */ + TriggerThresholdPercentage: number; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EnableMultiplayerServersForTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface EnableMultiplayerServersForTitleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The enabled status for the multiplayer server features for the title. */ + Status?: string; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FindFriendLobbiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Indicates which other platforms' friends this query should link to. */ + ExternalPlatformFriends?: string; + /** + * OData style string that contains one or more filters. Only the following operators are supported: "and" (logical and), + * "eq" (equal), "ne" (not equals), "ge" (greater than or equal), "gt" (greater than), "le" (less than or equal), and "lt" + * (less than). The left-hand side of each OData logical expression should be either a search property key (e.g. + * string_key1, number_key3, etc) or one of the pre-defined search keys all of which must be prefixed by "lobby/": + * lobby/memberCount (number of players in a lobby), lobby/maxMemberCount (maximum number of players allowed in a lobby), + * lobby/memberCountRemaining (remaining number of players who can be allowed in a lobby), lobby/membershipLock (must equal + * 'Unlocked' or 'Locked'), lobby/amOwner (required to equal "true"), lobby/amMember (required to equal "true"). + */ + Filter?: string; + /** + * OData style string that contains sorting for this query in either ascending ("asc") or descending ("desc") order. + * OrderBy clauses are of the form "number_key1 asc" or the pre-defined search key "lobby/memberCount asc", + * "lobby/memberCountRemaining desc" and "lobby/maxMemberCount desc". To sort by closest, a moniker `distance{number_key1 = + * 5}` can be used to sort by distance from the given number. This field only supports either one sort clause or one + * distance clause. + */ + OrderBy?: string; + /** Request pagination information. */ + Pagination?: PaginationRequest; + /** + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. Only mutual Xbox Live friends + * (where both users follow each other) are included, unlike GetFriendsList which includes all users the caller is + * following. + */ + XboxToken?: string; + + } + + export interface FindFriendLobbiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of lobbies found that matched FindFriendLobbies request. */ + Lobbies: FriendLobbySummary[]; + /** Pagination response for FindFriendLobbies request. */ + Pagination: PaginationResponse; + + } + + export interface FindLobbiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * OData style string that contains one or more filters. Only the following operators are supported: "and" (logical and), + * "eq" (equal), "ne" (not equals), "ge" (greater than or equal), "gt" (greater than), "le" (less than or equal), and "lt" + * (less than). The left-hand side of each OData logical expression should be either a search property key (e.g. + * string_key1, number_key3, etc) or one of the pre-defined search keys all of which must be prefixed by "lobby/": + * lobby/memberCount (number of players in a lobby), lobby/maxMemberCount (maximum number of players allowed in a lobby), + * lobby/memberCountRemaining (remaining number of players who can be allowed in a lobby), lobby/membershipLock (must equal + * 'Unlocked' or 'Locked'), lobby/amOwner (required to equal "true"), lobby/amMember (required to equal "true"). + */ + Filter?: string; + /** + * OData style string that contains sorting for this query in either ascending ("asc") or descending ("desc") order. + * OrderBy clauses are of the form "number_key1 asc" or the pre-defined search key "lobby/memberCount asc", + * "lobby/memberCountRemaining desc" and "lobby/maxMemberCount desc". To sort by closest, a moniker `distance{number_key1 = + * 5}` can be used to sort by distance from the given number. This field only supports either one sort clause or one + * distance clause. + */ + OrderBy?: string; + /** Request pagination information. */ + Pagination?: PaginationRequest; + + } + + export interface FindLobbiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of lobbies found that matched FindLobbies request. */ + Lobbies: LobbySummary[]; + /** Pagination response for FindLobbies request. */ + Pagination: PaginationResponse; + + } + + export interface FriendLobbySummary { + /** + * A string used to join the lobby.This field is populated by the Lobby service.Invites are performed by communicating this + * connectionString to other players. + */ + ConnectionString: string; + /** The current number of players in the lobby. */ + CurrentPlayers: number; + /** Friends in Lobby. */ + Friends?: EntityKey[]; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock?: string; + /** The client or server entity which owns this lobby. */ + Owner: EntityKey; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + + } + + export interface GameCertificateReference { + /** + * An alias for the game certificate. The game server will reference this alias via GSDK config to retrieve the game + * certificate. This alias is used as an identifier in game server code to allow a new certificate with different Name + * field to be uploaded without the need to change any game server code to reference the new Name. + */ + GsdkAlias?: string; + /** + * The name of the game certificate. This name should match the name of a certificate that was previously uploaded to this + * title. + */ + Name?: string; + + } + + export interface GameCertificateReferenceParams { + /** + * An alias for the game certificate. The game server will reference this alias via GSDK config to retrieve the game + * certificate. This alias is used as an identifier in game server code to allow a new certificate with different Name + * field to be uploaded without the need to change any game server code to reference the new Name. + */ + GsdkAlias: string; + /** + * The name of the game certificate. This name should match the name of a certificate that was previously uploaded to this + * title. + */ + Name: string; + + } + + export interface GameSecretReference { + /** The name of the game secret. This name should match the name of a secret that was previously added to this title. */ + Name?: string; + + } + + export interface GameSecretReferenceParams { + /** The name of the game secret. This name should match the name of a secret that was previously added to this title. */ + Name: string; + + } + + export interface GetAssetDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The asset's file name to get the download URL for. */ + FileName: string; + + } + + export interface GetAssetDownloadUrlResponse extends PlayFabModule.IPlayFabResultCommon { + /** The asset's download URL. */ + AssetDownloadUrl?: string; + /** The asset's file name to get the download URL for. */ + FileName?: string; + + } + + export interface GetAssetUploadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The asset's file name to get the upload URL for. */ + FileName: string; + + } + + export interface GetAssetUploadUrlResponse extends PlayFabModule.IPlayFabResultCommon { + /** The asset's upload URL. */ + AssetUploadUrl?: string; + /** The asset's file name to get the upload URL for. */ + FileName?: string; + + } + + export interface GetBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias ID of the alias to perform the action on. */ + AliasId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the build to get. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetBuildResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID of the build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The current build status. Valid values are - Deploying, Deployed, DeletingRegion, Unhealthy. */ + BuildStatus?: string; + /** The flavor of container of he build. */ + ContainerFlavor?: string; + /** + * The container command to run when the multiplayer server has been allocated, including any arguments. This only applies + * to custom builds. If the build is a managed build, this field will be null. + */ + ContainerRunCommand?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The custom game container image for a custom build. */ + CustomGameContainerImage?: ContainerImageReference; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** The instrumentation configuration of the build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Metadata of the build. The keys are case insensitive. The build metadata is made available to the server through Game + * Server SDK (GSDK). + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to hosted on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM. */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** + * The command to run when the multiplayer server has been allocated, including any arguments. This only applies to managed + * builds. If the build is a custom build, this field will be null. + */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface GetContainerRegistryCredentialsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetContainerRegistryCredentialsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The url of the container registry. */ + DnsName?: string; + /** The password for accessing the container registry. */ + Password?: string; + /** The username for accessing the container registry. */ + Username?: string; + + } + + export interface GetLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + + } + + export interface GetLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** The information pertaining to the requested lobby. */ + Lobby: Lobby; + + } + + export interface GetMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Id of the matchmaking queue to retrieve. */ + QueueName?: string; + + } + + export interface GetMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + /** The matchmaking queue config. */ + MatchmakingQueue?: MatchmakingQueueConfig; + + } + + export interface GetMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The name of the queue to find a match for. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** + * The reason why the current ticket was canceled. This field is only set if the ticket is in canceled state. Please retry + * if CancellationReason is RetryRequired. + */ + CancellationReasonString?: string; + /** Change number used for differentiating older matchmaking status updates from newer ones. */ + ChangeNumber?: number; + /** The server date and time at which ticket was created. */ + Created: string; + /** The Creator's entity key. */ + Creator: EntityKey; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The Id of a match. */ + MatchId?: string; + /** A list of Users that have joined this ticket. */ + Members: MatchmakingPlayer[]; + /** A list of PlayFab Ids of Users to match with. */ + MembersToMatchWith?: EntityKey[]; + /** The Id of a match queue. */ + QueueName: string; + /** + * The current ticket status. Possible values are: WaitingForPlayers, WaitingForMatch, WaitingForServer, Canceled and + * Matched. + */ + Status: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetMatchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The Id of a match. */ + MatchId: string; + /** The name of the queue to join. */ + QueueName: string; + /** Determines whether the matchmaking attributes for each user should be returned in the response for match request. */ + ReturnMemberAttributes: boolean; + + } + + export interface GetMatchResult extends PlayFabModule.IPlayFabResultCommon { + /** A string that is used by players that are matched together to join an arranged lobby. */ + ArrangementString?: string; + /** The Id of a match. */ + MatchId: string; + /** A list of Users that are matched together, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** + * A list of regions that the match could be played in sorted by preference. This value is only set if the queue has a + * region selection rule. + */ + RegionPreferences?: string[]; + /** The details of the server that the match has been allocated to. */ + ServerDetails?: ServerDetails; + + } + + export interface GetMultiplayerServerDetailsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The title generated guid string session ID of the multiplayer server to get details for. This is to keep track of + * multiplayer server sessions. + */ + SessionId: string; + + } + + export interface GetMultiplayerServerDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The identity of the build in which the server was allocated. */ + BuildId?: string; + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + FQDN?: string; + /** The public IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The list of public Ipv4 addresses associated with the server. */ + PublicIPV4Addresses?: PublicIpAddress[]; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + export interface GetMultiplayerServerLogsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The server ID of multiplayer server to get logs for. */ + ServerId: string; + + } + + export interface GetMultiplayerServerLogsResponse extends PlayFabModule.IPlayFabResultCommon { + /** URL for logs download. */ + LogDownloadUrl?: string; + + } + + export interface GetMultiplayerSessionLogsBySessionIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The server ID of multiplayer server to get logs for. */ + SessionId: string; + + } + + export interface GetQueueStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue. */ + QueueName: string; + + } + + export interface GetQueueStatisticsResult extends PlayFabModule.IPlayFabResultCommon { + /** The current number of players in the matchmaking queue, who are waiting to be matched. */ + NumberOfPlayersMatching?: number; + /** Statistics representing the time (in seconds) it takes for tickets to find a match. */ + TimeToMatchStatisticsInSeconds?: Statistics; + + } + + export interface GetRemoteLoginEndpointRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer server to get remote login information for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The region of the multiplayer server to get remote login information for. */ + Region: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface GetRemoteLoginEndpointResponse extends PlayFabModule.IPlayFabResultCommon { + /** The remote login IPV4 address of multiplayer server. */ + IPV4Address?: string; + /** The remote login port of multiplayer server. */ + Port: number; + + } + + export interface GetServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The name of the queue to find a match for. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The reason why the current ticket was canceled. This field is only set if the ticket is in canceled state. */ + CancellationReasonString?: string; + /** The server date and time at which ticket was created. */ + Created: string; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The Id of a match. */ + MatchId?: string; + /** A list of Users that are part of this ticket, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** The Id of a match queue. */ + QueueName: string; + /** The details of the server the members are connected to. */ + ServerDetails: ServerDetails; + /** The current ticket status. Possible values are: WaitingForMatch, Canceled and Matched. */ + Status: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetTitleEnabledForMultiplayerServersStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetTitleEnabledForMultiplayerServersStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** The enabled status for the multiplayer server features for the title. */ + Status?: string; + + } + + export interface GetTitleMultiplayerServersQuotaChangeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the change request to get. */ + RequestId: string; + + } + + export interface GetTitleMultiplayerServersQuotaChangeResponse extends PlayFabModule.IPlayFabResultCommon { + /** The change request for this title. */ + Change?: QuotaChange; + + } + + export interface GetTitleMultiplayerServersQuotasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetTitleMultiplayerServersQuotasResponse extends PlayFabModule.IPlayFabResultCommon { + /** The various quotas for multiplayer servers for the title. */ + Quotas?: TitleMultiplayerServersQuotas; + + } + + export interface InstrumentationConfiguration { + /** Designates whether windows instrumentation configuration will be enabled for this Build */ + IsEnabled?: boolean; + /** + * This property is deprecated, use IsEnabled. The list of processes to be monitored on a VM for this build. Providing + * processes will turn on performance metrics collection for this build. Process names should not include extensions. If + * the game server process is: GameServer.exe; then, ProcessesToMonitor = [ GameServer ] + */ + ProcessesToMonitor?: string[]; + + } + + export interface InviteToLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity invited to the lobby. */ + InviteeEntity?: EntityKey; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity sending the invite. Must be a member of the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface JoinArrangedLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** + * A field which indicates which lobby the user will be joining. This field is opaque to everyone except the Lobby service + * and the creator of the arrangementString (Matchmaking). This string defines a unique identifier for the arranged lobby + * as well as the title and member the string is valid for. Arrangement strings have an expiration. + */ + ArrangementString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The maximum number of players allowed in the lobby. The value must be between 2 and 128. */ + MaxPlayers: number; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Visible to all + * entities in the lobby. At most 30 key-value pairs may be stored here, keys are limited to 30 characters and values to + * 1000. The total size of all memberData values may not exceed 4096 bytes. Keys are case sensitive. + */ + MemberData?: { [key: string]: string | null }; + /** The member entity who is joining the lobby. The first member to join will be the lobby owner. */ + MemberEntity: EntityKey; + /** + * The policy for how a new owner is chosen. May be 'Automatic', 'Manual' or 'None'. Can only be specified by clients. If + * client-owned and 'Automatic' - The Lobby service will automatically assign another connected owner when the current + * owner leaves or disconnects. The useConnections property must be true. If client - owned and 'Manual' - Ownership is + * protected as long as the current owner is connected. If the current owner leaves or disconnects any member may set + * themselves as the current owner. The useConnections property must be true. If client-owned and 'None' - Any member can + * set ownership. The useConnections property can be either true or false. + */ + OwnerMigrationPolicy?: string; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Defaults to false if not specified. + * Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner: boolean; + /** + * A setting to control whether connections are used. Defaults to true. When true, notifications are sent to subscribed + * players, disconnect detection removes connectionHandles, only owner migration policies using connections are allowed, + * and lobbies must have at least one connected member to be searchable or be a server hosted lobby with a connected + * server. If false, then notifications are not sent, connections are not allowed, and lobbies do not need connections to + * be searchable. + */ + UseConnections: boolean; + + } + + export interface JoinLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * A field which indicates which lobby the game_server will be joining. This field is opaque to everyone except the Lobby + * service. + */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby but can only be modified by the joined + * server.At most 30 key - value pairs may be stored here, keys are limited to 30 characters and values to 1000.The total + * size of all serverData values may not exceed 4096 bytes. + */ + ServerData?: { [key: string]: string | null }; + /** + * The game_server entity which is joining the Lobby. If a different game_server entity has already joined the request will + * fail unless the joined entity is disconnected, in which case the incoming game_server entity will replace the + * disconnected entity. + */ + ServerEntity: EntityKey; + + } + + export interface JoinLobbyAsServerResult extends PlayFabModule.IPlayFabResultCommon { + /** Successfully joined lobby's id. */ + LobbyId: string; + + } + + export interface JoinLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A field which indicates which lobby the user will be joining. This field is opaque to everyone except the Lobby service. */ + ConnectionString?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Visible to all + * entities in the lobby. At most 30 key-value pairs may be stored here, keys are limited to 30 characters and values to + * 1000. The total size of all memberData values may not exceed 4096 bytes.Keys are case sensitive. + */ + MemberData?: { [key: string]: string | null }; + /** The member entity who is joining the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface JoinLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** Successfully joined lobby's id. */ + LobbyId: string; + + } + + export interface JoinMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The User who wants to join the ticket. Their Id must be listed in PlayFabIdsToMatchWith. */ + Member: MatchmakingPlayer; + /** The name of the queue to join. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface JoinMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LeaveLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId: string; + /** + * The game_server entity leaving the lobby. If the game_server was subscribed to notifications, it will be unsubscribed. + * If a the given game_server entity is not in the lobby, it will fail. + */ + ServerEntity: EntityKey; + + } + + export interface LeaveLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity leaving the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface LinearDifferenceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearRegionSelectionRuleExpansion { + /** This value gets added to MaxLatency at every expansion interval. */ + Delta: number; + /** Once the max Latency reaches this value, expansion stops. */ + Limit: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearSetIntersectionRuleExpansion { + /** This value gets added to MinIntersectionSize at every expansion interval. */ + Delta: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearTeamDifferenceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearTeamSizeBalanceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinuxInstrumentationConfiguration { + /** Designates whether Linux instrumentation configuration will be enabled for this Build */ + IsEnabled: boolean; + + } + + export interface ListAssetSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListAssetSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of asset summaries. */ + AssetSummaries?: AssetSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListBuildAliasesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListBuildAliasesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of build aliases for the title */ + BuildAliases?: BuildAliasDetailsResponse[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListBuildSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListBuildSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of build summaries for a title. */ + BuildSummaries?: BuildSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListCertificateSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListCertificateSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of game certificates. */ + CertificateSummaries?: CertificateSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListContainerImagesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListContainerImagesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of container images. */ + Images?: string[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListContainerImageTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container images we want to list tags for. */ + ImageName?: string; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListContainerImageTagsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** The list of tags for a particular container image. */ + Tags?: string[]; + + } + + export interface ListMatchmakingQueuesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListMatchmakingQueuesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of matchmaking queue configs for this title. */ + MatchMakingQueues?: MatchmakingQueueConfig[]; + + } + + export interface ListMatchmakingTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the queue to find a match for. */ + QueueName: string; + + } + + export interface ListMatchmakingTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of ticket Ids the user is a member of. */ + TicketIds: string[]; + + } + + export interface ListMultiplayerServersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer servers to list. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The region the multiplayer servers to list. */ + Region: string; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListMultiplayerServersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of multiplayer server summary details. */ + MultiplayerServerSummaries?: MultiplayerServerSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListPartyQosServersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListPartyQosServersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of QoS servers. */ + QosServers?: QosServer[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListQosServersForTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates that the response should contain Qos servers for all regions, including those where there are no builds + * deployed for the title. + */ + IncludeAllRegions?: boolean; + /** Indicates the Routing Preference used by the Qos servers. The default Routing Preference is Microsoft */ + RoutingPreference?: string; + + } + + export interface ListQosServersForTitleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of QoS servers. */ + QosServers?: QosServer[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListSecretSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListSecretSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of game secret. */ + SecretSummaries?: SecretSummary[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListServerBackfillTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The name of the queue the tickets are in. */ + QueueName: string; + + } + + export interface ListServerBackfillTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of backfill ticket Ids the user is a member of. */ + TicketIds: string[]; + + } + + export interface ListTitleMultiplayerServersQuotaChangesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListTitleMultiplayerServersQuotaChangesResponse extends PlayFabModule.IPlayFabResultCommon { + /** All change requests for this title. */ + Changes?: QuotaChange[]; + + } + + export interface ListVirtualMachineSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the virtual machines to list. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The region of the virtual machines to list. */ + Region: string; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListVirtualMachineSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** The list of virtual machine summaries. */ + VirtualMachines?: VirtualMachineSummary[]; + + } + + export interface Lobby { + /** A setting indicating who is allowed to join this lobby, as well as see it in queries. */ + AccessPolicy: string; + /** A number that increments once for each request that modifies the lobby. */ + ChangeNumber: number; + /** + * A string used to join the lobby. This field is populated by the Lobby service. Invites are performed by communicating + * this connectionString to other players. + */ + ConnectionString: string; + /** Lobby data. */ + LobbyData?: { [key: string]: string | null }; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** Array of all lobby members. */ + Members?: Member[]; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock: string; + /** The client or server entity which owns this lobby. */ + Owner?: EntityKey; + /** A setting indicating the owner migration policy. If server owned, this field is not present. */ + OwnerMigrationPolicy?: string; + /** + * An opaque string stored on a SubscribeToLobbyResource call, which indicates the connection an owner or member has with + * PubSub. + */ + PubSubConnectionHandle?: string; + /** + * A setting that controls lobby invites. When true only owners can invite new players, when false all members area allowed + * to invite. + */ + RestrictInvitesToLobbyOwner: boolean; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + /** Preview: Lobby joined server. This is not the server owner, rather the server that has joined a client owned lobby. */ + Server?: LobbyServer; + /** A flag which determines if connections are used. Defaults to true. Only set on create. */ + UseConnections: boolean; + + } + + export interface LobbyEmptyResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LobbyServer { + /** Opaque string, stored on a Subscribe call, which indicates the connection a joined server has with PubSub. */ + PubSubConnectionHandle?: string; + /** Key-value pairs specific to the joined server. */ + ServerData?: { [key: string]: string | null }; + /** The server entity key. */ + ServerEntity?: EntityKey; + + } + + export interface LobbySummary { + /** + * A string used to join the lobby.This field is populated by the Lobby service.Invites are performed by communicating this + * connectionString to other players. + */ + ConnectionString: string; + /** The current number of players in the lobby. */ + CurrentPlayers: number; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock?: string; + /** The client or server entity which owns this lobby. */ + Owner: EntityKey; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + + } + + export interface MatchmakingPlayer { + /** The user's attributes custom to the title. */ + Attributes?: MatchmakingPlayerAttributes; + /** The entity key of the matchmaking user. */ + Entity: EntityKey; + + } + + export interface MatchmakingPlayerAttributes { + /** A data object representing a user's attributes. */ + DataObject?: any; + /** An escaped data object representing a user's attributes. */ + EscapedDataObject?: string; + + } + + export interface MatchmakingPlayerWithTeamAssignment { + /** + * The user's attributes custom to the title. These attributes will be null unless the request has ReturnMemberAttributes + * flag set to true. + */ + Attributes?: MatchmakingPlayerAttributes; + /** The entity key of the matchmaking user. */ + Entity: EntityKey; + /** The Id of the team the User is assigned to. */ + TeamId?: string; + + } + + export interface MatchmakingQueueConfig { + /** This is the buildAlias that will be used to allocate the multiplayer server for the match. */ + BuildAliasParams?: BuildAliasParams; + /** This is the buildId that will be used to allocate the multiplayer server for the match. */ + BuildId?: string; + /** List of difference rules used to find an optimal match. */ + DifferenceRules?: DifferenceRule[]; + /** List of match total rules used to find an optimal match. */ + MatchTotalRules?: MatchTotalRule[]; + /** Maximum number of players in a match. */ + MaxMatchSize: number; + /** Maximum number of players in a ticket. Optional. */ + MaxTicketSize?: number; + /** Minimum number of players in a match. */ + MinMatchSize: number; + /** Unique identifier for a Queue. Chosen by the developer. */ + Name: string; + /** Region selection rule used to find an optimal match. */ + RegionSelectionRule?: RegionSelectionRule; + /** Boolean flag to enable server allocation for the queue. */ + ServerAllocationEnabled: boolean; + /** List of set intersection rules used to find an optimal match. */ + SetIntersectionRules?: SetIntersectionRule[]; + /** Controls which statistics are visible to players. */ + StatisticsVisibilityToPlayers?: StatisticsVisibilityToPlayers; + /** List of string equality rules used to find an optimal match. */ + StringEqualityRules?: StringEqualityRule[]; + /** List of team difference rules used to find an optimal match. */ + TeamDifferenceRules?: TeamDifferenceRule[]; + /** The team configuration for a match. This may be null if there are no teams. */ + Teams?: MatchmakingQueueTeam[]; + /** Team size balance rule used to find an optimal match. */ + TeamSizeBalanceRule?: TeamSizeBalanceRule; + /** Team ticket size similarity rule used to find an optimal match. */ + TeamTicketSizeSimilarityRule?: TeamTicketSizeSimilarityRule; + + } + + export interface MatchmakingQueueTeam { + /** The maximum number of players required for the team. */ + MaxTeamSize: number; + /** The minimum number of players required for the team. */ + MinTeamSize: number; + /** A name to identify the team. This is case insensitive. */ + Name: string; + + } + + export interface MatchTotalRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** Collection of fields relating to expanding this rule at set intervals. */ + Expansion?: MatchTotalRuleExpansion; + /** The maximum total value for a group. Must be >= Min. */ + Max: number; + /** The minimum total value for a group. Must be >=2. */ + Min: number; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface MatchTotalRuleExpansion { + /** Manually specify the values to use for each expansion interval. When this is set, Max is ignored. */ + MaxOverrides?: OverrideDouble[]; + /** Manually specify the values to use for each expansion interval. When this is set, Min is ignored. */ + MinOverrides?: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface Member { + /** Key-value pairs specific to member. */ + MemberData?: { [key: string]: string | null }; + /** The member entity key. */ + MemberEntity?: EntityKey; + /** Opaque string, stored on a Subscribe call, which indicates the connection an owner or member has with PubSub. */ + PubSubConnectionHandle?: string; + + } + + type MembershipLock = "Unlocked" + + | "Locked"; + + export interface MultiplayerServerSummary { + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The title generated guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + type OsPlatform = "Windows" + + | "Linux"; + + export interface OverrideDouble { + /** The custom expansion value. */ + Value: number; + + } + + export interface OverrideUnsignedInt { + /** The custom expansion value. */ + Value: number; + + } + + type OwnerMigrationPolicy = "None" + + | "Automatic" + | "Manual" + | "Server"; + + export interface PaginationRequest { + /** Continuation token returned as a result in a previous FindLobbies call. Cannot be specified by clients. */ + ContinuationToken?: string; + /** The number of lobbies that should be retrieved. Cannot be specified by servers, clients may specify any value up to 50 */ + PageSizeRequested?: number; + + } + + export interface PaginationResponse { + /** Continuation token returned by server call. Not returned for clients */ + ContinuationToken?: string; + /** The number of lobbies that matched the search request. */ + TotalMatchedLobbyCount?: number; + + } + + export interface PartyInvitationConfiguration { + /** + * The list of PlayFab EntityKeys that the invitation allows to authenticate into the network. If this list is empty, all + * users are allowed to authenticate using the invitation's identifier. This list may contain no more than 1024 items. + */ + EntityKeys?: EntityKey[]; + /** The invite identifier for this party. If this value is specified, it must be no longer than 127 characters. */ + Identifier?: string; + /** Controls which participants can revoke this invite. */ + Revocability?: string; + + } + + type PartyInvitationRevocability = "Creator" + + | "Anyone"; + + export interface PartyNetworkConfiguration { + /** Controls whether and how to support direct peer-to-peer connection attempts among devices in the network. */ + DirectPeerConnectivityOptions?: string; + /** The maximum number of devices allowed to connect to the network. Must be between 1 and 128, inclusive. */ + MaxDevices: number; + /** The maximum number of devices allowed per user. Must be greater than 0. */ + MaxDevicesPerUser: number; + /** The maximum number of endpoints allowed per device. Must be between 0 and 32, inclusive. */ + MaxEndpointsPerDevice: number; + /** The maximum number of unique users allowed in the network. Must be greater than 0. */ + MaxUsers: number; + /** The maximum number of users allowed per device. Must be between 1 and 8, inclusive. */ + MaxUsersPerDevice: number; + /** + * An optionally-specified configuration for the initial invitation for this party. If not provided, default configuration + * values will be used: a title-unique invitation identifier will be generated, the revocability will be Anyone, and the + * EntityID list will be empty. + */ + PartyInvitationConfiguration?: PartyInvitationConfiguration; + + } + + export interface Port { + /** The name for the port. */ + Name: string; + /** The number for the port. */ + Num: number; + /** The protocol for the port. */ + Protocol: string; + + } + + type ProtocolType = "TCP" + + | "UDP"; + + export interface PublicIpAddress { + /** FQDN of the public IP */ + FQDN: string; + /** Server IP Address */ + IpAddress: string; + /** Routing Type of the public IP. */ + RoutingType: string; + + } + + export interface QosServer { + /** The region the QoS server is located in. */ + Region?: string; + /** The QoS server URL. */ + ServerUrl?: string; + + } + + export interface QueueRuleAttribute { + /** Specifies which attribute in a ticket to use. */ + Path: string; + /** Specifies which source the attribute comes from. */ + Source: string; + + } + + export interface QuotaChange { + /** A brief description of the requested changes. */ + ChangeDescription?: string; + /** Requested changes to make to the titles cores quota. */ + Changes?: CoreCapacityChange[]; + /** Whether or not this request is pending a review. */ + IsPendingReview: boolean; + /** Additional information about this request that our team can use to better understand the requirements. */ + Notes?: string; + /** Id of the change request. */ + RequestId?: string; + /** Comments by our team when a request is reviewed. */ + ReviewComments?: string; + /** Whether or not this request was approved. */ + WasApproved: boolean; + + } + + export interface RegionSelectionRule { + /** + * Controls how the Max Latency parameter expands over time. Only one expansion can be set per rule. When this is set, + * MaxLatency is ignored. + */ + CustomExpansion?: CustomRegionSelectionRuleExpansion; + /** Controls how the Max Latency parameter expands over time. Only one expansion can be set per rule. */ + LinearExpansion?: LinearRegionSelectionRuleExpansion; + /** Specifies the maximum latency that is allowed between the client and the selected server. The value is in milliseconds. */ + MaxLatency: number; + /** Friendly name chosen by developer. */ + Name: string; + /** Specifies which attribute in a ticket to use. */ + Path: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface RemoveMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Id of the matchmaking queue to remove. */ + QueueName?: string; + + } + + export interface RemoveMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface RemoveMemberFromLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity to be removed from the lobby. */ + MemberEntity?: EntityKey; + /** If true, removed member can never rejoin this lobby. */ + PreventRejoin: boolean; + + } + + export interface RequestMultiplayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The identifiers of the build alias to use for the request. */ + BuildAliasParams?: BuildAliasParams; + /** The guid string build ID of the multiplayer server to request. */ + BuildId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Initial list of players (potentially matchmade) allowed to connect to the game. This list is passed to the game server + * when requested (via GSDK) and can be used to validate players connecting to it. + */ + InitialPlayers?: string[]; + /** + * The preferred regions to request a multiplayer server from. The Multiplayer Service will iterate through the regions in + * the specified order and allocate a server from the first one that has servers available. + */ + PreferredRegions: string[]; + /** + * Data encoded as a string that is passed to the game server when requested. This can be used to communicate information + * such as game mode or map through the request flow. Maximum size is 8KB + */ + SessionCookie?: string; + /** A guid string session ID created track the multiplayer server session over its life. */ + SessionId: string; + + } + + export interface RequestMultiplayerServerResponse extends PlayFabModule.IPlayFabResultCommon { + /** The identity of the build in which the server was allocated. */ + BuildId?: string; + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + FQDN?: string; + /** The public IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The list of public Ipv4 addresses associated with the server. */ + PublicIPV4Addresses?: PublicIpAddress[]; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + export interface RequestPartyServiceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The network configuration for this request. */ + NetworkConfiguration: PartyNetworkConfiguration; + /** A guid string party ID created track the party session over its life. */ + PartyId?: string; + /** A player entity Id on behalf of whom the request is being made. */ + PlayFabId?: string; + /** + * The preferred regions to request a party session from. The party service will iterate through the regions in the + * specified order and allocate a party session from the first one that is available. + */ + PreferredRegions: string[]; + + } + + export interface RequestPartyServiceResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The invitation identifier supplied in the PartyInvitationConfiguration, or the PlayFab-generated guid if none was + * supplied. + */ + InvitationId?: string; + /** The guid string party ID of the party session. */ + PartyId?: string; + /** The region the party session is located in. */ + Region?: string; + /** A base-64 encoded string containing the serialized network descriptor for this party. */ + SerializedNetworkDescriptor?: string; + + } + + export interface RolloverContainerRegistryCredentialsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface RolloverContainerRegistryCredentialsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The url of the container registry. */ + DnsName?: string; + /** The password for accessing the container registry. */ + Password?: string; + /** The username for accessing the container registry. */ + Username?: string; + + } + + type RoutingType = "Microsoft" + + | "Internet"; + + export interface Schedule { + /** A short description about this schedule. For example, "Game launch on July 15th". */ + Description?: string; + /** + * The date and time in UTC at which the schedule ends. If IsRecurringWeekly is true, this schedule will keep renewing for + * future weeks until disabled or removed. + */ + EndTime: string; + /** Disables the schedule. */ + IsDisabled: boolean; + /** If true, the StartTime and EndTime will get renewed every week. */ + IsRecurringWeekly: boolean; + /** The date and time in UTC at which the schedule starts. */ + StartTime: string; + /** The standby target to maintain for the duration of the schedule. */ + TargetStandby: number; + + } + + export interface ScheduledStandbySettings { + /** When true, scheduled standby will be enabled */ + IsEnabled: boolean; + /** A list of non-overlapping schedules */ + ScheduleList?: Schedule[]; + + } + + export interface Secret { + /** Optional secret expiration date. */ + ExpirationDate?: string; + /** A name for the secret. This is used to reference secrets in build configurations. */ + Name: string; + /** Secret value. */ + Value: string; + + } + + export interface SecretSummary { + /** Optional secret expiration date. */ + ExpirationDate?: string; + /** The name of the secret. */ + Name?: string; + /** The secret version auto-generated after upload. */ + Version?: string; + + } + + export interface ServerDetails { + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + Fqdn?: string; + /** The IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The server's region. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + + } + + export interface ServerResourceConstraintParams { + /** The maximum number of cores that each server is allowed to use. */ + CpuLimit: number; + /** + * The maximum number of GiB of memory that each server is allowed to use. WARNING: After exceeding this limit, the server + * will be killed + */ + MemoryLimitGB: number; + + } + + type ServerType = "Container" + + | "Process"; + + export interface SetIntersectionRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, MinIntersectionSize is ignored. + */ + CustomExpansion?: CustomSetIntersectionRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is UseDefault). Values must be unique. + */ + DefaultAttributeValue?: string[]; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearSetIntersectionRuleExpansion; + /** The minimum number of values that must match between sets. */ + MinIntersectionSize: number; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface SetMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The matchmaking queue config. */ + MatchmakingQueue: MatchmakingQueueConfig; + + } + + export interface SetMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ShutdownMultiplayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** A guid string session ID of the multiplayer server to shut down. */ + SessionId: string; + + } + + export interface Statistics { + /** The average. */ + Average: number; + /** The 50th percentile. */ + Percentile50: number; + /** The 90th percentile. */ + Percentile90: number; + /** The 99th percentile. */ + Percentile99: number; + + } + + export interface StatisticsVisibilityToPlayers { + /** Whether to allow players to view the current number of players in the matchmaking queue. */ + ShowNumberOfPlayersMatching: boolean; + /** Whether to allow players to view statistics representing the time it takes for tickets to find a match. */ + ShowTimeToMatch: boolean; + + } + + export interface StringEqualityRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). + */ + DefaultAttributeValue?: string; + /** + * Collection of fields relating to expanding this rule at set intervals. For StringEqualityRules, this is limited to + * turning the rule off or on during different intervals. + */ + Expansion?: StringEqualityRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface StringEqualityRuleExpansion { + /** List of bools specifying whether the rule is applied during this expansion. */ + EnabledOverrides: boolean[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface SubscribeToLobbyResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the subscription. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** + * The name of the resource to subscribe to. For LobbyChange subscriptions this is the lobbyId. For LobbyInvite + * subscriptions this should always be "@me". + */ + ResourceId: string; + /** Version number for the subscription of this resource. */ + SubscriptionVersion: number; + /** + * Subscription type. "LobbyChange" subscriptions allow a member or owner to receive notifications of lobby data, member or + * owner changes. "LobbyInvite" subscriptions allow a player to receive invites to lobbies. A player does not need to be a + * member of a lobby to receive lobby invites. + */ + Type: string; + + } + + export interface SubscribeToLobbyResourceResult extends PlayFabModule.IPlayFabResultCommon { + /** Topic will be returned in all notifications that are the result of this subscription. */ + Topic: string; + + } + + export interface SubscribeToMatchResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the subscription. The entity must be authorized to use this connectionHandle. */ + EntityKey: EntityKey; + /** + * Opaque string, given to a client upon creating a connection with PubSub. Notifications will be sent to the connection + * associated with this handle. + */ + PubSubConnectionHandle: string; + /** + * The name of the resource to subscribe to. It follows the format {queueName}|{ticketId} for MatchTicketStatusChange. For + * MatchInvite, ResourceId is @me. + */ + ResourceId: string; + /** Version number for the subscription of this resource. Current supported version must be 1. */ + SubscriptionVersion: number; + /** + * Subscription type. MatchInvite subscriptions are per-player. MatchTicketStatusChange subscriptions are per-ticket. + * Subscribe calls are idempotent. Subscribing on the same resource for the same connection results in success. + */ + Type: string; + + } + + export interface SubscribeToMatchResourceResult extends PlayFabModule.IPlayFabResultCommon { + /** Matchmaking resource */ + Topic: string; + + } + + type SubscriptionType = "LobbyChange" + + | "LobbyInvite"; + + export interface TeamDifferenceRule { + /** Description of the attribute used by this rule to match teams. */ + Attribute: QueueRuleAttribute; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, Difference is ignored. + */ + CustomExpansion?: CustomTeamDifferenceRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). + */ + DefaultAttributeValue: number; + /** The allowed difference between any two teams at the start of matchmaking. */ + Difference: number; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearTeamDifferenceRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + export interface TeamSizeBalanceRule { + /** + * Controls how the Difference parameter expands over time. Only one expansion can be set per rule. When this is set, + * Difference is ignored. + */ + CustomExpansion?: CustomTeamSizeBalanceRuleExpansion; + /** The allowed difference in team size between any two teams. */ + Difference: number; + /** Controls how the Difference parameter expands over time. Only one expansion can be set per rule. */ + LinearExpansion?: LinearTeamSizeBalanceRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + export interface TeamTicketSizeSimilarityRule { + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + type TitleMultiplayerServerEnabledStatus = "Initializing" + + | "Enabled" + | "Disabled"; + + export interface TitleMultiplayerServersQuotas { + /** The core capacity for the various regions and VM Family */ + CoreCapacities?: CoreCapacity[]; + + } + + export interface UnsubscribeFromLobbyResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity which performed the subscription. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** The name of the resource to unsubscribe from. */ + ResourceId: string; + /** Version number passed for the subscription of this resource. */ + SubscriptionVersion: number; + /** Subscription type. */ + Type: string; + + } + + export interface UnsubscribeFromMatchResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the unsubscription. The entity must be authorized to use this connectionHandle. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** + * The name of the resource to unsubscribe from. It follows the format {queueName}|{ticketId} for MatchTicketStatusChange. + * For MatchInvite, ResourceId is @me. + */ + ResourceId: string; + /** Version number for the unsubscription from this resource. */ + SubscriptionVersion: number; + /** Type of the subscription to be canceled. */ + Type: string; + + } + + export interface UnsubscribeFromMatchResourceResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UntagContainerImageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container image which tag we want to remove. */ + ImageName?: string; + /** The tag we want to remove. */ + Tag?: string; + + } + + export interface UpdateBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias Id of the alias to be updated. */ + AliasId: string; + /** The alias name. */ + AliasName?: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildNameRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update the name of. */ + BuildId: string; + /** The build name. */ + BuildName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildRegionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The updated region configuration that should be applied to the specified build. */ + BuildRegion: BuildRegionParams; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildRegionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The updated region configuration that should be applied to the specified build. */ + BuildRegions: BuildRegionParams[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId: string; + /** + * The private key-value pairs which are visible to all entities in the lobby and modifiable by the joined server. + * Optional. Sets or updates key-value pairs on the lobby. Only the current lobby lobby server can set serverData. Keys may + * be an arbitrary string of at most 30 characters. The total size of all serverData values may not exceed 4096 bytes. + * Values are not individually limited. There can be up to 30 key-value pairs stored here. Keys are case sensitive. + */ + ServerData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby serverData. Optional. Optional. Deletes key-value pairs on the lobby. Only the current + * joined lobby server can delete serverData. All the specified keys will be removed from the serverData. Keys that do not + * exist in the lobby are a no-op. If the key to delete exists in the serverData (same request) it will result in a bad + * request. + */ + ServerDataToDelete?: string[]; + /** + * The lobby server. Optional. Set a different server as the joined server of the lobby (there can only be 1 joined + * server). When changing the server the previous server will automatically be unsubscribed. + */ + ServerEntity?: EntityKey; + + } + + export interface UpdateLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby. Optional. Sets or updates key-value pairs on + * the lobby. Only the current lobby owner can set lobby data. Keys may be an arbitrary string of at most 30 characters. + * The total size of all lobbyData values may not exceed 4096 bytes. Values are not individually limited. There can be up + * to 30 key-value pairs stored here. Keys are case sensitive. + */ + LobbyData?: { [key: string]: string | null }; + /** The keys to delete from the lobby LobbyData. Optional. Behaves similar to searchDataToDelete, but applies to lobbyData. */ + LobbyDataToDelete?: string[]; + /** The id of the lobby. */ + LobbyId?: string; + /** + * The maximum number of players allowed in the lobby. Updates the maximum allowed number of players in the lobby. Only the + * current lobby owner can set this. If set, the value must be greater than or equal to the number of members currently in + * the lobby. + */ + MaxPlayers?: number; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Optional. Sets + * or updates new key-value pairs on the caller's member data. New keys will be added with their values and existing keys + * will be updated with the new values. Visible to all entities in the lobby. At most 30 key-value pairs may be stored + * here, keys are limited to 30 characters and values to 1000. The total size of all memberData values may not exceed 4096 + * bytes. Keys are case sensitive. Servers cannot specifiy this. + */ + MemberData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby MemberData. Optional. Deletes key-value pairs on the caller's member data. All the + * specified keys will be removed from the caller's member data. Keys that do not exist are a no-op. If the key to delete + * exists in the memberData (same request) it will result in a bad request. Servers cannot specifiy this. + */ + MemberDataToDelete?: string[]; + /** The member entity whose data is being modified. Servers cannot specify this. */ + MemberEntity?: EntityKey; + /** + * A setting indicating whether the lobby is locked. May be 'Unlocked' or 'Locked'. When Locked new members are not allowed + * to join. Defaults to 'Unlocked' on creation. Can only be changed by the lobby owner. + */ + MembershipLock?: string; + /** + * The lobby owner. Optional. Set to transfer ownership of the lobby. If client - owned and 'Automatic' - The Lobby service + * will automatically assign another connected owner when the current owner leaves or disconnects. useConnections must be + * true. If client - owned and 'Manual' - Ownership is protected as long as the current owner is connected. If the current + * owner leaves or disconnects any member may set themselves as the current owner. The useConnections property must be + * true. If client-owned and 'None' - Any member can set ownership. The useConnections property can be either true or + * false. For all client-owned lobbies when the owner leaves and a new owner can not be automatically selected - The owner + * field is set to null. For all client-owned lobbies when the owner disconnects and a new owner can not be automatically + * selected - The owner field remains unchanged and the current owner retains all owner abilities for the lobby. If + * server-owned (must be 'Server') - Any server can set ownership. The useConnections property must be true. + */ + Owner?: EntityKey; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Will not modify current configuration if not + * specified. Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner?: boolean; + /** + * The public key-value pairs which allow queries to differentiate between lobbies. Optional. Sets or updates key-value + * pairs on the lobby for use with queries. Only the current lobby owner can set search data. New keys will be added with + * their values and existing keys will be updated with the new values. There can be up to 30 key-value pairs stored here. + * Keys are of the format string_key1, string_key2... string_key30 for string values, or number_key1, number_key2, ... + * number_key30 for numeric values. Numeric values are floats. Values can be at most 256 characters long. The total size of + * all searchData values may not exceed 1024 bytes.Keys are case sensitive. + */ + SearchData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby SearchData. Optional. Deletes key-value pairs on the lobby. Only the current lobby + * owner can delete search data. All the specified keys will be removed from the search data. Keys that do not exist in the + * lobby are a no-op.If the key to delete exists in the searchData (same request) it will result in a bad request. + */ + SearchDataToDelete?: string[]; + + } + + export interface UploadCertificateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Forces the certificate renewal if the certificate already exists. Default is false */ + ForceUpdate?: boolean; + /** The game certificate to upload. */ + GameCertificate: Certificate; + + } + + export interface UploadSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Forces the secret renewal if the secret already exists. Default is false */ + ForceUpdate?: boolean; + /** The game secret to add. */ + GameSecret: Secret; + + } + + export interface VirtualMachineSummary { + /** The virtual machine health status. */ + HealthStatus?: string; + /** The virtual machine state. */ + State?: string; + /** The virtual machine ID. */ + VmId?: string; + + } + + export interface VmStartupScriptConfiguration { + /** Optional port requests (name/protocol) that will be used by the VmStartupScript. Max of 5 requests. */ + PortRequests?: VmStartupScriptPortRequest[]; + /** Asset which contains the VmStartupScript script and any other required files. */ + VmStartupScriptAssetReference: AssetReference; + + } + + export interface VmStartupScriptParams { + /** Optional port requests (name/protocol) that will be used by the VmStartupScript. Max of 5 requests. */ + PortRequests?: VmStartupScriptPortRequestParams[]; + /** Asset which contains the VmStartupScript script and any other required files. */ + VmStartupScriptAssetReference: AssetReferenceParams; + + } + + export interface VmStartupScriptPortRequest { + /** The name for the port. */ + Name: string; + /** The protocol for the port. */ + Protocol: string; + + } + + export interface VmStartupScriptPortRequestParams { + /** The name for the port. */ + Name: string; + /** The protocol for the port. */ + Protocol: string; + + } + + export interface WindowsCrashDumpConfiguration { + /** See https://docs.microsoft.com/en-us/windows/win32/wer/collecting-user-mode-dumps for valid values. */ + CustomDumpFlags?: number; + /** See https://docs.microsoft.com/en-us/windows/win32/wer/collecting-user-mode-dumps for valid values. */ + DumpType?: number; + /** Designates whether automatic crash dump capturing will be enabled for this Build. */ + IsEnabled: boolean; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabProfilesApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabProfilesApi.d.ts new file mode 100644 index 00000000..ce708bfc --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabProfilesApi.d.ts @@ -0,0 +1,370 @@ +/// + +declare module PlayFabProfilesModule { + export interface IPlayFabProfiles { + ForgetAllCredentials(): void; + + /** + * Gets the global title access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getglobalpolicy + */ + GetGlobalPolicy(request: PlayFabProfilesModels.GetGlobalPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the entity's profile. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getprofile + */ + GetProfile(request: PlayFabProfilesModels.GetEntityProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the entity's profile. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getprofiles + */ + GetProfiles(request: PlayFabProfilesModels.GetEntityProfilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title player accounts associated with the given master player account. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/gettitleplayersfrommasterplayeraccountids + */ + GetTitlePlayersFromMasterPlayerAccountIds(request: PlayFabProfilesModels.GetTitlePlayersFromMasterPlayerAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title player accounts associated with the given XUIDs. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/gettitleplayersfromxboxliveids + */ + GetTitlePlayersFromXboxLiveIDs(request: PlayFabProfilesModels.GetTitlePlayersFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the display name of the entity + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setdisplayname + */ + SetDisplayName(request: PlayFabProfilesModels.SetDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the global title access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setglobalpolicy + */ + SetGlobalPolicy(request: PlayFabProfilesModels.SetGlobalPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the entity's language. The precedence hierarchy for communication to the player is Title Player Account + * language, Master Player Account language, and then title default language if the first two aren't set or supported. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setprofilelanguage + */ + SetProfileLanguage(request: PlayFabProfilesModels.SetProfileLanguageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the profiles access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setprofilepolicy + */ + SetProfilePolicy(request: PlayFabProfilesModels.SetEntityProfilePolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabProfilesModels { + type EffectType = "Allow" + + | "Deny"; + + export interface EntityDataObject { + /** Un-escaped JSON object, if DataAsObject is true. */ + DataObject?: any; + /** Escaped string JSON body of the object, if DataAsObject is default or false. */ + EscapedDataObject?: string; + /** Name of this object. */ + ObjectName?: string; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLineage { + /** The Character Id of the associated entity. */ + CharacterId?: string; + /** The Group Id of the associated entity. */ + GroupId?: string; + /** The Master Player Account Id of the associated entity. */ + MasterPlayerAccountId?: string; + /** The Namespace Id of the associated entity. */ + NamespaceId?: string; + /** The Title Id of the associated entity. */ + TitleId?: string; + /** The Title Player Account Id of the associated entity. */ + TitlePlayerAccountId?: string; + + } + + export interface EntityPermissionStatement { + /** The action this statement effects. May be 'Read', 'Write' or '*' for both read and write. */ + Action: string; + /** A comment about the statement. Intended solely for bookkeeping and debugging. */ + Comment?: string; + /** Additional conditions to be applied for entity resources. */ + Condition?: any; + /** The effect this statement will have. It may be either Allow or Deny */ + Effect: string; + /** The principal this statement will effect. */ + Principal: any; + /** The resource this statements effects. Similar to 'pfrn:data--title![Title ID]/Profile/*' */ + Resource: string; + + } + + export interface EntityProfileBody { + /** Avatar URL for the entity. */ + AvatarUrl?: string; + /** The creation time of this profile in UTC. */ + Created: string; + /** + * The display name of the entity. This field may serve different purposes for different entity types. i.e.: for a title + * player account it could represent the display name of the player, whereas on a character it could be character's name. + */ + DisplayName?: string; + /** The entity id and type. */ + Entity?: EntityKey; + /** The chain of responsibility for this entity. Use Lineage. */ + EntityChain?: string; + /** The experiment variants of this profile. */ + ExperimentVariants?: string[]; + /** The files on this profile. */ + Files?: { [key: string]: EntityProfileFileMetadata }; + /** The language on this profile. */ + Language?: string; + /** The lineage of this profile. */ + Lineage?: EntityLineage; + /** The objects on this profile. */ + Objects?: { [key: string]: EntityDataObject }; + /** + * The permissions that govern access to this entity profile and its properties. Only includes permissions set on this + * profile, not global statements from titles and namespaces. + */ + Permissions?: EntityPermissionStatement[]; + /** The statistics on this profile. */ + Statistics?: { [key: string]: EntityStatisticValue }; + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + StatisticsColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** + * The version number of the profile in persistent storage at the time of the read. Used for optional optimistic + * concurrency during update. + */ + VersionNumber: number; + + } + + export interface EntityProfileFileMetadata { + /** Checksum value for the file, can be used to check if the file on the server has changed. */ + Checksum?: string; + /** Name of the file */ + FileName?: string; + /** Last UTC time the file was modified */ + LastModified: string; + /** Storage service's reported byte count */ + Size: number; + + } + + export interface EntityStatisticValue { + /** Metadata associated with the Statistic. */ + Metadata?: string; + /** Statistic name */ + Name?: string; + /** Statistic scores */ + Scores?: string[]; + /** Statistic version */ + Version: number; + + } + + export interface GetEntityProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the objects will be returned as an escaped JSON string or as a un-escaped JSON object. Default is + * JSON string. + */ + DataAsObject?: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Determines whether the entity statistics will be returned in the entity profile. Default is false. */ + IncludeStatistics: boolean; + + } + + export interface GetEntityProfileResponse extends PlayFabModule.IPlayFabResultCommon { + /** Entity profile */ + Profile?: EntityProfileBody; + + } + + export interface GetEntityProfilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the objects will be returned as an escaped JSON string or as a un-escaped JSON object. Default is + * JSON string. + */ + DataAsObject?: boolean; + /** Entity keys of the profiles to load. Must be between 1 and 25 */ + Entities: EntityKey[]; + /** Determines whether the entity statistics will be returned in the entity profile. Default is false. */ + IncludeStatistics: boolean; + + } + + export interface GetEntityProfilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** Entity profiles */ + Profiles?: EntityProfileBody[]; + + } + + export interface GetGlobalPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetGlobalPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** The permissions that govern access to all entities under this title or namespace. */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface GetTitlePlayersFromMasterPlayerAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Master player account ids. */ + MasterPlayerAccountIds: string[]; + /** Id of title to get players from. */ + TitleId?: string; + + } + + export interface GetTitlePlayersFromMasterPlayerAccountIdsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional id of title to get players from, required if calling using a master_player_account. */ + TitleId?: string; + /** Dictionary of master player ids mapped to title player entity keys and id pairs */ + TitlePlayerAccounts?: { [key: string]: EntityKey }; + + } + + export interface GetTitlePlayersFromProviderIDsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * Dictionary of provider identifiers mapped to title_player_account lineage. Missing lineage indicates the player either + * doesn't exist or doesn't play the requested title. + */ + TitlePlayerAccounts?: { [key: string]: EntityLineage }; + + } + + export interface GetTitlePlayersFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Xbox Sandbox the players had on their Xbox tokens. */ + Sandbox: string; + /** Optional ID of title to get players from, required if calling using a master_player_account. */ + TitleId?: string; + /** List of Xbox Live XUIDs */ + XboxLiveIds: string[]; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface SetDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new value to be set on Entity Profile's display name */ + DisplayName?: string; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The expected version of a profile to perform this update on */ + ExpectedVersion?: number; + + } + + export interface SetDisplayNameResponse extends PlayFabModule.IPlayFabResultCommon { + /** The type of operation that occured on the profile's display name */ + OperationResult?: string; + /** The updated version of the profile after the display name update */ + VersionNumber?: number; + + } + + export interface SetEntityProfilePolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The statements to include in the access policy. */ + Statements: EntityPermissionStatement[]; + + } + + export interface SetEntityProfilePolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The permissions that govern access to this entity profile and its properties. Only includes permissions set on this + * profile, not global statements from titles and namespaces. + */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface SetGlobalPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The permissions that govern access to all entities under this title or namespace. */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface SetGlobalPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetProfileLanguageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The expected version of a profile to perform this update on */ + ExpectedVersion?: number; + /** The language to set on the given entity. Deletes the profile's language if passed in a null string. */ + Language?: string; + + } + + export interface SetProfileLanguageResponse extends PlayFabModule.IPlayFabResultCommon { + /** The type of operation that occured on the profile's language */ + OperationResult?: string; + /** The updated version of the profile after the language update */ + VersionNumber?: number; + + } + + type StatisticAggregationMethod = "Last" + + | "Min" + | "Max" + | "Sum"; + + export interface StatisticColumn { + /** Aggregation method for calculating new value of a statistic. */ + AggregationMethod: string; + /** Name of the statistic column, as originally configured. */ + Name: string; + + } + + export interface StatisticColumnCollection { + /** Columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabProgressionApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabProgressionApi.d.ts new file mode 100644 index 00000000..00230005 --- /dev/null +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabProgressionApi.d.ts @@ -0,0 +1,815 @@ +/// + +declare module PlayFabProgressionModule { + export interface IPlayFabProgression { + ForgetAllCredentials(): void; + + /** + * Creates a new leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/createleaderboarddefinition + */ + CreateLeaderboardDefinition(request: PlayFabProgressionModels.CreateLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a new entity statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/createstatisticdefinition + */ + CreateStatisticDefinition(request: PlayFabProgressionModels.CreateStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/deleteleaderboarddefinition + */ + DeleteLeaderboardDefinition(request: PlayFabProgressionModels.DeleteLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the specified entries from the given leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/deleteleaderboardentries + */ + DeleteLeaderboardEntries(request: PlayFabProgressionModels.DeleteLeaderboardEntriesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete an entity statistic definition. Will delete all statistics on entity profiles and leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/deletestatisticdefinition + */ + DeleteStatisticDefinition(request: PlayFabProgressionModels.DeleteStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete statistics on an entity profile. This will remove all rankings from associated leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/deletestatistics + */ + DeleteStatistics(request: PlayFabProgressionModels.DeleteStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the friend leaderboard for the specified entity. A maximum of 25 friend entries are listed in the leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getfriendleaderboardforentity + */ + GetFriendLeaderboardForEntity(request: PlayFabProgressionModels.GetFriendLeaderboardForEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard for a specific entity type and statistic. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboard + */ + GetLeaderboard(request: PlayFabProgressionModels.GetEntityLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard around a specific entity. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboardaroundentity + */ + GetLeaderboardAroundEntity(request: PlayFabProgressionModels.GetLeaderboardAroundEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the specified leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboarddefinition + */ + GetLeaderboardDefinition(request: PlayFabProgressionModels.GetLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard limited to a set of entities. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboardforentities + */ + GetLeaderboardForEntities(request: PlayFabProgressionModels.GetLeaderboardForEntitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get current statistic definition information + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatisticdefinition + */ + GetStatisticDefinition(request: PlayFabProgressionModels.GetStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets statistics for the specified entity. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatistics + */ + GetStatistics(request: PlayFabProgressionModels.GetStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets statistics for the specified collection of entities. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatisticsforentities + */ + GetStatisticsForEntities(request: PlayFabProgressionModels.GetStatisticsForEntitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Increment a leaderboard version. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/incrementleaderboardversion + */ + IncrementLeaderboardVersion(request: PlayFabProgressionModels.IncrementLeaderboardVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Increment an entity statistic definition version. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/incrementstatisticversion + */ + IncrementStatisticVersion(request: PlayFabProgressionModels.IncrementStatisticVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists the leaderboard definitions defined for the Title. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/listleaderboarddefinitions + */ + ListLeaderboardDefinitions(request: PlayFabProgressionModels.ListLeaderboardDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get all current statistic definitions information + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/liststatisticdefinitions + */ + ListStatisticDefinitions(request: PlayFabProgressionModels.ListStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks an aggregation source from a statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/unlinkaggregationsourcefromstatistic + */ + UnlinkAggregationSourceFromStatistic(request: PlayFabProgressionModels.UnlinkAggregationSourceFromStatisticRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks a leaderboard definition from it's linked statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/unlinkleaderboardfromstatistic + */ + UnlinkLeaderboardFromStatistic(request: PlayFabProgressionModels.UnlinkLeaderboardFromStatisticRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/updateleaderboarddefinition + */ + UpdateLeaderboardDefinition(request: PlayFabProgressionModels.UpdateLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds or updates entries on the specified leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/updateleaderboardentries + */ + UpdateLeaderboardEntries(request: PlayFabProgressionModels.UpdateLeaderboardEntriesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update an existing entity statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/updatestatisticdefinition + */ + UpdateStatisticDefinition(request: PlayFabProgressionModels.UpdateStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update statistics on an entity profile. Depending on the statistic definition, this may result in entity being ranked on + * various leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/updatestatistics + */ + UpdateStatistics(request: PlayFabProgressionModels.UpdateStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabProgressionModels { + export interface CreateLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Leaderboard columns describing the sort directions, cannot be changed after creation. A maximum of 5 columns are + * allowed. + */ + Columns: LeaderboardColumn[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface CreateStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * [In Preview]: The list of statistic definition names whose scores must be aggregated towards this stat. If + * AggregationSource is specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, + * only one aggregation source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. A maximum of 5 columns are allowed. */ + Columns?: StatisticColumn[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity type allowed to have score(s) for this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Name of the statistic. Must be less than 150 characters. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + Name: string; + /** The version reset configuration for the statistic definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface DeleteLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard definition to delete. */ + Name: string; + + } + + export interface DeleteLeaderboardEntriesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique Ids of the entries to delete from the leaderboard. */ + EntityIds?: string[]; + /** The name of the leaderboard. */ + Name: string; + + } + + export interface DeleteStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic to delete. */ + Name: string; + + } + + export interface DeleteStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Collection of statistics to remove from this entity. */ + Statistics: StatisticDelete[]; + + } + + export interface DeleteStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLeaderboardEntry { + /** Entity's display name. */ + DisplayName?: string; + /** Entity identifier. */ + Entity?: EntityKey; + /** The time at which the last update to the entry was recorded on the server. */ + LastUpdated: string; + /** An opaque blob of data stored on the leaderboard entry. Note that the metadata is not used for ranking purposes. */ + Metadata?: string; + /** Position on the leaderboard. */ + Rank: number; + /** Scores for the entry. */ + Scores?: string[]; + + } + + export interface EntityStatistics { + /** The entity for which the statistics are returned. */ + EntityKey?: EntityKey; + /** The statistics for the given entity key. */ + Statistics?: EntityStatisticValue[]; + + } + + export interface EntityStatisticValue { + /** Metadata associated with the Statistic. */ + Metadata?: string; + /** Statistic name */ + Name?: string; + /** Statistic scores */ + Scores?: string[]; + /** Statistic version */ + Version: number; + + } + + type EventType = "None" + + | "Telemetry" + | "PlayStream"; + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface GetEntityLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Maximum number of results to return from the leaderboard. Minimum 1, maximum 100. */ + PageSize: number; + /** Index position to start from. 1 is beginning of leaderboard. */ + StartingPosition?: number; + /** Optional version of the leaderboard, defaults to current version. */ + Version?: number; + + } + + export interface GetEntityLeaderboardResponse extends PlayFabModule.IPlayFabResultCommon { + /** Leaderboard columns describing the sort directions. */ + Columns?: LeaderboardColumn[]; + /** The number of entries on the leaderboard. */ + EntryCount: number; + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ + NextReset?: string; + /** Individual entity rankings in the leaderboard, in sorted order by rank. */ + Rankings?: EntityLeaderboardEntry[]; + /** Version of the leaderboard being returned. */ + Version: number; + + } + + export interface GetFriendLeaderboardForEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalFriendSources?: string; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Optional version of the leaderboard, defaults to current version. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; + + } + + export interface GetLeaderboardAroundEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** + * Number of surrounding entries to return (in addition to specified entity). In general, the number of ranks above and + * below will be split into half. For example, if the specified value is 10, 5 ranks above and 5 ranks below will be + * retrieved. However, the numbers will get skewed in either direction when the specified entity is towards the top or + * bottom of the leaderboard. Also, the number of entries returned can be lower than the value specified for entries at the + * bottom of the leaderboard. + */ + MaxSurroundingEntries: number; + /** Optional version of the leaderboard, defaults to current. */ + Version?: number; + + } + + export interface GetLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard to retrieve the definition for. */ + Name: string; + + } + + export interface GetLeaderboardDefinitionResponse extends PlayFabModule.IPlayFabResultCommon { + /** Sort direction of the leaderboard columns, cannot be changed after creation. */ + Columns: LeaderboardColumn[]; + /** Created time, in UTC */ + Created: string; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** Last time, in UTC, leaderboard version was incremented. */ + LastResetTime?: string; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** Latest Leaderboard version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration: VersionConfiguration; + + } + + export interface GetLeaderboardForEntitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Collection of Entity IDs to include in the leaderboard. */ + EntityIds: string[]; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Optional version of the leaderboard, defaults to current. */ + Version?: number; + + } + + export interface GetStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic. Must be less than 150 characters. */ + Name: string; + + } + + export interface GetStatisticDefinitionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of statistic definitions names this definition aggregates to. */ + AggregationDestinations?: string[]; + /** + * The list of statistic definitions names whose values must be aggregated towards this stat. If AggregationSource is + * specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, only one aggregation + * source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + /** Created time, in UTC */ + Created: string; + /** The entity type that can have this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Last time, in UTC, statistic version was incremented. */ + LastResetTime?: string; + /** The list of leaderboards that are linked to this statistic definition. */ + LinkedLeaderboardNames?: string[]; + /** Name of the statistic. */ + Name?: string; + /** Statistic version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface GetStatisticsForEntitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Collection of Entity IDs to retrieve statistics for. */ + Entities: EntityKey[]; + /** The list of statistics to return for the user. If set to null, the current version of all statistics are returned. */ + StatisticNames?: string[]; + + } + + export interface GetStatisticsForEntitiesResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** List of entities mapped to their statistics. Only the latest version of a statistic is returned. */ + EntitiesStatistics?: EntityStatistics[]; + + } + + export interface GetStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The list of statistics to return for the user. If set to null, the current version of all statistics are returned. */ + StatisticNames?: string[]; + + } + + export interface GetStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** The entity id and type. */ + Entity?: EntityKey; + /** List of statistics keyed by Name. Only the latest version of a statistic is returned. */ + Statistics?: { [key: string]: EntityStatisticValue }; + + } + + export interface IncrementLeaderboardVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard to increment the version for. */ + Name: string; + + } + + export interface IncrementLeaderboardVersionResponse extends PlayFabModule.IPlayFabResultCommon { + /** New Leaderboard version. */ + Version: number; + + } + + export interface IncrementStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic to increment the version of. */ + Name: string; + + } + + export interface IncrementStatisticVersionResponse extends PlayFabModule.IPlayFabResultCommon { + /** New statistic version. */ + Version: number; + + } + + export interface LeaderboardColumn { + /** + * If the value for this column is sourced from a statistic, details of the linked column. Null if the leaderboard is not + * linked. + */ + LinkedStatisticColumn?: LinkedStatisticColumn; + /** A name for the leaderboard column, unique per leaderboard definition. */ + Name: string; + /** The sort direction for this column. */ + SortDirection: string; + + } + + export interface LeaderboardDefinition { + /** Sort direction of the leaderboard columns, cannot be changed after creation. */ + Columns: LeaderboardColumn[]; + /** Created time, in UTC */ + Created: string; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** Last time, in UTC, leaderboard version was incremented. */ + LastResetTime?: string; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** Latest Leaderboard version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration: VersionConfiguration; + + } + + export interface LeaderboardEntityRankOnVersionEndConfig { + /** The type of event to emit when the leaderboard version end. */ + EventType: string; + /** The maximum number of entity to return on leaderboard version end. Range is 1 to 1000. */ + RankLimit: number; + + } + + export interface LeaderboardEntryUpdate { + /** The unique Id for the entry. If using PlayFab Entities, this would be the entityId of the entity. */ + EntityId: string; + /** Arbitrary metadata to store along side the leaderboard entry, will be returned by all Leaderboard APIs. */ + Metadata?: string; + /** + * The scores for the leaderboard. The number of values provided here must match the number of columns in the Leaderboard + * definition. + */ + Scores?: string[]; + + } + + export interface LeaderboardEventEmissionConfig { + /** This event emits the top ranks of the leaderboard when the leaderboard version end. */ + EntityRankOnVersionEndConfig?: LeaderboardEntityRankOnVersionEndConfig; + /** This event is emitted when the leaderboard version end. */ + VersionEndConfig?: LeaderboardVersionEndConfig; + + } + + type LeaderboardSortDirection = "Descending" + + | "Ascending"; + + export interface LeaderboardVersionEndConfig { + /** The type of event to emit when the leaderboard version end. */ + EventType: string; + + } + + export interface LinkedStatisticColumn { + /** The name of the statistic column that this leaderboard column is sourced from. */ + LinkedStatisticColumnName: string; + /** The name of the statistic. */ + LinkedStatisticName: string; + + } + + export interface ListLeaderboardDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListLeaderboardDefinitionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of leaderboard definitions for the title. */ + LeaderboardDefinitions?: LeaderboardDefinition[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListStatisticDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListStatisticDefinitionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** List of statistic definitions for the title. */ + StatisticDefinitions?: StatisticDefinition[]; + + } + + type ResetInterval = "Manual" + + | "Hour" + | "Day" + | "Week" + | "Month"; + + type StatisticAggregationMethod = "Last" + + | "Min" + | "Max" + | "Sum"; + + export interface StatisticColumn { + /** Aggregation method for calculating new value of a statistic. */ + AggregationMethod: string; + /** Name of the statistic column, as originally configured. */ + Name: string; + + } + + export interface StatisticColumnCollection { + /** Columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + + } + + export interface StatisticDefinition { + /** The list of statistic definitions names this definition aggregates to. */ + AggregationDestinations?: string[]; + /** + * The list of statistic definitions names whose values must be aggregated towards this stat. If AggregationSource is + * specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, only one aggregation + * source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + /** Created time, in UTC */ + Created: string; + /** The entity type that can have this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Last time, in UTC, statistic version was incremented. */ + LastResetTime?: string; + /** The list of leaderboards that are linked to this statistic definition. */ + LinkedLeaderboardNames?: string[]; + /** Name of the statistic. */ + Name?: string; + /** Statistic version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface StatisticDelete { + /** Name of the statistic, as originally configured. */ + Name: string; + + } + + export interface StatisticsEventEmissionConfig { + /** Emitted when statistics are updated. */ + UpdateEventConfig?: StatisticsUpdateEventConfig; + + } + + export interface StatisticsUpdateEventConfig { + /** The event type to emit when statistics are updated. */ + EventType: string; + + } + + export interface StatisticUpdate { + /** + * A list of entities to which the statistic update must be aggregated to, in addition to the entity being updated. For + * example, for Group stats where the stat value is aggregated based on the group members, this would refer to the Group + * entity. For a community stat that's aggregated at the Title, it is not required to populate this property (Title is the + * default). + */ + AggregationTargetEntityKeys?: EntityKey[]; + /** Arbitrary metadata to store along side the statistic, will be returned by all Leaderboard APIs. */ + Metadata?: string; + /** Name of the statistic, as originally configured. */ + Name: string; + /** + * Statistic scores for the entity. This will be used in accordance with the aggregation method configured for the + * statistics.The maximum value allowed for each individual score is 9223372036854775807. The minimum value for each + * individual score is -9223372036854775807The values are formatted as strings to avoid interop issues with client + * libraries unable to handle 64bit integers. + */ + Scores?: string[]; + /** Optional field to indicate the version of the statistic to set. When empty defaults to the statistic's current version. */ + Version?: number; + + } + + export interface UnlinkAggregationSourceFromStatisticRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the statistic to unlink. */ + Name: string; + /** The name of the aggregation source statistic to unlink. */ + SourceStatisticName: string; + + } + + export interface UnlinkLeaderboardFromStatisticRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard definition to unlink. */ + Name: string; + /** The name of the statistic definition to unlink. */ + StatisticName: string; + + } + + export interface UpdateLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** The name of the leaderboard to update the definition for. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit?: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface UpdateLeaderboardEntriesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entries to add or update on the leaderboard. */ + Entries?: LeaderboardEntryUpdate[]; + /** The name of the leaderboard. */ + LeaderboardName: string; + + } + + export interface UpdateStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Name of the statistic. Must be less than 150 characters. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + Name: string; + /** The version reset configuration for the statistic definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface UpdateStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Collection of statistics to update, maximum 50. */ + Statistics: StatisticUpdate[]; + /** Optional transactionId of this update which can be used to ensure idempotence. */ + TransactionId?: string; + + } + + export interface UpdateStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** The entity id and type. */ + Entity?: EntityKey; + /** Updated entity profile statistics. */ + Statistics?: { [key: string]: EntityStatisticValue }; + + } + + export interface VersionConfiguration { + /** The maximum number of versions of this leaderboard/statistic that can be queried. */ + MaxQueryableVersions: number; + /** + * Reset interval that statistics or leaderboards will reset on. When using Manual intervalthe reset can only be increased + * by calling the Increase version API. When using Hour interval the resetwill occur at the start of the next hour UTC + * time. When using Day interval the reset will occur at thestart of the next day in UTC time. When using the Week interval + * the reset will occur at the start ofthe next Monday in UTC time. When using Month interval the reset will occur at the + * start of the nextmonth in UTC time. + */ + ResetInterval: string; + + } + + +} diff --git a/PlayFabSdk/src/Typings/PlayFab/PlayFabServerApi.d.ts b/PlayFabSdk/src/Typings/PlayFab/PlayFabServerApi.d.ts index ccbb636b..dbde1d7a 100644 --- a/PlayFabSdk/src/Typings/PlayFab/PlayFabServerApi.d.ts +++ b/PlayFabSdk/src/Typings/PlayFab/PlayFabServerApi.d.ts @@ -2,1163 +2,1319 @@ declare module PlayFabServerModule { export interface IPlayFabServer { + ForgetAllCredentials(): void; + /** - / Validated a client's session ticket, and if successful, returns details for that user - / https://api.playfab.com/Documentation/Server/method/AuthenticateSessionTicket + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the character's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/addcharactervirtualcurrency */ - AuthenticateSessionTicket(request: PlayFabServerModels.AuthenticateSessionTicketRequest, callback: PlayFabModule.ApiCallback): void; + AddCharacterVirtualCurrency(request: PlayFabServerModels.AddCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Bans users by PlayFab ID with optional IP address, or MAC address for the provided game. - / https://api.playfab.com/Documentation/Server/method/BanUsers + * Adds the Friend user to the friendlist of the user with PlayFabId. At least one of + * FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/addfriend */ - BanUsers(request: PlayFabServerModels.BanUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddFriend(request: PlayFabServerModels.AddFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. - / https://api.playfab.com/Documentation/Server/method/GetPlayFabIDsFromFacebookIDs + * Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab + * ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as + * authentication credentials, as the intent is that it is easily accessible by other players. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/addgenericid */ - GetPlayFabIDsFromFacebookIDs(request: PlayFabServerModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback): void; + AddGenericID(request: PlayFabServerModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile IDs for the user accounts, available as SteamId in the Steamworks Community API calls. - / https://api.playfab.com/Documentation/Server/method/GetPlayFabIDsFromSteamIDs + * Adds or updates a contact email to the specified player's profile. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/addorupdatecontactemail */ - GetPlayFabIDsFromSteamIDs(request: PlayFabServerModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback): void; + AddOrUpdateContactEmail(request: PlayFabServerModels.AddOrUpdateContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the relevant details for a specified user - / https://api.playfab.com/Documentation/Server/method/GetUserAccountInfo + * Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/addplayertag */ - GetUserAccountInfo(request: PlayFabServerModels.GetUserAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + AddPlayerTag(request: PlayFabServerModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all bans for a user. - / https://api.playfab.com/Documentation/Server/method/GetUserBans + * Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users + * in the group (and the server) can add new members. Shared Groups are designed for sharing data between a very small + * number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/addsharedgroupmembers */ - GetUserBans(request: PlayFabServerModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback): void; + AddSharedGroupMembers(request: PlayFabServerModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans for a user. - / https://api.playfab.com/Documentation/Server/method/RevokeAllBansForUser + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the user's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/adduservirtualcurrency */ - RevokeAllBansForUser(request: PlayFabServerModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback): void; + AddUserVirtualCurrency(request: PlayFabServerModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans specified with BanId. - / https://api.playfab.com/Documentation/Server/method/RevokeBans + * Validated a client's session ticket, and if successful, returns details for that user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/authenticatesessionticket */ - RevokeBans(request: PlayFabServerModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback): void; + AuthenticateSessionTicket(request: PlayFabServerModels.AuthenticateSessionTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sends an iOS/Android Push Notification to a specific user, if that user's device has been configured for Push Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. - / https://api.playfab.com/Documentation/Server/method/SendPushNotification + * Awards the specified users the specified Steam achievements + * https://docs.microsoft.com/rest/api/playfab/server/platform-specific-methods/awardsteamachievement */ - SendPushNotification(request: PlayFabServerModels.SendPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + AwardSteamAchievement(request: PlayFabServerModels.AwardSteamAchievementRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update the avatar URL of the specified player - / https://api.playfab.com/Documentation/Server/method/UpdateAvatarUrl + * Bans users by PlayFab ID with optional IP address for the provided game. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/banusers */ - UpdateAvatarUrl(request: PlayFabServerModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback): void; + BanUsers(request: PlayFabServerModels.BanUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates information of a list of existing bans specified with Ban Ids. - / https://api.playfab.com/Documentation/Server/method/UpdateBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's + * inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/consumeitem */ - UpdateBans(request: PlayFabServerModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback): void; + ConsumeItem(request: PlayFabServerModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the users for the provided game. Deletes custom data, all account linkages, and statistics. - / https://api.playfab.com/Documentation/Server/method/DeleteUsers + * Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the + * group. When created by a server, the group will initially have no members. Shared Groups are designed for sharing data + * between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/createsharedgroup */ - DeleteUsers(request: PlayFabServerModels.DeleteUsersRequest, callback: PlayFabModule.ApiCallback): void; + CreateSharedGroup(request: PlayFabServerModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the given player for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetFriendLeaderboard + * Deletes the specific character ID from the specified user. + * https://docs.microsoft.com/rest/api/playfab/server/characters/deletecharacterfromuser */ - GetFriendLeaderboard(request: PlayFabServerModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + DeleteCharacterFromUser(request: PlayFabServerModels.DeleteCharacterFromUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetLeaderboard + * Removes a user's player account from a title and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/server/account-management/deleteplayer */ - GetLeaderboard(request: PlayFabServerModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayer(request: PlayFabServerModels.DeletePlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, centered on the currently signed-in user - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardAroundUser + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/deleteplayercustomproperties */ - GetLeaderboardAroundUser(request: PlayFabServerModels.GetLeaderboardAroundUserRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerCustomProperties(request: PlayFabServerModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Returns whatever info is requested in the response for the user. Note that PII (like email address, facebook id) may be returned. All parameters default to false. - / https://api.playfab.com/Documentation/Server/method/GetPlayerCombinedInfo + * Deletes push notification template for title + * https://docs.microsoft.com/rest/api/playfab/server/account-management/deletepushnotificationtemplate */ - GetPlayerCombinedInfo(request: PlayFabServerModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback): void; + DeletePushNotificationTemplate(request: PlayFabServerModels.DeletePushNotificationTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current version and values for the indicated statistics, for the local player. - / https://api.playfab.com/Documentation/Server/method/GetPlayerStatistics + * Deletes a shared group, freeing up the shared group ID to be reused for a new group. Shared Groups are designed for + * sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/deletesharedgroup */ - GetPlayerStatistics(request: PlayFabServerModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + DeleteSharedGroup(request: PlayFabServerModels.DeleteSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Server/method/GetPlayerStatisticVersions + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Returns the result of an evaluation of a Random Result Table - the ItemId from the game Catalog which would + * have been added to the player inventory, if the Random Result Table were added via a Bundle or a call to + * UnlockContainer. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/evaluaterandomresulttable */ - GetPlayerStatisticVersions(request: PlayFabServerModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + EvaluateRandomResultTable(request: PlayFabServerModels.EvaluateRandomResultTableRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetUserData + * Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. The + * PlayFab ID is the entity ID of the player's master_player_account entity. + * https://docs.microsoft.com/rest/api/playfab/server/server-side-cloud-script/executecloudscript */ - GetUserData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExecuteCloudScript(request: PlayFabServerModels.ExecuteCloudScriptServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetUserInternalData + * Starts an export for the player profiles in a segment. This API creates a snapshot of all the player profiles which + * match the segment definition at the time of the API call. Profiles which change while an export is in progress will not + * be reflected in the results. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/exportplayersinsegment */ - GetUserInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportPlayersInSegment(request: PlayFabServerModels.ExportPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherData + * Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as + * ExportPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not + * change. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getallsegments */ - GetUserPublisherData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllSegments(request: PlayFabServerModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherInternalData + * Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be + * evaluated with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/server/characters/getalluserscharacters */ - GetUserPublisherInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllUsersCharacters(request: PlayFabServerModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherReadOnlyData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getcatalogitems */ - GetUserPublisherReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCatalogItems(request: PlayFabServerModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetUserReadOnlyData + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterdata */ - GetUserReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the user - / https://api.playfab.com/Documentation/Server/method/UpdatePlayerStatistics + * Retrieves the title-specific custom data for the user's character which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterinternaldata */ - UpdatePlayerStatistics(request: PlayFabServerModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterInternalData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified character's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getcharacterinventory */ - UpdateUserData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterInventory(request: PlayFabServerModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserInternalData + * Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/characters/getcharacterleaderboard */ - UpdateUserInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterLeaderboard(request: PlayFabServerModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherData + * Retrieves the title-specific custom data for the user's character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterreadonlydata */ - UpdateUserPublisherData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterReadOnlyData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherInternalData + * Retrieves the details of all title-specific statistics for the specific character + * https://docs.microsoft.com/rest/api/playfab/server/characters/getcharacterstatistics */ - UpdateUserPublisherInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterStatistics(request: PlayFabServerModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherReadOnlyData + * This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned + * URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the + * content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, + * the query to retrieve the data will fail. See this post for more information: + * https://community.playfab.com/hc/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, + * please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. + * https://docs.microsoft.com/rest/api/playfab/server/content/getcontentdownloadurl */ - UpdateUserPublisherReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetContentDownloadUrl(request: PlayFabServerModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserReadOnlyData + * Retrieves a list of ranked friends of the given player for the given statistic, starting from the indicated point in the + * leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getfriendleaderboard */ - UpdateUserReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetFriendLeaderboard(request: PlayFabServerModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Server/method/GetCatalogItems + * Retrieves the current friends for the user with PlayFabId, constrained to users who have PlayFab accounts. Friends from + * linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/getfriendslist */ - GetCatalogItems(request: PlayFabServerModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetFriendsList(request: PlayFabServerModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Server/method/GetPublisherData + * Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getleaderboard */ - GetPublisherData(request: PlayFabServerModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboard(request: PlayFabServerModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current server time - / https://api.playfab.com/Documentation/Server/method/GetTime + * Retrieves a list of ranked characters for the given statistic, centered on the requested user + * https://docs.microsoft.com/rest/api/playfab/server/characters/getleaderboardaroundcharacter */ - GetTime(request: PlayFabServerModels.GetTimeRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardAroundCharacter(request: PlayFabServerModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/GetTitleData + * Retrieves a list of ranked users for the given statistic, centered on the currently signed-in user + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getleaderboardarounduser */ - GetTitleData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardAroundUser(request: PlayFabServerModels.GetLeaderboardAroundUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom internal title settings - / https://api.playfab.com/Documentation/Server/method/GetTitleInternalData + * Retrieves a list of all of the user's characters for the given statistic. + * https://docs.microsoft.com/rest/api/playfab/server/characters/getleaderboardforusercharacters */ - GetTitleInternalData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardForUserCharacters(request: PlayFabServerModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title news feed, as configured in the developer portal - / https://api.playfab.com/Documentation/Server/method/GetTitleNews + * Returns whatever info is requested in the response for the user. Note that PII (like email address, facebook id) may be + * returned. All parameters default to false. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayercombinedinfo */ - GetTitleNews(request: PlayFabServerModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCombinedInfo(request: PlayFabServerModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Server/method/SetPublisherData + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayercustomproperty */ - SetPublisherData(request: PlayFabServerModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCustomProperty(request: PlayFabServerModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/SetTitleData + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayerprofile */ - SetTitleData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerProfile(request: PlayFabServerModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/SetTitleInternalData + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getplayersegments */ - SetTitleInternalData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSegments(request: PlayFabServerModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the character's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/AddCharacterVirtualCurrency + * Retrieves the current version and values for the indicated statistics, for the local player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayerstatistics */ - AddCharacterVirtualCurrency(request: PlayFabServerModels.AddCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatistics(request: PlayFabServerModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/AddUserVirtualCurrency + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayerstatisticversions */ - AddUserVirtualCurrency(request: PlayFabServerModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticVersions(request: PlayFabServerModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's inventory. - / https://api.playfab.com/Documentation/Server/method/ConsumeItem + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getplayertags */ - ConsumeItem(request: PlayFabServerModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerTags(request: PlayFabServerModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Returns the result of an evaluation of a Random Result Table - the ItemId from the game Catalog which would have been added to the player inventory, if the Random Result Table were added via a Bundle or a call to UnlockContainer. - / https://api.playfab.com/Documentation/Server/method/EvaluateRandomResultTable + * Retrieves the unique PlayFab identifiers for the given set of Battle.net account identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrombattlenetaccountids */ - EvaluateRandomResultTable(request: PlayFabServerModels.EvaluateRandomResultTableRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromBattleNetAccountIds(request: PlayFabServerModels.GetPlayFabIDsFromBattleNetAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified character's current inventory of virtual goods - / https://api.playfab.com/Documentation/Server/method/GetCharacterInventory + * Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromfacebookids */ - GetCharacterInventory(request: PlayFabServerModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookIDs(request: PlayFabServerModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the configuration information for the specified random results tables for the title, including all ItemId values and weights - / https://api.playfab.com/Documentation/Server/method/GetRandomResultTables + * Retrieves the unique PlayFab identifiers for the given set of Facebook Instant Games identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromfacebookinstantgamesids */ - GetRandomResultTables(request: PlayFabServerModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookInstantGamesIds(request: PlayFabServerModels.GetPlayFabIDsFromFacebookInstantGamesIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Server/method/GetUserInventory + * Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the generic identifier was + * added to the player account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromgenericids */ - GetUserInventory(request: PlayFabServerModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGenericIDs(request: PlayFabServerModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified character's inventory - / https://api.playfab.com/Documentation/Server/method/GrantItemsToCharacter + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Service Account identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromnintendoserviceaccountids */ - GrantItemsToCharacter(request: PlayFabServerModels.GrantItemsToCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoServiceAccountIds(request: PlayFabServerModels.GetPlayFabIDsFromNintendoServiceAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user's inventory - / https://api.playfab.com/Documentation/Server/method/GrantItemsToUser + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Switch Device identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromnintendoswitchdeviceids */ - GrantItemsToUser(request: PlayFabServerModels.GrantItemsToUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoSwitchDeviceIds(request: PlayFabServerModels.GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user inventories - / https://api.playfab.com/Documentation/Server/method/GrantItemsToUsers + * Retrieves the unique PlayFab identifiers for the given set of OpenId subject identifiers. A OpenId subject identifier is + * the OpenId issuer plus the OpenId subject for the player, as specified by the title when the OpenId identifier was added + * to the player account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromopenidsubjectidentifiers */ - GrantItemsToUsers(request: PlayFabServerModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromOpenIdSubjectIdentifiers(request: PlayFabServerModels.GetPlayFabIDsFromOpenIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Modifies the number of remaining uses of a player's inventory item - / https://api.playfab.com/Documentation/Server/method/ModifyItemUses + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrompsnaccountids */ - ModifyItemUses(request: PlayFabServerModels.ModifyItemUsesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNAccountIDs(request: PlayFabServerModels.GetPlayFabIDsFromPSNAccountIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a character's inventory into another of the users's character's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToCharacterFromCharacter + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrompsnonlineids */ - MoveItemToCharacterFromCharacter(request: PlayFabServerModels.MoveItemToCharacterFromCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNOnlineIDs(request: PlayFabServerModels.GetPlayFabIDsFromPSNOnlineIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a user's inventory into their character's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToCharacterFromUser + * Retrieves the associated PlayFab account identifiers for the given set of server custom player identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromservercustomids */ - MoveItemToCharacterFromUser(request: PlayFabServerModels.MoveItemToCharacterFromUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromServerCustomIDs(request: PlayFabServerModels.GetPlayFabIDsFromServerCustomIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a character's inventory into the owning user's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToUserFromCharacter + * Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile + * IDs for the user accounts, available as SteamId in the Steamworks Community API calls. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromsteamids */ - MoveItemToUserFromCharacter(request: PlayFabServerModels.MoveItemToUserFromCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamIDs(request: PlayFabServerModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the Economy->Catalogs tab in the PlayFab Game Manager. - / https://api.playfab.com/Documentation/Server/method/RedeemCoupon + * 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 */ - RedeemCoupon(request: PlayFabServerModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamNames(request: PlayFabServerModels.GetPlayFabIDsFromSteamNamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Submit a report about a player (due to bad bahavior, etc.) on behalf of another player, so that customer service representatives for the title can take action concerning potentially toxic players. - / https://api.playfab.com/Documentation/Server/method/ReportPlayer + * 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). + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromtwitchids */ - ReportPlayer(request: PlayFabServerModels.ReportPlayerServerRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromTwitchIDs(request: PlayFabServerModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revokes access to an item in a user's inventory - / https://api.playfab.com/Documentation/Server/method/RevokeInventoryItem + * Retrieves the unique PlayFab identifiers for the given set of XboxLive identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromxboxliveids */ - RevokeInventoryItem(request: PlayFabServerModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromXboxLiveIDs(request: PlayFabServerModels.GetPlayFabIDsFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the character's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/SubtractCharacterVirtualCurrency + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getpublisherdata */ - SubtractCharacterVirtualCurrency(request: PlayFabServerModels.SubtractCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabServerModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/SubtractUserVirtualCurrency + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the configuration information for the specified random results tables for the title, including all + * ItemId values and weights + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getrandomresulttables */ - SubtractUserVirtualCurrency(request: PlayFabServerModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetRandomResultTables(request: PlayFabServerModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens a specific container (ContainerItemInstanceId), with a specific key (KeyItemInstanceId, when required), and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Server/method/UnlockContainerInstance + * Retrieves the result of an export started by ExportPlayersInSegment API. If the ExportPlayersInSegment is successful and + * complete, this API returns the IndexUrl from which the index file can be downloaded. The index file has a list of urls + * from which the files containing the player profile data can be downloaded. Otherwise, it returns the current 'State' of + * the export + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getsegmentexport */ - UnlockContainerInstance(request: PlayFabServerModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentExport(request: PlayFabServerModels.GetPlayersInSegmentExportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Searches Player or Character inventory for any ItemInstance matching the given CatalogItemId, if necessary unlocks it using any appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Server/method/UnlockContainerItem + * Returns the total number of players in a given segment. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getsegmentplayercount */ - UnlockContainerItem(request: PlayFabServerModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentPlayerCount(request: PlayFabServerModels.GetSegmentPlayerCountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value pair data tagged to the specified item, which is read-only from the client. - / https://api.playfab.com/Documentation/Server/method/UpdateUserInventoryItemCustomData + * Retrieves the associated PlayFab account identifiers for the given set of server custom identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getservercustomidsfromplayfabids */ - UpdateUserInventoryItemCustomData(request: PlayFabServerModels.UpdateUserInventoryItemDataRequest, callback: PlayFabModule.ApiCallback): void; + GetServerCustomIDsFromPlayFabIDs(request: PlayFabServerModels.GetServerCustomIDsFromPlayFabIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the Friend user to the friendlist of the user with PlayFabId. At least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. - / https://api.playfab.com/Documentation/Server/method/AddFriend + * Retrieves data stored in a shared group object, as well as the list of members in the group. The server can access all + * public and private group data. Shared Groups are designed for sharing data between a very small number of players, + * please see our guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/getsharedgroupdata */ - AddFriend(request: PlayFabServerModels.AddFriendRequest, callback: PlayFabModule.ApiCallback): void; + GetSharedGroupData(request: PlayFabServerModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current friends for the user with PlayFabId, constrained to users who have PlayFab accounts. Friends from linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. - / https://api.playfab.com/Documentation/Server/method/GetFriendsList + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined, for the specified + * player + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getstoreitems */ - GetFriendsList(request: PlayFabServerModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabServerModels.GetStoreItemsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the specified friend from the the user's friend list - / https://api.playfab.com/Documentation/Server/method/RemoveFriend + * Retrieves the current server time + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettime */ - RemoveFriend(request: PlayFabServerModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback): void; + GetTime(request: PlayFabServerModels.GetTimeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the tag list for a specified user in the friend list of another user - / https://api.playfab.com/Documentation/Server/method/SetFriendTags + * Retrieves the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitledata */ - SetFriendTags(request: PlayFabServerModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Inform the matchmaker that a Game Server Instance is removed. - / https://api.playfab.com/Documentation/Server/method/DeregisterGame + * Retrieves the key-value store of custom internal title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitleinternaldata */ - DeregisterGame(request: PlayFabServerModels.DeregisterGameRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleInternalData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Informs the PlayFab match-making service that the user specified has left the Game Server Instance - / https://api.playfab.com/Documentation/Server/method/NotifyMatchmakerPlayerLeft + * Retrieves the title news feed, as configured in the developer portal + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitlenews */ - NotifyMatchmakerPlayerLeft(request: PlayFabServerModels.NotifyMatchmakerPlayerLeftRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleNews(request: PlayFabServerModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates a Game Server session ticket and returns details about the user - / https://api.playfab.com/Documentation/Server/method/RedeemMatchmakerTicket + * Retrieves the relevant details for a specified user + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getuseraccountinfo */ - RedeemMatchmakerTicket(request: PlayFabServerModels.RedeemMatchmakerTicketRequest, callback: PlayFabModule.ApiCallback): void; + GetUserAccountInfo(request: PlayFabServerModels.GetUserAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set the state of the indicated Game Server Instance. Also update the heartbeat for the instance. - / https://api.playfab.com/Documentation/Server/method/RefreshGameServerInstanceHeartbeat + * Gets all bans for a user. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getuserbans */ - RefreshGameServerInstanceHeartbeat(request: PlayFabServerModels.RefreshGameServerInstanceHeartbeatRequest, callback: PlayFabModule.ApiCallback): void; + GetUserBans(request: PlayFabServerModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Inform the matchmaker that a new Game Server Instance is added. - / https://api.playfab.com/Documentation/Server/method/RegisterGame + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserdata */ - RegisterGame(request: PlayFabServerModels.RegisterGameRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the custom data of the indicated Game Server Instance - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceData + * Retrieves the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserinternaldata */ - SetGameServerInstanceData(request: PlayFabServerModels.SetGameServerInstanceDataRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set the state of the indicated Game Server Instance. - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceState + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getuserinventory */ - SetGameServerInstanceState(request: PlayFabServerModels.SetGameServerInstanceStateRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabServerModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set custom tags for the specified Game Server Instance - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceTags + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherdata */ - SetGameServerInstanceTags(request: PlayFabServerModels.SetGameServerInstanceTagsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Awards the specified users the specified Steam achievements - / https://api.playfab.com/Documentation/Server/method/AwardSteamAchievement + * Retrieves the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherinternaldata */ - AwardSteamAchievement(request: PlayFabServerModels.AwardSteamAchievementRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a character-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WriteCharacterEvent + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherreadonlydata */ - WriteCharacterEvent(request: PlayFabServerModels.WriteServerCharacterEventRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a player-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WritePlayerEvent + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserreadonlydata */ - WritePlayerEvent(request: PlayFabServerModels.WriteServerPlayerEventRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a title-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WriteTitleEvent + * Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated + * with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/server/characters/grantcharactertouser */ - WriteTitleEvent(request: PlayFabServerModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback): void; + GrantCharacterToUser(request: PlayFabServerModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users in the group (and the server) can add new members. - / https://api.playfab.com/Documentation/Server/method/AddSharedGroupMembers + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified character's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstocharacter */ - AddSharedGroupMembers(request: PlayFabServerModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToCharacter(request: PlayFabServerModels.GrantItemsToCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the group. When created by a server, the group will initially have no members. - / https://api.playfab.com/Documentation/Server/method/CreateSharedGroup + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstouser */ - CreateSharedGroup(request: PlayFabServerModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUser(request: PlayFabServerModels.GrantItemsToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes a shared group, freeing up the shared group ID to be reused for a new group - / https://api.playfab.com/Documentation/Server/method/DeleteSharedGroup + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user inventories + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstousers */ - DeleteSharedGroup(request: PlayFabServerModels.DeleteSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUsers(request: PlayFabServerModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves data stored in a shared group object, as well as the list of members in the group. The server can access all public and private group data. - / https://api.playfab.com/Documentation/Server/method/GetSharedGroupData + * Links the Battle.net account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkbattlenetaccount */ - GetSharedGroupData(request: PlayFabServerModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + LinkBattleNetAccount(request: PlayFabServerModels.LinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the group can remove members. If as a result of the call, zero users remain with access, the group and its associated data will be deleted. - / https://api.playfab.com/Documentation/Server/method/RemoveSharedGroupMembers + * Links the Nintendo account associated with the token to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoserviceaccount */ - RemoveSharedGroupMembers(request: PlayFabServerModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccount(request: PlayFabServerModels.LinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated or added in this call will be readable by users not in the group. By default, data permissions are set to Private. Regardless of the permission setting, only members of the group (and the server) can update the data. - / https://api.playfab.com/Documentation/Server/method/UpdateSharedGroupData + * Links the Nintendo account associated with the Nintendo Service Account subject or id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoserviceaccountsubject */ - UpdateSharedGroupData(request: PlayFabServerModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccountSubject(request: PlayFabServerModels.LinkNintendoServiceAccountSubjectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Executes a CloudScript function, with the 'currentPlayerId' variable set to the specified PlayFabId parameter value. - / https://api.playfab.com/Documentation/Server/method/ExecuteCloudScript + * Links the NintendoSwitchDeviceId to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoswitchdeviceid */ - ExecuteCloudScript(request: PlayFabServerModels.ExecuteCloudScriptServerRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoSwitchDeviceId(request: PlayFabServerModels.LinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, the query to retrieve the data will fail. See this post for more information: https://community.playfab.com/hc/en-us/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Server/method/GetContentDownloadUrl + * Links the PlayStation :tm: Network account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkpsnaccount */ - GetContentDownloadUrl(request: PlayFabServerModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNAccount(request: PlayFabServerModels.LinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the specific character ID from the specified user. - / https://api.playfab.com/Documentation/Server/method/DeleteCharacterFromUser + * Links the PlayStation :tm: Network account associated with the provided user id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkpsnid */ - DeleteCharacterFromUser(request: PlayFabServerModels.DeleteCharacterFromUserRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNId(request: PlayFabServerModels.LinkPSNIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Server/method/GetAllUsersCharacters + * Links the custom server identifier, generated by the title, to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkservercustomid */ - GetAllUsersCharacters(request: PlayFabServerModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + LinkServerCustomId(request: PlayFabServerModels.LinkServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetCharacterLeaderboard + * Links the Steam account associated with the provided Steam ID to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linksteamid */ - GetCharacterLeaderboard(request: PlayFabServerModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LinkSteamId(request: PlayFabServerModels.LinkSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of all title-specific statistics for the specific character - / https://api.playfab.com/Documentation/Server/method/GetCharacterStatistics + * Links the Twitch account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linktwitchaccount */ - GetCharacterStatistics(request: PlayFabServerModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LinkTwitchAccount(request: PlayFabServerModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, centered on the requested user - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardAroundCharacter + * Links the Xbox Live account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkxboxaccount */ - GetLeaderboardAroundCharacter(request: PlayFabServerModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxAccount(request: PlayFabServerModels.LinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of all of the user's characters for the given statistic. - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardForUserCharacters + * Links the Xbox Live account associated with the provided Xbox ID and Sandbox to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkxboxid */ - GetLeaderboardForUserCharacters(request: PlayFabServerModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxId(request: PlayFabServerModels.LinkXboxIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Server/method/GrantCharacterToUser + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/listplayercustomproperties */ - GrantCharacterToUser(request: PlayFabServerModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabServerModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the specific character - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterStatistics + * Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithandroiddeviceid */ - UpdateCharacterStatistics(request: PlayFabServerModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithAndroidDeviceID(request: PlayFabServerModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterData + * Sign in the user with a Battle.net identity token + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithbattlenet */ - GetCharacterData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithBattleNet(request: PlayFabServerModels.LoginWithBattleNetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user's character which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterInternalData + * Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithcustomid */ - GetCharacterInternalData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithCustomID(request: PlayFabServerModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user's character which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterReadOnlyData + * Signs the user in using the iOS device identifier, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithiosdeviceid */ - GetCharacterReadOnlyData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithIOSDeviceID(request: PlayFabServerModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's chjaracter which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterData + * Signs the user in using a PlayStation :tm: Network authentication code, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithpsn */ - UpdateCharacterData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPSN(request: PlayFabServerModels.LoginWithPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's character which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterInternalData + * Securely login a game client from an external server backend using a custom identifier for that player. Server Custom ID + * and Client Custom ID are mutually exclusive and cannot be used to retrieve the same player account. + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithservercustomid */ - UpdateCharacterInternalData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithServerCustomId(request: PlayFabServerModels.LoginWithServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's character which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterReadOnlyData + * Signs the user in using an Steam ID, returning a session identifier that can subsequently be used for API calls which + * require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithsteamid */ - UpdateCharacterReadOnlyData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithSteamId(request: PlayFabServerModels.LoginWithSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Server/method/AddPlayerTag + * Sign in the user with a Twitch access token + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithtwitch */ - AddPlayerTag(request: PlayFabServerModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithTwitch(request: PlayFabServerModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieve a list of all PlayStream actions groups. - / https://api.playfab.com/Documentation/Server/method/GetAllActionGroups + * Signs the user in using a Xbox Live Token from an external server backend, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithxbox */ - GetAllActionGroups(request: PlayFabServerModels.GetAllActionGroupsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXbox(request: PlayFabServerModels.LoginWithXboxRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as GetPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not change. - / https://api.playfab.com/Documentation/Server/method/GetAllSegments + * Signs the user in using an Xbox ID and Sandbox ID, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithxboxid */ - GetAllSegments(request: PlayFabServerModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXboxId(request: PlayFabServerModels.LoginWithXboxIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Server/method/GetPlayerSegments + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Modifies the number of remaining uses of a player's inventory item + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/modifyitemuses */ - GetPlayerSegments(request: PlayFabServerModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + ModifyItemUses(request: PlayFabServerModels.ModifyItemUsesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Allows for paging through all players in a given segment. This API creates a snapshot of all player profiles that match the segment definition at the time of its creation and lives through the Total Seconds to Live, refreshing its life span on each subsequent use of the Continuation Token. Profiles that change during the course of paging will not be reflected in the results. AB Test segments are currently not supported by this operation. - / https://api.playfab.com/Documentation/Server/method/GetPlayersInSegment + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a character's inventory into another of the users's character's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtocharacterfromcharacter */ - GetPlayersInSegment(request: PlayFabServerModels.GetPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback): void; + MoveItemToCharacterFromCharacter(request: PlayFabServerModels.MoveItemToCharacterFromCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Server/method/GetPlayerTags + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a user's inventory into their character's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtocharacterfromuser */ - GetPlayerTags(request: PlayFabServerModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + MoveItemToCharacterFromUser(request: PlayFabServerModels.MoveItemToCharacterFromUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Server/method/RemovePlayerTag + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a character's inventory into the owning user's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtouserfromcharacter */ - RemovePlayerTag(request: PlayFabServerModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabServerModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ActionsOnPlayersInSegmentTaskSummary - */ - export interface ActionsOnPlayersInSegmentTaskSummary { + MoveItemToUserFromCharacter(request: PlayFabServerModels.MoveItemToUserFromCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the task instance. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the + * Economy->Catalogs tab in the PlayFab Game Manager. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/redeemcoupon */ - TaskInstanceId?: string; + RedeemCoupon(request: PlayFabServerModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Identifier of the task this instance belongs to. + * Removes the specified friend from the the user's friend list + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/removefriend */ - TaskIdentifier?: NameIdentifier; + RemoveFriend(request: PlayFabServerModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task started. + * Removes the specified generic service identifier from the player's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/removegenericid */ - StartedAt: string; + RemoveGenericID(request: PlayFabServerModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task completed. + * Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/removeplayertag */ - CompletedAt?: string; + RemovePlayerTag(request: PlayFabServerModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Current status of the task instance. + * Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the + * group can remove members. If as a result of the call, zero users remain with access, the group and its associated data + * will be deleted. Shared Groups are designed for sharing data between a very small number of players, please see our + * guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/removesharedgroupmembers */ - Status?: string; + RemoveSharedGroupMembers(request: PlayFabServerModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Progress represented as percentage. + * Submit a report about a player (due to bad bahavior, etc.) on behalf of another player, so that customer service + * representatives for the title can take action concerning potentially toxic players. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/reportplayer */ - PercentComplete?: number; + ReportPlayer(request: PlayFabServerModels.ReportPlayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Estimated time remaining in seconds. + * Revoke all active bans for a user. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/revokeallbansforuser */ - EstimatedSecondsRemaining?: number; + RevokeAllBansForUser(request: PlayFabServerModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / If manually scheduled, ID of user who scheduled the task. + * Revoke all active bans specified with BanId. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/revokebans */ - ScheduledByUserId?: string; + RevokeBans(request: PlayFabServerModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Error message for last processing attempt, if an error occured. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access to an item in a user's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/revokeinventoryitem */ - ErrorMessage?: string; + RevokeInventoryItem(request: PlayFabServerModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Flag indicating if the error was fatal, if false job will be retried. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access for up to 25 items across multiple users and characters. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/revokeinventoryitems */ - ErrorWasFatal?: boolean; + RevokeInventoryItems(request: PlayFabServerModels.RevokeInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total players in segment when task was started. + * Saves push notification template for title + * https://docs.microsoft.com/rest/api/playfab/server/account-management/savepushnotificationtemplate */ - TotalPlayersInSegment?: number; + SavePushNotificationTemplate(request: PlayFabServerModels.SavePushNotificationTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total number of players that have had the actions applied to. + * Forces an email to be sent to the registered contact email address for the user's account based on an account recovery + * email template + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendcustomaccountrecoveryemail */ - TotalPlayersProcessed?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AdCampaignAttribution - */ - export interface AdCampaignAttribution { + SendCustomAccountRecoveryEmail(request: PlayFabServerModels.SendCustomAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Sends an email based on an email template to a player's contact email + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendemailfromtemplate */ - Platform?: string; + SendEmailFromTemplate(request: PlayFabServerModels.SendEmailFromTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Sends an iOS/Android Push Notification to a specific user, if that user's device has been configured for Push + * Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendpushnotification */ - CampaignId?: string; + SendPushNotification(request: PlayFabServerModels.SendPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Sends an iOS/Android Push Notification template to a specific user, if that user's device has been configured for Push + * Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendpushnotificationfromtemplate */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AdCampaignAttributionModel - */ - export interface AdCampaignAttributionModel { + SendPushNotificationFromTemplate(request: PlayFabServerModels.SendPushNotificationFromTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Updates the tag list for a specified user in the friend list of another user + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/setfriendtags */ - Platform?: string; + SetFriendTags(request: PlayFabServerModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Sets the player's secret if it is not already set. Player secrets are used to sign API requests. To reset a player's + * secret use the Admin or Server API method SetPlayerSecret. + * https://docs.microsoft.com/rest/api/playfab/server/authentication/setplayersecret */ - CampaignId?: string; + SetPlayerSecret(request: PlayFabServerModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Updates the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/setpublisherdata */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddCharacterVirtualCurrencyRequest - */ - export interface AddCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { + SetPublisherData(request: PlayFabServerModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / PlayFab unique identifier of the user whose virtual currency balance is to be incremented. + * Updates the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/settitledata */ - PlayFabId: string; + SetTitleData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Updates the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/settitleinternaldata */ - CharacterId: string; + SetTitleInternalData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Name of the virtual currency which is to be incremented. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the character's balance of the specified virtual currency by the stated amount. It is possible to + * make a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/subtractcharactervirtualcurrency */ - VirtualCurrency: string; + SubtractCharacterVirtualCurrency(request: PlayFabServerModels.SubtractCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Amount to be added to the character balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the user's balance of the specified virtual currency by the stated amount. It is possible to make + * a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/subtractuservirtualcurrency */ - Amount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddFriendRequest - */ - export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { + SubtractUserVirtualCurrency(request: PlayFabServerModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / PlayFab identifier of the player to add a new friend. + * Unlinks the related Apple account from the specified user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkapple */ - PlayFabId: string; + UnlinkApple(request: PlayFabServerModels.UnlinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / The PlayFab identifier of the user being added. + * Unlinks the related Battle.net account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkbattlenetaccount */ - FriendPlayFabId?: string; + UnlinkBattleNetAccount(request: PlayFabServerModels.UnlinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / The PlayFab username of the user being added + * Unlinks the related Facebook account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkfacebookaccount */ - FriendUsername?: string; + UnlinkFacebookAccount(request: PlayFabServerModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Email address of the user being added. + * Unlinks the related Facebook Instant Games identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkfacebookinstantgamesid */ - FriendEmail?: string; + UnlinkFacebookInstantGamesId(request: PlayFabServerModels.UnlinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Title-specific display name of the user to being added. + * Unlinks the related Game Center account from the specified user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkgamecenteraccount */ - FriendTitleDisplayName?: string; + UnlinkGameCenterAccount(request: PlayFabServerModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Nintendo account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinknintendoserviceaccount + */ + UnlinkNintendoServiceAccount(request: PlayFabServerModels.UnlinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related NintendoSwitchDeviceId from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinknintendoswitchdeviceid + */ + UnlinkNintendoSwitchDeviceId(request: PlayFabServerModels.UnlinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related PlayStation :tm: Network account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkpsnaccount + */ + UnlinkPSNAccount(request: PlayFabServerModels.UnlinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the custom server identifier from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkservercustomid + */ + UnlinkServerCustomId(request: PlayFabServerModels.UnlinkServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the Steam account associated with the provided Steam ID to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinksteamid + */ + UnlinkSteamId(request: PlayFabServerModels.UnlinkSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Twitch account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinktwitchaccount + */ + UnlinkTwitchAccount(request: PlayFabServerModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Xbox Live account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkxboxaccount + */ + UnlinkXboxAccount(request: PlayFabServerModels.UnlinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Opens a specific container (ContainerItemInstanceId), with a specific key (KeyItemInstanceId, when + * required), and returns the contents of the opened container. If the container (and key when relevant) are consumable + * (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/unlockcontainerinstance + */ + UnlockContainerInstance(request: PlayFabServerModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Searches Player or Character inventory for any ItemInstance matching the given CatalogItemId, if necessary + * unlocks it using any appropriate key, and returns the contents of the opened container. If the container (and key when + * relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of + * ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/unlockcontaineritem + */ + UnlockContainerItem(request: PlayFabServerModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the avatar URL of the specified player + * https://docs.microsoft.com/rest/api/playfab/server/account-management/updateavatarurl + */ + UpdateAvatarUrl(request: PlayFabServerModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates information of a list of existing bans specified with Ban Ids. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/updatebans + */ + UpdateBans(request: PlayFabServerModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterdata + */ + UpdateCharacterData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterinternaldata + */ + UpdateCharacterInternalData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterreadonlydata + */ + UpdateCharacterReadOnlyData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the values of the specified title-specific statistics for the specific character + * https://docs.microsoft.com/rest/api/playfab/server/characters/updatecharacterstatistics + */ + UpdateCharacterStatistics(request: PlayFabServerModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateplayercustomproperties + */ + UpdatePlayerCustomProperties(request: PlayFabServerModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the values of the specified title-specific statistics for the user + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateplayerstatistics + */ + UpdatePlayerStatistics(request: PlayFabServerModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated + * or added in this call will be readable by users not in the group. By default, data permissions are set to Private. + * Regardless of the permission setting, only members of the group (and the server) can update the data. Shared Groups are + * designed for sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/updatesharedgroupdata + */ + UpdateSharedGroupData(request: PlayFabServerModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserdata + */ + UpdateUserData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserinternaldata + */ + UpdateUserInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the key-value pair data tagged to the specified item, which is read-only from the client. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/updateuserinventoryitemcustomdata + */ + UpdateUserInventoryItemCustomData(request: PlayFabServerModels.UpdateUserInventoryItemDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherdata + */ + UpdateUserPublisherData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherinternaldata + */ + UpdateUserPublisherInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherreadonlydata + */ + UpdateUserPublisherReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserreadonlydata + */ + UpdateUserReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a character-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writecharacterevent + */ + WriteCharacterEvent(request: PlayFabServerModels.WriteServerCharacterEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a player-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writeplayerevent + */ + WritePlayerEvent(request: PlayFabServerModels.WriteServerPlayerEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a title-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writetitleevent + */ + WriteTitleEvent(request: PlayFabServerModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } +} - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddPlayerTagRequest - */ - export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { +declare module PlayFabServerModels { + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + export interface AddCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Amount to be added to the character balance of the specified virtual currency. Maximum VC balance is Int32 + * (2,147,483,647). Any increase over this value will be discarded. */ + Amount: number; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be incremented. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Name of the virtual currency which is to be incremented. */ + VirtualCurrency: string; + + } + + export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Email address of the user being added. */ + FriendEmail?: string; + /** The PlayFab identifier of the user being added. */ + FriendPlayFabId?: string; + /** Title-specific display name of the user to being added. */ + FriendTitleDisplayName?: string; + /** The PlayFab username of the user being added */ + FriendUsername?: string; + /** PlayFab identifier of the player to add a new friend. */ + PlayFabId: string; + + } + + export interface AddGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Generic service identifier to add to the player account. */ + GenericId: GenericServiceId; + /** PlayFabId of the user to link. */ + PlayFabId: string; + + } + + export interface AddOrUpdateContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new contact email to associate with the player. */ + EmailAddress: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface AddOrUpdateContactEmailResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddPlayerTagResult - */ export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddSharedGroupMembersRequest - */ export interface AddSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddSharedGroupMembersResult - */ export interface AddSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / PlayFab unique identifier of the user whose virtual currency balance is to be increased. + * Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). + * Any increase over this value will be discarded. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be increased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be incremented. - */ + /** Name of the virtual currency which is to be incremented. */ VirtualCurrency: string; + + } + + export interface AdvancedPushPlatformMsg { /** - / Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. + * Stops GoogleCloudMessaging notifications from including both notification and data properties and instead only sends the + * data property. */ - Amount: number; + GCMDataOnly?: boolean; + /** The Json the platform should receive. */ + Json: string; + /** The platform that should receive the Json. */ + Platform: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AuthenticateSessionTicketRequest - */ export interface AuthenticateSessionTicketRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Session ticket as issued by a PlayFab client login API. - */ + /** Session ticket as issued by a PlayFab client login API. */ SessionTicket: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AuthenticateSessionTicketResult - */ export interface AuthenticateSessionTicketResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account info for the user whose session ticket was supplied. - */ + /** Indicates if token was expired at request time. */ + IsSessionTicketExpired?: boolean; + /** Account info for the user whose session ticket was supplied. */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementItem - */ export interface AwardSteamAchievementItem { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique Steam achievement name. - */ + /** Unique Steam achievement name. */ AchievementName: string; - /** - / Result of the award attempt (only valid on response, not on request). - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Result of the award attempt (only valid on response, not on request). */ Result: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementRequest - */ export interface AwardSteamAchievementRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of achievements to grant and the users to whom they are to be granted. - */ + /** Array of achievements to grant and the users to whom they are to be granted. */ Achievements: AwardSteamAchievementItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementResult - */ export interface AwardSteamAchievementResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of achievements granted. - */ + /** Array of achievements granted. */ AchievementResults?: AwardSteamAchievementItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanInfo - */ export interface BanInfo { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / The unique Ban Id associated with this ban. - */ + /** The active state of this ban. Expired bans may still have this value set to true but they will have no effect. */ + Active: boolean; + /** The unique Ban Id associated with this ban. */ BanId?: string; - /** - / The IP address on which the ban was applied. May affect multiple players. - */ - IPAddress?: string; - /** - / The MAC address on which the ban was applied. May affect multiple players. - */ - MACAddress?: string; - /** - / The time when this ban was applied. - */ + /** The time when this ban was applied. */ Created?: string; - /** - / The time when this ban expires. Permanent bans do not have expiration date. - */ + /** The time when this ban expires. Permanent bans do not have expiration date. */ Expires?: string; - /** - / The reason why this ban was applied. - */ + /** The IP address on which the ban was applied. May affect multiple players. */ + IPAddress?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** The reason why this ban was applied. */ Reason?: string; - /** - / The active state of this ban. Expired bans may still have this value set to true but they will have no effect. - */ - Active: boolean; + /** The family type of the user that is included in the ban. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanRequest - */ - export interface BanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / IP address to be banned. May affect multiple players. - */ + export interface BanRequest { + /** The duration in hours for the ban. Leave this blank for a permanent ban. */ + DurationInHours?: number; + /** IP address to be banned. May affect multiple players. */ IPAddress?: string; - /** - / MAC address to be banned. May affect multiple players. - */ - MACAddress?: string; - /** - / The reason for this ban. Maximum 140 characters. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The reason for this ban. Maximum 140 characters. */ Reason?: string; - /** - / The duration in hours for the ban. Leave this blank for a permanent ban. - */ - DurationInHours?: number; + /** The family type of the user that should be included in the ban if applicable. May affect multiple players. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanUsersRequest - */ export interface BanUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of ban requests to be applied. Maximum 100. - */ + /** List of ban requests to be applied. Maximum 100. */ Bans: BanRequest[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanUsersResult - */ export interface BanUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were applied - */ + /** Information on the bans that were applied */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItem - */ + export interface BattleNetAccountPlayFabIdPair { + /** Unique Battle.net account identifier for a user. */ + BattleNetAccountId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Battle.net account identifier. */ + PlayFabId?: string; + + } + export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - CustomData?: string; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the consumable properties (number of uses, timeout) for the item + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ - Consumable?: CatalogItemConsumableInfo; + UsagePeriod?: number; /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ - Container?: CatalogItemContainerInfo; + UsagePeriodGroup?: string; + + } + + export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ - Bundle?: CatalogItemBundleInfo; + KeyItemId?: string; /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) - */ - UsagePeriod?: number; - /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed - */ - UsagePeriodGroup?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemContainerInfo - */ - export interface CatalogItemContainerInfo { - /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) - */ - KeyItemId?: string; - /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterInventory - */ export interface CharacterInventory { - /** - / The id of this character. - */ + /** The id of this character. */ CharacterId?: string; - /** - / The inventory of this character. - */ + /** The inventory of this character. */ Inventory?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterLeaderboardEntry - */ export interface CharacterLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. - */ + /** PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. */ CharacterId?: string; - /** - / Title-specific display name of the character for this leaderboard entry. - */ + /** Title-specific display name of the character for this leaderboard entry. */ CharacterName?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Name of the character class for this entry. - */ + /** Name of the character class for this entry. */ CharacterType?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterResult - */ - export interface CharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The id for this character on this player. - */ + export interface CharacterResult { + /** The id for this character on this player. */ CharacterId?: string; - /** - / The name of this character. - */ + /** The name of this character. */ CharacterName?: string; - /** - / The type-string that was given to this character on creation. - */ + /** The type-string that was given to this character on creation. */ CharacterType?: string; } type CloudScriptRevisionOption = "Live" + | "Latest" | "Specific"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ConsumeItemRequest - */ export interface ConsumeItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique instance identifier of the item to be consumed. - */ - ItemInstanceId: string; - /** - / Number of uses to consume from the item. - */ - ConsumeCount: number; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Number of uses to consume from the item. */ + ConsumeCount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be consumed. */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ConsumeItemResult - */ export interface ConsumeItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ + /** Unique instance identifier of the item with uses consumed. */ ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ + /** Number of uses remaining on the item. */ RemainingUses: number; } + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; + + } + type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1406,31 +1562,23 @@ declare module PlayFabServerModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CreateSharedGroupRequest - */ export interface CreateSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). - */ + /** Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). */ SharedGroupId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CreateSharedGroupResult - */ export interface CreateSharedGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the shared group. - */ + /** Unique identifier for the shared group. */ SharedGroupId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1593,3614 +1741,4295 @@ declare module PlayFabServerModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteCharacterFromUserRequest - */ + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; + + } + export interface DeleteCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / If true, the character's inventory will be transferred up to the owning user; otherwise, this request will purge those items. + * If true, the character's inventory will be transferred up to the owning user; otherwise, this request will purge those + * items. */ SaveCharacterInventory: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteCharacterFromUserResult - */ export interface DeleteCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteSharedGroupRequest - */ - export interface DeleteSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteUsersRequest - */ - export interface DeleteUsersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - PlayFabIds: string[]; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; + /** PlayFab unique identifier of the user whose properties were deleted. */ + PlayFabId?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - TitleId: string; + PropertiesVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteUsersResult - */ - export interface DeleteUsersResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeletePlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeregisterGameRequest - */ - export interface DeregisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the Game Server Instance that is being deregistered. - */ - LobbyId: string; + export interface DeletePlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePushNotificationTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Id of the push notification template to be deleted. */ + PushNotificationTemplateId: string; + + } + + export interface DeletePushNotificationTemplateResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeregisterGameResponse - */ - export interface DeregisterGameResponse extends PlayFabModule.IPlayFabResultCommon { + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EmptyResult - */ export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EvaluateRandomResultTableRequest - */ + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + export interface EvaluateRandomResultTableRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / The unique identifier of the Random Result Table to use. - */ - TableId: string; - /** - / Specifies the catalog version that should be used to evaluate the Random Result Table. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to evaluate the Random Result Table. If unspecified, uses + * default/primary catalog. */ CatalogVersion?: string; + /** The unique identifier of the Random Result Table to use. */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EvaluateRandomResultTableResult - */ export interface EvaluateRandomResultTableResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the item returned from the Random Result Table evaluation, for the given catalog. - */ + /** Unique identifier for the item returned from the Random Result Table evaluation, for the given catalog. */ ResultItemId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ExecuteCloudScriptResult - */ export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - FunctionResult?: any; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ Logs?: LogStatement[]; - ExecutionTimeSeconds: number; /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - ProcessorTimeSeconds: number; + LogsTooLarge?: boolean; MemoryConsumedBytes: number; /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; - /** - / Number of external HTTP requests issued by the CloudScript function - */ - HttpRequestsIssued: number; - /** - / Information about the error, if any, that occured during execution + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - Error?: ScriptExecutionError; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ExecuteCloudScriptServerRequest - */ export interface ExecuteCloudScriptServerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The unique user identifier for the player on whose behalf the script is being run - */ - PlayFabId: string; - /** - / The name of the CloudScript function to execute - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the CloudScript function to execute */ FunctionName: string; - /** - / Object that is passed in to the function as the first argument - */ + /** Object that is passed in to the function as the first argument */ FunctionParameter?: any; /** - / Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' executes the current live, published revision, and 'Specific' executes the specified revision. The default value is 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. + * Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. */ - RevisionSelection?: string; + GeneratePlayStreamEvent?: boolean; + /** The unique user identifier for the player on whose behalf the script is being run */ + PlayFabId: string; /** - / The specivic revision to execute, when RevisionSelection is set to 'Specific' + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. */ + RevisionSelection?: string; + /** The specivic revision to execute, when RevisionSelection is set to 'Specific' */ SpecificRevision?: number; - /** - / Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. - */ - GeneratePlayStreamEvent?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.FacebookPlayFabIdPair - */ + export interface ExportPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the requested segment. */ + SegmentId: string; + + } + + export interface ExportPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId?: string; + /** Unique identifier of the requested Segment. */ + SegmentId?: string; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FacebookInstantGamesPlayFabIdPair { + /** Unique Facebook Instant Games identifier for a user. */ + FacebookInstantGamesId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook Instant Games identifier. */ + PlayFabId?: string; + + } + export interface FacebookPlayFabIdPair { - /** - / Unique Facebook identifier for a user. - */ + /** Unique Facebook identifier for a user. */ FacebookId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.FriendInfo - */ export interface FriendInfo { - /** - / PlayFab unique identifier for this friend. - */ + /** Available Facebook information (if the user and connected Facebook friend both have PlayFab Accounts in the same title). */ + FacebookInfo?: UserFacebookInfo; + /** PlayFab unique identifier for this friend. */ FriendPlayFabId?: string; /** - / PlayFab unique username for this friend. - */ - Username?: string; - /** - / Title-specific display name for this friend. - */ - TitleDisplayName?: string; - /** - / Tags which have been associated with this friend. - */ - Tags?: string[]; - /** - / Unique lobby identifier of the Game Server Instance to which this player is currently connected. + * Available Game Center information (if the user and connected Game Center friend both have PlayFab Accounts in the same + * title). */ - CurrentMatchmakerLobbyId?: string; - /** - / Available Facebook information (if the user and PlayFab friend are also connected in Facebook). - */ - FacebookInfo?: UserFacebookInfo; + GameCenterInfo?: UserGameCenterInfo; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; /** - / Available Steam information (if the user and PlayFab friend are also connected in Steam). + * Available PlayStation :tm: Network information, if the user connected PlayStation :tm Network friend both have PlayFab + * Accounts in the same title. */ + PSNInfo?: UserPsnInfo; + /** Available Steam information (if the user and connected Steam friend both have PlayFab Accounts in the same title). */ SteamInfo?: UserSteamInfo; - /** - / Available Game Center information (if the user and PlayFab friend are also connected in Game Center). - */ - GameCenterInfo?: UserGameCenterInfo; + /** Tags which have been associated with this friend. */ + Tags?: string[]; + /** Title-specific display name for this friend. */ + TitleDisplayName?: string; + /** PlayFab unique username for this friend. */ + Username?: string; + /** Available Xbox information, (if the user and connected Xbox Live friend both have PlayFab Accounts in the same title). */ + XboxInfo?: UserXboxInfo; } - type GameInstanceState = "Open" - | "Closed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetActionGroupResult - */ - export interface GetActionGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Action Group name - */ - Name: string; - /** - / Action Group ID - */ - Id?: string; + type GenericErrorCodes = "Success" + + | "UnkownError" + | "InvalidParams" + | "AccountNotFound" + | "AccountBanned" + | "InvalidUsernameOrPassword" + | "InvalidTitleId" + | "InvalidEmailAddress" + | "EmailAddressNotAvailable" + | "InvalidUsername" + | "InvalidPassword" + | "UsernameNotAvailable" + | "InvalidSteamTicket" + | "AccountAlreadyLinked" + | "LinkedAccountAlreadyClaimed" + | "InvalidFacebookToken" + | "AccountNotLinked" + | "FailedByPaymentProvider" + | "CouponCodeNotFound" + | "InvalidContainerItem" + | "ContainerNotOwned" + | "KeyNotOwned" + | "InvalidItemIdInTable" + | "InvalidReceipt" + | "ReceiptAlreadyUsed" + | "ReceiptCancelled" + | "GameNotFound" + | "GameModeNotFound" + | "InvalidGoogleToken" + | "UserIsNotPartOfDeveloper" + | "InvalidTitleForDeveloper" + | "TitleNameConflicts" + | "UserisNotValid" + | "ValueAlreadyExists" + | "BuildNotFound" + | "PlayerNotInGame" + | "InvalidTicket" + | "InvalidDeveloper" + | "InvalidOrderInfo" + | "RegistrationIncomplete" + | "InvalidPlatform" + | "UnknownError" + | "SteamApplicationNotOwned" + | "WrongSteamAccount" + | "TitleNotActivated" + | "RegistrationSessionNotFound" + | "NoSuchMod" + | "FileNotFound" + | "DuplicateEmail" + | "ItemNotFound" + | "ItemNotOwned" + | "ItemNotRecycleable" + | "ItemNotAffordable" + | "InvalidVirtualCurrency" + | "WrongVirtualCurrency" + | "WrongPrice" + | "NonPositiveValue" + | "InvalidRegion" + | "RegionAtCapacity" + | "ServerFailedToStart" + | "NameNotAvailable" + | "InsufficientFunds" + | "InvalidDeviceID" + | "InvalidPushNotificationToken" + | "NoRemainingUses" + | "InvalidPaymentProvider" + | "PurchaseInitializationFailure" + | "DuplicateUsername" + | "InvalidBuyerInfo" + | "NoGameModeParamsSet" + | "BodyTooLarge" + | "ReservedWordInBody" + | "InvalidTypeInBody" + | "InvalidRequest" + | "ReservedEventName" + | "InvalidUserStatistics" + | "NotAuthenticated" + | "StreamAlreadyExists" + | "ErrorCreatingStream" + | "StreamNotFound" + | "InvalidAccount" + | "PurchaseDoesNotExist" + | "InvalidPurchaseTransactionStatus" + | "APINotEnabledForGameClientAccess" + | "NoPushNotificationARNForTitle" + | "BuildAlreadyExists" + | "BuildPackageDoesNotExist" + | "CustomAnalyticsEventsNotEnabledForTitle" + | "InvalidSharedGroupId" + | "NotAuthorized" + | "MissingTitleGoogleProperties" + | "InvalidItemProperties" + | "InvalidPSNAuthCode" + | "InvalidItemId" + | "PushNotEnabledForAccount" + | "PushServiceError" + | "ReceiptDoesNotContainInAppItems" + | "ReceiptContainsMultipleInAppItems" + | "InvalidBundleID" + | "JavascriptException" + | "InvalidSessionTicket" + | "UnableToConnectToDatabase" + | "InternalServerError" + | "InvalidReportDate" + | "DatabaseThroughputExceeded" + | "InvalidGameTicket" + | "ExpiredGameTicket" + | "GameTicketDoesNotMatchLobby" + | "LinkedDeviceAlreadyClaimed" + | "DeviceAlreadyLinked" + | "DeviceNotLinked" + | "PartialFailure" + | "PublisherNotSet" + | "ServiceUnavailable" + | "VersionNotFound" + | "RevisionNotFound" + | "InvalidPublisherId" + | "DownstreamServiceUnavailable" + | "APINotIncludedInTitleUsageTier" + | "DAULimitExceeded" + | "APIRequestLimitExceeded" + | "InvalidAPIEndpoint" + | "BuildNotAvailable" + | "ConcurrentEditError" + | "ContentNotFound" + | "CharacterNotFound" + | "CloudScriptNotFound" + | "ContentQuotaExceeded" + | "InvalidCharacterStatistics" + | "PhotonNotEnabledForTitle" + | "PhotonApplicationNotFound" + | "PhotonApplicationNotAssociatedWithTitle" + | "InvalidEmailOrPassword" + | "FacebookAPIError" + | "InvalidContentType" + | "KeyLengthExceeded" + | "DataLengthExceeded" + | "TooManyKeys" + | "FreeTierCannotHaveVirtualCurrency" + | "MissingAmazonSharedKey" + | "AmazonValidationError" + | "InvalidPSNIssuerId" + | "PSNInaccessible" + | "ExpiredAuthToken" + | "FailedToGetEntitlements" + | "FailedToConsumeEntitlement" + | "TradeAcceptingUserNotAllowed" + | "TradeInventoryItemIsAssignedToCharacter" + | "TradeInventoryItemIsBundle" + | "TradeStatusNotValidForCancelling" + | "TradeStatusNotValidForAccepting" + | "TradeDoesNotExist" + | "TradeCancelled" + | "TradeAlreadyFilled" + | "TradeWaitForStatusTimeout" + | "TradeInventoryItemExpired" + | "TradeMissingOfferedAndAcceptedItems" + | "TradeAcceptedItemIsBundle" + | "TradeAcceptedItemIsStackable" + | "TradeInventoryItemInvalidStatus" + | "TradeAcceptedCatalogItemInvalid" + | "TradeAllowedUsersInvalid" + | "TradeInventoryItemDoesNotExist" + | "TradeInventoryItemIsConsumed" + | "TradeInventoryItemIsStackable" + | "TradeAcceptedItemsMismatch" + | "InvalidKongregateToken" + | "FeatureNotConfiguredForTitle" + | "NoMatchingCatalogItemForReceipt" + | "InvalidCurrencyCode" + | "NoRealMoneyPriceForCatalogItem" + | "TradeInventoryItemIsNotTradable" + | "TradeAcceptedCatalogItemIsNotTradable" + | "UsersAlreadyFriends" + | "LinkedIdentifierAlreadyClaimed" + | "CustomIdNotLinked" + | "TotalDataSizeExceeded" + | "DeleteKeyConflict" + | "InvalidXboxLiveToken" + | "ExpiredXboxLiveToken" + | "ResettableStatisticVersionRequired" + | "NotAuthorizedByTitle" + | "NoPartnerEnabled" + | "InvalidPartnerResponse" + | "APINotEnabledForGameServerAccess" + | "StatisticNotFound" + | "StatisticNameConflict" + | "StatisticVersionClosedForWrites" + | "StatisticVersionInvalid" + | "APIClientRequestRateLimitExceeded" + | "InvalidJSONContent" + | "InvalidDropTable" + | "StatisticVersionAlreadyIncrementedForScheduledInterval" + | "StatisticCountLimitExceeded" + | "StatisticVersionIncrementRateExceeded" + | "ContainerKeyInvalid" + | "CloudScriptExecutionTimeLimitExceeded" + | "NoWritePermissionsForEvent" + | "CloudScriptFunctionArgumentSizeExceeded" + | "CloudScriptAPIRequestCountExceeded" + | "CloudScriptAPIRequestError" + | "CloudScriptHTTPRequestError" + | "InsufficientGuildRole" + | "GuildNotFound" + | "OverLimit" + | "EventNotFound" + | "InvalidEventField" + | "InvalidEventName" + | "CatalogNotConfigured" + | "OperationNotSupportedForPlatform" + | "SegmentNotFound" + | "StoreNotFound" + | "InvalidStatisticName" + | "TitleNotQualifiedForLimit" + | "InvalidServiceLimitLevel" + | "ServiceLimitLevelInTransition" + | "CouponAlreadyRedeemed" + | "GameServerBuildSizeLimitExceeded" + | "GameServerBuildCountLimitExceeded" + | "VirtualCurrencyCountLimitExceeded" + | "VirtualCurrencyCodeExists" + | "TitleNewsItemCountLimitExceeded" + | "InvalidTwitchToken" + | "TwitchResponseError" + | "ProfaneDisplayName" + | "UserAlreadyAdded" + | "InvalidVirtualCurrencyCode" + | "VirtualCurrencyCannotBeDeleted" + | "IdentifierAlreadyClaimed" + | "IdentifierNotLinked" + | "InvalidContinuationToken" + | "ExpiredContinuationToken" + | "InvalidSegment" + | "InvalidSessionId" + | "SessionLogNotFound" + | "InvalidSearchTerm" + | "TwoFactorAuthenticationTokenRequired" + | "GameServerHostCountLimitExceeded" + | "PlayerTagCountLimitExceeded" + | "RequestAlreadyRunning" + | "ActionGroupNotFound" + | "MaximumSegmentBulkActionJobsRunning" + | "NoActionsOnPlayersInSegmentJob" + | "DuplicateStatisticName" + | "ScheduledTaskNameConflict" + | "ScheduledTaskCreateConflict" + | "InvalidScheduledTaskName" + | "InvalidTaskSchedule" + | "SteamNotEnabledForTitle" + | "LimitNotAnUpgradeOption" + | "NoSecretKeyEnabledForCloudScript" + | "TaskNotFound" + | "TaskInstanceNotFound" + | "InvalidIdentityProviderId" + | "MisconfiguredIdentityProvider" + | "InvalidScheduledTaskType" + | "BillingInformationRequired" + | "LimitedEditionItemUnavailable" + | "InvalidAdPlacementAndReward" + | "AllAdPlacementViewsAlreadyConsumed" + | "GoogleOAuthNotConfiguredForTitle" + | "GoogleOAuthError" + | "UserNotFriend" + | "InvalidSignature" + | "InvalidPublicKey" + | "GoogleOAuthNoIdTokenIncludedInResponse" + | "StatisticUpdateInProgress" + | "LeaderboardVersionNotAvailable" + | "StatisticAlreadyHasPrizeTable" + | "PrizeTableHasOverlappingRanks" + | "PrizeTableHasMissingRanks" + | "PrizeTableRankStartsAtZero" + | "InvalidStatistic" + | "ExpressionParseFailure" + | "ExpressionInvokeFailure" + | "ExpressionTooLong" + | "DataUpdateRateExceeded" + | "RestrictedEmailDomain" + | "EncryptionKeyDisabled" + | "EncryptionKeyMissing" + | "EncryptionKeyBroken" + | "NoSharedSecretKeyConfigured" + | "SecretKeyNotFound" + | "PlayerSecretAlreadyConfigured" + | "APIRequestsDisabledForTitle" + | "InvalidSharedSecretKey" + | "PrizeTableHasNoRanks" + | "ProfileDoesNotExist" + | "ContentS3OriginBucketNotConfigured" + | "InvalidEnvironmentForReceipt" + | "EncryptedRequestNotAllowed" + | "SignedRequestNotAllowed" + | "RequestViewConstraintParamsNotAllowed" + | "BadPartnerConfiguration" + | "XboxBPCertificateFailure" + | "XboxXASSExchangeFailure" + | "InvalidEntityId" + | "StatisticValueAggregationOverflow" + | "EmailMessageFromAddressIsMissing" + | "EmailMessageToAddressIsMissing" + | "SmtpServerAuthenticationError" + | "SmtpServerLimitExceeded" + | "SmtpServerInsufficientStorage" + | "SmtpServerCommunicationError" + | "SmtpServerGeneralFailure" + | "EmailClientTimeout" + | "EmailClientCanceledTask" + | "EmailTemplateMissing" + | "InvalidHostForTitleId" + | "EmailConfirmationTokenDoesNotExist" + | "EmailConfirmationTokenExpired" + | "AccountDeleted" + | "PlayerSecretNotConfigured" + | "InvalidSignatureTime" + | "NoContactEmailAddressFound" + | "InvalidAuthToken" + | "AuthTokenDoesNotExist" + | "AuthTokenExpired" + | "AuthTokenAlreadyUsedToResetPassword" + | "MembershipNameTooLong" + | "MembershipNotFound" + | "GoogleServiceAccountInvalid" + | "GoogleServiceAccountParseFailure" + | "EntityTokenMissing" + | "EntityTokenInvalid" + | "EntityTokenExpired" + | "EntityTokenRevoked" + | "InvalidProductForSubscription" + | "XboxInaccessible" + | "SubscriptionAlreadyTaken" + | "SmtpAddonNotEnabled" + | "APIConcurrentRequestLimitExceeded" + | "XboxRejectedXSTSExchangeRequest" + | "VariableNotDefined" + | "TemplateVersionNotDefined" + | "FileTooLarge" + | "TitleDeleted" + | "TitleContainsUserAccounts" + | "TitleDeletionPlayerCleanupFailure" + | "EntityFileOperationPending" + | "NoEntityFileOperationPending" + | "EntityProfileVersionMismatch" + | "TemplateVersionTooOld" + | "MembershipDefinitionInUse" + | "PaymentPageNotConfigured" + | "FailedLoginAttemptRateLimitExceeded" + | "EntityBlockedByGroup" + | "RoleDoesNotExist" + | "EntityIsAlreadyMember" + | "DuplicateRoleId" + | "GroupInvitationNotFound" + | "GroupApplicationNotFound" + | "OutstandingInvitationAcceptedInstead" + | "OutstandingApplicationAcceptedInstead" + | "RoleIsGroupDefaultMember" + | "RoleIsGroupAdmin" + | "RoleNameNotAvailable" + | "GroupNameNotAvailable" + | "EmailReportAlreadySent" + | "EmailReportRecipientBlacklisted" + | "EventNamespaceNotAllowed" + | "EventEntityNotAllowed" + | "InvalidEntityType" + | "NullTokenResultFromAad" + | "InvalidTokenResultFromAad" + | "NoValidCertificateForAad" + | "InvalidCertificateForAad" + | "DuplicateDropTableId" + | "MultiplayerServerError" + | "MultiplayerServerTooManyRequests" + | "MultiplayerServerNoContent" + | "MultiplayerServerBadRequest" + | "MultiplayerServerUnauthorized" + | "MultiplayerServerForbidden" + | "MultiplayerServerNotFound" + | "MultiplayerServerConflict" + | "MultiplayerServerInternalServerError" + | "MultiplayerServerUnavailable" + | "ExplicitContentDetected" + | "PIIContentDetected" + | "InvalidScheduledTaskParameter" + | "PerEntityEventRateLimitExceeded" + | "TitleDefaultLanguageNotSet" + | "EmailTemplateMissingDefaultVersion" + | "FacebookInstantGamesIdNotLinked" + | "InvalidFacebookInstantGamesSignature" + | "FacebookInstantGamesAuthNotConfiguredForTitle" + | "EntityProfileConstraintValidationFailed" + | "TelemetryIngestionKeyPending" + | "TelemetryIngestionKeyNotFound" + | "StatisticChildNameInvalid" + | "DataIntegrityError" + | "VirtualCurrencyCannotBeSetToOlderVersion" + | "VirtualCurrencyMustBeWithinIntegerRange" + | "EmailTemplateInvalidSyntax" + | "EmailTemplateMissingCallback" + | "PushNotificationTemplateInvalidPayload" + | "InvalidLocalizedPushNotificationLanguage" + | "MissingLocalizedPushNotificationMessage" + | "PushNotificationTemplateMissingPlatformPayload" + | "PushNotificationTemplatePayloadContainsInvalidJson" + | "PushNotificationTemplateContainsInvalidIosPayload" + | "PushNotificationTemplateContainsInvalidAndroidPayload" + | "PushNotificationTemplateIosPayloadMissingNotificationBody" + | "PushNotificationTemplateAndroidPayloadMissingNotificationBody" + | "PushNotificationTemplateNotFound" + | "PushNotificationTemplateMissingDefaultVersion" + | "PushNotificationTemplateInvalidSyntax" + | "PushNotificationTemplateNoCustomPayloadForV1" + | "NoLeaderboardForStatistic" + | "TitleNewsMissingDefaultLanguage" + | "TitleNewsNotFound" + | "TitleNewsDuplicateLanguage" + | "TitleNewsMissingTitleOrBody" + | "TitleNewsInvalidLanguage" + | "EmailRecipientBlacklisted" + | "InvalidGameCenterAuthRequest" + | "GameCenterAuthenticationFailed" + | "CannotEnablePartiesForTitle" + | "PartyError" + | "PartyRequests" + | "PartyNoContent" + | "PartyBadRequest" + | "PartyUnauthorized" + | "PartyForbidden" + | "PartyNotFound" + | "PartyConflict" + | "PartyInternalServerError" + | "PartyUnavailable" + | "PartyTooManyRequests" + | "PushNotificationTemplateMissingName" + | "CannotEnableMultiplayerServersForTitle" + | "WriteAttemptedDuringExport" + | "MultiplayerServerTitleQuotaCoresExceeded" + | "AutomationRuleNotFound" + | "EntityAPIKeyLimitExceeded" + | "EntityAPIKeyNotFound" + | "EntityAPIKeyOrSecretInvalid" + | "EconomyServiceUnavailable" + | "EconomyServiceInternalError" + | "QueryRateLimitExceeded" + | "EntityAPIKeyCreationDisabledForEntity" + | "ForbiddenByEntityPolicy" + | "UpdateInventoryRateLimitExceeded" + | "StudioCreationRateLimited" + | "StudioCreationInProgress" + | "DuplicateStudioName" + | "StudioNotFound" + | "StudioDeleted" + | "StudioDeactivated" + | "StudioActivated" + | "TitleCreationRateLimited" + | "TitleCreationInProgress" + | "DuplicateTitleName" + | "TitleActivationRateLimited" + | "TitleActivationInProgress" + | "TitleDeactivated" + | "TitleActivated" + | "CloudScriptAzureFunctionsExecutionTimeLimitExceeded" + | "CloudScriptAzureFunctionsArgumentSizeExceeded" + | "CloudScriptAzureFunctionsReturnSizeExceeded" + | "CloudScriptAzureFunctionsHTTPRequestError" + | "VirtualCurrencyBetaGetError" + | "VirtualCurrencyBetaCreateError" + | "VirtualCurrencyBetaInitialDepositSaveError" + | "VirtualCurrencyBetaSaveError" + | "VirtualCurrencyBetaDeleteError" + | "VirtualCurrencyBetaRestoreError" + | "VirtualCurrencyBetaSaveConflict" + | "VirtualCurrencyBetaUpdateError" + | "InsightsManagementDatabaseNotFound" + | "InsightsManagementOperationNotFound" + | "InsightsManagementErrorPendingOperationExists" + | "InsightsManagementSetPerformanceLevelInvalidParameter" + | "InsightsManagementSetStorageRetentionInvalidParameter" + | "InsightsManagementGetStorageUsageInvalidParameter" + | "InsightsManagementGetOperationStatusInvalidParameter" + | "DuplicatePurchaseTransactionId" + | "EvaluationModePlayerCountExceeded" + | "CloudScriptFunctionNameSizeExceeded" + | "PaidInsightsFeaturesNotEnabled" + | "CloudScriptAzureFunctionsQueueRequestError" + | "EvaluationModeTitleCountExceeded" + | "InsightsManagementTitleNotInFlight" + | "LimitNotFound" + | "LimitNotAvailableViaAPI" + | "InsightsManagementSetStorageRetentionBelowMinimum" + | "InsightsManagementSetStorageRetentionAboveMaximum" + | "AppleNotEnabledForTitle" + | "InsightsManagementNewActiveEventExportLimitInvalid" + | "InsightsManagementSetPerformanceRateLimited" + | "PartyRequestsThrottledFromRateLimiter" + | "XboxServiceTooManyRequests" + | "NintendoSwitchNotEnabledForTitle" + | "RequestMultiplayerServersThrottledFromRateLimiter" + | "TitleDataOverrideNotFound" + | "DuplicateKeys" + | "WasNotCreatedWithCloudRoot" + | "LegacyMultiplayerServersDeprecated" + | "VirtualCurrencyCurrentlyUnavailable" + | "SteamUserNotFound" + | "ElasticSearchOperationFailed" + | "NotImplemented" + | "PublisherNotFound" + | "PublisherDeleted" + | "ApiDisabledForMigration" + | "ResourceNameUpdateNotAllowed" + | "ApiNotEnabledForTitle" + | "DuplicateTitleNameForPublisher" + | "AzureTitleCreationInProgress" + | "TitleConstraintsPublisherDeletion" + | "InvalidPlayerAccountPoolId" + | "PlayerAccountPoolNotFound" + | "PlayerAccountPoolDeleted" + | "TitleCleanupInProgress" + | "AzureResourceConcurrentOperationInProgress" + | "TitlePublisherUpdateNotAllowed" + | "AzureResourceManagerNotSupportedInStamp" + | "ApiNotIncludedInAzurePlayFabFeatureSet" + | "GoogleServiceAccountFailedAuth" + | "GoogleAPIServiceUnavailable" + | "GoogleAPIServiceUnknownError" + | "NoValidIdentityForAad" + | "PlayerIdentityLinkNotFound" + | "PhotonApplicationIdAlreadyInUse" + | "CloudScriptUnableToDeleteProductionRevision" + | "CustomIdNotFound" + | "AutomationInvalidInput" + | "AutomationInvalidRuleName" + | "AutomationRuleAlreadyExists" + | "AutomationRuleLimitExceeded" + | "InvalidGooglePlayGamesServerAuthCode" + | "PlayStreamConnectionFailed" + | "InvalidEventContents" + | "InsightsV1Deprecated" + | "AnalysisSubscriptionNotFound" + | "AnalysisSubscriptionFailed" + | "AnalysisSubscriptionFoundAlready" + | "AnalysisSubscriptionManagementInvalidInput" + | "InvalidGameCenterId" + | "InvalidNintendoSwitchAccountId" + | "EntityAPIKeysNotSupported" + | "IpAddressBanned" + | "EntityLineageBanned" + | "NamespaceMismatch" + | "InvalidServiceConfiguration" + | "InvalidNamespaceMismatch" + | "LeaderboardColumnLengthMismatch" + | "InvalidStatisticScore" + | "LeaderboardColumnsNotSpecified" + | "LeaderboardMaxSizeTooLarge" + | "InvalidAttributeStatisticsSpecified" + | "LeaderboardNotFound" + | "TokenSigningKeyNotFound" + | "LeaderboardNameConflict" + | "LinkedStatisticColumnMismatch" + | "NoLinkedStatisticToLeaderboard" + | "StatDefinitionAlreadyLinkedToLeaderboard" + | "LinkingStatsNotAllowedForEntityType" + | "LeaderboardCountLimitExceeded" + | "LeaderboardSizeLimitExceeded" + | "LeaderboardDefinitionModificationNotAllowedWhileLinked" + | "StatisticDefinitionModificationNotAllowedWhileLinked" + | "LeaderboardUpdateNotAllowedWhileLinked" + | "CloudScriptAzureFunctionsEventHubRequestError" + | "ExternalEntityNotAllowedForTier" + | "InvalidBaseTimeForInterval" + | "EntityTypeMismatchWithStatDefinition" + | "SpecifiedVersionLeaderboardNotFound" + | "LeaderboardColumnLengthMismatchWithStatDefinition" + | "DuplicateColumnNameFound" + | "LinkedStatisticColumnNotFound" + | "LinkedStatisticColumnRequired" + | "MultipleLinkedStatisticsNotAllowed" + | "DuplicateLinkedStatisticColumnNameFound" + | "AggregationTypeNotAllowedForMultiColumnStatistic" + | "MaxQueryableVersionsValueNotAllowedForTier" + | "StatisticDefinitionHasNullOrEmptyVersionConfiguration" + | "StatisticColumnLengthMismatch" + | "InvalidExternalEntityId" + | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" + | "ResetIntervalCannotBeModified" + | "VersionIncrementRateExceeded" + | "InvalidSteamUsername" + | "InvalidVersionResetForLinkedLeaderboard" + | "BattleNetNotEnabledForTitle" + | "ReportNotProcessed" + | "DataNotAvailable" + | "InvalidReportName" + | "ResourceNotModified" + | "StudioCreationLimitExceeded" + | "StudioDeletionInitiated" + | "ProductDisabledForTitle" + | "PreconditionFailed" + | "CannotEnableAnonymousPlayerCreation" + | "ParentCustomerAccountNotFound" + | "AccountLinkedToABannedPlayer" + | "AzureSubscriptionNotEligibleForLinking" + | "EntityIsNotAMember" + | "IPAddressNotFound" + | "PSNNextGenNotConfiguredForTitle" + | "InvalidNintendoIssuer" + | "MatchmakingEntityInvalid" + | "MatchmakingPlayerAttributesInvalid" + | "MatchmakingQueueNotFound" + | "MatchmakingMatchNotFound" + | "MatchmakingTicketNotFound" + | "MatchmakingAlreadyJoinedTicket" + | "MatchmakingTicketAlreadyCompleted" + | "MatchmakingQueueConfigInvalid" + | "MatchmakingMemberProfileInvalid" + | "NintendoSwitchDeviceIdNotLinked" + | "MatchmakingNotEnabled" + | "MatchmakingPlayerAttributesTooLarge" + | "MatchmakingNumberOfPlayersInTicketTooLarge" + | "MatchmakingAttributeInvalid" + | "MatchmakingPlayerHasNotJoinedTicket" + | "MatchmakingRateLimitExceeded" + | "MatchmakingTicketMembershipLimitExceeded" + | "MatchmakingUnauthorized" + | "MatchmakingQueueLimitExceeded" + | "MatchmakingRequestTypeMismatch" + | "MatchmakingBadRequest" + | "PubSubFeatureNotEnabledForTitle" + | "PubSubTooManyRequests" + | "PubSubConnectionNotFoundForEntity" + | "PubSubConnectionHandleInvalid" + | "PubSubSubscriptionLimitExceeded" + | "TitleConfigNotFound" + | "TitleConfigUpdateConflict" + | "TitleConfigSerializationError" + | "CatalogApiNotImplemented" + | "CatalogEntityInvalid" + | "CatalogTitleIdMissing" + | "CatalogPlayerIdMissing" + | "CatalogClientIdentityInvalid" + | "CatalogOneOrMoreFilesInvalid" + | "CatalogItemMetadataInvalid" + | "CatalogItemIdInvalid" + | "CatalogSearchParameterInvalid" + | "CatalogFeatureDisabled" + | "CatalogConfigInvalid" + | "CatalogItemTypeInvalid" + | "CatalogBadRequest" + | "CatalogTooManyRequests" + | "InvalidCatalogItemConfiguration" + | "LegacyEconomyDisabled" + | "ExportInvalidStatusUpdate" + | "ExportInvalidPrefix" + | "ExportBlobContainerDoesNotExist" + | "ExportNotFound" + | "ExportCouldNotUpdate" + | "ExportInvalidStorageType" + | "ExportAmazonBucketDoesNotExist" + | "ExportInvalidBlobStorage" + | "ExportKustoException" + | "ExportKustoConnectionFailed" + | "ExportUnknownError" + | "ExportCantEditPendingExport" + | "ExportLimitExports" + | "ExportLimitEvents" + | "ExportInvalidPartitionStatusModification" + | "ExportCouldNotCreate" + | "ExportNoBackingDatabaseFound" + | "ExportCouldNotDelete" + | "ExportCannotDetermineEventQuery" + | "ExportInvalidQuerySchemaModification" + | "ExportQuerySchemaMissingRequiredColumns" + | "ExportCannotParseQuery" + | "ExportControlCommandsNotAllowed" + | "ExportQueryMissingTableReference" + | "ExportInsightsV1Deprecated" + | "ExplorerBasicInvalidQueryName" + | "ExplorerBasicInvalidQueryDescription" + | "ExplorerBasicInvalidQueryConditions" + | "ExplorerBasicInvalidQueryStartDate" + | "ExplorerBasicInvalidQueryEndDate" + | "ExplorerBasicInvalidQueryGroupBy" + | "ExplorerBasicInvalidQueryAggregateType" + | "ExplorerBasicInvalidQueryAggregateProperty" + | "ExplorerBasicLoadQueriesError" + | "ExplorerBasicLoadQueryError" + | "ExplorerBasicCreateQueryError" + | "ExplorerBasicDeleteQueryError" + | "ExplorerBasicUpdateQueryError" + | "ExplorerBasicSavedQueriesLimit" + | "ExplorerBasicSavedQueryNotFound" + | "TenantShardMapperShardNotFound" + | "TitleNotEnabledForParty" + | "PartyVersionNotFound" + | "MultiplayerServerBuildReferencedByMatchmakingQueue" + | "MultiplayerServerBuildReferencedByBuildAlias" + | "MultiplayerServerBuildAliasReferencedByMatchmakingQueue" + | "PartySerializationError" + | "ExperimentationExperimentStopped" + | "ExperimentationExperimentRunning" + | "ExperimentationExperimentNotFound" + | "ExperimentationExperimentNeverStarted" + | "ExperimentationExperimentDeleted" + | "ExperimentationClientTimeout" + | "ExperimentationInvalidVariantConfiguration" + | "ExperimentationInvalidVariableConfiguration" + | "ExperimentInvalidId" + | "ExperimentationNoScorecard" + | "ExperimentationTreatmentAssignmentFailed" + | "ExperimentationTreatmentAssignmentDisabled" + | "ExperimentationInvalidDuration" + | "ExperimentationMaxExperimentsReached" + | "ExperimentationExperimentSchedulingInProgress" + | "ExperimentationInvalidEndDate" + | "ExperimentationInvalidStartDate" + | "ExperimentationMaxDurationExceeded" + | "ExperimentationExclusionGroupNotFound" + | "ExperimentationExclusionGroupInsufficientCapacity" + | "ExperimentationExclusionGroupCannotDelete" + | "ExperimentationExclusionGroupInvalidTrafficAllocation" + | "ExperimentationExclusionGroupInvalidName" + | "ExperimentationLegacyExperimentInvalidOperation" + | "ExperimentationExperimentStopFailed" + | "ExperimentationExperimentDeleteFailed" + | "ExperimentationExperimentStartFailed" + | "MaxActionDepthExceeded" + | "TitleNotOnUpdatedPricingPlan" + | "SegmentManagementTitleNotInFlight" + | "SegmentManagementNoExpressionTree" + | "SegmentManagementTriggerActionCountOverLimit" + | "SegmentManagementSegmentCountOverLimit" + | "SegmentManagementInvalidSegmentId" + | "SegmentManagementInvalidInput" + | "SegmentManagementInvalidSegmentName" + | "DeleteSegmentRateLimitExceeded" + | "CreateSegmentRateLimitExceeded" + | "UpdateSegmentRateLimitExceeded" + | "GetSegmentsRateLimitExceeded" + | "AsyncExportNotInFlight" + | "AsyncExportNotFound" + | "AsyncExportRateLimitExceeded" + | "AnalyticsSegmentCountOverLimit" + | "GetSegmentPlayerCountNotInFlight" + | "GetSegmentPlayerCountRateLimitExceeded" + | "SnapshotNotFound" + | "InventoryApiNotImplemented" + | "InventoryCollectionDeletionDisallowed" + | "LobbyDoesNotExist" + | "LobbyRateLimitExceeded" + | "LobbyPlayerAlreadyJoined" + | "LobbyNotJoinable" + | "LobbyMemberCannotRejoin" + | "LobbyCurrentPlayersMoreThanMaxPlayers" + | "LobbyPlayerNotPresent" + | "LobbyBadRequest" + | "LobbyPlayerMaxLobbyLimitExceeded" + | "LobbyNewOwnerMustBeConnected" + | "LobbyCurrentOwnerStillConnected" + | "LobbyMemberIsNotOwner" + | "LobbyServerMismatch" + | "LobbyServerNotFound" + | "LobbyDifferentServerAlreadyJoined" + | "LobbyServerAlreadyJoined" + | "LobbyIsNotClientOwned" + | "LobbyDoesNotUseConnections" + | "EventSamplingInvalidRatio" + | "EventSamplingInvalidEventNamespace" + | "EventSamplingInvalidEventName" + | "EventSamplingRatioNotFound" + | "TelemetryKeyNotFound" + | "TelemetryKeyInvalidName" + | "TelemetryKeyAlreadyExists" + | "TelemetryKeyInvalid" + | "TelemetryKeyCountOverLimit" + | "TelemetryKeyDeactivated" + | "TelemetryKeyLongInsightsRetentionNotAllowed" + | "EventSinkConnectionInvalid" + | "EventSinkConnectionUnauthorized" + | "EventSinkRegionInvalid" + | "EventSinkLimitExceeded" + | "EventSinkSasTokenInvalid" + | "EventSinkNotFound" + | "EventSinkNameInvalid" + | "EventSinkSasTokenPermissionInvalid" + | "EventSinkSecretInvalid" + | "EventSinkTenantNotFound" + | "EventSinkAadNotFound" + | "EventSinkDatabaseNotFound" + | "EventSinkTitleUnauthorized" + | "EventSinkInsufficientRoleAssignment" + | "EventSinkContainerNotFound" + | "EventSinkTenantIdInvalid" + | "EventSinkResourceMisconfigured" + | "EventSinkAccessDenied" + | "EventSinkWriteConflict" + | "EventSinkResourceNotFound" + | "EventSinkResourceFeatureNotSupported" + | "EventSinkBucketNameInvalid" + | "EventSinkResourceUnavailable" + | "OperationCanceled" + | "InvalidDisplayNameRandomSuffixLength" + | "AllowNonUniquePlayerDisplayNamesDisableNotAllowed" + | "PartitionedEventInvalid" + | "PartitionedEventCountOverLimit" + | "ManageEventNamespaceInvalid" + | "ManageEventNameInvalid" + | "ManagedEventNotFound" + | "ManageEventsInvalidRatio" + | "ManagedEventInvalid" + | "PlayerCustomPropertiesPropertyNameTooLong" + | "PlayerCustomPropertiesPropertyNameIsInvalid" + | "PlayerCustomPropertiesStringPropertyValueTooLong" + | "PlayerCustomPropertiesValueIsInvalidType" + | "PlayerCustomPropertiesVersionMismatch" + | "PlayerCustomPropertiesPropertyCountTooHigh" + | "PlayerCustomPropertiesDuplicatePropertyName" + | "PlayerCustomPropertiesPropertyDoesNotExist" + | "AddonAlreadyExists" + | "AddonDoesntExist" + | "TrueSkillUnauthorized" + | "TrueSkillInvalidTitleId" + | "TrueSkillInvalidScenarioId" + | "TrueSkillInvalidModelId" + | "TrueSkillInvalidModelName" + | "TrueSkillInvalidPlayerIds" + | "TrueSkillInvalidEntityKey" + | "TrueSkillInvalidConditionKey" + | "TrueSkillInvalidConditionValue" + | "TrueSkillInvalidConditionAffinityWeight" + | "TrueSkillInvalidEventName" + | "TrueSkillMatchResultCreated" + | "TrueSkillMatchResultAlreadySubmitted" + | "TrueSkillBadPlayerIdInMatchResult" + | "TrueSkillInvalidBotIdInMatchResult" + | "TrueSkillDuplicatePlayerInMatchResult" + | "TrueSkillNoPlayerInMatchResultTeam" + | "TrueSkillPlayersInMatchResultExceedingLimit" + | "TrueSkillInvalidPreMatchPartyInMatchResult" + | "TrueSkillInvalidTimestampInMatchResult" + | "TrueSkillStartTimeMissingInMatchResult" + | "TrueSkillEndTimeMissingInMatchResult" + | "TrueSkillInvalidPlayerSecondsPlayedInMatchResult" + | "TrueSkillNoTeamInMatchResult" + | "TrueSkillNotEnoughTeamsInMatchResult" + | "TrueSkillInvalidRanksInMatchResult" + | "TrueSkillNoWinnerInMatchResult" + | "TrueSkillMissingRequiredCondition" + | "TrueSkillMissingRequiredEvent" + | "TrueSkillUnknownEventName" + | "TrueSkillInvalidEventCount" + | "TrueSkillUnknownConditionKey" + | "TrueSkillUnknownConditionValue" + | "TrueSkillScenarioConfigDoesNotExist" + | "TrueSkillUnknownModelId" + | "TrueSkillNoModelInScenario" + | "TrueSkillNotSupportedForTitle" + | "TrueSkillModelIsNotActive" + | "TrueSkillUnauthorizedToQueryOtherPlayerSkills" + | "TrueSkillInvalidMaxIterations" + | "TrueSkillEndTimeBeforeStartTime" + | "TrueSkillInvalidJobId" + | "TrueSkillInvalidMetadataId" + | "TrueSkillMissingBuildVerison" + | "TrueSkillJobAlreadyExists" + | "TrueSkillJobNotFound" + | "TrueSkillOperationCanceled" + | "TrueSkillActiveModelLimitExceeded" + | "TrueSkillTotalModelLimitExceeded" + | "TrueSkillUnknownInitialModelId" + | "TrueSkillUnauthorizedForJob" + | "TrueSkillInvalidScenarioName" + | "TrueSkillConditionStateIsRequired" + | "TrueSkillEventStateIsRequired" + | "TrueSkillDuplicateEvent" + | "TrueSkillDuplicateCondition" + | "TrueSkillInvalidAnomalyThreshold" + | "TrueSkillConditionKeyLimitExceeded" + | "TrueSkillConditionValuePerKeyLimitExceeded" + | "TrueSkillInvalidTimestamp" + | "TrueSkillEventLimitExceeded" + | "TrueSkillInvalidPlayers" + | "TrueSkillTrueSkillPlayerNull" + | "TrueSkillInvalidPlayerId" + | "TrueSkillInvalidSquadSize" + | "TrueSkillConditionSetNotInModel" + | "TrueSkillModelStateInvalidForOperation" + | "TrueSkillScenarioContainsActiveModel" + | "TrueSkillInvalidConditionRank" + | "TrueSkillTotalScenarioLimitExceeded" + | "TrueSkillInvalidConditionsList" + | "GameSaveManifestNotFound" + | "GameSaveManifestVersionAlreadyExists" + | "GameSaveConflictUpdatingManifest" + | "GameSaveManifestUpdatesNotAllowed" + | "GameSaveFileAlreadyExists" + | "GameSaveManifestVersionNotFinalized" + | "GameSaveUnknownFileInManifest" + | "GameSaveFileExceededReportedSize" + | "GameSaveFileNotUploaded" + | "GameSaveBadRequest" + | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" + | "GameSaveBaseVersionNotAvailable" + | "GameSaveManifestVersionQuarantined" + | "GameSaveManifestUploadProgressUpdateNotAllowed" + | "GameSaveNotFinalizedManifestNotEligibleAsKnownGood" + | "GameSaveNoUpdatesRequested" + | "GameSaveTitleDoesNotExist" + | "GameSaveOperationNotAllowedForTitle" + | "GameSaveManifestFilesLimitExceeded" + | "GameSaveManifestDescriptionUpdateNotAllowed" + | "GameSaveTitleConfigNotFound" + | "GameSaveTitleAlreadyOnboarded" + | "GameSaveServiceNotEnabledForTitle" + | "GameSaveServiceOnboardingPending" + | "GameSaveManifestNotEligibleAsConflictingVersion" + | "GameSaveServiceUnavailable" + | "GameSaveConflict" + | "GameSaveManifestNotEligibleForRollback" + | "GameSaveTitleClientAnonymousAccountCreationNotDisabled" + | "GameSaveTitleConfigNoUpdatesRequested" + | "GameSavePlayerNotEligibleForTransfer" + | "GameSaveAlreadyAutoRolledBack" + | "GameSaveManifestNotEligibleForRestore" + | "GameSaveManifestArchived" + | "StateShareForbidden" + | "StateShareTitleNotInFlight" + | "StateShareStateNotFound" + | "StateShareLinkNotFound" + | "StateShareStateRedemptionLimitExceeded" + | "StateShareStateRedemptionLimitNotUpdated" + | "StateShareCreatedStatesLimitExceeded" + | "StateShareIdMissingOrMalformed" + | "PlayerCreationDisabled" + | "AccountAlreadyExists" + | "TagInvalid" + | "TagTooLong" + | "StatisticColumnAggregationMismatch" + | "StatisticResetIntervalMismatch" + | "VersionConfigurationCannotBeSpecifiedForLinkedStat" + | "VersionConfigurationIsRequired" + | "InvalidEntityTypeForAggregation" + | "MultiLevelAggregationNotAllowed" + | "AggregationTypeNotAllowedForLinkedStat" + | "OperationDeniedDueToDefinitionPolicy" + | "StatisticUpdateNotAllowedWhileLinked" + | "UnsupportedEntityType" + | "EntityTypeSpecifiedRequiresAggregationSource" + | "PlayFabErrorEventNotSupportedForEntityType" + | "MetadataLengthExceeded" + | "MaxQueryableVersionsExceeded" + | "StatisticVersionIncrementNotAllowedWhileLinked" + | "StoreMetricsRequestInvalidInput" + | "StoreMetricsErrorRetrievingMetrics"; + + export interface GenericPlayFabIdPair { + /** Unique generic service identifier for a user. */ + GenericId?: GenericServiceId; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllActionGroupsRequest - */ - export interface GetAllActionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GenericServiceId { + /** Name of the service for which the player has a unique identifier. */ + ServiceName: string; + /** Unique identifier of the player in that service. */ + UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllActionGroupsResult - */ - export interface GetAllActionGroupsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of Action Groups. - */ - ActionGroups: GetActionGroupResult[]; + export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllSegmentsRequest - */ - export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllSegmentsResult - */ export interface GetAllSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments for this title. - */ + /** Array of segments for this title. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCatalogItemsRequest - */ export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterDataRequest - */ export interface GetCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterDataResult - */ export interface GetCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. - */ - DataVersion: number; - /** - / User specific data for this title. - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ - CharacterId?: string; + DataVersion: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterInventoryRequest - */ export interface GetCharacterInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Used to limit results to only those from a specific catalog version. - */ + /** Used to limit results to only those from a specific catalog version. */ CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterInventoryResult - */ export interface GetCharacterInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique identifier of the character for this inventory. - */ + /** Unique identifier of the character for this inventory. */ CharacterId?: string; - /** - / Array of inventory items belonging to the character. - */ + /** Array of inventory items belonging to the character. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the character. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the character. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterLeaderboardRequest - */ export interface GetCharacterLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterLeaderboardResult - */ export interface GetCharacterLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterStatisticsRequest - */ export interface GetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterStatisticsResult - */ export interface GetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose character statistics are being returned. - */ - PlayFabId?: string; - /** - / Unique identifier of the character for the statistics. - */ + /** Unique identifier of the character for the statistics. */ CharacterId?: string; - /** - / Character statistics for the requested user. - */ + /** Character statistics for the requested user. */ CharacterStatistics?: { [key: string]: number }; + /** PlayFab unique identifier of the user whose character statistics are being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetContentDownloadUrlRequest - */ export interface GetContentDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to fetch, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. - */ + /** HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. */ HttpMethod?: string; + /** Key of the content item to fetch, usually formatted as a path, e.g. images/a.png */ + Key: string; /** - / True if download through CDN. CDN provides better download bandwidth and time. However, if you want latest, non-cached version of the content, set this to false. Default is true. + * True to download through CDN. CDN provides higher download bandwidth and lower latency. However, if you want the latest, + * non-cached version of the content during development, set this to false. Default is true. */ ThruCDN?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetContentDownloadUrlResult - */ export interface GetContentDownloadUrlResult extends PlayFabModule.IPlayFabResultCommon { - /** - / URL for downloading content via HTTP GET or HEAD method. The URL will expire in 1 hour. - */ + /** URL for downloading content via HTTP GET or HEAD method. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendLeaderboardRequest - */ export interface GetFriendLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The player whose friend leaderboard to get + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. */ + MaxResultsCount: number; + /** The player whose friend leaderboard to get */ PlayFabId: string; /** - / Statistic used to rank friends for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; - /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + /** Statistic used to rank friends for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendsListRequest - */ export interface GetFriendsListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalPlatformFriends?: string; /** - / PlayFab identifier of the player whose friend list to get. + * If true, include friends from the same namespace even if they have not logged in to the current title. Defaults to + * false. */ + NamespaceWide?: boolean; + /** PlayFab identifier of the player whose friend list to get. */ PlayFabId: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - IncludeSteamFriends?: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; /** - / Indicates whether Facebook friends should be included in the response. Default is true. + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. When provided, all Xbox Live + * users the caller is following are included regardless of whether they follow the caller back. */ - IncludeFacebookFriends?: boolean; + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendsListResult - */ export interface GetFriendsListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of friends found. - */ + /** Array of friends found. */ Friends?: FriendInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundCharacterRequest - */ export interface GetLeaderboardAroundCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Maximum number of entries to retrieve. - */ + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundCharacterResult - */ export interface GetLeaderboardAroundCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundUserRequest - */ export interface GetLeaderboardAroundUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Maximum number of entries to retrieve. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundUserResult - */ export interface GetLeaderboardAroundUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardForUsersCharactersRequest - */ export interface GetLeaderboardForUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardForUsersCharactersResult - */ export interface GetLeaderboardForUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardRequest - */ export interface GetLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardResult - */ export interface GetLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoRequest - */ export interface GetPlayerCombinedInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the user whose data will be returned - */ - PlayFabId: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters: GetPlayerCombinedInfoRequestParams; + /** PlayFabId of the user whose data will be returned */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoRequestParams - */ export interface GetPlayerCombinedInfoRequestParams { - /** - / Whether to get the player's account Info. Defaults to false - */ + /** Whether to get character inventories. Defaults to false. */ + GetCharacterInventories: boolean; + /** Whether to get the list of characters. Defaults to false. */ + GetCharacterList: boolean; + /** Whether to get player profile. Defaults to false. Has no effect for a new player. */ + GetPlayerProfile: boolean; + /** Whether to get player statistics. Defaults to false. */ + GetPlayerStatistics: boolean; + /** Whether to get title data. Defaults to false. */ + GetTitleData: boolean; + /** Whether to get the player's account Info. Defaults to false */ GetUserAccountInfo: boolean; - /** - / Whether to get the player's inventory. Defaults to false - */ + /** Whether to get the player's custom data. Defaults to false */ + GetUserData: boolean; + /** Whether to get the player's inventory. Defaults to false */ GetUserInventory: boolean; - /** - / Whether to get the player's virtual currency balances. Defaults to false - */ + /** Whether to get the player's read only data. Defaults to false */ + GetUserReadOnlyData: boolean; + /** Whether to get the player's virtual currency balances. Defaults to false */ GetUserVirtualCurrency: boolean; - /** - / Whether to get the player's custom data. Defaults to false - */ - GetUserData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false - */ + /** Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false */ + PlayerStatisticNames?: string[]; + /** Specifies the properties to return from the player profile. Defaults to returning the player's display name. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false */ + TitleDataKeys?: string[]; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false */ UserDataKeys?: string[]; /** - / Whether to get the player's read only data. Defaults to false - */ - GetUserReadOnlyData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is false + * Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is + * false */ UserReadOnlyDataKeys?: string[]; - /** - / Whether to get character inventories. Defaults to false. - */ - GetCharacterInventories: boolean; - /** - / Whether to get the list of characters. Defaults to false. - */ - GetCharacterList: boolean; - /** - / Whether to get title data. Defaults to false. - */ - GetTitleData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false - */ - TitleDataKeys?: string[]; - /** - / Whether to get player statistics. Defaults to false. - */ - GetPlayerStatistics: boolean; - /** - / Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false - */ - PlayerStatisticNames?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoResult - */ export interface GetPlayerCombinedInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Results for requested info. - */ + /** Results for requested info. */ InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoResultPayload - */ export interface GetPlayerCombinedInfoResultPayload { - /** - / Account information for the user. This is always retrieved. - */ + /** Account information for the user. This is always retrieved. */ AccountInfo?: UserAccountInfo; + /** Inventories for each character for the user. */ + CharacterInventories?: CharacterInventory[]; + /** List of characters for the user. */ + CharacterList?: CharacterResult[]; /** - / Array of inventory items in the user's current inventory. + * The profile of the players. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ + PlayerProfile?: PlayerProfileModel; + /** List of statistics for this player. */ + PlayerStatistics?: StatisticValue[]; + /** Title data for this title. */ + TitleData?: { [key: string]: string | null }; + /** User specific custom data. */ + UserData?: { [key: string]: UserDataRecord }; + /** The version of the UserData that was returned. */ + UserDataVersion: number; + /** Array of inventory items in the user's current inventory. */ UserInventory?: ItemInstance[]; - /** - / Dictionary of virtual currency balance(s) belonging to the user. - */ + /** User specific read-only data. */ + UserReadOnlyData?: { [key: string]: UserDataRecord }; + /** The version of the Read-Only UserData that was returned. */ + UserReadOnlyDataVersion: number; + /** Dictionary of virtual currency balance(s) belonging to the user. */ UserVirtualCurrency?: { [key: string]: number }; - /** - / Dictionary of remaining times and timestamps for virtual currencies. - */ + /** Dictionary of remaining times and timestamps for virtual currencies. */ UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; + + } + + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Specific property name to search for in the player's properties. */ + PropertyName: string; + + } + + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; /** - / User specific custom data. - */ - UserData?: { [key: string]: UserDataRecord }; - /** - / The version of the UserData that was returned. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - UserDataVersion: number; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / User specific read-only data. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UserReadOnlyData?: { [key: string]: UserDataRecord }; + ProfileConstraints?: PlayerProfileViewConstraints; + + } + + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / The version of the Read-Only UserData that was returned. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - UserReadOnlyDataVersion: number; + PlayerProfile?: PlayerProfileModel; + + } + + export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of segments the requested player currently belongs to. */ + Segments?: GetSegmentResult[]; + + } + + export interface GetPlayersInSegmentExportRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId: string; + + } + + export interface GetPlayersInSegmentExportResponse extends PlayFabModule.IPlayFabResultCommon { + /** Url from which the index file can be downloaded. */ + IndexUrl?: string; + /** Shows the current status of the export */ + State?: string; + + } + + export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** user for whom statistics are being requested */ + PlayFabId: string; + /** statistics to return */ + StatisticNames?: string[]; /** - / List of characters for the user. + * statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be + * returned) */ - CharacterList?: CharacterResult[]; + StatisticNameVersions?: StatisticNameVersion[]; + + } + + export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose statistics are being returned */ + PlayFabId?: string; + /** User statistics for the requested user. */ + Statistics?: StatisticValue[]; + + } + + export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ + StatisticName?: string; + + } + + export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { + /** version change history of the statistic */ + StatisticVersions?: PlayerStatisticVersion[]; + + } + + export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ + Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Canonical tags (including namespace and tag's name) for the requested user */ + Tags: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Inventories for each character for the user. + * Array of unique Battle.net account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 10 in length. */ - CharacterInventories?: CharacterInventory[]; + BattleNetAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Battle.net account identifiers to PlayFab identifiers. */ + Data?: BattleNetAccountPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Title data for this title. + * Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - TitleData?: { [key: string]: string }; + FacebookIDs: string[]; + + } + + export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook identifiers to PlayFab identifiers. */ + Data?: FacebookPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / List of statistics for this player. + * Array of unique Facebook Instant Games identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - PlayerStatistics?: StatisticValue[]; + FacebookInstantGamesIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerSegmentsResult - */ - export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromFacebookInstantGamesIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook Instant Games identifiers to PlayFab identifiers. */ + Data?: FacebookInstantGamesPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromGenericIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of segments the requested player currently belongs to. + * Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a + * maximum of 10 in a single request. */ - Segments?: GetSegmentResult[]; + GenericIDs: GenericServiceId[]; + + } + + export interface GetPlayFabIDsFromGenericIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of generic service identifiers to PlayFab identifiers. */ + Data?: GenericPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersInSegmentRequest - */ - export interface GetPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromNintendoServiceAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier for this segment. + * Nintendo NSA issuer URL identifying the environment. When provided, only accounts registered in that environment are + * returned. If null or empty, falls back to the default environment. */ - SegmentId: string; + Issuer?: string; /** - / Number of seconds to keep the continuation token active. After token expiration it is not possible to continue paging results. Default is 300 (5 minutes). Maximum is 1,800 (30 minutes). + * Array of unique Nintendo Switch Account identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - SecondsToLive?: number; + NintendoAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromNintendoServiceAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Service Account identifiers to PlayFab identifiers. */ + Data?: NintendoServiceAccountPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Maximum number of profiles to load. Default is 1,000. Maximum is 10,000. + * Array of unique Nintendo Switch Device identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - MaxBatchSize?: number; + NintendoSwitchDeviceIds: string[]; + + } + + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Device identifiers to PlayFab identifiers. */ + Data?: NintendoSwitchPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromOpenIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Continuation token if retrieving subsequent pages of results. + * Array of unique OpenId Connect identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed + * 10 in length. */ - ContinuationToken?: string; + OpenIdSubjectIdentifiers: OpenIdSubjectIdentifier[]; + + } + + export interface GetPlayFabIDsFromOpenIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of OpenId Connect identifiers to PlayFab identifiers. */ + Data?: OpenIdSubjectIdentifierPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersInSegmentResult - */ - export interface GetPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromPSNAccountIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Count of profiles matching this segment. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - ProfilesInSegment: number; + IssuerId?: number; /** - / Continuation token to use to retrieve subsequent pages of results. If token returns null there are no more results. + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - ContinuationToken?: string; + PSNAccountIDs: string[]; /** - / Array of player profiles in this segment. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - PlayerProfiles?: PlayerProfile[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersSegmentsRequest - */ - export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; + export interface GetPlayFabIDsFromPSNAccountIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticsRequest - */ - export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromPSNOnlineIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / user for whom statistics are being requested + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - PlayFabId: string; + IssuerId?: number; /** - / statistics to return + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - StatisticNames?: string[]; + PSNOnlineIDs: string[]; /** - / statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be returned) + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - StatisticNameVersions?: StatisticNameVersion[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticsResult - */ - export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose statistics are being returned - */ - PlayFabId?: string; - /** - / User statistics for the requested user. - */ - Statistics?: StatisticValue[]; + export interface GetPlayFabIDsFromPSNOnlineIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNOnlinePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticVersionsRequest - */ - export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromServerCustomIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / unique name of the statistic + * Array of unique server custom player identifiers for which the title needs to get PlayFab identifiers. Cannot contain + * more than 25 identifiers. */ - StatisticName?: string; + ServerCustomIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticVersionsResult - */ - export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ - StatisticVersions?: PlayerStatisticVersion[]; + export interface GetPlayFabIDsFromServerCustomIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of server custom identifiers to PlayFab identifiers. */ + Data?: ServerCustomIDPlayFabIDPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerTagsRequest - */ - export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; + export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Optional namespace to filter results by + * Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Namespace?: string; + SteamStringIDs?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerTagsResult - */ - export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ - Tags: string[]; + export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromFacebookIDsRequest - */ - export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. + * Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - FacebookIDs: string[]; + SteamNames: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromFacebookIDsResult - */ - export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Facebook identifiers to PlayFab identifiers. - */ - Data?: FacebookPlayFabIdPair[]; + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamNamePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromSteamIDsRequest - */ - export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. + * Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - SteamStringIDs?: string[]; + TwitchIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromSteamIDsResult - */ - export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Twitch identifiers to PlayFab identifiers. */ + Data?: TwitchPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The ID of Xbox Live sandbox. */ + Sandbox?: string; /** - / Mapping of Steam identifiers to PlayFab identifiers. + * Array of unique Xbox Live account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Data?: SteamPlayFabIdPair[]; + XboxLiveAccountIDs: string[]; + + } + + export interface GetPlayFabIDsFromXboxLiveIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Xbox Live identifiers to PlayFab identifiers. */ + Data?: XboxLiveAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPublisherDataRequest - */ export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ Keys: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPublisherDataResult - */ export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetRandomResultTablesRequest - */ export interface GetRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Specifies the catalog version that should be used to retrieve the Random Result Tables. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to retrieve the Random Result Tables. If unspecified, uses + * default/primary catalog. */ CatalogVersion?: string; - /** - / The unique identifier of the Random Result Table to use. - */ + /** The unique identifier of the Random Result Table to use. */ TableIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetRandomResultTablesResult - */ export interface GetRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of random result tables currently available - */ + /** array of random result tables currently available */ Tables?: { [key: string]: RandomResultTableListing }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ + export interface GetSegmentPlayerCountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the requested segment. */ + SegmentId: string; + + } + + export interface GetSegmentPlayerCountResult extends PlayFabModule.IPlayFabResultCommon { + /** Count of profiles matching this segment. */ + ProfilesInSegment: number; + + } + + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ Id: string; - /** - / Segment name. - */ + /** Segment name. */ Name?: string; + + } + + export interface GetServerCustomIDsFromPlayFabIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Identifier of the segments AB Test, if it is attached to one. + * Array of unique PlayFab player identifiers for which the title needs to get server custom identifiers. Cannot contain + * more than 25 identifiers. */ - ABTestParent?: string; + PlayFabIDs: string[]; + + } + + export interface GetServerCustomIDsFromPlayFabIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of server custom player identifiers to PlayFab identifiers. */ + Data?: ServerCustomIDPlayFabIDPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSharedGroupDataRequest - */ export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** If true, return the list of all members of the shared group. */ + GetMembers?: boolean; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array indicates that no keys should be returned). + * Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array + * indicates that no keys should be returned). */ Keys?: string[]; - /** - / If true, return the list of all members of the shared group. - */ - GetMembers?: boolean; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSharedGroupDataResult - */ export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Data for the requested keys. - */ + /** Data for the requested keys. */ Data?: { [key: string]: SharedGroupDataRecord }; + /** List of PlayFabId identifiers for the members of this group, if requested. */ + Members?: string[]; + + } + + export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** The base catalog that this store is a part of. */ + CatalogVersion?: string; + /** Additional data about the store. */ + MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; + + } + + export interface GetStoreItemsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to store items from. Use default catalog version if null */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / List of PlayFabId identifiers for the members of this group, if requested. + * Optional identifier for the player to use in requesting the store information - if used, segment overrides will be + * applied */ - Members?: string[]; + PlayFabId?: string; + /** Unqiue identifier for the store which is being requested */ + StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTimeRequest - */ export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTimeResult - */ export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Current server time when the request was received, in UTC - */ + /** Current server time when the request was received, in UTC */ Time: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleDataRequest - */ export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Specific keys to search for in the title data (leave null to get all keys) + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - Keys?: string[]; + OverrideLabel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleDataResult - */ export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleNewsRequest - */ export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Limits the results to the last n entries. Defaults to 10 if not set. - */ + /** Limits the results to the last n entries. Defaults to 10 if not set. */ Count?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleNewsResult - */ export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of news items. - */ + /** Array of localized news items. */ News?: TitleNewsItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserAccountInfoRequest - */ export interface GetUserAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserAccountInfoResult - */ export interface GetUserAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account details for the user whose information was requested. - */ + /** Account details for the user whose information was requested. */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserBansRequest - */ export interface GetUserBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserBansResult - */ export interface GetUserBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the bans - */ + /** Information about the bans */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { + /** User specific data for this title. */ + Data?: { [key: string]: UserDataRecord }; /** - / PlayFab unique identifier of the user whose custom data is being returned. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; - /** - / User specific data for this title. - */ - Data?: { [key: string]: UserDataRecord }; + /** PlayFab unique identifier of the user whose custom data is being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantCharacterToUserRequest - */ export interface GrantCharacterToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Non-unique display name of the character being granted. - */ + /** Non-unique display name of the character being granted (1-40 characters in length). */ CharacterName: string; - /** - / Type of the character being granted; statistics can be sliced based on this value. - */ + /** Type of the character being granted; statistics can be sliced based on this value. */ CharacterType: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantCharacterToUserResult - */ export interface GrantCharacterToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier tagged to this character. - */ + /** Unique identifier tagged to this character. */ CharacterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantedItemInstance - */ export interface GrantedItemInstance { + /** Game specific comment associated with this instance when it was added to the user inventory. */ + Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ + BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Result of this operation. - */ - Result: boolean; - /** - / Unique identifier for the inventory item, as defined in the catalog. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ + DisplayName?: string; + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ + /** Unique item identifier for this specific instance of the item. */ ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Timestamp for when this instance was purchased. */ PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ + /** Total number of remaining uses, if this is a consumable item. */ RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Result of this operation. */ + Result: boolean; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToCharacterRequest - */ export interface GrantItemsToCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** String detailing any additional information concerning this operation. */ + Annotation?: string; + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / String detailing any additional information concerning this operation. - */ - Annotation?: string; - /** - / Array of itemIds to grant to the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of itemIds to grant to the user. */ ItemIds?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToCharacterResult - */ export interface GrantItemsToCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUserRequest - */ export interface GrantItemsToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ - CatalogVersion?: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / String detailing any additional information concerning this operation. - */ + /** String detailing any additional information concerning this operation. */ Annotation?: string; - /** - / Array of itemIds to grant to the user. - */ + /** Catalog version from which items are to be granted. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of itemIds to grant to the user. */ ItemIds: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUserResult - */ export interface GrantItemsToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUsersRequest - */ export interface GrantItemsToUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Array of items to grant and the users to whom the items are to be granted. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to grant and the users to whom the items are to be granted. */ ItemGrants: ItemGrant[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUsersResult - */ export interface GrantItemsToUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ItemGrant - */ export interface ItemGrant { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the catalog item to be granted to the user. - */ - ItemId: string; - /** - / String detailing any additional information concerning this operation. - */ + /** String detailing any additional information concerning this operation. */ Annotation?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; + /** Unique identifier of the catalog item to be granted to the user. */ + ItemId: string; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface LinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Battle.net account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LinkedPlatformAccountModel - */ export interface LinkedPlatformAccountModel { - /** - / Authentication platform - */ + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ Platform?: string; - /** - / Unique account identifier of the user on the platform - */ + /** Unique account identifier of the user on the platform */ PlatformUserId?: string; - /** - / Linked account username of the user on the platform, if available - */ + /** Linked account username of the user on the platform, if available */ Username?: string; - /** - / Linked account email of the user on the platform, if available - */ - Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ListUsersCharactersRequest - */ - export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Switch account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * The JSON Web token (JWT) returned by Nintendo after login. Used to validate the request and find the user ID (Nintendo + * Switch subject) to link with. */ + IdentityToken: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ListUsersCharactersResult - */ - export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested list of characters. - */ - Characters?: CharacterResult[]; + export interface LinkNintendoServiceAccountSubjectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Service Account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The Nintendo Service Account subject or id to link to the PlayFab user. */ + Subject: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LocationModel - */ - export interface LocationModel { - /** - / The two-character continent code for this location - */ - ContinentCode?: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode?: string; - /** - / City name. - */ - City?: string; - /** - / Latitude coordinate of the geographic location. - */ - Latitude?: number; - /** - / Longitude coordinate of the geographic location. - */ - Longitude?: number; + export interface LinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the Nintendo Switch Device ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - type LoginIdentityProvider = "Unknown" - | "PlayFab" - | "Custom" - | "GameCenter" - | "GooglePlay" - | "Steam" - | "XBoxLive" - | "PSN" - | "Kongregate" - | "Facebook" - | "IOSDevice" - | "AndroidDevice" - | "Twitch" - | "WindowsHello"; + export interface LinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LogStatement - */ - export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ - Level?: string; - Message?: string; + } + + export interface LinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Authentication code provided by the PlayStation :tm: Network. */ + AuthCode: string; /** - / Optional object accompanying the message as contextual information + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ - Data?: any; + AuthVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyCharacterVirtualCurrencyResult - */ - export interface ModifyCharacterVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface LinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyItemUsesRequest - */ - export interface ModifyItemUsesRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkPSNIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / PlayFab unique identifier of the user whose item is being modified. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signs in under, otherwise the link will not be resolved by that sign in. */ + IssuerId?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; + /** Id of the PlayStation :tm: Network user. Also known as the PSN Account Id. */ + PSNUserId: string; /** - / Unique instance identifier of the item to be modified. - */ - ItemInstanceId: string; - /** - / Number of uses to add to the item. Can be negative to remove uses. + * The PlayStation :tm: Network sandbox to key the link under. Sandbox membership is per account, not per title: supply + * this only when the account signs in from a sandbox, and omit it otherwise, including for all retail accounts. This must + * match the sandbox the account signs in from, otherwise the link will not be resolved by that sign in. */ - UsesToAdd: number; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyItemUsesResult - */ - export interface ModifyItemUsesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ - ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ - RemainingUses: number; + export interface LinkPSNIdResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyUserVirtualCurrencyResult - */ - export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User currency was subtracted from. - */ - PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface LinkServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the custom ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Unique PlayFab identifier. */ + PlayFabId: string; + /** Unique server custom identifier for this player. */ + ServerCustomId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromCharacterRequest - */ - export interface MoveItemToCharacterFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the character that currently has the item. - */ - GivingCharacterId: string; - /** - / Unique identifier of the character that will be receiving the item. - */ - ReceivingCharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + export interface LinkServerCustomIdResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromCharacterResult - */ - export interface MoveItemToCharacterFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; + /** Unique Steam identifier for a user. */ + SteamId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromUserRequest - */ - export interface MoveItemToCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + export interface LinkSteamIdResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromUserResult - */ - export interface MoveItemToCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Twitch access token for authentication. */ + AccessToken: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToUserFromCharacterRequest - */ - export interface MoveItemToUserFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface LinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToUserFromCharacterResult - */ - export interface MoveItemToUserFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NameIdentifier - */ - export interface NameIdentifier { - Name?: string; - Id?: string; + export interface LinkXboxIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; + /** The id of Xbox Live sandbox. */ + Sandbox: string; + /** Unique Xbox identifier for a user. */ + XboxId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NotifyMatchmakerPlayerLeftRequest - */ - export interface NotifyMatchmakerPlayerLeftRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Instance the user is leaving. - */ - LobbyId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NotifyMatchmakerPlayerLeftResult - */ - export interface NotifyMatchmakerPlayerLeftResult extends PlayFabModule.IPlayFabResultCommon { + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / State of user leaving the Game Server Instance. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - PlayerState?: string; + PropertiesVersion: number; } - type PlayerConnectionState = "Unassigned" - | "Connecting" - | "Participating" - | "Participated"; + export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLeaderboardEntry - */ - export interface PlayerLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ - Position: number; - /** - / The profile of the user, if requested. - */ - Profile?: PlayerProfileModel; + } + + export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of characters. */ + Characters?: CharacterResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLinkedAccount - */ - export interface PlayerLinkedAccount { - /** - / Authentication platform - */ - Platform?: string; - /** - / Platform user identifier - */ - PlatformUserId?: string; - /** - / Linked account's username - */ - Username?: string; - /** - / Linked account's email - */ - Email?: string; + export interface LocalizedPushNotificationProperties { + /** Message of the localized push notification template. */ + Message?: string; + /** Subject of the localized push notification template. */ + Subject?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLocation - */ - export interface PlayerLocation { - /** - / The two-character continent code for this location - */ - ContinentCode: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode: string; - /** - / City of the player's geographic location. - */ + export interface LocationModel { + /** City name. */ City?: string; - /** - / Latitude coordinate of the player's geographic location. - */ + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ Latitude?: number; - /** - / Longitude coordinate of the player's geographic location. - */ + /** Longitude coordinate of the geographic location. */ Longitude?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfile - */ - export interface PlayerProfile { - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Player record created - */ - Created?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / Banned until UTC Date. If permanent ban this is set for 20 years after the original ban date. - */ - BannedUntil?: string; - /** - / Image URL of the player's avatar. - */ - AvatarUrl?: string; - /** - / Dictionary of player's statistics using only the latest version's value - */ - Statistics?: { [key: string]: number }; - /** - / A sum of player's total purchases in USD across all currencies. - */ - TotalValueToDateInUSD?: number; - /** - / Dictionary of player's total purchases by currency. - */ - ValuesToDate?: { [key: string]: number }; - /** - / List of player's tags for segmentation. - */ - Tags?: string[]; - /** - / Dictionary of player's locations by type. - */ - Locations?: { [key: string]: PlayerLocation }; - /** - / Dictionary of player's virtual currency balances - */ - VirtualCurrencyBalances?: { [key: string]: number }; - /** - / Array of ad campaigns player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttribution[]; - /** - / Array of configured push notification end points - */ - PushNotificationRegistrations?: PushNotificationRegistration[]; - /** - / Array of third party accounts linked to this player - */ - LinkedAccounts?: PlayerLinkedAccount[]; - /** - / Array of player statistics - */ - PlayerStatistics?: PlayerStatistic[]; + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface LoginWithAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific model of the user's device. */ + AndroidDevice?: string; + /** Android device identifier for the user's device. */ + AndroidDeviceId: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + + } + + export interface LoginWithBattleNetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + + } + + export interface LoginWithCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** Custom unique identifier for the user, generated by the title. */ + CustomId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + + } + + export interface LoginWithIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId: string; + /** Specific model of the user's device. */ + DeviceModel?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + + } + + export interface LoginWithPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code provided by the PlayStation :tm: Network OAuth provider. */ + AuthCode: string; + /** + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". + */ + AuthVersion?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; + + } + + export interface LoginWithServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** The backend server identifier for this player. */ + ServerCustomId: string; + + } + + export interface LoginWithSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Unique Steam identifier for a user. */ + SteamId: string; + + } + + export interface LoginWithTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Twitch access token for authentication. */ + AccessToken: string; + /** If true, create a new PlayFab account if one does not exist. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Parameters for requesting additional player info. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret for additional authentication. */ + PlayerSecret?: string; + /** PlayFab unique identifier of the user. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfileModel - */ - export interface PlayerProfileModel { - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Player record created - */ - Created?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / If the player is currently banned, the UTC Date when the ban expires - */ - BannedUntil?: string; - /** - / List of geographic locations where the player has logged-in - */ - Locations?: LocationModel[]; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Image URL of the player's avatar - */ - AvatarUrl?: string; - /** - / List of player's tags for segmentation - */ - Tags?: TagModel[]; - /** - / List of configured end points registered for sending the player push notifications - */ - PushNotificationRegistrations?: PushNotificationRegistrationModel[]; - /** - / List of third party accounts linked to this player - */ - LinkedAccounts?: LinkedPlatformAccountModel[]; - /** - / List of advertising campaigns the player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttributionModel[]; - /** - / A sum of player's total purchases across all real-money currencies, converted to US Dollars equivalent - */ - TotalValueToDateInUSD?: number; - /** - / List of player's total lifetime real-money purchases by currency - */ - ValuesToDate?: ValueToDateModel[]; - /** - / List of player's virtual currency balances - */ - VirtualCurrencyBalances?: VirtualCurrencyBalanceModel[]; - /** - / List of leaderboard statistic values for the player - */ - Statistics?: StatisticModel[]; + export interface LoginWithXboxIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** The id of Xbox Live sandbox. */ + Sandbox: string; + /** Unique Xbox identifier for a user. */ + XboxId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfileViewConstraints - */ - export interface PlayerProfileViewConstraints { - /** - / Whether to show the display name. Defaults to false - */ - ShowDisplayName: boolean; - /** - / Whether to show the created date. Defaults to false - */ - ShowCreated: boolean; - /** - / Whether to show origination. Defaults to false - */ - ShowOrigination: boolean; - /** - / Whether to show the last login time. Defaults to false - */ - ShowLastLogin: boolean; - /** - / Whether to show the banned until time. Defaults to false - */ - ShowBannedUntil: boolean; - /** - / Whether to show statistics, the most recent version of each stat. Defaults to false - */ - ShowStatistics: boolean; - /** - / Whether to show campaign attributions. Defaults to false - */ - ShowCampaignAttributions: boolean; - /** - / Whether to show push notification registrations. Defaults to false - */ - ShowPushNotificationRegistrations: boolean; - /** - / Whether to show the linked accounts. Defaults to false - */ - ShowLinkedAccounts: boolean; - /** - / Whether to show the total value to date in usd. Defaults to false - */ - ShowTotalValueToDateInUsd: boolean; - /** - / Whether to show the values to date. Defaults to false - */ - ShowValuesToDate: boolean; - /** - / Whether to show tags. Defaults to false - */ - ShowTags: boolean; - /** - / Whether to show player's locations. Defaults to false - */ - ShowLocations: boolean; - /** - / Whether to show player's avatar URL. Defaults to false - */ - ShowAvatarUrl: boolean; + export interface LoginWithXboxRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerStatistic - */ - export interface PlayerStatistic { - /** - / Statistic ID - */ - Id?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - StatisticVersion: number; - /** - / Current statistic value - */ - StatisticValue: number; - /** - / Statistic name - */ - Name?: string; + export interface LogStatement { + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ + Level?: string; + Message?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerStatisticVersion - */ - export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ - StatisticName?: string; + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / version of the statistic + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - Version: number; - /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ - ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval - */ - ScheduledDeactivationTime?: string; - /** - / time when the statistic version became inactive due to statistic version incrementing - */ - DeactivationTime?: string; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; } - type PushNotificationPlatform = "ApplePushNotificationService" - | "GoogleCloudMessaging"; + export interface ModifyCharacterVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; + + } + + export interface ModifyItemUsesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be modified. */ + ItemInstanceId: string; + /** PlayFab unique identifier of the user whose item is being modified. */ + PlayFabId: string; + /** Number of uses to add to the item. Can be negative to remove uses. */ + UsesToAdd: number; + + } + + export interface ModifyItemUsesResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique instance identifier of the item with uses consumed. */ + ItemInstanceId?: string; + /** Number of uses remaining on the item. */ + RemainingUses: number; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PushNotificationRegistration - */ - export interface PushNotificationRegistration { + export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / Push notification platform + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ - Platform?: string; + BalanceChange: number; + /** User currency was subtracted from. */ + PlayFabId?: string; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; + + } + + export interface MoveItemToCharacterFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the character that currently has the item. */ + GivingCharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique identifier of the character that will be receiving the item. */ + ReceivingCharacterId: string; + + } + + export interface MoveItemToCharacterFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface MoveItemToCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface MoveItemToCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface MoveItemToUserFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface MoveItemToUserFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface NintendoServiceAccountPlayFabIdPair { + /** Unique Nintendo Switch Service Account identifier for a user. */ + NintendoServiceAccountId?: string; /** - / Notification configured endpoint + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Service Account + * identifier. */ - NotificationEndpointARN?: string; + PlayFabId?: string; + + } + + export interface NintendoSwitchPlayFabIdPair { + /** Unique Nintendo Switch Device identifier for a user. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Device identifier. */ + PlayFabId?: string; + + } + + export interface OpenIdSubjectIdentifier { + /** The issuer URL for the OpenId Connect provider, or the override URL if an override exists. */ + Issuer: string; + /** The unique subject identifier within the context of the issuer. */ + Subject: string; + + } + + export interface OpenIdSubjectIdentifierPlayFabIdPair { + /** Unique OpenId Connect identifier for a user. */ + OpenIdSubjectIdentifier?: OpenIdSubjectIdentifier; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the OpenId Connect identifier. */ + PlayFabId?: string; + + } + + export interface PlayerLeaderboardEntry { + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ + Position: number; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PushNotificationRegistrationModel - */ - export interface PushNotificationRegistrationModel { + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Push notification platform + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ - Platform?: string; + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Notification configured endpoint + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ - NotificationEndpointARN?: string; + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RandomResultTableListing - */ - export interface RandomResultTableListing { - /** - / Catalog version this table is associated with - */ - CatalogVersion?: string; - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ - Nodes: ResultTableNode[]; + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ + ShowBannedUntil: boolean; + /** Whether to show campaign attributions. Defaults to false */ + ShowCampaignAttributions: boolean; + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ + ShowLinkedAccounts: boolean; + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ + ShowTotalValueToDateInUsd: boolean; + /** Whether to show the values to date. Defaults to false */ + ShowValuesToDate: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemCouponRequest - */ - export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generated coupon code to redeem. - */ - CouponCode: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Catalog version of the coupon. - */ - CatalogVersion?: string; - /** - / Optional identifier for the Character that should receive the item. If null, item is added to the player - */ - CharacterId?: string; + export interface PlayerStatisticVersion { + /** time when the statistic version became active */ + ActivationTime: string; + /** time when the statistic version became inactive due to statistic version incrementing */ + DeactivationTime?: string; + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ + StatisticName?: string; + /** version of the statistic */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemCouponResult - */ - export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { + export interface PSNAccountPlayFabIdPair { /** - / Items granted to the player as a result of redeeming the coupon. + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - GrantedItems?: ItemInstance[]; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNAccountId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemMatchmakerTicketRequest - */ - export interface RedeemMatchmakerTicketRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Server authorization ticket passed back from a call to Matchmake or StartGame. - */ - Ticket: string; + export interface PSNOnlinePlayFabIdPair { /** - / Unique identifier of the Game Server Instance that is asking for validation of the authorization ticket. + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - LobbyId: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNOnlineId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemMatchmakerTicketResult - */ - export interface RedeemMatchmakerTicketResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Boolean indicating whether the ticket was validated by the PlayFab service. - */ - TicketIsValid: boolean; - /** - / Error value if the ticket was not validated. - */ - Error?: string; - /** - / User account information for the user validated. - */ - UserInfo?: UserAccountInfo; + export interface PushNotificationPackage { + /** Numerical badge to display on App icon (iOS only) */ + Badge: number; + /** This must be a JSON formatted object. For use with developer-created custom Push Notification plugins */ + CustomData?: string; + /** Icon file to display with the message (Not supported for iOS) */ + Icon?: string; + /** Content of the message (all platforms) */ + Message: string; + /** Sound file to play with the message (all platforms) */ + Sound?: string; + /** Title/Subject of the message. Not supported for iOS */ + Title: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RefreshGameServerInstanceHeartbeatRequest - */ - export interface RefreshGameServerInstanceHeartbeatRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance for which the heartbeat is updated. - */ - LobbyId: string; + type PushNotificationPlatform = "ApplePushNotificationService" - } + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RefreshGameServerInstanceHeartbeatResult - */ - export interface RefreshGameServerInstanceHeartbeatResult extends PlayFabModule.IPlayFabResultCommon { + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ + NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; + export interface RandomResultTableListing { + /** Catalog version this table is associated with */ + CatalogVersion?: string; + /** Child nodes that indicate what kind of drop table item this actually is. */ + Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RegisterGameRequest - */ - export interface RegisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / IP address of the Game Server Instance. - */ - ServerHost: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: string; - /** - / Unique identifier of the build running on the Game Server Instance. - */ - Build: string; - /** - / Region in which the Game Server Instance is running. For matchmaking using non-AWS region names, set this to any AWS region and use Tags (below) to specify your custom region. - */ - Region: string; - /** - / Game Mode the Game Server instance is running. Note that this must be defined in the Game Modes tab in the PlayFab Game Manager, along with the Build ID (the same Game Mode can be defined for multiple Build IDs). - */ - GameMode: string; - /** - / Tags for the Game Server Instance - */ - Tags?: { [key: string]: string }; + } + + export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version of the coupon. */ + CatalogVersion?: string; + /** Optional identifier for the Character that should receive the item. If null, item is added to the player */ + CharacterId?: string; + /** Generated coupon code to redeem. */ + CouponCode: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RegisterGameResponse - */ - export interface RegisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier generated for the Game Server Instance that is registered. - */ - LobbyId?: string; + export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { + /** Items granted to the player as a result of redeeming the coupon. */ + GrantedItems?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveFriendRequest - */ export interface RemoveFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account which is to be removed. - */ + /** PlayFab identifier of the friend account which is to be removed. */ FriendPlayFabId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RemoveGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Generic service identifier to be removed from the player. */ + GenericId: GenericServiceId; + /** PlayFabId of the user to remove. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemovePlayerTagRequest - */ export interface RemovePlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemovePlayerTagResult - */ export interface RemovePlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveSharedGroupMembersRequest - */ export interface RemoveSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveSharedGroupMembersResult - */ export interface RemoveSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ReportPlayerServerRequest - */ export interface ReportPlayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the reporting player. - */ - ReporterId: string; - /** - / PlayFabId of the reported player. - */ - ReporteeId: string; - /** - / Title player was reported in, optional if report not for specific title. - */ - TitleId?: string; - /** - / Optional additional comment by reporting player. - */ + /** Optional additional comment by reporting player. */ Comment?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier of the reported player. */ + ReporteeId: string; + /** PlayFabId of the reporting player. */ + ReporterId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ReportPlayerServerResult - */ export interface ReportPlayerServerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Indicates whether this action completed successfully. - */ - Updated: boolean; - /** - / The number of remaining reports which may be filed today by this reporting player. - */ + /** The number of remaining reports which may be filed today by this reporting player. */ SubmissionsRemaining: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ResultTableNode - */ export interface ResultTableNode { - /** - / Whether this entry in the table is an item or a link to another table - */ - ResultItemType: string; - /** - / Either an ItemId, or the TableId of another random result table - */ + /** Either an ItemId, or the TableId of another random result table */ ResultItem: string; - /** - / How likely this is to be rolled - larger numbers add more weight - */ + /** Whether this entry in the table is an item or a link to another table */ + ResultItemType: string; + /** How likely this is to be rolled - larger numbers add more weight */ Weight: number; } type ResultTableNodeType = "ItemId" + | "TableId"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeAllBansForUserRequest - */ export interface RevokeAllBansForUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeAllBansForUserResult - */ export interface RevokeAllBansForUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked. - */ + /** Information on the bans that were revoked. */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeBansRequest - */ export interface RevokeBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Ids of the bans to be revoked. Maximum 100. - */ + /** Ids of the bans to be revoked. Maximum 100. */ BanIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeBansResult - */ export interface RevokeBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked - */ + /** Information on the bans that were revoked */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeInventoryItemRequest - */ - export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface RevokeInventoryItem { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RevokeInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Array of player items to revoke, between 1 and 25 items. */ + Items: RevokeInventoryItem[]; + + } + + export interface RevokeInventoryItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** Collection of any errors that occurred during processing. */ + Errors?: RevokeItemError[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeInventoryResult - */ export interface RevokeInventoryResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ScriptExecutionError - */ + export interface RevokeItemError { + /** Specific error that was encountered. */ + Error?: string; + /** Item information that failed to be revoked. */ + Item?: RevokeInventoryItem; + + } + + export interface SavePushNotificationTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Android JSON for the notification template. */ + AndroidPayload?: string; + /** Id of the push notification template. */ + Id?: string; + /** IOS JSON for the notification template. */ + IOSPayload?: string; + /** Dictionary of localized push notification templates with the language as the key. */ + LocalizedPushNotificationTemplates?: { [key: string]: LocalizedPushNotificationProperties }; + /** Name of the push notification template. */ + Name: string; + + } + + export interface SavePushNotificationTemplateResult extends PlayFabModule.IPlayFabResultCommon { + /** Id of the push notification template that was saved. */ + PushNotificationTemplateId?: string; + + } + export interface ScriptExecutionError { /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ Error?: string; - /** - / Details about the error - */ + /** Details about the error */ Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ + /** Point during the execution of the script at which the error occurred, if any */ StackTrace?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SendPushNotificationRequest - */ - export interface SendPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the recipient of the push notification. - */ - Recipient: string; - /** - / Text of message to send. - */ - Message: string; - /** - / Subject of message to send (may not be displayed in all platforms. - */ - Subject?: string; + export interface SendCustomAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ + Email?: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId: string; + /** The user's username requesting an account recovery. */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SendPushNotificationResult - */ - export interface SendPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { + export interface SendCustomAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetFriendTagsRequest - */ - export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the player whose friend is to be updated. - */ + export interface SendEmailFromTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The email template id of the email template to send. */ + EmailTemplateId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / PlayFab identifier of the friend account to which the tag(s) should be applied. - */ - FriendPlayFabId: string; - /** - / Array of tags to set on the friend account. - */ - Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceDataRequest - */ - export interface SetGameServerInstanceDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface SendEmailFromTemplateResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SendPushNotificationFromTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the push notification template. */ + PushNotificationTemplateId: string; + /** PlayFabId of the push notification recipient. */ + Recipient: string; + + } + + export interface SendPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier of the Game Instance to be updated, in decimal format. + * Allows you to provide precisely formatted json to target devices. This is an advanced feature, allowing you to deliver + * to custom plugin logic, fields, or functionality not natively supported by PlayFab. */ - LobbyId: string; + AdvancedPlatformDelivery?: AdvancedPushPlatformMsg[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Text of message to send. */ + Message?: string; /** - / Custom data to set for the specified game server instance. + * Defines all possible push attributes like message, title, icon, etc. Some parameters are device specific - please see + * the PushNotificationPackage documentation for details. */ - GameServerData: string; + Package?: PushNotificationPackage; + /** PlayFabId of the recipient of the push notification. */ + Recipient: string; + /** Subject of message to send (may not be displayed in all platforms) */ + Subject?: string; + /** Target Platforms that should receive the Message or Package. If omitted, we will send to all available platforms. */ + TargetPlatforms?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceDataResult - */ - export interface SetGameServerInstanceDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface SendPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceStateRequest - */ - export interface SetGameServerInstanceStateRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Instance to be updated, in decimal format. - */ - LobbyId: string; + export interface ServerCustomIDPlayFabIDPair { + /** Unique PlayFab identifier. */ + PlayFabId?: string; + /** Unique server custom identifier for this player. */ + ServerCustomId?: string; + + } + + export interface ServerLoginResult extends PlayFabModule.IPlayFabResultCommon { /** - / State to set for the specified game server instance. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ - State: string; + EntityToken?: EntityTokenResponse; + /** Results for requested info. */ + InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue */ + LastLoginTime?: string; + /** True if the master_player_account was newly created on this login. */ + NewlyCreated: boolean; + /** Player's unique PlayFabId. */ + PlayFabId?: string; + /** Unique token authorizing the user and game at the server level, for the current session. */ + SessionTicket?: string; + /** Settings specific to this user. */ + SettingsForUser?: UserSettings; + /** The experimentation treatments for this user at the time of login. */ + TreatmentAssignment?: TreatmentAssignment; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceStateResult - */ - export interface SetGameServerInstanceStateResult extends PlayFabModule.IPlayFabResultCommon { + export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** PlayFab identifier of the friend account to which the tag(s) should be applied. */ + FriendPlayFabId: string; + /** PlayFab identifier of the player whose friend is to be updated. */ + PlayFabId: string; + /** Array of tags to set on the friend account. */ + Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceTagsRequest - */ - export interface SetGameServerInstanceTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance to be updated. - */ - LobbyId: string; - /** - / Tags to set for the specified Game Server Instance. Note that this is the complete list of tags to be associated with the Game Server Instance. - */ - Tags: { [key: string]: string }; + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceTagsResult - */ - export interface SetGameServerInstanceTagsResult extends PlayFabModule.IPlayFabResultCommon { + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetPublisherDataRequest - */ export interface SetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetPublisherDataResult - */ export interface SetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetTitleDataRequest - */ export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetTitleDataResult - */ export interface SetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SharedGroupDataRecord - */ export interface SharedGroupDataRecord { - /** - / Data stored for the specified group data key. - */ - Value?: string; - /** - / PlayFabId of the user to last update this value. - */ - LastUpdatedBy?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; - /** - / Indicates whether this data can be read by all users (public) or only members of the group (private). - */ + /** PlayFabId of the user to last update this value. */ + LastUpdatedBy?: string; + /** Indicates whether this data can be read by all users (public) or only members of the group (private). */ Permission?: string; + /** Data stored for the specified group data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticModel - */ + type SourceType = "Admin" + + | "BackEnd" + | "GameClient" + | "GameServer" + | "Partner" + | "Custom" + | "API"; + export interface StatisticModel { - /** - / Statistic name - */ + /** Statistic name */ Name?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - Version: number; - /** - / Statistic value - */ + /** Statistic value */ Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticNameVersion - */ export interface StatisticNameVersion { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; - /** - / the version of the statistic to be returned - */ + /** the version of the statistic to be returned */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticUpdate - */ export interface StatisticUpdate { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; + /** statistic value for the player */ + Value: number; /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when setting the statistic value for the first time. + * for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when + * setting the statistic value for the first time. */ Version?: number; - /** - / statistic value for the player - */ - Value: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticValue - */ export interface StatisticValue { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName?: string; - /** - / statistic value for the player - */ + /** statistic value for the player */ Value: number; - /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded - */ + /** for updates to an existing statistic value for a player, the version of the statistic when it was loaded */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SteamPlayFabIdPair - */ + 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 Steam identifier for a user. - */ + /** 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. */ SteamStringId?: string; + + } + + export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ - PlayFabId?: string; + ItemId: string; + /** Override prices for this item for specific currencies */ + RealCurrencyPrices?: { [key: string]: number }; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface StoreMarketingModel { + /** Tagline for a store. */ + Description?: string; + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ + Metadata?: any; + + } + + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SubtractCharacterVirtualCurrencyRequest - */ + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + export interface SubtractCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SubtractUserVirtualCurrencyRequest - */ export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose virtual currency balance is to be decreased. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be decreased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.TagModel - */ export interface TagModel { - /** - / Full value of the tag, including namespace - */ + /** Full value of the tag, including namespace */ TagValue?: string; } - type TaskInstanceStatus = "Succeeded" - | "Starting" - | "InProgress" - | "Failed" - | "Aborted" - | "Pending"; - type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.TitleNewsItem - */ export interface TitleNewsItem { - /** - / Date and time when the news items was posted. - */ - Timestamp: string; - /** - / Unique identifier of news item. - */ + /** News item body. */ + Body?: string; + /** Unique identifier of news item. */ NewsId?: string; - /** - / Title of the news item. - */ + /** Date and time when the news item was posted. */ + Timestamp: string; + /** Title of the news item. */ Title?: string; - /** - / News item text. - */ - Body?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerInstanceRequest - */ - export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + + export interface TwitchPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. */ + PlayFabId?: string; + /** Unique Twitch identifier for a user. */ + TwitchId?: string; + + } + + export interface UnlinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkAppleResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games identifier for the user. If not specified, the most recently linked identifier will be used. */ + FacebookInstantGamesId?: string; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Nintendo Switch Device identifier for the user. If not specified, the most recently signed in device ID will be used. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier. */ + PlayFabId: string; + /** Unique server custom identifier for this player. */ + ServerCustomId: string; + + } + + export interface UnlinkServerCustomIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam account. */ + PlayFabId: string; + + } + + export interface UnlinkSteamIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Valid token issued by Twitch. Used to specify which twitch account to unlink from the profile. By default it uses the + * one that is present on the profile. */ + AccessToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ PlayFabId: string; + + } + + export interface UnlinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog + * associated with the item instance. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / ItemInstanceId of the container to unlock. - */ + /** ItemInstanceId of the container to unlock. */ ContainerItemInstanceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this parameter is required. + * ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this + * parameter is required. */ KeyItemInstanceId?: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog associated with the item instance. - */ - CatalogVersion?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerItemRequest - */ export interface UnlockContainerItemRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary + * catalog. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Catalog ItemId of the container type to unlock. - */ + /** Catalog ItemId of the container type to unlock. */ ContainerItemId: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary catalog. - */ - CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerItemResult - */ export interface UnlockContainerItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the container unlocked. - */ + /** Items granted to the player as a result of unlocking the container. */ + GrantedItems?: ItemInstance[]; + /** Unique instance identifier of the container unlocked. */ UnlockedItemInstanceId?: string; - /** - / Unique instance identifier of the key used to unlock the container, if applicable. - */ + /** Unique instance identifier of the key used to unlock the container, if applicable. */ UnlockedWithItemInstanceId?: string; - /** - / Items granted to the player as a result of unlocking the container. - */ - GrantedItems?: ItemInstance[]; - /** - / Virtual currency granted to the player as a result of unlocking the container. - */ + /** Virtual currency granted to the player as a result of unlocking the container. */ VirtualCurrency?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateAvatarUrlRequest - */ export interface UpdateAvatarUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / URL of the avatar image. If empty, it removes the existing avatar URL. - */ + /** URL of the avatar image. If empty, it removes the existing avatar URL. */ ImageUrl: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBanRequest - */ - export interface UpdateBanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The id of the ban to be updated. - */ + export interface UpdateBanRequest { + /** The updated active state for the ban. Null for no change. */ + Active?: boolean; + /** The id of the ban to be updated. */ BanId: string; - /** - / The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. - */ - Reason?: string; - /** - / The updated expiration date for the ban. Null for no change. - */ + /** The updated expiration date for the ban. Null for no change. */ Expires?: string; - /** - / The updated IP address for the ban. Null for no change. - */ + /** The updated IP address for the ban. Null for no change. */ IPAddress?: string; - /** - / The updated MAC address for the ban. Null for no change. - */ - MACAddress?: string; - /** - / Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. - */ + /** Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. */ Permanent?: boolean; - /** - / The updated active state for the ban. Null for no change. - */ - Active?: boolean; + /** The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. */ + Reason?: string; + /** The updated family type of the user that should be included in the ban. Null for no change. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBansRequest - */ export interface UpdateBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of bans to be updated. Maximum 100. - */ + /** List of bans to be updated. Maximum 100. */ Bans: UpdateBanRequest[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBansResult - */ export interface UpdateBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were updated - */ + /** Information on the bans that were updated */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterDataRequest - */ export interface UpdateCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterDataResult - */ export interface UpdateCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterStatisticsRequest - */ export interface UpdateCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Statistics to be updated with the provided values. - */ + /** Statistics to be updated with the provided values. */ CharacterStatistics?: { [key: string]: number }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterStatisticsResult - */ export interface UpdateCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdatePlayerStatisticsRequest - */ - export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. */ + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; + + } + + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties were updated. */ + PlayFabId?: string; /** - / Statistics to be updated with the provided values + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Statistics: StatisticUpdate[]; + PropertiesVersion: number; + + } + + export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Indicates whether the statistics provided should be set, regardless of the aggregation method set on the statistic. Default is false. + * Indicates whether the statistics provided should be set, regardless of the aggregation method set on the statistic. + * Default is false. */ ForceUpdate?: boolean; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Statistics to be updated with the provided values */ + Statistics: StatisticUpdate[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdatePlayerStatisticsResult - */ export interface UpdatePlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateSharedGroupDataRequest - */ + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; + + } + export interface UpdateSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys in this request. - */ + /** Permission to be applied to all user data keys in this request. */ Permission?: string; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateSharedGroupDataResult - */ export interface UpdateSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserInternalDataRequest - */ export interface UpdateUserInternalDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserInventoryItemDataRequest - */ export interface UpdateUserInventoryItemDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned instance identifier of the item + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ + Data?: { [key: string]: string | null }; + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. - */ - Data?: { [key: string]: string }; - /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserCustomIdInfo - */ + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; + + } + export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + + type UserFamilyType = "None" + + | "Xbox" + | "Steam"; + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -5217,248 +6046,213 @@ declare module PlayFabServerModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; + + } + + export interface UserSettings { + /** Boolean for whether this player is eligible for gathering device info. */ + GatherDeviceInfo: boolean; + /** Boolean for whether this player should report OnFocus play-time tracking. */ + GatherFocusInfo: boolean; + /** Boolean for whether this player is eligible for ad tracking. */ + NeedsAttribution: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ValueToDateModel - */ export interface ValueToDateModel { - /** - / ISO 4217 code of the currency used in the purchases - */ + /** ISO 4217 code of the currency used in the purchases */ Currency?: string; /** - / Total value of the purchases in a whole number of 1/100 monetary units. For example 999 indicates nine dollars and ninety-nine cents when Currency is 'USD') + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ TotalValue: number; /** - / Total value of the purchases in a string representation of decimal monetary units (e.g. '9.99' indicates nine dollars and ninety-nine cents when Currency is 'USD')) + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ TotalValueAsDecimal?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.VirtualCurrencyBalanceModel - */ - export interface VirtualCurrencyBalanceModel { - /** - / Name of the virtual currency - */ - Currency?: string; - /** - / Balance of the virtual currency - */ - TotalValue: number; + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteEventResponse - */ export interface WriteEventResponse extends PlayFabModule.IPlayFabResultCommon { /** - / The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to any particular format. + * The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to + * any particular format. */ EventId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteServerCharacterEventRequest - */ export interface WriteServerCharacterEventRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteServerPlayerEventRequest - */ export interface WriteServerPlayerEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteTitleEventRequest - */ export interface WriteTitleEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; + + } + + export interface XboxLiveAccountPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Xbox Live identifier. */ + PlayFabId?: string; + /** Unique Xbox Live identifier for a user. */ + XboxLiveAccountId?: string; } diff --git a/PlayFabSdk/src/Typings/PlayFab/Playfab.d.ts b/PlayFabSdk/src/Typings/PlayFab/Playfab.d.ts index d5d8e6c7..441d70ef 100644 --- a/PlayFabSdk/src/Typings/PlayFab/Playfab.d.ts +++ b/PlayFabSdk/src/Typings/PlayFab/Playfab.d.ts @@ -1,17 +1,26 @@ /// -/// -/// /// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// declare module PlayFabModule { export interface ISettings { titleId: string; developerSecretKey: string; - advertisingIdType: string; - advertisingIdValue: string; - disableAdvertising: boolean; - AD_TYPE_IDFA: string; - AD_TYPE_ANDROID_ID: string; + GlobalHeaderInjection?: { [key: string]: string }; + productionServerUrl: string; } export interface IPlayFabRequestCommon { } export interface IPlayFabError { @@ -21,6 +30,9 @@ declare module PlayFabModule { errorCode: number; errorMessage: string; errorDetails?: { [key: string]: string[] }; + request?: any; + customData?: any; + retryAfterSeconds?: number; } export interface SuccessContainer extends IPlayFabError { data: TResult; @@ -33,16 +45,41 @@ declare module PlayFabModule { declare var PlayFab: { buildIdentifier: string; sdkVersion: string; + GenerateErrorReport(IPlayFabError): string; settings: PlayFabModule.ISettings; AdminApi: PlayFabAdminModule.IPlayFabAdmin; - MatchmakerApi: PlayFabMatchmakerModule.IPlayFabMatchmaker; - ServerApi: PlayFabServerModule.IPlayFabServer; ClientApi: PlayFabClientModule.IPlayFabClient; + ServerApi: PlayFabServerModule.IPlayFabServer; + AuthenticationApi: PlayFabAuthenticationModule.IPlayFabAuthentication; + CloudScriptApi: PlayFabCloudScriptModule.IPlayFabCloudScript; + DataApi: PlayFabDataModule.IPlayFabData; + EconomyApi: PlayFabEconomyModule.IPlayFabEconomy; + EventsApi: PlayFabEventsModule.IPlayFabEvents; + ExperimentationApi: PlayFabExperimentationModule.IPlayFabExperimentation; + InsightsApi: PlayFabInsightsModule.IPlayFabInsights; + GroupsApi: PlayFabGroupsModule.IPlayFabGroups; + ProgressionApi: PlayFabProgressionModule.IPlayFabProgression; + LocalizationApi: PlayFabLocalizationModule.IPlayFabLocalization; + MultiplayerApi: PlayFabMultiplayerModule.IPlayFabMultiplayer; + ProfilesApi: PlayFabProfilesModule.IPlayFabProfiles; + AddonApi: PlayFabAddonModule.IPlayFabAddon; }; // Continue to support older usage declare var PlayFabAdminSDK: PlayFabAdminModule.IPlayFabAdmin; -declare var PlayFabMatchmakerSDK: PlayFabMatchmakerModule.IPlayFabMatchmaker; -declare var PlayFabServerSDK: PlayFabServerModule.IPlayFabServer; declare var PlayFabClientSDK: PlayFabClientModule.IPlayFabClient; +declare var PlayFabServerSDK: PlayFabServerModule.IPlayFabServer; +declare var PlayFabAuthenticationSDK: PlayFabAuthenticationModule.IPlayFabAuthentication; +declare var PlayFabCloudScriptSDK: PlayFabCloudScriptModule.IPlayFabCloudScript; +declare var PlayFabDataSDK: PlayFabDataModule.IPlayFabData; +declare var PlayFabEconomySDK: PlayFabEconomyModule.IPlayFabEconomy; +declare var PlayFabEventsSDK: PlayFabEventsModule.IPlayFabEvents; +declare var PlayFabExperimentationSDK: PlayFabExperimentationModule.IPlayFabExperimentation; +declare var PlayFabInsightsSDK: PlayFabInsightsModule.IPlayFabInsights; +declare var PlayFabGroupsSDK: PlayFabGroupsModule.IPlayFabGroups; +declare var PlayFabProgressionSDK: PlayFabProgressionModule.IPlayFabProgression; +declare var PlayFabLocalizationSDK: PlayFabLocalizationModule.IPlayFabLocalization; +declare var PlayFabMultiplayerSDK: PlayFabMultiplayerModule.IPlayFabMultiplayer; +declare var PlayFabProfilesSDK: PlayFabProfilesModule.IPlayFabProfiles; +declare var PlayFabAddonSDK: PlayFabAddonModule.IPlayFabAddon; diff --git a/PlayFabTestingExample/PlayFabApiTest.csproj b/PlayFabTestingExample/PlayFabApiTest.csproj index b645d439..3d733211 100644 --- a/PlayFabTestingExample/PlayFabApiTest.csproj +++ b/PlayFabTestingExample/PlayFabApiTest.csproj @@ -7,16 +7,17 @@ {349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc} Library bin - v4.6.1 + v4.6.2 full true - 2.1 + Latest true + @@ -25,8 +26,20 @@ - + + + + + + + + + + + + + @@ -34,8 +47,20 @@ - + + + + + + + + + + + + + @@ -73,9 +98,9 @@ - false - true - ES5 + False + True + ES2017 None True False diff --git a/PlayFabTestingExample/PlayFabApiTest.js b/PlayFabTestingExample/PlayFabApiTest.js index 512731a2..9050b163 100644 --- a/PlayFabTestingExample/PlayFabApiTest.js +++ b/PlayFabTestingExample/PlayFabApiTest.js @@ -1,20 +1,23 @@ var PlayFabApiTests = { testTitleDataFilename: "testTitleData.json", + testRetryDelay: 250, + testRetryCount: 8, titleData: { titleId: null, developerSecretKey: null, userEmail: "put valid email associated with an existing account here", - characterName: "put any character name here" + extraHeaders: {} }, testData: { + entityToken: null, + entityId: null, + entityType: null, playFabId: null, - characterId: null, - testNumber: null // Used by several tests + testNumber: null, // Arbitrary counter, used by several tests }, testConstants: { TEST_DATA_KEY: "testCounter", - TEST_STAT_NAME: "str", - CHAR_TEST_TYPE: "Fighter" + TEST_STAT_NAME: "str" }, ManualExecution: function () { $.getJSON(PlayFabApiTests.testTitleDataFilename, function (json) { @@ -33,18 +36,20 @@ var PlayFabApiTests = { QUnit.test("InvalidLogin", PlayFabApiTests.InvalidLogin); QUnit.test("InvalidRegistration", PlayFabApiTests.InvalidRegistration); QUnit.test("LoginOrRegister", PlayFabApiTests.LoginOrRegister); - QUnit.test("LoginWithAdvertisingId", PlayFabApiTests.LoginWithAdvertisingId); - setTimeout(function () { PlayFabApiTests.PostLoginTests(0); }, 200); + setTimeout(function () { PlayFabApiTests.PostLoginTests(0); }, PlayFabApiTests.testRetryDelay); + setTimeout(function () { PlayFabApiTests.PostEntityTokenTests(0); }, PlayFabApiTests.testRetryDelay); }, PostLoginTests: function (count) { - if (count > 5) + if (count > PlayFabApiTests.testRetryCount) return; if (!PlayFabClientSDK.IsClientLoggedIn()) { // Wait for login - setTimeout(function () { PlayFabApiTests.PostLoginTests(count + 1); }, 200); + setTimeout(function () { PlayFabApiTests.PostLoginTests(count + 1); }, PlayFabApiTests.testRetryDelay); } else { // Continue with other tests that require login + QUnit.test("GetEntityToken", PlayFabApiTests.GetEntityToken); + QUnit.test("EntityObjects", PlayFabApiTests.EntityObjects); QUnit.test("UserDataApi", PlayFabApiTests.UserDataApi); QUnit.test("PlayerStatisticsApi", PlayFabApiTests.PlayerStatisticsApi); QUnit.test("UserCharacter", PlayFabApiTests.UserCharacter); @@ -53,20 +58,33 @@ var PlayFabApiTests = { QUnit.test("CloudScript", PlayFabApiTests.CloudScript); QUnit.test("CloudScriptError", PlayFabApiTests.CloudScriptError); QUnit.test("WriteEvent", PlayFabApiTests.WriteEvent); + QUnit.test("ForgetCredentials", PlayFabApiTests.ForgetCredentials); + } + }, + PostEntityTokenTests: function (count) { + if (count > PlayFabApiTests.testRetryCount) + return; + if (!PlayFab["_internalSettings"].entityToken) { + // Wait for login + setTimeout(function () { PlayFabApiTests.PostEntityTokenTests(count + 1); }, PlayFabApiTests.testRetryDelay); + } + else { + // Continue with other tests that require login + // QUnit.test("EntityObjects", PlayFabApiTests.EntityObjects); // TODO: Release Entity API } }, SetUp: function (inputTitleData) { // All of these must exist for the titleData load to be successful var titleDataValid = inputTitleData.hasOwnProperty("titleId") && inputTitleData.titleId != null && inputTitleData.hasOwnProperty("developerSecretKey") && inputTitleData.developerSecretKey != null - && inputTitleData.hasOwnProperty("userEmail") - && inputTitleData.hasOwnProperty("characterName"); + && inputTitleData.hasOwnProperty("userEmail"); if (titleDataValid) PlayFabApiTests.titleData = inputTitleData; else console.log("testTitleData input file did not parse correctly"); PlayFab.settings.titleId = PlayFabApiTests.titleData.titleId; PlayFab.settings.developerSecretKey = PlayFabApiTests.titleData.developerSecretKey; + PlayFab.settings.GlobalHeaderInjection = PlayFabApiTests.titleData.extraHeaders; return titleDataValid; }, CallbackWrapper: function (callbackName, callback, assert) { @@ -80,10 +98,10 @@ var PlayFabApiTests = { } }; }, - SimpleCallbackWrapper: function (callbackName, callback, assert) { + SimpleCallbackWrapper: function (callbackName, callback, assert, kwargs = null) { return function () { try { - callback(); + callback(kwargs); } catch (e) { console.log("Exception thrown during " + callbackName + " callback: " + e.toString() + "\n" + e.stack); // Very irritatingly, qunit doesn't report failure results until all async callbacks return, which doesn't always happen when there's an exception @@ -94,26 +112,16 @@ var PlayFabApiTests = { VerifyNullError: function (result, error, assert, message) { var success = (result !== null && error == null); if (error != null) { - assert.ok(false, "PlayFab error message: " + PlayFabApiTests.CompileErrorReport(error)); + assert.ok(false, "PlayFab error message: " + PlayFab.GenerateErrorReport(error)); } else { assert.ok(success, message); } }, - CompileErrorReport: function (error) { - if (error == null) - return ""; - var fullErrors = error.errorMessage; - for (var paramName in error.errorDetails) - for (var msgIdx in error.errorDetails[paramName]) - fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; - return fullErrors; - }, - /// - /// CLIENT API - /// Try to deliberately log in with an inappropriate password, - /// and verify that the error displays as expected. - /// + /* CLIENT API + * Try to deliberately log in with an inappropriate password, + * and verify that the error displays as expected. + */ InvalidLogin: function (assert) { var invalidDone = assert.async(); var invalidRequest = { @@ -129,11 +137,10 @@ var PlayFabApiTests = { }; PlayFabClientSDK.LoginWithEmailAddress(invalidRequest, PlayFabApiTests.CallbackWrapper("invalidLoginCallback", invalidLoginCallback, assert)); }, - /// - /// CLIENT API - /// Try to deliberately register a user with an invalid email and password - /// Verify that errorDetails are populated correctly. - /// + /* CLIENT API + * Try to deliberately register a user with an invalid email and password + * Verify that errorDetails are populated correctly. + */ InvalidRegistration: function (assert) { var invalidDone = assert.async(); var invalidRequest = { @@ -146,17 +153,16 @@ var PlayFabApiTests = { assert.ok(error != null, "InvalidRegistration should have failed"); var expectedEmailMsg = "email address is not valid."; var expectedPasswordMsg = "password must be between"; - var errorReport = PlayFabApiTests.CompileErrorReport(error); + var errorReport = PlayFab.GenerateErrorReport(error); assert.ok(errorReport.toLowerCase().indexOf(expectedEmailMsg) > -1, "Expect errorMessage about invalid email: " + errorReport); assert.ok(errorReport.toLowerCase().indexOf(expectedPasswordMsg) > -1, "Expect errorMessage about invalid password: " + errorReport); invalidDone(); }; PlayFabClientSDK.RegisterPlayFabUser(invalidRequest, PlayFabApiTests.CallbackWrapper("registerCallback", registerCallback, assert)); }, - /// - /// CLIENT API - /// Log in or create a user, track their PlayFabId - /// + /* CLIENT API + * Log in or create a user, track their PlayFabId + */ LoginOrRegister: function (assert) { var loginRequest = { CustomId: PlayFab.buildIdentifier, @@ -170,44 +176,16 @@ var PlayFabApiTests = { PlayFabApiTests.testData.playFabId = result.data.PlayFabId; // Save the PlayFabId, it will be used in other tests loginDone(); }; - PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("loginCallback", loginCallback, assert)); - }, - /// - /// CLIENT API - /// Test that the login call sequence sends the AdvertisingId when set - /// - LoginWithAdvertisingId: function (assert) { - PlayFab.settings.advertisingIdType = PlayFab.settings.AD_TYPE_ANDROID_ID; - PlayFab.settings.advertisingIdValue = "PlayFabTestId"; - var loginDone = assert.async(); - var count = -1; - var finishAdvertId = function () { - count += 1; - if (count <= 10 && PlayFab.settings.advertisingIdType !== PlayFab.settings.AD_TYPE_ANDROID_ID + "_Successful") { - setTimeout(PlayFabApiTests.SimpleCallbackWrapper("finishAdvertId", finishAdvertId, assert), 200); - } - else { - assert.ok(PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_ANDROID_ID + "_Successful", "Testing whether advertisingId submitted properly"); - loginDone(); - } - }; - var advertLoginCallback = function (result, error) { - PlayFabApiTests.VerifyNullError(result, error, assert, "Testing Advert-Login result"); - setTimeout(PlayFabApiTests.SimpleCallbackWrapper("finishAdvertId", finishAdvertId, assert), 200); - }; - var loginRequest = { - CustomId: PlayFab.buildIdentifier, - CreateAccount: true - }; - PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("advertLoginCallback", advertLoginCallback, assert)); + var loginPromise = Promise.resolve(PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("loginCallback", loginCallback, assert))); + // By definition, a promise object should have a .then function, and Promise.resolve(promise) should equal promise + assert.ok(typeof loginPromise.then === "function" && Promise.resolve(loginPromise) === loginPromise, "Testing whether the login request returned a promise object"); }, - /// - /// CLIENT API - /// Test a sequence of calls that modifies saved data, - /// and verifies that the next sequential API call contains updated data. - /// Verify that the data is correctly modified on the next call. - /// Parameter types tested: string, Dictionary, DateTime - /// + /* CLIENT API + * Test a sequence of calls that modifies saved data, + * and verifies that the next sequential API call contains updated data. + * Verify that the data is correctly modified on the next call. + * Parameter types tested: string, Dictionary, DateTime + */ UserDataApi: function (assert) { var getDataRequest = {}; // null also works // This test is always exactly 3 async calls @@ -247,13 +225,12 @@ var PlayFabApiTests = { // Kick off this test process PlayFabClientSDK.GetUserData(getDataRequest, PlayFabApiTests.CallbackWrapper("getDataCallback1", getDataCallback1, assert)); }, - /// - /// CLIENT API - /// Test a sequence of calls that modifies saved data, - /// and verifies that the next sequential API call contains updated data. - /// Verify that the data is saved correctly, and that specific types are tested - /// Parameter types tested: Dictionary - /// + /* CLIENT API + * Test a sequence of calls that modifies saved data, + * and verifies that the next sequential API call contains updated data. + * Verify that the data is saved correctly, and that specific types are tested + * Parameter types tested: Dictionary + */ PlayerStatisticsApi: function (assert) { var getStatsRequest = {}; // null also works // This test is always exactly 3 async calls @@ -292,67 +269,28 @@ var PlayFabApiTests = { // Kick off this test process PlayFabClientSDK.GetPlayerStatistics(getStatsRequest, PlayFabApiTests.CallbackWrapper("getStatsCallback1", getStatsCallback1, assert)); }, - /// - /// SERVER API - /// Get or create the given test character for the given user - /// Parameter types tested: Contained-Classes, string - /// + /* CLIENT API + * Get or create the given test character for the given user + * Parameter types tested: Contained-Classes, string + */ UserCharacter: function (assert) { var getCharsRequest = {}; - var grantCharRequest = { - TitleId: PlayFabApiTests.titleData.titleId, - PlayFabId: PlayFabApiTests.testData.playFabId, - CharacterName: PlayFabApiTests.titleData.characterName, - CharacterType: PlayFabApiTests.testConstants.CHAR_TEST_TYPE - }; - // We don't know at this point how many async calls we'll make - var getDone = null; - var grantDone = null; - var mandatoryGetCharsCallback = function (result, error) { - // GetChars MUST succeed at some point during this test + var getDone = assert.async(); + var getCharsCallback = function (result, error) { PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetChars result"); - for (var i in result.data.Characters) - if (result.data.Characters[i].CharacterName === PlayFabApiTests.titleData.characterName) - PlayFabApiTests.testData.characterId = result.data.Characters[i].CharacterId; // Save the characterId, it will be used in other tests - assert.ok(PlayFabApiTests.testData.characterId != null, "Searching for " + PlayFabApiTests.titleData.characterName + " on this account."); getDone(); }; - var grantCharCallback = function (result, error) { - // Second character callback MUST succeed - PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GrantCharacter result"); - // Get chars again, this time with the newly granted character - getDone = assert.async(); - PlayFabClientSDK.GetAllUsersCharacters(grantCharRequest, PlayFabApiTests.CallbackWrapper("mandatoryGetCharsCallback", mandatoryGetCharsCallback, assert)); - grantDone(); - }; - var optionalGetCharsCallback = function (result, error) { - // First get chars falls back upon grant-char if target character not present - if (result.data.Characters.length === 0) { - // Register the character and try again - grantDone = assert.async(); - PlayFabServerSDK.GrantCharacterToUser(grantCharRequest, PlayFabApiTests.CallbackWrapper("grantCharCallback", grantCharCallback, assert)); - getDone(); - } - else { - // Confirm the successful login - mandatoryGetCharsCallback(result, error); - } - }; - getDone = assert.async(); - PlayFabClientSDK.GetAllUsersCharacters(getCharsRequest, PlayFabApiTests.CallbackWrapper("optionalGetCharsCallback", optionalGetCharsCallback, assert)); + PlayFabClientSDK.GetAllUsersCharacters(getCharsRequest, PlayFabApiTests.CallbackWrapper("getCharsCallback", getCharsCallback, assert)); }, - /// - /// CLIENT AND SERVER API - /// Test that leaderboard results can be requested - /// Parameter types tested: List of contained-classes - /// + /* CLIENT AND SERVER API + * Test that leaderboard results can be requested + * Parameter types tested: List of contained-classes + */ LeaderBoard: function (assert) { var clientRequest = { MaxResultsCount: 3, StartPosition: 0, - StatisticName: PlayFabApiTests.testConstants.TEST_STAT_NAME, - UseSpecificVersion: false, - Version: 0 + StatisticName: PlayFabApiTests.testConstants.TEST_STAT_NAME }; var serverRequest = { MaxResultsCount: 3, @@ -380,11 +318,10 @@ var PlayFabApiTests = { PlayFabClientSDK.GetLeaderboard(clientRequest, PlayFabApiTests.CallbackWrapper("getLeaderboardCallbackC", getLeaderboardCallbackC, assert)); PlayFabServerSDK.GetLeaderboard(serverRequest, PlayFabApiTests.CallbackWrapper("getLeaderboardCallbackS", getLeaderboardCallbackS, assert)); }, - /// - /// CLIENT API - /// Test that AccountInfo can be requested - /// Parameter types tested: List of enum-as-strings converted to list of enums - /// + /* CLIENT API + * Test that AccountInfo can be requested + * Parameter types tested: List of enum-as-strings converted to list of enums + */ AccountInfo: function (assert) { var getDone = assert.async(); var getAccountInfoCallback = function (result, error) { @@ -397,10 +334,9 @@ var PlayFabApiTests = { }; PlayFabClientSDK.GetAccountInfo({}, PlayFabApiTests.CallbackWrapper("getAccountInfoCallback", getAccountInfoCallback, assert)); }, - /// - /// CLIENT API - /// Test that CloudScript can be properly set up and invoked - /// + /* CLIENT API + * Test that CloudScript can be properly set up and invoked + */ CloudScript: function (assert) { var hwDone = assert.async(); var helloWorldRequest = { @@ -417,10 +353,9 @@ var PlayFabApiTests = { }; PlayFabClientSDK.ExecuteCloudScript(helloWorldRequest, PlayFabApiTests.CallbackWrapper("helloWorldCallback", helloWorldCallback, assert)); }, - /// - /// CLIENT API - /// Test that CloudScript errors can be deciphered - /// + /* CLIENT API + * Test that CloudScript errors can be deciphered + */ CloudScriptError: function (assert) { var errDone = assert.async(); var errRequest = { @@ -437,10 +372,9 @@ var PlayFabApiTests = { }; PlayFabClientSDK.ExecuteCloudScript(errRequest, PlayFabApiTests.CallbackWrapper("errCallback", errCallback, assert)); }, - /// - /// CLIENT API - /// Test that the client can publish custom PlayStream events - /// + /* CLIENT API + * Test that the client can publish custom PlayStream events + */ WriteEvent: function (assert) { var writeEventDone = assert.async(); var writeEventRequest = { @@ -455,6 +389,82 @@ var PlayFabApiTests = { }; PlayFabClientSDK.WritePlayerEvent(writeEventRequest, PlayFabApiTests.CallbackWrapper("writeEventCallback", writeEventCallback, assert)); }, + ///* ENTITY API + // * Test a sequence of calls that modifies saved data, + // * and verifies that the next sequential API call contains updated data. + // * Verify that the data is correctly modified on the next call. + // * Parameter types tested: string, Dictionary, DateTime + // */ + GetEntityToken: function (assert) { + var getTokenDone = assert.async(); + var getTokenCallback = function (result, error) { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetToken result"); + PlayFabApiTests.testData.entityId = result.data.Entity.Id; + PlayFabApiTests.testData.entityType = result.data.Entity.Type; + getTokenDone(); + }; + var getTokenRequest = {}; + PlayFabAuthenticationSDK.GetEntityToken(getTokenRequest, PlayFabApiTests.CallbackWrapper("getTokenCallback", getTokenCallback, assert)); + }, + ///* ENTITY API + // * Test a sequence of calls that modifies saved data, + // * and verifies that the next sequential API call contains updated data. + // * Verify that the data is correctly modified on the next call. + // * Parameter types tested: string, Dictionary, DateTime + // */ + EntityObjects: function (assert) { + var getObjectRequest = { + Entity: { + Id: PlayFabApiTests.testData.entityId, + Type: PlayFabApiTests.testData.entityType, + }, + EscapeObject: true, + }; + // This test is always exactly 3 async calls + var get1Done = assert.async(); + var updateDone = assert.async(); + var get2Done = assert.async(); + var getObjectCallback2 = function (result, error) { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetObjects result"); + assert.ok(result.data.Objects != null, "Testing GetObjects Objects"); + var actualtestNumber = JSON.parse(result.data.Objects[PlayFabApiTests.testConstants.TEST_DATA_KEY].EscapedDataObject); + assert.ok(actualtestNumber != null && typeof actualtestNumber === "number", "Testing GetObjects contains target obj (as number)"); + assert.equal(PlayFabApiTests.testData.testNumber, actualtestNumber, "Testing incrementing counter: " + PlayFabApiTests.testData.testNumber + "==" + actualtestNumber); + get2Done(); + }; + var setObjectCallback = function (result, error) { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing SetObjects result"); + PlayFabDataSDK.GetObjects(getObjectRequest, PlayFabApiTests.CallbackWrapper("getObjectCallback2", getObjectCallback2, assert)); + updateDone(); + }; + var getObjectCallback1 = function (result, error) { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetObjects result"); + assert.ok(result.data.Objects != null, "Testing GetObjects Objects"); + PlayFabApiTests.testData.testNumber = 0; + if (result.data.Objects.hasOwnProperty(PlayFabApiTests.testConstants.TEST_DATA_KEY)) + PlayFabApiTests.testData.testNumber = JSON.parse(result.data.Objects[PlayFabApiTests.testConstants.TEST_DATA_KEY].EscapedDataObject); + PlayFabApiTests.testData.testNumber = (PlayFabApiTests.testData.testNumber + 1) % 100; // This test is about the expected value changing - but not testing more complicated issues like bounds + var updateDataRequest = { + Entity: { + Id: PlayFabApiTests.testData.entityId, + Type: PlayFabApiTests.testData.entityType, + }, + Objects: [{ ObjectName: PlayFabApiTests.testConstants.TEST_DATA_KEY, DataObject: PlayFabApiTests.testData.testNumber }] + }; + PlayFabDataSDK.SetObjects(updateDataRequest, PlayFabApiTests.CallbackWrapper("setObjectCallback", setObjectCallback, assert)); + get1Done(); + }; + // Kick off this test process + PlayFabDataSDK.GetObjects(getObjectRequest, PlayFabApiTests.CallbackWrapper("getObjectCallback1", getObjectCallback1, assert)); + }, + /* CLIENT API + * Test that the client can log out + */ + ForgetCredentials: function (assert) { + assert.ok(PlayFabClientSDK.IsClientLoggedIn(), "Client should be logged in."); + PlayFabClientSDK.ForgetAllCredentials(); + assert.ok(!PlayFabClientSDK.IsClientLoggedIn(), "Client should NOT be logged in."); + }, }; // The test report that will ultimately be relayed back to Cloud Script when the suite finishes var PfTestReport = [{ diff --git a/PlayFabTestingExample/PlayFabApiTest.ts b/PlayFabTestingExample/PlayFabApiTest.ts index b227da70..336ffa7f 100644 --- a/PlayFabTestingExample/PlayFabApiTest.ts +++ b/PlayFabTestingExample/PlayFabApiTest.ts @@ -1,24 +1,27 @@ declare var QUnit: any; declare var $: any; -interface IAction { (): void } +interface IAction { (any): void } var PlayFabApiTests = { testTitleDataFilename: "testTitleData.json", // Since you never want this to be public, a web page can ONLY load this if it's a local file in the same directory (Also can't convert to environment variable) + testRetryDelay: 250, + testRetryCount: 8, titleData: { titleId: null, // put titleId here developerSecretKey: null, // put secretKey here userEmail: "put valid email associated with an existing account here", - characterName: "put any character name here" + extraHeaders: {} }, testData: { - playFabId: null, // Filled during login - characterId: null, // Filled during character-access - testNumber: null // Used by several tests + entityToken: null, // Entity-Login: filled after login + entityId: null, // Entity-Login: filled after login + entityType: null, // Entity-Login: filled after login + playFabId: null, // Client-Login: filled during login + testNumber: null, // Arbitrary counter, used by several tests }, testConstants: { TEST_DATA_KEY: "testCounter", - TEST_STAT_NAME: "str", - CHAR_TEST_TYPE: "Fighter" + TEST_STAT_NAME: "str" }, ManualExecution: function (): void { @@ -40,20 +43,22 @@ var PlayFabApiTests = { QUnit.test("InvalidLogin", PlayFabApiTests.InvalidLogin); QUnit.test("InvalidRegistration", PlayFabApiTests.InvalidRegistration); QUnit.test("LoginOrRegister", PlayFabApiTests.LoginOrRegister); - QUnit.test("LoginWithAdvertisingId", PlayFabApiTests.LoginWithAdvertisingId); - setTimeout(function (): void { PlayFabApiTests.PostLoginTests(0); }, 200); + setTimeout(function (): void { PlayFabApiTests.PostLoginTests(0); }, PlayFabApiTests.testRetryDelay); + setTimeout(function (): void { PlayFabApiTests.PostEntityTokenTests(0); }, PlayFabApiTests.testRetryDelay); }, PostLoginTests: function (count): void { - if (count > 5) + if (count > PlayFabApiTests.testRetryCount) return; if (!PlayFabClientSDK.IsClientLoggedIn()) { // Wait for login - setTimeout(function (): void { PlayFabApiTests.PostLoginTests(count + 1); }, 200); + setTimeout(function (): void { PlayFabApiTests.PostLoginTests(count + 1); }, PlayFabApiTests.testRetryDelay); } else { // Continue with other tests that require login + QUnit.test("GetEntityToken", PlayFabApiTests.GetEntityToken); + QUnit.test("EntityObjects", PlayFabApiTests.EntityObjects); QUnit.test("UserDataApi", PlayFabApiTests.UserDataApi); QUnit.test("PlayerStatisticsApi", PlayFabApiTests.PlayerStatisticsApi); QUnit.test("UserCharacter", PlayFabApiTests.UserCharacter); @@ -62,15 +67,28 @@ var PlayFabApiTests = { QUnit.test("CloudScript", PlayFabApiTests.CloudScript); QUnit.test("CloudScriptError", PlayFabApiTests.CloudScriptError); QUnit.test("WriteEvent", PlayFabApiTests.WriteEvent); + QUnit.test("ForgetCredentials", PlayFabApiTests.ForgetCredentials); } }, - SetUp: function (inputTitleData): void { + PostEntityTokenTests: function (count): void { + if (count > PlayFabApiTests.testRetryCount) + return; + + if (!PlayFab["_internalSettings"].entityToken) { + // Wait for login + setTimeout(function (): void { PlayFabApiTests.PostEntityTokenTests(count + 1); }, PlayFabApiTests.testRetryDelay); + } else { + // Continue with other tests that require login + // QUnit.test("EntityObjects", PlayFabApiTests.EntityObjects); // TODO: Release Entity API + } + }, + + SetUp: function (inputTitleData): boolean { // All of these must exist for the titleData load to be successful var titleDataValid = inputTitleData.hasOwnProperty("titleId") && inputTitleData.titleId != null && inputTitleData.hasOwnProperty("developerSecretKey") && inputTitleData.developerSecretKey != null - && inputTitleData.hasOwnProperty("userEmail") - && inputTitleData.hasOwnProperty("characterName"); + && inputTitleData.hasOwnProperty("userEmail"); if (titleDataValid) PlayFabApiTests.titleData = inputTitleData; @@ -79,6 +97,7 @@ var PlayFabApiTests = { PlayFab.settings.titleId = PlayFabApiTests.titleData.titleId; PlayFab.settings.developerSecretKey = PlayFabApiTests.titleData.developerSecretKey; + PlayFab.settings.GlobalHeaderInjection = PlayFabApiTests.titleData.extraHeaders; return titleDataValid; }, @@ -94,10 +113,10 @@ var PlayFabApiTests = { }; }, - SimpleCallbackWrapper: function (callbackName: string, callback: IAction, assert): IAction { + SimpleCallbackWrapper: function (callbackName: string, callback: IAction, assert, kwargs: any = null): IAction { return function (): void { try { - callback(); + callback(kwargs); } catch (e) { console.log("Exception thrown during " + callbackName + " callback: " + e.toString() + "\n" + e.stack); // Very irritatingly, qunit doesn't report failure results until all async callbacks return, which doesn't always happen when there's an exception assert.ok(false, "Exception thrown during " + callbackName + " callback: " + e.toString() + "\n" + e.stack); @@ -108,27 +127,16 @@ var PlayFabApiTests = { VerifyNullError: function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError, assert, message: string): void { var success = (result !== null && error == null); if (error != null) { - assert.ok(false, "PlayFab error message: " + PlayFabApiTests.CompileErrorReport(error)); + assert.ok(false, "PlayFab error message: " + PlayFab.GenerateErrorReport(error)); } else { assert.ok(success, message); } }, - CompileErrorReport: function (error: PlayFabModule.IPlayFabError): string { - if (error == null) - return ""; - var fullErrors = error.errorMessage; - for (var paramName in error.errorDetails) - for (var msgIdx in error.errorDetails[paramName]) - fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; - return fullErrors; - }, - - /// - /// CLIENT API - /// Try to deliberately log in with an inappropriate password, - /// and verify that the error displays as expected. - /// + /* CLIENT API + * Try to deliberately log in with an inappropriate password, + * and verify that the error displays as expected. + */ InvalidLogin: function (assert): void { var invalidDone = assert.async(); @@ -148,11 +156,10 @@ var PlayFabApiTests = { PlayFabClientSDK.LoginWithEmailAddress(invalidRequest, PlayFabApiTests.CallbackWrapper("invalidLoginCallback", invalidLoginCallback, assert)); }, - /// - /// CLIENT API - /// Try to deliberately register a user with an invalid email and password - /// Verify that errorDetails are populated correctly. - /// + /* CLIENT API + * Try to deliberately register a user with an invalid email and password + * Verify that errorDetails are populated correctly. + */ InvalidRegistration: function (assert): void { var invalidDone = assert.async(); @@ -167,7 +174,7 @@ var PlayFabApiTests = { assert.ok(error != null, "InvalidRegistration should have failed"); var expectedEmailMsg = "email address is not valid."; var expectedPasswordMsg = "password must be between"; - var errorReport = PlayFabApiTests.CompileErrorReport(error); + var errorReport = PlayFab.GenerateErrorReport(error); assert.ok(errorReport.toLowerCase().indexOf(expectedEmailMsg) > -1, "Expect errorMessage about invalid email: " + errorReport); assert.ok(errorReport.toLowerCase().indexOf(expectedPasswordMsg) > -1, "Expect errorMessage about invalid password: " + errorReport); invalidDone(); @@ -176,10 +183,9 @@ var PlayFabApiTests = { PlayFabClientSDK.RegisterPlayFabUser(invalidRequest, PlayFabApiTests.CallbackWrapper("registerCallback", registerCallback, assert)); }, - /// - /// CLIENT API - /// Log in or create a user, track their PlayFabId - /// + /* CLIENT API + * Log in or create a user, track their PlayFabId + */ LoginOrRegister: function (assert): void { var loginRequest = { CustomId: PlayFab.buildIdentifier, @@ -195,46 +201,17 @@ var PlayFabApiTests = { loginDone(); }; - PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("loginCallback", loginCallback, assert)); - }, - - /// - /// CLIENT API - /// Test that the login call sequence sends the AdvertisingId when set - /// - LoginWithAdvertisingId: function (assert): void { - PlayFab.settings.advertisingIdType = PlayFab.settings.AD_TYPE_ANDROID_ID; - PlayFab.settings.advertisingIdValue = "PlayFabTestId"; - - var loginDone = assert.async(); - var count = -1; - var finishAdvertId = function (): void { - count += 1; - if (count <= 10 && PlayFab.settings.advertisingIdType !== PlayFab.settings.AD_TYPE_ANDROID_ID + "_Successful") { - setTimeout(PlayFabApiTests.SimpleCallbackWrapper("finishAdvertId", finishAdvertId, assert), 200); - } else { - assert.ok(PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_ANDROID_ID + "_Successful", "Testing whether advertisingId submitted properly"); - loginDone(); - } - }; - var advertLoginCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { - PlayFabApiTests.VerifyNullError(result, error, assert, "Testing Advert-Login result"); - setTimeout(PlayFabApiTests.SimpleCallbackWrapper("finishAdvertId", finishAdvertId, assert), 200); - }; - var loginRequest = { - CustomId: PlayFab.buildIdentifier, - CreateAccount: true - }; - PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("advertLoginCallback", advertLoginCallback, assert)); + var loginPromise = Promise.resolve(PlayFabClientSDK.LoginWithCustomID(loginRequest, PlayFabApiTests.CallbackWrapper("loginCallback", loginCallback, assert))) + // By definition, a promise object should have a .then function, and Promise.resolve(promise) should equal promise + assert.ok(typeof loginPromise.then === "function" && Promise.resolve(loginPromise) === loginPromise, "Testing whether the login request returned a promise object"); }, - /// - /// CLIENT API - /// Test a sequence of calls that modifies saved data, - /// and verifies that the next sequential API call contains updated data. - /// Verify that the data is correctly modified on the next call. - /// Parameter types tested: string, Dictionary, DateTime - /// + /* CLIENT API + * Test a sequence of calls that modifies saved data, + * and verifies that the next sequential API call contains updated data. + * Verify that the data is correctly modified on the next call. + * Parameter types tested: string, Dictionary, DateTime + */ UserDataApi: function (assert): void { var getDataRequest = {}; // null also works @@ -283,13 +260,12 @@ var PlayFabApiTests = { PlayFabClientSDK.GetUserData(getDataRequest, PlayFabApiTests.CallbackWrapper("getDataCallback1", getDataCallback1, assert)); }, - /// - /// CLIENT API - /// Test a sequence of calls that modifies saved data, - /// and verifies that the next sequential API call contains updated data. - /// Verify that the data is saved correctly, and that specific types are tested - /// Parameter types tested: Dictionary - /// + /* CLIENT API + * Test a sequence of calls that modifies saved data, + * and verifies that the next sequential API call contains updated data. + * Verify that the data is saved correctly, and that specific types are tested + * Parameter types tested: Dictionary + */ PlayerStatisticsApi: function (assert): void { var getStatsRequest = {}; // null also works @@ -336,73 +312,30 @@ var PlayFabApiTests = { PlayFabClientSDK.GetPlayerStatistics(getStatsRequest, PlayFabApiTests.CallbackWrapper("getStatsCallback1", getStatsCallback1, assert)); }, - /// - /// SERVER API - /// Get or create the given test character for the given user - /// Parameter types tested: Contained-Classes, string - /// + /* CLIENT API + * Get or create the given test character for the given user + * Parameter types tested: Contained-Classes, string + */ UserCharacter: function (assert): void { var getCharsRequest = {}; - var grantCharRequest = { - TitleId: PlayFabApiTests.titleData.titleId, - PlayFabId: PlayFabApiTests.testData.playFabId, - CharacterName: PlayFabApiTests.titleData.characterName, - CharacterType: PlayFabApiTests.testConstants.CHAR_TEST_TYPE - }; - - // We don't know at this point how many async calls we'll make - var getDone = null; - var grantDone = null; + var getDone = assert.async(); - var mandatoryGetCharsCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { - // GetChars MUST succeed at some point during this test + var getCharsCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetChars result"); - - for (var i in result.data.Characters) - if (result.data.Characters[i].CharacterName === PlayFabApiTests.titleData.characterName) - PlayFabApiTests.testData.characterId = result.data.Characters[i].CharacterId; // Save the characterId, it will be used in other tests - - assert.ok(PlayFabApiTests.testData.characterId != null, "Searching for " + PlayFabApiTests.titleData.characterName + " on this account."); getDone(); }; - var grantCharCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { - // Second character callback MUST succeed - PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GrantCharacter result"); - - // Get chars again, this time with the newly granted character - getDone = assert.async(); - PlayFabClientSDK.GetAllUsersCharacters(grantCharRequest, PlayFabApiTests.CallbackWrapper("mandatoryGetCharsCallback", mandatoryGetCharsCallback, assert)); - grantDone(); - }; - var optionalGetCharsCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { - // First get chars falls back upon grant-char if target character not present - if (result.data.Characters.length === 0) { - // Register the character and try again - grantDone = assert.async(); - PlayFabServerSDK.GrantCharacterToUser(grantCharRequest, PlayFabApiTests.CallbackWrapper("grantCharCallback", grantCharCallback, assert)); - getDone(); - } - else { - // Confirm the successful login - mandatoryGetCharsCallback(result, error); - } - }; - getDone = assert.async(); - PlayFabClientSDK.GetAllUsersCharacters(getCharsRequest, PlayFabApiTests.CallbackWrapper("optionalGetCharsCallback", optionalGetCharsCallback, assert)); + PlayFabClientSDK.GetAllUsersCharacters(getCharsRequest, PlayFabApiTests.CallbackWrapper("getCharsCallback", getCharsCallback, assert)); }, - /// - /// CLIENT AND SERVER API - /// Test that leaderboard results can be requested - /// Parameter types tested: List of contained-classes - /// + /* CLIENT AND SERVER API + * Test that leaderboard results can be requested + * Parameter types tested: List of contained-classes + */ LeaderBoard: function (assert): void { var clientRequest = { MaxResultsCount: 3, StartPosition: 0, - StatisticName: PlayFabApiTests.testConstants.TEST_STAT_NAME, - UseSpecificVersion: false, - Version: 0 + StatisticName: PlayFabApiTests.testConstants.TEST_STAT_NAME }; var serverRequest = { MaxResultsCount: 3, @@ -435,11 +368,10 @@ var PlayFabApiTests = { PlayFabServerSDK.GetLeaderboard(serverRequest, PlayFabApiTests.CallbackWrapper("getLeaderboardCallbackS", getLeaderboardCallbackS, assert)); }, - /// - /// CLIENT API - /// Test that AccountInfo can be requested - /// Parameter types tested: List of enum-as-strings converted to list of enums - /// + /* CLIENT API + * Test that AccountInfo can be requested + * Parameter types tested: List of enum-as-strings converted to list of enums + */ AccountInfo: function (assert): void { var getDone = assert.async(); @@ -455,10 +387,9 @@ var PlayFabApiTests = { PlayFabClientSDK.GetAccountInfo({}, PlayFabApiTests.CallbackWrapper("getAccountInfoCallback", getAccountInfoCallback, assert)); }, - /// - /// CLIENT API - /// Test that CloudScript can be properly set up and invoked - /// + /* CLIENT API + * Test that CloudScript can be properly set up and invoked + */ CloudScript: function (assert): void { var hwDone = assert.async(); @@ -479,10 +410,9 @@ var PlayFabApiTests = { PlayFabClientSDK.ExecuteCloudScript(helloWorldRequest, PlayFabApiTests.CallbackWrapper("helloWorldCallback", helloWorldCallback, assert)); }, - /// - /// CLIENT API - /// Test that CloudScript errors can be deciphered - /// + /* CLIENT API + * Test that CloudScript errors can be deciphered + */ CloudScriptError: function (assert): void { var errDone = assert.async(); @@ -503,10 +433,9 @@ var PlayFabApiTests = { PlayFabClientSDK.ExecuteCloudScript(errRequest, PlayFabApiTests.CallbackWrapper("errCallback", errCallback, assert)); }, - /// - /// CLIENT API - /// Test that the client can publish custom PlayStream events - /// + /* CLIENT API + * Test that the client can publish custom PlayStream events + */ WriteEvent: function (assert): void { var writeEventDone = assert.async(); @@ -524,6 +453,92 @@ var PlayFabApiTests = { PlayFabClientSDK.WritePlayerEvent(writeEventRequest, PlayFabApiTests.CallbackWrapper("writeEventCallback", writeEventCallback, assert)); }, + + ///* ENTITY API + // * Test a sequence of calls that modifies saved data, + // * and verifies that the next sequential API call contains updated data. + // * Verify that the data is correctly modified on the next call. + // * Parameter types tested: string, Dictionary, DateTime + // */ + GetEntityToken: function (assert): void { + var getTokenDone = assert.async(); + var getTokenCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetToken result"); + PlayFabApiTests.testData.entityId = result.data.Entity.Id; + PlayFabApiTests.testData.entityType = result.data.Entity.Type; + getTokenDone(); + }; + + var getTokenRequest = {}; + PlayFabAuthenticationSDK.GetEntityToken(getTokenRequest, PlayFabApiTests.CallbackWrapper("getTokenCallback", getTokenCallback, assert)); + }, + + ///* ENTITY API + // * Test a sequence of calls that modifies saved data, + // * and verifies that the next sequential API call contains updated data. + // * Verify that the data is correctly modified on the next call. + // * Parameter types tested: string, Dictionary, DateTime + // */ + EntityObjects: function (assert): void { + var getObjectRequest = { + Entity: { + Id: PlayFabApiTests.testData.entityId, + Type: PlayFabApiTests.testData.entityType, + }, + EscapeObject: true, + }; + + // This test is always exactly 3 async calls + var get1Done = assert.async(); + var updateDone = assert.async(); + var get2Done = assert.async(); + + var getObjectCallback2 = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetObjects result"); + assert.ok(result.data.Objects != null, "Testing GetObjects Objects"); + var actualtestNumber = JSON.parse(result.data.Objects[PlayFabApiTests.testConstants.TEST_DATA_KEY].EscapedDataObject); + assert.ok(actualtestNumber != null && typeof actualtestNumber === "number", "Testing GetObjects contains target obj (as number)"); + + assert.equal(PlayFabApiTests.testData.testNumber, actualtestNumber, "Testing incrementing counter: " + PlayFabApiTests.testData.testNumber + "==" + actualtestNumber); + get2Done(); + }; + var setObjectCallback = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing SetObjects result"); + + PlayFabDataSDK.GetObjects(getObjectRequest, PlayFabApiTests.CallbackWrapper("getObjectCallback2", getObjectCallback2, assert)); + updateDone(); + }; + var getObjectCallback1 = function (result: PlayFabModule.SuccessContainer, error: PlayFabModule.IPlayFabError): void { + PlayFabApiTests.VerifyNullError(result, error, assert, "Testing GetObjects result"); + assert.ok(result.data.Objects != null, "Testing GetObjects Objects"); + PlayFabApiTests.testData.testNumber = 0; + if (result.data.Objects.hasOwnProperty(PlayFabApiTests.testConstants.TEST_DATA_KEY)) + PlayFabApiTests.testData.testNumber = JSON.parse(result.data.Objects[PlayFabApiTests.testConstants.TEST_DATA_KEY].EscapedDataObject); + PlayFabApiTests.testData.testNumber = (PlayFabApiTests.testData.testNumber + 1) % 100; // This test is about the expected value changing - but not testing more complicated issues like bounds + + var updateDataRequest = { + Entity: { + Id: PlayFabApiTests.testData.entityId, + Type: PlayFabApiTests.testData.entityType, + }, + Objects: [{ ObjectName: PlayFabApiTests.testConstants.TEST_DATA_KEY, DataObject: PlayFabApiTests.testData.testNumber }] + }; + PlayFabDataSDK.SetObjects(updateDataRequest, PlayFabApiTests.CallbackWrapper("setObjectCallback", setObjectCallback, assert)); + get1Done(); + }; + + // Kick off this test process + PlayFabDataSDK.GetObjects(getObjectRequest, PlayFabApiTests.CallbackWrapper("getObjectCallback1", getObjectCallback1, assert)); + }, + + /* CLIENT API + * Test that the client can log out + */ + ForgetCredentials: function (assert): void { + assert.ok(PlayFabClientSDK.IsClientLoggedIn(), "Client should be logged in."); + PlayFabClientSDK.ForgetAllCredentials(); + assert.ok(!PlayFabClientSDK.IsClientLoggedIn(), "Client should NOT be logged in."); + }, }; // The test report that will ultimately be relayed back to Cloud Script when the suite finishes diff --git a/PlayFabTestingExample/code.jquery.com/qunit/license.txt b/PlayFabTestingExample/code.jquery.com/qunit/license.txt new file mode 100644 index 00000000..d7fa09de --- /dev/null +++ b/PlayFabTestingExample/code.jquery.com/qunit/license.txt @@ -0,0 +1,9 @@ +Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/PlayFabTestingExample/code.jquery.com/qunit/qunit-1.19.0.js b/PlayFabTestingExample/code.jquery.com/qunit/qunit-1.19.0.js deleted file mode 100644 index 2fbd37d7..00000000 --- a/PlayFabTestingExample/code.jquery.com/qunit/qunit-1.19.0.js +++ /dev/null @@ -1,3963 +0,0 @@ -/*! - * QUnit 1.19.0 - * http://qunitjs.com/ - * - * Copyright jQuery Foundation and other contributors - * Released under the MIT license - * http://jquery.org/license - * - * Date: 2015-09-01T15:00Z - */ - -(function( global ) { - -var QUnit = {}; - -var Date = global.Date; -var now = Date.now || function() { - return new Date().getTime(); -}; - -var setTimeout = global.setTimeout; -var clearTimeout = global.clearTimeout; - -// Store a local window from the global to allow direct references. -var window = global.window; - -var defined = { - document: window && window.document !== undefined, - setTimeout: setTimeout !== undefined, - sessionStorage: (function() { - var x = "qunit-test-string"; - try { - sessionStorage.setItem( x, x ); - sessionStorage.removeItem( x ); - return true; - } catch ( e ) { - return false; - } - }() ) -}; - -var fileName = ( sourceFromStacktrace( 0 ) || "" ).replace( /(:\d+)+\)?/, "" ).replace( /.+\//, "" ); -var globalStartCalled = false; -var runStarted = false; - -var toString = Object.prototype.toString, - hasOwn = Object.prototype.hasOwnProperty; - -// returns a new Array with the elements that are in a but not in b -function diff( a, b ) { - var i, j, - result = a.slice(); - - for ( i = 0; i < result.length; i++ ) { - for ( j = 0; j < b.length; j++ ) { - if ( result[ i ] === b[ j ] ) { - result.splice( i, 1 ); - i--; - break; - } - } - } - return result; -} - -// from jquery.js -function inArray( elem, array ) { - if ( array.indexOf ) { - return array.indexOf( elem ); - } - - for ( var i = 0, length = array.length; i < length; i++ ) { - if ( array[ i ] === elem ) { - return i; - } - } - - return -1; -} - -/** - * Makes a clone of an object using only Array or Object as base, - * and copies over the own enumerable properties. - * - * @param {Object} obj - * @return {Object} New object with only the own properties (recursively). - */ -function objectValues ( obj ) { - var key, val, - vals = QUnit.is( "array", obj ) ? [] : {}; - for ( key in obj ) { - if ( hasOwn.call( obj, key ) ) { - val = obj[ key ]; - vals[ key ] = val === Object( val ) ? objectValues( val ) : val; - } - } - return vals; -} - -function extend( a, b, undefOnly ) { - for ( var prop in b ) { - if ( hasOwn.call( b, prop ) ) { - - // Avoid "Member not found" error in IE8 caused by messing with window.constructor - // This block runs on every environment, so `global` is being used instead of `window` - // to avoid errors on node. - if ( prop !== "constructor" || a !== global ) { - if ( b[ prop ] === undefined ) { - delete a[ prop ]; - } else if ( !( undefOnly && typeof a[ prop ] !== "undefined" ) ) { - a[ prop ] = b[ prop ]; - } - } - } - } - - return a; -} - -function objectType( obj ) { - if ( typeof obj === "undefined" ) { - return "undefined"; - } - - // Consider: typeof null === object - if ( obj === null ) { - return "null"; - } - - var match = toString.call( obj ).match( /^\[object\s(.*)\]$/ ), - type = match && match[ 1 ] || ""; - - switch ( type ) { - case "Number": - if ( isNaN( obj ) ) { - return "nan"; - } - return "number"; - case "String": - case "Boolean": - case "Array": - case "Set": - case "Map": - case "Date": - case "RegExp": - case "Function": - return type.toLowerCase(); - } - if ( typeof obj === "object" ) { - return "object"; - } - return undefined; -} - -// Safe object type checking -function is( type, obj ) { - return QUnit.objectType( obj ) === type; -} - -var getUrlParams = function() { - var i, current; - var urlParams = {}; - var location = window.location; - var params = location.search.slice( 1 ).split( "&" ); - var length = params.length; - - if ( params[ 0 ] ) { - for ( i = 0; i < length; i++ ) { - current = params[ i ].split( "=" ); - current[ 0 ] = decodeURIComponent( current[ 0 ] ); - - // allow just a key to turn on a flag, e.g., test.html?noglobals - current[ 1 ] = current[ 1 ] ? decodeURIComponent( current[ 1 ] ) : true; - if ( urlParams[ current[ 0 ] ] ) { - urlParams[ current[ 0 ] ] = [].concat( urlParams[ current[ 0 ] ], current[ 1 ] ); - } else { - urlParams[ current[ 0 ] ] = current[ 1 ]; - } - } - } - - return urlParams; -}; - -// Doesn't support IE6 to IE9, it will return undefined on these browsers -// See also https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Error/Stack -function extractStacktrace( e, offset ) { - offset = offset === undefined ? 4 : offset; - - var stack, include, i; - - if ( e.stack ) { - stack = e.stack.split( "\n" ); - if ( /^error$/i.test( stack[ 0 ] ) ) { - stack.shift(); - } - if ( fileName ) { - include = []; - for ( i = offset; i < stack.length; i++ ) { - if ( stack[ i ].indexOf( fileName ) !== -1 ) { - break; - } - include.push( stack[ i ] ); - } - if ( include.length ) { - return include.join( "\n" ); - } - } - return stack[ offset ]; - - // Support: Safari <=6 only - } else if ( e.sourceURL ) { - - // exclude useless self-reference for generated Error objects - if ( /qunit.js$/.test( e.sourceURL ) ) { - return; - } - - // for actual exceptions, this is useful - return e.sourceURL + ":" + e.line; - } -} - -function sourceFromStacktrace( offset ) { - var error = new Error(); - - // Support: Safari <=7 only, IE <=10 - 11 only - // Not all browsers generate the `stack` property for `new Error()`, see also #636 - if ( !error.stack ) { - try { - throw error; - } catch ( err ) { - error = err; - } - } - - return extractStacktrace( error, offset ); -} - -/** - * Config object: Maintain internal state - * Later exposed as QUnit.config - * `config` initialized at top of scope - */ -var config = { - // The queue of tests to run - queue: [], - - // block until document ready - blocking: true, - - // by default, run previously failed tests first - // very useful in combination with "Hide passed tests" checked - reorder: true, - - // by default, modify document.title when suite is done - altertitle: true, - - // by default, scroll to top of the page when suite is done - scrolltop: true, - - // depth up-to which object will be dumped - maxDepth: 5, - - // when enabled, all tests must call expect() - requireExpects: false, - - // add checkboxes that are persisted in the query-string - // when enabled, the id is set to `true` as a `QUnit.config` property - urlConfig: [ - { - id: "hidepassed", - label: "Hide passed tests", - tooltip: "Only show tests and assertions that fail. Stored as query-strings." - }, - { - id: "noglobals", - label: "Check for Globals", - tooltip: "Enabling this will test if any test introduces new properties on the " + - "global object (`window` in Browsers). Stored as query-strings." - }, - { - id: "notrycatch", - label: "No try-catch", - tooltip: "Enabling this will run tests outside of a try-catch block. Makes debugging " + - "exceptions in IE reasonable. Stored as query-strings." - } - ], - - // Set of all modules. - modules: [], - - // The first unnamed module - currentModule: { - name: "", - tests: [] - }, - - callbacks: {} -}; - -var urlParams = defined.document ? getUrlParams() : {}; - -// Push a loose unnamed module to the modules collection -config.modules.push( config.currentModule ); - -if ( urlParams.filter === true ) { - delete urlParams.filter; -} - -// String search anywhere in moduleName+testName -config.filter = urlParams.filter; - -config.testId = []; -if ( urlParams.testId ) { - // Ensure that urlParams.testId is an array - urlParams.testId = decodeURIComponent( urlParams.testId ).split( "," ); - for (var i = 0; i < urlParams.testId.length; i++ ) { - config.testId.push( urlParams.testId[ i ] ); - } -} - -var loggingCallbacks = {}; - -// Register logging callbacks -function registerLoggingCallbacks( obj ) { - var i, l, key, - callbackNames = [ "begin", "done", "log", "testStart", "testDone", - "moduleStart", "moduleDone" ]; - - function registerLoggingCallback( key ) { - var loggingCallback = function( callback ) { - if ( objectType( callback ) !== "function" ) { - throw new Error( - "QUnit logging methods require a callback function as their first parameters." - ); - } - - config.callbacks[ key ].push( callback ); - }; - - // DEPRECATED: This will be removed on QUnit 2.0.0+ - // Stores the registered functions allowing restoring - // at verifyLoggingCallbacks() if modified - loggingCallbacks[ key ] = loggingCallback; - - return loggingCallback; - } - - for ( i = 0, l = callbackNames.length; i < l; i++ ) { - key = callbackNames[ i ]; - - // Initialize key collection of logging callback - if ( objectType( config.callbacks[ key ] ) === "undefined" ) { - config.callbacks[ key ] = []; - } - - obj[ key ] = registerLoggingCallback( key ); - } -} - -function runLoggingCallbacks( key, args ) { - var i, l, callbacks; - - callbacks = config.callbacks[ key ]; - for ( i = 0, l = callbacks.length; i < l; i++ ) { - callbacks[ i ]( args ); - } -} - -// DEPRECATED: This will be removed on 2.0.0+ -// This function verifies if the loggingCallbacks were modified by the user -// If so, it will restore it, assign the given callback and print a console warning -function verifyLoggingCallbacks() { - var loggingCallback, userCallback; - - for ( loggingCallback in loggingCallbacks ) { - if ( QUnit[ loggingCallback ] !== loggingCallbacks[ loggingCallback ] ) { - - userCallback = QUnit[ loggingCallback ]; - - // Restore the callback function - QUnit[ loggingCallback ] = loggingCallbacks[ loggingCallback ]; - - // Assign the deprecated given callback - QUnit[ loggingCallback ]( userCallback ); - - if ( global.console && global.console.warn ) { - global.console.warn( - "QUnit." + loggingCallback + " was replaced with a new value.\n" + - "Please, check out the documentation on how to apply logging callbacks.\n" + - "Reference: http://api.qunitjs.com/category/callbacks/" - ); - } - } - } -} - -( function() { - if ( !defined.document ) { - return; - } - - // `onErrorFnPrev` initialized at top of scope - // Preserve other handlers - var onErrorFnPrev = window.onerror; - - // Cover uncaught exceptions - // Returning true will suppress the default browser handler, - // returning false will let it run. - window.onerror = function( error, filePath, linerNr ) { - var ret = false; - if ( onErrorFnPrev ) { - ret = onErrorFnPrev( error, filePath, linerNr ); - } - - // Treat return value as window.onerror itself does, - // Only do our handling if not suppressed. - if ( ret !== true ) { - if ( QUnit.config.current ) { - if ( QUnit.config.current.ignoreGlobalErrors ) { - return true; - } - QUnit.pushFailure( error, filePath + ":" + linerNr ); - } else { - QUnit.test( "global failure", extend(function() { - QUnit.pushFailure( error, filePath + ":" + linerNr ); - }, { validTest: true } ) ); - } - return false; - } - - return ret; - }; -} )(); - -QUnit.urlParams = urlParams; - -// Figure out if we're running the tests from a server or not -QUnit.isLocal = !( defined.document && window.location.protocol !== "file:" ); - -// Expose the current QUnit version -QUnit.version = "1.19.0"; - -extend( QUnit, { - - // call on start of module test to prepend name to all tests - module: function( name, testEnvironment ) { - var currentModule = { - name: name, - testEnvironment: testEnvironment, - tests: [] - }; - - // DEPRECATED: handles setup/teardown functions, - // beforeEach and afterEach should be used instead - if ( testEnvironment && testEnvironment.setup ) { - testEnvironment.beforeEach = testEnvironment.setup; - delete testEnvironment.setup; - } - if ( testEnvironment && testEnvironment.teardown ) { - testEnvironment.afterEach = testEnvironment.teardown; - delete testEnvironment.teardown; - } - - config.modules.push( currentModule ); - config.currentModule = currentModule; - }, - - // DEPRECATED: QUnit.asyncTest() will be removed in QUnit 2.0. - asyncTest: asyncTest, - - test: test, - - skip: skip, - - // DEPRECATED: The functionality of QUnit.start() will be altered in QUnit 2.0. - // In QUnit 2.0, invoking it will ONLY affect the `QUnit.config.autostart` blocking behavior. - start: function( count ) { - var globalStartAlreadyCalled = globalStartCalled; - - if ( !config.current ) { - globalStartCalled = true; - - if ( runStarted ) { - throw new Error( "Called start() outside of a test context while already started" ); - } else if ( globalStartAlreadyCalled || count > 1 ) { - throw new Error( "Called start() outside of a test context too many times" ); - } else if ( config.autostart ) { - throw new Error( "Called start() outside of a test context when " + - "QUnit.config.autostart was true" ); - } else if ( !config.pageLoaded ) { - - // The page isn't completely loaded yet, so bail out and let `QUnit.load` handle it - config.autostart = true; - return; - } - } else { - - // If a test is running, adjust its semaphore - config.current.semaphore -= count || 1; - - // Don't start until equal number of stop-calls - if ( config.current.semaphore > 0 ) { - return; - } - - // throw an Error if start is called more often than stop - if ( config.current.semaphore < 0 ) { - config.current.semaphore = 0; - - QUnit.pushFailure( - "Called start() while already started (test's semaphore was 0 already)", - sourceFromStacktrace( 2 ) - ); - return; - } - } - - resumeProcessing(); - }, - - // DEPRECATED: QUnit.stop() will be removed in QUnit 2.0. - stop: function( count ) { - - // If there isn't a test running, don't allow QUnit.stop() to be called - if ( !config.current ) { - throw new Error( "Called stop() outside of a test context" ); - } - - // If a test is running, adjust its semaphore - config.current.semaphore += count || 1; - - pauseProcessing(); - }, - - config: config, - - is: is, - - objectType: objectType, - - extend: extend, - - load: function() { - config.pageLoaded = true; - - // Initialize the configuration options - extend( config, { - stats: { all: 0, bad: 0 }, - moduleStats: { all: 0, bad: 0 }, - started: 0, - updateRate: 1000, - autostart: true, - filter: "" - }, true ); - - config.blocking = false; - - if ( config.autostart ) { - resumeProcessing(); - } - }, - - stack: function( offset ) { - offset = ( offset || 0 ) + 2; - return sourceFromStacktrace( offset ); - } -}); - -registerLoggingCallbacks( QUnit ); - -function begin() { - var i, l, - modulesLog = []; - - // If the test run hasn't officially begun yet - if ( !config.started ) { - - // Record the time of the test run's beginning - config.started = now(); - - verifyLoggingCallbacks(); - - // Delete the loose unnamed module if unused. - if ( config.modules[ 0 ].name === "" && config.modules[ 0 ].tests.length === 0 ) { - config.modules.shift(); - } - - // Avoid unnecessary information by not logging modules' test environments - for ( i = 0, l = config.modules.length; i < l; i++ ) { - modulesLog.push({ - name: config.modules[ i ].name, - tests: config.modules[ i ].tests - }); - } - - // The test run is officially beginning now - runLoggingCallbacks( "begin", { - totalTests: Test.count, - modules: modulesLog - }); - } - - config.blocking = false; - process( true ); -} - -function process( last ) { - function next() { - process( last ); - } - var start = now(); - config.depth = ( config.depth || 0 ) + 1; - - while ( config.queue.length && !config.blocking ) { - if ( !defined.setTimeout || config.updateRate <= 0 || - ( ( now() - start ) < config.updateRate ) ) { - if ( config.current ) { - - // Reset async tracking for each phase of the Test lifecycle - config.current.usedAsync = false; - } - config.queue.shift()(); - } else { - setTimeout( next, 13 ); - break; - } - } - config.depth--; - if ( last && !config.blocking && !config.queue.length && config.depth === 0 ) { - done(); - } -} - -function pauseProcessing() { - config.blocking = true; - - if ( config.testTimeout && defined.setTimeout ) { - clearTimeout( config.timeout ); - config.timeout = setTimeout(function() { - if ( config.current ) { - config.current.semaphore = 0; - QUnit.pushFailure( "Test timed out", sourceFromStacktrace( 2 ) ); - } else { - throw new Error( "Test timed out" ); - } - resumeProcessing(); - }, config.testTimeout ); - } -} - -function resumeProcessing() { - runStarted = true; - - // A slight delay to allow this iteration of the event loop to finish (more assertions, etc.) - if ( defined.setTimeout ) { - setTimeout(function() { - if ( config.current && config.current.semaphore > 0 ) { - return; - } - if ( config.timeout ) { - clearTimeout( config.timeout ); - } - - begin(); - }, 13 ); - } else { - begin(); - } -} - -function done() { - var runtime, passed; - - config.autorun = true; - - // Log the last module results - if ( config.previousModule ) { - runLoggingCallbacks( "moduleDone", { - name: config.previousModule.name, - tests: config.previousModule.tests, - failed: config.moduleStats.bad, - passed: config.moduleStats.all - config.moduleStats.bad, - total: config.moduleStats.all, - runtime: now() - config.moduleStats.started - }); - } - delete config.previousModule; - - runtime = now() - config.started; - passed = config.stats.all - config.stats.bad; - - runLoggingCallbacks( "done", { - failed: config.stats.bad, - passed: passed, - total: config.stats.all, - runtime: runtime - }); -} - -function Test( settings ) { - var i, l; - - ++Test.count; - - extend( this, settings ); - this.assertions = []; - this.semaphore = 0; - this.usedAsync = false; - this.module = config.currentModule; - this.stack = sourceFromStacktrace( 3 ); - - // Register unique strings - for ( i = 0, l = this.module.tests; i < l.length; i++ ) { - if ( this.module.tests[ i ].name === this.testName ) { - this.testName += " "; - } - } - - this.testId = generateHash( this.module.name, this.testName ); - - this.module.tests.push({ - name: this.testName, - testId: this.testId - }); - - if ( settings.skip ) { - - // Skipped tests will fully ignore any sent callback - this.callback = function() {}; - this.async = false; - this.expected = 0; - } else { - this.assert = new Assert( this ); - } -} - -Test.count = 0; - -Test.prototype = { - before: function() { - if ( - - // Emit moduleStart when we're switching from one module to another - this.module !== config.previousModule || - - // They could be equal (both undefined) but if the previousModule property doesn't - // yet exist it means this is the first test in a suite that isn't wrapped in a - // module, in which case we'll just emit a moduleStart event for 'undefined'. - // Without this, reporters can get testStart before moduleStart which is a problem. - !hasOwn.call( config, "previousModule" ) - ) { - if ( hasOwn.call( config, "previousModule" ) ) { - runLoggingCallbacks( "moduleDone", { - name: config.previousModule.name, - tests: config.previousModule.tests, - failed: config.moduleStats.bad, - passed: config.moduleStats.all - config.moduleStats.bad, - total: config.moduleStats.all, - runtime: now() - config.moduleStats.started - }); - } - config.previousModule = this.module; - config.moduleStats = { all: 0, bad: 0, started: now() }; - runLoggingCallbacks( "moduleStart", { - name: this.module.name, - tests: this.module.tests - }); - } - - config.current = this; - - if ( this.module.testEnvironment ) { - delete this.module.testEnvironment.beforeEach; - delete this.module.testEnvironment.afterEach; - } - this.testEnvironment = extend( {}, this.module.testEnvironment ); - - this.started = now(); - runLoggingCallbacks( "testStart", { - name: this.testName, - module: this.module.name, - testId: this.testId - }); - - if ( !config.pollution ) { - saveGlobal(); - } - }, - - run: function() { - var promise; - - config.current = this; - - if ( this.async ) { - QUnit.stop(); - } - - this.callbackStarted = now(); - - if ( config.notrycatch ) { - promise = this.callback.call( this.testEnvironment, this.assert ); - this.resolvePromise( promise ); - return; - } - - try { - promise = this.callback.call( this.testEnvironment, this.assert ); - this.resolvePromise( promise ); - } catch ( e ) { - this.pushFailure( "Died on test #" + ( this.assertions.length + 1 ) + " " + - this.stack + ": " + ( e.message || e ), extractStacktrace( e, 0 ) ); - - // else next test will carry the responsibility - saveGlobal(); - - // Restart the tests if they're blocking - if ( config.blocking ) { - QUnit.start(); - } - } - }, - - after: function() { - checkPollution(); - }, - - queueHook: function( hook, hookName ) { - var promise, - test = this; - return function runHook() { - config.current = test; - if ( config.notrycatch ) { - promise = hook.call( test.testEnvironment, test.assert ); - test.resolvePromise( promise, hookName ); - return; - } - try { - promise = hook.call( test.testEnvironment, test.assert ); - test.resolvePromise( promise, hookName ); - } catch ( error ) { - test.pushFailure( hookName + " failed on " + test.testName + ": " + - ( error.message || error ), extractStacktrace( error, 0 ) ); - } - }; - }, - - // Currently only used for module level hooks, can be used to add global level ones - hooks: function( handler ) { - var hooks = []; - - // Hooks are ignored on skipped tests - if ( this.skip ) { - return hooks; - } - - if ( this.module.testEnvironment && - QUnit.objectType( this.module.testEnvironment[ handler ] ) === "function" ) { - hooks.push( this.queueHook( this.module.testEnvironment[ handler ], handler ) ); - } - - return hooks; - }, - - finish: function() { - config.current = this; - if ( config.requireExpects && this.expected === null ) { - this.pushFailure( "Expected number of assertions to be defined, but expect() was " + - "not called.", this.stack ); - } else if ( this.expected !== null && this.expected !== this.assertions.length ) { - this.pushFailure( "Expected " + this.expected + " assertions, but " + - this.assertions.length + " were run", this.stack ); - } else if ( this.expected === null && !this.assertions.length ) { - this.pushFailure( "Expected at least one assertion, but none were run - call " + - "expect(0) to accept zero assertions.", this.stack ); - } - - var i, - bad = 0; - - this.runtime = now() - this.started; - config.stats.all += this.assertions.length; - config.moduleStats.all += this.assertions.length; - - for ( i = 0; i < this.assertions.length; i++ ) { - if ( !this.assertions[ i ].result ) { - bad++; - config.stats.bad++; - config.moduleStats.bad++; - } - } - - runLoggingCallbacks( "testDone", { - name: this.testName, - module: this.module.name, - skipped: !!this.skip, - failed: bad, - passed: this.assertions.length - bad, - total: this.assertions.length, - runtime: this.runtime, - - // HTML Reporter use - assertions: this.assertions, - testId: this.testId, - - // Source of Test - source: this.stack, - - // DEPRECATED: this property will be removed in 2.0.0, use runtime instead - duration: this.runtime - }); - - // QUnit.reset() is deprecated and will be replaced for a new - // fixture reset function on QUnit 2.0/2.1. - // It's still called here for backwards compatibility handling - QUnit.reset(); - - config.current = undefined; - }, - - queue: function() { - var bad, - test = this; - - if ( !this.valid() ) { - return; - } - - function run() { - - // each of these can by async - synchronize([ - function() { - test.before(); - }, - - test.hooks( "beforeEach" ), - - function() { - test.run(); - }, - - test.hooks( "afterEach" ).reverse(), - - function() { - test.after(); - }, - function() { - test.finish(); - } - ]); - } - - // `bad` initialized at top of scope - // defer when previous test run passed, if storage is available - bad = QUnit.config.reorder && defined.sessionStorage && - +sessionStorage.getItem( "qunit-test-" + this.module.name + "-" + this.testName ); - - if ( bad ) { - run(); - } else { - synchronize( run, true ); - } - }, - - push: function( result, actual, expected, message, negative ) { - var source, - details = { - module: this.module.name, - name: this.testName, - result: result, - message: message, - actual: actual, - expected: expected, - testId: this.testId, - negative: negative || false, - runtime: now() - this.started - }; - - if ( !result ) { - source = sourceFromStacktrace(); - - if ( source ) { - details.source = source; - } - } - - runLoggingCallbacks( "log", details ); - - this.assertions.push({ - result: !!result, - message: message - }); - }, - - pushFailure: function( message, source, actual ) { - if ( !( this instanceof Test ) ) { - throw new Error( "pushFailure() assertion outside test context, was " + - sourceFromStacktrace( 2 ) ); - } - - var details = { - module: this.module.name, - name: this.testName, - result: false, - message: message || "error", - actual: actual || null, - testId: this.testId, - runtime: now() - this.started - }; - - if ( source ) { - details.source = source; - } - - runLoggingCallbacks( "log", details ); - - this.assertions.push({ - result: false, - message: message - }); - }, - - resolvePromise: function( promise, phase ) { - var then, message, - test = this; - if ( promise != null ) { - then = promise.then; - if ( QUnit.objectType( then ) === "function" ) { - QUnit.stop(); - then.call( - promise, - function() { QUnit.start(); }, - function( error ) { - message = "Promise rejected " + - ( !phase ? "during" : phase.replace( /Each$/, "" ) ) + - " " + test.testName + ": " + ( error.message || error ); - test.pushFailure( message, extractStacktrace( error, 0 ) ); - - // else next test will carry the responsibility - saveGlobal(); - - // Unblock - QUnit.start(); - } - ); - } - } - }, - - valid: function() { - var include, - filter = config.filter && config.filter.toLowerCase(), - module = QUnit.urlParams.module && QUnit.urlParams.module.toLowerCase(), - fullName = ( this.module.name + ": " + this.testName ).toLowerCase(); - - // Internally-generated tests are always valid - if ( this.callback && this.callback.validTest ) { - return true; - } - - if ( config.testId.length > 0 && inArray( this.testId, config.testId ) < 0 ) { - return false; - } - - if ( module && ( !this.module.name || this.module.name.toLowerCase() !== module ) ) { - return false; - } - - if ( !filter ) { - return true; - } - - include = filter.charAt( 0 ) !== "!"; - if ( !include ) { - filter = filter.slice( 1 ); - } - - // If the filter matches, we need to honour include - if ( fullName.indexOf( filter ) !== -1 ) { - return include; - } - - // Otherwise, do the opposite - return !include; - } - -}; - -// Resets the test setup. Useful for tests that modify the DOM. -/* -DEPRECATED: Use multiple tests instead of resetting inside a test. -Use testStart or testDone for custom cleanup. -This method will throw an error in 2.0, and will be removed in 2.1 -*/ -QUnit.reset = function() { - - // Return on non-browser environments - // This is necessary to not break on node tests - if ( !defined.document ) { - return; - } - - var fixture = defined.document && document.getElementById && - document.getElementById( "qunit-fixture" ); - - if ( fixture ) { - fixture.innerHTML = config.fixture; - } -}; - -QUnit.pushFailure = function() { - if ( !QUnit.config.current ) { - throw new Error( "pushFailure() assertion outside test context, in " + - sourceFromStacktrace( 2 ) ); - } - - // Gets current test obj - var currentTest = QUnit.config.current; - - return currentTest.pushFailure.apply( currentTest, arguments ); -}; - -// Based on Java's String.hashCode, a simple but not -// rigorously collision resistant hashing function -function generateHash( module, testName ) { - var hex, - i = 0, - hash = 0, - str = module + "\x1C" + testName, - len = str.length; - - for ( ; i < len; i++ ) { - hash = ( ( hash << 5 ) - hash ) + str.charCodeAt( i ); - hash |= 0; - } - - // Convert the possibly negative integer hash code into an 8 character hex string, which isn't - // strictly necessary but increases user understanding that the id is a SHA-like hash - hex = ( 0x100000000 + hash ).toString( 16 ); - if ( hex.length < 8 ) { - hex = "0000000" + hex; - } - - return hex.slice( -8 ); -} - -function synchronize( callback, last ) { - if ( QUnit.objectType( callback ) === "array" ) { - while ( callback.length ) { - synchronize( callback.shift() ); - } - return; - } - config.queue.push( callback ); - - if ( config.autorun && !config.blocking ) { - process( last ); - } -} - -function saveGlobal() { - config.pollution = []; - - if ( config.noglobals ) { - for ( var key in global ) { - if ( hasOwn.call( global, key ) ) { - - // in Opera sometimes DOM element ids show up here, ignore them - if ( /^qunit-test-output/.test( key ) ) { - continue; - } - config.pollution.push( key ); - } - } - } -} - -function checkPollution() { - var newGlobals, - deletedGlobals, - old = config.pollution; - - saveGlobal(); - - newGlobals = diff( config.pollution, old ); - if ( newGlobals.length > 0 ) { - QUnit.pushFailure( "Introduced global variable(s): " + newGlobals.join( ", " ) ); - } - - deletedGlobals = diff( old, config.pollution ); - if ( deletedGlobals.length > 0 ) { - QUnit.pushFailure( "Deleted global variable(s): " + deletedGlobals.join( ", " ) ); - } -} - -// Will be exposed as QUnit.asyncTest -function asyncTest( testName, expected, callback ) { - if ( arguments.length === 2 ) { - callback = expected; - expected = null; - } - - QUnit.test( testName, expected, callback, true ); -} - -// Will be exposed as QUnit.test -function test( testName, expected, callback, async ) { - var newTest; - - if ( arguments.length === 2 ) { - callback = expected; - expected = null; - } - - newTest = new Test({ - testName: testName, - expected: expected, - async: async, - callback: callback - }); - - newTest.queue(); -} - -// Will be exposed as QUnit.skip -function skip( testName ) { - var test = new Test({ - testName: testName, - skip: true - }); - - test.queue(); -} - -function Assert( testContext ) { - this.test = testContext; -} - -// Assert helpers -QUnit.assert = Assert.prototype = { - - // Specify the number of expected assertions to guarantee that failed test - // (no assertions are run at all) don't slip through. - expect: function( asserts ) { - if ( arguments.length === 1 ) { - this.test.expected = asserts; - } else { - return this.test.expected; - } - }, - - // Increment this Test's semaphore counter, then return a single-use function that - // decrements that counter a maximum of once. - async: function() { - var test = this.test, - popped = false; - - test.semaphore += 1; - test.usedAsync = true; - pauseProcessing(); - - return function done() { - if ( !popped ) { - test.semaphore -= 1; - popped = true; - resumeProcessing(); - } else { - test.pushFailure( "Called the callback returned from `assert.async` more than once", - sourceFromStacktrace( 2 ) ); - } - }; - }, - - // Exports test.push() to the user API - push: function( /* result, actual, expected, message, negative */ ) { - var assert = this, - currentTest = ( assert instanceof Assert && assert.test ) || QUnit.config.current; - - // Backwards compatibility fix. - // Allows the direct use of global exported assertions and QUnit.assert.* - // Although, it's use is not recommended as it can leak assertions - // to other tests from async tests, because we only get a reference to the current test, - // not exactly the test where assertion were intended to be called. - if ( !currentTest ) { - throw new Error( "assertion outside test context, in " + sourceFromStacktrace( 2 ) ); - } - - if ( currentTest.usedAsync === true && currentTest.semaphore === 0 ) { - currentTest.pushFailure( "Assertion after the final `assert.async` was resolved", - sourceFromStacktrace( 2 ) ); - - // Allow this assertion to continue running anyway... - } - - if ( !( assert instanceof Assert ) ) { - assert = currentTest.assert; - } - return assert.test.push.apply( assert.test, arguments ); - }, - - ok: function( result, message ) { - message = message || ( result ? "okay" : "failed, expected argument to be truthy, was: " + - QUnit.dump.parse( result ) ); - this.push( !!result, result, true, message ); - }, - - notOk: function( result, message ) { - message = message || ( !result ? "okay" : "failed, expected argument to be falsy, was: " + - QUnit.dump.parse( result ) ); - this.push( !result, result, false, message, true ); - }, - - equal: function( actual, expected, message ) { - /*jshint eqeqeq:false */ - this.push( expected == actual, actual, expected, message ); - }, - - notEqual: function( actual, expected, message ) { - /*jshint eqeqeq:false */ - this.push( expected != actual, actual, expected, message, true ); - }, - - propEqual: function( actual, expected, message ) { - actual = objectValues( actual ); - expected = objectValues( expected ); - this.push( QUnit.equiv( actual, expected ), actual, expected, message ); - }, - - notPropEqual: function( actual, expected, message ) { - actual = objectValues( actual ); - expected = objectValues( expected ); - this.push( !QUnit.equiv( actual, expected ), actual, expected, message, true ); - }, - - deepEqual: function( actual, expected, message ) { - this.push( QUnit.equiv( actual, expected ), actual, expected, message ); - }, - - notDeepEqual: function( actual, expected, message ) { - this.push( !QUnit.equiv( actual, expected ), actual, expected, message, true ); - }, - - strictEqual: function( actual, expected, message ) { - this.push( expected === actual, actual, expected, message ); - }, - - notStrictEqual: function( actual, expected, message ) { - this.push( expected !== actual, actual, expected, message, true ); - }, - - "throws": function( block, expected, message ) { - var actual, expectedType, - expectedOutput = expected, - ok = false, - currentTest = ( this instanceof Assert && this.test ) || QUnit.config.current; - - // 'expected' is optional unless doing string comparison - if ( message == null && typeof expected === "string" ) { - message = expected; - expected = null; - } - - currentTest.ignoreGlobalErrors = true; - try { - block.call( currentTest.testEnvironment ); - } catch (e) { - actual = e; - } - currentTest.ignoreGlobalErrors = false; - - if ( actual ) { - expectedType = QUnit.objectType( expected ); - - // we don't want to validate thrown error - if ( !expected ) { - ok = true; - expectedOutput = null; - - // expected is a regexp - } else if ( expectedType === "regexp" ) { - ok = expected.test( errorString( actual ) ); - - // expected is a string - } else if ( expectedType === "string" ) { - ok = expected === errorString( actual ); - - // expected is a constructor, maybe an Error constructor - } else if ( expectedType === "function" && actual instanceof expected ) { - ok = true; - - // expected is an Error object - } else if ( expectedType === "object" ) { - ok = actual instanceof expected.constructor && - actual.name === expected.name && - actual.message === expected.message; - - // expected is a validation function which returns true if validation passed - } else if ( expectedType === "function" && expected.call( {}, actual ) === true ) { - expectedOutput = null; - ok = true; - } - } - - currentTest.assert.push( ok, actual, expectedOutput, message ); - } -}; - -// Provide an alternative to assert.throws(), for enviroments that consider throws a reserved word -// Known to us are: Closure Compiler, Narwhal -(function() { - /*jshint sub:true */ - Assert.prototype.raises = Assert.prototype[ "throws" ]; -}()); - -function errorString( error ) { - var name, message, - resultErrorString = error.toString(); - if ( resultErrorString.substring( 0, 7 ) === "[object" ) { - name = error.name ? error.name.toString() : "Error"; - message = error.message ? error.message.toString() : ""; - if ( name && message ) { - return name + ": " + message; - } else if ( name ) { - return name; - } else if ( message ) { - return message; - } else { - return "Error"; - } - } else { - return resultErrorString; - } -} - -// Test for equality any JavaScript type. -// Author: Philippe Rathé -QUnit.equiv = (function() { - - // Call the o related callback with the given arguments. - function bindCallbacks( o, callbacks, args ) { - var prop = QUnit.objectType( o ); - if ( prop ) { - if ( QUnit.objectType( callbacks[ prop ] ) === "function" ) { - return callbacks[ prop ].apply( callbacks, args ); - } else { - return callbacks[ prop ]; // or undefined - } - } - } - - // the real equiv function - var innerEquiv, - - // stack to decide between skip/abort functions - callers = [], - - // stack to avoiding loops from circular referencing - parents = [], - parentsB = [], - - getProto = Object.getPrototypeOf || function( obj ) { - /* jshint camelcase: false, proto: true */ - return obj.__proto__; - }, - callbacks = (function() { - - // for string, boolean, number and null - function useStrictEquality( b, a ) { - - /*jshint eqeqeq:false */ - if ( b instanceof a.constructor || a instanceof b.constructor ) { - - // to catch short annotation VS 'new' annotation of a - // declaration - // e.g. var i = 1; - // var j = new Number(1); - return a == b; - } else { - return a === b; - } - } - - return { - "string": useStrictEquality, - "boolean": useStrictEquality, - "number": useStrictEquality, - "null": useStrictEquality, - "undefined": useStrictEquality, - - "nan": function( b ) { - return isNaN( b ); - }, - - "date": function( b, a ) { - return QUnit.objectType( b ) === "date" && a.valueOf() === b.valueOf(); - }, - - "regexp": function( b, a ) { - return QUnit.objectType( b ) === "regexp" && - - // the regex itself - a.source === b.source && - - // and its modifiers - a.global === b.global && - - // (gmi) ... - a.ignoreCase === b.ignoreCase && - a.multiline === b.multiline && - a.sticky === b.sticky; - }, - - // - skip when the property is a method of an instance (OOP) - // - abort otherwise, - // initial === would have catch identical references anyway - "function": function() { - var caller = callers[ callers.length - 1 ]; - return caller !== Object && typeof caller !== "undefined"; - }, - - "array": function( b, a ) { - var i, j, len, loop, aCircular, bCircular; - - // b could be an object literal here - if ( QUnit.objectType( b ) !== "array" ) { - return false; - } - - len = a.length; - if ( len !== b.length ) { - // safe and faster - return false; - } - - // track reference to avoid circular references - parents.push( a ); - parentsB.push( b ); - for ( i = 0; i < len; i++ ) { - loop = false; - for ( j = 0; j < parents.length; j++ ) { - aCircular = parents[ j ] === a[ i ]; - bCircular = parentsB[ j ] === b[ i ]; - if ( aCircular || bCircular ) { - if ( a[ i ] === b[ i ] || aCircular && bCircular ) { - loop = true; - } else { - parents.pop(); - parentsB.pop(); - return false; - } - } - } - if ( !loop && !innerEquiv( a[ i ], b[ i ] ) ) { - parents.pop(); - parentsB.pop(); - return false; - } - } - parents.pop(); - parentsB.pop(); - return true; - }, - - "set": function( b, a ) { - var aArray, bArray; - - // b could be any object here - if ( QUnit.objectType( b ) !== "set" ) { - return false; - } - - aArray = []; - a.forEach( function( v ) { - aArray.push( v ); - }); - bArray = []; - b.forEach( function( v ) { - bArray.push( v ); - }); - - return innerEquiv( bArray, aArray ); - }, - - "map": function( b, a ) { - var aArray, bArray; - - // b could be any object here - if ( QUnit.objectType( b ) !== "map" ) { - return false; - } - - aArray = []; - a.forEach( function( v, k ) { - aArray.push( [ k, v ] ); - }); - bArray = []; - b.forEach( function( v, k ) { - bArray.push( [ k, v ] ); - }); - - return innerEquiv( bArray, aArray ); - }, - - "object": function( b, a ) { - - /*jshint forin:false */ - var i, j, loop, aCircular, bCircular, - // Default to true - eq = true, - aProperties = [], - bProperties = []; - - // comparing constructors is more strict than using - // instanceof - if ( a.constructor !== b.constructor ) { - - // Allow objects with no prototype to be equivalent to - // objects with Object as their constructor. - if ( !( ( getProto( a ) === null && getProto( b ) === Object.prototype ) || - ( getProto( b ) === null && getProto( a ) === Object.prototype ) ) ) { - return false; - } - } - - // stack constructor before traversing properties - callers.push( a.constructor ); - - // track reference to avoid circular references - parents.push( a ); - parentsB.push( b ); - - // be strict: don't ensure hasOwnProperty and go deep - for ( i in a ) { - loop = false; - for ( j = 0; j < parents.length; j++ ) { - aCircular = parents[ j ] === a[ i ]; - bCircular = parentsB[ j ] === b[ i ]; - if ( aCircular || bCircular ) { - if ( a[ i ] === b[ i ] || aCircular && bCircular ) { - loop = true; - } else { - eq = false; - break; - } - } - } - aProperties.push( i ); - if ( !loop && !innerEquiv( a[ i ], b[ i ] ) ) { - eq = false; - break; - } - } - - parents.pop(); - parentsB.pop(); - callers.pop(); // unstack, we are done - - for ( i in b ) { - bProperties.push( i ); // collect b's properties - } - - // Ensures identical properties name - return eq && innerEquiv( aProperties.sort(), bProperties.sort() ); - } - }; - }()); - - innerEquiv = function() { // can take multiple arguments - var args = [].slice.apply( arguments ); - if ( args.length < 2 ) { - return true; // end transition - } - - return ( (function( a, b ) { - if ( a === b ) { - return true; // catch the most you can - } else if ( a === null || b === null || typeof a === "undefined" || - typeof b === "undefined" || - QUnit.objectType( a ) !== QUnit.objectType( b ) ) { - - // don't lose time with error prone cases - return false; - } else { - return bindCallbacks( a, callbacks, [ b, a ] ); - } - - // apply transition with (1..n) arguments - }( args[ 0 ], args[ 1 ] ) ) && - innerEquiv.apply( this, args.splice( 1, args.length - 1 ) ) ); - }; - - return innerEquiv; -}()); - -// Based on jsDump by Ariel Flesler -// http://flesler.blogspot.com/2008/05/jsdump-pretty-dump-of-any-javascript.html -QUnit.dump = (function() { - function quote( str ) { - return "\"" + str.toString().replace( /\\/g, "\\\\" ).replace( /"/g, "\\\"" ) + "\""; - } - function literal( o ) { - return o + ""; - } - function join( pre, arr, post ) { - var s = dump.separator(), - base = dump.indent(), - inner = dump.indent( 1 ); - if ( arr.join ) { - arr = arr.join( "," + s + inner ); - } - if ( !arr ) { - return pre + post; - } - return [ pre, inner + arr, base + post ].join( s ); - } - function array( arr, stack ) { - var i = arr.length, - ret = new Array( i ); - - if ( dump.maxDepth && dump.depth > dump.maxDepth ) { - return "[object Array]"; - } - - this.up(); - while ( i-- ) { - ret[ i ] = this.parse( arr[ i ], undefined, stack ); - } - this.down(); - return join( "[", ret, "]" ); - } - - var reName = /^function (\w+)/, - dump = { - - // objType is used mostly internally, you can fix a (custom) type in advance - parse: function( obj, objType, stack ) { - stack = stack || []; - var res, parser, parserType, - inStack = inArray( obj, stack ); - - if ( inStack !== -1 ) { - return "recursion(" + ( inStack - stack.length ) + ")"; - } - - objType = objType || this.typeOf( obj ); - parser = this.parsers[ objType ]; - parserType = typeof parser; - - if ( parserType === "function" ) { - stack.push( obj ); - res = parser.call( this, obj, stack ); - stack.pop(); - return res; - } - return ( parserType === "string" ) ? parser : this.parsers.error; - }, - typeOf: function( obj ) { - var type; - if ( obj === null ) { - type = "null"; - } else if ( typeof obj === "undefined" ) { - type = "undefined"; - } else if ( QUnit.is( "regexp", obj ) ) { - type = "regexp"; - } else if ( QUnit.is( "date", obj ) ) { - type = "date"; - } else if ( QUnit.is( "function", obj ) ) { - type = "function"; - } else if ( obj.setInterval !== undefined && - obj.document !== undefined && - obj.nodeType === undefined ) { - type = "window"; - } else if ( obj.nodeType === 9 ) { - type = "document"; - } else if ( obj.nodeType ) { - type = "node"; - } else if ( - - // native arrays - toString.call( obj ) === "[object Array]" || - - // NodeList objects - ( typeof obj.length === "number" && obj.item !== undefined && - ( obj.length ? obj.item( 0 ) === obj[ 0 ] : ( obj.item( 0 ) === null && - obj[ 0 ] === undefined ) ) ) - ) { - type = "array"; - } else if ( obj.constructor === Error.prototype.constructor ) { - type = "error"; - } else { - type = typeof obj; - } - return type; - }, - separator: function() { - return this.multiline ? this.HTML ? "
" : "\n" : this.HTML ? " " : " "; - }, - // extra can be a number, shortcut for increasing-calling-decreasing - indent: function( extra ) { - if ( !this.multiline ) { - return ""; - } - var chr = this.indentChar; - if ( this.HTML ) { - chr = chr.replace( /\t/g, " " ).replace( / /g, " " ); - } - return new Array( this.depth + ( extra || 0 ) ).join( chr ); - }, - up: function( a ) { - this.depth += a || 1; - }, - down: function( a ) { - this.depth -= a || 1; - }, - setParser: function( name, parser ) { - this.parsers[ name ] = parser; - }, - // The next 3 are exposed so you can use them - quote: quote, - literal: literal, - join: join, - // - depth: 1, - maxDepth: QUnit.config.maxDepth, - - // This is the list of parsers, to modify them, use dump.setParser - parsers: { - window: "[Window]", - document: "[Document]", - error: function( error ) { - return "Error(\"" + error.message + "\")"; - }, - unknown: "[Unknown]", - "null": "null", - "undefined": "undefined", - "function": function( fn ) { - var ret = "function", - - // functions never have name in IE - name = "name" in fn ? fn.name : ( reName.exec( fn ) || [] )[ 1 ]; - - if ( name ) { - ret += " " + name; - } - ret += "( "; - - ret = [ ret, dump.parse( fn, "functionArgs" ), "){" ].join( "" ); - return join( ret, dump.parse( fn, "functionCode" ), "}" ); - }, - array: array, - nodelist: array, - "arguments": array, - object: function( map, stack ) { - var keys, key, val, i, nonEnumerableProperties, - ret = []; - - if ( dump.maxDepth && dump.depth > dump.maxDepth ) { - return "[object Object]"; - } - - dump.up(); - keys = []; - for ( key in map ) { - keys.push( key ); - } - - // Some properties are not always enumerable on Error objects. - nonEnumerableProperties = [ "message", "name" ]; - for ( i in nonEnumerableProperties ) { - key = nonEnumerableProperties[ i ]; - if ( key in map && inArray( key, keys ) < 0 ) { - keys.push( key ); - } - } - keys.sort(); - for ( i = 0; i < keys.length; i++ ) { - key = keys[ i ]; - val = map[ key ]; - ret.push( dump.parse( key, "key" ) + ": " + - dump.parse( val, undefined, stack ) ); - } - dump.down(); - return join( "{", ret, "}" ); - }, - node: function( node ) { - var len, i, val, - open = dump.HTML ? "<" : "<", - close = dump.HTML ? ">" : ">", - tag = node.nodeName.toLowerCase(), - ret = open + tag, - attrs = node.attributes; - - if ( attrs ) { - for ( i = 0, len = attrs.length; i < len; i++ ) { - val = attrs[ i ].nodeValue; - - // IE6 includes all attributes in .attributes, even ones not explicitly - // set. Those have values like undefined, null, 0, false, "" or - // "inherit". - if ( val && val !== "inherit" ) { - ret += " " + attrs[ i ].nodeName + "=" + - dump.parse( val, "attribute" ); - } - } - } - ret += close; - - // Show content of TextNode or CDATASection - if ( node.nodeType === 3 || node.nodeType === 4 ) { - ret += node.nodeValue; - } - - return ret + open + "/" + tag + close; - }, - - // function calls it internally, it's the arguments part of the function - functionArgs: function( fn ) { - var args, - l = fn.length; - - if ( !l ) { - return ""; - } - - args = new Array( l ); - while ( l-- ) { - - // 97 is 'a' - args[ l ] = String.fromCharCode( 97 + l ); - } - return " " + args.join( ", " ) + " "; - }, - // object calls it internally, the key part of an item in a map - key: quote, - // function calls it internally, it's the content of the function - functionCode: "[code]", - // node calls it internally, it's an html attribute value - attribute: quote, - string: quote, - date: quote, - regexp: literal, - number: literal, - "boolean": literal - }, - // if true, entities are escaped ( <, >, \t, space and \n ) - HTML: false, - // indentation unit - indentChar: " ", - // if true, items in a collection, are separated by a \n, else just a space. - multiline: true - }; - - return dump; -}()); - -// back compat -QUnit.jsDump = QUnit.dump; - -// For browser, export only select globals -if ( defined.document ) { - - // Deprecated - // Extend assert methods to QUnit and Global scope through Backwards compatibility - (function() { - var i, - assertions = Assert.prototype; - - function applyCurrent( current ) { - return function() { - var assert = new Assert( QUnit.config.current ); - current.apply( assert, arguments ); - }; - } - - for ( i in assertions ) { - QUnit[ i ] = applyCurrent( assertions[ i ] ); - } - })(); - - (function() { - var i, l, - keys = [ - "test", - "module", - "expect", - "asyncTest", - "start", - "stop", - "ok", - "notOk", - "equal", - "notEqual", - "propEqual", - "notPropEqual", - "deepEqual", - "notDeepEqual", - "strictEqual", - "notStrictEqual", - "throws" - ]; - - for ( i = 0, l = keys.length; i < l; i++ ) { - window[ keys[ i ] ] = QUnit[ keys[ i ] ]; - } - })(); - - window.QUnit = QUnit; -} - -// For nodejs -if ( typeof module !== "undefined" && module && module.exports ) { - module.exports = QUnit; - - // For consistency with CommonJS environments' exports - module.exports.QUnit = QUnit; -} - -// For CommonJS with exports, but without module.exports, like Rhino -if ( typeof exports !== "undefined" && exports ) { - exports.QUnit = QUnit; -} - -if ( typeof define === "function" && define.amd ) { - define( function() { - return QUnit; - } ); - QUnit.config.autostart = false; -} - -/* - * This file is a modified version of google-diff-match-patch's JavaScript implementation - * (https://code.google.com/p/google-diff-match-patch/source/browse/trunk/javascript/diff_match_patch_uncompressed.js), - * modifications are licensed as more fully set forth in LICENSE.txt. - * - * The original source of google-diff-match-patch is attributable and licensed as follows: - * - * Copyright 2006 Google Inc. - * http://code.google.com/p/google-diff-match-patch/ - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * More Info: - * https://code.google.com/p/google-diff-match-patch/ - * - * Usage: QUnit.diff(expected, actual) - * - */ -QUnit.diff = ( function() { - function DiffMatchPatch() { - } - - // DIFF FUNCTIONS - - /** - * The data structure representing a diff is an array of tuples: - * [[DIFF_DELETE, 'Hello'], [DIFF_INSERT, 'Goodbye'], [DIFF_EQUAL, ' world.']] - * which means: delete 'Hello', add 'Goodbye' and keep ' world.' - */ - var DIFF_DELETE = -1, - DIFF_INSERT = 1, - DIFF_EQUAL = 0; - - /** - * Find the differences between two texts. Simplifies the problem by stripping - * any common prefix or suffix off the texts before diffing. - * @param {string} text1 Old string to be diffed. - * @param {string} text2 New string to be diffed. - * @param {boolean=} optChecklines Optional speedup flag. If present and false, - * then don't run a line-level diff first to identify the changed areas. - * Defaults to true, which does a faster, slightly less optimal diff. - * @return {!Array.} Array of diff tuples. - */ - DiffMatchPatch.prototype.DiffMain = function( text1, text2, optChecklines ) { - var deadline, checklines, commonlength, - commonprefix, commonsuffix, diffs; - - // The diff must be complete in up to 1 second. - deadline = ( new Date() ).getTime() + 1000; - - // Check for null inputs. - if ( text1 === null || text2 === null ) { - throw new Error( "Null input. (DiffMain)" ); - } - - // Check for equality (speedup). - if ( text1 === text2 ) { - if ( text1 ) { - return [ - [ DIFF_EQUAL, text1 ] - ]; - } - return []; - } - - if ( typeof optChecklines === "undefined" ) { - optChecklines = true; - } - - checklines = optChecklines; - - // Trim off common prefix (speedup). - commonlength = this.diffCommonPrefix( text1, text2 ); - commonprefix = text1.substring( 0, commonlength ); - text1 = text1.substring( commonlength ); - text2 = text2.substring( commonlength ); - - // Trim off common suffix (speedup). - commonlength = this.diffCommonSuffix( text1, text2 ); - commonsuffix = text1.substring( text1.length - commonlength ); - text1 = text1.substring( 0, text1.length - commonlength ); - text2 = text2.substring( 0, text2.length - commonlength ); - - // Compute the diff on the middle block. - diffs = this.diffCompute( text1, text2, checklines, deadline ); - - // Restore the prefix and suffix. - if ( commonprefix ) { - diffs.unshift( [ DIFF_EQUAL, commonprefix ] ); - } - if ( commonsuffix ) { - diffs.push( [ DIFF_EQUAL, commonsuffix ] ); - } - this.diffCleanupMerge( diffs ); - return diffs; - }; - - /** - * Reduce the number of edits by eliminating operationally trivial equalities. - * @param {!Array.} diffs Array of diff tuples. - */ - DiffMatchPatch.prototype.diffCleanupEfficiency = function( diffs ) { - var changes, equalities, equalitiesLength, lastequality, - pointer, preIns, preDel, postIns, postDel; - changes = false; - equalities = []; // Stack of indices where equalities are found. - equalitiesLength = 0; // Keeping our own length var is faster in JS. - /** @type {?string} */ - lastequality = null; - // Always equal to diffs[equalities[equalitiesLength - 1]][1] - pointer = 0; // Index of current position. - // Is there an insertion operation before the last equality. - preIns = false; - // Is there a deletion operation before the last equality. - preDel = false; - // Is there an insertion operation after the last equality. - postIns = false; - // Is there a deletion operation after the last equality. - postDel = false; - while ( pointer < diffs.length ) { - - // Equality found. - if ( diffs[ pointer ][ 0 ] === DIFF_EQUAL ) { - if ( diffs[ pointer ][ 1 ].length < 4 && ( postIns || postDel ) ) { - - // Candidate found. - equalities[ equalitiesLength++ ] = pointer; - preIns = postIns; - preDel = postDel; - lastequality = diffs[ pointer ][ 1 ]; - } else { - - // Not a candidate, and can never become one. - equalitiesLength = 0; - lastequality = null; - } - postIns = postDel = false; - - // An insertion or deletion. - } else { - - if ( diffs[ pointer ][ 0 ] === DIFF_DELETE ) { - postDel = true; - } else { - postIns = true; - } - - /* - * Five types to be split: - * ABXYCD - * AXCD - * ABXC - * AXCD - * ABXC - */ - if ( lastequality && ( ( preIns && preDel && postIns && postDel ) || - ( ( lastequality.length < 2 ) && - ( preIns + preDel + postIns + postDel ) === 3 ) ) ) { - - // Duplicate record. - diffs.splice( - equalities[ equalitiesLength - 1 ], - 0, - [ DIFF_DELETE, lastequality ] - ); - - // Change second copy to insert. - diffs[ equalities[ equalitiesLength - 1 ] + 1 ][ 0 ] = DIFF_INSERT; - equalitiesLength--; // Throw away the equality we just deleted; - lastequality = null; - if ( preIns && preDel ) { - // No changes made which could affect previous entry, keep going. - postIns = postDel = true; - equalitiesLength = 0; - } else { - equalitiesLength--; // Throw away the previous equality. - pointer = equalitiesLength > 0 ? equalities[ equalitiesLength - 1 ] : -1; - postIns = postDel = false; - } - changes = true; - } - } - pointer++; - } - - if ( changes ) { - this.diffCleanupMerge( diffs ); - } - }; - - /** - * Convert a diff array into a pretty HTML report. - * @param {!Array.} diffs Array of diff tuples. - * @param {integer} string to be beautified. - * @return {string} HTML representation. - */ - DiffMatchPatch.prototype.diffPrettyHtml = function( diffs ) { - var op, data, x, - html = []; - for ( x = 0; x < diffs.length; x++ ) { - op = diffs[ x ][ 0 ]; // Operation (insert, delete, equal) - data = diffs[ x ][ 1 ]; // Text of change. - switch ( op ) { - case DIFF_INSERT: - html[ x ] = "" + data + ""; - break; - case DIFF_DELETE: - html[ x ] = "" + data + ""; - break; - case DIFF_EQUAL: - html[ x ] = "" + data + ""; - break; - } - } - return html.join( "" ); - }; - - /** - * Determine the common prefix of two strings. - * @param {string} text1 First string. - * @param {string} text2 Second string. - * @return {number} The number of characters common to the start of each - * string. - */ - DiffMatchPatch.prototype.diffCommonPrefix = function( text1, text2 ) { - var pointermid, pointermax, pointermin, pointerstart; - // Quick check for common null cases. - if ( !text1 || !text2 || text1.charAt( 0 ) !== text2.charAt( 0 ) ) { - return 0; - } - // Binary search. - // Performance analysis: http://neil.fraser.name/news/2007/10/09/ - pointermin = 0; - pointermax = Math.min( text1.length, text2.length ); - pointermid = pointermax; - pointerstart = 0; - while ( pointermin < pointermid ) { - if ( text1.substring( pointerstart, pointermid ) === - text2.substring( pointerstart, pointermid ) ) { - pointermin = pointermid; - pointerstart = pointermin; - } else { - pointermax = pointermid; - } - pointermid = Math.floor( ( pointermax - pointermin ) / 2 + pointermin ); - } - return pointermid; - }; - - /** - * Determine the common suffix of two strings. - * @param {string} text1 First string. - * @param {string} text2 Second string. - * @return {number} The number of characters common to the end of each string. - */ - DiffMatchPatch.prototype.diffCommonSuffix = function( text1, text2 ) { - var pointermid, pointermax, pointermin, pointerend; - // Quick check for common null cases. - if ( !text1 || - !text2 || - text1.charAt( text1.length - 1 ) !== text2.charAt( text2.length - 1 ) ) { - return 0; - } - // Binary search. - // Performance analysis: http://neil.fraser.name/news/2007/10/09/ - pointermin = 0; - pointermax = Math.min( text1.length, text2.length ); - pointermid = pointermax; - pointerend = 0; - while ( pointermin < pointermid ) { - if ( text1.substring( text1.length - pointermid, text1.length - pointerend ) === - text2.substring( text2.length - pointermid, text2.length - pointerend ) ) { - pointermin = pointermid; - pointerend = pointermin; - } else { - pointermax = pointermid; - } - pointermid = Math.floor( ( pointermax - pointermin ) / 2 + pointermin ); - } - return pointermid; - }; - - /** - * Find the differences between two texts. Assumes that the texts do not - * have any common prefix or suffix. - * @param {string} text1 Old string to be diffed. - * @param {string} text2 New string to be diffed. - * @param {boolean} checklines Speedup flag. If false, then don't run a - * line-level diff first to identify the changed areas. - * If true, then run a faster, slightly less optimal diff. - * @param {number} deadline Time when the diff should be complete by. - * @return {!Array.} Array of diff tuples. - * @private - */ - DiffMatchPatch.prototype.diffCompute = function( text1, text2, checklines, deadline ) { - var diffs, longtext, shorttext, i, hm, - text1A, text2A, text1B, text2B, - midCommon, diffsA, diffsB; - - if ( !text1 ) { - // Just add some text (speedup). - return [ - [ DIFF_INSERT, text2 ] - ]; - } - - if ( !text2 ) { - // Just delete some text (speedup). - return [ - [ DIFF_DELETE, text1 ] - ]; - } - - longtext = text1.length > text2.length ? text1 : text2; - shorttext = text1.length > text2.length ? text2 : text1; - i = longtext.indexOf( shorttext ); - if ( i !== -1 ) { - // Shorter text is inside the longer text (speedup). - diffs = [ - [ DIFF_INSERT, longtext.substring( 0, i ) ], - [ DIFF_EQUAL, shorttext ], - [ DIFF_INSERT, longtext.substring( i + shorttext.length ) ] - ]; - // Swap insertions for deletions if diff is reversed. - if ( text1.length > text2.length ) { - diffs[ 0 ][ 0 ] = diffs[ 2 ][ 0 ] = DIFF_DELETE; - } - return diffs; - } - - if ( shorttext.length === 1 ) { - // Single character string. - // After the previous speedup, the character can't be an equality. - return [ - [ DIFF_DELETE, text1 ], - [ DIFF_INSERT, text2 ] - ]; - } - - // Check to see if the problem can be split in two. - hm = this.diffHalfMatch( text1, text2 ); - if ( hm ) { - // A half-match was found, sort out the return data. - text1A = hm[ 0 ]; - text1B = hm[ 1 ]; - text2A = hm[ 2 ]; - text2B = hm[ 3 ]; - midCommon = hm[ 4 ]; - // Send both pairs off for separate processing. - diffsA = this.DiffMain( text1A, text2A, checklines, deadline ); - diffsB = this.DiffMain( text1B, text2B, checklines, deadline ); - // Merge the results. - return diffsA.concat( [ - [ DIFF_EQUAL, midCommon ] - ], diffsB ); - } - - if ( checklines && text1.length > 100 && text2.length > 100 ) { - return this.diffLineMode( text1, text2, deadline ); - } - - return this.diffBisect( text1, text2, deadline ); - }; - - /** - * Do the two texts share a substring which is at least half the length of the - * longer text? - * This speedup can produce non-minimal diffs. - * @param {string} text1 First string. - * @param {string} text2 Second string. - * @return {Array.} Five element Array, containing the prefix of - * text1, the suffix of text1, the prefix of text2, the suffix of - * text2 and the common middle. Or null if there was no match. - * @private - */ - DiffMatchPatch.prototype.diffHalfMatch = function( text1, text2 ) { - var longtext, shorttext, dmp, - text1A, text2B, text2A, text1B, midCommon, - hm1, hm2, hm; - - longtext = text1.length > text2.length ? text1 : text2; - shorttext = text1.length > text2.length ? text2 : text1; - if ( longtext.length < 4 || shorttext.length * 2 < longtext.length ) { - return null; // Pointless. - } - dmp = this; // 'this' becomes 'window' in a closure. - - /** - * Does a substring of shorttext exist within longtext such that the substring - * is at least half the length of longtext? - * Closure, but does not reference any external variables. - * @param {string} longtext Longer string. - * @param {string} shorttext Shorter string. - * @param {number} i Start index of quarter length substring within longtext. - * @return {Array.} Five element Array, containing the prefix of - * longtext, the suffix of longtext, the prefix of shorttext, the suffix - * of shorttext and the common middle. Or null if there was no match. - * @private - */ - function diffHalfMatchI( longtext, shorttext, i ) { - var seed, j, bestCommon, prefixLength, suffixLength, - bestLongtextA, bestLongtextB, bestShorttextA, bestShorttextB; - // Start with a 1/4 length substring at position i as a seed. - seed = longtext.substring( i, i + Math.floor( longtext.length / 4 ) ); - j = -1; - bestCommon = ""; - while ( ( j = shorttext.indexOf( seed, j + 1 ) ) !== -1 ) { - prefixLength = dmp.diffCommonPrefix( longtext.substring( i ), - shorttext.substring( j ) ); - suffixLength = dmp.diffCommonSuffix( longtext.substring( 0, i ), - shorttext.substring( 0, j ) ); - if ( bestCommon.length < suffixLength + prefixLength ) { - bestCommon = shorttext.substring( j - suffixLength, j ) + - shorttext.substring( j, j + prefixLength ); - bestLongtextA = longtext.substring( 0, i - suffixLength ); - bestLongtextB = longtext.substring( i + prefixLength ); - bestShorttextA = shorttext.substring( 0, j - suffixLength ); - bestShorttextB = shorttext.substring( j + prefixLength ); - } - } - if ( bestCommon.length * 2 >= longtext.length ) { - return [ bestLongtextA, bestLongtextB, - bestShorttextA, bestShorttextB, bestCommon - ]; - } else { - return null; - } - } - - // First check if the second quarter is the seed for a half-match. - hm1 = diffHalfMatchI( longtext, shorttext, - Math.ceil( longtext.length / 4 ) ); - // Check again based on the third quarter. - hm2 = diffHalfMatchI( longtext, shorttext, - Math.ceil( longtext.length / 2 ) ); - if ( !hm1 && !hm2 ) { - return null; - } else if ( !hm2 ) { - hm = hm1; - } else if ( !hm1 ) { - hm = hm2; - } else { - // Both matched. Select the longest. - hm = hm1[ 4 ].length > hm2[ 4 ].length ? hm1 : hm2; - } - - // A half-match was found, sort out the return data. - text1A, text1B, text2A, text2B; - if ( text1.length > text2.length ) { - text1A = hm[ 0 ]; - text1B = hm[ 1 ]; - text2A = hm[ 2 ]; - text2B = hm[ 3 ]; - } else { - text2A = hm[ 0 ]; - text2B = hm[ 1 ]; - text1A = hm[ 2 ]; - text1B = hm[ 3 ]; - } - midCommon = hm[ 4 ]; - return [ text1A, text1B, text2A, text2B, midCommon ]; - }; - - /** - * Do a quick line-level diff on both strings, then rediff the parts for - * greater accuracy. - * This speedup can produce non-minimal diffs. - * @param {string} text1 Old string to be diffed. - * @param {string} text2 New string to be diffed. - * @param {number} deadline Time when the diff should be complete by. - * @return {!Array.} Array of diff tuples. - * @private - */ - DiffMatchPatch.prototype.diffLineMode = function( text1, text2, deadline ) { - var a, diffs, linearray, pointer, countInsert, - countDelete, textInsert, textDelete, j; - // Scan the text on a line-by-line basis first. - a = this.diffLinesToChars( text1, text2 ); - text1 = a.chars1; - text2 = a.chars2; - linearray = a.lineArray; - - diffs = this.DiffMain( text1, text2, false, deadline ); - - // Convert the diff back to original text. - this.diffCharsToLines( diffs, linearray ); - // Eliminate freak matches (e.g. blank lines) - this.diffCleanupSemantic( diffs ); - - // Rediff any replacement blocks, this time character-by-character. - // Add a dummy entry at the end. - diffs.push( [ DIFF_EQUAL, "" ] ); - pointer = 0; - countDelete = 0; - countInsert = 0; - textDelete = ""; - textInsert = ""; - while ( pointer < diffs.length ) { - switch ( diffs[ pointer ][ 0 ] ) { - case DIFF_INSERT: - countInsert++; - textInsert += diffs[ pointer ][ 1 ]; - break; - case DIFF_DELETE: - countDelete++; - textDelete += diffs[ pointer ][ 1 ]; - break; - case DIFF_EQUAL: - // Upon reaching an equality, check for prior redundancies. - if ( countDelete >= 1 && countInsert >= 1 ) { - // Delete the offending records and add the merged ones. - diffs.splice( pointer - countDelete - countInsert, - countDelete + countInsert ); - pointer = pointer - countDelete - countInsert; - a = this.DiffMain( textDelete, textInsert, false, deadline ); - for ( j = a.length - 1; j >= 0; j-- ) { - diffs.splice( pointer, 0, a[ j ] ); - } - pointer = pointer + a.length; - } - countInsert = 0; - countDelete = 0; - textDelete = ""; - textInsert = ""; - break; - } - pointer++; - } - diffs.pop(); // Remove the dummy entry at the end. - - return diffs; - }; - - /** - * Find the 'middle snake' of a diff, split the problem in two - * and return the recursively constructed diff. - * See Myers 1986 paper: An O(ND) Difference Algorithm and Its Variations. - * @param {string} text1 Old string to be diffed. - * @param {string} text2 New string to be diffed. - * @param {number} deadline Time at which to bail if not yet complete. - * @return {!Array.} Array of diff tuples. - * @private - */ - DiffMatchPatch.prototype.diffBisect = function( text1, text2, deadline ) { - var text1Length, text2Length, maxD, vOffset, vLength, - v1, v2, x, delta, front, k1start, k1end, k2start, - k2end, k2Offset, k1Offset, x1, x2, y1, y2, d, k1, k2; - // Cache the text lengths to prevent multiple calls. - text1Length = text1.length; - text2Length = text2.length; - maxD = Math.ceil( ( text1Length + text2Length ) / 2 ); - vOffset = maxD; - vLength = 2 * maxD; - v1 = new Array( vLength ); - v2 = new Array( vLength ); - // Setting all elements to -1 is faster in Chrome & Firefox than mixing - // integers and undefined. - for ( x = 0; x < vLength; x++ ) { - v1[ x ] = -1; - v2[ x ] = -1; - } - v1[ vOffset + 1 ] = 0; - v2[ vOffset + 1 ] = 0; - delta = text1Length - text2Length; - // If the total number of characters is odd, then the front path will collide - // with the reverse path. - front = ( delta % 2 !== 0 ); - // Offsets for start and end of k loop. - // Prevents mapping of space beyond the grid. - k1start = 0; - k1end = 0; - k2start = 0; - k2end = 0; - for ( d = 0; d < maxD; d++ ) { - // Bail out if deadline is reached. - if ( ( new Date() ).getTime() > deadline ) { - break; - } - - // Walk the front path one step. - for ( k1 = -d + k1start; k1 <= d - k1end; k1 += 2 ) { - k1Offset = vOffset + k1; - if ( k1 === -d || ( k1 !== d && v1[ k1Offset - 1 ] < v1[ k1Offset + 1 ] ) ) { - x1 = v1[ k1Offset + 1 ]; - } else { - x1 = v1[ k1Offset - 1 ] + 1; - } - y1 = x1 - k1; - while ( x1 < text1Length && y1 < text2Length && - text1.charAt( x1 ) === text2.charAt( y1 ) ) { - x1++; - y1++; - } - v1[ k1Offset ] = x1; - if ( x1 > text1Length ) { - // Ran off the right of the graph. - k1end += 2; - } else if ( y1 > text2Length ) { - // Ran off the bottom of the graph. - k1start += 2; - } else if ( front ) { - k2Offset = vOffset + delta - k1; - if ( k2Offset >= 0 && k2Offset < vLength && v2[ k2Offset ] !== -1 ) { - // Mirror x2 onto top-left coordinate system. - x2 = text1Length - v2[ k2Offset ]; - if ( x1 >= x2 ) { - // Overlap detected. - return this.diffBisectSplit( text1, text2, x1, y1, deadline ); - } - } - } - } - - // Walk the reverse path one step. - for ( k2 = -d + k2start; k2 <= d - k2end; k2 += 2 ) { - k2Offset = vOffset + k2; - if ( k2 === -d || ( k2 !== d && v2[ k2Offset - 1 ] < v2[ k2Offset + 1 ] ) ) { - x2 = v2[ k2Offset + 1 ]; - } else { - x2 = v2[ k2Offset - 1 ] + 1; - } - y2 = x2 - k2; - while ( x2 < text1Length && y2 < text2Length && - text1.charAt( text1Length - x2 - 1 ) === - text2.charAt( text2Length - y2 - 1 ) ) { - x2++; - y2++; - } - v2[ k2Offset ] = x2; - if ( x2 > text1Length ) { - // Ran off the left of the graph. - k2end += 2; - } else if ( y2 > text2Length ) { - // Ran off the top of the graph. - k2start += 2; - } else if ( !front ) { - k1Offset = vOffset + delta - k2; - if ( k1Offset >= 0 && k1Offset < vLength && v1[ k1Offset ] !== -1 ) { - x1 = v1[ k1Offset ]; - y1 = vOffset + x1 - k1Offset; - // Mirror x2 onto top-left coordinate system. - x2 = text1Length - x2; - if ( x1 >= x2 ) { - // Overlap detected. - return this.diffBisectSplit( text1, text2, x1, y1, deadline ); - } - } - } - } - } - // Diff took too long and hit the deadline or - // number of diffs equals number of characters, no commonality at all. - return [ - [ DIFF_DELETE, text1 ], - [ DIFF_INSERT, text2 ] - ]; - }; - - /** - * Given the location of the 'middle snake', split the diff in two parts - * and recurse. - * @param {string} text1 Old string to be diffed. - * @param {string} text2 New string to be diffed. - * @param {number} x Index of split point in text1. - * @param {number} y Index of split point in text2. - * @param {number} deadline Time at which to bail if not yet complete. - * @return {!Array.} Array of diff tuples. - * @private - */ - DiffMatchPatch.prototype.diffBisectSplit = function( text1, text2, x, y, deadline ) { - var text1a, text1b, text2a, text2b, diffs, diffsb; - text1a = text1.substring( 0, x ); - text2a = text2.substring( 0, y ); - text1b = text1.substring( x ); - text2b = text2.substring( y ); - - // Compute both diffs serially. - diffs = this.DiffMain( text1a, text2a, false, deadline ); - diffsb = this.DiffMain( text1b, text2b, false, deadline ); - - return diffs.concat( diffsb ); - }; - - /** - * Reduce the number of edits by eliminating semantically trivial equalities. - * @param {!Array.} diffs Array of diff tuples. - */ - DiffMatchPatch.prototype.diffCleanupSemantic = function( diffs ) { - var changes, equalities, equalitiesLength, lastequality, - pointer, lengthInsertions2, lengthDeletions2, lengthInsertions1, - lengthDeletions1, deletion, insertion, overlapLength1, overlapLength2; - changes = false; - equalities = []; // Stack of indices where equalities are found. - equalitiesLength = 0; // Keeping our own length var is faster in JS. - /** @type {?string} */ - lastequality = null; - // Always equal to diffs[equalities[equalitiesLength - 1]][1] - pointer = 0; // Index of current position. - // Number of characters that changed prior to the equality. - lengthInsertions1 = 0; - lengthDeletions1 = 0; - // Number of characters that changed after the equality. - lengthInsertions2 = 0; - lengthDeletions2 = 0; - while ( pointer < diffs.length ) { - if ( diffs[ pointer ][ 0 ] === DIFF_EQUAL ) { // Equality found. - equalities[ equalitiesLength++ ] = pointer; - lengthInsertions1 = lengthInsertions2; - lengthDeletions1 = lengthDeletions2; - lengthInsertions2 = 0; - lengthDeletions2 = 0; - lastequality = diffs[ pointer ][ 1 ]; - } else { // An insertion or deletion. - if ( diffs[ pointer ][ 0 ] === DIFF_INSERT ) { - lengthInsertions2 += diffs[ pointer ][ 1 ].length; - } else { - lengthDeletions2 += diffs[ pointer ][ 1 ].length; - } - // Eliminate an equality that is smaller or equal to the edits on both - // sides of it. - if ( lastequality && ( lastequality.length <= - Math.max( lengthInsertions1, lengthDeletions1 ) ) && - ( lastequality.length <= Math.max( lengthInsertions2, - lengthDeletions2 ) ) ) { - - // Duplicate record. - diffs.splice( - equalities[ equalitiesLength - 1 ], - 0, - [ DIFF_DELETE, lastequality ] - ); - - // Change second copy to insert. - diffs[ equalities[ equalitiesLength - 1 ] + 1 ][ 0 ] = DIFF_INSERT; - - // Throw away the equality we just deleted. - equalitiesLength--; - - // Throw away the previous equality (it needs to be reevaluated). - equalitiesLength--; - pointer = equalitiesLength > 0 ? equalities[ equalitiesLength - 1 ] : -1; - - // Reset the counters. - lengthInsertions1 = 0; - lengthDeletions1 = 0; - lengthInsertions2 = 0; - lengthDeletions2 = 0; - lastequality = null; - changes = true; - } - } - pointer++; - } - - // Normalize the diff. - if ( changes ) { - this.diffCleanupMerge( diffs ); - } - - // Find any overlaps between deletions and insertions. - // e.g: abcxxxxxxdef - // -> abcxxxdef - // e.g: xxxabcdefxxx - // -> defxxxabc - // Only extract an overlap if it is as big as the edit ahead or behind it. - pointer = 1; - while ( pointer < diffs.length ) { - if ( diffs[ pointer - 1 ][ 0 ] === DIFF_DELETE && - diffs[ pointer ][ 0 ] === DIFF_INSERT ) { - deletion = diffs[ pointer - 1 ][ 1 ]; - insertion = diffs[ pointer ][ 1 ]; - overlapLength1 = this.diffCommonOverlap( deletion, insertion ); - overlapLength2 = this.diffCommonOverlap( insertion, deletion ); - if ( overlapLength1 >= overlapLength2 ) { - if ( overlapLength1 >= deletion.length / 2 || - overlapLength1 >= insertion.length / 2 ) { - // Overlap found. Insert an equality and trim the surrounding edits. - diffs.splice( - pointer, - 0, - [ DIFF_EQUAL, insertion.substring( 0, overlapLength1 ) ] - ); - diffs[ pointer - 1 ][ 1 ] = - deletion.substring( 0, deletion.length - overlapLength1 ); - diffs[ pointer + 1 ][ 1 ] = insertion.substring( overlapLength1 ); - pointer++; - } - } else { - if ( overlapLength2 >= deletion.length / 2 || - overlapLength2 >= insertion.length / 2 ) { - - // Reverse overlap found. - // Insert an equality and swap and trim the surrounding edits. - diffs.splice( - pointer, - 0, - [ DIFF_EQUAL, deletion.substring( 0, overlapLength2 ) ] - ); - - diffs[ pointer - 1 ][ 0 ] = DIFF_INSERT; - diffs[ pointer - 1 ][ 1 ] = - insertion.substring( 0, insertion.length - overlapLength2 ); - diffs[ pointer + 1 ][ 0 ] = DIFF_DELETE; - diffs[ pointer + 1 ][ 1 ] = - deletion.substring( overlapLength2 ); - pointer++; - } - } - pointer++; - } - pointer++; - } - }; - - /** - * Determine if the suffix of one string is the prefix of another. - * @param {string} text1 First string. - * @param {string} text2 Second string. - * @return {number} The number of characters common to the end of the first - * string and the start of the second string. - * @private - */ - DiffMatchPatch.prototype.diffCommonOverlap = function( text1, text2 ) { - var text1Length, text2Length, textLength, - best, length, pattern, found; - // Cache the text lengths to prevent multiple calls. - text1Length = text1.length; - text2Length = text2.length; - // Eliminate the null case. - if ( text1Length === 0 || text2Length === 0 ) { - return 0; - } - // Truncate the longer string. - if ( text1Length > text2Length ) { - text1 = text1.substring( text1Length - text2Length ); - } else if ( text1Length < text2Length ) { - text2 = text2.substring( 0, text1Length ); - } - textLength = Math.min( text1Length, text2Length ); - // Quick check for the worst case. - if ( text1 === text2 ) { - return textLength; - } - - // Start by looking for a single character match - // and increase length until no match is found. - // Performance analysis: http://neil.fraser.name/news/2010/11/04/ - best = 0; - length = 1; - while ( true ) { - pattern = text1.substring( textLength - length ); - found = text2.indexOf( pattern ); - if ( found === -1 ) { - return best; - } - length += found; - if ( found === 0 || text1.substring( textLength - length ) === - text2.substring( 0, length ) ) { - best = length; - length++; - } - } - }; - - /** - * Split two texts into an array of strings. Reduce the texts to a string of - * hashes where each Unicode character represents one line. - * @param {string} text1 First string. - * @param {string} text2 Second string. - * @return {{chars1: string, chars2: string, lineArray: !Array.}} - * An object containing the encoded text1, the encoded text2 and - * the array of unique strings. - * The zeroth element of the array of unique strings is intentionally blank. - * @private - */ - DiffMatchPatch.prototype.diffLinesToChars = function( text1, text2 ) { - var lineArray, lineHash, chars1, chars2; - lineArray = []; // e.g. lineArray[4] === 'Hello\n' - lineHash = {}; // e.g. lineHash['Hello\n'] === 4 - - // '\x00' is a valid character, but various debuggers don't like it. - // So we'll insert a junk entry to avoid generating a null character. - lineArray[ 0 ] = ""; - - /** - * Split a text into an array of strings. Reduce the texts to a string of - * hashes where each Unicode character represents one line. - * Modifies linearray and linehash through being a closure. - * @param {string} text String to encode. - * @return {string} Encoded string. - * @private - */ - function diffLinesToCharsMunge( text ) { - var chars, lineStart, lineEnd, lineArrayLength, line; - chars = ""; - // Walk the text, pulling out a substring for each line. - // text.split('\n') would would temporarily double our memory footprint. - // Modifying text would create many large strings to garbage collect. - lineStart = 0; - lineEnd = -1; - // Keeping our own length variable is faster than looking it up. - lineArrayLength = lineArray.length; - while ( lineEnd < text.length - 1 ) { - lineEnd = text.indexOf( "\n", lineStart ); - if ( lineEnd === -1 ) { - lineEnd = text.length - 1; - } - line = text.substring( lineStart, lineEnd + 1 ); - lineStart = lineEnd + 1; - - if ( lineHash.hasOwnProperty ? lineHash.hasOwnProperty( line ) : - ( lineHash[ line ] !== undefined ) ) { - chars += String.fromCharCode( lineHash[ line ] ); - } else { - chars += String.fromCharCode( lineArrayLength ); - lineHash[ line ] = lineArrayLength; - lineArray[ lineArrayLength++ ] = line; - } - } - return chars; - } - - chars1 = diffLinesToCharsMunge( text1 ); - chars2 = diffLinesToCharsMunge( text2 ); - return { - chars1: chars1, - chars2: chars2, - lineArray: lineArray - }; - }; - - /** - * Rehydrate the text in a diff from a string of line hashes to real lines of - * text. - * @param {!Array.} diffs Array of diff tuples. - * @param {!Array.} lineArray Array of unique strings. - * @private - */ - DiffMatchPatch.prototype.diffCharsToLines = function( diffs, lineArray ) { - var x, chars, text, y; - for ( x = 0; x < diffs.length; x++ ) { - chars = diffs[ x ][ 1 ]; - text = []; - for ( y = 0; y < chars.length; y++ ) { - text[ y ] = lineArray[ chars.charCodeAt( y ) ]; - } - diffs[ x ][ 1 ] = text.join( "" ); - } - }; - - /** - * Reorder and merge like edit sections. Merge equalities. - * Any edit section can move as long as it doesn't cross an equality. - * @param {!Array.} diffs Array of diff tuples. - */ - DiffMatchPatch.prototype.diffCleanupMerge = function( diffs ) { - var pointer, countDelete, countInsert, textInsert, textDelete, - commonlength, changes, diffPointer, position; - diffs.push( [ DIFF_EQUAL, "" ] ); // Add a dummy entry at the end. - pointer = 0; - countDelete = 0; - countInsert = 0; - textDelete = ""; - textInsert = ""; - commonlength; - while ( pointer < diffs.length ) { - switch ( diffs[ pointer ][ 0 ] ) { - case DIFF_INSERT: - countInsert++; - textInsert += diffs[ pointer ][ 1 ]; - pointer++; - break; - case DIFF_DELETE: - countDelete++; - textDelete += diffs[ pointer ][ 1 ]; - pointer++; - break; - case DIFF_EQUAL: - // Upon reaching an equality, check for prior redundancies. - if ( countDelete + countInsert > 1 ) { - if ( countDelete !== 0 && countInsert !== 0 ) { - // Factor out any common prefixies. - commonlength = this.diffCommonPrefix( textInsert, textDelete ); - if ( commonlength !== 0 ) { - if ( ( pointer - countDelete - countInsert ) > 0 && - diffs[ pointer - countDelete - countInsert - 1 ][ 0 ] === - DIFF_EQUAL ) { - diffs[ pointer - countDelete - countInsert - 1 ][ 1 ] += - textInsert.substring( 0, commonlength ); - } else { - diffs.splice( 0, 0, [ DIFF_EQUAL, - textInsert.substring( 0, commonlength ) - ] ); - pointer++; - } - textInsert = textInsert.substring( commonlength ); - textDelete = textDelete.substring( commonlength ); - } - // Factor out any common suffixies. - commonlength = this.diffCommonSuffix( textInsert, textDelete ); - if ( commonlength !== 0 ) { - diffs[ pointer ][ 1 ] = textInsert.substring( textInsert.length - - commonlength ) + diffs[ pointer ][ 1 ]; - textInsert = textInsert.substring( 0, textInsert.length - - commonlength ); - textDelete = textDelete.substring( 0, textDelete.length - - commonlength ); - } - } - // Delete the offending records and add the merged ones. - if ( countDelete === 0 ) { - diffs.splice( pointer - countInsert, - countDelete + countInsert, [ DIFF_INSERT, textInsert ] ); - } else if ( countInsert === 0 ) { - diffs.splice( pointer - countDelete, - countDelete + countInsert, [ DIFF_DELETE, textDelete ] ); - } else { - diffs.splice( - pointer - countDelete - countInsert, - countDelete + countInsert, - [ DIFF_DELETE, textDelete ], [ DIFF_INSERT, textInsert ] - ); - } - pointer = pointer - countDelete - countInsert + - ( countDelete ? 1 : 0 ) + ( countInsert ? 1 : 0 ) + 1; - } else if ( pointer !== 0 && diffs[ pointer - 1 ][ 0 ] === DIFF_EQUAL ) { - - // Merge this equality with the previous one. - diffs[ pointer - 1 ][ 1 ] += diffs[ pointer ][ 1 ]; - diffs.splice( pointer, 1 ); - } else { - pointer++; - } - countInsert = 0; - countDelete = 0; - textDelete = ""; - textInsert = ""; - break; - } - } - if ( diffs[ diffs.length - 1 ][ 1 ] === "" ) { - diffs.pop(); // Remove the dummy entry at the end. - } - - // Second pass: look for single edits surrounded on both sides by equalities - // which can be shifted sideways to eliminate an equality. - // e.g: ABAC -> ABAC - changes = false; - pointer = 1; - - // Intentionally ignore the first and last element (don't need checking). - while ( pointer < diffs.length - 1 ) { - if ( diffs[ pointer - 1 ][ 0 ] === DIFF_EQUAL && - diffs[ pointer + 1 ][ 0 ] === DIFF_EQUAL ) { - - diffPointer = diffs[ pointer ][ 1 ]; - position = diffPointer.substring( - diffPointer.length - diffs[ pointer - 1 ][ 1 ].length - ); - - // This is a single edit surrounded by equalities. - if ( position === diffs[ pointer - 1 ][ 1 ] ) { - - // Shift the edit over the previous equality. - diffs[ pointer ][ 1 ] = diffs[ pointer - 1 ][ 1 ] + - diffs[ pointer ][ 1 ].substring( 0, diffs[ pointer ][ 1 ].length - - diffs[ pointer - 1 ][ 1 ].length ); - diffs[ pointer + 1 ][ 1 ] = - diffs[ pointer - 1 ][ 1 ] + diffs[ pointer + 1 ][ 1 ]; - diffs.splice( pointer - 1, 1 ); - changes = true; - } else if ( diffPointer.substring( 0, diffs[ pointer + 1 ][ 1 ].length ) === - diffs[ pointer + 1 ][ 1 ] ) { - - // Shift the edit over the next equality. - diffs[ pointer - 1 ][ 1 ] += diffs[ pointer + 1 ][ 1 ]; - diffs[ pointer ][ 1 ] = - diffs[ pointer ][ 1 ].substring( diffs[ pointer + 1 ][ 1 ].length ) + - diffs[ pointer + 1 ][ 1 ]; - diffs.splice( pointer + 1, 1 ); - changes = true; - } - } - pointer++; - } - // If shifts were made, the diff needs reordering and another shift sweep. - if ( changes ) { - this.diffCleanupMerge( diffs ); - } - }; - - return function( o, n ) { - var diff, output, text; - diff = new DiffMatchPatch(); - output = diff.DiffMain( o, n ); - diff.diffCleanupEfficiency( output ); - text = diff.diffPrettyHtml( output ); - - return text; - }; -}() ); - -// Get a reference to the global object, like window in browsers -}( (function() { - return this; -})() )); - -(function() { - -// Don't load the HTML Reporter on non-Browser environments -if ( typeof window === "undefined" || !window.document ) { - return; -} - -// Deprecated QUnit.init - Ref #530 -// Re-initialize the configuration options -QUnit.init = function() { - var tests, banner, result, qunit, - config = QUnit.config; - - config.stats = { all: 0, bad: 0 }; - config.moduleStats = { all: 0, bad: 0 }; - config.started = 0; - config.updateRate = 1000; - config.blocking = false; - config.autostart = true; - config.autorun = false; - config.filter = ""; - config.queue = []; - - // Return on non-browser environments - // This is necessary to not break on node tests - if ( typeof window === "undefined" ) { - return; - } - - qunit = id( "qunit" ); - if ( qunit ) { - qunit.innerHTML = - "

" + escapeText( document.title ) + "

" + - "

" + - "
" + - "

" + - "
    "; - } - - tests = id( "qunit-tests" ); - banner = id( "qunit-banner" ); - result = id( "qunit-testresult" ); - - if ( tests ) { - tests.innerHTML = ""; - } - - if ( banner ) { - banner.className = ""; - } - - if ( result ) { - result.parentNode.removeChild( result ); - } - - if ( tests ) { - result = document.createElement( "p" ); - result.id = "qunit-testresult"; - result.className = "result"; - tests.parentNode.insertBefore( result, tests ); - result.innerHTML = "Running...
     "; - } -}; - -var config = QUnit.config, - hasOwn = Object.prototype.hasOwnProperty, - defined = { - document: window.document !== undefined, - sessionStorage: (function() { - var x = "qunit-test-string"; - try { - sessionStorage.setItem( x, x ); - sessionStorage.removeItem( x ); - return true; - } catch ( e ) { - return false; - } - }()) - }, - modulesList = []; - -/** -* Escape text for attribute or text content. -*/ -function escapeText( s ) { - if ( !s ) { - return ""; - } - s = s + ""; - - // Both single quotes and double quotes (for attributes) - return s.replace( /['"<>&]/g, function( s ) { - switch ( s ) { - case "'": - return "'"; - case "\"": - return """; - case "<": - return "<"; - case ">": - return ">"; - case "&": - return "&"; - } - }); -} - -/** - * @param {HTMLElement} elem - * @param {string} type - * @param {Function} fn - */ -function addEvent( elem, type, fn ) { - if ( elem.addEventListener ) { - - // Standards-based browsers - elem.addEventListener( type, fn, false ); - } else if ( elem.attachEvent ) { - - // support: IE <9 - elem.attachEvent( "on" + type, function() { - var event = window.event; - if ( !event.target ) { - event.target = event.srcElement || document; - } - - fn.call( elem, event ); - }); - } -} - -/** - * @param {Array|NodeList} elems - * @param {string} type - * @param {Function} fn - */ -function addEvents( elems, type, fn ) { - var i = elems.length; - while ( i-- ) { - addEvent( elems[ i ], type, fn ); - } -} - -function hasClass( elem, name ) { - return ( " " + elem.className + " " ).indexOf( " " + name + " " ) >= 0; -} - -function addClass( elem, name ) { - if ( !hasClass( elem, name ) ) { - elem.className += ( elem.className ? " " : "" ) + name; - } -} - -function toggleClass( elem, name ) { - if ( hasClass( elem, name ) ) { - removeClass( elem, name ); - } else { - addClass( elem, name ); - } -} - -function removeClass( elem, name ) { - var set = " " + elem.className + " "; - - // Class name may appear multiple times - while ( set.indexOf( " " + name + " " ) >= 0 ) { - set = set.replace( " " + name + " ", " " ); - } - - // trim for prettiness - elem.className = typeof set.trim === "function" ? set.trim() : set.replace( /^\s+|\s+$/g, "" ); -} - -function id( name ) { - return defined.document && document.getElementById && document.getElementById( name ); -} - -function getUrlConfigHtml() { - var i, j, val, - escaped, escapedTooltip, - selection = false, - len = config.urlConfig.length, - urlConfigHtml = ""; - - for ( i = 0; i < len; i++ ) { - val = config.urlConfig[ i ]; - if ( typeof val === "string" ) { - val = { - id: val, - label: val - }; - } - - escaped = escapeText( val.id ); - escapedTooltip = escapeText( val.tooltip ); - - if ( config[ val.id ] === undefined ) { - config[ val.id ] = QUnit.urlParams[ val.id ]; - } - - if ( !val.value || typeof val.value === "string" ) { - urlConfigHtml += ""; - } else { - urlConfigHtml += ""; - } - } - - return urlConfigHtml; -} - -// Handle "click" events on toolbar checkboxes and "change" for select menus. -// Updates the URL with the new state of `config.urlConfig` values. -function toolbarChanged() { - var updatedUrl, value, - field = this, - params = {}; - - // Detect if field is a select menu or a checkbox - if ( "selectedIndex" in field ) { - value = field.options[ field.selectedIndex ].value || undefined; - } else { - value = field.checked ? ( field.defaultValue || true ) : undefined; - } - - params[ field.name ] = value; - updatedUrl = setUrl( params ); - - if ( "hidepassed" === field.name && "replaceState" in window.history ) { - config[ field.name ] = value || false; - if ( value ) { - addClass( id( "qunit-tests" ), "hidepass" ); - } else { - removeClass( id( "qunit-tests" ), "hidepass" ); - } - - // It is not necessary to refresh the whole page - window.history.replaceState( null, "", updatedUrl ); - } else { - window.location = updatedUrl; - } -} - -function setUrl( params ) { - var key, - querystring = "?"; - - params = QUnit.extend( QUnit.extend( {}, QUnit.urlParams ), params ); - - for ( key in params ) { - if ( hasOwn.call( params, key ) ) { - if ( params[ key ] === undefined ) { - continue; - } - querystring += encodeURIComponent( key ); - if ( params[ key ] !== true ) { - querystring += "=" + encodeURIComponent( params[ key ] ); - } - querystring += "&"; - } - } - return location.protocol + "//" + location.host + - location.pathname + querystring.slice( 0, -1 ); -} - -function applyUrlParams() { - var selectedModule, - modulesList = id( "qunit-modulefilter" ), - filter = id( "qunit-filter-input" ).value; - - selectedModule = modulesList ? - decodeURIComponent( modulesList.options[ modulesList.selectedIndex ].value ) : - undefined; - - window.location = setUrl({ - module: ( selectedModule === "" ) ? undefined : selectedModule, - filter: ( filter === "" ) ? undefined : filter, - - // Remove testId filter - testId: undefined - }); -} - -function toolbarUrlConfigContainer() { - var urlConfigContainer = document.createElement( "span" ); - - urlConfigContainer.innerHTML = getUrlConfigHtml(); - addClass( urlConfigContainer, "qunit-url-config" ); - - // For oldIE support: - // * Add handlers to the individual elements instead of the container - // * Use "click" instead of "change" for checkboxes - addEvents( urlConfigContainer.getElementsByTagName( "input" ), "click", toolbarChanged ); - addEvents( urlConfigContainer.getElementsByTagName( "select" ), "change", toolbarChanged ); - - return urlConfigContainer; -} - -function toolbarLooseFilter() { - var filter = document.createElement( "form" ), - label = document.createElement( "label" ), - input = document.createElement( "input" ), - button = document.createElement( "button" ); - - addClass( filter, "qunit-filter" ); - - label.innerHTML = "Filter: "; - - input.type = "text"; - input.value = config.filter || ""; - input.name = "filter"; - input.id = "qunit-filter-input"; - - button.innerHTML = "Go"; - - label.appendChild( input ); - - filter.appendChild( label ); - filter.appendChild( button ); - addEvent( filter, "submit", function( ev ) { - applyUrlParams(); - - if ( ev && ev.preventDefault ) { - ev.preventDefault(); - } - - return false; - }); - - return filter; -} - -function toolbarModuleFilterHtml() { - var i, - moduleFilterHtml = ""; - - if ( !modulesList.length ) { - return false; - } - - modulesList.sort(function( a, b ) { - return a.localeCompare( b ); - }); - - moduleFilterHtml += "" + - ""; - - return moduleFilterHtml; -} - -function toolbarModuleFilter() { - var toolbar = id( "qunit-testrunner-toolbar" ), - moduleFilter = document.createElement( "span" ), - moduleFilterHtml = toolbarModuleFilterHtml(); - - if ( !toolbar || !moduleFilterHtml ) { - return false; - } - - moduleFilter.setAttribute( "id", "qunit-modulefilter-container" ); - moduleFilter.innerHTML = moduleFilterHtml; - - addEvent( moduleFilter.lastChild, "change", applyUrlParams ); - - toolbar.appendChild( moduleFilter ); -} - -function appendToolbar() { - var toolbar = id( "qunit-testrunner-toolbar" ); - - if ( toolbar ) { - toolbar.appendChild( toolbarUrlConfigContainer() ); - toolbar.appendChild( toolbarLooseFilter() ); - } -} - -function appendHeader() { - var header = id( "qunit-header" ); - - if ( header ) { - header.innerHTML = "" + header.innerHTML + " "; - } -} - -function appendBanner() { - var banner = id( "qunit-banner" ); - - if ( banner ) { - banner.className = ""; - } -} - -function appendTestResults() { - var tests = id( "qunit-tests" ), - result = id( "qunit-testresult" ); - - if ( result ) { - result.parentNode.removeChild( result ); - } - - if ( tests ) { - tests.innerHTML = ""; - result = document.createElement( "p" ); - result.id = "qunit-testresult"; - result.className = "result"; - tests.parentNode.insertBefore( result, tests ); - result.innerHTML = "Running...
     "; - } -} - -function storeFixture() { - var fixture = id( "qunit-fixture" ); - if ( fixture ) { - config.fixture = fixture.innerHTML; - } -} - -function appendUserAgent() { - var userAgent = id( "qunit-userAgent" ); - - if ( userAgent ) { - userAgent.innerHTML = ""; - userAgent.appendChild( - document.createTextNode( - "QUnit " + QUnit.version + "; " + navigator.userAgent - ) - ); - } -} - -function appendTestsList( modules ) { - var i, l, x, z, test, moduleObj; - - for ( i = 0, l = modules.length; i < l; i++ ) { - moduleObj = modules[ i ]; - - if ( moduleObj.name ) { - modulesList.push( moduleObj.name ); - } - - for ( x = 0, z = moduleObj.tests.length; x < z; x++ ) { - test = moduleObj.tests[ x ]; - - appendTest( test.name, test.testId, moduleObj.name ); - } - } -} - -function appendTest( name, testId, moduleName ) { - var title, rerunTrigger, testBlock, assertList, - tests = id( "qunit-tests" ); - - if ( !tests ) { - return; - } - - title = document.createElement( "strong" ); - title.innerHTML = getNameHtml( name, moduleName ); - - rerunTrigger = document.createElement( "a" ); - rerunTrigger.innerHTML = "Rerun"; - rerunTrigger.href = setUrl({ testId: testId }); - - testBlock = document.createElement( "li" ); - testBlock.appendChild( title ); - testBlock.appendChild( rerunTrigger ); - testBlock.id = "qunit-test-output-" + testId; - - assertList = document.createElement( "ol" ); - assertList.className = "qunit-assert-list"; - - testBlock.appendChild( assertList ); - - tests.appendChild( testBlock ); -} - -// HTML Reporter initialization and load -QUnit.begin(function( details ) { - var qunit = id( "qunit" ); - - // Fixture is the only one necessary to run without the #qunit element - storeFixture(); - - if ( qunit ) { - qunit.innerHTML = - "

    " + escapeText( document.title ) + "

    " + - "

    " + - "
    " + - "

    " + - "
      "; - } - - appendHeader(); - appendBanner(); - appendTestResults(); - appendUserAgent(); - appendToolbar(); - appendTestsList( details.modules ); - toolbarModuleFilter(); - - if ( qunit && config.hidepassed ) { - addClass( qunit.lastChild, "hidepass" ); - } -}); - -QUnit.done(function( details ) { - var i, key, - banner = id( "qunit-banner" ), - tests = id( "qunit-tests" ), - html = [ - "Tests completed in ", - details.runtime, - " milliseconds.
      ", - "", - details.passed, - " assertions of ", - details.total, - " passed, ", - details.failed, - " failed." - ].join( "" ); - - if ( banner ) { - banner.className = details.failed ? "qunit-fail" : "qunit-pass"; - } - - if ( tests ) { - id( "qunit-testresult" ).innerHTML = html; - } - - if ( config.altertitle && defined.document && document.title ) { - - // show ✖ for good, ✔ for bad suite result in title - // use escape sequences in case file gets loaded with non-utf-8-charset - document.title = [ - ( details.failed ? "\u2716" : "\u2714" ), - document.title.replace( /^[\u2714\u2716] /i, "" ) - ].join( " " ); - } - - // clear own sessionStorage items if all tests passed - if ( config.reorder && defined.sessionStorage && details.failed === 0 ) { - for ( i = 0; i < sessionStorage.length; i++ ) { - key = sessionStorage.key( i++ ); - if ( key.indexOf( "qunit-test-" ) === 0 ) { - sessionStorage.removeItem( key ); - } - } - } - - // scroll back to top to show results - if ( config.scrolltop && window.scrollTo ) { - window.scrollTo( 0, 0 ); - } -}); - -function getNameHtml( name, module ) { - var nameHtml = ""; - - if ( module ) { - nameHtml = "" + escapeText( module ) + ": "; - } - - nameHtml += "" + escapeText( name ) + ""; - - return nameHtml; -} - -QUnit.testStart(function( details ) { - var running, testBlock, bad; - - testBlock = id( "qunit-test-output-" + details.testId ); - if ( testBlock ) { - testBlock.className = "running"; - } else { - - // Report later registered tests - appendTest( details.name, details.testId, details.module ); - } - - running = id( "qunit-testresult" ); - if ( running ) { - bad = QUnit.config.reorder && defined.sessionStorage && - +sessionStorage.getItem( "qunit-test-" + details.module + "-" + details.name ); - - running.innerHTML = ( bad ? - "Rerunning previously failed test:
      " : - "Running:
      " ) + - getNameHtml( details.name, details.module ); - } - -}); - -function stripHtml( string ) { - // strip tags, html entity and whitespaces - return string.replace(/<\/?[^>]+(>|$)/g, "").replace(/\"/g, "").replace(/\s+/g, ""); -} - -QUnit.log(function( details ) { - var assertList, assertLi, - message, expected, actual, diff, - showDiff = false, - testItem = id( "qunit-test-output-" + details.testId ); - - if ( !testItem ) { - return; - } - - message = escapeText( details.message ) || ( details.result ? "okay" : "failed" ); - message = "" + message + ""; - message += "@ " + details.runtime + " ms"; - - // pushFailure doesn't provide details.expected - // when it calls, it's implicit to also not show expected and diff stuff - // Also, we need to check details.expected existence, as it can exist and be undefined - if ( !details.result && hasOwn.call( details, "expected" ) ) { - if ( details.negative ) { - expected = escapeText( "NOT " + QUnit.dump.parse( details.expected ) ); - } else { - expected = escapeText( QUnit.dump.parse( details.expected ) ); - } - - actual = escapeText( QUnit.dump.parse( details.actual ) ); - message += ""; - - if ( actual !== expected ) { - - message += ""; - - // Don't show diff if actual or expected are booleans - if ( !( /^(true|false)$/.test( actual ) ) && - !( /^(true|false)$/.test( expected ) ) ) { - diff = QUnit.diff( expected, actual ); - showDiff = stripHtml( diff ).length !== - stripHtml( expected ).length + - stripHtml( actual ).length; - } - - // Don't show diff if expected and actual are totally different - if ( showDiff ) { - message += ""; - } - } else if ( expected.indexOf( "[object Array]" ) !== -1 || - expected.indexOf( "[object Object]" ) !== -1 ) { - message += ""; - } - - if ( details.source ) { - message += ""; - } - - message += "
      Expected:
      " +
      -			expected +
      -			"
      Result:
      " +
      -				actual + "
      Diff:
      " +
      -					diff + "
      Message: " + - "Diff suppressed as the depth of object is more than current max depth (" + - QUnit.config.maxDepth + ").

      Hint: Use QUnit.dump.maxDepth to " + - " run with a higher max depth or " + - "Rerun without max depth.

      Source:
      " +
      -				escapeText( details.source ) + "
      "; - - // this occours when pushFailure is set and we have an extracted stack trace - } else if ( !details.result && details.source ) { - message += "" + - "" + - "
      Source:
      " +
      -			escapeText( details.source ) + "
      "; - } - - assertList = testItem.getElementsByTagName( "ol" )[ 0 ]; - - assertLi = document.createElement( "li" ); - assertLi.className = details.result ? "pass" : "fail"; - assertLi.innerHTML = message; - assertList.appendChild( assertLi ); -}); - -QUnit.testDone(function( details ) { - var testTitle, time, testItem, assertList, - good, bad, testCounts, skipped, sourceName, - tests = id( "qunit-tests" ); - - if ( !tests ) { - return; - } - - testItem = id( "qunit-test-output-" + details.testId ); - - assertList = testItem.getElementsByTagName( "ol" )[ 0 ]; - - good = details.passed; - bad = details.failed; - - // store result when possible - if ( config.reorder && defined.sessionStorage ) { - if ( bad ) { - sessionStorage.setItem( "qunit-test-" + details.module + "-" + details.name, bad ); - } else { - sessionStorage.removeItem( "qunit-test-" + details.module + "-" + details.name ); - } - } - - if ( bad === 0 ) { - addClass( assertList, "qunit-collapsed" ); - } - - // testItem.firstChild is the test name - testTitle = testItem.firstChild; - - testCounts = bad ? - "" + bad + ", " + "" + good + ", " : - ""; - - testTitle.innerHTML += " (" + testCounts + - details.assertions.length + ")"; - - if ( details.skipped ) { - testItem.className = "skipped"; - skipped = document.createElement( "em" ); - skipped.className = "qunit-skipped-label"; - skipped.innerHTML = "skipped"; - testItem.insertBefore( skipped, testTitle ); - } else { - addEvent( testTitle, "click", function() { - toggleClass( assertList, "qunit-collapsed" ); - }); - - testItem.className = bad ? "fail" : "pass"; - - time = document.createElement( "span" ); - time.className = "runtime"; - time.innerHTML = details.runtime + " ms"; - testItem.insertBefore( time, assertList ); - } - - // Show the source of the test when showing assertions - if ( details.source ) { - sourceName = document.createElement( "p" ); - sourceName.innerHTML = "Source: " + details.source; - addClass( sourceName, "qunit-source" ); - if ( bad === 0 ) { - addClass( sourceName, "qunit-collapsed" ); - } - addEvent( testTitle, "click", function() { - toggleClass( sourceName, "qunit-collapsed" ); - }); - testItem.appendChild( sourceName ); - } -}); - -if ( defined.document ) { - - // Avoid readyState issue with phantomjs - // Ref: #818 - var notPhantom = ( function( p ) { - return !( p && p.version && p.version.major > 0 ); - } )( window.phantom ); - - if ( notPhantom && document.readyState === "complete" ) { - QUnit.load(); - } else { - addEvent( window, "load", QUnit.load ); - } -} else { - config.pageLoaded = true; - config.autorun = true; -} - -})(); diff --git a/PlayFabTestingExample/index.html b/PlayFabTestingExample/index.html index 1e983a09..a60aec41 100644 --- a/PlayFabTestingExample/index.html +++ b/PlayFabTestingExample/index.html @@ -9,11 +9,23 @@
      - + - + + + + + + + + + + + + + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabAddonApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabAddonApi.js new file mode 100644 index 00000000..24cba57f --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabAddonApi.js @@ -0,0 +1,371 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.AddonApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + ConfigurePSNEventStreams: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/ConfigurePSNEventStreams", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdatePSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdatePSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateOrUpdateTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/CreateOrUpdateTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeletePSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeletePSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/DeleteTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetApple", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFacebook: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetFacebook", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFacebookInstantGames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetFacebookInstantGames", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetGoogle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetGoogle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetKongregate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetNintendo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetNintendo", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetPSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetPSN", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetSteam: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetSteam", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetToxMod: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetToxMod", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Addon/GetTwitch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabAddonSDK = PlayFab.AddonApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabAdminApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabAdminApi.js index 4206df24..b543d7be 100644 --- a/PlayFabTestingExample/src/PlayFab/PlayFabAdminApi.js +++ b/PlayFabTestingExample/src/PlayFab/PlayFabAdminApi.js @@ -6,655 +6,734 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" } + }, - xhr.onerror = function () { - if (callback == null) - return; + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); + if (!authValue) throw authError; } - - xhr.send(requestBody); + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.AdminApi = { - - GetPolicy: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPolicy", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - UpdatePolicy: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdatePolicy", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AbortTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AbortTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - BanUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/BanUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddLocalizedNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddLocalizedNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserAccountInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserAccountInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddPlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddPlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeAllBansForUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeAllBansForUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/AddVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + BanUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/BanUsers", request, "X-SecretKey", callback, customData, extraHeaders); }, - SendAccountRecoveryEmail: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SendAccountRecoveryEmail", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CheckLimitedEditionItemAvailability: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CheckLimitedEditionItemAvailability", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateActionsOnPlayersInSegmentTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateActionsOnPlayersInSegmentTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserTitleDisplayName: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserTitleDisplayName", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateCloudScriptTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateCloudScriptTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreatePlayerStatisticDefinition: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreatePlayerStatisticDefinition", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateInsightsScheduledScalingTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateInsightsScheduledScalingTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateIPBan", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetDataReport: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetDataReport", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticDefinitions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerStatisticDefinitions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreatePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreatePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerStatisticVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreatePlayerStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreatePlayerStatisticDefinition", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/CreateSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteContent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteContent", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMasterPlayerAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMasterPlayerAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMasterPlayerEventData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMasterPlayerEventData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteMembershipSubscription: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteMembershipSubscription", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - IncrementPlayerStatisticVersion: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/IncrementPlayerStatisticVersion", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayer", request, "X-SecretKey", callback, customData, extraHeaders); }, - RefundPurchase: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RefundPurchase", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetUserStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetUserStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeletePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResolvePurchaseDispute: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResolvePurchaseDispute", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdatePlayerStatisticDefinition: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdatePlayerStatisticDefinition", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteStore: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteStore", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTitle", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteTitleDataOverride: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/DeleteTitleDataOverride", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportMasterPlayerData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ExportMasterPlayerData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportPlayersInSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ExportPlayersInSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetActionsOnPlayersInSegmentTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetActionsOnPlayersInSegmentTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddNews: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddNews", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetAllSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteStore: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteStore", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptRevision: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptRevision", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptTaskInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptTaskInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCloudScriptVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetCloudScriptVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetContentList", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentUploadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetContentUploadUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetDataReport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetDataReport", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetIPBansForIP: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetIPBansForIP", request, "X-SecretKey", callback, customData, extraHeaders); }, - ListVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ListVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetIPBansForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetIPBansForTitle", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveVirtualCurrencyTypes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemoveVirtualCurrencyTypes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayedTitleList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayedTitleList", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerCustomProperty", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerIdFromAuthToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerIdFromAuthToken", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerProfile", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetupPushNotification: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetupPushNotification", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSharedSecrets: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerSharedSecrets", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerStatisticDefinitions", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerStatisticVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateStoreItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateStoreItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPlayerTags", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetUserInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GrantItemsToUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeInventoryItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RevokeInventoryItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentExport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegmentExport", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SubtractUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentPlayerCount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegmentPlayerCount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetMatchmakerGameInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetMatchmakerGameInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetMatchmakerGameModes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetMatchmakerGameModes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyMatchmakerGameModes: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ModifyMatchmakerGameModes", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTaskInstances: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTaskInstances", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTasks: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTasks", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetServerBuildInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetServerBuildInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserAccountInfo", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetServerBuildUploadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetServerBuildUploadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserData", request, "X-SecretKey", callback, customData, extraHeaders); }, - ListServerBuilds: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ListServerBuilds", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserInventory", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ModifyServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveServerBuild: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemoveServerBuild", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GetUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/GrantItemsToUsers", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + IncrementLimitedEditionItemAvailability: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/IncrementLimitedEditionItemAvailability", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptRevision: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + IncrementPlayerStatisticVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/IncrementPlayerStatisticVersion", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptRevision", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ListOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListPlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ListVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ListVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublishedRevision: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RefundPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RefundPurchase", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/SetPublishedRevision", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemovePlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RemovePlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCloudScript: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemoveVirtualCurrencyTypes: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RemoveVirtualCurrencyTypes", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateCloudScript", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ResetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteContent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ResetPassword: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetPassword", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteContent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ResetUserStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResetUserStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentList: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ResolvePurchaseDispute: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ResolvePurchaseDispute", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetContentList", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeAllBansForUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeAllBansForUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentUploadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetContentUploadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeInventoryItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeInventoryItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - ResetCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeInventoryItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/ResetCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RevokeIPBan", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddPlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RunTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/RunTask", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AddPlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SendAccountRecoveryEmail", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllActionGroups: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetAllActionGroups", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetMembershipOverride: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetMembershipOverride", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPlayerSecret", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetAllSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetPublishedRevision: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPublishedRevision", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayersInSegment: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayersInSegment", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetTitleDataAndOverrides: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleDataAndOverrides", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetPlayerTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetupPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SetupPushNotification", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemovePlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/SubtractUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RemovePlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateBans", request, "X-SecretKey", callback, customData, extraHeaders); }, - AbortTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/AbortTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateCloudScript", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateActionsOnPlayersInSegmentTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateIPBan: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateIPBan", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreateActionsOnPlayersInSegmentTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateOpenIdConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateOpenIdConnection", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateCloudScriptTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/CreateCloudScriptTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePlayerSharedSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerSharedSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePlayerStatisticDefinition", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/DeleteTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdatePolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetActionsOnPlayersInSegmentTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetActionsOnPlayersInSegmentTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCloudScriptTaskInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetCloudScriptTaskInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateTask", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTaskInstances: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTaskInstances", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTasks: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/GetTasks", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RunTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/RunTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateTask: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserTitleDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/UpdateUserTitleDisplayName", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Admin/UpdateTask", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ValidateApiPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Admin/ValidateApiPolicy", request, "X-SecretKey", callback, customData, extraHeaders); }, + }; var PlayFabAdminSDK = PlayFab.AdminApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabAuthenticationApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabAuthenticationApi.js new file mode 100644 index 00000000..8ac1c155 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabAuthenticationApi.js @@ -0,0 +1,278 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.AuthenticationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AuthenticateGameServerWithCustomId: function (request, callback, customData, extraHeaders) { + var overloadCallback = function (result, error) { + if (result != null && result.data.EntityToken != null && result.data.EntityToken.EntityToken != null) + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/GameServerIdentity/AuthenticateGameServerWithCustomId", request, "X-EntityToken", overloadCallback, customData, extraHeaders); + }, + + Delete: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/GameServerIdentity/Delete", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityToken: function (request, callback, customData, extraHeaders) { + var authKey = null; var authValue = null; + if (!authKey && PlayFab._internalSettings.sessionTicket) { var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey="X-Authorization"); authKey = authInfo.authKey, authValue = authInfo.authValue; } + if (!authKey && PlayFab.settings.developerSecretKey) { var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey="X-SecretKey"); authKey = authInfo.authKey, authValue = authInfo.authValue; } + var overloadCallback = function (result, error) { + if (result != null && result.data.EntityToken != null) + PlayFab._internalSettings.entityToken = result.data.EntityToken; + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/Authentication/GetEntityToken", request, authKey, overloadCallback, customData, extraHeaders); + }, + + ValidateEntityToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Authentication/ValidateEntityToken", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabAuthenticationSDK = PlayFab.AuthenticationApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabClientApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabClientApi.js index f36d32f8..f66af485 100644 --- a/PlayFabTestingExample/src/PlayFab/PlayFabClientApi.js +++ b/PlayFabTestingExample/src/PlayFab/PlayFabClientApi.js @@ -6,996 +6,1375 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, - xhr.onerror = function () { - if (callback == null) - return; + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - xhr.send(requestBody); + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.ClientApi = { IsClientLoggedIn: function () { return PlayFab._internalSettings.sessionTicket != null && PlayFab._internalSettings.sessionTicket.length > 0; }, - - GetPhotonAuthenticationToken: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPhotonAuthenticationToken", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - GetWindowsHelloChallenge: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetWindowsHelloChallenge", request, null, null, callback); + AcceptTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AcceptTrade", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkWindowsHello: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkWindowsHello", request, null, null, callback); + AddFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddFriend", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithAndroidDeviceID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithAndroidDeviceID", request, null, null, overloadCallback); + AddGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddGenericID", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithCustomID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithCustomID", request, null, null, overloadCallback); + AddOrUpdateContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddOrUpdateContactEmail", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithEmailAddress: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithEmailAddress", request, null, null, overloadCallback); + AddSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddSharedGroupMembers", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithFacebook: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithFacebook", request, null, null, overloadCallback); + AddUsernamePassword: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddUsernamePassword", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithGameCenter: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithGameCenter", request, null, null, overloadCallback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AddUserVirtualCurrency", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithGoogleAccount: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithGoogleAccount", request, null, null, overloadCallback); + AndroidDevicePushNotificationRegistration: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AndroidDevicePushNotificationRegistration", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithIOSDeviceID: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithIOSDeviceID", request, null, null, overloadCallback); + AttributeInstall: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/AttributeInstall", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithKongregate: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithKongregate", request, null, null, overloadCallback); + CancelTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/CancelTrade", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithPlayFab: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithPlayFab", request, null, null, overloadCallback); + ConfirmPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConfirmPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithSteam: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithSteam", request, null, null, overloadCallback); + ConsumeItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeItem", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithTwitch: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithTwitch", request, null, null, overloadCallback); + ConsumeMicrosoftStoreEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeMicrosoftStoreEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - LoginWithWindowsHello: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LoginWithWindowsHello", request, null, null, overloadCallback); + ConsumePS5Entitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumePS5Entitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterPlayFabUser: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterPlayFabUser", request, null, null, overloadCallback); + ConsumePSNEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumePSNEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterWithWindowsHello: function (request, callback) { - request.TitleId = PlayFab.settings.titleId != null ? PlayFab.settings.titleId : request.TitleId; if (request.TitleId == null) throw "Must be have PlayFab.settings.titleId set to call this method"; - - var overloadCallback = function (result, error) { - if (result != null && result.data.SessionTicket != null) { - PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; - PlayFab.ClientApi._MultiStepClientLogin(result.data.SettingsForUser.NeedsAttribution); - } - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterWithWindowsHello", request, null, null, overloadCallback); + ConsumeXboxEntitlements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ConsumeXboxEntitlements", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkWindowsHello: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkWindowsHello", request, null, null, callback); + CreateSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/CreateSharedGroup", request, "X-Authorization", callback, customData, extraHeaders); }, - AddGenericID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddGenericID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/DeletePlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); }, - AddUsernamePassword: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddUsernamePassword", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ExecuteCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ExecuteCloudScript", request, "X-Authorization", callback, customData, extraHeaders); }, - GetAccountInfo: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetAccountInfo", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAccountInfo", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerCombinedInfo: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerCombinedInfo", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAdPlacements: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAdPlacements", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromFacebookIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromFacebookIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetAllUsersCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetAllUsersCharacters", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGameCenterIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGameCenterIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCatalogItems", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGenericIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGenericIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromGoogleIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromGoogleIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterInventory", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromKongregateIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromKongregateIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromSteamIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromSteamIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayFabIDsFromTwitchIDs: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayFabIDsFromTwitchIDs", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetCharacterStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkAndroidDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkAndroidDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetContentDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetContentDownloadUrl", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkCustomID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkCustomID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkFacebookAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkFacebookAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendLeaderboardAroundPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendLeaderboardAroundPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkGameCenterAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkGameCenterAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetFriendsList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetFriendsList", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkGoogleAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkGoogleAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboard", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkIOSDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkIOSDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardAroundCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardAroundCharacter", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkKongregate: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkKongregate", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardAroundPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardAroundPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkSteamAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkSteamAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetLeaderboardForUserCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetLeaderboardForUserCharacters", request, "X-Authorization", callback, customData, extraHeaders); }, - LinkTwitch: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/LinkTwitch", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPaymentToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPaymentToken", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveGenericID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveGenericID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPhotonAuthenticationToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPhotonAuthenticationToken", request, "X-Authorization", callback, customData, extraHeaders); }, - ReportPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ReportPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerCombinedInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerCombinedInfo", request, "X-Authorization", callback, customData, extraHeaders); }, - SendAccountRecoveryEmail: function (request, callback) { - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SendAccountRecoveryEmail", request, null, null, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerCustomProperty", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkAndroidDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkAndroidDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerProfile", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkCustomID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkCustomID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerSegments", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkFacebookAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkFacebookAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkGameCenterAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkGameCenterAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerStatisticVersions", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkGoogleAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkGoogleAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerTags", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkIOSDeviceID: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkIOSDeviceID", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayerTrades: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayerTrades", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkKongregate: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkKongregate", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromBattleNetAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromBattleNetAccountIds", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkSteamAccount: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkSteamAccount", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromFacebookIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromFacebookIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlinkTwitch: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlinkTwitch", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromFacebookInstantGamesIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromFacebookInstantGamesIds", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateAvatarUrl: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateAvatarUrl", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGameCenterIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGameCenterIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserTitleDisplayName: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserTitleDisplayName", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGenericIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGenericIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGoogleIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGoogleIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendLeaderboardAroundPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendLeaderboardAroundPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromGooglePlayGamesPlayerIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromGooglePlayGamesPlayerIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromKongregateIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromKongregateIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardAroundPlayer: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardAroundPlayer", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromNintendoServiceAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromNintendoServiceAccountIds", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromNintendoSwitchDeviceIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromNintendoSwitchDeviceIds", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerStatisticVersions", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromOpenIdSubjectIdentifiers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromOpenIdSubjectIdentifiers", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromPSNAccountIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromPSNAccountIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromPSNOnlineIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromPSNOnlineIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserPublisherReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromSteamIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromSteamIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromSteamNames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromSteamNames", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdatePlayerStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdatePlayerStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromTwitchIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromTwitchIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPlayFabIDsFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPlayFabIDsFromXboxLiveIDs", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateUserPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPublisherData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCatalogItems", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPublisherData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetSharedGroupData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetStoreItems: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetStoreItems", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetStoreItems", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTime: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTime", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTime: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTime", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTitleData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitleData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTitleNews: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTitleNews", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitleNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitleNews", request, "X-Authorization", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddUserVirtualCurrency", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTitlePublicKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTitlePublicKey", request, null, callback, customData, extraHeaders); }, - ConfirmPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ConfirmPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetTradeStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetTradeStatus", request, "X-Authorization", callback, customData, extraHeaders); }, - ConsumeItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ConsumeItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterInventory: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterInventory", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserInventory", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserPublisherData", request, "X-Authorization", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetUserInventory", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserPublisherReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - PayForPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/PayForPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GetUserReadOnlyData", request, "X-Authorization", callback, customData, extraHeaders); }, - PurchaseItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/PurchaseItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + GrantCharacterToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/GrantCharacterToUser", request, "X-Authorization", callback, customData, extraHeaders); }, - RedeemCoupon: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RedeemCoupon", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkAndroidDeviceID", request, "X-Authorization", callback, customData, extraHeaders); }, - StartPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkApple", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/StartPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkBattleNetAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkCustomID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SubtractUserVirtualCurrency", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkFacebookAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlockContainerInstance: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkFacebookInstantGamesId", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlockContainerInstance", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGameCenterAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UnlockContainerItem: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkGoogleAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGoogleAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UnlockContainerItem", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkGooglePlayGamesServicesAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkGooglePlayGamesServicesAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - AddFriend: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkIOSDeviceID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddFriend", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkKongregate", request, "X-Authorization", callback, customData, extraHeaders); }, - GetFriendsList: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkNintendoServiceAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetFriendsList", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkNintendoSwitchDeviceId", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveFriend: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkOpenIdConnect: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkOpenIdConnect", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveFriend", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkPSNAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - SetFriendTags: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkSteamAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkSteamAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/SetFriendTags", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LinkTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkTwitch", request, "X-Authorization", callback, customData, extraHeaders); }, - RegisterForIOSPushNotification: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LinkXboxAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RegisterForIOSPushNotification", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ListPlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); }, - RestoreIOSPurchases: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithAndroidDeviceID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithAndroidDeviceID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RestoreIOSPurchases", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithApple: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithApple", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - ValidateIOSReceipt: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithBattleNet: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithBattleNet", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateIOSReceipt", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithCustomID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithCustomID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - GetCurrentGames: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithEmailAddress: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithEmailAddress", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCurrentGames", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithFacebook: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithFacebook", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - GetGameServerRegions: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithFacebookInstantGamesId", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetGameServerRegions", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithGameCenter: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGameCenter", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - Matchmake: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithGoogleAccount: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGoogleAccount", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/Matchmake", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithGooglePlayGamesServices: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithGooglePlayGamesServices", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - StartGame: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithIOSDeviceID: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithIOSDeviceID", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/StartGame", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithKongregate: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithKongregate", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - AndroidDevicePushNotificationRegistration: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithNintendoServiceAccount", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AndroidDevicePushNotificationRegistration", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithNintendoSwitchDeviceId", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - ValidateGooglePlayPurchase: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithOpenIdConnect: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithOpenIdConnect", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateGooglePlayPurchase", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithPlayFab: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithPlayFab", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WriteCharacterEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithPSN: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithPSN", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WriteCharacterEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithSteam: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithSteam", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WritePlayerEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + LoginWithTwitch: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithTwitch", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WritePlayerEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + LoginWithXbox: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + PlayFab._internalSettings.ExecuteRequestWrapper("/Client/LoginWithXbox", request, null, overloadCallback, customData, extraHeaders); + // Return a Promise so that multiple asynchronous calls to this method can be handled simultaneously with Promise.all() + return new Promise(function(resolve){resolve(authenticationContext);}); }, - WriteTitleEvent: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + OpenTrade: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/OpenTrade", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/WriteTitleEvent", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + PayForPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/PayForPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - AddSharedGroupMembers: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + PurchaseItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/PurchaseItem", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AddSharedGroupMembers", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RedeemCoupon: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RedeemCoupon", request, "X-Authorization", callback, customData, extraHeaders); }, - CreateSharedGroup: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RefreshPSNAuthToken: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RefreshPSNAuthToken", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/CreateSharedGroup", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RegisterForIOSPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RegisterForIOSPushNotification", request, "X-Authorization", callback, customData, extraHeaders); }, - GetSharedGroupData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RegisterPlayFabUser: function (request, callback, customData, extraHeaders) { + request.TitleId = PlayFab.settings.titleId ? PlayFab.settings.titleId : request.TitleId; if (!request.TitleId) throw PlayFab._internalSettings.errorTitleId; + // PlayFab._internalSettings.authenticationContext can be modified by other asynchronous login attempts + // Deep-copy the authenticationContext here to safely update it + var authenticationContext = JSON.parse(JSON.stringify(PlayFab._internalSettings.authenticationContext)); + var overloadCallback = function (result, error) { + if (result != null) { + if(result.data.SessionTicket != null) { + PlayFab._internalSettings.sessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken != null) { + PlayFab._internalSettings.entityToken = result.data.EntityToken.EntityToken; + } + // Apply the updates for the AuthenticationContext returned to the client + authenticationContext = PlayFab._internalSettings.UpdateAuthenticationContext(authenticationContext, result); + } + if (callback != null && typeof (callback) === "function") + callback(result, error); + }; + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RegisterPlayFabUser", request, null, overloadCallback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetSharedGroupData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RemoveContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveContactEmail", request, "X-Authorization", callback, customData, extraHeaders); }, - RemoveSharedGroupMembers: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RemoveFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveFriend", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/RemoveSharedGroupMembers", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RemoveGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveGenericID", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateSharedGroupData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RemoveSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RemoveSharedGroupMembers", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateSharedGroupData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ReportAdActivity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportAdActivity", request, "X-Authorization", callback, customData, extraHeaders); }, - ExecuteCloudScript: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ReportDeviceInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportDeviceInfo", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ExecuteCloudScript", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ReportPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ReportPlayer", request, "X-Authorization", callback, customData, extraHeaders); }, - GetContentDownloadUrl: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + RestoreIOSPurchases: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RestoreIOSPurchases", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetContentDownloadUrl", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + RewardAdActivity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/RewardAdActivity", request, "X-Authorization", callback, customData, extraHeaders); }, - GetAllUsersCharacters: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SendAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SendAccountRecoveryEmail", request, null, callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetAllUsersCharacters", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + SetFriendTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SetFriendTags", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterLeaderboard: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SetPlayerSecret", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterLeaderboard", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + StartPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/StartPurchase", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/SubtractUserVirtualCurrency", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkAndroidDeviceID", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardAroundCharacter: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkApple", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardAroundCharacter", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkBattleNetAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GetLeaderboardForUserCharacters: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkCustomID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetLeaderboardForUserCharacters", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkFacebookAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GrantCharacterToUser: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkFacebookInstantGamesId", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GrantCharacterToUser", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGameCenterAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateCharacterStatistics: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkGoogleAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGoogleAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateCharacterStatistics", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkGooglePlayGamesServicesAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkGooglePlayGamesServicesAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkIOSDeviceID", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkKongregate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkKongregate", request, "X-Authorization", callback, customData, extraHeaders); }, - GetCharacterReadOnlyData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkNintendoServiceAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetCharacterReadOnlyData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkNintendoSwitchDeviceId", request, "X-Authorization", callback, customData, extraHeaders); }, - UpdateCharacterData: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkOpenIdConnect: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkOpenIdConnect", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/UpdateCharacterData", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkPSNAccount", request, "X-Authorization", callback, customData, extraHeaders); }, - ValidateAmazonIAPReceipt: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkSteamAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkSteamAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateAmazonIAPReceipt", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlinkTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkTwitch", request, "X-Authorization", callback, customData, extraHeaders); }, - AcceptTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlinkXboxAccount", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AcceptTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UnlockContainerInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlockContainerInstance", request, "X-Authorization", callback, customData, extraHeaders); }, - CancelTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UnlockContainerItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UnlockContainerItem", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/CancelTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateAvatarUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateAvatarUrl", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerTrades: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateCharacterData", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerTrades", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateCharacterStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - GetTradeStatus: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdatePlayerCustomProperties", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetTradeStatus", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdatePlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdatePlayerStatistics", request, "X-Authorization", callback, customData, extraHeaders); }, - OpenTrade: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateSharedGroupData", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/OpenTrade", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserData", request, "X-Authorization", callback, customData, extraHeaders); }, - AttributeInstall: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserPublisherData", request, "X-Authorization", callback, customData, extraHeaders); + }, - var overloadCallback = function (result, error) { - // Modify advertisingIdType: Prevents us from sending the id multiple times, and allows automated tests to determine id was sent successfully - PlayFab.settings.advertisingIdType += "_Successful"; + UpdateUserTitleDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/UpdateUserTitleDisplayName", request, "X-Authorization", callback, customData, extraHeaders); + }, - if (callback != null && typeof (callback) == "function") - callback(result, error); - }; - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/AttributeInstall", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, overloadCallback); + ValidateAmazonIAPReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateAmazonIAPReceipt", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ValidateGooglePlayPurchase: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateGooglePlayPurchase", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerSegments", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + ValidateIOSReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateIOSReceipt", request, "X-Authorization", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab._internalSettings.sessionTicket == null) throw "Must be logged in to call this method"; + ValidateWindowsStoreReceipt: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/ValidateWindowsStoreReceipt", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/GetPlayerTags", request, "X-Authorization", PlayFab._internalSettings.sessionTicket, callback); + WriteCharacterEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WriteCharacterEvent", request, "X-Authorization", callback, customData, extraHeaders); }, - ValidateWindowsStoreReceipt: function (request, callback) { + WritePlayerEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WritePlayerEvent", request, "X-Authorization", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Client/ValidateWindowsStoreReceipt", request, null, null, callback); + WriteTitleEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Client/WriteTitleEvent", request, "X-Authorization", callback, customData, extraHeaders); }, - _MultiStepClientLogin: function (needsAttribution) { - if (needsAttribution && !PlayFab.settings.disableAdvertising && PlayFab.settings.advertisingIdType !== null && PlayFab.settings.advertisingIdValue !== null) { - var request = {}; - if (PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_IDFA) - request.Idfa = PlayFab.settings.advertisingIdValue; - else if (PlayFab.settings.advertisingIdType === PlayFab.settings.AD_TYPE_ANDROID_ID) - request.Adid = PlayFab.settings.advertisingIdValue; - else - return; - PlayFab.ClientApi.AttributeInstall(request, null); - } - } }; var PlayFabClientSDK = PlayFab.ClientApi; + +PlayFab.RegisterWithPhaser = function() { + if ( typeof Phaser === "undefined" || typeof Phaser.Plugin === "undefined" ) + return; + + Phaser.Plugin.PlayFab = function (game, parent) { + Phaser.Plugin.call(this, game, parent); + }; + Phaser.Plugin.PlayFab.prototype = Object.create(Phaser.Plugin.prototype); + Phaser.Plugin.PlayFab.prototype.constructor = Phaser.Plugin.PlayFab; + Phaser.Plugin.PlayFab.prototype.PlayFab = PlayFab; + Phaser.Plugin.PlayFab.prototype.settings = PlayFab.settings; + Phaser.Plugin.PlayFab.prototype.ClientApi = PlayFab.ClientApi; +}; +PlayFab.RegisterWithPhaser(); + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabCloudScriptApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabCloudScriptApi.js new file mode 100644 index 00000000..17c11b0f --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabCloudScriptApi.js @@ -0,0 +1,307 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.CloudScriptApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + ExecuteEntityCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ExecuteEntityCloudScript", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ExecuteFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/GetFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListEventHubFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListEventHubFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListHttpFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListHttpFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListQueuedFunctions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/ListQueuedFunctions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForEntityTriggeredAction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForEntityTriggeredAction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForFunctionExecution: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForFunctionExecution", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForPlayerTriggeredAction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForPlayerTriggeredAction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PostFunctionResultForScheduledTask: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/PostFunctionResultForScheduledTask", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterEventHubFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterEventHubFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterHttpFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterHttpFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RegisterQueuedFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/RegisterQueuedFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnregisterFunction: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/CloudScript/UnregisterFunction", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabCloudScriptSDK = PlayFab.CloudScriptApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabDataApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabDataApi.js new file mode 100644 index 00000000..49e60dfc --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabDataApi.js @@ -0,0 +1,275 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.DataApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AbortFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/AbortFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteFiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/DeleteFiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FinalizeFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/FinalizeFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/GetFiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetObjects: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Object/GetObjects", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InitiateFileUploads: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/File/InitiateFileUploads", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetObjects: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Object/SetObjects", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabDataSDK = PlayFab.DataApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabEconomyApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabEconomyApi.js new file mode 100644 index 00000000..013d5ea7 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabEconomyApi.js @@ -0,0 +1,431 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.EconomyApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AddInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/AddInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/CreateDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateUploadUrls: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/CreateUploadUrls", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteEntityItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/DeleteEntityItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteInventoryCollection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/DeleteInventoryCollection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/DeleteInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/DeleteItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteInventoryOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/ExecuteInventoryOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ExecuteTransferOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/ExecuteTransferOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetCatalogConfig: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetCatalogConfig", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDraftItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetDraftItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityDraftItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetEntityDraftItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetEntityItemReview: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetEntityItemReview", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryCollectionIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryCollectionIds", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetInventoryOperationStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetInventoryOperationStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemContainers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemContainers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemModerationState: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemModerationState", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemPublishStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemPublishStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItemReviewSummary: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItemReviewSummary", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/GetItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTransactionHistory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/GetTransactionHistory", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PublishDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/PublishDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + PurchaseInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/PurchaseInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemAppleAppStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemAppleAppStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemAppleAppStoreWithJwsInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemAppleAppStoreWithJwsInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemGooglePlayInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemGooglePlayInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemMicrosoftStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemMicrosoftStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemNintendoEShopInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemNintendoEShopInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemPlayStationStoreInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemPlayStationStoreInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RedeemSteamInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/RedeemSteamInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReportItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReportItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReportItemReview: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReportItemReview", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ReviewItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/ReviewItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SearchItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SearchItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetItemModerationState: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SetItemModerationState", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubmitItemReviewVote: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/SubmitItemReviewVote", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubtractInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/SubtractInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + TakedownItemReviews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/TakedownItemReviews", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + TransferInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/TransferInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateCatalogConfig: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/UpdateCatalogConfig", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateDraftItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Catalog/UpdateDraftItem", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Inventory/UpdateInventoryItems", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabEconomySDK = PlayFab.EconomyApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabEventsApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabEventsApi.js new file mode 100644 index 00000000..c8ed22b3 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabEventsApi.js @@ -0,0 +1,295 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.EventsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/CreateTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/DeleteDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/DeleteTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/GetDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTelemetryKey: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/GetTelemetryKey", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListDataConnections: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/ListDataConnections", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListTelemetryKeys: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/ListTelemetryKeys", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDataConnection: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetDataConnection", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDataConnectionActive: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetDataConnectionActive", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetTelemetryKeyActive: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/SetTelemetryKeyActive", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + WriteEvents: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/WriteEvents", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + WriteTelemetryEvents: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Event/WriteTelemetryEvents", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabEventsSDK = PlayFab.EventsApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabExperimentationApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabExperimentationApi.js new file mode 100644 index 00000000..06fe7806 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabExperimentationApi.js @@ -0,0 +1,299 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ExperimentationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/CreateExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/CreateExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/DeleteExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/DeleteExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExclusionGroups: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExclusionGroups", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExclusionGroupTraffic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExclusionGroupTraffic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetExperiments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetExperiments", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLatestScorecard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetLatestScorecard", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTreatmentAssignment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/GetTreatmentAssignment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + StartExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/StartExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + StopExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/StopExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateExclusionGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/UpdateExclusionGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateExperiment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Experimentation/UpdateExperiment", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabExperimentationSDK = PlayFab.ExperimentationApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabGroupsApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabGroupsApi.js new file mode 100644 index 00000000..5ff17e41 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabGroupsApi.js @@ -0,0 +1,347 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.GroupsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + AcceptGroupApplication: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AcceptGroupApplication", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + AcceptGroupInvitation: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AcceptGroupInvitation", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + AddMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/AddMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ApplyToGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ApplyToGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + BlockEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/BlockEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ChangeMemberRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ChangeMemberRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/CreateGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/CreateRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/DeleteGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/DeleteRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/GetGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InviteToGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/InviteToGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IsMember: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/IsMember", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupApplications: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupApplications", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupBlocks: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupBlocks", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupInvitations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupInvitations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListGroupMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMembership: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListMembership", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMembershipOpportunities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/ListMembershipOpportunities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveGroupApplication: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveGroupApplication", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveGroupInvitation: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveGroupInvitation", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/RemoveMembers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnblockEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UnblockEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UpdateGroup", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateRole: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Group/UpdateRole", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabGroupsSDK = PlayFab.GroupsApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabInsightsApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabInsightsApi.js new file mode 100644 index 00000000..4751a9f5 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabInsightsApi.js @@ -0,0 +1,271 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.InsightsApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetDetails: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetDetails", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLimits: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetLimits", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetOperationStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetOperationStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetPendingOperations: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/GetPendingOperations", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetPerformance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/SetPerformance", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetStorageRetention: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Insights/SetStorageRetention", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabInsightsSDK = PlayFab.InsightsApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabLocalizationApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabLocalizationApi.js new file mode 100644 index 00000000..f2b8672f --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabLocalizationApi.js @@ -0,0 +1,251 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.LocalizationApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetLanguageList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Locale/GetLanguageList", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabLocalizationSDK = PlayFab.LocalizationApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabMatchmakerApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabMatchmakerApi.js deleted file mode 100644 index dd1e6a0e..00000000 --- a/PlayFabTestingExample/src/PlayFab/PlayFabMatchmakerApi.js +++ /dev/null @@ -1,138 +0,0 @@ -/// - -var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; - -if(!PlayFab.settings) { - PlayFab.settings = { - titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) - developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" - } -} - -if(!PlayFab._internalSettings) { - PlayFab._internalSettings = { - sessionTicket: null, - productionServerUrl: ".playfabapi.com", - - GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; - }, - - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; - - if (data == null) - data = {}; - - var startTime = new Date(); - var requestBody = JSON.stringify(data); - - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); - - xhr.setRequestHeader('Content-Type', 'application/json'); - - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); - - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); - - xhr.onloadend = function () { - if (callback == null) - return; - - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } - - result.CallBackTimeMS = new Date() - startTime; - - if (result.code === 200) - callback(result, null); - else - callback(null, result); - } - - xhr.onerror = function () { - if (callback == null) - return; - - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } - - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } - - xhr.send(requestBody); - } - } -} - -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; - -PlayFab.MatchmakerApi = { - - AuthUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/AuthUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - PlayerJoined: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/PlayerJoined", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - PlayerLeft: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/PlayerLeft", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - StartGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/StartGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, - - UserInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Matchmaker/UserInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); - }, -}; - -var PlayFabMatchmakerSDK = PlayFab.MatchmakerApi; diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabMultiplayerApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabMultiplayerApi.js new file mode 100644 index 00000000..d92785ef --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabMultiplayerApi.js @@ -0,0 +1,595 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.MultiplayerApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CancelAllMatchmakingTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelAllMatchmakingTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelAllServerBackfillTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelAllServerBackfillTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CancelServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CancelServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithCustomContainer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithCustomContainer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithManagedContainer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithManagedContainer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateBuildWithProcessBasedServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateBuildWithProcessBasedServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/CreateLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateRemoteUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateRemoteUser", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateServerMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/CreateServerMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateTitleMultiplayerServersQuotaChange: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/CreateTitleMultiplayerServersQuotaChange", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteAsset: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteAsset", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuild: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuild", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteBuildRegion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteBuildRegion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteCertificate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteCertificate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteContainerImageRepository: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteContainerImageRepository", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/DeleteLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteRemoteUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteRemoteUser", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/DeleteSecret", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + EnableMultiplayerServersForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/EnableMultiplayerServersForTitle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FindFriendLobbies: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/FindFriendLobbies", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + FindLobbies: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/FindLobbies", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetAssetDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetAssetDownloadUrl", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetAssetUploadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetAssetUploadUrl", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetBuild: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetBuild", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetContainerRegistryCredentials: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetContainerRegistryCredentials", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/GetLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatch", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerServerDetails: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerServerDetails", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerServerLogs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerServerLogs", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetMultiplayerSessionLogsBySessionId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetMultiplayerSessionLogsBySessionId", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetQueueStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetQueueStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetRemoteLoginEndpoint: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetRemoteLoginEndpoint", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetServerBackfillTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/GetServerBackfillTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleEnabledForMultiplayerServersStatus: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleEnabledForMultiplayerServersStatus", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleMultiplayerServersQuotaChange: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleMultiplayerServersQuotaChange", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitleMultiplayerServersQuotas: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/GetTitleMultiplayerServersQuotas", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + InviteToLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/InviteToLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinArrangedLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinArrangedLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/JoinLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + JoinMatchmakingTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/JoinMatchmakingTicket", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + LeaveLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/LeaveLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + LeaveLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/LeaveLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListArchivedMultiplayerServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListArchivedMultiplayerServers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListAssetSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListAssetSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListBuildAliases: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListBuildAliases", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListBuildSummariesV2: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListBuildSummariesV2", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListCertificateSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListCertificateSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListContainerImages: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListContainerImages", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListContainerImageTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListContainerImageTags", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMatchmakingQueues: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListMatchmakingQueues", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMatchmakingTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListMatchmakingTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListMultiplayerServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListMultiplayerServers", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListPartyQosServers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListPartyQosServers", request, null, callback, customData, extraHeaders); + }, + + ListQosServersForTitle: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListQosServersForTitle", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListSecretSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListSecretSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListServerBackfillTicketsForPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/ListServerBackfillTicketsForPlayer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListTitleMultiplayerServersQuotaChanges: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListTitleMultiplayerServersQuotaChanges", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListVirtualMachineSummaries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ListVirtualMachineSummaries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/RemoveMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RemoveMember: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/RemoveMember", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RequestMultiplayerServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/RequestMultiplayerServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RequestPartyService: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Party/RequestPartyService", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + RolloverContainerRegistryCredentials: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/RolloverContainerRegistryCredentials", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetMatchmakingQueue: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/SetMatchmakingQueue", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ShutdownMultiplayerServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/ShutdownMultiplayerServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubscribeToLobbyResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/SubscribeToLobbyResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SubscribeToMatchmakingResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/SubscribeToMatchmakingResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnsubscribeFromLobbyResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UnsubscribeFromLobbyResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnsubscribeFromMatchmakingResource: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Match/UnsubscribeFromMatchmakingResource", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UntagContainerImage: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UntagContainerImage", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildAlias: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildAlias", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildName", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildRegion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildRegion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateBuildRegions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UpdateBuildRegions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLobby: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UpdateLobby", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLobbyAsServer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Lobby/UpdateLobbyAsServer", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UploadCertificate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UploadCertificate", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UploadSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/MultiplayerServer/UploadSecret", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabMultiplayerSDK = PlayFab.MultiplayerApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabProfilesApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabProfilesApi.js new file mode 100644 index 00000000..5a1ec15d --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabProfilesApi.js @@ -0,0 +1,283 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ProfilesApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + GetGlobalPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetGlobalPolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetProfile", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetProfiles: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetProfiles", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitlePlayersFromMasterPlayerAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetTitlePlayersFromMasterPlayerAccountIds", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetTitlePlayersFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/GetTitlePlayersFromXboxLiveIDs", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetDisplayName: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetDisplayName", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetGlobalPolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetGlobalPolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetProfileLanguage: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetProfileLanguage", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + SetProfilePolicy: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Profile/SetProfilePolicy", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabProfilesSDK = PlayFab.ProfilesApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabProgressionApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabProgressionApi.js new file mode 100644 index 00000000..479bc913 --- /dev/null +++ b/PlayFabTestingExample/src/PlayFab/PlayFabProgressionApi.js @@ -0,0 +1,343 @@ +/// + +var PlayFab = typeof PlayFab != "undefined" ? PlayFab : {}; + +if(!PlayFab.settings) { + PlayFab.settings = { + titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) + developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" + } +} + +if(!PlayFab._internalSettings) { + PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, + sessionTicket: null, + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", + + GetServerUrl: function () { + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } + }, + + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; + + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, + + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } + + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } + + xhr.onerror = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } + + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, + + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } + + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, + + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, + + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; + } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, + + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, + + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, + + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; + + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); + } + } +} + +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; + +PlayFab.ProgressionApi = { + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; + }, + + CreateLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/CreateLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + CreateStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/CreateStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/DeleteLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteLeaderboardEntries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/DeleteLeaderboardEntries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/DeleteStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + DeleteStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/DeleteStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetFriendLeaderboardForEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetFriendLeaderboardForEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboard", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardAroundEntity: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardAroundEntity", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetLeaderboardForEntities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/GetLeaderboardForEntities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + GetStatisticsForEntities: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/GetStatisticsForEntities", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IncrementLeaderboardVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/IncrementLeaderboardVersion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + IncrementStatisticVersion: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/IncrementStatisticVersion", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListLeaderboardDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/ListLeaderboardDefinitions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + ListStatisticDefinitions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/ListStatisticDefinitions", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnlinkAggregationSourceFromStatistic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UnlinkAggregationSourceFromStatistic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UnlinkLeaderboardFromStatistic: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UnlinkLeaderboardFromStatistic", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLeaderboardDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UpdateLeaderboardDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateLeaderboardEntries: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Leaderboard/UpdateLeaderboardEntries", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateStatisticDefinition: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UpdateStatisticDefinition", request, "X-EntityToken", callback, customData, extraHeaders); + }, + + UpdateStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Statistic/UpdateStatistics", request, "X-EntityToken", callback, customData, extraHeaders); + }, + +}; + +var PlayFabProgressionSDK = PlayFab.ProgressionApi; + diff --git a/PlayFabTestingExample/src/PlayFab/PlayFabServerApi.js b/PlayFabTestingExample/src/PlayFab/PlayFabServerApi.js index 8b42722b..a0f01589 100644 --- a/PlayFabTestingExample/src/PlayFab/PlayFabServerApi.js +++ b/PlayFabTestingExample/src/PlayFab/PlayFabServerApi.js @@ -6,745 +6,890 @@ if(!PlayFab.settings) { PlayFab.settings = { titleId: null, // You must set this value for PlayFabSdk to work properly (Found in the Game Manager for your title, at the PlayFab Website) developerSecretKey: null, // For security reasons you must never expose this value to the client or players - You must set this value for Server-APIs to work properly (Found in the Game Manager for your title, at the PlayFab Website) - advertisingIdType: null, - advertisingIdValue: null, - - // disableAdvertising is provided for completeness, but changing it is not suggested - // Disabling this may prevent your advertising-related PlayFab marketplace partners from working correctly - disableAdvertising: false, - AD_TYPE_IDFA: "Idfa", - AD_TYPE_ANDROID_ID: "Adid" + GlobalHeaderInjection: null, + productionServerUrl: ".playfabapi.com" } } if(!PlayFab._internalSettings) { PlayFab._internalSettings = { + entityToken: null, + sdkVersion: "1.222.260922", + requestGetParams: { + sdk: "JavaScriptSDK-1.222.260922" + }, sessionTicket: null, - productionServerUrl: ".playfabapi.com", + verticalName: null, // The name of a customer vertical. This is only for customers running a private cluster. Generally you shouldn't touch this + errorTitleId: "Must be have PlayFab.settings.titleId set to call this method", + errorLoggedIn: "Must be logged in to call this method", + errorEntityToken: "You must successfully call GetEntityToken before calling this", + errorSecretKey: "Must have PlayFab.settings.developerSecretKey set to call this method", GetServerUrl: function () { - return "https://" + PlayFab.settings.titleId + PlayFab._internalSettings.productionServerUrl; + if (!(PlayFab.settings.productionServerUrl.substring(0, 4) === "http")) { + if (PlayFab._internalSettings.verticalName) { + return "https://" + PlayFab._internalSettings.verticalName + PlayFab.settings.productionServerUrl; + } else { + return "https://" + PlayFab.settings.titleId + PlayFab.settings.productionServerUrl; + } + } else { + return PlayFab.settings.productionServerUrl; + } }, - ExecuteRequest: function (completeUrl, data, authkey, authValue, callback) { - if (callback != null && typeof (callback) != "function") - throw "Callback must be null of a function"; + InjectHeaders: function (xhr, headersObj) { + if (!headersObj) + return; - if (data == null) - data = {}; + for (var headerKey in headersObj) + { + try { + xhr.setRequestHeader(gHeaderKey, headersObj[headerKey]); + } catch (e) { + console.log("Failed to append header: " + headerKey + " = " + headersObj[headerKey] + "Error: " + e); + } + } + }, - var startTime = new Date(); - var requestBody = JSON.stringify(data); + ExecuteRequest: function (url, request, authkey, authValue, callback, customData, extraHeaders) { + var resultPromise = new Promise(function (resolve, reject) { + if (callback != null && typeof (callback) !== "function") + throw "Callback must be null or a function"; + + if (request == null) + request = {}; + + var startTime = new Date(); + var requestBody = JSON.stringify(request); + + var urlArr = [url]; + var getParams = PlayFab._internalSettings.requestGetParams; + if (getParams != null) { + var firstParam = true; + for (var key in getParams) { + if (firstParam) { + urlArr.push("?"); + firstParam = false; + } else { + urlArr.push("&"); + } + urlArr.push(key); + urlArr.push("="); + urlArr.push(getParams[key]); + } + } - var xhr = new XMLHttpRequest(); - // window.console.log("URL: " + completeUrl); - xhr.open("POST", completeUrl, true); + var completeUrl = urlArr.join(""); + + var xhr = new XMLHttpRequest(); + // window.console.log("URL: " + completeUrl); + xhr.open("POST", completeUrl, true); + + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.setRequestHeader("X-PlayFabSDK", "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + if (authkey != null) + xhr.setRequestHeader(authkey, authValue); + PlayFab._internalSettings.InjectHeaders(xhr, PlayFab.settings.GlobalHeaderInjection); + PlayFab._internalSettings.InjectHeaders(xhr, extraHeaders); + + xhr.onloadend = function () { + if (callback == null) + return; + + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + if (result.code === 200) { + callback(result, null); + } else { + callback(null, result); + } + } - xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.onerror = function () { + if (callback == null) + return; - if (authkey != null) - xhr.setRequestHeader(authkey, authValue); + var result = PlayFab._internalSettings.GetPlayFabResponse(request, xhr, startTime, customData); + callback(null, result); + } - xhr.setRequestHeader('X-PlayFabSDK', "JavaScriptSDK-" + PlayFab._internalSettings.sdkVersion); + xhr.send(requestBody); + xhr.onreadystatechange = function () { + if (this.readyState === 4) { + var xhrResult = PlayFab._internalSettings.GetPlayFabResponse(request, this, startTime, customData); + if (this.status === 200) { + resolve(xhrResult); + } else { + reject(xhrResult); + } + } + }; + }); + // Return a Promise so that calls to various API methods can be handled asynchronously + return resultPromise; + }, - xhr.onloadend = function () { - if (callback == null) - return; + GetPlayFabResponse: function(request, xhr, startTime, customData) { + var result = null; + try { + // window.console.log("parsing json result: " + xhr.responseText); + result = JSON.parse(xhr.responseText); + } catch (e) { + result = { + code: 503, // Service Unavailable + status: "Service Unavailable", + error: "Connection error", + errorCode: 2, // PlayFabErrorCode.ConnectionError + errorMessage: xhr.responseText + }; + } - var result; - try { - // window.console.log("parsing json result: " + xhr.responseText); - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + result.CallBackTimeMS = new Date() - startTime; + result.Request = request; + result.CustomData = customData; + return result; + }, - result.CallBackTimeMS = new Date() - startTime; + authenticationContext: { + PlayFabId: null, + EntityId: null, + EntityType: null, + SessionTicket: null, + EntityToken: null + }, - if (result.code === 200) - callback(result, null); - else - callback(null, result); + UpdateAuthenticationContext: function (authenticationContext, result) { + var authenticationContextUpdates = {}; + if(result.data.PlayFabId !== null) { + PlayFab._internalSettings.authenticationContext.PlayFabId = result.data.PlayFabId; + authenticationContextUpdates.PlayFabId = result.data.PlayFabId; + } + if(result.data.SessionTicket !== null) { + PlayFab._internalSettings.authenticationContext.SessionTicket = result.data.SessionTicket; + authenticationContextUpdates.SessionTicket = result.data.SessionTicket; } + if (result.data.EntityToken !== null) { + PlayFab._internalSettings.authenticationContext.EntityId = result.data.EntityToken.Entity.Id; + authenticationContextUpdates.EntityId = result.data.EntityToken.Entity.Id; + PlayFab._internalSettings.authenticationContext.EntityType = result.data.EntityToken.Entity.Type; + authenticationContextUpdates.EntityType = result.data.EntityToken.Entity.Type; + PlayFab._internalSettings.authenticationContext.EntityToken = result.data.EntityToken.EntityToken; + authenticationContextUpdates.EntityToken = result.data.EntityToken.EntityToken; + } + // Update the authenticationContext with values from the result + authenticationContext = Object.assign(authenticationContext, authenticationContextUpdates); + return authenticationContext; + }, - xhr.onerror = function () { - if (callback == null) - return; + AuthInfoMap: { + "X-EntityToken": { + authAttr: "entityToken", + authError: "errorEntityToken" + }, + "X-Authorization": { + authAttr: "sessionTicket", + authError: "errorLoggedIn" + }, + "X-SecretKey": { + authAttr: "developerSecretKey", + authError: "errorSecretKey" + } + }, - var result; - try { - result = JSON.parse(xhr.responseText); - } catch (e) { - result = { - code: 503, // Service Unavailable - status: "Service Unavailable", - error: "Connection error", - errorCode: 2, // PlayFabErrorCode.ConnectionError - errorMessage: xhr.responseText - }; - } + GetAuthInfo: function (request, authKey) { + // Use the most-recently saved authKey, unless one was provided in the request via the AuthenticationContext + var authError = PlayFab._internalSettings.AuthInfoMap[authKey].authError; + var authAttr = PlayFab._internalSettings.AuthInfoMap[authKey].authAttr; + var defaultAuthValue = null; + if (authAttr === "entityToken") + defaultAuthValue = PlayFab._internalSettings.entityToken; + else if (authAttr === "sessionTicket") + defaultAuthValue = PlayFab._internalSettings.sessionTicket; + else if (authAttr === "developerSecretKey") + defaultAuthValue = PlayFab.settings.developerSecretKey; + var authValue = request.AuthenticationContext ? request.AuthenticationContext[authAttr] : defaultAuthValue; + return {"authKey": authKey, "authValue": authValue, "authError": authError}; + }, - result.CallBackTimeMS = new Date() - startTime; - callback(null, result); - } + ExecuteRequestWrapper: function (apiURL, request, authKey, callback, customData, extraHeaders) { + var authValue = null; + if (authKey !== null){ + var authInfo = PlayFab._internalSettings.GetAuthInfo(request, authKey=authKey); + var authKey = authInfo.authKey, authValue = authInfo.authValue, authError = authInfo.authError; - xhr.send(requestBody); + if (!authValue) throw authError; + } + return PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + apiURL, request, authKey, authValue, callback, customData, extraHeaders); } } } -PlayFab.buildIdentifier = "jbuild_javascriptsdk_1"; -PlayFab.sdkVersion = "1.2.170313"; +PlayFab.buildIdentifier = "adobuild_javascriptsdk_115"; +PlayFab.sdkVersion = "1.222.260922"; +PlayFab.GenerateErrorReport = function (error) { + if (error == null) + return ""; + var fullErrors = error.errorMessage; + for (var paramName in error.errorDetails) + for (var msgIdx in error.errorDetails[paramName]) + fullErrors += "\n" + paramName + ": " + error.errorDetails[paramName][msgIdx]; + return fullErrors; +}; PlayFab.ServerApi = { - - AuthenticateSessionTicket: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AuthenticateSessionTicket", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ForgetAllCredentials: function () { + PlayFab._internalSettings.sessionTicket = null; + PlayFab._internalSettings.entityToken = null; }, - BanUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/BanUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddCharacterVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddCharacterVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayFabIDsFromFacebookIDs: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayFabIDsFromFacebookIDs", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddFriend", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayFabIDsFromSteamIDs: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayFabIDsFromSteamIDs", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddGenericID", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserAccountInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserAccountInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddOrUpdateContactEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddOrUpdateContactEmail", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddPlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddPlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeAllBansForUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeAllBansForUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddSharedGroupMembers", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AddUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AddUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - SendPushNotification: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SendPushNotification", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AuthenticateSessionTicket: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AuthenticateSessionTicket", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateAvatarUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateAvatarUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + AwardSteamAchievement: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/AwardSteamAchievement", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateBans: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateBans", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + BanUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/BanUsers", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ConsumeItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ConsumeItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetFriendLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetFriendLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + CreateSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/CreateSharedGroup", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteCharacterFromUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeleteCharacterFromUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardAroundUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardAroundUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePlayer", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerCombinedInfo: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerCombinedInfo", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeletePushNotificationTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeletePushNotificationTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerStatisticVersions: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerStatisticVersions", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + DeleteSharedGroup: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/DeleteSharedGroup", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + EvaluateRandomResultTable: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/EvaluateRandomResultTable", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExecuteCloudScript: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ExecuteCloudScript", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ExportPlayersInSegment: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ExportPlayersInSegment", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetAllSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetAllUsersCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetAllUsersCharacters", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCatalogItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCatalogItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdatePlayerStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdatePlayerStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterInventory", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserPublisherReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetContentDownloadUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetContentDownloadUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCatalogItems: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCatalogItems", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetFriendLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetFriendLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetFriendsList: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetFriendsList", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTime: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTime", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboard: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboard", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardAroundCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardAroundCharacter", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardAroundUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardAroundUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetTitleNews: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetTitleNews", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetLeaderboardForUserCharacters: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetLeaderboardForUserCharacters", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetPublisherData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetPublisherData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCombinedInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerCombinedInfo", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetTitleData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerCustomProperty: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerCustomProperty", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetTitleInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetTitleInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerProfile: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerProfile", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddCharacterVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddCharacterVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerSegments: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerSegments", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerStatistics", request, "X-SecretKey", callback, customData, extraHeaders); }, - ConsumeItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ConsumeItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerStatisticVersions: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerStatisticVersions", request, "X-SecretKey", callback, customData, extraHeaders); }, - EvaluateRandomResultTable: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/EvaluateRandomResultTable", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayerTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayerTags", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromBattleNetAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromBattleNetAccountIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetRandomResultTables: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetRandomResultTables", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromFacebookIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromFacebookIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetUserInventory: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetUserInventory", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromFacebookInstantGamesIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromFacebookInstantGamesIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromGenericIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromGenericIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromNintendoServiceAccountIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromNintendoServiceAccountIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantItemsToUsers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantItemsToUsers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromNintendoSwitchDeviceIds: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromNintendoSwitchDeviceIds", request, "X-SecretKey", callback, customData, extraHeaders); }, - ModifyItemUses: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; - - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ModifyItemUses", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromOpenIdSubjectIdentifiers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromOpenIdSubjectIdentifiers", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToCharacterFromCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromPSNAccountIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromPSNAccountIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToCharacterFromCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromPSNOnlineIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromPSNOnlineIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToCharacterFromUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromServerCustomIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromServerCustomIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToCharacterFromUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromSteamIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromSteamIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - MoveItemToUserFromCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromSteamNames: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromSteamNames", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/MoveItemToUserFromCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPlayFabIDsFromTwitchIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromTwitchIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - RedeemCoupon: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetPlayFabIDsFromXboxLiveIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPlayFabIDsFromXboxLiveIDs", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RedeemCoupon", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - ReportPlayer: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetRandomResultTables: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetRandomResultTables", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ReportPlayer", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetSegmentExport: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSegmentExport", request, "X-SecretKey", callback, customData, extraHeaders); }, - RevokeInventoryItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetSegmentPlayerCount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSegmentPlayerCount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RevokeInventoryItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetServerCustomIDsFromPlayFabIDs: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetServerCustomIDsFromPlayFabIDs", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractCharacterVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetSharedGroupData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SubtractCharacterVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetStoreItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetStoreItems", request, "X-SecretKey", callback, customData, extraHeaders); }, - SubtractUserVirtualCurrency: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTime: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTime", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SubtractUserVirtualCurrency", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UnlockContainerInstance: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UnlockContainerInstance", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetTitleNews: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetTitleNews", request, "X-SecretKey", callback, customData, extraHeaders); }, - UnlockContainerItem: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserAccountInfo: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserAccountInfo", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UnlockContainerItem", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserBans", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateUserInventoryItemCustomData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateUserInventoryItemCustomData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddFriend: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserInventory: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserInventory", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddFriend", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetFriendsList: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetFriendsList", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GetUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveFriend: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GetUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GetUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemoveFriend", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GrantCharacterToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantCharacterToUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetFriendTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetFriendTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + GrantItemsToUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeregisterGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + GrantItemsToUsers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/GrantItemsToUsers", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeregisterGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkBattleNetAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - NotifyMatchmakerPlayerLeft: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoServiceAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/NotifyMatchmakerPlayerLeft", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkNintendoServiceAccountSubject: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoServiceAccountSubject", request, "X-SecretKey", callback, customData, extraHeaders); }, - RedeemMatchmakerTicket: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkNintendoSwitchDeviceId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RedeemMatchmakerTicket", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkPSNAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - RefreshGameServerInstanceHeartbeat: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkPSNId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkPSNId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RefreshGameServerInstanceHeartbeat", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); }, - RegisterGame: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkSteamId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RegisterGame", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkTwitchAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkTwitchAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkXboxAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LinkXboxId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LinkXboxId", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceState: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ListPlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ListPlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceState", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithAndroidDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithAndroidDeviceID", request, "X-SecretKey", callback, customData, extraHeaders); }, - SetGameServerInstanceTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithBattleNet: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithBattleNet", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/SetGameServerInstanceTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithCustomID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithCustomID", request, "X-SecretKey", callback, customData, extraHeaders); }, - AwardSteamAchievement: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithIOSDeviceID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithIOSDeviceID", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AwardSteamAchievement", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithPSN: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithPSN", request, "X-SecretKey", callback, customData, extraHeaders); }, - WriteCharacterEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WriteCharacterEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithSteamId", request, "X-SecretKey", callback, customData, extraHeaders); }, - WritePlayerEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithTwitch: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithTwitch", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WritePlayerEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + LoginWithXbox: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithXbox", request, "X-SecretKey", callback, customData, extraHeaders); }, - WriteTitleEvent: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + LoginWithXboxId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/LoginWithXboxId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/WriteTitleEvent", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + ModifyItemUses: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ModifyItemUses", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddSharedGroupMembers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + MoveItemToCharacterFromCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToCharacterFromCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddSharedGroupMembers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + MoveItemToCharacterFromUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToCharacterFromUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - CreateSharedGroup: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + MoveItemToUserFromCharacter: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/MoveItemToUserFromCharacter", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/CreateSharedGroup", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RedeemCoupon: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RedeemCoupon", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteSharedGroup: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemoveFriend: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveFriend", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteSharedGroup", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemoveGenericID: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveGenericID", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetSharedGroupData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RemovePlayerTag: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemovePlayerTag", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetSharedGroupData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RemoveSharedGroupMembers: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RemoveSharedGroupMembers", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemoveSharedGroupMembers: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + ReportPlayer: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/ReportPlayer", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemoveSharedGroupMembers", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeAllBansForUser: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeAllBansForUser", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateSharedGroupData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateSharedGroupData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + RevokeInventoryItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeInventoryItem", request, "X-SecretKey", callback, customData, extraHeaders); }, - ExecuteCloudScript: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + RevokeInventoryItems: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/RevokeInventoryItems", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/ExecuteCloudScript", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SavePushNotificationTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SavePushNotificationTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetContentDownloadUrl: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SendCustomAccountRecoveryEmail: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendCustomAccountRecoveryEmail", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetContentDownloadUrl", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendEmailFromTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendEmailFromTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - DeleteCharacterFromUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SendPushNotification: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendPushNotification", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/DeleteCharacterFromUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SendPushNotificationFromTemplate: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SendPushNotificationFromTemplate", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllUsersCharacters: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetFriendTags: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetFriendTags", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllUsersCharacters", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetPlayerSecret: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetPlayerSecret", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterLeaderboard: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterLeaderboard", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SetTitleData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetTitleData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SetTitleInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SetTitleInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + SubtractCharacterVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SubtractCharacterVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardAroundCharacter: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + SubtractUserVirtualCurrency: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/SubtractUserVirtualCurrency", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardAroundCharacter", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkApple: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkApple", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetLeaderboardForUserCharacters: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkBattleNetAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkBattleNetAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetLeaderboardForUserCharacters", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkFacebookAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkFacebookAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GrantCharacterToUser: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkFacebookInstantGamesId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkFacebookInstantGamesId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GrantCharacterToUser", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkGameCenterAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkGameCenterAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterStatistics: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkNintendoServiceAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkNintendoServiceAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterStatistics", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkNintendoSwitchDeviceId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkNintendoSwitchDeviceId", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkPSNAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkPSNAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkServerCustomId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkServerCustomId", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkSteamId: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkSteamId", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlinkTwitchAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkTwitchAccount", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetCharacterReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlinkXboxAccount: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlinkXboxAccount", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetCharacterReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UnlockContainerInstance: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlockContainerInstance", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UnlockContainerItem: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UnlockContainerItem", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateAvatarUrl: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateAvatarUrl", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterInternalData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateBans: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateBans", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterInternalData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCharacterData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterData", request, "X-SecretKey", callback, customData, extraHeaders); }, - UpdateCharacterReadOnlyData: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCharacterInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/UpdateCharacterReadOnlyData", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateCharacterReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - AddPlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateCharacterStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateCharacterStatistics", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/AddPlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdatePlayerCustomProperties: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdatePlayerCustomProperties", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllActionGroups: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdatePlayerStatistics: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdatePlayerStatistics", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllActionGroups", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateSharedGroupData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateSharedGroupData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetAllSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetAllSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserInternalData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerSegments: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserInventoryItemCustomData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserInventoryItemCustomData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerSegments", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayersInSegment: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserPublisherInternalData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherInternalData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayersInSegment", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + UpdateUserPublisherReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserPublisherReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); }, - GetPlayerTags: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + UpdateUserReadOnlyData: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/UpdateUserReadOnlyData", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/GetPlayerTags", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + WriteCharacterEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WriteCharacterEvent", request, "X-SecretKey", callback, customData, extraHeaders); }, - RemovePlayerTag: function (request, callback) { - if (PlayFab.settings.developerSecretKey == null) throw "Must have PlayFab.settings.developerSecretKey set to call this method"; + WritePlayerEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WritePlayerEvent", request, "X-SecretKey", callback, customData, extraHeaders); + }, - PlayFab._internalSettings.ExecuteRequest(PlayFab._internalSettings.GetServerUrl() + "/Server/RemovePlayerTag", request, "X-SecretKey", PlayFab.settings.developerSecretKey, callback); + WriteTitleEvent: function (request, callback, customData, extraHeaders) { + return PlayFab._internalSettings.ExecuteRequestWrapper("/Server/WriteTitleEvent", request, "X-SecretKey", callback, customData, extraHeaders); }, + }; var PlayFabServerSDK = PlayFab.ServerApi; + diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFab.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFab.d.ts index d5d8e6c7..441d70ef 100644 --- a/PlayFabTestingExample/src/typings/PlayFab/PlayFab.d.ts +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFab.d.ts @@ -1,17 +1,26 @@ /// -/// -/// /// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// declare module PlayFabModule { export interface ISettings { titleId: string; developerSecretKey: string; - advertisingIdType: string; - advertisingIdValue: string; - disableAdvertising: boolean; - AD_TYPE_IDFA: string; - AD_TYPE_ANDROID_ID: string; + GlobalHeaderInjection?: { [key: string]: string }; + productionServerUrl: string; } export interface IPlayFabRequestCommon { } export interface IPlayFabError { @@ -21,6 +30,9 @@ declare module PlayFabModule { errorCode: number; errorMessage: string; errorDetails?: { [key: string]: string[] }; + request?: any; + customData?: any; + retryAfterSeconds?: number; } export interface SuccessContainer extends IPlayFabError { data: TResult; @@ -33,16 +45,41 @@ declare module PlayFabModule { declare var PlayFab: { buildIdentifier: string; sdkVersion: string; + GenerateErrorReport(IPlayFabError): string; settings: PlayFabModule.ISettings; AdminApi: PlayFabAdminModule.IPlayFabAdmin; - MatchmakerApi: PlayFabMatchmakerModule.IPlayFabMatchmaker; - ServerApi: PlayFabServerModule.IPlayFabServer; ClientApi: PlayFabClientModule.IPlayFabClient; + ServerApi: PlayFabServerModule.IPlayFabServer; + AuthenticationApi: PlayFabAuthenticationModule.IPlayFabAuthentication; + CloudScriptApi: PlayFabCloudScriptModule.IPlayFabCloudScript; + DataApi: PlayFabDataModule.IPlayFabData; + EconomyApi: PlayFabEconomyModule.IPlayFabEconomy; + EventsApi: PlayFabEventsModule.IPlayFabEvents; + ExperimentationApi: PlayFabExperimentationModule.IPlayFabExperimentation; + InsightsApi: PlayFabInsightsModule.IPlayFabInsights; + GroupsApi: PlayFabGroupsModule.IPlayFabGroups; + ProgressionApi: PlayFabProgressionModule.IPlayFabProgression; + LocalizationApi: PlayFabLocalizationModule.IPlayFabLocalization; + MultiplayerApi: PlayFabMultiplayerModule.IPlayFabMultiplayer; + ProfilesApi: PlayFabProfilesModule.IPlayFabProfiles; + AddonApi: PlayFabAddonModule.IPlayFabAddon; }; // Continue to support older usage declare var PlayFabAdminSDK: PlayFabAdminModule.IPlayFabAdmin; -declare var PlayFabMatchmakerSDK: PlayFabMatchmakerModule.IPlayFabMatchmaker; -declare var PlayFabServerSDK: PlayFabServerModule.IPlayFabServer; declare var PlayFabClientSDK: PlayFabClientModule.IPlayFabClient; +declare var PlayFabServerSDK: PlayFabServerModule.IPlayFabServer; +declare var PlayFabAuthenticationSDK: PlayFabAuthenticationModule.IPlayFabAuthentication; +declare var PlayFabCloudScriptSDK: PlayFabCloudScriptModule.IPlayFabCloudScript; +declare var PlayFabDataSDK: PlayFabDataModule.IPlayFabData; +declare var PlayFabEconomySDK: PlayFabEconomyModule.IPlayFabEconomy; +declare var PlayFabEventsSDK: PlayFabEventsModule.IPlayFabEvents; +declare var PlayFabExperimentationSDK: PlayFabExperimentationModule.IPlayFabExperimentation; +declare var PlayFabInsightsSDK: PlayFabInsightsModule.IPlayFabInsights; +declare var PlayFabGroupsSDK: PlayFabGroupsModule.IPlayFabGroups; +declare var PlayFabProgressionSDK: PlayFabProgressionModule.IPlayFabProgression; +declare var PlayFabLocalizationSDK: PlayFabLocalizationModule.IPlayFabLocalization; +declare var PlayFabMultiplayerSDK: PlayFabMultiplayerModule.IPlayFabMultiplayer; +declare var PlayFabProfilesSDK: PlayFabProfilesModule.IPlayFabProfiles; +declare var PlayFabAddonSDK: PlayFabAddonModule.IPlayFabAddon; diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabAddonApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAddonApi.d.ts new file mode 100644 index 00000000..6ec1a36a --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAddonApi.d.ts @@ -0,0 +1,758 @@ +/// + +declare module PlayFabAddonModule { + export interface IPlayFabAddon { + ForgetAllCredentials(): void; + + /** + * Configures PSN event streams for an existing PSN addon on a title, without requiring a full addon upsert. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/configurepsneventstreams + */ + ConfigurePSNEventStreams(request: PlayFabAddonModels.ConfigurePSNEventStreamsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Apple addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdateapple + */ + CreateOrUpdateApple(request: PlayFabAddonModels.CreateOrUpdateAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Facebook addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatefacebook + */ + CreateOrUpdateFacebook(request: PlayFabAddonModels.CreateOrUpdateFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Facebook Instant Games addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatefacebookinstantgames + */ + CreateOrUpdateFacebookInstantGames(request: PlayFabAddonModels.CreateOrUpdateFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Google addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdategoogle + */ + CreateOrUpdateGoogle(request: PlayFabAddonModels.CreateOrUpdateGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Kongregate addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatekongregate + */ + CreateOrUpdateKongregate(request: PlayFabAddonModels.CreateOrUpdateKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Nintendo addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatenintendo + */ + CreateOrUpdateNintendo(request: PlayFabAddonModels.CreateOrUpdateNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the PSN addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatepsn + */ + CreateOrUpdatePSN(request: PlayFabAddonModels.CreateOrUpdatePSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Steam addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatesteam + */ + CreateOrUpdateSteam(request: PlayFabAddonModels.CreateOrUpdateSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the ToxMod addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatetoxmod + */ + CreateOrUpdateToxMod(request: PlayFabAddonModels.CreateOrUpdateToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates the Twitch addon on a title, or updates it if it already exists. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/createorupdatetwitch + */ + CreateOrUpdateTwitch(request: PlayFabAddonModels.CreateOrUpdateTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Apple addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deleteapple + */ + DeleteApple(request: PlayFabAddonModels.DeleteAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Facebook addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletefacebook + */ + DeleteFacebook(request: PlayFabAddonModels.DeleteFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Facebook addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletefacebookinstantgames + */ + DeleteFacebookInstantGames(request: PlayFabAddonModels.DeleteFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Google addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletegoogle + */ + DeleteGoogle(request: PlayFabAddonModels.DeleteGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Kongregate addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletekongregate + */ + DeleteKongregate(request: PlayFabAddonModels.DeleteKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Nintendo addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletenintendo + */ + DeleteNintendo(request: PlayFabAddonModels.DeleteNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the PSN addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletepsn + */ + DeletePSN(request: PlayFabAddonModels.DeletePSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Steam addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletesteam + */ + DeleteSteam(request: PlayFabAddonModels.DeleteSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the ToxMod addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletetoxmod + */ + DeleteToxMod(request: PlayFabAddonModels.DeleteToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the Twitch addon on a title. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/deletetwitch + */ + DeleteTwitch(request: PlayFabAddonModels.DeleteTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Apple addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getapple + */ + GetApple(request: PlayFabAddonModels.GetAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Facebook addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getfacebook + */ + GetFacebook(request: PlayFabAddonModels.GetFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Facebook Instant Games addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getfacebookinstantgames + */ + GetFacebookInstantGames(request: PlayFabAddonModels.GetFacebookInstantGamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Google addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getgoogle + */ + GetGoogle(request: PlayFabAddonModels.GetGoogleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Kongregate addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getkongregate + */ + GetKongregate(request: PlayFabAddonModels.GetKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Nintendo addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getnintendo + */ + GetNintendo(request: PlayFabAddonModels.GetNintendoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the PSN addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getpsn + */ + GetPSN(request: PlayFabAddonModels.GetPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Steam addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/getsteam + */ + GetSteam(request: PlayFabAddonModels.GetSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the ToxMod addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/gettoxmod + */ + GetToxMod(request: PlayFabAddonModels.GetToxModRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information of the Twitch addon on a title, omits secrets. + * https://docs.microsoft.com/rest/api/playfab/addon/addon/gettwitch + */ + GetTwitch(request: PlayFabAddonModels.GetTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabAddonModels { + export interface ConfigurePSNEventStreamsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Title name obtained after setting a back server for PS5. Used for clawback event listeners. */ + TitleName?: string; + + } + + export interface ConfigurePSNEventStreamsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Allow validation of receipts from the Apple production environment. Required for app releases. */ + AllowProduction?: boolean; + /** Allow validation of receipts from the Apple sandbox environment. Typically used while testing. */ + AllowSandbox?: boolean; + /** iOS App Bundle ID obtained after setting up your app in the App Store. */ + AppBundleId: string; + /** AppId obtained after setting up your app in the App Store. */ + AppId?: string; + /** iOS App Shared Secret obtained after setting up your app in the App Store. */ + AppSharedSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Ignore expiration date for identity tokens. Be aware that when set to true this can invalidate expired tokens in the + * case where Apple rotates their signing keys. + */ + IgnoreExpirationDate?: boolean; + /** IssuerId obtained after setting up your app in the App Store. */ + IssuerId?: string; + /** KeyId obtained after setting up your app in the App Store. */ + KeyId?: string; + /** PrivateKey obtained after setting up your app in the App Store. */ + PrivateKey?: string; + /** Require secure authentication only for this app. */ + RequireSecureAuthentication?: boolean; + + } + + export interface CreateOrUpdateAppleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Facebook App ID obtained after setting up your app in Facebook Instant Games. */ + AppID: string; + /** Facebook App Secret obtained after setting up your app in Facebook Instant Games. */ + AppSecret: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Facebook App ID obtained after setting up your app in Facebook. */ + AppID: string; + /** Facebook App Secret obtained after setting up your app in Facebook. */ + AppSecret: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Email address for purchase dispute notifications. */ + NotificationEmail: string; + + } + + export interface CreateOrUpdateFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Google App License Key obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppLicenseKey?: string; + /** + * Google App Package ID obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppPackageID?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Google OAuth Client ID obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientID?: string; + /** + * Google OAuth Client Secret obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientSecret?: string; + /** + * Authorized Redirect Uri obtained through the Google Developer Console. This currently defaults to + * https://oauth.playfab.com/oauth2/google. If you are authenticating players via browser, please update this to your own + * domain. + */ + OAuthCustomRedirectUri?: string; + /** Needed to enable pending purchase handling and subscription processing. */ + ServiceAccountKey?: string; + + } + + export interface CreateOrUpdateGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Kongregate Secret API Key obtained after setting up your game in your Kongregate developer account. */ + SecretAPIKey: string; + + } + + export interface CreateOrUpdateKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Nintendo Switch Application ID, without the "0x" prefix. */ + ApplicationID?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** List of Nintendo Environments, currently supporting up to 4. Needs Catalog enabled. */ + Environments?: NintendoEnvironment[]; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** List of Nintendo Subscription Environments, currently supporting up to 4. Needs Catalog enabled. */ + SubscriptionEnvironments?: NintendoEnvironment[]; + + } + + export interface CreateOrUpdateNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdatePSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Client ID obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientID?: string; + /** Client secret obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** + * Client ID obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientID?: string; + /** + * Client secret obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientSecret?: string; + + } + + export interface CreateOrUpdatePSNResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Application ID obtained after setting up your app in Valve's developer portal. */ + ApplicationId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Enforce usage of AzurePlayFab identity in user authentication tickets. */ + EnforceServiceSpecificTickets?: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + /** Sercet Key obtained after setting up your app in Valve's developer portal. */ + SecretKey: string; + /** Use Steam Payments sandbox endpoint for test transactions. */ + UseSandbox?: boolean; + + } + + export interface CreateOrUpdateSteamResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Account ID obtained after creating your ToxMod developer account. */ + AccountId: string; + /** Account Key obtained after creating your ToxMod developer account. */ + AccountKey: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Whether ToxMod Addon is Enabled by Title. */ + Enabled: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateToxModResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CreateOrUpdateTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Client ID obtained after creating your Twitch developer account. */ + ClientID?: string; + /** Client Secret obtained after creating your Twitch developer account. */ + ClientSecret?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** If an error should be returned if the addon already exists. */ + ErrorIfExists?: boolean; + + } + + export interface CreateOrUpdateTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteAppleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeletePSNResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteSteamResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteToxModResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface DeleteTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface GetAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetAppleResponse extends PlayFabModule.IPlayFabResultCommon { + /** iOS App Bundle ID obtained after setting up your app in the App Store. */ + AppBundleId?: string; + /** Addon status. */ + Created: boolean; + /** Ignore expiration date for identity tokens. */ + IgnoreExpirationDate?: boolean; + /** Require secure authentication only for this app. */ + RequireSecureAuthentication?: boolean; + + } + + export interface GetFacebookInstantGamesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetFacebookInstantGamesResponse extends PlayFabModule.IPlayFabResultCommon { + /** Facebook App ID obtained after setting up your app in Facebook Instant Games. */ + AppID?: string; + /** Addon status. */ + Created: boolean; + + } + + export interface GetFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetFacebookResponse extends PlayFabModule.IPlayFabResultCommon { + /** Facebook App ID obtained after setting up your app in Facebook. */ + AppID?: string; + /** Addon status. */ + Created: boolean; + /** Email address for purchase dispute notifications. */ + NotificationEmail?: string; + + } + + export interface GetGoogleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetGoogleResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * Google App Package ID obtained after setting up your app in the Google Play developer portal. Required if using Google + * receipt validation. + */ + AppPackageID?: string; + /** Addon status. */ + Created: boolean; + /** + * Google OAuth Client ID obtained through the Google Developer Console by creating a new set of "OAuth Client ID". + * Required if using Google Authentication. + */ + OAuthClientID?: string; + /** + * Authorized Redirect Uri obtained through the Google Developer Console. This currently defaults to + * https://oauth.playfab.com/oauth2/google. If you are authenticating players via browser, please update this to your own + * domain. + */ + OauthCustomRedirectUri?: string; + + } + + export interface GetKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetKongregateResponse extends PlayFabModule.IPlayFabResultCommon { + /** Addon status. */ + Created: boolean; + + } + + export interface GetNintendoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetNintendoResponse extends PlayFabModule.IPlayFabResultCommon { + /** Nintendo Switch Application ID, without the "0x" prefix. */ + ApplicationID?: string; + /** Addon status. */ + Created: boolean; + /** List of Nintendo Environments, currently supporting up to 4. */ + Environments?: NintendoEnvironment[]; + /** List of Nintendo Subscription Environments associated to a secondary AppId, currently supporting up to 4. */ + SecondarySubscriptionEnvironments?: NintendoEnvironment[]; + /** List of Nintendo Subscription Environments, currently supporting up to 4. */ + SubscriptionEnvironments?: NintendoEnvironment[]; + + } + + export interface GetPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetPSNResponse extends PlayFabModule.IPlayFabResultCommon { + /** Client ID obtained after setting up your game with Sony. This one is associated with the existing PS4 marketplace. */ + ClientID?: string; + /** Addon status. */ + Created: boolean; + /** + * Client ID obtained after setting up your game with Sony. This one is associated with the modern marketplace, which + * includes PS5, cross-generation for PS4, and unified entitlements. + */ + NextGenClientID?: string; + + } + + export interface GetSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetSteamResponse extends PlayFabModule.IPlayFabResultCommon { + /** Application ID obtained after setting up your game in Valve's developer portal. */ + ApplicationId?: string; + /** Addon status. */ + Created: boolean; + /** Enforce usage of AzurePlayFab identity in user authentication tickets. */ + EnforceServiceSpecificTickets?: boolean; + /** Use Steam Payments sandbox endpoint for test transactions. */ + UseSandbox?: boolean; + + } + + export interface GetToxModRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetToxModResponse extends PlayFabModule.IPlayFabResultCommon { + /** Account ID obtained after creating your Twitch developer account. */ + AccountId?: string; + /** Account Key obtained after creating your Twitch developer account. */ + AccountKey?: string; + /** Addon status. */ + Created: boolean; + /** Whether the ToxMod Addon is enabled by the title. */ + Enabled: boolean; + + } + + export interface GetTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetTwitchResponse extends PlayFabModule.IPlayFabResultCommon { + /** Client ID obtained after creating your Twitch developer account. */ + ClientID?: string; + /** Addon status. */ + Created: boolean; + + } + + export interface NintendoEnvironment { + /** Client ID for the Nintendo Environment. */ + ClientID?: string; + /** Client Secret for the Nintendo Environment. */ + ClientSecret?: string; + /** ID for the Nintendo Environment. */ + ID?: string; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabAdminApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAdminApi.d.ts index 1ce76ba8..46869cef 100644 --- a/PlayFabTestingExample/src/typings/PlayFab/PlayFabAdminApi.d.ts +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAdminApi.d.ts @@ -2,1090 +2,1175 @@ declare module PlayFabAdminModule { export interface IPlayFabAdmin { + ForgetAllCredentials(): void; + /** - / Gets the requested policy. - / https://api.playfab.com/Documentation/Admin/method/GetPolicy + * Abort an ongoing task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/aborttaskinstance */ - GetPolicy(request: PlayFabAdminModels.GetPolicyRequest, callback: PlayFabModule.ApiCallback): void; + AbortTaskInstance(request: PlayFabAdminModels.AbortTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Changes a policy for a title - / https://api.playfab.com/Documentation/Admin/method/UpdatePolicy + * Update news item to include localized version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addlocalizednews */ - UpdatePolicy(request: PlayFabAdminModels.UpdatePolicyRequest, callback: PlayFabModule.ApiCallback): void; + AddLocalizedNews(request: PlayFabAdminModels.AddLocalizedNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Bans users by PlayFab ID with optional IP address, or MAC address for the provided game. - / https://api.playfab.com/Documentation/Admin/method/BanUsers + * Adds a new news item to the title's news feed + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addnews */ - BanUsers(request: PlayFabAdminModels.BanUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddNews(request: PlayFabAdminModels.AddNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the relevant details for a specified user, based upon a match against a supplied unique identifier - / https://api.playfab.com/Documentation/Admin/method/GetUserAccountInfo + * Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/addplayertag */ - GetUserAccountInfo(request: PlayFabAdminModels.LookupUserAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + AddPlayerTag(request: PlayFabAdminModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all bans for a user. - / https://api.playfab.com/Documentation/Admin/method/GetUserBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/adduservirtualcurrency */ - GetUserBans(request: PlayFabAdminModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback): void; + AddUserVirtualCurrency(request: PlayFabAdminModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Resets all title-specific information about a particular account, including user data, virtual currency balances, inventory, purchase history, and statistics - / https://api.playfab.com/Documentation/Admin/method/ResetUsers + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds one or more virtual currencies to the set defined for the title. Virtual Currencies have a maximum + * value of 2,147,483,647 when granted to a player. Any value over that will be discarded. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/addvirtualcurrencytypes */ - ResetUsers(request: PlayFabAdminModels.ResetUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddVirtualCurrencyTypes(request: PlayFabAdminModels.AddVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans for a user. - / https://api.playfab.com/Documentation/Admin/method/RevokeAllBansForUser + * Bans users by PlayFab ID with optional IP address for the provided game. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/banusers */ - RevokeAllBansForUser(request: PlayFabAdminModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback): void; + BanUsers(request: PlayFabAdminModels.BanUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans specified with BanId. - / https://api.playfab.com/Documentation/Admin/method/RevokeBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Checks the global count for the limited edition item. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/checklimitededitionitemavailability */ - RevokeBans(request: PlayFabAdminModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback): void; + CheckLimitedEditionItemAvailability(request: PlayFabAdminModels.CheckLimitedEditionItemAvailabilityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Forces an email to be sent to the registered email address for the specified account, with a link allowing the user to change the password - / https://api.playfab.com/Documentation/Admin/method/SendAccountRecoveryEmail + * Create an ActionsOnPlayersInSegment task, which iterates through all players in a segment to execute action. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createactionsonplayersinsegmenttask */ - SendAccountRecoveryEmail(request: PlayFabAdminModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback): void; + CreateActionsOnPlayersInSegmentTask(request: PlayFabAdminModels.CreateActionsOnPlayerSegmentTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates information of a list of existing bans specified with Ban Ids. - / https://api.playfab.com/Documentation/Admin/method/UpdateBans + * Create a CloudScript task, which can run a CloudScript on a schedule. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createcloudscripttask */ - UpdateBans(request: PlayFabAdminModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback): void; + CreateCloudScriptTask(request: PlayFabAdminModels.CreateCloudScriptTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title specific display name for a user - / https://api.playfab.com/Documentation/Admin/method/UpdateUserTitleDisplayName + * Create a Insights Scheduled Scaling task, which can scale Insights Performance Units on a schedule + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/createinsightsscheduledscalingtask */ - UpdateUserTitleDisplayName(request: PlayFabAdminModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback): void; + CreateInsightsScheduledScalingTask(request: PlayFabAdminModels.CreateInsightsScheduledScalingTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a new player statistic configuration to the title, optionally allowing the developer to specify a reset interval and an aggregation method. - / https://api.playfab.com/Documentation/Admin/method/CreatePlayerStatisticDefinition + * Bans an IP address or CIDR range for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/createipban */ - CreatePlayerStatisticDefinition(request: PlayFabAdminModels.CreatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback): void; + CreateIPBan(request: PlayFabAdminModels.CreateIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the users for the provided game. Deletes custom data, all account linkages, and statistics. This method does not remove the player's event history, login history, inventory items, nor virtual currencies. - / https://api.playfab.com/Documentation/Admin/method/DeleteUsers + * Registers a relationship between a title and an Open ID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/createopenidconnection */ - DeleteUsers(request: PlayFabAdminModels.DeleteUsersRequest, callback: PlayFabModule.ApiCallback): void; + CreateOpenIdConnection(request: PlayFabAdminModels.CreateOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a download URL for the requested report - / https://api.playfab.com/Documentation/Admin/method/GetDataReport + * Creates a new Player Shared Secret Key. It may take up to 5 minutes for this key to become generally available after + * this API returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/createplayersharedsecret */ - GetDataReport(request: PlayFabAdminModels.GetDataReportRequest, callback: PlayFabModule.ApiCallback): void; + CreatePlayerSharedSecret(request: PlayFabAdminModels.CreatePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the configuration information for all player statistics defined in the title, regardless of whether they have a reset interval. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerStatisticDefinitions + * Adds a new player statistic configuration to the title, optionally allowing the developer to specify a reset interval + * and an aggregation method. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/createplayerstatisticdefinition */ - GetPlayerStatisticDefinitions(request: PlayFabAdminModels.GetPlayerStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback): void; + CreatePlayerStatisticDefinition(request: PlayFabAdminModels.CreatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerStatisticVersions + * Creates a new player segment by defining the conditions on player properties. Also, create actions to target the player + * segments for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/createsegment */ - GetPlayerStatisticVersions(request: PlayFabAdminModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + CreateSegment(request: PlayFabAdminModels.CreateSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserData + * Delete a content file from the title. When deleting a file that does not exist, it returns success. + * https://docs.microsoft.com/rest/api/playfab/admin/content/deletecontent */ - GetUserData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteContent(request: PlayFabAdminModels.DeleteContentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserInternalData + * Removes a master player account entirely from all titles and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemasterplayeraccount */ - GetUserInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMasterPlayerAccount(request: PlayFabAdminModels.DeleteMasterPlayerAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherData + * Deletes PlayStream and telemetry event data associated with the master player account from PlayFab storage + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemasterplayereventdata */ - GetUserPublisherData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMasterPlayerEventData(request: PlayFabAdminModels.DeleteMasterPlayerEventDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherInternalData + * Deletes a player's subscription + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletemembershipsubscription */ - GetUserPublisherInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteMembershipSubscription(request: PlayFabAdminModels.DeleteMembershipSubscriptionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserPublisherReadOnlyData + * Removes a relationship between a title and an OpenID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/deleteopenidconnection */ - GetUserPublisherReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteOpenIdConnection(request: PlayFabAdminModels.DeleteOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetUserReadOnlyData + * Removes a user's player account from a title and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deleteplayer */ - GetUserReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayer(request: PlayFabAdminModels.DeletePlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Resets the indicated statistic, removing all player entries for it and backing up the old values. - / https://api.playfab.com/Documentation/Admin/method/IncrementPlayerStatisticVersion + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/deleteplayercustomproperties */ - IncrementPlayerStatisticVersion(request: PlayFabAdminModels.IncrementPlayerStatisticVersionRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerCustomProperties(request: PlayFabAdminModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to process an order refund through the original real money payment provider. - / https://api.playfab.com/Documentation/Admin/method/RefundPurchase + * Deletes an existing Player Shared Secret Key. It may take up to 5 minutes for this delete to be reflected after this API + * returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/deleteplayersharedsecret */ - RefundPurchase(request: PlayFabAdminModels.RefundPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerSharedSecret(request: PlayFabAdminModels.DeletePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completely removes all statistics for the specified user, for the current game - / https://api.playfab.com/Documentation/Admin/method/ResetUserStatistics + * Deletes an existing player segment and its associated action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/deletesegment */ - ResetUserStatistics(request: PlayFabAdminModels.ResetUserStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + DeleteSegment(request: PlayFabAdminModels.DeleteSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to resolve a dispute with the original order's payment provider. - / https://api.playfab.com/Documentation/Admin/method/ResolvePurchaseDispute + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Deletes an existing virtual item store + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/deletestore */ - ResolvePurchaseDispute(request: PlayFabAdminModels.ResolvePurchaseDisputeRequest, callback: PlayFabModule.ApiCallback): void; + DeleteStore(request: PlayFabAdminModels.DeleteStoreRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates a player statistic configuration for the title, optionally allowing the developer to specify a reset interval. - / https://api.playfab.com/Documentation/Admin/method/UpdatePlayerStatisticDefinition + * Delete a task. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/deletetask */ - UpdatePlayerStatisticDefinition(request: PlayFabAdminModels.UpdatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTask(request: PlayFabAdminModels.DeleteTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserData + * Permanently deletes a title and all associated configuration + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/deletetitle */ - UpdateUserData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTitle(request: PlayFabAdminModels.DeleteTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserInternalData + * Deletes a specified set of title data overrides. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/deletetitledataoverride */ - UpdateUserInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + DeleteTitleDataOverride(request: PlayFabAdminModels.DeleteTitleDataOverrideRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherData + * Exports all associated data of a master player account + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/exportmasterplayerdata */ - UpdateUserPublisherData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportMasterPlayerData(request: PlayFabAdminModels.ExportMasterPlayerDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherInternalData + * Starts an export for the player profiles in a segment. This API creates a snapshot of all the player profiles which + * match the segment definition at the time of the API call. Profiles which change while an export is in progress will not + * be reflected in the results. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/exportplayersinsegment */ - UpdateUserPublisherInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportPlayersInSegment(request: PlayFabAdminModels.ExportPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserPublisherReadOnlyData + * Get information about a ActionsOnPlayersInSegment task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/getactionsonplayersinsegmenttaskinstance */ - UpdateUserPublisherReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetActionsOnPlayersInSegmentTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Admin/method/UpdateUserReadOnlyData + * Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as + * ExportPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not + * change. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getallsegments */ - UpdateUserReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllSegments(request: PlayFabAdminModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a new news item to the title's news feed - / https://api.playfab.com/Documentation/Admin/method/AddNews + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getcatalogitems */ - AddNews(request: PlayFabAdminModels.AddNewsRequest, callback: PlayFabModule.ApiCallback): void; + GetCatalogItems(request: PlayFabAdminModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds one or more virtual currencies to the set defined for the title. Virtual Currencies have a maximum value of 2,147,483,647 when granted to a player. Any value over that will be discarded. - / https://api.playfab.com/Documentation/Admin/method/AddVirtualCurrencyTypes + * Gets the contents and information of a specific Cloud Script revision. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/getcloudscriptrevision */ - AddVirtualCurrencyTypes(request: PlayFabAdminModels.AddVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptRevision(request: PlayFabAdminModels.GetCloudScriptRevisionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes an existing virtual item store - / https://api.playfab.com/Documentation/Admin/method/DeleteStore + * Get detail information about a CloudScript task instance. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/getcloudscripttaskinstance */ - DeleteStore(request: PlayFabAdminModels.DeleteStoreRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Admin/method/GetCatalogItems + * Lists all the current cloud script versions. For each version, information about the current published and latest + * revisions is also listed. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/getcloudscriptversions */ - GetCatalogItems(request: PlayFabAdminModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetCloudScriptVersions(request: PlayFabAdminModels.GetCloudScriptVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Admin/method/GetPublisherData + * List all contents of the title and get statistics such as size + * https://docs.microsoft.com/rest/api/playfab/admin/content/getcontentlist */ - GetPublisherData(request: PlayFabAdminModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetContentList(request: PlayFabAdminModels.GetContentListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the random drop table configuration for the title - / https://api.playfab.com/Documentation/Admin/method/GetRandomResultTables + * Retrieves the pre-signed URL for uploading a content file. A subsequent HTTP PUT to the returned URL uploads the + * content. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN + * rates apply. + * https://docs.microsoft.com/rest/api/playfab/admin/content/getcontentuploadurl */ - GetRandomResultTables(request: PlayFabAdminModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetContentUploadUrl(request: PlayFabAdminModels.GetContentUploadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the set of items defined for the specified store, including all prices defined - / https://api.playfab.com/Documentation/Admin/method/GetStoreItems + * Retrieves a download URL for the requested report + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getdatareport */ - GetStoreItems(request: PlayFabAdminModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetDataReport(request: PlayFabAdminModels.GetDataReportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings which can be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetTitleData + * Gets all IP bans that apply to a specific IP address. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getipbansforip */ - GetTitleData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetIPBansForIP(request: PlayFabAdminModels.GetIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings which cannot be read by the client - / https://api.playfab.com/Documentation/Admin/method/GetTitleInternalData + * Gets all IP bans for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getipbansfortitle */ - GetTitleInternalData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetIPBansForTitle(request: PlayFabAdminModels.GetAllIPBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retuns the list of all defined virtual currencies for the title - / https://api.playfab.com/Documentation/Admin/method/ListVirtualCurrencyTypes + * Get the list of titles that the player has played + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayedtitlelist */ - ListVirtualCurrencyTypes(request: PlayFabAdminModels.ListVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayedTitleList(request: PlayFabAdminModels.GetPlayedTitleListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes one or more virtual currencies from the set defined for the title. - / https://api.playfab.com/Documentation/Admin/method/RemoveVirtualCurrencyTypes + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayercustomproperty */ - RemoveVirtualCurrencyTypes(request: PlayFabAdminModels.RemoveVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCustomProperty(request: PlayFabAdminModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates the catalog configuration of all virtual goods for the specified catalog version - / https://api.playfab.com/Documentation/Admin/method/SetCatalogItems + * Gets a player's ID from an auth token. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayeridfromauthtoken */ - SetCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerIdFromAuthToken(request: PlayFabAdminModels.GetPlayerIdFromAuthTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets all the items in one virtual store - / https://api.playfab.com/Documentation/Admin/method/SetStoreItems + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getplayerprofile */ - SetStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerProfile(request: PlayFabAdminModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the key-value store of custom title settings which can be read by the client - / https://api.playfab.com/Documentation/Admin/method/SetTitleData + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getplayersegments */ - SetTitleData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSegments(request: PlayFabAdminModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings which cannot be read by the client - / https://api.playfab.com/Documentation/Admin/method/SetTitleInternalData + * Returns all Player Shared Secret Keys including disabled and expired. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/getplayersharedsecrets */ - SetTitleInternalData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSharedSecrets(request: PlayFabAdminModels.GetPlayerSharedSecretsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the Amazon Resource Name (ARN) for iOS and Android push notifications. Documentation on the exact restrictions can be found at: http://docs.aws.amazon.com/sns/latest/api/API_CreatePlatformApplication.html. Currently, Amazon device Messaging is not supported. - / https://api.playfab.com/Documentation/Admin/method/SetupPushNotification + * Retrieves the configuration information for all player statistics defined in the title, regardless of whether they have + * a reset interval. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayerstatisticdefinitions */ - SetupPushNotification(request: PlayFabAdminModels.SetupPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticDefinitions(request: PlayFabAdminModels.GetPlayerStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the catalog configuration for virtual goods in the specified catalog version - / https://api.playfab.com/Documentation/Admin/method/UpdateCatalogItems + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getplayerstatisticversions */ - UpdateCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticVersions(request: PlayFabAdminModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the random drop table configuration for the title - / https://api.playfab.com/Documentation/Admin/method/UpdateRandomResultTables + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getplayertags */ - UpdateRandomResultTables(request: PlayFabAdminModels.UpdateRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerTags(request: PlayFabAdminModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates an existing virtual item store with new or modified items - / https://api.playfab.com/Documentation/Admin/method/UpdateStoreItems + * Gets the requested policy. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/getpolicy */ - UpdateStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetPolicy(request: PlayFabAdminModels.GetPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Admin/method/AddUserVirtualCurrency + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getpublisherdata */ - AddUserVirtualCurrency(request: PlayFabAdminModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabAdminModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Admin/method/GetUserInventory + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the random drop table configuration for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getrandomresulttables */ - GetUserInventory(request: PlayFabAdminModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetRandomResultTables(request: PlayFabAdminModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user inventories - / https://api.playfab.com/Documentation/Admin/method/GrantItemsToUsers + * Retrieves the result of an export started by ExportPlayersInSegment API. If the ExportPlayersInSegment is successful and + * complete, this API returns the IndexUrl from which the index file can be downloaded. The index file has a list of urls + * from which the files containing the player profile data can be downloaded. Otherwise, it returns the current 'State' of + * the export + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getsegmentexport */ - GrantItemsToUsers(request: PlayFabAdminModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentExport(request: PlayFabAdminModels.GetPlayersInSegmentExportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revokes access to an item in a user's inventory - / https://api.playfab.com/Documentation/Admin/method/RevokeInventoryItem + * Returns the total number of players in a given segment. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/getsegmentplayercount */ - RevokeInventoryItem(request: PlayFabAdminModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentPlayerCount(request: PlayFabAdminModels.GetSegmentPlayerCountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Admin/method/SubtractUserVirtualCurrency + * Get detail information of a segment and its associated definition(s) and action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/getsegments */ - SubtractUserVirtualCurrency(request: PlayFabAdminModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetSegments(request: PlayFabAdminModels.GetSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details for a specific completed session, including links to standard out and standard error logs - / https://api.playfab.com/Documentation/Admin/method/GetMatchmakerGameInfo + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/getstoreitems */ - GetMatchmakerGameInfo(request: PlayFabAdminModels.GetMatchmakerGameInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabAdminModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of defined game modes for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/GetMatchmakerGameModes + * Query for task instances by task, status, or time range. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/gettaskinstances */ - GetMatchmakerGameModes(request: PlayFabAdminModels.GetMatchmakerGameModesRequest, callback: PlayFabModule.ApiCallback): void; + GetTaskInstances(request: PlayFabAdminModels.GetTaskInstancesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the game server mode details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/ModifyMatchmakerGameModes + * Get definition information on a specified task or all tasks within a title. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/gettasks */ - ModifyMatchmakerGameModes(request: PlayFabAdminModels.ModifyMatchmakerGameModesRequest, callback: PlayFabModule.ApiCallback): void; + GetTasks(request: PlayFabAdminModels.GetTasksRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the game server executable specified (previously uploaded - see GetServerBuildUploadUrl) to the set of those a client is permitted to request in a call to StartGame - / https://api.playfab.com/Documentation/Admin/method/AddServerBuild + * Retrieves the key-value store of custom title settings which can be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/gettitledata */ - AddServerBuild(request: PlayFabAdminModels.AddServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the build details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/GetServerBuildInfo + * Retrieves the key-value store of custom title settings which cannot be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/gettitleinternaldata */ - GetServerBuildInfo(request: PlayFabAdminModels.GetServerBuildInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleInternalData(request: PlayFabAdminModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the pre-authorized URL for uploading a game server package containing a build (does not enable the build for use - see AddServerBuild) - / https://api.playfab.com/Documentation/Admin/method/GetServerBuildUploadUrl + * Retrieves the relevant details for a specified user, based upon a match against a supplied unique identifier + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getuseraccountinfo */ - GetServerBuildUploadUrl(request: PlayFabAdminModels.GetServerBuildUploadURLRequest, callback: PlayFabModule.ApiCallback): void; + GetUserAccountInfo(request: PlayFabAdminModels.LookupUserAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the build details for all game server executables which are currently defined for the title - / https://api.playfab.com/Documentation/Admin/method/ListServerBuilds + * Gets all bans for a user. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/getuserbans */ - ListServerBuilds(request: PlayFabAdminModels.ListBuildsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserBans(request: PlayFabAdminModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the build details for the specified game server executable - / https://api.playfab.com/Documentation/Admin/method/ModifyServerBuild + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserdata */ - ModifyServerBuild(request: PlayFabAdminModels.ModifyServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the game server executable specified from the set of those a client is permitted to request in a call to StartGame - / https://api.playfab.com/Documentation/Admin/method/RemoveServerBuild + * Retrieves the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserinternaldata */ - RemoveServerBuild(request: PlayFabAdminModels.RemoveServerBuildRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Admin/method/SetPublisherData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/getuserinventory */ - SetPublisherData(request: PlayFabAdminModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabAdminModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets the contents and information of a specific Cloud Script revision. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptRevision + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherdata */ - GetCloudScriptRevision(request: PlayFabAdminModels.GetCloudScriptRevisionRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all the current cloud script versions. For each version, information about the current published and latest revisions is also listed. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptVersions + * Retrieves the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherinternaldata */ - GetCloudScriptVersions(request: PlayFabAdminModels.GetCloudScriptVersionsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherInternalData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the currently published revision of a title Cloud Script - / https://api.playfab.com/Documentation/Admin/method/SetPublishedRevision + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserpublisherreadonlydata */ - SetPublishedRevision(request: PlayFabAdminModels.SetPublishedRevisionRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates a new Cloud Script revision and uploads source code to it. Note that at this time, only one file should be submitted in the revision. - / https://api.playfab.com/Documentation/Admin/method/UpdateCloudScript + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/getuserreadonlydata */ - UpdateCloudScript(request: PlayFabAdminModels.UpdateCloudScriptRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabAdminModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Delete a content file from the title - / https://api.playfab.com/Documentation/Admin/method/DeleteContent + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user inventories + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/grantitemstousers */ - DeleteContent(request: PlayFabAdminModels.DeleteContentRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUsers(request: PlayFabAdminModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all contents of the title and get statistics such as size - / https://api.playfab.com/Documentation/Admin/method/GetContentList + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increases the global count for the given scarce resource. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/incrementlimitededitionitemavailability */ - GetContentList(request: PlayFabAdminModels.GetContentListRequest, callback: PlayFabModule.ApiCallback): void; + IncrementLimitedEditionItemAvailability(request: PlayFabAdminModels.IncrementLimitedEditionItemAvailabilityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the pre-signed URL for uploading a content file. A subsequent HTTP PUT to the returned URL uploads the content. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Admin/method/GetContentUploadUrl + * Resets the indicated statistic, removing all player entries for it and backing up the old values. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/incrementplayerstatisticversion */ - GetContentUploadUrl(request: PlayFabAdminModels.GetContentUploadUrlRequest, callback: PlayFabModule.ApiCallback): void; + IncrementPlayerStatisticVersion(request: PlayFabAdminModels.IncrementPlayerStatisticVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completely removes all statistics for the specified character, for the current game - / https://api.playfab.com/Documentation/Admin/method/ResetCharacterStatistics + * Retrieves a list of all Open ID Connect providers registered to a title. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/listopenidconnection */ - ResetCharacterStatistics(request: PlayFabAdminModels.ResetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + ListOpenIdConnection(request: PlayFabAdminModels.ListOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Admin/method/AddPlayerTag + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/listplayercustomproperties */ - AddPlayerTag(request: PlayFabAdminModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabAdminModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieve a list of all PlayStream actions groups. - / https://api.playfab.com/Documentation/Admin/method/GetAllActionGroups + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retuns the list of all defined virtual currencies for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/listvirtualcurrencytypes */ - GetAllActionGroups(request: PlayFabAdminModels.GetAllActionGroupsRequest, callback: PlayFabModule.ApiCallback): void; + ListVirtualCurrencyTypes(request: PlayFabAdminModels.ListVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as GetPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not change. - / https://api.playfab.com/Documentation/Admin/method/GetAllSegments + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Attempts to process an order refund through the original real money payment provider. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/refundpurchase */ - GetAllSegments(request: PlayFabAdminModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + RefundPurchase(request: PlayFabAdminModels.RefundPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerSegments + * Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/admin/playstream/removeplayertag */ - GetPlayerSegments(request: PlayFabAdminModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + RemovePlayerTag(request: PlayFabAdminModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Allows for paging through all players in a given segment. This API creates a snapshot of all player profiles that match the segment definition at the time of its creation and lives through the Total Seconds to Live, refreshing its life span on each subsequent use of the Continuation Token. Profiles that change during the course of paging will not be reflected in the results. AB Test segments are currently not supported by this operation. - / https://api.playfab.com/Documentation/Admin/method/GetPlayersInSegment + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Removes one or more virtual currencies from the set defined for the title. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/removevirtualcurrencytypes */ - GetPlayersInSegment(request: PlayFabAdminModels.GetPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback): void; + RemoveVirtualCurrencyTypes(request: PlayFabAdminModels.RemoveVirtualCurrencyTypesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Admin/method/GetPlayerTags + * Completely removes all statistics for the specified character, for the current game + * https://docs.microsoft.com/rest/api/playfab/admin/characters/resetcharacterstatistics */ - GetPlayerTags(request: PlayFabAdminModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + ResetCharacterStatistics(request: PlayFabAdminModels.ResetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Admin/method/RemovePlayerTag + * Reset a player's password for a given title. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/resetpassword */ - RemovePlayerTag(request: PlayFabAdminModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + ResetPassword(request: PlayFabAdminModels.ResetPasswordRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Abort an ongoing task instance. - / https://api.playfab.com/Documentation/Admin/method/AbortTaskInstance + * Completely removes all statistics for the specified user, for the current game + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/resetuserstatistics */ - AbortTaskInstance(request: PlayFabAdminModels.AbortTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + ResetUserStatistics(request: PlayFabAdminModels.ResetUserStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Create an ActionsOnPlayersInSegment task, which iterates through all players in a segment to execute action. - / https://api.playfab.com/Documentation/Admin/method/CreateActionsOnPlayersInSegmentTask + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Attempts to resolve a dispute with the original order's payment provider. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/resolvepurchasedispute */ - CreateActionsOnPlayersInSegmentTask(request: PlayFabAdminModels.CreateActionsOnPlayerSegmentTaskRequest, callback: PlayFabModule.ApiCallback): void; + ResolvePurchaseDispute(request: PlayFabAdminModels.ResolvePurchaseDisputeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Create a CloudScript task, which can run a CloudScript on a schedule. - / https://api.playfab.com/Documentation/Admin/method/CreateCloudScriptTask + * Revoke all active bans for a user. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokeallbansforuser */ - CreateCloudScriptTask(request: PlayFabAdminModels.CreateCloudScriptTaskRequest, callback: PlayFabModule.ApiCallback): void; + RevokeAllBansForUser(request: PlayFabAdminModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Delete a task. - / https://api.playfab.com/Documentation/Admin/method/DeleteTask + * Revoke all active bans specified with BanId. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokebans */ - DeleteTask(request: PlayFabAdminModels.DeleteTaskRequest, callback: PlayFabModule.ApiCallback): void; + RevokeBans(request: PlayFabAdminModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get information about a ActionsOnPlayersInSegment task instance. - / https://api.playfab.com/Documentation/Admin/method/GetActionsOnPlayersInSegmentTaskInstance + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access to an item in a user's inventory + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/revokeinventoryitem */ - GetActionsOnPlayersInSegmentTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + RevokeInventoryItem(request: PlayFabAdminModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get detail information about a CloudScript task instance. - / https://api.playfab.com/Documentation/Admin/method/GetCloudScriptTaskInstance + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access for up to 25 items across multiple users and characters. + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/revokeinventoryitems */ - GetCloudScriptTaskInstance(request: PlayFabAdminModels.GetTaskInstanceRequest, callback: PlayFabModule.ApiCallback): void; + RevokeInventoryItems(request: PlayFabAdminModels.RevokeInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Query for task instances by task, status, or time range. - / https://api.playfab.com/Documentation/Admin/method/GetTaskInstances + * Revokes an active IP ban. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/revokeipban */ - GetTaskInstances(request: PlayFabAdminModels.GetTaskInstancesRequest, callback: PlayFabModule.ApiCallback): void; + RevokeIPBan(request: PlayFabAdminModels.RevokeIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get definition information on a specified task or all tasks within a title. - / https://api.playfab.com/Documentation/Admin/method/GetTasks + * Run a task immediately regardless of its schedule. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/runtask */ - GetTasks(request: PlayFabAdminModels.GetTasksRequest, callback: PlayFabModule.ApiCallback): void; + RunTask(request: PlayFabAdminModels.RunTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Run a task immediately regardless of its schedule. - / https://api.playfab.com/Documentation/Admin/method/RunTask + * Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to + * change the password.If an account recovery email template ID is provided, an email using the custom email template will + * be used. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/sendaccountrecoveryemail */ - RunTask(request: PlayFabAdminModels.RunTaskRequest, callback: PlayFabModule.ApiCallback): void; + SendAccountRecoveryEmail(request: PlayFabAdminModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update an existing task. - / https://api.playfab.com/Documentation/Admin/method/UpdateTask + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Creates the catalog configuration of all virtual goods for the specified catalog version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setcatalogitems */ - UpdateTask(request: PlayFabAdminModels.UpdateTaskRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabAdminModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AbortTaskInstanceRequest - */ - export interface AbortTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + SetCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of a task instance that is being aborted. + * Sets the override expiration for a membership subscription + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/setmembershipoverride */ - TaskInstanceId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ActionsOnPlayersInSegmentTaskParameter - */ - export interface ActionsOnPlayersInSegmentTaskParameter { + SetMembershipOverride(request: PlayFabAdminModels.SetMembershipOverrideRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the segment to perform actions on. + * Sets or resets the player's secret. Player secrets are used to sign API requests. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/setplayersecret */ - SegmentId: string; + SetPlayerSecret(request: PlayFabAdminModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the action to perform on each player in segment. + * Sets the currently published revision of a title Cloud Script + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/setpublishedrevision */ - ActionId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ActionsOnPlayersInSegmentTaskSummary - */ - export interface ActionsOnPlayersInSegmentTaskSummary { + SetPublishedRevision(request: PlayFabAdminModels.SetPublishedRevisionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the task instance. + * Updates the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/admin/shared-group-data/setpublisherdata */ - TaskInstanceId?: string; + SetPublisherData(request: PlayFabAdminModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Identifier of the task this instance belongs to. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Sets all the items in one virtual store + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setstoreitems */ - TaskIdentifier?: NameIdentifier; + SetStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task started. + * Creates and updates the key-value store of custom title settings which can be read by the client. For example, a + * developer could choose to store values which modify the user experience, such as enemy spawn rates, weapon strengths, + * movement speeds, etc. This allows a developer to update the title without the need to create, test, and ship a new + * build. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitledata */ - StartedAt: string; + SetTitleData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task completed. + * Set and delete key-value pairs in a title data override instance. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitledataandoverrides */ - CompletedAt?: string; + SetTitleDataAndOverrides(request: PlayFabAdminModels.SetTitleDataAndOverridesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Current status of the task instance. + * Updates the key-value store of custom title settings which cannot be read by the client. These values can be used to + * tweak settings used by game servers and Cloud Scripts without the need to update and re-deploy. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/settitleinternaldata */ - Status?: string; + SetTitleInternalData(request: PlayFabAdminModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Progress represented as percentage. + * Sets the Amazon Resource Name (ARN) for iOS and Android push notifications. Documentation on the exact restrictions can + * be found at: http://docs.aws.amazon.com/sns/latest/api/API_CreatePlatformApplication.html. Currently, Amazon device + * Messaging is not supported. + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/setuppushnotification */ - PercentComplete?: number; + SetupPushNotification(request: PlayFabAdminModels.SetupPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Estimated time remaining in seconds. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/admin/player-item-management/subtractuservirtualcurrency */ - EstimatedSecondsRemaining?: number; + SubtractUserVirtualCurrency(request: PlayFabAdminModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / If manually scheduled, ID of user who scheduled the task. + * Updates information of a list of existing bans specified with Ban Ids. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updatebans */ - ScheduledByUserId?: string; + UpdateBans(request: PlayFabAdminModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Error message for last processing attempt, if an error occured. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the catalog configuration for virtual goods in the specified catalog version + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updatecatalogitems */ - ErrorMessage?: string; + UpdateCatalogItems(request: PlayFabAdminModels.UpdateCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Flag indicating if the error was fatal, if false job will be retried. + * Creates a new Cloud Script revision and uploads source code to it. Note that at this time, only one file should be + * submitted in the revision. + * https://docs.microsoft.com/rest/api/playfab/admin/server-side-cloud-script/updatecloudscript */ - ErrorWasFatal?: boolean; + UpdateCloudScript(request: PlayFabAdminModels.UpdateCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total players in segment when task was started. + * Updates an existing IP ban. + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updateipban */ - TotalPlayersInSegment?: number; + UpdateIPBan(request: PlayFabAdminModels.UpdateIPBanRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total number of players that have had the actions applied to. + * Modifies data and credentials for an existing relationship between a title and an Open ID Connect provider + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updateopenidconnection */ - TotalPlayersProcessed?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AdCampaignAttribution - */ - export interface AdCampaignAttribution { + UpdateOpenIdConnection(request: PlayFabAdminModels.UpdateOpenIdConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateplayercustomproperties */ - Platform?: string; + UpdatePlayerCustomProperties(request: PlayFabAdminModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Updates a existing Player Shared Secret Key. It may take up to 5 minutes for this update to become generally available + * after this API returns. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updateplayersharedsecret */ - CampaignId?: string; + UpdatePlayerSharedSecret(request: PlayFabAdminModels.UpdatePlayerSharedSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Updates a player statistic configuration for the title, optionally allowing the developer to specify a reset interval. + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateplayerstatisticdefinition */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddNewsRequest - */ - export interface AddNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdatePlayerStatisticDefinition(request: PlayFabAdminModels.UpdatePlayerStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Time this news was published. If not set, defaults to now. + * Changes a policy for a title + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/updatepolicy */ - Timestamp?: string; + UpdatePolicy(request: PlayFabAdminModels.UpdatePolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Title (headline) of the news item + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the random drop table configuration for the title + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updaterandomresulttables */ - Title: string; + UpdateRandomResultTables(request: PlayFabAdminModels.UpdateRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Body text of the news + * Updates an existing player segment and its associated definition(s) and action(s) for a title. + * https://docs.microsoft.com/rest/api/playfab/admin/segments/updatesegment */ - Body: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddNewsResult - */ - export interface AddNewsResult extends PlayFabModule.IPlayFabResultCommon { + UpdateSegment(request: PlayFabAdminModels.UpdateSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique id of the new news item + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates an existing virtual item store with new or modified items + * https://docs.microsoft.com/rest/api/playfab/admin/title-wide-data-management/updatestoreitems */ - NewsId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddPlayerTagRequest - */ - export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdateStoreItems(request: PlayFabAdminModels.UpdateStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Update an existing task. + * https://docs.microsoft.com/rest/api/playfab/admin/scheduledtask/updatetask */ - PlayFabId: string; + UpdateTask(request: PlayFabAdminModels.UpdateTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique tag for player profile. + * Updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserdata */ - TagName: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddPlayerTagResult - */ - export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddServerBuildRequest - */ - export interface AddServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + UpdateUserData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / unique identifier for the build executable + * Updates the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserinternaldata */ - BuildId: string; + UpdateUserInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / appended to the end of the command line when starting game servers + * Updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherdata */ - CommandLineTemplate?: string; + UpdateUserPublisherData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / path to the game server executable. Defaults to gameserver.exe + * Updates the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherinternaldata */ - ExecutablePath?: string; + UpdateUserPublisherInternalData(request: PlayFabAdminModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / server host regions in which this build should be running and available + * Updates the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserpublisherreadonlydata */ - ActiveRegions?: string[]; + UpdateUserPublisherReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / developer comment(s) for this build + * Updates the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/admin/player-data-management/updateuserreadonlydata */ - Comment?: string; + UpdateUserReadOnlyData(request: PlayFabAdminModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / maximum number of game server instances that can run on a single host machine + * Updates the title specific display name for a user + * https://docs.microsoft.com/rest/api/playfab/admin/account-management/updateusertitledisplayname */ - MaxGamesPerHost: number; + UpdateUserTitleDisplayName(request: PlayFabAdminModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) + * Validates the result of a policy update without persisting it. + * https://docs.microsoft.com/rest/api/playfab/admin/authentication/validateapipolicy */ - MinFreeGameSlots: number; + ValidateApiPolicy(request: PlayFabAdminModels.ValidateApiPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } +} - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddServerBuildResult - */ - export interface AddServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ - Comment?: string; - /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / the current status of the build validation and processing steps - */ +declare module PlayFabAdminModels { + export interface AbortTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of a task instance that is being aborted. */ + TaskInstanceId: string; + + } + + export interface Action { + /** Action content to add inventory item v2 */ + AddInventoryItemV2Content?: AddInventoryItemV2Content; + /** Action content to ban player */ + BanPlayerContent?: BanPlayerContent; + /** Action content to delete inventory item v2 */ + DeleteInventoryItemV2Content?: DeleteInventoryItemV2Content; + /** Action content to delete player */ + DeletePlayerContent?: DeletePlayerContent; + /** Action content to execute cloud script */ + ExecuteCloudScriptContent?: ExecuteCloudScriptContent; + /** Action content to execute azure function */ + ExecuteFunctionContent?: ExecuteFunctionContent; + /** Action content to grant item */ + GrantItemContent?: GrantItemContent; + /** Action content to grant virtual currency */ + GrantVirtualCurrencyContent?: GrantVirtualCurrencyContent; + /** Action content to increment player statistic */ + IncrementPlayerStatisticContent?: IncrementPlayerStatisticContent; + /** Action content to send push notification */ + PushNotificationContent?: PushNotificationContent; + /** Action content to send email */ + SendEmailContent?: SendEmailContent; + /** Action content to subtract inventory item v2 */ + SubtractInventoryItemV2Content?: SubtractInventoryItemV2Content; + + } + + export interface ActionsOnPlayersInSegmentTaskParameter { + /** List of actions to perform on each player in a segment. Each action object can contain only one action type. */ + Actions?: Action[]; + /** ID of the segment to perform actions on. */ + SegmentId: string; + + } + + export interface ActionsOnPlayersInSegmentTaskSummary { + /** UTC timestamp when the task completed. */ + CompletedAt?: string; + /** Error message for last processing attempt, if an error occured. */ + ErrorMessage?: string; + /** Flag indicating if the error was fatal, if false job will be retried. */ + ErrorWasFatal?: boolean; + /** Estimated time remaining in seconds. */ + EstimatedSecondsRemaining?: number; + /** Progress represented as percentage. */ + PercentComplete?: number; + /** If manually scheduled, ID of user who scheduled the task. */ + ScheduledByUserId?: string; + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; + /** Total players in segment when task was started. */ + TotalPlayersInSegment?: number; + /** Total number of players that have had the actions applied to. */ + TotalPlayersProcessed?: number; + + } + + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + export interface AdCampaignSegmentFilter { + /** Campaign id. */ + CampaignId?: string; + /** Campaign source. */ + CampaignSource?: string; + /** Campaign comparison. */ + Comparison?: string; + + } + + export interface AddInventoryItemsV2SegmentAction { + /** Amount of the item to be granted to a player */ + Amount?: number; + /** The collection id for where the item will be granted in the player inventory */ + CollectionId?: string; + /** The duration in seconds of the subscription to be granted to a player */ + DurationInSeconds?: number; + /** The id of item to be granted to the player */ + ItemId?: string; + /** The stack id for where the item will be granted in the player inventory */ + StackId?: string; + + } + + export interface AddInventoryItemV2Content { + /** Amount of the item to be granted to a player */ + Amount?: number; + /** The collection id for where the item will be granted in the player inventory */ + CollectionId?: string; + /** The duration in seconds of the subscription to be granted to a player */ + DurationInSeconds?: number; + /** The id of item to be granted to the player */ + ItemId?: string; + /** The stack id for where the item will be granted in the player inventory */ + StackId?: string; + + } + + export interface AddLocalizedNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Localized body text of the news. */ + Body: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Language of the news item. */ + Language: string; + /** Unique id of the updated news item. */ + NewsId: string; + /** Localized title (headline) of the news item. */ + Title: string; + + } + + export interface AddLocalizedNewsResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface AddNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Default body text of the news. */ + Body: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional status for the new news item. If not set, defaults to Published. */ Status?: string; + /** Time this news was published. If not set, defaults to now. */ + Timestamp?: string; + /** Default title (headline) of the news item. */ + Title: string; + + } + + export interface AddNewsResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique id of the new news item */ + NewsId?: string; + + } + + export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique tag for player profile. */ + TagName: string; + + } + + export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / PlayFab unique identifier of the user whose virtual currency balance is to be increased. + * Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). + * Any increase over this value will be discarded. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be increased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be incremented. - */ + /** Name of the virtual currency which is to be incremented. */ VirtualCurrency: string; - /** - / Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.AddVirtualCurrencyTypesRequest - */ export interface AddVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / List of virtual currencies and their initial deposits (the amount a user is granted when signing in for the first time) to the title + * List of virtual currencies and their initial deposits (the amount a user is granted when signing in for the first time) + * to the title */ VirtualCurrencies: VirtualCurrencyData[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanInfo - */ + export interface AllPlayersSegmentFilter { + + } + + export interface ApiCondition { + /** Require that API calls contain an RSA encrypted payload or signed headers. */ + HasSignatureOrEncryption?: string; + + } + + type AuthTokenType = "Email" + + export interface BanInfo { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / The unique Ban Id associated with this ban. - */ + /** The active state of this ban. Expired bans may still have this value set to true but they will have no effect. */ + Active: boolean; + /** The unique Ban Id associated with this ban. */ BanId?: string; - /** - / The IP address on which the ban was applied. May affect multiple players. - */ - IPAddress?: string; - /** - / The MAC address on which the ban was applied. May affect multiple players. - */ - MACAddress?: string; - /** - / The time when this ban was applied. - */ + /** The time when this ban was applied. */ Created?: string; - /** - / The time when this ban expires. Permanent bans do not have expiration date. - */ + /** The time when this ban expires. Permanent bans do not have expiration date. */ Expires?: string; - /** - / The reason why this ban was applied. - */ + /** The IP address on which the ban was applied. May affect multiple players. */ + IPAddress?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** The reason why this ban was applied. */ Reason?: string; - /** - / The active state of this ban. Expired bans may still have this value set to true but they will have no effect. - */ - Active: boolean; + /** The family type of the user that is included in the ban. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanRequest - */ - export interface BanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / IP address to be banned. May affect multiple players. - */ + export interface BanPlayerContent { + /** Duration(in hours) to ban a player. If not provided, the player will be banned permanently. */ + BanDurationHours?: number; + /** Reason to ban a player */ + BanReason?: string; + + } + + export interface BanPlayerSegmentAction { + /** Ban hours duration. */ + BanHours?: number; + /** Reason for ban. */ + ReasonForBan?: string; + + } + + export interface BanRequest { + /** The duration in hours for the ban. Leave this blank for a permanent ban. */ + DurationInHours?: number; + /** IP address to be banned. May affect multiple players. */ IPAddress?: string; - /** - / MAC address to be banned. May affect multiple players. - */ - MACAddress?: string; - /** - / The reason for this ban. Maximum 140 characters. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The reason for this ban. Maximum 140 characters. */ Reason?: string; - /** - / The duration in hours for the ban. Leave this blank for a permanent ban. - */ - DurationInHours?: number; + /** The family type of the user that should be included in the ban if applicable. May affect multiple players. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanUsersRequest - */ export interface BanUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of ban requests to be applied. Maximum 100. - */ + /** List of ban requests to be applied. Maximum 100. */ Bans: BanRequest[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BanUsersResult - */ export interface BanUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were applied - */ + /** Information on the bans that were applied */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.BlankResult - */ export interface BlankResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItem - */ export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - CustomData?: string; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the consumable properties (number of uses, timeout) for the item - */ - Consumable?: CatalogItemConsumableInfo; - /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API - */ - Container?: CatalogItemContainerInfo; - /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies - */ - Bundle?: CatalogItemBundleInfo; - /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ UsagePeriod?: number; /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ UsagePeriodGroup?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CatalogItemContainerInfo - */ export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ KeyItemId?: string; /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptFile - */ + export interface CheckLimitedEditionItemAvailabilityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Which catalog is being updated. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The item to check for. */ + ItemId: string; + + } + + export interface CheckLimitedEditionItemAvailabilityResult extends PlayFabModule.IPlayFabResultCommon { + /** The amount of the specified resource remaining. */ + Amount: number; + + } + + export interface ChurnPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; + + } + + type ChurnRiskLevel = "NoData" + + | "LowRisk" + | "MediumRisk" + | "HighRisk"; + export interface CloudScriptFile { + /** Contents of the Cloud Script javascript. Must be string-escaped javascript. */ + FileContents: string; /** - / Name of the javascript file. These names are not used internally by the server, they are only for developer organizational purposes. + * Name of the javascript file. These names are not used internally by the server, they are only for developer + * organizational purposes. */ Filename: string; - /** - / Contents of the Cloud Script javascript. Must be string-escaped javascript. - */ - FileContents: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptTaskParameter - */ export interface CloudScriptTaskParameter { - /** - / Name of the CloudScript function to execute. - */ - FunctionName?: string; - /** - / Argument to pass to the CloudScript function. - */ + /** Argument to pass to the CloudScript function. */ Argument?: any; + /** Name of the CloudScript function to execute. */ + FunctionName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptTaskSummary - */ export interface CloudScriptTaskSummary { - /** - / ID of the task instance. - */ - TaskInstanceId?: string; - /** - / Identifier of the task this instance belongs to. - */ - TaskIdentifier?: NameIdentifier; - /** - / UTC timestamp when the task started. - */ - StartedAt: string; - /** - / UTC timestamp when the task completed. - */ + /** UTC timestamp when the task completed. */ CompletedAt?: string; - /** - / Current status of the task instance. - */ - Status?: string; - /** - / Progress represented as percentage. - */ - PercentComplete?: number; - /** - / Estimated time remaining in seconds. - */ + /** Estimated time remaining in seconds. */ EstimatedSecondsRemaining?: number; - /** - / If manually scheduled, ID of user who scheduled the task. - */ - ScheduledByUserId?: string; - /** - / Result of CloudScript execution - */ + /** Progress represented as percentage. */ + PercentComplete?: number; + /** Result of CloudScript execution */ Result?: ExecuteCloudScriptResult; + /** If manually scheduled, ID of user who scheduled the task. */ + ScheduledByUserId?: string; + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CloudScriptVersionStatus - */ export interface CloudScriptVersionStatus { - /** - / Version number - */ - Version: number; - /** - / Published code revision for this Cloud Script version - */ - PublishedRevision: number; - /** - / Most recent revision for this Cloud Script version - */ + /** Most recent revision for this Cloud Script version */ LatestRevision: number; + /** Published code revision for this Cloud Script version */ + PublishedRevision: number; + /** Version number */ + Version: number; + + } + + type Conditionals = "Any" + + | "True" + | "False"; + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ContentInfo - */ export interface ContentInfo { - /** - / Key of the content - */ + /** Key of the content */ Key?: string; - /** - / Size of the content in bytes - */ - Size: number; - /** - / Last modified time - */ + /** Last modified time */ LastModified: string; + /** Size of the content in bytes */ + Size: number; } type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1333,104 +1418,153 @@ declare module PlayFabAdminModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateActionsOnPlayerSegmentTaskRequest - */ export interface CreateActionsOnPlayerSegmentTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ - Name: string; - /** - / Description the task - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ - Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ IsActive: boolean; - /** - / Task details related to segment and action - */ + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** Task details related to segment and action */ Parameter: ActionsOnPlayersInSegmentTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateCloudScriptTaskRequest - */ export interface CreateCloudScriptTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ + Description?: string; + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ Name: string; - /** - / Description the task - */ + /** Task details related to CloudScript */ + Parameter: CloudScriptTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; + + } + + export interface CreateInsightsScheduledScalingTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** Task details related to Insights Scaling */ + Parameter: InsightsScalingTaskParameter; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ Schedule?: string; + + } + + export interface CreateIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. + * The UTC date and time when the IP ban expires. Leave this blank for a permanent ban. Must be later than the current time + * and no more than 100 years in the future. */ - IsActive: boolean; + Expires?: string; + /** The IP address to be banned. */ + IPAddress: string; + /** The reason for the IP ban. Maximum 140 characters. */ + Reason?: string; + + } + + export interface CreateIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was created */ + IPBanData?: IPBanInfo; + + } + + export interface CreateOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The client ID given by the ID provider. */ + ClientId: string; + /** The client secret given by the ID provider. */ + ClientSecret: string; + /** A name for the connection that identifies it within the title. */ + ConnectionId: string; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; /** - / Task details related to CloudScript + * The discovery document URL to read issuer information from. This must be the absolute URL to the JSON OpenId + * Configuration document and must be accessible from the internet. If you don't know it, try your issuer URL followed by + * "/.well-known/openid-configuration". For example, if the issuer is https://example.com, try + * https://example.com/.well-known/openid-configuration */ - Parameter: CloudScriptTaskParameter; + IssuerDiscoveryUrl?: string; + /** Manually specified information for an OpenID Connect issuer. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; + + } + + export interface CreatePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Friendly name for this key */ + FriendlyName?: string; + + } + + export interface CreatePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SecretKey?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreatePlayerStatisticDefinitionRequest - */ export interface CreatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName: string; - /** - / interval at which the values of the statistic for all players are reset (resets begin at the next interval boundary) - */ + /** interval at which the values of the statistic for all players are reset (resets begin at the next interval boundary) */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreatePlayerStatisticDefinitionResult - */ export interface CreatePlayerStatisticDefinitionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / created statistic definition - */ + /** created statistic definition */ Statistic?: PlayerStatisticDefinition; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.CreateTaskResult - */ + export interface CreateSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment model with all of the segment properties data. */ + SegmentModel: SegmentModel; + + } + + export interface CreateSegmentResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** Segment id. */ + SegmentId?: string; + + } + export interface CreateTaskResult extends PlayFabModule.IPlayFabResultCommon { - /** - / ID of the task - */ + /** ID of the task */ TaskId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1593,1271 +1727,2214 @@ declare module PlayFabAdminModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteContentRequest - */ + export interface CustomPropertyBooleanSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property boolean value. */ + PropertyValue: boolean; + + } + + export interface CustomPropertyDateTimeSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property datetime value. */ + PropertyValue: string; + + } + + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; + + } + + export interface CustomPropertyNumericSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property numeric value. */ + PropertyValue: number; + + } + + export interface CustomPropertyStringSegmentFilter { + /** Custom property comparison. */ + Comparison?: string; + /** Custom property name. */ + PropertyName?: string; + /** Custom property string value. */ + PropertyValue?: string; + + } + export interface DeleteContentRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to be deleted - */ + /** Key of the content item to be deleted */ Key: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteStoreRequest - */ - export interface DeleteStoreRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version of the store to delete. If null, uses the default catalog. - */ - CatalogVersion?: string; - /** - / unqiue identifier for the store which is to be deleted - */ - StoreId: string; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteStoreResult - */ - export interface DeleteStoreResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteInventoryItemsV2SegmentAction { + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteTaskRequest - */ - export interface DeleteTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specify either the task ID or the name of task to be deleted. - */ - Identifier?: NameIdentifier; + export interface DeleteInventoryItemV2Content { + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteUsersRequest - */ - export interface DeleteUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabIds: string[]; + export interface DeleteMasterPlayerAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Developer created string to identify a user without PlayFab ID */ + MetaData?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface DeleteMasterPlayerAccountResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * A notification email with this job receipt Id will be sent to the title notification email address when deletion is + * complete. */ - TitleId: string; + JobReceiptId?: string; + /** List of titles from which the player's data will be deleted. */ + TitleIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.DeleteUsersResult - */ - export interface DeleteUsersResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteMasterPlayerEventDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - type EffectType = "Allow" - | "Deny"; + export interface DeleteMasterPlayerEventDataResult extends PlayFabModule.IPlayFabResultCommon { + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.EmptyResult - */ - export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeleteMembershipSubscriptionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the membership to apply the override expiration date to. */ + MembershipId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Id of the subscription that should be deleted from the membership. */ + SubscriptionId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ExecuteCloudScriptResult - */ - export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ - FunctionName?: string; - /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any - */ - FunctionResult?: any; - /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. - */ - Logs?: LogStatement[]; - ExecutionTimeSeconds: number; - /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. - */ - ProcessorTimeSeconds: number; - MemoryConsumedBytes: number; - /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; + export interface DeleteMembershipSubscriptionResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** unique name of the connection */ + ConnectionId: string; + + } + + export interface DeletePlayerContent { + + } + + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Number of external HTTP requests issued by the CloudScript function + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - HttpRequestsIssued: number; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; + /** PlayFab unique identifier of the user whose properties were deleted. */ + PlayFabId?: string; /** - / Information about the error, if any, that occured during execution + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Error?: ScriptExecutionError; + PropertiesVersion: number; + + } + + export interface DeletePlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface DeletePlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePlayerSegmentAction { + + } + + export interface DeletePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The shared secret key to delete */ + SecretKey?: string; + + } + + export interface DeletePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePlayerStatisticSegmentAction { + /** Statistic name. */ + StatisticName?: string; + + } + + export interface DeleteSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment id. */ + SegmentId: string; + + } + + export interface DeleteSegmentsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + + } + + export interface DeleteStoreRequest extends PlayFabModule.IPlayFabRequestCommon { + /** catalog version of the store to delete. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unqiue identifier for the store which is to be deleted */ + StoreId: string; + + } + + export interface DeleteStoreResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specify either the task ID or the name of task to be deleted. */ + Identifier?: NameIdentifier; + + } + + export interface DeleteTitleDataOverrideRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Name of the override. */ + OverrideLabel: string; + + } + + export interface DeleteTitleDataOverrideResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface DeleteTitleResult extends PlayFabModule.IPlayFabResultCommon { + + } + + type EffectType = "Allow" + + | "Deny"; + + export interface EmailNotificationSegmentAction { + /** Email template id. */ + EmailTemplateId?: string; + /** Email template name. */ + EmailTemplateName?: string; + + } + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; } - type GameBuildStatus = "Available" - | "Validating" - | "InvalidBuildPackage" - | "Processing" - | "FailedToProcess"; + export interface ExecuteAzureFunctionSegmentAction { + /** Azure function. */ + AzureFunction?: string; + /** Azure function parameter. */ + FunctionParameter?: any; + /** Generate play stream event. */ + GenerateFunctionExecutedEvents: boolean; + + } + + export interface ExecuteCloudScriptContent { + /** Arguments(JSON) to be passed into the cloudscript method */ + CloudScriptMethodArguments: string; + /** Cloudscript method name */ + CloudScriptMethodName: string; + /** Publish cloudscript results as playstream event */ + PublishResultsToPlayStream: boolean; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GameModeInfo - */ - export interface GameModeInfo { + export interface ExecuteCloudScriptResult { + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / specific game mode type + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - Gamemode: string; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / minimum user count required for this Game Server Instance to continue (usually 1) + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ - MinPlayerCount: number; + Logs?: LogStatement[]; /** - / maximum user count a specific Game Server Instance can support + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - MaxPlayerCount: number; + LogsTooLarge?: boolean; + MemoryConsumedBytes: number; /** - / whether to start as an open session, meaning that players can matchmake into it (defaults to true) + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - StartOpen?: boolean; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetActionGroupResult - */ - export interface GetActionGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Action Group name - */ - Name: string; + export interface ExecuteCloudScriptSegmentAction { + /** Cloud script function. */ + CloudScriptFunction?: string; + /** Generate play stream event. */ + CloudScriptPublishResultsToPlayStream: boolean; + /** Cloud script function parameter. */ + FunctionParameter?: any; + /** Cloud script function parameter json text. */ + FunctionParameterJson?: string; + + } + + export interface ExecuteFunctionContent { + /** Arguments(JSON) to be passed into the cloudscript azure function */ + CloudScriptFunctionArguments: string; + /** Cloudscript azure function name */ + CloudScriptFunctionName: string; + /** Publish results from executing the azure function as playstream event */ + PublishResultsToPlayStream: boolean; + + } + + export interface ExportMasterPlayerDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface ExportMasterPlayerDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Action Group ID + * An email with this job receipt Id containing the export download link will be sent to the title notification email + * address when the export is complete. */ - Id?: string; + JobReceiptId?: string; + + } + + export interface ExportPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the requested segment. */ + SegmentId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetActionsOnPlayersInSegmentTaskInstanceResult - */ + export interface ExportPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId?: string; + /** Unique identifier of the requested Segment. */ + SegmentId?: string; + + } + + export interface FirstLoginDateSegmentFilter { + /** First player login date comparison. */ + Comparison?: string; + /** First player login date. */ + LogInDate: string; + + } + + export interface FirstLoginTimespanSegmentFilter { + /** First player login duration comparison. */ + Comparison?: string; + /** First player login duration. */ + DurationInMinutes: number; + + } + + type GenericErrorCodes = "Success" + + | "UnkownError" + | "InvalidParams" + | "AccountNotFound" + | "AccountBanned" + | "InvalidUsernameOrPassword" + | "InvalidTitleId" + | "InvalidEmailAddress" + | "EmailAddressNotAvailable" + | "InvalidUsername" + | "InvalidPassword" + | "UsernameNotAvailable" + | "InvalidSteamTicket" + | "AccountAlreadyLinked" + | "LinkedAccountAlreadyClaimed" + | "InvalidFacebookToken" + | "AccountNotLinked" + | "FailedByPaymentProvider" + | "CouponCodeNotFound" + | "InvalidContainerItem" + | "ContainerNotOwned" + | "KeyNotOwned" + | "InvalidItemIdInTable" + | "InvalidReceipt" + | "ReceiptAlreadyUsed" + | "ReceiptCancelled" + | "GameNotFound" + | "GameModeNotFound" + | "InvalidGoogleToken" + | "UserIsNotPartOfDeveloper" + | "InvalidTitleForDeveloper" + | "TitleNameConflicts" + | "UserisNotValid" + | "ValueAlreadyExists" + | "BuildNotFound" + | "PlayerNotInGame" + | "InvalidTicket" + | "InvalidDeveloper" + | "InvalidOrderInfo" + | "RegistrationIncomplete" + | "InvalidPlatform" + | "UnknownError" + | "SteamApplicationNotOwned" + | "WrongSteamAccount" + | "TitleNotActivated" + | "RegistrationSessionNotFound" + | "NoSuchMod" + | "FileNotFound" + | "DuplicateEmail" + | "ItemNotFound" + | "ItemNotOwned" + | "ItemNotRecycleable" + | "ItemNotAffordable" + | "InvalidVirtualCurrency" + | "WrongVirtualCurrency" + | "WrongPrice" + | "NonPositiveValue" + | "InvalidRegion" + | "RegionAtCapacity" + | "ServerFailedToStart" + | "NameNotAvailable" + | "InsufficientFunds" + | "InvalidDeviceID" + | "InvalidPushNotificationToken" + | "NoRemainingUses" + | "InvalidPaymentProvider" + | "PurchaseInitializationFailure" + | "DuplicateUsername" + | "InvalidBuyerInfo" + | "NoGameModeParamsSet" + | "BodyTooLarge" + | "ReservedWordInBody" + | "InvalidTypeInBody" + | "InvalidRequest" + | "ReservedEventName" + | "InvalidUserStatistics" + | "NotAuthenticated" + | "StreamAlreadyExists" + | "ErrorCreatingStream" + | "StreamNotFound" + | "InvalidAccount" + | "PurchaseDoesNotExist" + | "InvalidPurchaseTransactionStatus" + | "APINotEnabledForGameClientAccess" + | "NoPushNotificationARNForTitle" + | "BuildAlreadyExists" + | "BuildPackageDoesNotExist" + | "CustomAnalyticsEventsNotEnabledForTitle" + | "InvalidSharedGroupId" + | "NotAuthorized" + | "MissingTitleGoogleProperties" + | "InvalidItemProperties" + | "InvalidPSNAuthCode" + | "InvalidItemId" + | "PushNotEnabledForAccount" + | "PushServiceError" + | "ReceiptDoesNotContainInAppItems" + | "ReceiptContainsMultipleInAppItems" + | "InvalidBundleID" + | "JavascriptException" + | "InvalidSessionTicket" + | "UnableToConnectToDatabase" + | "InternalServerError" + | "InvalidReportDate" + | "DatabaseThroughputExceeded" + | "InvalidGameTicket" + | "ExpiredGameTicket" + | "GameTicketDoesNotMatchLobby" + | "LinkedDeviceAlreadyClaimed" + | "DeviceAlreadyLinked" + | "DeviceNotLinked" + | "PartialFailure" + | "PublisherNotSet" + | "ServiceUnavailable" + | "VersionNotFound" + | "RevisionNotFound" + | "InvalidPublisherId" + | "DownstreamServiceUnavailable" + | "APINotIncludedInTitleUsageTier" + | "DAULimitExceeded" + | "APIRequestLimitExceeded" + | "InvalidAPIEndpoint" + | "BuildNotAvailable" + | "ConcurrentEditError" + | "ContentNotFound" + | "CharacterNotFound" + | "CloudScriptNotFound" + | "ContentQuotaExceeded" + | "InvalidCharacterStatistics" + | "PhotonNotEnabledForTitle" + | "PhotonApplicationNotFound" + | "PhotonApplicationNotAssociatedWithTitle" + | "InvalidEmailOrPassword" + | "FacebookAPIError" + | "InvalidContentType" + | "KeyLengthExceeded" + | "DataLengthExceeded" + | "TooManyKeys" + | "FreeTierCannotHaveVirtualCurrency" + | "MissingAmazonSharedKey" + | "AmazonValidationError" + | "InvalidPSNIssuerId" + | "PSNInaccessible" + | "ExpiredAuthToken" + | "FailedToGetEntitlements" + | "FailedToConsumeEntitlement" + | "TradeAcceptingUserNotAllowed" + | "TradeInventoryItemIsAssignedToCharacter" + | "TradeInventoryItemIsBundle" + | "TradeStatusNotValidForCancelling" + | "TradeStatusNotValidForAccepting" + | "TradeDoesNotExist" + | "TradeCancelled" + | "TradeAlreadyFilled" + | "TradeWaitForStatusTimeout" + | "TradeInventoryItemExpired" + | "TradeMissingOfferedAndAcceptedItems" + | "TradeAcceptedItemIsBundle" + | "TradeAcceptedItemIsStackable" + | "TradeInventoryItemInvalidStatus" + | "TradeAcceptedCatalogItemInvalid" + | "TradeAllowedUsersInvalid" + | "TradeInventoryItemDoesNotExist" + | "TradeInventoryItemIsConsumed" + | "TradeInventoryItemIsStackable" + | "TradeAcceptedItemsMismatch" + | "InvalidKongregateToken" + | "FeatureNotConfiguredForTitle" + | "NoMatchingCatalogItemForReceipt" + | "InvalidCurrencyCode" + | "NoRealMoneyPriceForCatalogItem" + | "TradeInventoryItemIsNotTradable" + | "TradeAcceptedCatalogItemIsNotTradable" + | "UsersAlreadyFriends" + | "LinkedIdentifierAlreadyClaimed" + | "CustomIdNotLinked" + | "TotalDataSizeExceeded" + | "DeleteKeyConflict" + | "InvalidXboxLiveToken" + | "ExpiredXboxLiveToken" + | "ResettableStatisticVersionRequired" + | "NotAuthorizedByTitle" + | "NoPartnerEnabled" + | "InvalidPartnerResponse" + | "APINotEnabledForGameServerAccess" + | "StatisticNotFound" + | "StatisticNameConflict" + | "StatisticVersionClosedForWrites" + | "StatisticVersionInvalid" + | "APIClientRequestRateLimitExceeded" + | "InvalidJSONContent" + | "InvalidDropTable" + | "StatisticVersionAlreadyIncrementedForScheduledInterval" + | "StatisticCountLimitExceeded" + | "StatisticVersionIncrementRateExceeded" + | "ContainerKeyInvalid" + | "CloudScriptExecutionTimeLimitExceeded" + | "NoWritePermissionsForEvent" + | "CloudScriptFunctionArgumentSizeExceeded" + | "CloudScriptAPIRequestCountExceeded" + | "CloudScriptAPIRequestError" + | "CloudScriptHTTPRequestError" + | "InsufficientGuildRole" + | "GuildNotFound" + | "OverLimit" + | "EventNotFound" + | "InvalidEventField" + | "InvalidEventName" + | "CatalogNotConfigured" + | "OperationNotSupportedForPlatform" + | "SegmentNotFound" + | "StoreNotFound" + | "InvalidStatisticName" + | "TitleNotQualifiedForLimit" + | "InvalidServiceLimitLevel" + | "ServiceLimitLevelInTransition" + | "CouponAlreadyRedeemed" + | "GameServerBuildSizeLimitExceeded" + | "GameServerBuildCountLimitExceeded" + | "VirtualCurrencyCountLimitExceeded" + | "VirtualCurrencyCodeExists" + | "TitleNewsItemCountLimitExceeded" + | "InvalidTwitchToken" + | "TwitchResponseError" + | "ProfaneDisplayName" + | "UserAlreadyAdded" + | "InvalidVirtualCurrencyCode" + | "VirtualCurrencyCannotBeDeleted" + | "IdentifierAlreadyClaimed" + | "IdentifierNotLinked" + | "InvalidContinuationToken" + | "ExpiredContinuationToken" + | "InvalidSegment" + | "InvalidSessionId" + | "SessionLogNotFound" + | "InvalidSearchTerm" + | "TwoFactorAuthenticationTokenRequired" + | "GameServerHostCountLimitExceeded" + | "PlayerTagCountLimitExceeded" + | "RequestAlreadyRunning" + | "ActionGroupNotFound" + | "MaximumSegmentBulkActionJobsRunning" + | "NoActionsOnPlayersInSegmentJob" + | "DuplicateStatisticName" + | "ScheduledTaskNameConflict" + | "ScheduledTaskCreateConflict" + | "InvalidScheduledTaskName" + | "InvalidTaskSchedule" + | "SteamNotEnabledForTitle" + | "LimitNotAnUpgradeOption" + | "NoSecretKeyEnabledForCloudScript" + | "TaskNotFound" + | "TaskInstanceNotFound" + | "InvalidIdentityProviderId" + | "MisconfiguredIdentityProvider" + | "InvalidScheduledTaskType" + | "BillingInformationRequired" + | "LimitedEditionItemUnavailable" + | "InvalidAdPlacementAndReward" + | "AllAdPlacementViewsAlreadyConsumed" + | "GoogleOAuthNotConfiguredForTitle" + | "GoogleOAuthError" + | "UserNotFriend" + | "InvalidSignature" + | "InvalidPublicKey" + | "GoogleOAuthNoIdTokenIncludedInResponse" + | "StatisticUpdateInProgress" + | "LeaderboardVersionNotAvailable" + | "StatisticAlreadyHasPrizeTable" + | "PrizeTableHasOverlappingRanks" + | "PrizeTableHasMissingRanks" + | "PrizeTableRankStartsAtZero" + | "InvalidStatistic" + | "ExpressionParseFailure" + | "ExpressionInvokeFailure" + | "ExpressionTooLong" + | "DataUpdateRateExceeded" + | "RestrictedEmailDomain" + | "EncryptionKeyDisabled" + | "EncryptionKeyMissing" + | "EncryptionKeyBroken" + | "NoSharedSecretKeyConfigured" + | "SecretKeyNotFound" + | "PlayerSecretAlreadyConfigured" + | "APIRequestsDisabledForTitle" + | "InvalidSharedSecretKey" + | "PrizeTableHasNoRanks" + | "ProfileDoesNotExist" + | "ContentS3OriginBucketNotConfigured" + | "InvalidEnvironmentForReceipt" + | "EncryptedRequestNotAllowed" + | "SignedRequestNotAllowed" + | "RequestViewConstraintParamsNotAllowed" + | "BadPartnerConfiguration" + | "XboxBPCertificateFailure" + | "XboxXASSExchangeFailure" + | "InvalidEntityId" + | "StatisticValueAggregationOverflow" + | "EmailMessageFromAddressIsMissing" + | "EmailMessageToAddressIsMissing" + | "SmtpServerAuthenticationError" + | "SmtpServerLimitExceeded" + | "SmtpServerInsufficientStorage" + | "SmtpServerCommunicationError" + | "SmtpServerGeneralFailure" + | "EmailClientTimeout" + | "EmailClientCanceledTask" + | "EmailTemplateMissing" + | "InvalidHostForTitleId" + | "EmailConfirmationTokenDoesNotExist" + | "EmailConfirmationTokenExpired" + | "AccountDeleted" + | "PlayerSecretNotConfigured" + | "InvalidSignatureTime" + | "NoContactEmailAddressFound" + | "InvalidAuthToken" + | "AuthTokenDoesNotExist" + | "AuthTokenExpired" + | "AuthTokenAlreadyUsedToResetPassword" + | "MembershipNameTooLong" + | "MembershipNotFound" + | "GoogleServiceAccountInvalid" + | "GoogleServiceAccountParseFailure" + | "EntityTokenMissing" + | "EntityTokenInvalid" + | "EntityTokenExpired" + | "EntityTokenRevoked" + | "InvalidProductForSubscription" + | "XboxInaccessible" + | "SubscriptionAlreadyTaken" + | "SmtpAddonNotEnabled" + | "APIConcurrentRequestLimitExceeded" + | "XboxRejectedXSTSExchangeRequest" + | "VariableNotDefined" + | "TemplateVersionNotDefined" + | "FileTooLarge" + | "TitleDeleted" + | "TitleContainsUserAccounts" + | "TitleDeletionPlayerCleanupFailure" + | "EntityFileOperationPending" + | "NoEntityFileOperationPending" + | "EntityProfileVersionMismatch" + | "TemplateVersionTooOld" + | "MembershipDefinitionInUse" + | "PaymentPageNotConfigured" + | "FailedLoginAttemptRateLimitExceeded" + | "EntityBlockedByGroup" + | "RoleDoesNotExist" + | "EntityIsAlreadyMember" + | "DuplicateRoleId" + | "GroupInvitationNotFound" + | "GroupApplicationNotFound" + | "OutstandingInvitationAcceptedInstead" + | "OutstandingApplicationAcceptedInstead" + | "RoleIsGroupDefaultMember" + | "RoleIsGroupAdmin" + | "RoleNameNotAvailable" + | "GroupNameNotAvailable" + | "EmailReportAlreadySent" + | "EmailReportRecipientBlacklisted" + | "EventNamespaceNotAllowed" + | "EventEntityNotAllowed" + | "InvalidEntityType" + | "NullTokenResultFromAad" + | "InvalidTokenResultFromAad" + | "NoValidCertificateForAad" + | "InvalidCertificateForAad" + | "DuplicateDropTableId" + | "MultiplayerServerError" + | "MultiplayerServerTooManyRequests" + | "MultiplayerServerNoContent" + | "MultiplayerServerBadRequest" + | "MultiplayerServerUnauthorized" + | "MultiplayerServerForbidden" + | "MultiplayerServerNotFound" + | "MultiplayerServerConflict" + | "MultiplayerServerInternalServerError" + | "MultiplayerServerUnavailable" + | "ExplicitContentDetected" + | "PIIContentDetected" + | "InvalidScheduledTaskParameter" + | "PerEntityEventRateLimitExceeded" + | "TitleDefaultLanguageNotSet" + | "EmailTemplateMissingDefaultVersion" + | "FacebookInstantGamesIdNotLinked" + | "InvalidFacebookInstantGamesSignature" + | "FacebookInstantGamesAuthNotConfiguredForTitle" + | "EntityProfileConstraintValidationFailed" + | "TelemetryIngestionKeyPending" + | "TelemetryIngestionKeyNotFound" + | "StatisticChildNameInvalid" + | "DataIntegrityError" + | "VirtualCurrencyCannotBeSetToOlderVersion" + | "VirtualCurrencyMustBeWithinIntegerRange" + | "EmailTemplateInvalidSyntax" + | "EmailTemplateMissingCallback" + | "PushNotificationTemplateInvalidPayload" + | "InvalidLocalizedPushNotificationLanguage" + | "MissingLocalizedPushNotificationMessage" + | "PushNotificationTemplateMissingPlatformPayload" + | "PushNotificationTemplatePayloadContainsInvalidJson" + | "PushNotificationTemplateContainsInvalidIosPayload" + | "PushNotificationTemplateContainsInvalidAndroidPayload" + | "PushNotificationTemplateIosPayloadMissingNotificationBody" + | "PushNotificationTemplateAndroidPayloadMissingNotificationBody" + | "PushNotificationTemplateNotFound" + | "PushNotificationTemplateMissingDefaultVersion" + | "PushNotificationTemplateInvalidSyntax" + | "PushNotificationTemplateNoCustomPayloadForV1" + | "NoLeaderboardForStatistic" + | "TitleNewsMissingDefaultLanguage" + | "TitleNewsNotFound" + | "TitleNewsDuplicateLanguage" + | "TitleNewsMissingTitleOrBody" + | "TitleNewsInvalidLanguage" + | "EmailRecipientBlacklisted" + | "InvalidGameCenterAuthRequest" + | "GameCenterAuthenticationFailed" + | "CannotEnablePartiesForTitle" + | "PartyError" + | "PartyRequests" + | "PartyNoContent" + | "PartyBadRequest" + | "PartyUnauthorized" + | "PartyForbidden" + | "PartyNotFound" + | "PartyConflict" + | "PartyInternalServerError" + | "PartyUnavailable" + | "PartyTooManyRequests" + | "PushNotificationTemplateMissingName" + | "CannotEnableMultiplayerServersForTitle" + | "WriteAttemptedDuringExport" + | "MultiplayerServerTitleQuotaCoresExceeded" + | "AutomationRuleNotFound" + | "EntityAPIKeyLimitExceeded" + | "EntityAPIKeyNotFound" + | "EntityAPIKeyOrSecretInvalid" + | "EconomyServiceUnavailable" + | "EconomyServiceInternalError" + | "QueryRateLimitExceeded" + | "EntityAPIKeyCreationDisabledForEntity" + | "ForbiddenByEntityPolicy" + | "UpdateInventoryRateLimitExceeded" + | "StudioCreationRateLimited" + | "StudioCreationInProgress" + | "DuplicateStudioName" + | "StudioNotFound" + | "StudioDeleted" + | "StudioDeactivated" + | "StudioActivated" + | "TitleCreationRateLimited" + | "TitleCreationInProgress" + | "DuplicateTitleName" + | "TitleActivationRateLimited" + | "TitleActivationInProgress" + | "TitleDeactivated" + | "TitleActivated" + | "CloudScriptAzureFunctionsExecutionTimeLimitExceeded" + | "CloudScriptAzureFunctionsArgumentSizeExceeded" + | "CloudScriptAzureFunctionsReturnSizeExceeded" + | "CloudScriptAzureFunctionsHTTPRequestError" + | "VirtualCurrencyBetaGetError" + | "VirtualCurrencyBetaCreateError" + | "VirtualCurrencyBetaInitialDepositSaveError" + | "VirtualCurrencyBetaSaveError" + | "VirtualCurrencyBetaDeleteError" + | "VirtualCurrencyBetaRestoreError" + | "VirtualCurrencyBetaSaveConflict" + | "VirtualCurrencyBetaUpdateError" + | "InsightsManagementDatabaseNotFound" + | "InsightsManagementOperationNotFound" + | "InsightsManagementErrorPendingOperationExists" + | "InsightsManagementSetPerformanceLevelInvalidParameter" + | "InsightsManagementSetStorageRetentionInvalidParameter" + | "InsightsManagementGetStorageUsageInvalidParameter" + | "InsightsManagementGetOperationStatusInvalidParameter" + | "DuplicatePurchaseTransactionId" + | "EvaluationModePlayerCountExceeded" + | "CloudScriptFunctionNameSizeExceeded" + | "PaidInsightsFeaturesNotEnabled" + | "CloudScriptAzureFunctionsQueueRequestError" + | "EvaluationModeTitleCountExceeded" + | "InsightsManagementTitleNotInFlight" + | "LimitNotFound" + | "LimitNotAvailableViaAPI" + | "InsightsManagementSetStorageRetentionBelowMinimum" + | "InsightsManagementSetStorageRetentionAboveMaximum" + | "AppleNotEnabledForTitle" + | "InsightsManagementNewActiveEventExportLimitInvalid" + | "InsightsManagementSetPerformanceRateLimited" + | "PartyRequestsThrottledFromRateLimiter" + | "XboxServiceTooManyRequests" + | "NintendoSwitchNotEnabledForTitle" + | "RequestMultiplayerServersThrottledFromRateLimiter" + | "TitleDataOverrideNotFound" + | "DuplicateKeys" + | "WasNotCreatedWithCloudRoot" + | "LegacyMultiplayerServersDeprecated" + | "VirtualCurrencyCurrentlyUnavailable" + | "SteamUserNotFound" + | "ElasticSearchOperationFailed" + | "NotImplemented" + | "PublisherNotFound" + | "PublisherDeleted" + | "ApiDisabledForMigration" + | "ResourceNameUpdateNotAllowed" + | "ApiNotEnabledForTitle" + | "DuplicateTitleNameForPublisher" + | "AzureTitleCreationInProgress" + | "TitleConstraintsPublisherDeletion" + | "InvalidPlayerAccountPoolId" + | "PlayerAccountPoolNotFound" + | "PlayerAccountPoolDeleted" + | "TitleCleanupInProgress" + | "AzureResourceConcurrentOperationInProgress" + | "TitlePublisherUpdateNotAllowed" + | "AzureResourceManagerNotSupportedInStamp" + | "ApiNotIncludedInAzurePlayFabFeatureSet" + | "GoogleServiceAccountFailedAuth" + | "GoogleAPIServiceUnavailable" + | "GoogleAPIServiceUnknownError" + | "NoValidIdentityForAad" + | "PlayerIdentityLinkNotFound" + | "PhotonApplicationIdAlreadyInUse" + | "CloudScriptUnableToDeleteProductionRevision" + | "CustomIdNotFound" + | "AutomationInvalidInput" + | "AutomationInvalidRuleName" + | "AutomationRuleAlreadyExists" + | "AutomationRuleLimitExceeded" + | "InvalidGooglePlayGamesServerAuthCode" + | "PlayStreamConnectionFailed" + | "InvalidEventContents" + | "InsightsV1Deprecated" + | "AnalysisSubscriptionNotFound" + | "AnalysisSubscriptionFailed" + | "AnalysisSubscriptionFoundAlready" + | "AnalysisSubscriptionManagementInvalidInput" + | "InvalidGameCenterId" + | "InvalidNintendoSwitchAccountId" + | "EntityAPIKeysNotSupported" + | "IpAddressBanned" + | "EntityLineageBanned" + | "NamespaceMismatch" + | "InvalidServiceConfiguration" + | "InvalidNamespaceMismatch" + | "LeaderboardColumnLengthMismatch" + | "InvalidStatisticScore" + | "LeaderboardColumnsNotSpecified" + | "LeaderboardMaxSizeTooLarge" + | "InvalidAttributeStatisticsSpecified" + | "LeaderboardNotFound" + | "TokenSigningKeyNotFound" + | "LeaderboardNameConflict" + | "LinkedStatisticColumnMismatch" + | "NoLinkedStatisticToLeaderboard" + | "StatDefinitionAlreadyLinkedToLeaderboard" + | "LinkingStatsNotAllowedForEntityType" + | "LeaderboardCountLimitExceeded" + | "LeaderboardSizeLimitExceeded" + | "LeaderboardDefinitionModificationNotAllowedWhileLinked" + | "StatisticDefinitionModificationNotAllowedWhileLinked" + | "LeaderboardUpdateNotAllowedWhileLinked" + | "CloudScriptAzureFunctionsEventHubRequestError" + | "ExternalEntityNotAllowedForTier" + | "InvalidBaseTimeForInterval" + | "EntityTypeMismatchWithStatDefinition" + | "SpecifiedVersionLeaderboardNotFound" + | "LeaderboardColumnLengthMismatchWithStatDefinition" + | "DuplicateColumnNameFound" + | "LinkedStatisticColumnNotFound" + | "LinkedStatisticColumnRequired" + | "MultipleLinkedStatisticsNotAllowed" + | "DuplicateLinkedStatisticColumnNameFound" + | "AggregationTypeNotAllowedForMultiColumnStatistic" + | "MaxQueryableVersionsValueNotAllowedForTier" + | "StatisticDefinitionHasNullOrEmptyVersionConfiguration" + | "StatisticColumnLengthMismatch" + | "InvalidExternalEntityId" + | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" + | "ResetIntervalCannotBeModified" + | "VersionIncrementRateExceeded" + | "InvalidSteamUsername" + | "InvalidVersionResetForLinkedLeaderboard" + | "BattleNetNotEnabledForTitle" + | "ReportNotProcessed" + | "DataNotAvailable" + | "InvalidReportName" + | "ResourceNotModified" + | "StudioCreationLimitExceeded" + | "StudioDeletionInitiated" + | "ProductDisabledForTitle" + | "PreconditionFailed" + | "CannotEnableAnonymousPlayerCreation" + | "ParentCustomerAccountNotFound" + | "AccountLinkedToABannedPlayer" + | "AzureSubscriptionNotEligibleForLinking" + | "EntityIsNotAMember" + | "IPAddressNotFound" + | "PSNNextGenNotConfiguredForTitle" + | "InvalidNintendoIssuer" + | "MatchmakingEntityInvalid" + | "MatchmakingPlayerAttributesInvalid" + | "MatchmakingQueueNotFound" + | "MatchmakingMatchNotFound" + | "MatchmakingTicketNotFound" + | "MatchmakingAlreadyJoinedTicket" + | "MatchmakingTicketAlreadyCompleted" + | "MatchmakingQueueConfigInvalid" + | "MatchmakingMemberProfileInvalid" + | "NintendoSwitchDeviceIdNotLinked" + | "MatchmakingNotEnabled" + | "MatchmakingPlayerAttributesTooLarge" + | "MatchmakingNumberOfPlayersInTicketTooLarge" + | "MatchmakingAttributeInvalid" + | "MatchmakingPlayerHasNotJoinedTicket" + | "MatchmakingRateLimitExceeded" + | "MatchmakingTicketMembershipLimitExceeded" + | "MatchmakingUnauthorized" + | "MatchmakingQueueLimitExceeded" + | "MatchmakingRequestTypeMismatch" + | "MatchmakingBadRequest" + | "PubSubFeatureNotEnabledForTitle" + | "PubSubTooManyRequests" + | "PubSubConnectionNotFoundForEntity" + | "PubSubConnectionHandleInvalid" + | "PubSubSubscriptionLimitExceeded" + | "TitleConfigNotFound" + | "TitleConfigUpdateConflict" + | "TitleConfigSerializationError" + | "CatalogApiNotImplemented" + | "CatalogEntityInvalid" + | "CatalogTitleIdMissing" + | "CatalogPlayerIdMissing" + | "CatalogClientIdentityInvalid" + | "CatalogOneOrMoreFilesInvalid" + | "CatalogItemMetadataInvalid" + | "CatalogItemIdInvalid" + | "CatalogSearchParameterInvalid" + | "CatalogFeatureDisabled" + | "CatalogConfigInvalid" + | "CatalogItemTypeInvalid" + | "CatalogBadRequest" + | "CatalogTooManyRequests" + | "InvalidCatalogItemConfiguration" + | "LegacyEconomyDisabled" + | "ExportInvalidStatusUpdate" + | "ExportInvalidPrefix" + | "ExportBlobContainerDoesNotExist" + | "ExportNotFound" + | "ExportCouldNotUpdate" + | "ExportInvalidStorageType" + | "ExportAmazonBucketDoesNotExist" + | "ExportInvalidBlobStorage" + | "ExportKustoException" + | "ExportKustoConnectionFailed" + | "ExportUnknownError" + | "ExportCantEditPendingExport" + | "ExportLimitExports" + | "ExportLimitEvents" + | "ExportInvalidPartitionStatusModification" + | "ExportCouldNotCreate" + | "ExportNoBackingDatabaseFound" + | "ExportCouldNotDelete" + | "ExportCannotDetermineEventQuery" + | "ExportInvalidQuerySchemaModification" + | "ExportQuerySchemaMissingRequiredColumns" + | "ExportCannotParseQuery" + | "ExportControlCommandsNotAllowed" + | "ExportQueryMissingTableReference" + | "ExportInsightsV1Deprecated" + | "ExplorerBasicInvalidQueryName" + | "ExplorerBasicInvalidQueryDescription" + | "ExplorerBasicInvalidQueryConditions" + | "ExplorerBasicInvalidQueryStartDate" + | "ExplorerBasicInvalidQueryEndDate" + | "ExplorerBasicInvalidQueryGroupBy" + | "ExplorerBasicInvalidQueryAggregateType" + | "ExplorerBasicInvalidQueryAggregateProperty" + | "ExplorerBasicLoadQueriesError" + | "ExplorerBasicLoadQueryError" + | "ExplorerBasicCreateQueryError" + | "ExplorerBasicDeleteQueryError" + | "ExplorerBasicUpdateQueryError" + | "ExplorerBasicSavedQueriesLimit" + | "ExplorerBasicSavedQueryNotFound" + | "TenantShardMapperShardNotFound" + | "TitleNotEnabledForParty" + | "PartyVersionNotFound" + | "MultiplayerServerBuildReferencedByMatchmakingQueue" + | "MultiplayerServerBuildReferencedByBuildAlias" + | "MultiplayerServerBuildAliasReferencedByMatchmakingQueue" + | "PartySerializationError" + | "ExperimentationExperimentStopped" + | "ExperimentationExperimentRunning" + | "ExperimentationExperimentNotFound" + | "ExperimentationExperimentNeverStarted" + | "ExperimentationExperimentDeleted" + | "ExperimentationClientTimeout" + | "ExperimentationInvalidVariantConfiguration" + | "ExperimentationInvalidVariableConfiguration" + | "ExperimentInvalidId" + | "ExperimentationNoScorecard" + | "ExperimentationTreatmentAssignmentFailed" + | "ExperimentationTreatmentAssignmentDisabled" + | "ExperimentationInvalidDuration" + | "ExperimentationMaxExperimentsReached" + | "ExperimentationExperimentSchedulingInProgress" + | "ExperimentationInvalidEndDate" + | "ExperimentationInvalidStartDate" + | "ExperimentationMaxDurationExceeded" + | "ExperimentationExclusionGroupNotFound" + | "ExperimentationExclusionGroupInsufficientCapacity" + | "ExperimentationExclusionGroupCannotDelete" + | "ExperimentationExclusionGroupInvalidTrafficAllocation" + | "ExperimentationExclusionGroupInvalidName" + | "ExperimentationLegacyExperimentInvalidOperation" + | "ExperimentationExperimentStopFailed" + | "ExperimentationExperimentDeleteFailed" + | "ExperimentationExperimentStartFailed" + | "MaxActionDepthExceeded" + | "TitleNotOnUpdatedPricingPlan" + | "SegmentManagementTitleNotInFlight" + | "SegmentManagementNoExpressionTree" + | "SegmentManagementTriggerActionCountOverLimit" + | "SegmentManagementSegmentCountOverLimit" + | "SegmentManagementInvalidSegmentId" + | "SegmentManagementInvalidInput" + | "SegmentManagementInvalidSegmentName" + | "DeleteSegmentRateLimitExceeded" + | "CreateSegmentRateLimitExceeded" + | "UpdateSegmentRateLimitExceeded" + | "GetSegmentsRateLimitExceeded" + | "AsyncExportNotInFlight" + | "AsyncExportNotFound" + | "AsyncExportRateLimitExceeded" + | "AnalyticsSegmentCountOverLimit" + | "GetSegmentPlayerCountNotInFlight" + | "GetSegmentPlayerCountRateLimitExceeded" + | "SnapshotNotFound" + | "InventoryApiNotImplemented" + | "InventoryCollectionDeletionDisallowed" + | "LobbyDoesNotExist" + | "LobbyRateLimitExceeded" + | "LobbyPlayerAlreadyJoined" + | "LobbyNotJoinable" + | "LobbyMemberCannotRejoin" + | "LobbyCurrentPlayersMoreThanMaxPlayers" + | "LobbyPlayerNotPresent" + | "LobbyBadRequest" + | "LobbyPlayerMaxLobbyLimitExceeded" + | "LobbyNewOwnerMustBeConnected" + | "LobbyCurrentOwnerStillConnected" + | "LobbyMemberIsNotOwner" + | "LobbyServerMismatch" + | "LobbyServerNotFound" + | "LobbyDifferentServerAlreadyJoined" + | "LobbyServerAlreadyJoined" + | "LobbyIsNotClientOwned" + | "LobbyDoesNotUseConnections" + | "EventSamplingInvalidRatio" + | "EventSamplingInvalidEventNamespace" + | "EventSamplingInvalidEventName" + | "EventSamplingRatioNotFound" + | "TelemetryKeyNotFound" + | "TelemetryKeyInvalidName" + | "TelemetryKeyAlreadyExists" + | "TelemetryKeyInvalid" + | "TelemetryKeyCountOverLimit" + | "TelemetryKeyDeactivated" + | "TelemetryKeyLongInsightsRetentionNotAllowed" + | "EventSinkConnectionInvalid" + | "EventSinkConnectionUnauthorized" + | "EventSinkRegionInvalid" + | "EventSinkLimitExceeded" + | "EventSinkSasTokenInvalid" + | "EventSinkNotFound" + | "EventSinkNameInvalid" + | "EventSinkSasTokenPermissionInvalid" + | "EventSinkSecretInvalid" + | "EventSinkTenantNotFound" + | "EventSinkAadNotFound" + | "EventSinkDatabaseNotFound" + | "EventSinkTitleUnauthorized" + | "EventSinkInsufficientRoleAssignment" + | "EventSinkContainerNotFound" + | "EventSinkTenantIdInvalid" + | "EventSinkResourceMisconfigured" + | "EventSinkAccessDenied" + | "EventSinkWriteConflict" + | "EventSinkResourceNotFound" + | "EventSinkResourceFeatureNotSupported" + | "EventSinkBucketNameInvalid" + | "EventSinkResourceUnavailable" + | "OperationCanceled" + | "InvalidDisplayNameRandomSuffixLength" + | "AllowNonUniquePlayerDisplayNamesDisableNotAllowed" + | "PartitionedEventInvalid" + | "PartitionedEventCountOverLimit" + | "ManageEventNamespaceInvalid" + | "ManageEventNameInvalid" + | "ManagedEventNotFound" + | "ManageEventsInvalidRatio" + | "ManagedEventInvalid" + | "PlayerCustomPropertiesPropertyNameTooLong" + | "PlayerCustomPropertiesPropertyNameIsInvalid" + | "PlayerCustomPropertiesStringPropertyValueTooLong" + | "PlayerCustomPropertiesValueIsInvalidType" + | "PlayerCustomPropertiesVersionMismatch" + | "PlayerCustomPropertiesPropertyCountTooHigh" + | "PlayerCustomPropertiesDuplicatePropertyName" + | "PlayerCustomPropertiesPropertyDoesNotExist" + | "AddonAlreadyExists" + | "AddonDoesntExist" + | "TrueSkillUnauthorized" + | "TrueSkillInvalidTitleId" + | "TrueSkillInvalidScenarioId" + | "TrueSkillInvalidModelId" + | "TrueSkillInvalidModelName" + | "TrueSkillInvalidPlayerIds" + | "TrueSkillInvalidEntityKey" + | "TrueSkillInvalidConditionKey" + | "TrueSkillInvalidConditionValue" + | "TrueSkillInvalidConditionAffinityWeight" + | "TrueSkillInvalidEventName" + | "TrueSkillMatchResultCreated" + | "TrueSkillMatchResultAlreadySubmitted" + | "TrueSkillBadPlayerIdInMatchResult" + | "TrueSkillInvalidBotIdInMatchResult" + | "TrueSkillDuplicatePlayerInMatchResult" + | "TrueSkillNoPlayerInMatchResultTeam" + | "TrueSkillPlayersInMatchResultExceedingLimit" + | "TrueSkillInvalidPreMatchPartyInMatchResult" + | "TrueSkillInvalidTimestampInMatchResult" + | "TrueSkillStartTimeMissingInMatchResult" + | "TrueSkillEndTimeMissingInMatchResult" + | "TrueSkillInvalidPlayerSecondsPlayedInMatchResult" + | "TrueSkillNoTeamInMatchResult" + | "TrueSkillNotEnoughTeamsInMatchResult" + | "TrueSkillInvalidRanksInMatchResult" + | "TrueSkillNoWinnerInMatchResult" + | "TrueSkillMissingRequiredCondition" + | "TrueSkillMissingRequiredEvent" + | "TrueSkillUnknownEventName" + | "TrueSkillInvalidEventCount" + | "TrueSkillUnknownConditionKey" + | "TrueSkillUnknownConditionValue" + | "TrueSkillScenarioConfigDoesNotExist" + | "TrueSkillUnknownModelId" + | "TrueSkillNoModelInScenario" + | "TrueSkillNotSupportedForTitle" + | "TrueSkillModelIsNotActive" + | "TrueSkillUnauthorizedToQueryOtherPlayerSkills" + | "TrueSkillInvalidMaxIterations" + | "TrueSkillEndTimeBeforeStartTime" + | "TrueSkillInvalidJobId" + | "TrueSkillInvalidMetadataId" + | "TrueSkillMissingBuildVerison" + | "TrueSkillJobAlreadyExists" + | "TrueSkillJobNotFound" + | "TrueSkillOperationCanceled" + | "TrueSkillActiveModelLimitExceeded" + | "TrueSkillTotalModelLimitExceeded" + | "TrueSkillUnknownInitialModelId" + | "TrueSkillUnauthorizedForJob" + | "TrueSkillInvalidScenarioName" + | "TrueSkillConditionStateIsRequired" + | "TrueSkillEventStateIsRequired" + | "TrueSkillDuplicateEvent" + | "TrueSkillDuplicateCondition" + | "TrueSkillInvalidAnomalyThreshold" + | "TrueSkillConditionKeyLimitExceeded" + | "TrueSkillConditionValuePerKeyLimitExceeded" + | "TrueSkillInvalidTimestamp" + | "TrueSkillEventLimitExceeded" + | "TrueSkillInvalidPlayers" + | "TrueSkillTrueSkillPlayerNull" + | "TrueSkillInvalidPlayerId" + | "TrueSkillInvalidSquadSize" + | "TrueSkillConditionSetNotInModel" + | "TrueSkillModelStateInvalidForOperation" + | "TrueSkillScenarioContainsActiveModel" + | "TrueSkillInvalidConditionRank" + | "TrueSkillTotalScenarioLimitExceeded" + | "TrueSkillInvalidConditionsList" + | "GameSaveManifestNotFound" + | "GameSaveManifestVersionAlreadyExists" + | "GameSaveConflictUpdatingManifest" + | "GameSaveManifestUpdatesNotAllowed" + | "GameSaveFileAlreadyExists" + | "GameSaveManifestVersionNotFinalized" + | "GameSaveUnknownFileInManifest" + | "GameSaveFileExceededReportedSize" + | "GameSaveFileNotUploaded" + | "GameSaveBadRequest" + | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" + | "GameSaveBaseVersionNotAvailable" + | "GameSaveManifestVersionQuarantined" + | "GameSaveManifestUploadProgressUpdateNotAllowed" + | "GameSaveNotFinalizedManifestNotEligibleAsKnownGood" + | "GameSaveNoUpdatesRequested" + | "GameSaveTitleDoesNotExist" + | "GameSaveOperationNotAllowedForTitle" + | "GameSaveManifestFilesLimitExceeded" + | "GameSaveManifestDescriptionUpdateNotAllowed" + | "GameSaveTitleConfigNotFound" + | "GameSaveTitleAlreadyOnboarded" + | "GameSaveServiceNotEnabledForTitle" + | "GameSaveServiceOnboardingPending" + | "GameSaveManifestNotEligibleAsConflictingVersion" + | "GameSaveServiceUnavailable" + | "GameSaveConflict" + | "GameSaveManifestNotEligibleForRollback" + | "GameSaveTitleClientAnonymousAccountCreationNotDisabled" + | "GameSaveTitleConfigNoUpdatesRequested" + | "GameSavePlayerNotEligibleForTransfer" + | "GameSaveAlreadyAutoRolledBack" + | "GameSaveManifestNotEligibleForRestore" + | "GameSaveManifestArchived" + | "StateShareForbidden" + | "StateShareTitleNotInFlight" + | "StateShareStateNotFound" + | "StateShareLinkNotFound" + | "StateShareStateRedemptionLimitExceeded" + | "StateShareStateRedemptionLimitNotUpdated" + | "StateShareCreatedStatesLimitExceeded" + | "StateShareIdMissingOrMalformed" + | "PlayerCreationDisabled" + | "AccountAlreadyExists" + | "TagInvalid" + | "TagTooLong" + | "StatisticColumnAggregationMismatch" + | "StatisticResetIntervalMismatch" + | "VersionConfigurationCannotBeSpecifiedForLinkedStat" + | "VersionConfigurationIsRequired" + | "InvalidEntityTypeForAggregation" + | "MultiLevelAggregationNotAllowed" + | "AggregationTypeNotAllowedForLinkedStat" + | "OperationDeniedDueToDefinitionPolicy" + | "StatisticUpdateNotAllowedWhileLinked" + | "UnsupportedEntityType" + | "EntityTypeSpecifiedRequiresAggregationSource" + | "PlayFabErrorEventNotSupportedForEntityType" + | "MetadataLengthExceeded" + | "MaxQueryableVersionsExceeded" + | "StatisticVersionIncrementNotAllowedWhileLinked" + | "StoreMetricsRequestInvalidInput" + | "StoreMetricsErrorRetrievingMetrics"; + export interface GetActionsOnPlayersInSegmentTaskInstanceResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Status summary of the actions-on-players-in-segment task instance - */ - Summary?: ActionsOnPlayersInSegmentTaskSummary; - /** - / Parameter of this task instance - */ + /** Parameter of this task instance */ Parameter?: ActionsOnPlayersInSegmentTaskParameter; + /** Status summary of the actions-on-players-in-segment task instance */ + Summary?: ActionsOnPlayersInSegmentTaskSummary; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllActionGroupsRequest - */ - export interface GetAllActionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetAllIPBansRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllActionGroupsResult - */ - export interface GetAllActionGroupsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of Action Groups. - */ - ActionGroups: GetActionGroupResult[]; + export interface GetAllIPBansResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on all IP bans */ + IPBanData?: IPBanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllSegmentsRequest - */ export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetAllSegmentsResult - */ export interface GetAllSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments for this title. - */ + /** Array of segments for this title. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCatalogItemsRequest - */ export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptRevisionRequest - */ export interface GetCloudScriptRevisionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Version number. If left null, defaults to the latest version - */ - Version?: number; - /** - / Revision number. If left null, defaults to the latest revision - */ + /** Revision number. If left null, defaults to the latest revision */ Revision?: number; + /** Version number. If left null, defaults to the latest version */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptRevisionResult - */ export interface GetCloudScriptRevisionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Version number. - */ - Version: number; - /** - / Revision number. - */ - Revision: number; - /** - / Time this revision was created - */ + /** Time this revision was created */ CreatedAt: string; - /** - / List of Cloud Script files in this revision. - */ + /** List of Cloud Script files in this revision. */ Files?: CloudScriptFile[]; - /** - / True if this is the currently published revision - */ + /** True if this is the currently published revision */ IsPublished: boolean; + /** Revision number. */ + Revision: number; + /** Version number. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptTaskInstanceResult - */ export interface GetCloudScriptTaskInstanceResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Status summary of the CloudScript task instance - */ - Summary?: CloudScriptTaskSummary; - /** - / Parameter of this task instance - */ + /** Parameter of this task instance */ Parameter?: CloudScriptTaskParameter; + /** Status summary of the CloudScript task instance */ + Summary?: CloudScriptTaskSummary; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptVersionsRequest - */ export interface GetCloudScriptVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetCloudScriptVersionsResult - */ export interface GetCloudScriptVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of versions - */ + /** List of versions */ Versions?: CloudScriptVersionStatus[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentListRequest - */ export interface GetContentListRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Limits the response to keys that begin with the specified prefix. You can use prefixes to list contents under a folder, or for a specified version, etc. + * Limits the response to keys that begin with the specified prefix. You can use prefixes to list contents under a folder, + * or for a specified version, etc. */ Prefix?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentListResult - */ export interface GetContentListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Number of content items returned. We currently have a maximum of 1000 items limit. - */ + /** List of content items. */ + Contents?: ContentInfo[]; + /** Number of content items returned. We currently have a maximum of 1000 items limit. */ ItemCount: number; - /** - / The total size of listed contents in bytes. - */ + /** The total size of listed contents in bytes. */ TotalSize: number; - /** - / List of content items. - */ - Contents?: ContentInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentUploadUrlRequest - */ export interface GetContentUploadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Key of the content item to upload, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. + * A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when + * uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. */ ContentType?: string; + /** Key of the content item to upload, usually formatted as a path, e.g. images/a.png */ + Key: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetContentUploadUrlResult - */ export interface GetContentUploadUrlResult extends PlayFabModule.IPlayFabResultCommon { /** - / URL for uploading content via HTTP PUT method. The URL will expire in 1 hour. + * URL for uploading content via HTTP PUT method. The URL requires the 'x-ms-blob-type' header to have the value + * 'BlockBlob'. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetDataReportRequest - */ export interface GetDataReportRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Report name - */ + /** Reporting year (UTC) */ + Day: number; + /** Reporting month (UTC) */ + Month: number; + /** Report name */ ReportName: string; - /** - / Reporting year (UTC) - */ + /** Reporting year (UTC) */ Year: number; - /** - / Reporting month (UTC) - */ - Month: number; - /** - / Reporting year (UTC) - */ - Day: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetDataReportResult - */ export interface GetDataReportResult extends PlayFabModule.IPlayFabResultCommon { /** - / The URL where the requested report can be downloaded. + * The URL where the requested report can be downloaded. This can be any PlayFab generated reports. The full list of + * reports can be found at: https://docs.microsoft.com/en-us/gaming/playfab/features/analytics/reports/quickstart. */ DownloadUrl?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameInfoRequest - */ - export interface GetMatchmakerGameInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the lobby for which info is being requested - */ - LobbyId: string; + export interface GetIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The IP address of the ban to retrieve information on. */ + IPAddress: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameInfoResult - */ - export interface GetMatchmakerGameInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier of the lobby - */ - LobbyId?: string; - /** - / unique identifier of the Game Server Instance for this lobby - */ - TitleId?: string; - /** - / time when the Game Server Instance was created - */ - StartTime: string; - /** - / time when Game Server Instance is currently scheduled to end - */ - EndTime?: string; - /** - / game mode for this Game Server Instance - */ - Mode?: string; - /** - / version identifier of the game server executable binary being run - */ - BuildVersion?: string; - /** - / region in which the Game Server Instance is running - */ - Region?: string; - /** - / array of unique PlayFab identifiers for users currently connected to this Game Server Instance - */ - Players?: string[]; - /** - / IP address for this Game Server Instance - */ - ServerAddress?: string; - /** - / communication port for this Game Server Instance - */ - ServerPort: number; + export interface GetIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban */ + IPBanData?: IPBanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameModesRequest - */ - export interface GetMatchmakerGameModesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / previously uploaded build version for which game modes are being requested - */ - BuildVersion: string; + export interface GetPlayedTitleListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetMatchmakerGameModesResult - */ - export interface GetMatchmakerGameModesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of game modes available for the specified build - */ - GameModes?: GameModeInfo[]; + export interface GetPlayedTitleListResult extends PlayFabModule.IPlayFabResultCommon { + /** List of titles the player has played */ + TitleIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerSegmentsResult - */ - export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments the requested player currently belongs to. - */ - Segments?: GetSegmentResult[]; + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Specific property name to search for in the player's properties. */ + PropertyName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersInSegmentRequest - */ - export interface GetPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for this segment. - */ - SegmentId: string; - /** - / Number of seconds to keep the continuation token active. After token expiration it is not possible to continue paging results. Default is 300 (5 minutes). Maximum is 1,800 (30 minutes). - */ - SecondsToLive?: number; - /** - / Maximum number of profiles to load. Default is 1,000. Maximum is 10,000. - */ - MaxBatchSize?: number; + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; /** - / Continuation token if retrieving subsequent pages of results. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - ContinuationToken?: string; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersInSegmentResult - */ - export interface GetPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Count of profiles matching this segment. - */ - ProfilesInSegment: number; - /** - / Continuation token to use to retrieve subsequent pages of results. If token returns null there are no more results. - */ - ContinuationToken?: string; + export interface GetPlayerIdFromAuthTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The auth token of the player requesting the password reset. */ + Token: string; + /** The type of auth token of the player requesting the password reset. */ + TokenType: string; + + } + + export interface GetPlayerIdFromAuthTokenResult extends PlayFabModule.IPlayFabResultCommon { + /** The player ID from the token passed in */ + PlayFabId?: string; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / Array of player profiles in this segment. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - PlayerProfiles?: PlayerProfile[]; + ProfileConstraints?: PlayerProfileViewConstraints; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayersSegmentsRequest - */ - export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - PlayFabId: string; + PlayerProfile?: PlayerProfileModel; + + } + + export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of segments the requested player currently belongs to. */ + Segments?: GetSegmentResult[]; + + } + + export interface GetPlayerSharedSecretsRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface GetPlayerSharedSecretsResult extends PlayFabModule.IPlayFabResultCommon { + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SharedSecrets?: SharedSecret[]; + + } + + export interface GetPlayersInSegmentExportRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId: string; + + } + + export interface GetPlayersInSegmentExportResponse extends PlayFabModule.IPlayFabResultCommon { + /** Url from which the index file can be downloaded. */ + IndexUrl?: string; + /** Shows the current status of the export */ + State?: string; + + } + + export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticDefinitionsRequest - */ export interface GetPlayerStatisticDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticDefinitionsResult - */ export interface GetPlayerStatisticDefinitionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / the player statistic definitions for the title - */ + /** the player statistic definitions for the title */ Statistics?: PlayerStatisticDefinition[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticVersionsRequest - */ export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerStatisticVersionsResult - */ export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ + /** version change history of the statistic */ StatisticVersions?: PlayerStatisticVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerTagsRequest - */ export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Optional namespace to filter results by - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPlayerTagsResult - */ export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ + /** Canonical tags (including namespace and tag's name) for the requested user */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPolicyRequest - */ export interface GetPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / The name of the policy to read. Only supported name is 'ApiPolicy'. + * The name of the policy to read. Only 'ApiPolicy' is supported. This parameter is optional and defaults to 'ApiPolicy' if + * omitted. */ PolicyName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPolicyResponse - */ export interface GetPolicyResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the policy read. - */ + /** The UTC date and time when the policy was last updated. Null if the policy has never been customized. */ + LastUpdated?: string; + /** The name of the policy read. */ PolicyName?: string; - /** - / The statements in the requested policy. - */ + /** Policy version. */ + PolicyVersion: number; + /** The statements in the requested policy. */ Statements?: PermissionStatement[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPublisherDataRequest - */ export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ Keys: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetPublisherDataResult - */ export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetRandomResultTablesRequest - */ export interface GetRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to fetch tables from. Use default catalog version if null - */ + /** catalog version to fetch tables from. Use default catalog version if null */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetRandomResultTablesResult - */ export interface GetRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of random result tables currently available - */ + /** array of random result tables currently available */ Tables?: { [key: string]: RandomResultTableListing }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ - Id: string; - /** - / Segment name. - */ - Name?: string; - /** - / Identifier of the segments AB Test, if it is attached to one. - */ - ABTestParent?: string; + export interface GetSegmentPlayerCountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the requested segment. */ + SegmentId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildInfoRequest - */ - export interface GetServerBuildInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable for which information is being requested - */ - BuildId: string; + export interface GetSegmentPlayerCountResult extends PlayFabModule.IPlayFabResultCommon { + /** Count of profiles matching this segment. */ + ProfilesInSegment: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildInfoResult - */ - export interface GetServerBuildInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / developer comment(s) for this build - */ - Comment?: string; - /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / the current status of the build validation and processing steps - */ - Status?: string; - /** - / error message, if any, about this build - */ - ErrorMessage?: string; + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ + Id: string; + /** Segment name. */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildUploadURLRequest - */ - export interface GetServerBuildUploadURLRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the game server build to upload - */ - BuildId: string; + export interface GetSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment ids to filter title segments. */ + SegmentIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetServerBuildUploadURLResult - */ - export interface GetServerBuildUploadURLResult extends PlayFabModule.IPlayFabResultCommon { - /** - / pre-authorized URL for uploading the game server build package - */ - URL?: string; + export interface GetSegmentsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** List of title segments. */ + Segments?: SegmentModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetStoreItemsRequest - */ export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to store items from. Use default catalog version if null - */ + /** Catalog version to store items from. Use default catalog version if null */ CatalogVersion?: string; - /** - / Unqiue identifier for the store which is being requested. - */ + /** Unqiue identifier for the store which is being requested. */ StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetStoreItemsResult - */ export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased from this store. - */ - Store?: StoreItem[]; - /** - / How the store was last updated (Admin or a third party). - */ - Source?: string; - /** - / The base catalog that this store is a part of. - */ + /** The base catalog that this store is a part of. */ CatalogVersion?: string; - /** - / The ID of this store. - */ - StoreId?: string; - /** - / Additional data about the store. - */ + /** Additional data about the store. */ MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstanceRequest - */ export interface GetTaskInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / ID of the requested task instance. - */ + /** ID of the requested task instance. */ TaskInstanceId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstancesRequest - */ export interface GetTaskInstancesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name or ID of the task whose instances are being queried. If not specified, return all task instances that satisfy conditions set by other filters. - */ - TaskIdentifier?: NameIdentifier; - /** - / Optional filter for task instances that are of a specific status. - */ - StatusFilter?: string; - /** - / Optional range-from filter for task instances' StartedAt timestamp. - */ + /** Optional range-from filter for task instances' StartedAt timestamp. */ StartedAtRangeFrom?: string; + /** Optional range-to filter for task instances' StartedAt timestamp. */ + StartedAtRangeTo?: string; + /** Optional filter for task instances that are of a specific status. */ + StatusFilter?: string; /** - / Optional range-to filter for task instances' StartedAt timestamp. + * Name or ID of the task whose instances are being queried. If not specified, return all task instances that satisfy + * conditions set by other filters. */ - StartedAtRangeTo?: string; + TaskIdentifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTaskInstancesResult - */ export interface GetTaskInstancesResult extends PlayFabModule.IPlayFabResultCommon { /** - / Basic status summaries of the queried task instances. Empty If no task instances meets the filter criteria. To get detailed status summary, use Get*TaskInstance API according to task type (e.g. GetActionsOnPlayersInSegmentTaskInstance). + * Basic status summaries of the queried task instances. Empty If no task instances meets the filter criteria. To get + * detailed status summary, use Get*TaskInstance API according to task type (e.g. + * GetActionsOnPlayersInSegmentTaskInstance). */ Summaries?: TaskInstanceBasicSummary[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTasksRequest - */ export interface GetTasksRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Provide either the task ID or the task name to get a specific task. If not specified, return all defined tasks. - */ + /** Provide either the task ID or the task name to get a specific task. If not specified, return all defined tasks. */ Identifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTasksResult - */ export interface GetTasksResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Result tasks. Empty if there is no task found. - */ + /** Result tasks. Empty if there is no task found. */ Tasks?: ScheduledTask[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTitleDataRequest - */ export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Specific keys to search for in the title data (leave null to get all keys) + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - Keys?: string[]; + OverrideLabel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetTitleDataResult - */ export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserBansRequest - */ export interface GetUserBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserBansResult - */ export interface GetUserBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the bans - */ + /** Information about the bans */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { + /** User specific data for this title. */ + Data?: { [key: string]: UserDataRecord }; /** - / PlayFab unique identifier of the user whose custom data is being returned. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; - /** - / User specific data for this title. - */ - Data?: { [key: string]: UserDataRecord }; + /** PlayFab unique identifier of the user whose custom data is being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantedItemInstance - */ export interface GrantedItemInstance { + /** Game specific comment associated with this instance when it was added to the user inventory. */ + Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ + BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Result of this operation. - */ - Result: boolean; - /** - / Unique identifier for the inventory item, as defined in the catalog. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ + DisplayName?: string; + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ + /** Unique item identifier for this specific instance of the item. */ ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Timestamp for when this instance was purchased. */ PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ + /** Total number of remaining uses, if this is a consumable item. */ RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Result of this operation. */ + Result: boolean; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface GrantItemContent { + /** The catalog version of the item to be granted to the player */ + CatalogVersion?: string; + /** The id of item to be granted to the player */ + ItemId?: string; + /** Quantity of the item to be granted to a player */ + ItemQuantity: number; + + } + + export interface GrantItemSegmentAction { + /** Item catalog id. */ + CatelogId?: string; + /** Item id. */ + ItemId?: string; + /** Item quantity. */ + Quantity: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantItemsToUsersRequest - */ export interface GrantItemsToUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Array of items to grant and the users to whom the items are to be granted. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to grant and the users to whom the items are to be granted. */ ItemGrants: ItemGrant[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.GrantItemsToUsersResult - */ export interface GrantItemsToUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.IncrementPlayerStatisticVersionRequest - */ - export interface IncrementPlayerStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ - StatisticName?: string; + export interface GrantVirtualCurrencyContent { + /** Amount of currency to be granted to a player */ + CurrencyAmount: number; + /** Code of the currency to be granted to a player */ + CurrencyCode: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.IncrementPlayerStatisticVersionResult - */ - export interface IncrementPlayerStatisticVersionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ - StatisticVersion?: PlayerStatisticVersion; + export interface GrantVirtualCurrencySegmentAction { + /** Virtual currency amount. */ + Amount: number; + /** Virtual currency code. */ + CurrencyCode?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ItemGrant - */ - export interface ItemGrant { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the catalog item to be granted to the user. - */ + export interface IncrementLimitedEditionItemAvailabilityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Amount to increase availability by. */ + Amount: number; + /** Which catalog is being updated. If null, uses the default catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The item which needs more availability. */ ItemId: string; - /** - / String detailing any additional information concerning this operation. - */ - Annotation?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface IncrementLimitedEditionItemAvailabilityResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface IncrementPlayerStatisticContent { + /** Amount(in whole number) to increase the player statistic by */ + StatisticChangeBy: number; + /** Name of the player statistic to be incremented */ + StatisticName: string; + + } + + export interface IncrementPlayerStatisticSegmentAction { + /** Increment value. */ + IncrementValue: number; + /** Statistic name. */ + StatisticName?: string; + + } + + export interface IncrementPlayerStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ + StatisticName?: string; + + } + + export interface IncrementPlayerStatisticVersionResult extends PlayFabModule.IPlayFabResultCommon { + /** version change history of the statistic */ + StatisticVersion?: PlayerStatisticVersion; + + } + + export interface InsightsScalingTaskParameter { + /** Insights Performance Level to scale to. */ + Level: number; + + } + + export interface IPBanInfo { + /** The active state of this ban. */ + Active: boolean; + /** PlayFab Developer ID of who issued the ban. Null if ban issued via Title Secret Key. */ + BannedByDeveloperId?: string; + /** The time when this IP ban was applied. */ + Created?: string; + /** The time when this ban expires. Permanent bans do not have expiration date. */ + Expires?: string; + /** The IP address on which the ban was applied. */ + IPAddress?: string; + /** The reason why this IP ban was applied. */ + Reason?: string; + + } + + export interface ItemGrant { + /** String detailing any additional information concerning this operation. */ + Annotation?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; + /** Unique identifier of the catalog item to be granted to the user. */ + ItemId: string; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface LastLoginDateSegmentFilter { + /** Last player login date comparison. */ + Comparison?: string; + /** Last player login date. */ + LogInDate: string; + + } + + export interface LastLoginTimespanSegmentFilter { + /** Last player login duration comparison. */ + Comparison?: string; + /** Last player login duration. */ + DurationInMinutes: number; + + } + + export interface LinkedPlatformAccountModel { + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ + Platform?: string; + /** Unique account identifier of the user on the platform */ + PlatformUserId?: string; + /** Linked account username of the user on the platform, if available */ + Username?: string; + + } + + export interface LinkedUserAccountHasEmailSegmentFilter { + /** Login provider comparison. */ + Comparison?: string; + /** Login provider. */ + LoginProvider?: string; + + } + + export interface LinkedUserAccountSegmentFilter { + /** Login provider. */ + LoginProvider?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListBuildsRequest - */ - export interface ListBuildsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface ListOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListBuildsResult - */ - export interface ListBuildsResult extends PlayFabModule.IPlayFabResultCommon { + export interface ListOpenIdConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of Open ID Connections */ + Connections?: OpenIdConnection[]; + + } + + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / array of uploaded game server builds + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Builds?: GetServerBuildInfoResult[]; + PropertiesVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListVirtualCurrencyTypesRequest - */ export interface ListVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ListVirtualCurrencyTypesResult - */ export interface ListVirtualCurrencyTypesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of virtual currency names defined for this title - */ + /** List of virtual currency names defined for this title */ VirtualCurrencies?: VirtualCurrencyData[]; } + export interface LocationModel { + /** City name. */ + City?: string; + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ + Latitude?: number; + /** Longitude coordinate of the geographic location. */ + Longitude?: number; + + } + + export interface LocationSegmentFilter { + /** Segment country code. */ + CountryCode?: string; + + } + type LoginIdentityProvider = "Unknown" + | "PlayFab" | "Custom" | "GameCenter" @@ -2870,1677 +3947,2079 @@ declare module PlayFabAdminModels { | "IOSDevice" | "AndroidDevice" | "Twitch" - | "WindowsHello"; + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LogStatement - */ export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ Level?: string; Message?: string; - /** - / Optional object accompanying the message as contextual information - */ - Data?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LookupUserAccountInfoRequest - */ export interface LookupUserAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / User email address attached to their account - */ + /** User email address attached to their account */ Email?: string; - /** - / PlayFab username for the account (3-20 characters) - */ - Username?: string; - /** - / Title specific username to match against existing user accounts - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Title specific username to match against existing user accounts */ TitleDisplayName?: string; + /** PlayFab username for the account (3-20 characters) */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.LookupUserAccountInfoResult - */ export interface LookupUserAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User info for the user matching the request - */ + /** User info for the user matching the request */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyMatchmakerGameModesRequest - */ - export interface ModifyMatchmakerGameModesRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / previously uploaded build version for which game modes are being specified + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - BuildVersion: string; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; + + } + + export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / array of game modes (Note: this will replace all game modes for the indicated build version) + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ - GameModes: GameModeInfo[]; + BalanceChange: number; + /** User currency was subtracted from. */ + PlayFabId?: string; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyMatchmakerGameModesResult - */ - export interface ModifyMatchmakerGameModesResult extends PlayFabModule.IPlayFabResultCommon { + export interface NameIdentifier { + /** Id Identifier, if present */ + Id?: string; + /** Name Identifier, if present */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyServerBuildRequest - */ - export interface ModifyServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable to be updated - */ - BuildId: string; - /** - / new timestamp - */ - Timestamp?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ - Comment?: string; + type NewsStatus = "None" + + | "Unpublished" + | "Published" + | "Archived"; + + export interface OpenIdConnection { + /** The client ID given by the ID provider. */ + ClientId?: string; + /** The client secret given by the ID provider. */ + ClientSecret?: string; + /** A name for the connection to identify it within the title. */ + ConnectionId?: string; + /** Shows if data about the connection will be loaded from the issuer's discovery document */ + DiscoverConfiguration: boolean; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; + /** Information for an OpenID Connect provider. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyServerBuildResult - */ - export interface ModifyServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for this build executable - */ - BuildId?: string; - /** - / array of regions where this build can used, when it is active - */ - ActiveRegions?: string[]; - /** - / maximum number of game server instances that can run on a single host machine - */ - MaxGamesPerHost: number; - /** - / minimum capacity of additional game server instances that can be started before the autoscaling service starts new host machines (given the number of current running host machines and game server instances) - */ - MinFreeGameSlots: number; - /** - / appended to the end of the command line when starting game servers - */ - CommandLineTemplate?: string; - /** - / path to the game server executable. Defaults to gameserver.exe - */ - ExecutablePath?: string; - /** - / developer comment(s) for this build - */ + export interface OpenIdIssuerInformation { + /** Authorization endpoint URL to direct users to for signin. */ + AuthorizationUrl: string; + /** The URL of the issuer of the tokens. This must match the exact URL of the issuer field in tokens. */ + Issuer: string; + /** JSON Web Key Set for validating the signature of tokens. */ + JsonWebKeySet: any; + /** Token endpoint URL for code verification. */ + TokenUrl: string; + + } + + export interface PermissionStatement { + /** The action this statement effects. May only be '*'. This parameter is optional and defaults to '*' if omitted. */ + Action?: string; + /** Additional conditions to be applied for API Resources. */ + ApiConditions?: ApiCondition; + /** A comment about the statement. Intended solely for bookkeeping and debugging. */ Comment?: string; + /** The effect this statement will have. It could be either Allow or Deny */ + Effect: string; /** - / time this build was last modified (or uploaded, if this build has never been modified) - */ - Timestamp: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * The principal this statement will effect. May be '*' to match all callers, or a JSON object targeting a specific entity + * type, e.g. {"title_player_account":"*"} for players or {"master_player_account":"*"} for master player accounts. */ - TitleId?: string; + Principal: string; /** - / the current status of the build validation and processing steps + * The resource this statements effects. The only supported resources look like 'pfrn:api--*' for all apis, or + * 'pfrn:api--/Client/ConfirmPurchase' for specific apis. */ - Status?: string; + Resource: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ModifyUserVirtualCurrencyResult - */ - export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User currency was subtracted from. - */ - PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface PlayerChurnPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.NameIdentifier - */ - export interface NameIdentifier { - Name?: string; - Id?: string; + export interface PlayerChurnPredictionTimeSegmentFilter { + /** Comparison */ + Comparison?: string; + /** DurationInDays */ + DurationInDays: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PermissionStatement - */ - export interface PermissionStatement { - /** - / The resource this statements effects. The only supported resources look like 'pfrn:api--*' for all apis, or 'pfrn:api--/Client/ConfirmPurchase' for specific apis. - */ - Resource: string; - /** - / The action this statement effects. The only supported action is 'Execute'. - */ - Action: string; - /** - / The effect this statement will have. It could be either Allow or Deny - */ - Effect: string; - /** - / The principal this statement will effect. The only supported principal is '*'. - */ - Principal: string; - /** - / A comment about the statement. Intended solely for bookeeping and debugging. - */ - Comment?: string; + export interface PlayerChurnPreviousPredictionSegmentFilter { + /** Comparison */ + Comparison?: string; + /** RiskLevel */ + RiskLevel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerLinkedAccount - */ - export interface PlayerLinkedAccount { - /** - / Authentication platform - */ - Platform?: string; - /** - / Platform user identifier - */ - PlatformUserId?: string; + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Linked account's username + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ - Username?: string; + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Linked account's email + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ - Email?: string; + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ + ShowBannedUntil: boolean; + /** Whether to show campaign attributions. Defaults to false */ + ShowCampaignAttributions: boolean; + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ + ShowLinkedAccounts: boolean; + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ + ShowTotalValueToDateInUsd: boolean; + /** Whether to show the values to date. Defaults to false */ + ShowValuesToDate: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerLocation - */ - export interface PlayerLocation { - /** - / The two-character continent code for this location - */ - ContinentCode: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode: string; - /** - / City of the player's geographic location. - */ - City?: string; - /** - / Latitude coordinate of the player's geographic location. - */ - Latitude?: number; - /** - / Longitude coordinate of the player's geographic location. - */ - Longitude?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerProfile - */ - export interface PlayerProfile { - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Player record created - */ - Created?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / Banned until UTC Date. If permanent ban this is set for 20 years after the original ban date. - */ - BannedUntil?: string; - /** - / Image URL of the player's avatar. - */ - AvatarUrl?: string; - /** - / Dictionary of player's statistics using only the latest version's value - */ - Statistics?: { [key: string]: number }; - /** - / A sum of player's total purchases in USD across all currencies. - */ - TotalValueToDateInUSD?: number; - /** - / Dictionary of player's total purchases by currency. - */ - ValuesToDate?: { [key: string]: number }; - /** - / List of player's tags for segmentation. - */ - Tags?: string[]; - /** - / Dictionary of player's locations by type. - */ - Locations?: { [key: string]: PlayerLocation }; - /** - / Dictionary of player's virtual currency balances - */ - VirtualCurrencyBalances?: { [key: string]: number }; - /** - / Array of ad campaigns player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttribution[]; - /** - / Array of configured push notification end points - */ - PushNotificationRegistrations?: PushNotificationRegistration[]; - /** - / Array of third party accounts linked to this player - */ - LinkedAccounts?: PlayerLinkedAccount[]; - /** - / Array of player statistics - */ - PlayerStatistics?: PlayerStatistic[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatistic - */ - export interface PlayerStatistic { - /** - / Statistic ID - */ - Id?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - StatisticVersion: number; - /** - / Current statistic value - */ - StatisticValue: number; - /** - / Statistic name - */ - Name?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatisticDefinition - */ export interface PlayerStatisticDefinition { - /** - / unique name of the statistic - */ - StatisticName?: string; - /** - / current active version of the statistic, incremented each time the statistic resets - */ + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** current active version of the statistic, incremented each time the statistic resets */ CurrentVersion: number; - /** - / interval at which the values of the statistic for all players are reset automatically - */ + /** unique name of the statistic */ + StatisticName?: string; + /** interval at which the values of the statistic for all players are reset automatically */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PlayerStatisticVersion - */ export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ - StatisticName?: string; - /** - / version of the statistic - */ - Version: number; - /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ + /** time when the statistic version became active */ ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval - */ - ScheduledDeactivationTime?: string; - /** - / time when the statistic version became inactive due to statistic version incrementing - */ + /** URL for the downloadable archive of player statistic values, if available */ + ArchiveDownloadUrl?: string; + /** time when the statistic version became inactive due to statistic version incrementing */ DeactivationTime?: string; - /** - / status of the process of saving player statistic values of the previous version to a downloadable archive - */ - ArchivalStatus?: string; - /** - / status of the statistic version - */ + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ + StatisticName?: string; + /** status of the statistic version */ Status?: string; + /** version of the statistic */ + Version: number; + + } + + export interface PolicyDiffSummary { + /** Number of new statements that would be added. */ + StatementsAdded: number; + /** Number of existing statements that would be removed. Only applicable when OverwritePolicy is true. */ + StatementsRemoved: number; /** - / URL for the downloadable archive of player statistic values, if available + * Number of existing statements that would be replaced by functionally equivalent incoming statements (e.g., same + * resource/effect/principal but different comment). */ - ArchiveDownloadUrl?: string; + StatementsReplaced: number; + /** Number of existing statements that would remain unchanged. */ + StatementsUnchanged: number; + /** Total number of statements in the resulting policy. */ + TotalResultingStatements: number; + + } + + export interface PushNotificationContent { + /** Text of message to send. */ + Message?: string; + /** Id of the push notification template. */ + PushNotificationTemplateId?: string; + /** Subject of message to send (may not be displayed in all platforms) */ + Subject?: string; } type PushNotificationPlatform = "ApplePushNotificationService" + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.PushNotificationRegistration - */ - export interface PushNotificationRegistration { - /** - / Push notification platform - */ - Platform?: string; - /** - / Notification configured endpoint - */ + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; + + } + + export interface PushNotificationSegmentAction { + /** Push notification template id. */ + PushNotificationTemplateId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RandomResultTable - */ + export interface PushNotificationSegmentFilter { + /** Push notification device platform. */ + PushNotificationDevicePlatform?: string; + + } + + type PushSetupPlatform = "GCM" + + | "APNS" + | "APNS_SANDBOX"; + export interface RandomResultTable { - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ + /** Child nodes that indicate what kind of drop table item this actually is. */ Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RandomResultTableListing - */ export interface RandomResultTableListing { - /** - / Catalog version this table is associated with - */ + /** Catalog version this table is associated with */ CatalogVersion?: string; - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ + /** Child nodes that indicate what kind of drop table item this actually is. */ Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RefundPurchaseRequest - */ export interface RefundPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique order ID for the purchase in question. - */ + /** Unique order ID for the purchase in question. */ OrderId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / Reason for refund. In the case of Facebook this must match one of their refund or dispute resolution enums (See: https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) + * The Reason parameter should correspond with the payment providers reason field, if they require one such as Facebook. In + * the case of Facebook this must match one of their refund or dispute resolution enums (See: + * https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) */ Reason?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RefundPurchaseResponse - */ export interface RefundPurchaseResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The order's updated purchase status. - */ + /** The order's updated purchase status. */ PurchaseStatus?: string; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemovePlayerTagRequest - */ export interface RemovePlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemovePlayerTagResult - */ export interface RemovePlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveServerBuildRequest - */ - export interface RemoveServerBuildRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique identifier of the previously uploaded build executable to be removed - */ - BuildId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveServerBuildResult - */ - export interface RemoveServerBuildResult extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RemoveVirtualCurrencyTypesRequest - */ export interface RemoveVirtualCurrencyTypesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of virtual currencies to delete - */ + /** List of virtual currencies to delete */ VirtualCurrencies: VirtualCurrencyData[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetCharacterStatisticsRequest - */ export interface ResetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetCharacterStatisticsResult - */ export interface ResetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUsersRequest - */ - export interface ResetUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of users to reset - */ - Users: UserCredentials[]; + export interface ResetPasswordRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new password for the player. */ + Password: string; + /** The token of the player requesting the password reset. */ + Token: string; + + } + + export interface ResetPasswordResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUserStatisticsRequest - */ export interface ResetUserStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResetUserStatisticsResult - */ export interface ResetUserStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } type ResolutionOutcome = "Revoke" + | "Reinstate" | "Manual"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResolvePurchaseDisputeRequest - */ export interface ResolvePurchaseDisputeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique order ID for the purchase in question. */ + OrderId: string; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Enum for the desired purchase result state after notifying the payment provider. Valid values are Revoke, Reinstate and + * Manual. Manual will cause no change to the order state. */ + Outcome: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; /** - / Unique order ID for the purchase in question. - */ - OrderId: string; - /** - / Reason for refund. In the case of Facebook this must match one of their refund or dispute resolution enums (See: https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) + * The Reason parameter should correspond with the payment providers reason field, if they require one such as Facebook. In + * the case of Facebook this must match one of their refund or dispute resolution enums (See: + * https://developers.facebook.com/docs/payments/implementation-guide/handling-disputes-refunds) */ Reason?: string; - /** - / Enum for the desired purchase result state after notifying the payment provider. Valid values are Revoke, Reinstate and Manual. Manual will cause no change to the order state. - */ - Outcome: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResolvePurchaseDisputeResponse - */ export interface ResolvePurchaseDisputeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The order's updated purchase status. - */ + /** The order's updated purchase status. */ PurchaseStatus?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ResultTableNode - */ export interface ResultTableNode { - /** - / Whether this entry in the table is an item or a link to another table - */ - ResultItemType: string; - /** - / Either an ItemId, or the TableId of another random result table - */ + /** Either an ItemId, or the TableId of another random result table */ ResultItem: string; - /** - / How likely this is to be rolled - larger numbers add more weight - */ + /** Whether this entry in the table is an item or a link to another table */ + ResultItemType: string; + /** How likely this is to be rolled - larger numbers add more weight */ Weight: number; } type ResultTableNodeType = "ItemId" + | "TableId"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeAllBansForUserRequest - */ export interface RevokeAllBansForUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeAllBansForUserResult - */ export interface RevokeAllBansForUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked. - */ + /** Information on the bans that were revoked. */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeBansRequest - */ export interface RevokeBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Ids of the bans to be revoked. Maximum 100. - */ + /** Ids of the bans to be revoked. Maximum 100. */ BanIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeBansResult - */ export interface RevokeBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked - */ + /** Information on the bans that were revoked */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeInventoryItemRequest - */ - export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface RevokeInventoryItem { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RevokeInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Array of player items to revoke, between 1 and 25 items. */ + Items: RevokeInventoryItem[]; + + } + + export interface RevokeInventoryItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** Collection of any errors that occurred during processing. */ + Errors?: RevokeItemError[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RevokeInventoryResult - */ export interface RevokeInventoryResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RunTaskRequest - */ + export interface RevokeIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The IP address of the ban to be revoked. */ + IPAddress: string; + + } + + export interface RevokeIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was revoked */ + IPBanData?: IPBanInfo; + + } + + export interface RevokeItemError { + /** Specific error that was encountered. */ + Error?: string; + /** Item information that failed to be revoked. */ + Item?: RevokeInventoryItem; + + } + export interface RunTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Provide either the task ID or the task name to run a task. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Provide either the task ID or the task name to run a task. */ Identifier?: NameIdentifier; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.RunTaskResult - */ export interface RunTaskResult extends PlayFabModule.IPlayFabResultCommon { /** - / ID of the task instance that is started. This can be used in Get*TaskInstance (e.g. GetCloudScriptTaskInstance) API call to retrieve status for the task instance. + * ID of the task instance that is started. This can be used in Get*TaskInstance (e.g. GetCloudScriptTaskInstance) API call + * to retrieve status for the task instance. */ TaskInstanceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ScheduledTask - */ export interface ScheduledTask { + /** Description the task */ + Description?: string; + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** UTC time of last run */ + LastRunTime?: string; + /** Name of the task. This is a unique identifier for tasks in the title. */ + Name: string; + /** UTC time of next run */ + NextRunTime?: string; /** - / ID of the task + * Task parameter. Different types of task have different parameter structure. See each task type's create API + * documentation for the details. */ + Parameter?: any; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ + Schedule?: string; + /** ID of the task */ TaskId?: string; - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ - Name?: string; - /** - / Description the task - */ - Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ - Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ - IsActive: boolean; - /** - / Task type. - */ + /** Task type. */ Type?: string; + + } + + type ScheduledTaskType = "CloudScript" + + | "ActionsOnPlayerSegment" + | "CloudScriptAzureFunctions" + | "InsightsScheduledScaling"; + + export interface ScriptExecutionError { /** - / Task parameter. Different types of task have different parameter structure. See each task type's create API documentation for the details. - */ - Parameter?: any; - /** - / UTC time of last run - */ - LastRunTime?: string; - /** - / UTC time of next run + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ - NextRunTime?: string; + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the script at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface SegmentAndDefinition { + /** Filter property for ad campaign filter. */ + AdCampaignFilter?: AdCampaignSegmentFilter; + /** property for all player filter. */ + AllPlayersFilter?: AllPlayersSegmentFilter; + /** Filter property for player churn risk level. */ + ChurnPredictionFilter?: ChurnPredictionSegmentFilter; + /** Filter property for boolean custom properties. */ + CustomPropertyBooleanFilter?: CustomPropertyBooleanSegmentFilter; + /** Filter property for datetime custom properties. */ + CustomPropertyDateTimeFilter?: CustomPropertyDateTimeSegmentFilter; + /** Filter property for numeric custom properties. */ + CustomPropertyNumericFilter?: CustomPropertyNumericSegmentFilter; + /** Filter property for string custom properties. */ + CustomPropertyStringFilter?: CustomPropertyStringSegmentFilter; + /** Filter property for first login date. */ + FirstLoginDateFilter?: FirstLoginDateSegmentFilter; + /** Filter property for first login timespan. */ + FirstLoginFilter?: FirstLoginTimespanSegmentFilter; + /** Filter property for last login date. */ + LastLoginDateFilter?: LastLoginDateSegmentFilter; + /** Filter property for last login timespan. */ + LastLoginFilter?: LastLoginTimespanSegmentFilter; + /** Filter property for linked in user account. */ + LinkedUserAccountFilter?: LinkedUserAccountSegmentFilter; + /** Filter property for linked in user account has email. */ + LinkedUserAccountHasEmailFilter?: LinkedUserAccountHasEmailSegmentFilter; + /** Filter property for location. */ + LocationFilter?: LocationSegmentFilter; + /** Filter property for current player churn value. */ + PlayerChurnPredictionFilter?: PlayerChurnPredictionSegmentFilter; + /** Filter property for player churn timespan. */ + PlayerChurnPredictionTimeFilter?: PlayerChurnPredictionTimeSegmentFilter; + /** Filter property for previous player churn value. */ + PlayerChurnPreviousPredictionFilter?: PlayerChurnPreviousPredictionSegmentFilter; + /** Filter property for push notification. */ + PushNotificationFilter?: PushNotificationSegmentFilter; + /** Filter property for statistics. */ + StatisticFilter?: StatisticSegmentFilter; + /** Filter property for tags. */ + TagFilter?: TagSegmentFilter; + /** Filter property for total value to date in USD. */ + TotalValueToDateInUSDFilter?: TotalValueToDateInUSDSegmentFilter; + /** Filter property for user origination. */ + UserOriginationFilter?: UserOriginationSegmentFilter; + /** Filter property for value to date. */ + ValueToDateFilter?: ValueToDateSegmentFilter; + /** Filter property for virtual currency. */ + VirtualCurrencyBalanceFilter?: VirtualCurrencyBalanceSegmentFilter; + + } + + type SegmentCountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW"; + + type SegmentCurrency = "AED" + + | "AFN" + | "ALL" + | "AMD" + | "ANG" + | "AOA" + | "ARS" + | "AUD" + | "AWG" + | "AZN" + | "BAM" + | "BBD" + | "BDT" + | "BGN" + | "BHD" + | "BIF" + | "BMD" + | "BND" + | "BOB" + | "BRL" + | "BSD" + | "BTN" + | "BWP" + | "BYR" + | "BZD" + | "CAD" + | "CDF" + | "CHF" + | "CLP" + | "CNY" + | "COP" + | "CRC" + | "CUC" + | "CUP" + | "CVE" + | "CZK" + | "DJF" + | "DKK" + | "DOP" + | "DZD" + | "EGP" + | "ERN" + | "ETB" + | "EUR" + | "FJD" + | "FKP" + | "GBP" + | "GEL" + | "GGP" + | "GHS" + | "GIP" + | "GMD" + | "GNF" + | "GTQ" + | "GYD" + | "HKD" + | "HNL" + | "HRK" + | "HTG" + | "HUF" + | "IDR" + | "ILS" + | "IMP" + | "INR" + | "IQD" + | "IRR" + | "ISK" + | "JEP" + | "JMD" + | "JOD" + | "JPY" + | "KES" + | "KGS" + | "KHR" + | "KMF" + | "KPW" + | "KRW" + | "KWD" + | "KYD" + | "KZT" + | "LAK" + | "LBP" + | "LKR" + | "LRD" + | "LSL" + | "LYD" + | "MAD" + | "MDL" + | "MGA" + | "MKD" + | "MMK" + | "MNT" + | "MOP" + | "MRO" + | "MUR" + | "MVR" + | "MWK" + | "MXN" + | "MYR" + | "MZN" + | "NAD" + | "NGN" + | "NIO" + | "NOK" + | "NPR" + | "NZD" + | "OMR" + | "PAB" + | "PEN" + | "PGK" + | "PHP" + | "PKR" + | "PLN" + | "PYG" + | "QAR" + | "RON" + | "RSD" + | "RUB" + | "RWF" + | "SAR" + | "SBD" + | "SCR" + | "SDG" + | "SEK" + | "SGD" + | "SHP" + | "SLL" + | "SOS" + | "SPL" + | "SRD" + | "STD" + | "SVC" + | "SYP" + | "SZL" + | "THB" + | "TJS" + | "TMT" + | "TND" + | "TOP" + | "TRY" + | "TTD" + | "TVD" + | "TWD" + | "TZS" + | "UAH" + | "UGX" + | "USD" + | "UYU" + | "UZS" + | "VEF" + | "VND" + | "VUV" + | "WST" + | "XAF" + | "XCD" + | "XDR" + | "XOF" + | "XPF" + | "YER" + | "ZAR" + | "ZMW" + | "ZWD"; + + type SegmentFilterComparison = "GreaterThan" + + | "LessThan" + | "EqualTo" + | "NotEqualTo" + | "GreaterThanOrEqual" + | "LessThanOrEqual" + | "Exists" + | "Contains" + | "NotContains"; + + type SegmentLoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames"; + + export interface SegmentModel { + /** Segment description. */ + Description?: string; + /** Segment actions for current entered segment players. */ + EnteredSegmentActions?: SegmentTrigger[]; + /** Segment last updated date time. */ + LastUpdateTime: string; + /** Segment actions for current left segment players. */ + LeftSegmentActions?: SegmentTrigger[]; + /** Segment name. */ + Name?: string; + /** Segment id in hex. */ + SegmentId?: string; + /** Segment or definitions. This includes segment and definitions and filters. */ + SegmentOrDefinitions?: SegmentOrDefinition[]; } - type ScheduledTaskType = "CloudScript" - | "ActionsOnPlayerSegment"; + export interface SegmentOrDefinition { + /** List of segment and definitions. */ + SegmentAndDefinitions?: SegmentAndDefinition[]; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.ScriptExecutionError - */ - export interface ScriptExecutionError { - /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError - */ - Error?: string; - /** - / Details about the error - */ - Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ - StackTrace?: string; + } + + type SegmentPushNotificationDevicePlatform = "ApplePushNotificationService" + + | "GoogleCloudMessaging"; + + export interface SegmentTrigger { + /** Add inventory item v2 segment trigger action. */ + AddInventoryItemsV2Action?: AddInventoryItemsV2SegmentAction; + /** Ban player segment trigger action. */ + BanPlayerAction?: BanPlayerSegmentAction; + /** Delete inventory item v2 segment trigger action. */ + DeleteInventoryItemsV2Action?: DeleteInventoryItemsV2SegmentAction; + /** Delete player segment trigger action. */ + DeletePlayerAction?: DeletePlayerSegmentAction; + /** Delete player statistic segment trigger action. */ + DeletePlayerStatisticAction?: DeletePlayerStatisticSegmentAction; + /** Email notification segment trigger action. */ + EmailNotificationAction?: EmailNotificationSegmentAction; + /** Execute azure function segment trigger action. */ + ExecuteAzureFunctionAction?: ExecuteAzureFunctionSegmentAction; + /** Execute cloud script segment trigger action. */ + ExecuteCloudScriptAction?: ExecuteCloudScriptSegmentAction; + /** Grant item segment trigger action. */ + GrantItemAction?: GrantItemSegmentAction; + /** Grant virtual currency segment trigger action. */ + GrantVirtualCurrencyAction?: GrantVirtualCurrencySegmentAction; + /** Increment player statistic segment trigger action. */ + IncrementPlayerStatisticAction?: IncrementPlayerStatisticSegmentAction; + /** Push notification segment trigger action. */ + PushNotificationAction?: PushNotificationSegmentAction; + /** Subtract inventory item v2 segment trigger action. */ + SubtractInventoryItemsV2Action?: SubtractInventoryItemsV2SegmentAction; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SendAccountRecoveryEmailRequest - */ export interface SendAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SendAccountRecoveryEmailResult - */ export interface SendAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublishedRevisionRequest - */ + export interface SendEmailContent { + /** The email template id of the email template to send. */ + EmailTemplateId: string; + + } + + export interface SetMembershipOverrideRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Expiration time for the membership in DateTime format, will override any subscription expirations. */ + ExpirationTime: string; + /** Id of the membership to apply the override expiration date to. */ + MembershipId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface SetMembershipOverrideResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface SetPublishedRevisionRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Version number - */ - Version: number; - /** - / Revision to make the current published revision - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Revision to make the current published revision */ Revision: number; + /** Version number */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublishedRevisionResult - */ export interface SetPublishedRevisionResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublisherDataRequest - */ export interface SetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetPublisherDataResult - */ export interface SetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetTitleDataRequest - */ - export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface SetTitleDataAndOverridesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * List of titleData key-value pairs to set/delete. Use an empty value to delete an existing key; use a non-empty value to + * create/update a key. */ - Key: string; + KeyValues: TitleDataKeyValue[]; + /** Name of the override. */ + OverrideLabel?: string; + + } + + export interface SetTitleDataAndOverridesResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / new value to set. Set to null to remove a value + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ + Key: string; + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetTitleDataResult - */ export interface SetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetupPushNotificationRequest - */ export interface SetupPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / name of the application sending the message (application names must be made up of only uppercase and lowercase ASCII letters, numbers, underscores, hyphens, and periods, and must be between 1 and 256 characters long) - */ - Name: string; - /** - / supported notification platforms are Apple Push Notification Service (APNS and APNS_SANDBOX) for iOS and Google Cloud Messaging (GCM) for Android - */ - Platform: string; - /** - / for APNS, this is the PlatformPrincipal (SSL Certificate) - */ + /** Credential is the Private Key for APNS/APNS_SANDBOX, and the API Key for GCM */ + Credential: string; + /** for APNS, this is the PlatformPrincipal (SSL Certificate) */ Key?: string; + /** This field is deprecated and any usage of this will cause the API to fail. */ + Name?: string; /** - / Credential is the Private Key for APNS/APNS_SANDBOX, and the API Key for GCM + * replace any existing ARN with the newly generated one. If this is set to false, an error will be returned if + * notifications have already setup for this platform. */ - Credential: string; + OverwriteOldARN: boolean; /** - / replace any existing ARN with the newly generated one. If this is set to false, an error will be returned if notifications have already setup for this platform. + * supported notification platforms are Apple Push Notification Service (APNS and APNS_SANDBOX) for iOS and Google Cloud + * Messaging (GCM) for Android */ - OverwriteOldARN: boolean; + Platform: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SetupPushNotificationResult - */ export interface SetupPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Amazon Resource Name for the created notification topic. - */ + /** Amazon Resource Name for the created notification topic. */ ARN?: string; } + export interface SharedSecret { + /** Flag to indicate if this key is disabled */ + Disabled: boolean; + /** Friendly name for this key */ + FriendlyName?: string; + /** The player shared secret to use when calling Client/GetTitlePublicKey */ + SecretKey?: string; + + } + type SourceType = "Admin" + | "BackEnd" | "GameClient" | "GameServer" - | "Partner"; + | "Partner" + | "Custom" + | "API"; type StatisticAggregationMethod = "Last" + | "Min" | "Max" | "Sum"; + export interface StatisticModel { + /** Statistic name */ + Name?: string; + /** Statistic value */ + Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; + + } + type StatisticResetIntervalOption = "Never" + | "Hour" | "Day" | "Week" | "Month"; + export interface StatisticSegmentFilter { + /** Statistic filter comparison. */ + Comparison?: string; + /** Statistic filter value. */ + FilterValue?: string; + /** Statistic name. */ + Name?: string; + /** Use current version of statistic? */ + UseCurrentVersion?: boolean; + /** Statistic version. */ + Version?: number; + + } + type StatisticVersionArchivalStatus = "NotScheduled" + | "Scheduled" | "Queued" | "InProgress" | "Complete"; type StatisticVersionStatus = "Active" + | "SnapshotPending" | "Snapshot" | "ArchivalPending" | "Archived"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.StoreItem - */ export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the catalog + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ ItemId: string; - /** - / Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Override prices for this item for specific currencies - */ + /** Override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Store specific custom data. The data only exists as part of this store; it is not transferred to item instances - */ - CustomData?: any; - /** - / Intended display position for this item. Note that 0 is the first position - */ - DisplayPosition?: number; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.StoreMarketingModel - */ export interface StoreMarketingModel { - /** - / Display name of a store as it will appear to users. - */ - DisplayName?: string; - /** - / Tagline for a store. - */ + /** Tagline for a store. */ Description?: string; - /** - / Custom data about a store. - */ + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ Metadata?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.SubtractUserVirtualCurrencyRequest - */ + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + + export interface SubtractInventoryItemsV2SegmentAction { + /** Amount of the item to removed from the player */ + Amount?: number; + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The duration in seconds to be removed from the subscription in the players inventory */ + DurationInSeconds?: number; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; + + } + + export interface SubtractInventoryItemV2Content { + /** Amount of the item to removed from the player */ + Amount?: number; + /** The collection id for where the item will be removed from the player inventory */ + CollectionId?: string; + /** The duration in seconds to be removed from the subscription in the players inventory */ + DurationInSeconds?: number; + /** The id of item to be removed from the player */ + ItemId?: string; + /** The stack id for where the item will be removed from the player inventory */ + StackId?: string; + + } + export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose virtual currency balance is to be decreased. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be decreased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.TaskInstanceBasicSummary - */ + export interface TagModel { + /** Full value of the tag, including namespace */ + TagValue?: string; + + } + + export interface TagSegmentFilter { + /** Tag comparison. */ + Comparison?: string; + /** Tag value. */ + TagValue?: string; + + } + export interface TaskInstanceBasicSummary { - /** - / ID of the task instance. - */ - TaskInstanceId?: string; - /** - / Identifier of the task this instance belongs to. - */ - TaskIdentifier?: NameIdentifier; - /** - / UTC timestamp when the task started. - */ - StartedAt: string; - /** - / UTC timestamp when the task completed. - */ + /** UTC timestamp when the task completed. */ CompletedAt?: string; - /** - / Current status of the task instance. - */ - Status?: string; - /** - / Progress represented as percentage. - */ - PercentComplete?: number; - /** - / Estimated time remaining in seconds. - */ + /** Error message for last processing attempt, if an error occured. */ + ErrorMessage?: string; + /** Estimated time remaining in seconds. */ EstimatedSecondsRemaining?: number; - /** - / If manually scheduled, ID of user who scheduled the task. - */ + /** Progress represented as percentage. */ + PercentComplete?: number; + /** If manually scheduled, ID of user who scheduled the task. */ ScheduledByUserId?: string; - /** - / Type of the task. - */ + /** UTC timestamp when the task started. */ + StartedAt: string; + /** Current status of the task instance. */ + Status?: string; + /** Identifier of the task this instance belongs to. */ + TaskIdentifier?: NameIdentifier; + /** ID of the task instance. */ + TaskInstanceId?: string; + /** Type of the task. */ Type?: string; } type TaskInstanceStatus = "Succeeded" + | "Starting" | "InProgress" | "Failed" | "Aborted" - | "Pending"; + | "Stalled"; type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBanRequest - */ - export interface UpdateBanRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface TitleDataKeyValue { /** - / The id of the ban to be updated. + * Key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ + Key?: string; + /** New value to set. Set to null to remove a value */ + Value?: string; + + } + + export interface TotalValueToDateInUSDSegmentFilter { + /** Total value to date USD amount. */ + Amount?: string; + /** Total value to date USD comparison. */ + Comparison?: string; + + } + + export interface UpdateBanRequest { + /** The updated active state for the ban. Null for no change. */ + Active?: boolean; + /** The id of the ban to be updated. */ BanId: string; - /** - / The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. - */ - Reason?: string; - /** - / The updated expiration date for the ban. Null for no change. - */ + /** The updated expiration date for the ban. Null for no change. */ Expires?: string; - /** - / The updated IP address for the ban. Null for no change. - */ + /** The updated IP address for the ban. Null for no change. */ IPAddress?: string; - /** - / The updated MAC address for the ban. Null for no change. - */ - MACAddress?: string; - /** - / Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. - */ + /** Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. */ Permanent?: boolean; - /** - / The updated active state for the ban. Null for no change. - */ - Active?: boolean; + /** The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. */ + Reason?: string; + /** The updated family type of the user that should be included in the ban. Null for no change. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBansRequest - */ export interface UpdateBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of bans to be updated. Maximum 100. - */ + /** List of bans to be updated. Maximum 100. */ Bans: UpdateBanRequest[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateBansResult - */ export interface UpdateBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were updated - */ + /** Information on the bans that were updated */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCatalogItemsRequest - */ export interface UpdateCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Which catalog is being updated. If null, uses the default catalog. + * Array of catalog items to be submitted. Note that while CatalogItem has a parameter for CatalogVersion, it is not + * required and ignored in this call. */ + Catalog?: CatalogItem[]; + /** Which catalog is being updated. If null, uses the default catalog. */ CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Should this catalog be set as the default catalog. Defaults to true. If there is currently no default catalog, this will always set it. + * Should this catalog be set as the default catalog. Defaults to true. If there is currently no default catalog, this will + * always set it. */ SetAsDefaultCatalog?: boolean; - /** - / Array of catalog items to be submitted. Note that while CatalogItem has a parameter for CatalogVersion, it is not required and ignored in this call. - */ - Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCatalogItemsResult - */ export interface UpdateCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCloudScriptRequest - */ export interface UpdateCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of Cloud Script files to upload to create the new revision. Must have at least one file. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab user ID of the developer initiating the request. */ + DeveloperPlayFabId?: string; + /** List of Cloud Script files to upload to create the new revision. Must have at least one file. */ Files: CloudScriptFile[]; - /** - / Immediately publish the new revision - */ + /** Immediately publish the new revision */ Publish: boolean; - /** - / PlayFab user ID of the developer initiating the request. - */ - DeveloperPlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateCloudScriptResult - */ export interface UpdateCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Cloud Script version updated - */ + /** New revision number created */ + Revision: number; + /** Cloud Script version updated */ Version: number; + + } + + export interface UpdateIPBanRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The updated active state for the IP ban. Null for no change. */ + Active?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The updated expiration date for the IP ban. Null for no change. */ + Expires?: string; + /** The IP address of the ban to be updated. */ + IPAddress: string; + /** Whether to make this IP ban permanent. Set to true to make this IP ban permanent. This will not modify Active state. */ + Permanent?: boolean; + /** The updated reason for the IP ban. Maximum 140 characters. Null for no change. */ + Reason?: string; + + } + + export interface UpdateIPBanResult extends PlayFabModule.IPlayFabResultCommon { + /** Information on the ban that was created */ + IPBanData?: IPBanInfo; + + } + + export interface UpdateOpenIdConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The client ID given by the ID provider. */ + ClientId?: string; + /** The client secret given by the ID provider. */ + ClientSecret?: string; + /** A name for the connection that identifies it within the title. */ + ConnectionId: string; + /** Ignore 'nonce' claim in identity tokens. */ + IgnoreNonce?: boolean; + /** The issuer URL or discovery document URL to read issuer information from */ + IssuerDiscoveryUrl?: string; + /** Manually specified information for an OpenID Connect issuer. */ + IssuerInformation?: OpenIdIssuerInformation; + /** Override the issuer name for user indexing and lookup. */ + IssuerOverride?: string; + + } + + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / New revision number created + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. */ - Revision: number; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePlayerStatisticDefinitionRequest - */ - export interface UpdatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties were updated. */ + PlayFabId?: string; /** - / unique name of the statistic + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface UpdatePlayerSharedSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Disable or Enable this key */ + Disabled: boolean; + /** Friendly name for this key */ + FriendlyName?: string; + /** The shared secret key to update */ + SecretKey?: string; + + } + + export interface UpdatePlayerSharedSecretResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UpdatePlayerStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** the aggregation method to use in updating the statistic (defaults to last) */ + AggregationMethod?: string; + /** unique name of the statistic */ StatisticName: string; /** - / interval at which the values of the statistic for all players are reset (changes are effective at the next occurance of the new interval boundary) + * interval at which the values of the statistic for all players are reset (changes are effective at the next occurance of + * the new interval boundary) */ VersionChangeInterval?: string; - /** - / the aggregation method to use in updating the statistic (defaults to last) - */ - AggregationMethod?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePlayerStatisticDefinitionResult - */ export interface UpdatePlayerStatisticDefinitionResult extends PlayFabModule.IPlayFabResultCommon { - /** - / updated statistic definition - */ + /** updated statistic definition */ Statistic?: PlayerStatisticDefinition; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePolicyRequest - */ export interface UpdatePolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to overwrite or append to the existing policy. */ + OverwritePolicy: boolean; /** - / The name of the policy being updated. Only supported name is 'ApiPolicy' - */ - PolicyName: string; - /** - / The new statements to include in the policy. + * The name of the policy being updated. Only 'ApiPolicy' is supported. This parameter is optional and defaults to + * 'ApiPolicy' if omitted. */ + PolicyName?: string; + /** Version of the policy to update. Must be the latest (as returned by GetPolicy). */ + PolicyVersion: number; + /** The new statements to include in the policy. */ Statements: PermissionStatement[]; - /** - / Whether to overwrite or append to the existing policy. - */ - OverwritePolicy: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdatePolicyResponse - */ export interface UpdatePolicyResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the policy that was updated. - */ + /** The name of the policy that was updated. */ PolicyName?: string; + /** The statements included in the new version of the policy. */ + Statements?: PermissionStatement[]; /** - / The statements included in the new version of the policy. + * Optional warnings about policy statements that may not have the intended effect. For example, resource paths that don't + * match any known API endpoint. The policy update still succeeds when warnings are present. */ - Statements?: PermissionStatement[]; + Warnings?: string[]; + + } + + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateRandomResultTablesRequest - */ export interface UpdateRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / which catalog is being updated. If null, update the current default catalog version - */ + /** which catalog is being updated. If null, update the current default catalog version */ CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / array of random result tables to make available (Note: specifying an existing TableId will result in overwriting that table, while any others will be added to the available set) + * array of random result tables to make available (Note: specifying an existing TableId will result in overwriting that + * table, while any others will be added to the available set) */ Tables?: RandomResultTable[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateRandomResultTablesResult - */ export interface UpdateRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateStoreItemsRequest - */ + export interface UpdateSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Segment model with all of the segment properties data. */ + SegmentModel: SegmentModel; + + } + + export interface UpdateSegmentResponse extends PlayFabModule.IPlayFabResultCommon { + /** Error message. */ + ErrorMessage?: string; + /** Segment id. */ + SegmentId?: string; + + } + export interface UpdateStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version of the store to update. If null, uses the default catalog. - */ + /** Catalog version of the store to update. If null, uses the default catalog. */ CatalogVersion?: string; - /** - / Unique identifier for the store which is to be updated - */ - StoreId: string; - /** - / Additional data about the store - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Additional data about the store */ MarketingData?: StoreMarketingModel; - /** - / Array of store items - references to catalog items, with specific pricing - to be added - */ + /** Array of store items - references to catalog items, with specific pricing - to be added */ Store?: StoreItem[]; + /** Unique identifier for the store which is to be updated */ + StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateStoreItemsResult - */ export interface UpdateStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateTaskRequest - */ export interface UpdateTaskRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specify either the task ID or the name of the task to be updated. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description the task */ + Description?: string; + /** Specify either the task ID or the name of the task to be updated. */ Identifier?: NameIdentifier; - /** - / Name of the task. This is a unique identifier for tasks in the title. - */ + /** Whether the schedule is active. Inactive schedule will not trigger task execution. */ + IsActive: boolean; + /** Name of the task. This is a unique identifier for tasks in the title. */ Name: string; - /** - / Description the task - */ - Description?: string; - /** - / Cron expression for the run schedule of the task. The expression should be in UTC. - */ + /** Parameter object specific to the task type. See each task type's create API documentation for details. */ + Parameter?: any; + /** Cron expression for the run schedule of the task. The expression should be in UTC. */ Schedule?: string; - /** - / Whether the schedule is active. Inactive schedule will not trigger task execution. - */ - IsActive: boolean; - /** - / Task type. - */ + /** Task type. */ Type: string; - /** - / Parameter object specific to the task type. See each task type's create API documentation for details. - */ - Parameter?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserInternalDataRequest - */ export interface UpdateUserInternalDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserTitleDisplayNameRequest - */ export interface UpdateUserTitleDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose title specific display name is to be changed - */ - PlayFabId: string; - /** - / new title display name for the user - must be between 3 and 25 characters - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** New title display name for the user - must be between 3 and 25 characters */ DisplayName: string; + /** PlayFab unique identifier of the user whose title specific display name is to be changed */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UpdateUserTitleDisplayNameResult - */ export interface UpdateUserTitleDisplayNameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / current title display name for the user (this will be the original display name if the rename attempt failed) - */ + /** current title display name for the user (this will be the original display name if the rename attempt failed) */ DisplayName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserCredentials - */ - export interface UserCredentials { - /** - / Username of user to reset - */ - Username: string; + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserCustomIdInfo - */ export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + + type UserFamilyType = "None" + + | "Xbox" + | "Steam"; + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -4557,161 +6036,200 @@ declare module PlayFabAdminModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface UserOriginationSegmentFilter { + /** User login provider. */ + LoginProvider?: string; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.VirtualCurrencyData - */ - export interface VirtualCurrencyData { + export interface ValidateApiPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether the validation should simulate overwriting or appending to the existing policy. */ + OverwritePolicy: boolean; /** - / unique two-character identifier for this currency type (e.g.: "CC") + * The name of the policy to validate. Only 'ApiPolicy' is supported. This parameter is optional and defaults to + * 'ApiPolicy' if omitted. */ - CurrencyCode: string; + PolicyName?: string; + /** Version of the policy to validate against. Must be the latest (as returned by GetPolicy). */ + PolicyVersion: number; + /** The statements to validate. */ + Statements: PermissionStatement[]; + + } + + export interface ValidateApiPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Summary of what would change compared to the current policy. */ + Diff?: PolicyDiffSummary; + /** Whether the proposed policy is valid and would be accepted by UpdatePolicy. */ + IsValid: boolean; + /** The name of the policy validated. */ + PolicyName?: string; + /** Policy version. */ + PolicyVersion: number; + /** The full set of statements that would result from applying this update. */ + ResultingStatements?: PermissionStatement[]; + /** Validation errors that would cause UpdatePolicy to reject this request. Empty if IsValid is true. */ + ValidationErrors?: string[]; + /** Non-blocking warnings about the proposed policy (e.g., near statement limit, duplicate statements). */ + Warnings?: string[]; + + } + + export interface ValueToDateModel { + /** ISO 4217 code of the currency used in the purchases */ + Currency?: string; /** - / friendly name to show in the developer portal, reports, etc. + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ - DisplayName?: string; + TotalValue: number; /** - / amount to automatically grant users upon first login to the title + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ + TotalValueAsDecimal?: string; + + } + + export interface ValueToDateSegmentFilter { + /** Value to date amount. */ + Amount?: string; + /** Value to date comparison. */ + Comparison?: string; + /** Currency using for filter. */ + Currency?: string; + + } + + export interface VirtualCurrencyBalanceSegmentFilter { + /** Total amount. */ + Amount: number; + /** Amount comparison. */ + Comparison?: string; + /** Currency code. */ + CurrencyCode?: string; + + } + + export interface VirtualCurrencyData { + /** unique two-character identifier for this currency type (e.g.: "CC") */ + CurrencyCode: string; + /** friendly name to show in the developer portal, reports, etc. */ + DisplayName?: string; + /** amount to automatically grant users upon first login to the title */ InitialDeposit?: number; - /** - / rate at which the currency automatically be added to over time, in units per day (24 hours) - */ - RechargeRate?: number; - /** - / maximum amount to which the currency will recharge (cannot exceed MaxAmount, but can be less) - */ + /** maximum amount to which the currency will recharge (cannot exceed MaxAmount, but can be less) */ RechargeMax?: number; + /** rate at which the currency automatically be added to over time, in units per day (24 hours) */ + RechargeRate?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Admin.Models/PlayFab.Admin.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabAuthenticationApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAuthenticationApi.d.ts new file mode 100644 index 00000000..6730e3dc --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabAuthenticationApi.d.ts @@ -0,0 +1,176 @@ +/// + +declare module PlayFabAuthenticationModule { + export interface IPlayFabAuthentication { + ForgetAllCredentials(): void; + + /** + * Create a game_server entity token and return a new or existing game_server entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/authenticategameserverwithcustomid + */ + AuthenticateGameServerWithCustomId(request: PlayFabAuthenticationModels.AuthenticateCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete a game_server entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/delete + */ + Delete(request: PlayFabAuthenticationModels.DeleteRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Method to exchange a legacy AuthenticationTicket or title SecretKey for an Entity Token or to refresh a still valid + * Entity Token. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/getentitytoken + */ + GetEntityToken(request: PlayFabAuthenticationModels.GetEntityTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Method for a server to validate a client provided EntityToken. Only callable by the title entity. + * https://docs.microsoft.com/rest/api/playfab/authentication/authentication/validateentitytoken + */ + ValidateEntityToken(request: PlayFabAuthenticationModels.ValidateEntityTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabAuthenticationModels { + export interface AuthenticateCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The customId used to create and retrieve game_server entity tokens. This is unique at the title level. CustomId must be + * between 32 and 100 characters. + */ + CustomId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface AuthenticateCustomIdResult extends PlayFabModule.IPlayFabResultCommon { + /** The token generated used to set X-EntityToken for game_server calls. */ + EntityToken?: EntityTokenResponse; + /** True if the account was newly created on this authentication. */ + NewlyCreated: boolean; + + } + + export interface DeleteRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The game_server entity to be removed. */ + Entity: EntityKey; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLineage { + /** The Character Id of the associated entity. */ + CharacterId?: string; + /** The Group Id of the associated entity. */ + GroupId?: string; + /** The Master Player Account Id of the associated entity. */ + MasterPlayerAccountId?: string; + /** The Namespace Id of the associated entity. */ + NamespaceId?: string; + /** The Title Id of the associated entity. */ + TitleId?: string; + /** The Title Player Account Id of the associated entity. */ + TitlePlayerAccountId?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + + export interface GetEntityTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetEntityTokenResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + + type IdentifiedDeviceType = "Unknown" + + | "XboxOne" + | "Scarlett" + | "WindowsOneCore" + | "WindowsOneCoreMobile" + | "Win32" + | "android" + | "iOS" + | "PlayStation" + | "Nintendo"; + + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface ValidateEntityTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Client EntityToken */ + EntityToken: string; + + } + + export interface ValidateEntityTokenResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The authenticated device for this entity, for the given login */ + IdentifiedDeviceType?: string; + /** The identity provider for this entity, for the given login */ + IdentityProvider?: string; + /** The ID issued by the identity provider, e.g. a XUID on Xbox Live */ + IdentityProviderIssuedId?: string; + /** The lineage of this profile. */ + Lineage?: EntityLineage; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabClientApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabClientApi.d.ts index 5e13abf0..b75e42e4 100644 --- a/PlayFabTestingExample/src/typings/PlayFab/PlayFabClientApi.d.ts +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabClientApi.d.ts @@ -4,1235 +4,1504 @@ declare module PlayFabClientModule { export interface IPlayFabClient { IsClientLoggedIn(): boolean; + ForgetAllCredentials(): void; + + /** + * Accepts an open trade (one that has not yet been accepted or cancelled), if the locally signed-in player is in the + * allowed player list for the trade, or it is open to all players. If the call is successful, the offered and accepted + * items will be swapped between the two players' inventories. + * https://docs.microsoft.com/rest/api/playfab/client/trading/accepttrade + */ + AcceptTrade(request: PlayFabClientModels.AcceptTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds the PlayFab user, based upon a match against a supplied unique identifier, to the friend list of the local user. At + * least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/addfriend + */ + AddFriend(request: PlayFabClientModels.AddFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab + * ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as + * authentication credentials, as the intent is that it is easily accessible by other players. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addgenericid + */ + AddGenericID(request: PlayFabClientModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds or updates a contact email to the player's profile. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addorupdatecontactemail + */ + AddOrUpdateContactEmail(request: PlayFabClientModels.AddOrUpdateContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users + * in the group can add new members. Shared Groups are designed for sharing data between a very small number of players, + * please see our guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/addsharedgroupmembers + */ + AddSharedGroupMembers(request: PlayFabClientModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds playfab username/password auth to an existing account created via an anonymous auth method, e.g. automatic device + * ID login. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/addusernamepassword + */ + AddUsernamePassword(request: PlayFabClientModels.AddUsernamePasswordRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the user's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/adduservirtualcurrency + */ + AddUserVirtualCurrency(request: PlayFabClientModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers the Android device to receive push notifications + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/androiddevicepushnotificationregistration + */ + AndroidDevicePushNotificationRegistration(request: PlayFabClientModels.AndroidDevicePushNotificationRegistrationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Attributes an install for advertisment. + * https://docs.microsoft.com/rest/api/playfab/client/advertising/attributeinstall + */ + AttributeInstall(request: PlayFabClientModels.AttributeInstallRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancels an open trade (one that has not yet been accepted or cancelled). Note that only the player who created the trade + * can cancel it via this API call, to prevent griefing of the trade system (cancelling trades in order to prevent other + * players from accepting them, for trades that can be claimed by more than one player). + * https://docs.microsoft.com/rest/api/playfab/client/trading/canceltrade + */ + CancelTrade(request: PlayFabClientModels.CancelTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Confirms with the payment provider that the purchase was approved (if applicable) and adjusts inventory and + * virtual currency balances as appropriate + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/confirmpurchase + */ + ConfirmPurchase(request: PlayFabClientModels.ConfirmPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's + * inventory. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/consumeitem + */ + ConsumeItem(request: PlayFabClientModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Grants the player's current entitlements from Microsoft Store's Collection API + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumemicrosoftstoreentitlements + */ + ConsumeMicrosoftStoreEntitlements(request: PlayFabClientModels.ConsumeMicrosoftStoreEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks for any new consumable entitlements. If any are found, they are consumed (if they're consumables) and added as + * PlayFab items + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumeps5entitlements + */ + ConsumePS5Entitlements(request: PlayFabClientModels.ConsumePS5EntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks for any new consumable entitlements. If any are found, they are consumed and added as PlayFab items + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumepsnentitlements + */ + ConsumePSNEntitlements(request: PlayFabClientModels.ConsumePSNEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Grants the player's current entitlements from Xbox Live, consuming all availble items in Xbox and granting them to the + * player's PlayFab inventory. This call is idempotent and will not grant previously granted items to the player. + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/consumexboxentitlements + */ + ConsumeXboxEntitlements(request: PlayFabClientModels.ConsumeXboxEntitlementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the + * group. Upon creation, the current user will be the only member of the group. Shared Groups are designed for sharing data + * between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/createsharedgroup + */ + CreateSharedGroup(request: PlayFabClientModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/deleteplayercustomproperties + */ + DeletePlayerCustomProperties(request: PlayFabClientModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. The + * PlayFab ID is the entity ID of the player's master_player_account entity. + * https://docs.microsoft.com/rest/api/playfab/client/server-side-cloud-script/executecloudscript + */ + ExecuteCloudScript(request: PlayFabClientModels.ExecuteCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the user's PlayFab account details + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getaccountinfo + */ + GetAccountInfo(request: PlayFabClientModels.GetAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Returns a list of ad placements and a reward for each + * https://docs.microsoft.com/rest/api/playfab/client/advertising/getadplacements + */ + GetAdPlacements(request: PlayFabClientModels.GetAdPlacementsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be + * evaluated with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/client/characters/getalluserscharacters + */ + GetAllUsersCharacters(request: PlayFabClientModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getcatalogitems + */ + GetCatalogItems(request: PlayFabClientModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title-specific custom data for the character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/getcharacterdata + */ + GetCharacterData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified character's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getcharacterinventory + */ + GetCharacterInventory(request: PlayFabClientModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/characters/getcharacterleaderboard + */ + GetCharacterLeaderboard(request: PlayFabClientModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title-specific custom data for the character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/getcharacterreadonlydata + */ + GetCharacterReadOnlyData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the details of all title-specific statistics for the user + * https://docs.microsoft.com/rest/api/playfab/client/characters/getcharacterstatistics + */ + GetCharacterStatistics(request: PlayFabClientModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned + * URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the + * content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, + * the query to retrieve the data will fail. See this post for more information: + * https://community.playfab.com/hc/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, + * please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. + * https://docs.microsoft.com/rest/api/playfab/client/content/getcontentdownloadurl + */ + GetContentDownloadUrl(request: PlayFabClientModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked friends of the current player for the given statistic, starting from the indicated point in + * the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getfriendleaderboard + */ + GetFriendLeaderboard(request: PlayFabClientModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked friends of the current player for the given statistic, centered on the requested PlayFab + * user. If PlayFabId is empty or null will return currently logged in user. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getfriendleaderboardaroundplayer + */ + GetFriendLeaderboardAroundPlayer(request: PlayFabClientModels.GetFriendLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the current friend list for the local user, constrained to users who have PlayFab accounts. Friends from + * linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/getfriendslist + */ + GetFriendsList(request: PlayFabClientModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getleaderboard + */ + GetLeaderboard(request: PlayFabClientModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked characters for the given statistic, centered on the requested Character ID + * https://docs.microsoft.com/rest/api/playfab/client/characters/getleaderboardaroundcharacter + */ + GetLeaderboardAroundCharacter(request: PlayFabClientModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of ranked users for the given statistic, centered on the requested player. If PlayFabId is empty or + * null will return currently logged in user. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getleaderboardaroundplayer + */ + GetLeaderboardAroundPlayer(request: PlayFabClientModels.GetLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a list of all of the user's characters for the given statistic. + * https://docs.microsoft.com/rest/api/playfab/client/characters/getleaderboardforusercharacters + */ + GetLeaderboardForUserCharacters(request: PlayFabClientModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ For payments flows where the provider requires playfab (the fulfiller) to initiate the transaction, but the + * client completes the rest of the flow. In the Xsolla case, the token returned here will be passed to Xsolla by the + * client to create a cart. Poll GetPurchase using the returned OrderId once you've completed the payment. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getpaymenttoken + */ + GetPaymentToken(request: PlayFabClientModels.GetPaymentTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a Photon custom authentication token that can be used to securely join the player into a Photon room. See + * https://docs.microsoft.com/gaming/playfab/features/multiplayer/photon/quickstart for more details. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/getphotonauthenticationtoken + */ + GetPhotonAuthenticationToken(request: PlayFabClientModels.GetPhotonAuthenticationTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves all of the user's different kinds of info. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayercombinedinfo + */ + GetPlayerCombinedInfo(request: PlayFabClientModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayercustomproperty + */ + GetPlayerCustomProperty(request: PlayFabClientModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayerprofile + */ + GetPlayerProfile(request: PlayFabClientModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/client/playstream/getplayersegments + */ + GetPlayerSegments(request: PlayFabClientModels.GetPlayerSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the indicated statistics (current version and values for all statistics, if none are specified), for the local + * player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayerstatistics + */ + GetPlayerStatistics(request: PlayFabClientModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getplayerstatisticversions + */ + GetPlayerStatisticVersions(request: PlayFabClientModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/client/playstream/getplayertags + */ + GetPlayerTags(request: PlayFabClientModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets all trades the player has either opened or accepted, optionally filtered by trade status. + * https://docs.microsoft.com/rest/api/playfab/client/trading/getplayertrades + */ + GetPlayerTrades(request: PlayFabClientModels.GetPlayerTradesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the unique PlayFab identifiers for the given set of Battle.net account identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrombattlenetaccountids + */ + GetPlayFabIDsFromBattleNetAccountIds(request: PlayFabClientModels.GetPlayFabIDsFromBattleNetAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets a Photon custom authentication token that can be used to securely join the player into a Photon room. See https://api.playfab.com/docs/using-photon-with-playfab/ for more details. - / https://api.playfab.com/Documentation/Client/method/GetPhotonAuthenticationToken + * Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromfacebookids */ - GetPhotonAuthenticationToken(request: PlayFabClientModels.GetPhotonAuthenticationTokenRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookIDs(request: PlayFabClientModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests a challenge from the server to be signed by Windows Hello Passport service to authenticate. - / https://api.playfab.com/Documentation/Client/method/GetWindowsHelloChallenge + * Retrieves the unique PlayFab identifiers for the given set of Facebook Instant Game identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromfacebookinstantgamesids */ - GetWindowsHelloChallenge(request: PlayFabClientModels.GetWindowsHelloChallengeRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookInstantGamesIds(request: PlayFabClientModels.GetPlayFabIDsFromFacebookInstantGamesIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Link Windows Hello to the current PlayFab Account - / https://api.playfab.com/Documentation/Client/method/LinkWindowsHello + * Retrieves the unique PlayFab identifiers for the given set of Game Center identifiers (referenced in the Game Center + * Programming Guide as the Player Identifier). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgamecenterids */ - LinkWindowsHello(request: PlayFabClientModels.LinkWindowsHelloAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGameCenterIDs(request: PlayFabClientModels.GetPlayFabIDsFromGameCenterIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithAndroidDeviceID + * Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the generic identifier was + * added to the player account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgenericids */ - LoginWithAndroidDeviceID(request: PlayFabClientModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGenericIDs(request: PlayFabClientModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithCustomID + * Retrieves the unique PlayFab identifiers for the given set of Google identifiers. The Google identifiers are the IDs for + * the user accounts, available as "id" in the Google+ People API calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgoogleids */ - LoginWithCustomID(request: PlayFabClientModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGoogleIDs(request: PlayFabClientModels.GetPlayFabIDsFromGoogleIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithEmailAddress + * Retrieves the unique PlayFab identifiers for the given set of Google Play Games identifiers. The Google Play Games + * identifiers are the IDs for the user accounts, available as "playerId" in the Google Play Games Services - Players API + * calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromgoogleplaygamesplayerids */ - LoginWithEmailAddress(request: PlayFabClientModels.LoginWithEmailAddressRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGooglePlayGamesPlayerIDs(request: PlayFabClientModels.GetPlayFabIDsFromGooglePlayGamesPlayerIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Facebook access token, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithFacebook + * Retrieves the unique PlayFab identifiers for the given set of Kongregate identifiers. The Kongregate identifiers are the + * IDs for the user accounts, available as "user_id" from the Kongregate API methods(ex: + * http://developers.kongregate.com/docs/client/getUserId). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromkongregateids */ - LoginWithFacebook(request: PlayFabClientModels.LoginWithFacebookRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromKongregateIDs(request: PlayFabClientModels.GetPlayFabIDsFromKongregateIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using an iOS Game Center player identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithGameCenter + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Service Account identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromnintendoserviceaccountids */ - LoginWithGameCenter(request: PlayFabClientModels.LoginWithGameCenterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoServiceAccountIds(request: PlayFabClientModels.GetPlayFabIDsFromNintendoServiceAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using their Google account credentials - / https://api.playfab.com/Documentation/Client/method/LoginWithGoogleAccount + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Switch Device identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromnintendoswitchdeviceids */ - LoginWithGoogleAccount(request: PlayFabClientModels.LoginWithGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoSwitchDeviceIds(request: PlayFabClientModels.GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using the vendor-specific iOS device identifier, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithIOSDeviceID + * Retrieves the unique PlayFab identifiers for the given set of OpenId subject identifiers. A OpenId identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the OpenId identifier was added + * to the player account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromopenidsubjectidentifiers */ - LoginWithIOSDeviceID(request: PlayFabClientModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromOpenIdSubjectIdentifiers(request: PlayFabClientModels.GetPlayFabIDsFromOpenIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Kongregate player account. - / https://api.playfab.com/Documentation/Client/method/LoginWithKongregate + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrompsnaccountids */ - LoginWithKongregate(request: PlayFabClientModels.LoginWithKongregateRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNAccountIDs(request: PlayFabClientModels.GetPlayFabIDsFromPSNAccountIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls which require an authenticated user. Unlike other login API calls, LoginWithEmailAddress does not permit the creation of new accounts via the CreateAccountFlag. Email accounts must be created using the RegisterPlayFabUser API or added to existing accounts using AddUsernamePassword. - / https://api.playfab.com/Documentation/Client/method/LoginWithPlayFab + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfrompsnonlineids */ - LoginWithPlayFab(request: PlayFabClientModels.LoginWithPlayFabRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNOnlineIDs(request: PlayFabClientModels.GetPlayFabIDsFromPSNOnlineIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Steam authentication ticket, returning a session identifier that can subsequently be used for API calls which require an authenticated user - / https://api.playfab.com/Documentation/Client/method/LoginWithSteam + * Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile + * IDs for the user accounts, available as SteamId in the Steamworks Community API calls. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromsteamids */ - LoginWithSteam(request: PlayFabClientModels.LoginWithSteamRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamIDs(request: PlayFabClientModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Signs the user in using a Twitch access token. - / https://api.playfab.com/Documentation/Client/method/LoginWithTwitch + * 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 */ - LoginWithTwitch(request: PlayFabClientModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamNames(request: PlayFabClientModels.GetPlayFabIDsFromSteamNamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Completes the Windows Hello login flow by returning the signed value of the challange from GetWindowsHelloChallenge. Windows Hello has a 2 step client to server authentication scheme. Step one is to request from the server a challenge string. Step two is to request the user sign the string via Windows Hello and then send the signed value back to the server. - / https://api.playfab.com/Documentation/Client/method/LoginWithWindowsHello + * 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). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromtwitchids */ - LoginWithWindowsHello(request: PlayFabClientModels.LoginWithWindowsHelloRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromTwitchIDs(request: PlayFabClientModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers a new Playfab user account, returning a session identifier that can subsequently be used for API calls which require an authenticated user. You must supply either a username or an email address. - / https://api.playfab.com/Documentation/Client/method/RegisterPlayFabUser + * Retrieves the unique PlayFab identifiers for the given set of XboxLive identifiers. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/getplayfabidsfromxboxliveids */ - RegisterPlayFabUser(request: PlayFabClientModels.RegisterPlayFabUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromXboxLiveIDs(request: PlayFabClientModels.GetPlayFabIDsFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Register using Windows Hello authentication. Before a user can request a challenge or perform a signin the user must first either register or link a Windows Hello account. - / https://api.playfab.com/Documentation/Client/method/RegisterWithWindowsHello + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getpublisherdata */ - RegisterWithWindowsHello(request: PlayFabClientModels.RegisterWithWindowsHelloRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabClientModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlink Windows Hello from the current PlayFab Account - / https://api.playfab.com/Documentation/Client/method/UnlinkWindowsHello + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves a purchase along with its current PlayFab status. Returns inventory items from the purchase that + * are still active. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getpurchase */ - UnlinkWindowsHello(request: PlayFabClientModels.UnlinkWindowsHelloAccountRequest, callback: PlayFabModule.ApiCallback): void; + GetPurchase(request: PlayFabClientModels.GetPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as authentication credentials, as the intent is that it is easily accessible by other players. - / https://api.playfab.com/Documentation/Client/method/AddGenericID + * Retrieves data stored in a shared group object, as well as the list of members in the group. Non-members of the group + * may use this to retrieve group data, including membership, but they will not receive data for keys marked as private. + * Shared Groups are designed for sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/getsharedgroupdata */ - AddGenericID(request: PlayFabClientModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback): void; + GetSharedGroupData(request: PlayFabClientModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds playfab username/password auth to an existing account created via an anonymous auth method, e.g. automatic device ID login. - / https://api.playfab.com/Documentation/Client/method/AddUsernamePassword + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/getstoreitems */ - AddUsernamePassword(request: PlayFabClientModels.AddUsernamePasswordRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabClientModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the user's PlayFab account details - / https://api.playfab.com/Documentation/Client/method/GetAccountInfo + * Retrieves the current server time + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettime */ - GetAccountInfo(request: PlayFabClientModels.GetAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTime(request: PlayFabClientModels.GetTimeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves all of the user's different kinds of info. - / https://api.playfab.com/Documentation/Client/method/GetPlayerCombinedInfo + * Retrieves the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettitledata */ - GetPlayerCombinedInfo(request: PlayFabClientModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabClientModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromFacebookIDs + * Retrieves the title news feed, as configured in the developer portal + * https://docs.microsoft.com/rest/api/playfab/client/title-wide-data-management/gettitlenews */ - GetPlayFabIDsFromFacebookIDs(request: PlayFabClientModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleNews(request: PlayFabClientModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Game Center identifiers (referenced in the Game Center Programming Guide as the Player Identifier). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGameCenterIDs + * Returns the title's base 64 encoded RSA CSP blob. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/gettitlepublickey */ - GetPlayFabIDsFromGameCenterIDs(request: PlayFabClientModels.GetPlayFabIDsFromGameCenterIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitlePublicKey(request: PlayFabClientModels.GetTitlePublicKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the service name plus the service-specific ID for the player, as specified by the title when the generic identifier was added to the player account. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGenericIDs + * Gets the current status of an existing trade. + * https://docs.microsoft.com/rest/api/playfab/client/trading/gettradestatus */ - GetPlayFabIDsFromGenericIDs(request: PlayFabClientModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetTradeStatus(request: PlayFabClientModels.GetTradeStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Google identifiers. The Google identifiers are the IDs for the user accounts, available as "id" in the Google+ People API calls. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromGoogleIDs + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserdata */ - GetPlayFabIDsFromGoogleIDs(request: PlayFabClientModels.GetPlayFabIDsFromGoogleIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Kongregate identifiers. The Kongregate identifiers are the IDs for the user accounts, available as "user_id" from the Kongregate API methods(ex: http://developers.kongregate.com/docs/client/getUserId). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromKongregateIDs + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/getuserinventory */ - GetPlayFabIDsFromKongregateIDs(request: PlayFabClientModels.GetPlayFabIDsFromKongregateIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabClientModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile IDs for the user accounts, available as SteamId in the Steamworks Community API calls. - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromSteamIDs + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserpublisherdata */ - GetPlayFabIDsFromSteamIDs(request: PlayFabClientModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / 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). - / https://api.playfab.com/Documentation/Client/method/GetPlayFabIDsFromTwitchIDs + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserpublisherreadonlydata */ - GetPlayFabIDsFromTwitchIDs(request: PlayFabClientModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Android device identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkAndroidDeviceID + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/getuserreadonlydata */ - LinkAndroidDeviceID(request: PlayFabClientModels.LinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the custom identifier, generated by the title, to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkCustomID + * Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated + * with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/client/characters/grantcharactertouser */ - LinkCustomID(request: PlayFabClientModels.LinkCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + GrantCharacterToUser(request: PlayFabClientModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Facebook account associated with the provided Facebook access token to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkFacebookAccount + * Links the Android device identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkandroiddeviceid */ - LinkFacebookAccount(request: PlayFabClientModels.LinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkAndroidDeviceID(request: PlayFabClientModels.LinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Game Center account associated with the provided Game Center ID to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkGameCenterAccount + * Links the Apple account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkapple */ - LinkGameCenterAccount(request: PlayFabClientModels.LinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkApple(request: PlayFabClientModels.LinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the currently signed-in user account to their Google account, using their Google account credentials - / https://api.playfab.com/Documentation/Client/method/LinkGoogleAccount + * Links the Battle.net account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkbattlenetaccount */ - LinkGoogleAccount(request: PlayFabClientModels.LinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkBattleNetAccount(request: PlayFabClientModels.LinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the vendor-specific iOS device identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkIOSDeviceID + * Links the custom identifier, generated by the title, to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkcustomid */ - LinkIOSDeviceID(request: PlayFabClientModels.LinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkCustomID(request: PlayFabClientModels.LinkCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Kongregate identifier to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkKongregate + * Links the Facebook account associated with the provided Facebook access token to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkfacebookaccount */ - LinkKongregate(request: PlayFabClientModels.LinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkFacebookAccount(request: PlayFabClientModels.LinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Steam account associated with the provided Steam authentication ticket to the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/LinkSteamAccount + * Links the Facebook Instant Games Id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkfacebookinstantgamesid */ - LinkSteamAccount(request: PlayFabClientModels.LinkSteamAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkFacebookInstantGamesId(request: PlayFabClientModels.LinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Links the Twitch account associated with the token to the user's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/LinkTwitch + * Links the Game Center account associated with the provided Game Center ID to the user's PlayFab account. Logging in with + * a Game Center ID is insecure if you do not include the optional PublicKeyUrl, Salt, Signature, and Timestamp parameters + * in this request. It is recommended you require these parameters on all Game Center calls by going to the Apple Add-ons + * page in the PlayFab Game Manager and enabling the 'Require secure authentication only for this app' option. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgamecenteraccount */ - LinkTwitch(request: PlayFabClientModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkGameCenterAccount(request: PlayFabClientModels.LinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the specified generic service identifier from the player's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/RemoveGenericID + * Links the currently signed-in user account to their Google account, using their Google account credentials + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgoogleaccount */ - RemoveGenericID(request: PlayFabClientModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkGoogleAccount(request: PlayFabClientModels.LinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Submit a report for another player (due to bad bahavior, etc.), so that customer service representatives for the title can take action concerning potentially toxic players. - / https://api.playfab.com/Documentation/Client/method/ReportPlayer + * Links the currently signed-in user account to their Google Play Games account, using their Google Play Games account + * credentials + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkgoogleplaygamesservicesaccount */ - ReportPlayer(request: PlayFabClientModels.ReportPlayerClientRequest, callback: PlayFabModule.ApiCallback): void; + LinkGooglePlayGamesServicesAccount(request: PlayFabClientModels.LinkGooglePlayGamesServicesAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to change the password - / https://api.playfab.com/Documentation/Client/method/SendAccountRecoveryEmail + * Links the vendor-specific iOS device identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkiosdeviceid */ - SendAccountRecoveryEmail(request: PlayFabClientModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback): void; + LinkIOSDeviceID(request: PlayFabClientModels.LinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Android device identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkAndroidDeviceID + * Links the Kongregate identifier to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkkongregate */ - UnlinkAndroidDeviceID(request: PlayFabClientModels.UnlinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkKongregate(request: PlayFabClientModels.LinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related custom identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkCustomID + * Links the Nintendo account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linknintendoserviceaccount */ - UnlinkCustomID(request: PlayFabClientModels.UnlinkCustomIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccount(request: PlayFabClientModels.LinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Facebook account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkFacebookAccount + * Links the NintendoSwitchDeviceId to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linknintendoswitchdeviceid */ - UnlinkFacebookAccount(request: PlayFabClientModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoSwitchDeviceId(request: PlayFabClientModels.LinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Game Center account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkGameCenterAccount + * Links an OpenID Connect account to a user's PlayFab account, based on an existing relationship between a title and an + * Open ID Connect provider and the OpenId Connect JWT from that provider. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkopenidconnect */ - UnlinkGameCenterAccount(request: PlayFabClientModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkOpenIdConnect(request: PlayFabClientModels.LinkOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Google account from the user's PlayFab account (https://developers.google.com/android/reference/com/google/android/gms/auth/GoogleAuthUtil#public-methods). - / https://api.playfab.com/Documentation/Client/method/UnlinkGoogleAccount + * Links the PlayStation :tm: Network account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkpsnaccount */ - UnlinkGoogleAccount(request: PlayFabClientModels.UnlinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNAccount(request: PlayFabClientModels.LinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related iOS device identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkIOSDeviceID + * Links the Steam account associated with the provided Steam authentication ticket to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linksteamaccount */ - UnlinkIOSDeviceID(request: PlayFabClientModels.UnlinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback): void; + LinkSteamAccount(request: PlayFabClientModels.LinkSteamAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Kongregate identifier from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkKongregate + * Links the Twitch account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linktwitch */ - UnlinkKongregate(request: PlayFabClientModels.UnlinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkTwitch(request: PlayFabClientModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Steam account from the user's PlayFab account - / https://api.playfab.com/Documentation/Client/method/UnlinkSteamAccount + * Links the Xbox Live account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/linkxboxaccount */ - UnlinkSteamAccount(request: PlayFabClientModels.UnlinkSteamAccountRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxAccount(request: PlayFabClientModels.LinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unlinks the related Twitch account from the user's PlayFab account. - / https://api.playfab.com/Documentation/Client/method/UnlinkTwitch + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/listplayercustomproperties */ - UnlinkTwitch(request: PlayFabClientModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabClientModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update the avatar URL of the player - / https://api.playfab.com/Documentation/Client/method/UpdateAvatarUrl + * Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithandroiddeviceid */ - UpdateAvatarUrl(request: PlayFabClientModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithAndroidDeviceID(request: PlayFabClientModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title specific display name for the user - / https://api.playfab.com/Documentation/Client/method/UpdateUserTitleDisplayName + * Signs in the user with a Sign in with Apple identity token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithapple */ - UpdateUserTitleDisplayName(request: PlayFabClientModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithApple(request: PlayFabClientModels.LoginWithAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the current player for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetFriendLeaderboard + * Sign in the user with a Battle.net identity token + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithbattlenet */ - GetFriendLeaderboard(request: PlayFabClientModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithBattleNet(request: PlayFabClientModels.LoginWithBattleNetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the current player for the given statistic, centered on the requested PlayFab user. If PlayFabId is empty or null will return currently logged in user. - / https://api.playfab.com/Documentation/Client/method/GetFriendLeaderboardAroundPlayer + * Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithcustomid */ - GetFriendLeaderboardAroundPlayer(request: PlayFabClientModels.GetFriendLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithCustomID(request: PlayFabClientModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetLeaderboard + * Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user. Unlike most other login API calls, LoginWithEmailAddress does not permit the + * creation of new accounts via the CreateAccountFlag. Email addresses may be used to create accounts via + * RegisterPlayFabUser. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithemailaddress */ - GetLeaderboard(request: PlayFabClientModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithEmailAddress(request: PlayFabClientModels.LoginWithEmailAddressRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, centered on the requested player. If PlayFabId is empty or null will return currently logged in user. - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardAroundPlayer + * Signs the user in using a Facebook access token, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithfacebook */ - GetLeaderboardAroundPlayer(request: PlayFabClientModels.GetLeaderboardAroundPlayerRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithFacebook(request: PlayFabClientModels.LoginWithFacebookRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the indicated statistics (current version and values for all statistics, if none are specified), for the local player. - / https://api.playfab.com/Documentation/Client/method/GetPlayerStatistics + * Signs the user in using a Facebook Instant Games ID, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user. Requires Facebook Instant Games to be configured. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithfacebookinstantgamesid */ - GetPlayerStatistics(request: PlayFabClientModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithFacebookInstantGamesId(request: PlayFabClientModels.LoginWithFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Client/method/GetPlayerStatisticVersions + * Signs the user in using an iOS Game Center player identifier, returning a session identifier that can subsequently be + * used for API calls which require an authenticated user. Logging in with a Game Center ID is insecure if you do not + * include the optional PublicKeyUrl, Salt, Signature, and Timestamp parameters in this request. It is recommended you + * require these parameters on all Game Center calls by going to the Apple Add-ons page in the PlayFab Game Manager and + * enabling the 'Require secure authentication only for this app' option. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgamecenter */ - GetPlayerStatisticVersions(request: PlayFabClientModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGameCenter(request: PlayFabClientModels.LoginWithGameCenterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetUserData + * Signs the user in using their Google account credentials + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgoogleaccount */ - GetUserData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGoogleAccount(request: PlayFabClientModels.LoginWithGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetUserPublisherData + * Signs the user in using their Google Play Games account credentials + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithgoogleplaygamesservices */ - GetUserPublisherData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithGooglePlayGamesServices(request: PlayFabClientModels.LoginWithGooglePlayGamesServicesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetUserPublisherReadOnlyData + * Signs the user in using the vendor-specific iOS device identifier, returning a session identifier that can subsequently + * be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithiosdeviceid */ - GetUserPublisherReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithIOSDeviceID(request: PlayFabClientModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetUserReadOnlyData + * Signs the user in using a Kongregate player account. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithkongregate */ - GetUserReadOnlyData(request: PlayFabClientModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithKongregate(request: PlayFabClientModels.LoginWithKongregateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the user. By default, clients are not permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. - / https://api.playfab.com/Documentation/Client/method/UpdatePlayerStatistics + * Signs in the user with a Nintendo service account token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithnintendoserviceaccount */ - UpdatePlayerStatistics(request: PlayFabClientModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithNintendoServiceAccount(request: PlayFabClientModels.LoginWithNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateUserData + * Signs the user in using a Nintendo Switch Device ID, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithnintendoswitchdeviceid */ - UpdateUserData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithNintendoSwitchDeviceId(request: PlayFabClientModels.LoginWithNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateUserPublisherData + * Logs in a user with an Open ID Connect JWT created by an existing relationship between a title and an Open ID Connect + * provider. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithopenidconnect */ - UpdateUserPublisherData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithOpenIdConnect(request: PlayFabClientModels.LoginWithOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Client/method/GetCatalogItems + * Signs the user into the PlayFab account, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user. Unlike most other login API calls, LoginWithPlayFab does not permit the creation of + * new accounts via the CreateAccountFlag. Username/Password credentials may be used to create accounts via + * RegisterPlayFabUser, or added to existing accounts using AddUsernamePassword. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithplayfab */ - GetCatalogItems(request: PlayFabClientModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPlayFab(request: PlayFabClientModels.LoginWithPlayFabRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Client/method/GetPublisherData + * Signs the user in using a PlayStation :tm: Network authentication code, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithpsn */ - GetPublisherData(request: PlayFabClientModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPSN(request: PlayFabClientModels.LoginWithPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the set of items defined for the specified store, including all prices defined - / https://api.playfab.com/Documentation/Client/method/GetStoreItems + * Signs the user in using a Steam authentication ticket, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithsteam */ - GetStoreItems(request: PlayFabClientModels.GetStoreItemsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithSteam(request: PlayFabClientModels.LoginWithSteamRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current server time - / https://api.playfab.com/Documentation/Client/method/GetTime + * Signs the user in using a Twitch access token. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithtwitch */ - GetTime(request: PlayFabClientModels.GetTimeRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithTwitch(request: PlayFabClientModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings - / https://api.playfab.com/Documentation/Client/method/GetTitleData + * Signs the user in using a Xbox Live Token, returning a session identifier that can subsequently be used for API calls + * which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/client/authentication/loginwithxbox */ - GetTitleData(request: PlayFabClientModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXbox(request: PlayFabClientModels.LoginWithXboxRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title news feed, as configured in the developer portal - / https://api.playfab.com/Documentation/Client/method/GetTitleNews + * Opens a new outstanding trade. Note that a given item instance may only be in one open trade at a time. + * https://docs.microsoft.com/rest/api/playfab/client/trading/opentrade */ - GetTitleNews(request: PlayFabClientModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback): void; + OpenTrade(request: PlayFabClientModels.OpenTradeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Client/method/AddUserVirtualCurrency + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Selects a payment option for purchase order created via StartPurchase + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/payforpurchase */ - AddUserVirtualCurrency(request: PlayFabClientModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + PayForPurchase(request: PlayFabClientModels.PayForPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Confirms with the payment provider that the purchase was approved (if applicable) and adjusts inventory and virtual currency balances as appropriate - / https://api.playfab.com/Documentation/Client/method/ConfirmPurchase + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Buys a single item with virtual currency. You must specify both the virtual currency to use to purchase, as + * well as what the client believes the price to be. This lets the server fail the purchase if the price has changed. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/purchaseitem */ - ConfirmPurchase(request: PlayFabClientModels.ConfirmPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + PurchaseItem(request: PlayFabClientModels.PurchaseItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's inventory. - / https://api.playfab.com/Documentation/Client/method/ConsumeItem + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the + * Economy->Catalogs tab in the PlayFab Game Manager. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/redeemcoupon */ - ConsumeItem(request: PlayFabClientModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback): void; + RedeemCoupon(request: PlayFabClientModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified character's current inventory of virtual goods - / https://api.playfab.com/Documentation/Client/method/GetCharacterInventory + * Uses the supplied OAuth code to refresh the internally cached player PlayStation :tm: Network auth token + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/refreshpsnauthtoken */ - GetCharacterInventory(request: PlayFabClientModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback): void; + RefreshPSNAuthToken(request: PlayFabClientModels.RefreshPSNAuthTokenRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a completed purchase along with its current PlayFab status. - / https://api.playfab.com/Documentation/Client/method/GetPurchase + * Registers the iOS device to receive push notifications + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/registerforiospushnotification */ - GetPurchase(request: PlayFabClientModels.GetPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RegisterForIOSPushNotification(request: PlayFabClientModels.RegisterForIOSPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Client/method/GetUserInventory + * Registers a new Playfab user account, returning a session identifier that can subsequently be used for API calls which + * require an authenticated user. You must supply a username and an email address. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/registerplayfabuser */ - GetUserInventory(request: PlayFabClientModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + RegisterPlayFabUser(request: PlayFabClientModels.RegisterPlayFabUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Selects a payment option for purchase order created via StartPurchase - / https://api.playfab.com/Documentation/Client/method/PayForPurchase + * Removes a contact email from the player's profile. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/removecontactemail */ - PayForPurchase(request: PlayFabClientModels.PayForPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RemoveContactEmail(request: PlayFabClientModels.RemoveContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Buys a single item with virtual currency. You must specify both the virtual currency to use to purchase, as well as what the client believes the price to be. This lets the server fail the purchase if the price has changed. - / https://api.playfab.com/Documentation/Client/method/PurchaseItem + * Removes a specified user from the friend list of the local user + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/removefriend */ - PurchaseItem(request: PlayFabClientModels.PurchaseItemRequest, callback: PlayFabModule.ApiCallback): void; + RemoveFriend(request: PlayFabClientModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the Economy->Catalogs tab in the PlayFab Game Manager. - / https://api.playfab.com/Documentation/Client/method/RedeemCoupon + * Removes the specified generic service identifier from the player's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/removegenericid */ - RedeemCoupon(request: PlayFabClientModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback): void; + RemoveGenericID(request: PlayFabClientModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates an order for a list of items from the title catalog - / https://api.playfab.com/Documentation/Client/method/StartPurchase + * Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the + * group can remove members. If as a result of the call, zero users remain with access, the group and its associated data + * will be deleted. Shared Groups are designed for sharing data between a very small number of players, please see our + * guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/removesharedgroupmembers */ - StartPurchase(request: PlayFabClientModels.StartPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + RemoveSharedGroupMembers(request: PlayFabClientModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Client/method/SubtractUserVirtualCurrency + * Report player's ad activity + * https://docs.microsoft.com/rest/api/playfab/client/advertising/reportadactivity */ - SubtractUserVirtualCurrency(request: PlayFabClientModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + ReportAdActivity(request: PlayFabClientModels.ReportAdActivityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens the specified container, with the specified key (when required), and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Client/method/UnlockContainerInstance + * Write a PlayStream event to describe the provided player device information. This API method is not designed to be + * called directly by developers. Each PlayFab client SDK will eventually report this information automatically. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/reportdeviceinfo */ - UnlockContainerInstance(request: PlayFabClientModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback): void; + ReportDeviceInfo(request: PlayFabClientModels.DeviceInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Searches target inventory for an ItemInstance matching the given CatalogItemId, if necessary unlocks it using an appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Client/method/UnlockContainerItem + * Submit a report for another player (due to bad bahavior, etc.), so that customer service representatives for the title + * can take action concerning potentially toxic players. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/reportplayer */ - UnlockContainerItem(request: PlayFabClientModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback): void; + ReportPlayer(request: PlayFabClientModels.ReportPlayerClientRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the PlayFab user, based upon a match against a supplied unique identifier, to the friend list of the local user. At least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. - / https://api.playfab.com/Documentation/Client/method/AddFriend + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Restores all in-app purchases based on the given restore receipt + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/restoreiospurchases */ - AddFriend(request: PlayFabClientModels.AddFriendRequest, callback: PlayFabModule.ApiCallback): void; + RestoreIOSPurchases(request: PlayFabClientModels.RestoreIOSPurchasesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current friend list for the local user, constrained to users who have PlayFab accounts. Friends from linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. - / https://api.playfab.com/Documentation/Client/method/GetFriendsList + * Reward player's ad activity + * https://docs.microsoft.com/rest/api/playfab/client/advertising/rewardadactivity */ - GetFriendsList(request: PlayFabClientModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback): void; + RewardAdActivity(request: PlayFabClientModels.RewardAdActivityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes a specified user from the friend list of the local user - / https://api.playfab.com/Documentation/Client/method/RemoveFriend + * Forces an email to be sent to the registered email address for the user's account, with a link allowing the user to + * change the password.If an account recovery email template ID is provided, an email using the custom email template will + * be used. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/sendaccountrecoveryemail */ - RemoveFriend(request: PlayFabClientModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback): void; + SendAccountRecoveryEmail(request: PlayFabClientModels.SendAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the tag list for a specified user in the friend list of the local user - / https://api.playfab.com/Documentation/Client/method/SetFriendTags + * Updates the tag list for a specified user in the friend list of the local user + * https://docs.microsoft.com/rest/api/playfab/client/friend-list-management/setfriendtags */ - SetFriendTags(request: PlayFabClientModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback): void; + SetFriendTags(request: PlayFabClientModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers the iOS device to receive push notifications - / https://api.playfab.com/Documentation/Client/method/RegisterForIOSPushNotification + * Sets the player's secret if it is not already set. Player secrets are used to sign API requests. To reset a player's + * secret use the Admin or Server API method SetPlayerSecret. + * https://docs.microsoft.com/rest/api/playfab/client/authentication/setplayersecret */ - RegisterForIOSPushNotification(request: PlayFabClientModels.RegisterForIOSPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + SetPlayerSecret(request: PlayFabClientModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Restores all in-app purchases based on the given refresh receipt. - / https://api.playfab.com/Documentation/Client/method/RestoreIOSPurchases + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Creates an order for a list of items from the title catalog + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/startpurchase */ - RestoreIOSPurchases(request: PlayFabClientModels.RestoreIOSPurchasesRequest, callback: PlayFabModule.ApiCallback): void; + StartPurchase(request: PlayFabClientModels.StartPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with the Apple store that the receipt for an iOS in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateIOSReceipt + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the user's balance of the specified virtual currency by the stated amount. It is possible to make + * a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/subtractuservirtualcurrency */ - ValidateIOSReceipt(request: PlayFabClientModels.ValidateIOSReceiptRequest, callback: PlayFabModule.ApiCallback): void; + SubtractUserVirtualCurrency(request: PlayFabClientModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get details about all current running game servers matching the given parameters. - / https://api.playfab.com/Documentation/Client/method/GetCurrentGames + * Unlinks the related Android device identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkandroiddeviceid */ - GetCurrentGames(request: PlayFabClientModels.CurrentGamesRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkAndroidDeviceID(request: PlayFabClientModels.UnlinkAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get details about the regions hosting game servers matching the given parameters. - / https://api.playfab.com/Documentation/Client/method/GetGameServerRegions + * Unlinks the related Apple account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkapple */ - GetGameServerRegions(request: PlayFabClientModels.GameServerRegionsRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkApple(request: PlayFabClientModels.UnlinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attempts to locate a game session matching the given parameters. If the goal is to match the player into a specific active session, only the LobbyId is required. Otherwise, the BuildVersion, GameMode, and Region are all required parameters. Note that parameters specified in the search are required (they are not weighting factors). If a slot is found in a server instance matching the parameters, the slot will be assigned to that player, removing it from the availabe set. In that case, the information on the game session will be returned, otherwise the Status returned will be GameNotFound. Note that EnableQueue is deprecated at this time. - / https://api.playfab.com/Documentation/Client/method/Matchmake + * Unlinks the related Battle.net account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkbattlenetaccount */ - Matchmake(request: PlayFabClientModels.MatchmakeRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkBattleNetAccount(request: PlayFabClientModels.UnlinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Start a new game server with a given configuration, add the current player and return the connection information. - / https://api.playfab.com/Documentation/Client/method/StartGame + * Unlinks the related custom identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkcustomid */ - StartGame(request: PlayFabClientModels.StartGameRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkCustomID(request: PlayFabClientModels.UnlinkCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Registers the Android device to receive push notifications - / https://api.playfab.com/Documentation/Client/method/AndroidDevicePushNotificationRegistration + * Unlinks the related Facebook account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkfacebookaccount */ - AndroidDevicePushNotificationRegistration(request: PlayFabClientModels.AndroidDevicePushNotificationRegistrationRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkFacebookAccount(request: PlayFabClientModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates a Google Play purchase and gives the corresponding item to the player. - / https://api.playfab.com/Documentation/Client/method/ValidateGooglePlayPurchase + * Unlinks the related Facebook Instant Game Ids from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkfacebookinstantgamesid */ - ValidateGooglePlayPurchase(request: PlayFabClientModels.ValidateGooglePlayPurchaseRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkFacebookInstantGamesId(request: PlayFabClientModels.UnlinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a character-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WriteCharacterEvent + * Unlinks the related Game Center account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgamecenteraccount */ - WriteCharacterEvent(request: PlayFabClientModels.WriteClientCharacterEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGameCenterAccount(request: PlayFabClientModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a player-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WritePlayerEvent + * Unlinks the related Google account from the user's PlayFab account + * (https://developers.google.com/android/reference/com/google/android/gms/auth/GoogleAuthUtil#public-methods). + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgoogleaccount */ - WritePlayerEvent(request: PlayFabClientModels.WriteClientPlayerEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGoogleAccount(request: PlayFabClientModels.UnlinkGoogleAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a title-based event into PlayStream. - / https://api.playfab.com/Documentation/Client/method/WriteTitleEvent + * Unlinks the related Google Play Games account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkgoogleplaygamesservicesaccount */ - WriteTitleEvent(request: PlayFabClientModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkGooglePlayGamesServicesAccount(request: PlayFabClientModels.UnlinkGooglePlayGamesServicesAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users in the group can add new members. - / https://api.playfab.com/Documentation/Client/method/AddSharedGroupMembers + * Unlinks the related iOS device identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkiosdeviceid */ - AddSharedGroupMembers(request: PlayFabClientModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkIOSDeviceID(request: PlayFabClientModels.UnlinkIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the group. Upon creation, the current user will be the only member of the group. - / https://api.playfab.com/Documentation/Client/method/CreateSharedGroup + * Unlinks the related Kongregate identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkkongregate */ - CreateSharedGroup(request: PlayFabClientModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkKongregate(request: PlayFabClientModels.UnlinkKongregateAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves data stored in a shared group object, as well as the list of members in the group. Non-members of the group may use this to retrieve group data, including membership, but they will not receive data for keys marked as private. - / https://api.playfab.com/Documentation/Client/method/GetSharedGroupData + * Unlinks the related Nintendo account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinknintendoserviceaccount */ - GetSharedGroupData(request: PlayFabClientModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkNintendoServiceAccount(request: PlayFabClientModels.UnlinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the group can remove members. If as a result of the call, zero users remain with access, the group and its associated data will be deleted. - / https://api.playfab.com/Documentation/Client/method/RemoveSharedGroupMembers + * Unlinks the related NintendoSwitchDeviceId from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinknintendoswitchdeviceid */ - RemoveSharedGroupMembers(request: PlayFabClientModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkNintendoSwitchDeviceId(request: PlayFabClientModels.UnlinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated or added in this call will be readable by users not in the group. By default, data permissions are set to Private. Regardless of the permission setting, only members of the group can update the data. - / https://api.playfab.com/Documentation/Client/method/UpdateSharedGroupData + * Unlinks an OpenID Connect account from a user's PlayFab account, based on the connection ID of an existing relationship + * between a title and an Open ID Connect provider. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkopenidconnect */ - UpdateSharedGroupData(request: PlayFabClientModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkOpenIdConnect(request: PlayFabClientModels.UnlinkOpenIdConnectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. - / https://api.playfab.com/Documentation/Client/method/ExecuteCloudScript + * Unlinks the related PlayStation :tm: Network account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkpsnaccount */ - ExecuteCloudScript(request: PlayFabClientModels.ExecuteCloudScriptRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkPSNAccount(request: PlayFabClientModels.UnlinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, the query to retrieve the data will fail. See this post for more information: https://community.playfab.com/hc/en-us/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Client/method/GetContentDownloadUrl + * Unlinks the related Steam account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinksteamaccount */ - GetContentDownloadUrl(request: PlayFabClientModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkSteamAccount(request: PlayFabClientModels.UnlinkSteamAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Client/method/GetAllUsersCharacters + * Unlinks the related Twitch account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinktwitch */ - GetAllUsersCharacters(request: PlayFabClientModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkTwitch(request: PlayFabClientModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Client/method/GetCharacterLeaderboard + * Unlinks the related Xbox Live account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/client/account-management/unlinkxboxaccount */ - GetCharacterLeaderboard(request: PlayFabClientModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + UnlinkXboxAccount(request: PlayFabClientModels.UnlinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of all title-specific statistics for the user - / https://api.playfab.com/Documentation/Client/method/GetCharacterStatistics + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Opens the specified container, with the specified key (when required), and returns the contents of the + * opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will + * be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/unlockcontainerinstance */ - GetCharacterStatistics(request: PlayFabClientModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + UnlockContainerInstance(request: PlayFabClientModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, centered on the requested Character ID - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardAroundCharacter + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Searches target inventory for an ItemInstance matching the given CatalogItemId, if necessary unlocks it + * using an appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are + * consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/client/player-item-management/unlockcontaineritem */ - GetLeaderboardAroundCharacter(request: PlayFabClientModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback): void; + UnlockContainerItem(request: PlayFabClientModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of all of the user's characters for the given statistic. - / https://api.playfab.com/Documentation/Client/method/GetLeaderboardForUserCharacters + * Update the avatar URL of the player + * https://docs.microsoft.com/rest/api/playfab/client/account-management/updateavatarurl */ - GetLeaderboardForUserCharacters(request: PlayFabClientModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + UpdateAvatarUrl(request: PlayFabClientModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Client/method/GrantCharacterToUser + * Creates and updates the title-specific custom data for the user's character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/character-data/updatecharacterdata */ - GrantCharacterToUser(request: PlayFabClientModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback): void; + UpdateCharacterData(request: PlayFabClientModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the specific character. By default, clients are not permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. - / https://api.playfab.com/Documentation/Client/method/UpdateCharacterStatistics + * Updates the values of the specified title-specific statistics for the specific character. By default, clients are not + * permitted to update statistics. Developers may override this setting in the Game Manager > Settings > API Features. + * https://docs.microsoft.com/rest/api/playfab/client/characters/updatecharacterstatistics */ - UpdateCharacterStatistics(request: PlayFabClientModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + UpdateCharacterStatistics(request: PlayFabClientModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the character which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/GetCharacterData + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateplayercustomproperties */ - GetCharacterData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdatePlayerCustomProperties(request: PlayFabClientModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the character which can only be read by the client - / https://api.playfab.com/Documentation/Client/method/GetCharacterReadOnlyData + * Updates the values of the specified title-specific statistics for the user. By default, clients are not permitted to + * update statistics. Developers may override this setting in the Game Manager > Settings > API Features. + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateplayerstatistics */ - GetCharacterReadOnlyData(request: PlayFabClientModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdatePlayerStatistics(request: PlayFabClientModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Creates and updates the title-specific custom data for the user's character which is readable and writable by the client - / https://api.playfab.com/Documentation/Client/method/UpdateCharacterData + * Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated + * or added in this call will be readable by users not in the group. By default, data permissions are set to Private. + * Regardless of the permission setting, only members of the group can update the data. Shared Groups are designed for + * sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/client/shared-group-data/updatesharedgroupdata */ - UpdateCharacterData(request: PlayFabClientModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + UpdateSharedGroupData(request: PlayFabClientModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with Amazon that the receipt for an Amazon App Store in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateAmazonIAPReceipt + * Creates and updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateuserdata */ - ValidateAmazonIAPReceipt(request: PlayFabClientModels.ValidateAmazonReceiptRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Accepts an open trade (one that has not yet been accepted or cancelled), if the locally signed-in player is in the allowed player list for the trade, or it is open to all players. If the call is successful, the offered and accepted items will be swapped between the two players' inventories. - / https://api.playfab.com/Documentation/Client/method/AcceptTrade + * Creates and updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/client/player-data-management/updateuserpublisherdata */ - AcceptTrade(request: PlayFabClientModels.AcceptTradeRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserPublisherData(request: PlayFabClientModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Cancels an open trade (one that has not yet been accepted or cancelled). Note that only the player who created the trade can cancel it via this API call, to prevent griefing of the trade system (cancelling trades in order to prevent other players from accepting them, for trades that can be claimed by more than one player). - / https://api.playfab.com/Documentation/Client/method/CancelTrade + * Updates the title specific display name for the user + * https://docs.microsoft.com/rest/api/playfab/client/account-management/updateusertitledisplayname */ - CancelTrade(request: PlayFabClientModels.CancelTradeRequest, callback: PlayFabModule.ApiCallback): void; + UpdateUserTitleDisplayName(request: PlayFabClientModels.UpdateUserTitleDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all trades the player has either opened or accepted, optionally filtered by trade status. - / https://api.playfab.com/Documentation/Client/method/GetPlayerTrades + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with Amazon that the receipt for an Amazon App Store in-app purchase is valid and that it matches + * the purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validateamazoniapreceipt */ - GetPlayerTrades(request: PlayFabClientModels.GetPlayerTradesRequest, callback: PlayFabModule.ApiCallback): void; + ValidateAmazonIAPReceipt(request: PlayFabClientModels.ValidateAmazonReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets the current status of an existing trade. - / https://api.playfab.com/Documentation/Client/method/GetTradeStatus + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates a Google Play purchase and gives the corresponding item to the player. + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validategoogleplaypurchase */ - GetTradeStatus(request: PlayFabClientModels.GetTradeStatusRequest, callback: PlayFabModule.ApiCallback): void; + ValidateGooglePlayPurchase(request: PlayFabClientModels.ValidateGooglePlayPurchaseRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens a new outstanding trade. Note that a given item instance may only be in one open trade at a time. - / https://api.playfab.com/Documentation/Client/method/OpenTrade + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with the Apple store that the receipt for an iOS in-app purchase is valid and that it matches the + * purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validateiosreceipt */ - OpenTrade(request: PlayFabClientModels.OpenTradeRequest, callback: PlayFabModule.ApiCallback): void; + ValidateIOSReceipt(request: PlayFabClientModels.ValidateIOSReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attributes an install for advertisment. - / https://api.playfab.com/Documentation/Client/method/AttributeInstall + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Validates with Windows that the receipt for an Windows App Store in-app purchase is valid and that it + * matches the purchased catalog item + * https://docs.microsoft.com/rest/api/playfab/client/platform-specific-methods/validatewindowsstorereceipt */ - AttributeInstall(request: PlayFabClientModels.AttributeInstallRequest, callback: PlayFabModule.ApiCallback): void; + ValidateWindowsStoreReceipt(request: PlayFabClientModels.ValidateWindowsReceiptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Client/method/GetPlayerSegments + * Writes a character-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writecharacterevent */ - GetPlayerSegments(request: PlayFabClientModels.GetPlayerSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + WriteCharacterEvent(request: PlayFabClientModels.WriteClientCharacterEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Client/method/GetPlayerTags + * Writes a player-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writeplayerevent */ - GetPlayerTags(request: PlayFabClientModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + WritePlayerEvent(request: PlayFabClientModels.WriteClientPlayerEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates with Windows that the receipt for an Windows App Store in-app purchase is valid and that it matches the purchased catalog item - / https://api.playfab.com/Documentation/Client/method/ValidateWindowsStoreReceipt + * Writes a title-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/client/analytics/writetitleevent */ - ValidateWindowsStoreReceipt(request: PlayFabClientModels.ValidateWindowsReceiptRequest, callback: PlayFabModule.ApiCallback): void; + WriteTitleEvent(request: PlayFabClientModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } } declare module PlayFabClientModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AcceptTradeRequest - */ export interface AcceptTradeRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Player who opened the trade. + * Items from the accepting player's inventory in exchange for the offered items in the trade. In the case of a gift, this + * will be null. */ + AcceptedInventoryInstanceIds?: string[]; + /** Player who opened the trade. */ OfferingPlayerId: string; - /** - / Trade identifier. - */ + /** Trade identifier. */ TradeId: string; - /** - / Items from the accepting player's or guild's inventory in exchange for the offered items in the trade. In the case of a gift, this will be null. - */ - AcceptedInventoryInstanceIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AcceptTradeResponse - */ export interface AcceptTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Details about trade which was just accepted. - */ + /** Details about trade which was just accepted. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AdCampaignAttributionModel - */ + type AdActivity = "Opened" + + | "Closed" + | "Start" + | "End"; + export interface AdCampaignAttributionModel { - /** - / Attribution network name - */ - Platform?: string; - /** - / Attribution campaign identifier - */ - CampaignId?: string; - /** - / UTC time stamp of attribution - */ + /** UTC time stamp of attribution */ AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddFriendRequest - */ export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the user to attempt to add to the local user's friend list. - */ - FriendPlayFabId?: string; - /** - / PlayFab username of the user to attempt to add to the local user's friend list. - */ - FriendUsername?: string; - /** - / Email address of the user to attempt to add to the local user's friend list. - */ + /** Email address of the user to attempt to add to the local user's friend list. */ FriendEmail?: string; - /** - / Title-specific display name of the user to attempt to add to the local user's friend list. - */ + /** PlayFab identifier of the user to attempt to add to the local user's friend list. */ + FriendPlayFabId?: string; + /** Title-specific display name of the user to attempt to add to the local user's friend list. */ FriendTitleDisplayName?: string; + /** PlayFab username of the user to attempt to add to the local user's friend list. */ + FriendUsername?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddFriendResult - */ export interface AddFriendResult extends PlayFabModule.IPlayFabResultCommon { - /** - / True if the friend request was processed successfully. - */ + /** True if the friend request was processed successfully. */ Created: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddGenericIDRequest - */ export interface AddGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generic service identifier to add to the player account. - */ + /** Generic service identifier to add to the player account. */ GenericId: GenericServiceId; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddGenericIDResult - */ export interface AddGenericIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddSharedGroupMembersRequest - */ + export interface AddOrUpdateContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new contact email to associate with the player. */ + EmailAddress: string; + + } + + export interface AddOrUpdateContactEmailResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface AddSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddSharedGroupMembersResult - */ export interface AddSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUsernamePasswordRequest - */ export interface AddUsernamePasswordRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab username for the account (3-20 characters) - */ - Username: string; - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; - /** - / Password for the PlayFab account (6-100 characters) - */ + /** Password for the PlayFab account (6-100 characters) */ Password: string; + /** PlayFab username for the account (3-20 characters) */ + Username: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUsernamePasswordResult - */ export interface AddUsernamePasswordResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique user name. - */ + /** PlayFab unique user name. */ Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the virtual currency which is to be incremented. - */ - VirtualCurrency: string; - /** - / Amount to be added to the user balance of the specified virtual currency. - */ + /** Amount to be added to the user balance of the specified virtual currency. */ Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the virtual currency which is to be incremented. */ + VirtualCurrency: string; + + } + + export interface AdPlacementDetails { + /** Placement unique ID */ + PlacementId?: string; + /** Placement name */ + PlacementName?: string; + /** If placement has viewing limits indicates how many views are left */ + PlacementViewsRemaining?: number; + /** If placement has viewing limits indicates when they will next reset */ + PlacementViewsResetMinutes?: number; + /** Optional URL to a reward asset */ + RewardAssetUrl?: string; + /** Reward description */ + RewardDescription?: string; + /** Reward unique ID */ + RewardId?: string; + /** Reward name */ + RewardName?: string; + + } + + export interface AdRewardItemGranted { + /** Catalog ID */ + CatalogId?: string; + /** Catalog item display name */ + DisplayName?: string; + /** Inventory instance ID */ + InstanceId?: string; + /** Item ID */ + ItemId?: string; + + } + + export interface AdRewardResults { + /** Array of the items granted to the player */ + GrantedItems?: AdRewardItemGranted[]; + /** Dictionary of virtual currencies that were granted to the player */ + GrantedVirtualCurrencies?: { [key: string]: number }; + /** Dictionary of statistics that were modified for the player */ + IncrementedStatistics?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AndroidDevicePushNotificationRegistrationRequest - */ export interface AndroidDevicePushNotificationRegistrationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Message to display when confirming push notification. */ + ConfirmationMessage?: string; /** - / Registration ID provided by the Google Cloud Messaging service when the title registered to receive push notifications (see the GCM documentation, here: http://developer.android.com/google/gcm/client.html). + * Registration ID provided by the Google Cloud Messaging service when the title registered to receive push notifications + * (see the GCM documentation, here: http://developer.android.com/google/gcm/client.html). */ DeviceToken: string; - /** - / If true, send a test push message immediately after sucessful registration. Defaults to false. - */ + /** If true, send a test push message immediately after sucessful registration. Defaults to false. */ SendPushNotificationConfirmation?: boolean; - /** - / Message to display when confirming push notification. - */ - ConfirmationMessage?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AndroidDevicePushNotificationRegistrationResult - */ export interface AndroidDevicePushNotificationRegistrationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AttributeInstallRequest - */ export interface AttributeInstallRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The IdentifierForAdvertisers for iOS Devices. - */ - Idfa?: string; - /** - / The adid for this device. - */ + /** The adid for this device. */ Adid?: string; + /** The IdentifierForAdvertisers for iOS Devices. */ + Idfa?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.AttributeInstallResult - */ export interface AttributeInstallResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CancelTradeRequest - */ + export interface BattleNetAccountPlayFabIdPair { + /** Unique Battle.net account identifier for a user. */ + BattleNetAccountId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Battle.net account identifier. */ + PlayFabId?: string; + + } + export interface CancelTradeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Trade identifier. - */ + /** Trade identifier. */ TradeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CancelTradeResponse - */ export interface CancelTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Details about trade which was just canceled. - */ + /** Details about trade which was just canceled. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CartItem - */ export interface CartItem { - /** - / Unique identifier for the catalog item. - */ - ItemId?: string; - /** - / Class name to which catalog item belongs. - */ + /** Description of the catalog item. */ + Description?: string; + /** Display name for the catalog item. */ + DisplayName?: string; + /** Class name to which catalog item belongs. */ ItemClass?: string; - /** - / Unique instance identifier for this catalog item. - */ + /** Unique identifier for the catalog item. */ + ItemId?: string; + /** Unique instance identifier for this catalog item. */ ItemInstanceId?: string; - /** - / Display name for the catalog item. - */ - DisplayName?: string; - /** - / Description of the catalog item. - */ - Description?: string; - /** - / Cost of the catalog item for each applicable virtual currency. - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Cost of the catalog item for each applicable real world currency. - */ + /** Cost of the catalog item for each applicable real world currency. */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Amount of each applicable virtual currency which will be received as a result of purchasing this catalog item. - */ + /** Amount of each applicable virtual currency which will be received as a result of purchasing this catalog item. */ VCAmount?: { [key: string]: number }; + /** Cost of the catalog item for each applicable virtual currency. */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItem - */ export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data - */ - CustomData?: string; - /** - / defines the consumable properties (number of uses, timeout) for the item + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - Consumable?: CatalogItemConsumableInfo; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ - Container?: CatalogItemContainerInfo; + UsagePeriod?: number; /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies - */ - Bundle?: CatalogItemBundleInfo; - /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) - */ - UsagePeriod?: number; - /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ UsagePeriodGroup?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CatalogItemContainerInfo - */ export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ KeyItemId?: string; /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterInventory - */ export interface CharacterInventory { - /** - / The id of this character. - */ + /** The id of this character. */ CharacterId?: string; - /** - / The inventory of this character. - */ + /** The inventory of this character. */ Inventory?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterLeaderboardEntry - */ export interface CharacterLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. - */ + /** PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. */ CharacterId?: string; - /** - / Title-specific display name of the character for this leaderboard entry. - */ + /** Title-specific display name of the character for this leaderboard entry. */ CharacterName?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Name of the character class for this entry. - */ + /** Name of the character class for this entry. */ CharacterType?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CharacterResult - */ - export interface CharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The id for this character on this player. - */ + export interface CharacterResult { + /** The id for this character on this player. */ CharacterId?: string; - /** - / The name of this character. - */ + /** The name of this character. */ CharacterName?: string; - /** - / The type-string that was given to this character on creation. - */ + /** The type-string that was given to this character on creation. */ CharacterType?: string; } type CloudScriptRevisionOption = "Live" + | "Latest" | "Specific"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CollectionFilter - */ - export interface CollectionFilter { - /** - / List of Include rules, with any of which if a collection matches, it is included by the filter, unless it is excluded by one of the Exclude rule - */ - Includes?: Container_Dictionary_String_String[]; - /** - / List of Exclude rules, with any of which if a collection matches, it is excluded by the filter. - */ - Excludes?: Container_Dictionary_String_String[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConfirmPurchaseRequest - */ export interface ConfirmPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier returned from StartPurchase. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Purchase order identifier returned from StartPurchase. */ OrderId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConfirmPurchaseResult - */ export interface ConfirmPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ + /** Array of items purchased. */ + Items?: ItemInstance[]; + /** Purchase order identifier. */ OrderId?: string; - /** - / Date and time of the purchase. - */ + /** Date and time of the purchase. */ PurchaseDate: string; - /** - / Array of items purchased. - */ - Items?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConsumeItemRequest - */ export interface ConsumeItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique instance identifier of the item to be consumed. - */ - ItemInstanceId: string; - /** - / Number of uses to consume from the item. - */ - ConsumeCount: number; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Number of uses to consume from the item. */ + ConsumeCount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be consumed. */ + ItemInstanceId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ConsumeItemResult - */ export interface ConsumeItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ + /** Unique instance identifier of the item with uses consumed. */ ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ + /** Number of uses remaining on the item. */ RemainingUses: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.Container_Dictionary_String_String - */ - export interface Container_Dictionary_String_String { - /** - / Content of data - */ - Data?: { [key: string]: string }; + export interface ConsumeMicrosoftStoreEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Marketplace specific payload containing details to fetch in app purchase transactions */ + MarketplaceSpecificData: MicrosoftStorePayload; + + } + + export interface ConsumeMicrosoftStoreEntitlementsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ConsumePS5EntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Marketplace specific payload containing details to fetch in app purchase transactions */ + MarketplaceSpecificData: PlayStation5Payload; + + } + + export interface ConsumePS5EntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ConsumePSNEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Which catalog to match granted entitlements against. If null, defaults to title default catalog */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the PlayStation :tm: Network service label to consume entitlements from */ + ServiceLabel: number; + + } + + export interface ConsumePSNEntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of items granted to the player as a result of consuming entitlements. */ + ItemsGranted?: ItemInstance[]; + + } + + export interface ConsumeXboxEntitlementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to use */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; + + } + + export interface ConsumeXboxEntitlementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; } type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1480,31 +1749,23 @@ declare module PlayFabClientModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CreateSharedGroupRequest - */ export interface CreateSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). - */ + /** Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). */ SharedGroupId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CreateSharedGroupResult - */ export interface CreateSharedGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the shared group. - */ + /** Unique identifier for the shared group. */ SharedGroupId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1667,2081 +1928,1725 @@ declare module PlayFabClientModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CurrentGamesRequest - */ - export interface CurrentGamesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Region to check for Game Server Instances. - */ - Region?: string; - /** - / Build to match against. - */ - BuildVersion?: string; - /** - / Game mode to look for. - */ - GameMode?: string; - /** - / Statistic name to find statistic-based matches. - */ - StatisticName?: string; - /** - / Filter to include and/or exclude Game Server Instances associated with certain tags. - */ - TagFilter?: CollectionFilter; + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.CurrentGamesResult - */ - export interface CurrentGamesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of games found - */ - Games?: GameInfo[]; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; + + } + + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / total number of players across all servers + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - PlayerCount: number; + ExpectedPropertiesVersion?: number; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; /** - / number of games running + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - GameCount: number; + PropertiesVersion: number; + + } + + export interface DeviceInfoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Information posted to the PlayStream Event. Currently arbitrary, and specific to the environment sending it. */ + Info?: { [key: string]: any }; + + } + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.EmptyResult - */ export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ExecuteCloudScriptRequest - */ + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + export interface ExecuteCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The name of the CloudScript function to execute - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the CloudScript function to execute */ FunctionName: string; - /** - / Object that is passed in to the function as the first argument - */ + /** Object that is passed in to the function as the first argument */ FunctionParameter?: any; /** - / Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' executes the current live, published revision, and 'Specific' executes the specified revision. The default value is 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. + * Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. */ - RevisionSelection?: string; + GeneratePlayStreamEvent?: boolean; /** - / The specivic revision to execute, when RevisionSelection is set to 'Specific' + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. */ + RevisionSelection?: string; + /** The specivic revision to execute, when RevisionSelection is set to 'Specific' */ SpecificRevision?: number; - /** - / Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. - */ - GeneratePlayStreamEvent?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ExecuteCloudScriptResult - */ export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - FunctionResult?: any; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ Logs?: LogStatement[]; - ExecutionTimeSeconds: number; /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - ProcessorTimeSeconds: number; + LogsTooLarge?: boolean; MemoryConsumedBytes: number; /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; - /** - / Number of external HTTP requests issued by the CloudScript function + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - HttpRequestsIssued: number; - /** - / Information about the error, if any, that occured during execution - */ - Error?: ScriptExecutionError; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FacebookInstantGamesPlayFabIdPair { + /** Unique Facebook Instant Games identifier for a user. */ + FacebookInstantGamesId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook Instant Games identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.FacebookPlayFabIdPair - */ export interface FacebookPlayFabIdPair { - /** - / Unique Facebook identifier for a user. - */ + /** Unique Facebook identifier for a user. */ FacebookId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.FriendInfo - */ export interface FriendInfo { - /** - / PlayFab unique identifier for this friend. - */ + /** Available Facebook information (if the user and connected Facebook friend both have PlayFab Accounts in the same title). */ + FacebookInfo?: UserFacebookInfo; + /** PlayFab unique identifier for this friend. */ FriendPlayFabId?: string; /** - / PlayFab unique username for this friend. - */ - Username?: string; - /** - / Title-specific display name for this friend. - */ - TitleDisplayName?: string; - /** - / Tags which have been associated with this friend. - */ - Tags?: string[]; - /** - / Unique lobby identifier of the Game Server Instance to which this player is currently connected. - */ - CurrentMatchmakerLobbyId?: string; - /** - / Available Facebook information (if the user and PlayFab friend are also connected in Facebook). + * Available Game Center information (if the user and connected Game Center friend both have PlayFab Accounts in the same + * title). */ - FacebookInfo?: UserFacebookInfo; + GameCenterInfo?: UserGameCenterInfo; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; /** - / Available Steam information (if the user and PlayFab friend are also connected in Steam). + * Available PlayStation :tm: Network information, if the user connected PlayStation :tm Network friend both have PlayFab + * Accounts in the same title. */ + PSNInfo?: UserPsnInfo; + /** Available Steam information (if the user and connected Steam friend both have PlayFab Accounts in the same title). */ SteamInfo?: UserSteamInfo; - /** - / Available Game Center information (if the user and PlayFab friend are also connected in Game Center). - */ - GameCenterInfo?: UserGameCenterInfo; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameCenterPlayFabIdPair - */ - export interface GameCenterPlayFabIdPair { - /** - / Unique Game Center identifier for a user. - */ - GameCenterId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Game Center identifier. - */ - PlayFabId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameInfo - */ - export interface GameInfo { - /** - / region to which this server is associated - */ - Region?: string; - /** - / unique lobby identifier for this game server - */ - LobbyID?: string; - /** - / build version this server is running - */ - BuildVersion?: string; - /** - / game mode this server is running - */ - GameMode?: string; - /** - / stastic used to match this game in player statistic matchmaking - */ - StatisticName?: string; - /** - / maximum players this server can support - */ - MaxPlayers?: number; - /** - / array of current player IDs on this server - */ - PlayerUserIds?: string[]; - /** - / duration in seconds this server has been running - */ - RunTime: number; - /** - / game specific string denoting server configuration - */ - GameServerState?: string; - /** - / game session custom data - */ - GameServerData?: string; - /** - / game session tags - */ - Tags?: { [key: string]: string }; - /** - / last heartbeat of the game server instance, used in external game server provider mode - */ - LastHeartbeat?: string; - /** - / IP address of the server - */ - ServerHostname?: string; - /** - / port number to use for non-http communications with the server - */ - ServerPort?: number; - - } - - type GameInstanceState = "Open" - | "Closed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameServerRegionsRequest - */ - export interface GameServerRegionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / version of game server for which stats are being requested - */ - BuildVersion: string; - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; + /** Tags which have been associated with this friend. */ + Tags?: string[]; + /** Title-specific display name for this friend. */ + TitleDisplayName?: string; + /** PlayFab unique username for this friend. */ + Username?: string; + /** Available Xbox information, (if the user and connected Xbox Live friend both have PlayFab Accounts in the same title). */ + XboxInfo?: UserXboxInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GameServerRegionsResult - */ - export interface GameServerRegionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of regions found matching the request parameters - */ - Regions?: RegionInfo[]; + export interface GameCenterPlayFabIdPair { + /** Unique Game Center identifier for a user. */ + GameCenterId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Game Center identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GenericPlayFabIdPair - */ export interface GenericPlayFabIdPair { - /** - / Unique generic service identifier for a user. - */ + /** Unique generic service identifier for a user. */ GenericId?: GenericServiceId; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GenericServiceId - */ export interface GenericServiceId { - /** - / Name of the service for which the player has a unique identifier. - */ + /** Name of the service for which the player has a unique identifier. */ ServiceName: string; - /** - / Unique identifier of the player in that service. - */ + /** Unique identifier of the player in that service. */ UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetAccountInfoRequest - */ export interface GetAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { + /** User email address for the account to find (if no Username is specified). */ + Email?: string; /** - / Unique PlayFab identifier of the user whose info is being requested. Optional, defaults to the authenticated user if no other lookup identifier set. + * Unique PlayFab identifier of the user whose info is being requested. Optional, defaults to the authenticated user if no + * other lookup identifier set. */ PlayFabId?: string; /** - / PlayFab Username for the account to find (if no PlayFabId is specified). - */ - Username?: string; - /** - / User email address for the account to find (if no Username is specified). - */ - Email?: string; - /** - / Title-specific username for the account to find (if no Email is set). Note that if the non-unique Title Display Names option is enabled for the title, attempts to look up users by Title Display Name will always return AccountNotFound. + * Title-specific username for the account to find (if no Email is set). Note that if the non-unique Title Display Names + * option is enabled for the title, attempts to look up users by Title Display Name will always return AccountNotFound. */ TitleDisplayName?: string; + /** PlayFab Username for the account to find (if no PlayFabId is specified). */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetAccountInfoResult - */ export interface GetAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account information for the local user. - */ + /** Account information for the local user. */ AccountInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCatalogItemsRequest - */ + export interface GetAdPlacementsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The current AppId to use */ + AppId: string; + /** Using the name or unique identifier, filter the result for get a specific placement. */ + Identifier?: NameIdentifier; + + } + + export interface GetAdPlacementsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of results */ + AdPlacements?: AdPlacementDetails[]; + + } + export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterDataRequest - */ export interface GetCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterDataResult - */ export interface GetCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / User specific data for this title. - */ + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterInventoryRequest - */ export interface GetCharacterInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Used to limit results to only those from a specific catalog version. - */ + /** Used to limit results to only those from a specific catalog version. */ CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterInventoryResult - */ export interface GetCharacterInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier of the character for this inventory. - */ + /** Unique identifier of the character for this inventory. */ CharacterId?: string; - /** - / Array of inventory items belonging to the character. - */ + /** Array of inventory items belonging to the character. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the character. - */ + /** Array of virtual currency balance(s) belonging to the character. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterLeaderboardRequest - */ export interface GetCharacterLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterLeaderboardResult - */ export interface GetCharacterLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterStatisticsRequest - */ export interface GetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetCharacterStatisticsResult - */ export interface GetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested character statistics. - */ + /** The requested character statistics. */ CharacterStatistics?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetContentDownloadUrlRequest - */ export interface GetContentDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to fetch, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. - */ + /** HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. */ HttpMethod?: string; + /** Key of the content item to fetch, usually formatted as a path, e.g. images/a.png */ + Key: string; /** - / True if download through CDN. CDN provides better download bandwidth and time. However, if you want latest, non-cached version of the content, set this to false. Default is true. + * True to download through CDN. CDN provides higher download bandwidth and lower latency. However, if you want the latest, + * non-cached version of the content during development, set this to false. Default is true. */ ThruCDN?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetContentDownloadUrlResult - */ export interface GetContentDownloadUrlResult extends PlayFabModule.IPlayFabResultCommon { - /** - / URL for downloading content via HTTP GET or HEAD method. The URL will expire in 1 hour. - */ + /** URL for downloading content via HTTP GET or HEAD method. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardAroundPlayerRequest - */ export interface GetFriendLeaderboardAroundPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Statistic used to rank players for this leaderboard. - */ - StatisticName: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; - /** - / PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. - */ + /** PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. */ PlayFabId?: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Statistic used to rank players for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardAroundPlayerResult - */ export interface GetFriendLeaderboardAroundPlayerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendLeaderboardRequest - */ export interface GetFriendLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Statistic used to rank friends for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ + StartPosition: number; + /** Statistic used to rank friends for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendsListRequest - */ export interface GetFriendsListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalPlatformFriends?: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. + * If true, include friends from the same namespace even if they have not logged in to the current title. Defaults to + * false. */ - IncludeSteamFriends?: boolean; + NamespaceWide?: boolean; /** - / Indicates whether Facebook friends should be included in the response. Default is true. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - IncludeFacebookFriends?: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. When provided, all Xbox Live + * users the caller is following are included regardless of whether they follow the caller back. + */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetFriendsListResult - */ export interface GetFriendsListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of friends found. - */ + /** Array of friends found. */ Friends?: FriendInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundCharacterRequest - */ export interface GetLeaderboardAroundCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID for a specific character on which to center the leaderboard. - */ + /** Unique PlayFab assigned ID for a specific character on which to center the leaderboard. */ CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundCharacterResult - */ export interface GetLeaderboardAroundCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundPlayerRequest - */ export interface GetLeaderboardAroundPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ + MaxResultsCount?: number; + /** PlayFab unique identifier of the user to center the leaderboard around. If null will center on the logged in user. */ PlayFabId?: string; /** - / Statistic used to rank players for this leaderboard. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Statistic used to rank players for this leaderboard. */ StatisticName: string; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ - MaxResultsCount?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardAroundPlayerResult - */ export interface GetLeaderboardAroundPlayerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardForUsersCharactersRequest - */ export interface GetLeaderboardForUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ + /** Unique identifier for the title-specific statistic for the leaderboard. */ StatisticName: string; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardForUsersCharactersResult - */ export interface GetLeaderboardForUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardRequest - */ export interface GetLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Statistic used to rank players for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. Default 10, maximum 100. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. Default 10, maximum 100. */ MaxResultsCount?: number; /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ + StartPosition: number; + /** Statistic used to rank players for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetLeaderboardResult - */ export interface GetLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPhotonAuthenticationTokenRequest - */ - export interface GetPhotonAuthenticationTokenRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The Photon applicationId for the game you wish to log into. - */ + export interface GetPaymentTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The name of service to provide the payment token. Allowed Values are: xsolla */ + TokenProvider: string; + + } + + export interface GetPaymentTokenResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab's purchase order identifier. */ + OrderId?: string; + /** The token from provider. */ + ProviderToken?: string; + + } + + export interface GetPhotonAuthenticationTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The Photon applicationId for the game you wish to log into. */ PhotonApplicationId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPhotonAuthenticationTokenResult - */ export interface GetPhotonAuthenticationTokenResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The Photon authentication token for this game-session. - */ + /** The Photon authentication token for this game-session. */ PhotonCustomAuthenticationToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoRequest - */ export interface GetPlayerCombinedInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the user whose data will be returned. If not filled included, we return the data for the calling player. - */ - PlayFabId?: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters: GetPlayerCombinedInfoRequestParams; + /** PlayFabId of the user whose data will be returned. If not filled included, we return the data for the calling player. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoRequestParams - */ export interface GetPlayerCombinedInfoRequestParams { - /** - / Whether to get the player's account Info. Defaults to false - */ + /** Whether to get character inventories. Defaults to false. */ + GetCharacterInventories: boolean; + /** Whether to get the list of characters. Defaults to false. */ + GetCharacterList: boolean; + /** Whether to get player profile. Defaults to false. Has no effect for a new player. */ + GetPlayerProfile: boolean; + /** Whether to get player statistics. Defaults to false. */ + GetPlayerStatistics: boolean; + /** Whether to get title data. Defaults to false. */ + GetTitleData: boolean; + /** Whether to get the player's account Info. Defaults to false */ GetUserAccountInfo: boolean; - /** - / Whether to get the player's inventory. Defaults to false - */ + /** Whether to get the player's custom data. Defaults to false */ + GetUserData: boolean; + /** Whether to get the player's inventory. Defaults to false */ GetUserInventory: boolean; - /** - / Whether to get the player's virtual currency balances. Defaults to false - */ + /** Whether to get the player's read only data. Defaults to false */ + GetUserReadOnlyData: boolean; + /** Whether to get the player's virtual currency balances. Defaults to false */ GetUserVirtualCurrency: boolean; - /** - / Whether to get the player's custom data. Defaults to false - */ - GetUserData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false - */ + /** Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false */ + PlayerStatisticNames?: string[]; + /** Specifies the properties to return from the player profile. Defaults to returning the player's display name. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false */ + TitleDataKeys?: string[]; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false */ UserDataKeys?: string[]; /** - / Whether to get the player's read only data. Defaults to false - */ - GetUserReadOnlyData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is false + * Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is + * false */ UserReadOnlyDataKeys?: string[]; - /** - / Whether to get character inventories. Defaults to false. - */ - GetCharacterInventories: boolean; - /** - / Whether to get the list of characters. Defaults to false. - */ - GetCharacterList: boolean; - /** - / Whether to get title data. Defaults to false. - */ - GetTitleData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false - */ - TitleDataKeys?: string[]; - /** - / Whether to get player statistics. Defaults to false. - */ - GetPlayerStatistics: boolean; - /** - / Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false - */ - PlayerStatisticNames?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoResult - */ export interface GetPlayerCombinedInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Results for requested info. - */ + /** Results for requested info. */ InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerCombinedInfoResultPayload - */ export interface GetPlayerCombinedInfoResultPayload { - /** - / Account information for the user. This is always retrieved. - */ + /** Account information for the user. This is always retrieved. */ AccountInfo?: UserAccountInfo; + /** Inventories for each character for the user. */ + CharacterInventories?: CharacterInventory[]; + /** List of characters for the user. */ + CharacterList?: CharacterResult[]; /** - / Array of inventory items in the user's current inventory. - */ - UserInventory?: ItemInstance[]; - /** - / Dictionary of virtual currency balance(s) belonging to the user. - */ - UserVirtualCurrency?: { [key: string]: number }; - /** - / Dictionary of remaining times and timestamps for virtual currencies. - */ - UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; - /** - / User specific custom data. + * The profile of the players. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ + PlayerProfile?: PlayerProfileModel; + /** List of statistics for this player. */ + PlayerStatistics?: StatisticValue[]; + /** Title data for this title. */ + TitleData?: { [key: string]: string | null }; + /** User specific custom data. */ UserData?: { [key: string]: UserDataRecord }; - /** - / The version of the UserData that was returned. - */ + /** The version of the UserData that was returned. */ UserDataVersion: number; - /** - / User specific read-only data. - */ + /** Array of inventory items in the user's current inventory. */ + UserInventory?: ItemInstance[]; + /** User specific read-only data. */ UserReadOnlyData?: { [key: string]: UserDataRecord }; - /** - / The version of the Read-Only UserData that was returned. - */ + /** The version of the Read-Only UserData that was returned. */ UserReadOnlyDataVersion: number; + /** Dictionary of virtual currency balance(s) belonging to the user. */ + UserVirtualCurrency?: { [key: string]: number }; + /** Dictionary of remaining times and timestamps for virtual currencies. */ + UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; + + } + + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific property name to search for in the player's properties. */ + PropertyName: string; + + } + + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { /** - / List of characters for the user. - */ - CharacterList?: CharacterResult[]; - /** - / Inventories for each character for the user. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - CharacterInventories?: CharacterInventory[]; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; /** - / Title data for this title. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - TitleData?: { [key: string]: string }; + ProfileConstraints?: PlayerProfileViewConstraints; + + } + + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / List of statistics for this player. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - PlayerStatistics?: StatisticValue[]; + PlayerProfile?: PlayerProfileModel; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerSegmentsRequest - */ export interface GetPlayerSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerSegmentsResult - */ export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments the requested player currently belongs to. - */ + /** Array of segments the requested player currently belongs to. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticsRequest - */ export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / statistics to return (current version will be returned for each) - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** statistics to return (current version will be returned for each) */ StatisticNames?: string[]; /** - / statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be returned) + * statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be + * returned) */ StatisticNameVersions?: StatisticNameVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticsResult - */ export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User statistics for the requested user. - */ + /** User statistics for the requested user. */ Statistics?: StatisticValue[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticVersionsRequest - */ export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / unique name of the statistic - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ StatisticName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerStatisticVersionsResult - */ export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ + /** version change history of the statistic */ StatisticVersions?: PlayerStatisticVersion[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTagsRequest - */ export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Optional namespace to filter results by - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTagsResult - */ export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ + /** Canonical tags (including namespace and tag's name) for the requested user */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTradesRequest - */ export interface GetPlayerTradesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Returns only trades with the given status. If null, returns all trades. - */ + /** Returns only trades with the given status. If null, returns all trades. */ StatusFilter?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayerTradesResponse - */ export interface GetPlayerTradesResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The trades for this player which are currently available to be accepted. - */ + /** History of trades which this player has accepted. */ + AcceptedTrades?: TradeInfo[]; + /** The trades for this player which are currently available to be accepted. */ OpenedTrades?: TradeInfo[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / History of trades which this player has accepted. + * Array of unique Battle.net account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 10 in length. */ - AcceptedTrades?: TradeInfo[]; + BattleNetAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Battle.net account identifiers to PlayFab identifiers. */ + Data?: BattleNetAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromFacebookIDsRequest - */ export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. + * Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ FacebookIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromFacebookIDsResult - */ export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook identifiers to PlayFab identifiers. */ + Data?: FacebookPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Facebook identifiers to PlayFab identifiers. + * Array of unique Facebook Instant Games identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: FacebookPlayFabIdPair[]; + FacebookInstantGamesIds: string[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook Instant Games identifiers to PlayFab identifiers. */ + Data?: FacebookInstantGamesPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGameCenterIDsRequest - */ export interface GetPlayFabIDsFromGameCenterIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Game Center identifiers (the Player Identifier) for which the title needs to get PlayFab identifiers. + * Array of unique Game Center identifiers (the Player Identifier) for which the title needs to get PlayFab identifiers. + * The array cannot exceed 25 in length. */ GameCenterIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGameCenterIDsResult - */ export interface GetPlayFabIDsFromGameCenterIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Game Center identifiers to PlayFab identifiers. - */ + /** Mapping of Game Center identifiers to PlayFab identifiers. */ Data?: GameCenterPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGenericIDsRequest - */ export interface GetPlayFabIDsFromGenericIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a maximum of 10 in a single request. + * Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a + * maximum of 10 in a single request. */ GenericIDs: GenericServiceId[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGenericIDsResult - */ export interface GetPlayFabIDsFromGenericIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of generic service identifiers to PlayFab identifiers. - */ + /** Mapping of generic service identifiers to PlayFab identifiers. */ Data?: GenericPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGoogleIDsRequest - */ export interface GetPlayFabIDsFromGoogleIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Google identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. + * Array of unique Google identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ GoogleIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromGoogleIDsResult - */ export interface GetPlayFabIDsFromGoogleIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Google identifiers to PlayFab identifiers. */ + Data?: GooglePlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromGooglePlayGamesPlayerIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Google identifiers to PlayFab identifiers. + * Array of unique Google Play Games identifiers (Google+ user IDs) for which the title needs to get PlayFab identifiers. + * The array cannot exceed 25 in length. */ - Data?: GooglePlayFabIdPair[]; + GooglePlayGamesPlayerIDs: string[]; + + } + + export interface GetPlayFabIDsFromGooglePlayGamesPlayerIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Google Play Games identifiers to PlayFab identifiers. */ + Data?: GooglePlayGamesPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromKongregateIDsRequest - */ export interface GetPlayFabIDsFromKongregateIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Kongregate identifiers (Kongregate's user_id) for which the title needs to get PlayFab identifiers. + * Array of unique Kongregate identifiers (Kongregate's user_id) for which the title needs to get PlayFab identifiers. The + * array cannot exceed 25 in length. */ KongregateIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromKongregateIDsResult - */ export interface GetPlayFabIDsFromKongregateIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Kongregate identifiers to PlayFab identifiers. - */ + /** Mapping of Kongregate identifiers to PlayFab identifiers. */ Data?: KongregatePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromSteamIDsRequest - */ - export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromNintendoServiceAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. + * Nintendo NSA issuer URL identifying the environment. When provided, only accounts registered in that environment are + * returned. If null or empty, falls back to the default environment. */ - SteamStringIDs?: string[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromSteamIDsResult - */ - export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + Issuer?: string; /** - / Mapping of Steam identifiers to PlayFab identifiers. + * Array of unique Nintendo Switch Account identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: SteamPlayFabIdPair[]; + NintendoAccountIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromTwitchIDsRequest - */ - export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. - */ - TwitchIds: string[]; + export interface GetPlayFabIDsFromNintendoServiceAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Service Account identifiers to PlayFab identifiers. */ + Data?: NintendoServiceAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPlayFabIDsFromTwitchIDsResult - */ - export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Mapping of Twitch identifiers to PlayFab identifiers. + * Array of unique Nintendo Switch Device identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Data?: TwitchPlayFabIdPair[]; + NintendoSwitchDeviceIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPublisherDataRequest - */ - export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ - Keys: string[]; + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Device identifiers to PlayFab identifiers. */ + Data?: NintendoSwitchPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPublisherDataResult - */ - export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromOpenIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / a dictionary object of key / value pairs + * Array of unique OpenId Connect identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed + * 10 in length. */ - Data?: { [key: string]: string }; + OpenIdSubjectIdentifiers: OpenIdSubjectIdentifier[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPurchaseRequest - */ - export interface GetPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier. - */ - OrderId: string; + export interface GetPlayFabIDsFromOpenIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of OpenId Connect identifiers to PlayFab identifiers. */ + Data?: OpenIdSubjectIdentifierPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetPurchaseResult - */ - export interface GetPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; + export interface GetPlayFabIDsFromPSNAccountIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Payment provider used for transaction (If not VC) + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - PaymentProvider?: string; - /** - / Provider transaction ID (If not VC) - */ - TransactionId?: string; + IssuerId?: number; /** - / PlayFab transaction status + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - TransactionStatus?: string; - /** - / Date and time of the purchase. - */ - PurchaseDate: string; + PSNAccountIDs: string[]; /** - / Array of items purchased. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - Items?: ItemInstance[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ - Id: string; - /** - / Segment name. - */ - Name?: string; - /** - / Identifier of the segments AB Test, if it is attached to one. - */ - ABTestParent?: string; + export interface GetPlayFabIDsFromPSNAccountIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSharedGroupDataRequest - */ - export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromPSNOnlineIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier for the shared group. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - SharedGroupId: string; + IssuerId?: number; /** - / Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array indicates that no keys should be returned). + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Keys?: string[]; + PSNOnlineIDs: string[]; /** - / If true, return the list of all members of the shared group. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - GetMembers?: boolean; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetSharedGroupDataResult - */ - export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Data for the requested keys. - */ - Data?: { [key: string]: SharedGroupDataRecord }; - /** - / List of PlayFabId identifiers for the members of this group, if requested. - */ - Members?: string[]; + export interface GetPlayFabIDsFromPSNOnlineIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNOnlinePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetStoreItemsRequest - */ - export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / catalog version to store items from. Use default catalog version if null - */ - CatalogVersion?: string; + export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unqiue identifier for the store which is being requested. + * Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - StoreId: string; + SteamStringIDs?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetStoreItemsResult - */ - export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased from this store. - */ - Store?: StoreItem[]; - /** - / How the store was last updated (Admin or a third party). - */ - Source?: string; - /** - / The base catalog that this store is a part of. - */ - CatalogVersion?: string; - /** - / The ID of this store. - */ - StoreId?: string; + export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Additional data about the store. + * Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - MarketingData?: StoreMarketingModel; + SteamNames: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTimeRequest - */ - export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamNamePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTimeResult - */ - export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Current server time when the request was received, in UTC + * Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Time: string; + TwitchIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleDataRequest - */ - export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Specific keys to search for in the title data (leave null to get all keys) - */ - Keys?: string[]; + export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Twitch identifiers to PlayFab identifiers. */ + Data?: TwitchPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleDataResult - */ - export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The ID of Xbox Live sandbox. */ + Sandbox?: string; /** - / a dictionary object of key / value pairs + * Array of unique Xbox Live account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Data?: { [key: string]: string }; + XboxLiveAccountIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleNewsRequest - */ - export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Limits the results to the last n entries. Defaults to 10 if not set. - */ - Count?: number; + export interface GetPlayFabIDsFromXboxLiveIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Xbox Live identifiers to PlayFab identifiers. */ + Data?: XboxLiveAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTitleNewsResult - */ - export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ + Keys: string[]; + + } + + export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; + + } + + export interface GetPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Purchase order identifier. */ + OrderId: string; + + } + + export interface GetPurchaseResult extends PlayFabModule.IPlayFabResultCommon { + /** Purchase order identifier. */ + OrderId?: string; + /** Payment provider used for transaction (If not VC) */ + PaymentProvider?: string; + /** Date and time of the purchase. */ + PurchaseDate: string; + /** Provider transaction ID (If not VC) */ + TransactionId?: string; + /** PlayFab transaction status */ + TransactionStatus?: string; + + } + + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ + Id: string; + /** Segment name. */ + Name?: string; + + } + + export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** If true, return the list of all members of the shared group. */ + GetMembers?: boolean; /** - / Array of news items. + * Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array + * indicates that no keys should be returned). */ - News?: TitleNewsItem[]; + Keys?: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTradeStatusRequest - */ - export interface GetTradeStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { + /** Data for the requested keys. */ + Data?: { [key: string]: SharedGroupDataRecord }; + /** List of PlayFabId identifiers for the members of this group, if requested. */ + Members?: string[]; + + } + + export interface GetStoreItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to store items from. Use default catalog version if null */ + CatalogVersion?: string; + /** Unqiue identifier for the store which is being requested. */ + StoreId: string; + + } + + export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** The base catalog that this store is a part of. */ + CatalogVersion?: string; + /** Additional data about the store. */ + MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; + + } + + export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { + /** Current server time when the request was received, in UTC */ + Time: string; + + } + + export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Player who opened trade. + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - OfferingPlayerId: string; + OverrideLabel?: string; + + } + + export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; + + } + + export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Limits the results to the last n entries. Defaults to 10 if not set. */ + Count?: number; + + } + + export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of news items. */ + News?: TitleNewsItem[]; + + } + + export interface GetTitlePublicKeyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Trade identifier as returned by OpenTradeOffer. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId: string; + /** The shared secret key for this title */ + TitleSharedSecret: string; + + } + + export interface GetTitlePublicKeyResult extends PlayFabModule.IPlayFabResultCommon { + /** Base64 encoded RSA CSP byte array blob containing the title's public RSA key */ + RSAPublicKey?: string; + + } + + export interface GetTradeStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player who opened trade. */ + OfferingPlayerId: string; + /** Trade identifier as returned by OpenTradeOffer. */ TradeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetTradeStatusResponse - */ export interface GetTradeStatusResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the requested trade. - */ + /** Information about the requested trade. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Specific keys to search for in the custom data. Leave null to get all keys. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ + IfChangedFromDataVersion?: number; + /** List of unique keys to load from. */ Keys?: string[]; /** - / Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. When specified to a PlayFab id of another player, then this will only return public keys for that account. + * Unique PlayFab identifier of the user to load data for. Optional, defaults to yourself if not set. When specified to a + * PlayFab id of another player, then this will only return public keys for that account. */ PlayFabId?: string; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. - */ - IfChangedFromDataVersion?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User specific data for this title. - */ + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetWindowsHelloChallengeRequest - */ - export interface GetWindowsHelloChallengeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId: string; - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GetWindowsHelloChallengeResponse - */ - export interface GetWindowsHelloChallengeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Server generated challenge to be signed by the user. - */ - Challenge?: string; + export interface GooglePlayFabIdPair { + /** Unique Google identifier for a user. */ + GoogleId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GooglePlayFabIdPair - */ - export interface GooglePlayFabIdPair { - /** - / Unique Google identifier for a user. - */ - GoogleId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google identifier. - */ + export interface GooglePlayGamesPlayFabIdPair { + /** Unique Google Play Games identifier for a user. */ + GooglePlayGamesPlayerId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Google Play Games identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GrantCharacterToUserRequest - */ export interface GrantCharacterToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; + /** Non-unique display name of the character being granted (1-40 characters in length). */ + CharacterName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Catalog item identifier of the item in the user's inventory that corresponds to the character in the catalog to be created. + * Catalog item identifier of the item in the user's inventory that corresponds to the character in the catalog to be + * created. */ ItemId: string; - /** - / Non-unique display name of the character being granted. - */ - CharacterName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.GrantCharacterToUserResult - */ export interface GrantCharacterToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier tagged to this character. - */ + /** Unique identifier tagged to this character. */ CharacterId?: string; - /** - / Type of character that was created. - */ + /** Type of character that was created. */ CharacterType?: string; - /** - / Indicates whether this character was created successfully. - */ + /** Indicates whether this character was created successfully. */ Result: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ItemPurchaseRequest - */ - export interface ItemPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique ItemId of the item to purchase. - */ + export interface ItemPurchaseRequest { + /** Title-specific text concerning this purchase. */ + Annotation?: string; + /** Unique ItemId of the item to purchase. */ ItemId: string; - /** - / How many of this item to purchase. - */ + /** How many of this item to purchase. Min 1, maximum 25. */ Quantity: number; - /** - / Title-specific text concerning this purchase. - */ - Annotation?: string; - /** - / Items to be upgraded as a result of this purchase (upgraded items are hidden, as they are "replaced" by the new items). - */ + /** Items to be upgraded as a result of this purchase (upgraded items are hidden, as they are "replaced" by the new items). */ UpgradeFromItems?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.KongregatePlayFabIdPair - */ export interface KongregatePlayFabIdPair { - /** - / Unique Kongregate identifier for a user. - */ + /** Unique Kongregate identifier for a user. */ KongregateId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Kongregate identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Kongregate identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkAndroidDeviceIDRequest - */ export interface LinkAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Android device identifier for the user's device. - */ - AndroidDeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. - */ + /** Specific model of the user's device. */ AndroidDevice?: string; - /** - / If another user is already linked to the device, unlink the other user and re-link. - */ + /** Android device identifier for the user's device. */ + AndroidDeviceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the device, unlink the other user and re-link. */ ForceLink?: boolean; + /** Specific Operating System version for the user's device. */ + OS?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkAndroidDeviceIDResult - */ export interface LinkAndroidDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkCustomIDRequest - */ - export interface LinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Apple account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Custom unique identifier for the user, generated by the title. + * The JSON Web token (JWT) returned by Apple after login. Represented as the identityToken field in the authorization + * credential payload. Used to validate the request and find the user ID (Apple subject) to link with. */ + IdentityToken: string; + + } + + export interface LinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Battle.net account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + + } + + export interface LinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom unique identifier for the user, generated by the title. */ CustomId: string; - /** - / If another user is already linked to the custom ID, unlink the other user and re-link. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the custom ID, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkCustomIDResult - */ export interface LinkCustomIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkedPlatformAccountModel - */ export interface LinkedPlatformAccountModel { - /** - / Authentication platform - */ + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ Platform?: string; - /** - / Unique account identifier of the user on the platform - */ + /** Unique account identifier of the user on the platform */ PlatformUserId?: string; - /** - / Linked account username of the user on the platform, if available - */ + /** Linked account username of the user on the platform, if available */ Username?: string; - /** - / Linked account email of the user on the platform, if available - */ - Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkFacebookAccountRequest - */ export interface LinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier from Facebook for the user. - */ - AccessToken: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + /** Unique identifier from Facebook for the user. */ + AccessToken?: string; + /** Token used for limited login authentication. */ + AuthenticationToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkFacebookAccountResult - */ export interface LinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGameCenterAccountRequest - */ + export interface LinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games signature for the user. */ + FacebookInstantGamesSignature: string; + /** If another user is already linked to the Facebook Instant Games ID, unlink the other user and re-link. */ + ForceLink?: boolean; + + } + + export interface LinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface LinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Game Center identifier for the player account to be linked. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ + ForceLink?: boolean; + /** Game Center identifier for the player account to be linked. */ GameCenterId: string; + /** The URL for the public encryption key that will be used to verify the signature. */ + PublicKeyUrl?: string; + /** A random value used to compute the hash and keep it randomized. */ + Salt?: string; + /** The verification signature of the authentication payload. */ + Signature?: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * The integer representation of date and time that the signature was created on. PlayFab will reject authentication + * signatures not within 10 minutes of the server's current time. */ - ForceLink?: boolean; + Timestamp?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGameCenterAccountResult - */ export interface LinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGoogleAccountRequest - */ export interface LinkGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Server authentication code obtained on the client by calling getServerAuthCode() (https://developers.google.com/identity/sign-in/android/offline-access) from Google Play for the user. - */ - ServerAuthCode?: string; - /** - / OAuth 2.0 access token obtained on the client by calling the getAccessToken() Google client API. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ - AccessToken?: string; + ForceLink?: boolean; /** - / If another user is already linked to the account, unlink the other user and re-link. + * Server authentication code obtained on the client by calling getServerAuthCode() + * (https://developers.google.com/identity/sign-in/android/offline-access) from Google Play for the user. */ - ForceLink?: boolean; + ServerAuthCode?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkGoogleAccountResult - */ export interface LinkGoogleAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkIOSDeviceIDRequest - */ - export interface LinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkGooglePlayGamesServicesAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Vendor-specific iOS identifier for the user's device. + * If another user is already linked to the account, unlink the other user and re-link. If the current user is already + * linked, link both accounts */ - DeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; + ForceLink?: boolean; /** - / Specific model of the user's device. + * OAuth 2.0 server authentication code obtained on the client by calling the requestServerSideAccess() + * (https://developers.google.com/games/services/android/signin) Google Play Games client API. */ + ServerAuthCode: string; + + } + + export interface LinkGooglePlayGamesServicesAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId: string; + /** Specific model of the user's device. */ DeviceModel?: string; - /** - / If another user is already linked to the device, unlink the other user and re-link. - */ + /** If another user is already linked to the device, unlink the other user and re-link. */ ForceLink?: boolean; + /** Specific Operating System version for the user's device. */ + OS?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkIOSDeviceIDResult - */ export interface LinkIOSDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkKongregateAccountRequest - */ export interface LinkKongregateAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Valid session auth ticket issued by Kongregate */ + AuthTicket: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Numeric user ID assigned by Kongregate */ + KongregateId: string; + + } + + export interface LinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Switch account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Numeric user ID assigned by Kongregate + * The JSON Web token (JWT) returned by Nintendo after login. Used to validate the request and find the user ID (Nintendo + * Switch subject) to link with. */ - KongregateId: string; + IdentityToken: string; + + } + + export interface LinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the Nintendo Switch Device ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId: string; + + } + + export interface LinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LinkOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific OpenId Connect user, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Valid session auth ticket issued by Kongregate + * The JSON Web token (JWT) returned by the identity provider after login. Represented as the id_token field in the + * identity provider's response. Used to validate the request and find the user ID (OpenID Connect subject) to link with. */ - AuthTicket: string; + IdToken: string; + + } + + export interface LinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Authentication code provided by the PlayStation :tm: Network. */ + AuthCode: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ + AuthVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkKongregateAccountResult - */ - export interface LinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkSteamAccountRequest - */ export interface LinkSteamAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte 0x08 should become "08"). + * Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte + * 0x08 should become "08"). */ SteamTicket: string; /** - / If another user is already linked to the account, unlink the other user and re-link. + * True if ticket was generated using ISteamUser::GetAuthTicketForWebAPI() using "AzurePlayFab" as the identity string. + * False if the ticket was generated with ISteamUser::GetAuthSessionTicket(). */ - ForceLink?: boolean; + TicketIsServiceSpecific?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkSteamAccountResult - */ export interface LinkSteamAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkTwitchAccountRequest - */ export interface LinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Valid token issued by Twitch - */ + /** Valid token issued by Twitch */ AccessToken: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkTwitchAccountResult - */ export interface LinkTwitchAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkWindowsHelloAccountRequest - */ - export interface LinkWindowsHelloAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Player's user named used by Windows Hello. - */ - UserName: string; - /** - / PublicKey generated by Windows Hello. - */ - PublicKey: string; - /** - / Device name. - */ - DeviceName?: string; - /** - / If another user is already linked to the account, unlink the other user and re-link. - */ + export interface LinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ ForceLink?: boolean; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LinkWindowsHelloAccountResponse - */ - export interface LinkWindowsHelloAccountResponse extends PlayFabModule.IPlayFabResultCommon { + export interface LinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ListUsersCharactersRequest - */ - export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + + } + + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ListUsersCharactersResult - */ export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested list of characters. - */ + /** The requested list of characters. */ Characters?: CharacterResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LocationModel - */ export interface LocationModel { - /** - / The two-character continent code for this location - */ + /** City name. */ + City?: string; + /** The two-character continent code for this location */ ContinentCode?: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ + /** The two-character ISO 3166-1 country code for the country associated with the location */ CountryCode?: string; - /** - / City name. - */ - City?: string; - /** - / Latitude coordinate of the geographic location. - */ + /** Latitude coordinate of the geographic location. */ Latitude?: number; - /** - / Longitude coordinate of the geographic location. - */ + /** Longitude coordinate of the geographic location. */ Longitude?: number; } type LoginIdentityProvider = "Unknown" + | "PlayFab" | "Custom" | "GameCenter" @@ -3754,1568 +3659,1367 @@ declare module PlayFabClientModels { | "IOSDevice" | "AndroidDevice" | "Twitch" - | "WindowsHello"; + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginResult - */ export interface LoginResult extends PlayFabModule.IPlayFabResultCommon { /** - / Unique token authorizing the user and game at the server level, for the current session. - */ - SessionTicket?: string; - /** - / Player's unique PlayFabId. - */ - PlayFabId?: string; - /** - / True if the account was newly created on this login. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ + EntityToken?: EntityTokenResponse; + /** Results for requested info. */ + InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue */ + LastLoginTime?: string; + /** True if the master_player_account was newly created on this login. */ NewlyCreated: boolean; - /** - / Settings specific to this user. - */ + /** Player's unique PlayFabId. */ + PlayFabId?: string; + /** Unique token authorizing the user and game at the server level, for the current session. */ + SessionTicket?: string; + /** Settings specific to this user. */ SettingsForUser?: UserSettings; - /** - / The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue - */ - LastLoginTime?: string; - /** - / Results for requested info. - */ - InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The experimentation treatments for this user at the time of login. */ + TreatmentAssignment?: TreatmentAssignment; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithAndroidDeviceIDRequest - */ export interface LoginWithAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific model of the user's device. */ + AndroidDevice?: string; + /** Android device identifier for the user's device. */ + AndroidDeviceId?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; + + } + + export interface LoginWithAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; /** - / Android device identifier for the user's device. - */ - AndroidDeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. + * The JSON Web token (JWT) returned by Apple after login. Represented as the identityToken field in the authorization + * credential payload. If you choose to ignore the expiration date for identity tokens, you will receive an NotAuthorized + * error if Apple rotates the signing key. In this case, users have to login to provide a fresh identity token. */ - AndroidDevice?: string; + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Android device. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId?: string; + + } + + export interface LoginWithBattleNetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithCustomIDRequest - */ export interface LoginWithCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Custom unique identifier for the user, generated by the title. - */ - CustomId: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Custom ID. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** Custom unique identifier for the user, generated by the title. */ + CustomId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithEmailAddressRequest - */ export interface LoginWithEmailAddressRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Email address for the account. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Email address for the account. */ Email: string; - /** - / Password for the PlayFab account (6-100 characters) - */ + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ Password: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithFacebookRequest - */ - export interface LoginWithFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LoginWithFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Facebook Instant Games signature for the user. */ + FacebookInstantGamesSignature: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / Unique identifier from Facebook for the user. - */ - AccessToken: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Facebook account. - */ + + } + + export interface LoginWithFacebookRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier from Facebook for the user. */ + AccessToken?: string; + /** Token used for limited login authentication. */ + AuthenticationToken?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithGameCenterRequest - */ export interface LoginWithGameCenterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Unique Game Center player id. - */ - PlayerId: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Game Center id. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Unique Game Center player id. */ + PlayerId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** The URL for the public encryption key that will be used to verify the signature. */ + PublicKeyUrl?: string; + /** A random value used to compute the hash and keep it randomized. */ + Salt?: string; + /** The verification signature of the authentication payload. */ + Signature?: string; + /** + * The integer representation of date and time that the signature was created on. PlayFab will reject authentication + * signatures not within 10 minutes of the server's current time. + */ + Timestamp?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithGoogleAccountRequest - */ export interface LoginWithGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / OAuth 2.0 server authentication code obtained on the client by calling the getServerAuthCode() (https://developers.google.com/identity/sign-in/android/offline-access) Google client API. + * OAuth 2.0 server authentication code obtained on the client by calling the getServerAuthCode() + * (https://developers.google.com/identity/sign-in/android/offline-access) Google client API. */ ServerAuthCode?: string; + /** Optional boolean to opt out of setting the MPA email when creating a Google account, defaults to true. */ + SetEmail?: boolean; /** - / OAuth 2.0 access token obtained on the client by calling the getAccessToken() Google client API. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - AccessToken?: string; + TitleId?: string; + + } + + export interface LoginWithGooglePlayGamesServicesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Google account. + * OAuth 2.0 server authentication code obtained on the client by calling the requestServerSideAccess() + * (https://developers.google.com/games/services/android/signin) Google Play Games client API. */ - CreateAccount?: boolean; + ServerAuthCode?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithIOSDeviceIDRequest - */ export interface LoginWithIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Vendor-specific iOS identifier for the user's device. - */ - DeviceId: string; - /** - / Specific Operating System version for the user's device. - */ - OS?: string; - /** - / Specific model of the user's device. - */ + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId?: string; + /** Specific model of the user's device. */ DeviceModel?: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this iOS device. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - CreateAccount?: boolean; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithKongregateRequest - */ export interface LoginWithKongregateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Token issued by Kongregate's client API for the user. */ + AuthTicket?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Numeric user ID assigned by Kongregate */ + KongregateId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; + + } + + export interface LoginWithNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** The JSON Web token (JWT) returned by Nintendo after login. */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Numeric user ID assigned by Kongregate - */ - KongregateId: string; - /** - / Token issued by Kongregate's client API for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - AuthTicket: string; + TitleId?: string; + + } + + export interface LoginWithNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Kongregate account. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ + TitleId?: string; + + } + + export interface LoginWithOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; /** - / Flags for which pieces of info to return for the user. + * The JSON Web token (JWT) returned by the identity provider after login. Represented as the id_token field in the + * identity provider's response. */ + IdToken: string; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. + */ + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithPlayFabRequest - */ export interface LoginWithPlayFabRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ + Password: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / PlayFab username for the account. - */ + /** PlayFab username for the account. */ Username: string; + + } + + export interface LoginWithPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code provided by the PlayStation :tm: Network OAuth provider. */ + AuthCode?: string; /** - / Password for the PlayFab account (6-100 characters) + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ - Password: string; + AuthVersion?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithSteamRequest - */ export interface LoginWithSteamRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte 0x08 should become "08"). + * Authentication token for the user, returned as a byte array from Steam, and converted to a string (for example, the byte + * 0x08 should become "08"). */ - SteamTicket: string; + SteamTicket?: string; /** - / Automatically create a PlayFab account if one is not currently linked to this Steam account. + * True if ticket was generated using ISteamUser::GetAuthTicketForWebAPI() using "AzurePlayFab" as the identity string. + * False if the ticket was generated with ISteamUser::GetAuthSessionTicket(). */ - CreateAccount?: boolean; + TicketIsServiceSpecific?: boolean; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithTwitchRequest - */ export interface LoginWithTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / Token issued by Twitch's API for the user. - */ - AccessToken: string; - /** - / Automatically create a PlayFab account if one is not currently linked to this Twitch account. - */ + /** Token issued by Twitch's API for the user. */ + AccessToken?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Flags for which pieces of info to return for the user. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + TitleId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LoginWithWindowsHelloRequest - */ - export interface LoginWithWindowsHelloRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LoginWithXboxRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId?: string; - /** - / The signed response from the user for the Challenge. - */ - ChallengeSignature: string; - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; - /** - / Flags for which pieces of info to return for the user. - */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.LogStatement - */ export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ Level?: string; Message?: string; - /** - / Optional object accompanying the message as contextual information - */ - Data?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.MatchmakeRequest - */ - export interface MatchmakeRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Build version to match against. [Note: Required if LobbyId is not specified] - */ - BuildVersion?: string; - /** - / Region to match make against. [Note: Required if LobbyId is not specified] - */ - Region?: string; - /** - / Game mode to match make against. [Note: Required if LobbyId is not specified] - */ - GameMode?: string; - /** - / Lobby identifier to match make against. This is used to select a specific Game Server Instance. - */ - LobbyId?: string; + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / Player statistic to use in finding a match. May be null for no stat-based matching. + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - StatisticName?: string; - /** - / Character to use for stats based matching. Leave null to use account stats. - */ - CharacterId?: string; - /** - / Start a game session if one with an open slot is not found. Defaults to true. - */ - StartNewIfNoneFound?: boolean; - /** - / Filter to include and/or exclude Game Server Instances associated with certain Tags - */ - TagFilter?: CollectionFilter; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.MatchmakeResult - */ - export interface MatchmakeResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique lobby identifier of the server matched - */ - LobbyID?: string; - /** - / IP address of the server - */ - ServerHostname?: string; - /** - / port number to use for non-http communications with the server - */ - ServerPort?: number; - /** - / server authorization ticket (used by RedeemMatchmakerTicket to validate user insertion into the game) - */ - Ticket?: string; - /** - / timestamp for when the server will expire, if applicable - */ - Expires?: string; - /** - / time in milliseconds the application is configured to wait on matchmaking results - */ - PollWaitTimeMS?: number; + export interface MicrosoftStorePayload { + /** Microsoft store ID key. This is optional. Alternatively you can use XboxToken */ + CollectionsMsIdKey?: string; + /** If collectionsMsIdKey is provided, this will verify the user id in the collectionsMsIdKey is the same. */ + UserId?: string; /** - / result of match making process + * Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). This is + * optional. Alternatively can use CollectionsMsIdKey */ - Status?: string; + XboxToken?: string; } - type MatchmakeStatus = "Complete" - | "Waiting" - | "GameNotFound" - | "NoAvailableSlots" - | "SessionClosed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ModifyUserVirtualCurrencyResult - */ export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / User currency was subtracted from. + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ + BalanceChange: number; + /** User currency was subtracted from. */ PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ + /** Name of the virtual currency which was modified. */ VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.NameIdentifier - */ export interface NameIdentifier { - Name?: string; + /** Id Identifier, if present */ Id?: string; + /** Name Identifier, if present */ + Name?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.OpenTradeRequest - */ - export interface OpenTradeRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface NintendoServiceAccountPlayFabIdPair { + /** Unique Nintendo Switch Service Account identifier for a user. */ + NintendoServiceAccountId?: string; /** - / Player inventory items offered for trade. If not set, the trade is effectively a gift request + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Service Account + * identifier. */ - OfferedInventoryInstanceIds?: string[]; - /** - / Catalog items accepted for the trade. If not set, the trade is effectively a gift. - */ - RequestedCatalogItemIds?: string[]; + PlayFabId?: string; + + } + + export interface NintendoSwitchPlayFabIdPair { + /** Unique Nintendo Switch Device identifier for a user. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Device identifier. */ + PlayFabId?: string; + + } + + export interface OpenIdSubjectIdentifier { + /** The issuer URL for the OpenId Connect provider, or the override URL if an override exists. */ + Issuer: string; + /** The unique subject identifier within the context of the issuer. */ + Subject: string; + + } + + export interface OpenIdSubjectIdentifierPlayFabIdPair { + /** Unique OpenId Connect identifier for a user. */ + OpenIdSubjectIdentifier?: OpenIdSubjectIdentifier; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the OpenId Connect identifier. */ + PlayFabId?: string; + + } + + export interface OpenTradeRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Players who are allowed to accept the trade. If null, the trade may be accepted by any player. If empty, the trade may not be accepted by any player. + * Players who are allowed to accept the trade. If null, the trade may be accepted by any player. If empty, the trade may + * not be accepted by any player. */ AllowedPlayerIds?: string[]; + /** Player inventory items offered for trade. If not set, the trade is effectively a gift request */ + OfferedInventoryInstanceIds?: string[]; + /** Catalog items accepted for the trade. If not set, the trade is effectively a gift. */ + RequestedCatalogItemIds?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.OpenTradeResponse - */ export interface OpenTradeResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / The information about the trade that was just opened. - */ + /** The information about the trade that was just opened. */ Trade?: TradeInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PayForPurchaseRequest - */ export interface PayForPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Purchase order identifier returned from StartPurchase. - */ + /** Currency to use to fund the purchase. */ + Currency: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Purchase order identifier returned from StartPurchase. */ OrderId: string; - /** - / Payment provider to use to fund the purchase. - */ + /** Payment provider to use to fund the purchase. */ ProviderName: string; - /** - / Currency to use to fund the purchase. - */ - Currency: string; - /** - / Payment provider transaction identifier. Required for Facebook Payments. - */ + /** Payment provider transaction identifier. Required for Facebook Payments. */ ProviderTransactionId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PayForPurchaseResult - */ export interface PayForPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; - /** - / Status of the transaction. - */ - Status?: string; - /** - / Virtual currency cost of the transaction. - */ - VCAmount?: { [key: string]: number }; - /** - / Real world currency for the transaction. - */ - PurchaseCurrency?: string; - /** - / Real world cost of the transaction. - */ - PurchasePrice: number; - /** - / Local credit applied to the transaction (provider specific). - */ + /** Local credit applied to the transaction (provider specific). */ CreditApplied: number; - /** - / Provider used for the transaction. - */ + /** Purchase order identifier. */ + OrderId?: string; + /** Provider used for the transaction. */ ProviderData?: string; - /** - / URL to the purchase provider page that details the purchase. - */ + /** A token generated by the provider to authenticate the request (provider-specific). */ + ProviderToken?: string; + /** URL to the purchase provider page that details the purchase. */ PurchaseConfirmationPageURL?: string; - /** - / Current virtual currency totals for the user. - */ + /** Currency for the transaction, may be a virtual currency or real money. */ + PurchaseCurrency?: string; + /** Cost of the transaction. */ + PurchasePrice: number; + /** Status of the transaction. */ + Status?: string; + /** Virtual currencies granted by the transaction, if any. */ + VCAmount?: { [key: string]: number }; + /** Current virtual currency balances for the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / A token generated by the provider to authenticate the request (provider-specific). - */ - ProviderToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PaymentOption - */ export interface PaymentOption { - /** - / Specific currency to use to fund the purchase. - */ + /** Specific currency to use to fund the purchase. */ Currency?: string; - /** - / Name of the purchase provider for this option. - */ - ProviderName?: string; - /** - / Amount of the specified currency needed for the purchase. - */ + /** Amount of the specified currency needed for the purchase. */ Price: number; - /** - / Amount of existing credit the user has with the provider. - */ + /** Name of the purchase provider for this option. */ + ProviderName?: string; + /** Amount of existing credit the user has with the provider. */ StoreCredit: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerLeaderboardEntry - */ export interface PlayerLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ + /** Title-specific display name of the user for this leaderboard entry. */ DisplayName?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; - /** - / The profile of the user, if requested. - */ + /** The profile of the user, if requested. */ Profile?: PlayerProfileModel; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerProfileModel - */ export interface PlayerProfileModel { - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Player record created - */ + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Player account origination - */ - Origination?: string; - /** - / Last login + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ LastLogin?: string; - /** - / If the player is currently banned, the UTC Date when the ban expires - */ - BannedUntil?: string; - /** - / List of geographic locations where the player has logged-in - */ + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ Locations?: LocationModel[]; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Image URL of the player's avatar - */ - AvatarUrl?: string; - /** - / List of player's tags for segmentation - */ - Tags?: TagModel[]; - /** - / List of configured end points registered for sending the player push notifications - */ + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ PushNotificationRegistrations?: PushNotificationRegistrationModel[]; - /** - / List of third party accounts linked to this player - */ - LinkedAccounts?: LinkedPlatformAccountModel[]; - /** - / List of advertising campaigns the player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttributionModel[]; - /** - / A sum of player's total purchases across all real-money currencies, converted to US Dollars equivalent - */ - TotalValueToDateInUSD?: number; - /** - / List of player's total lifetime real-money purchases by currency - */ - ValuesToDate?: ValueToDateModel[]; - /** - / List of player's virtual currency balances - */ - VirtualCurrencyBalances?: VirtualCurrencyBalanceModel[]; - /** - / List of leaderboard statistic values for the player - */ + /** List of leaderboard statistic values for the player */ Statistics?: StatisticModel[]; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerProfileViewConstraints - */ - export interface PlayerProfileViewConstraints { - /** - / Whether to show the display name. Defaults to false - */ - ShowDisplayName: boolean; - /** - / Whether to show the created date. Defaults to false - */ - ShowCreated: boolean; - /** - / Whether to show origination. Defaults to false - */ - ShowOrigination: boolean; - /** - / Whether to show the last login time. Defaults to false - */ - ShowLastLogin: boolean; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Whether to show the banned until time. Defaults to false + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ ShowBannedUntil: boolean; - /** - / Whether to show statistics, the most recent version of each stat. Defaults to false - */ - ShowStatistics: boolean; - /** - / Whether to show campaign attributions. Defaults to false - */ + /** Whether to show campaign attributions. Defaults to false */ ShowCampaignAttributions: boolean; - /** - / Whether to show push notification registrations. Defaults to false - */ - ShowPushNotificationRegistrations: boolean; - /** - / Whether to show the linked accounts. Defaults to false - */ + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ ShowLinkedAccounts: boolean; - /** - / Whether to show the total value to date in usd. Defaults to false - */ + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ ShowTotalValueToDateInUsd: boolean; - /** - / Whether to show the values to date. Defaults to false - */ + /** Whether to show the values to date. Defaults to false */ ShowValuesToDate: boolean; - /** - / Whether to show tags. Defaults to false - */ - ShowTags: boolean; - /** - / Whether to show player's locations. Defaults to false - */ - ShowLocations: boolean; - /** - / Whether to show player's avatar URL. Defaults to false - */ - ShowAvatarUrl: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PlayerStatisticVersion - */ export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ + /** time when the statistic version became active */ + ActivationTime: string; + /** time when the statistic version became inactive due to statistic version incrementing */ + DeactivationTime?: string; + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ StatisticName?: string; - /** - / version of the statistic - */ + /** version of the statistic */ Version: number; + + } + + export interface PlayStation5Payload { + /** An optional list of entitlement ids to query against PlayStation :tm: Network */ + Ids?: string[]; + /** Id of the PlayStation :tm: Network service label to consume entitlements from */ + ServiceLabel?: string; + + } + + export interface PSNAccountPlayFabIdPair { /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ - ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - ScheduledDeactivationTime?: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNAccountId?: string; + + } + + export interface PSNOnlinePlayFabIdPair { /** - / time when the statistic version became inactive due to statistic version incrementing + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - DeactivationTime?: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNOnlineId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PurchaseItemRequest - */ export interface PurchaseItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the item to purchase. - */ + /** Catalog version for the items to be purchased (defaults to most recent version. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique identifier of the item to purchase. */ ItemId: string; - /** - / Virtual currency to use to purchase the item. - */ - VirtualCurrency: string; - /** - / Price the client expects to pay for the item (in case a new catalog or store was uploaded, with new prices). - */ + /** Price the client expects to pay for the item (in case a new catalog or store was uploaded, with new prices). */ Price: number; - /** - / Catalog version for the items to be purchased (defaults to most recent version. - */ - CatalogVersion?: string; - /** - / Store to buy this item through. If not set, prices default to those in the catalog. - */ + /** Store to buy this item through. If not set, prices default to those in the catalog. */ StoreId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId?: string; + /** Virtual currency to use to purchase the item. */ + VirtualCurrency: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PurchaseItemResult - */ export interface PurchaseItemResult extends PlayFabModule.IPlayFabResultCommon { + /** Details for the items purchased. */ + Items?: ItemInstance[]; + + } + + export interface PurchaseReceiptFulfillment { + /** Items granted to the player in fulfillment of the validated receipt. */ + FulfilledItems?: ItemInstance[]; /** - / Details for the items purchased. + * Source of the payment price information for the recorded purchase transaction. A value of 'Request' indicates that the + * price specified in the request was used, whereas a value of 'Catalog' indicates that the real-money price of the catalog + * item matching the product ID in the validated receipt transaction and the currency specified in the request (defaulting + * to USD) was used. */ - Items?: ItemInstance[]; + RecordedPriceSource?: string; + /** Currency used to purchase the items (ISO 4217 currency code). */ + RecordedTransactionCurrency?: string; + /** Amount of the stated currency paid for the items, in centesimal units */ + RecordedTransactionTotal?: number; } type PushNotificationPlatform = "ApplePushNotificationService" + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.PushNotificationRegistrationModel - */ export interface PushNotificationRegistrationModel { - /** - / Push notification platform - */ - Platform?: string; - /** - / Notification configured endpoint - */ + /** Notification configured endpoint */ NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RedeemCouponRequest - */ export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generated coupon code to redeem. - */ - CouponCode: string; - /** - / Catalog version of the coupon. If null, uses the default catalog - */ + /** Catalog version of the coupon. If null, uses the default catalog */ CatalogVersion?: string; - /** - / Optional identifier for the Character that should receive the item. If null, item is added to the player - */ + /** Optional identifier for the Character that should receive the item. If null, item is added to the player */ CharacterId?: string; + /** Generated coupon code to redeem. */ + CouponCode: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RedeemCouponResult - */ export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Items granted to the player as a result of redeeming the coupon. - */ + /** Items granted to the player as a result of redeeming the coupon. */ GrantedItems?: ItemInstance[]; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegionInfo - */ - export interface RegionInfo { - /** - / unique identifier for the region - */ - Region?: string; - /** - / name of the region - */ - Name?: string; - /** - / indicates whether the server specified is available in this region - */ - Available: boolean; - /** - / url to ping to get roundtrip time - */ - PingUrl?: string; + export interface RefreshPSNAuthTokenRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code returned by PlayStation :tm: Network OAuth system. */ + AuthCode: string; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterForIOSPushNotificationRequest - */ export interface RegisterForIOSPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique token generated by the Apple Push Notification service when the title registered to receive push notifications. - */ + /** Message to display when confirming push notification. */ + ConfirmationMessage?: string; + /** Unique token generated by the Apple Push Notification service when the title registered to receive push notifications. */ DeviceToken: string; - /** - / If true, send a test push message immediately after sucessful registration. Defaults to false. - */ + /** If true, send a test push message immediately after sucessful registration. Defaults to false. */ SendPushNotificationConfirmation?: boolean; - /** - / Message to display when confirming push notification. - */ - ConfirmationMessage?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterForIOSPushNotificationResult - */ export interface RegisterForIOSPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterPlayFabUserRequest - */ export interface RegisterPlayFabUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId?: string; - /** - / PlayFab username for the account (3-20 characters) - */ - Username?: string; - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** An optional parameter for setting the display name for this title (3-25 characters). */ + DisplayName?: string; + /** User email address attached to their account */ Email?: string; + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Password for the PlayFab account (6-100 characters) */ + Password?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; /** - / Password for the PlayFab account (6-100 characters) - */ - Password: string; - /** - / An optional parameter that specifies whether both the username and email parameters are required. If true, both parameters are required; if false, the user must supply either the username or email parameter. The default value is true. + * An optional parameter that specifies whether both the username and email parameters are required. If true, both + * parameters are required; if false, the user must supply either the username or email parameter. The default value is + * true. */ RequireBothUsernameAndEmail?: boolean; /** - / An optional parameter for setting the display name for this title. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ - DisplayName?: string; + TitleId?: string; + /** PlayFab username for the account (3-20 characters) */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterPlayFabUserResult - */ export interface RegisterPlayFabUserResult extends PlayFabModule.IPlayFabResultCommon { /** - / PlayFab unique identifier for this newly created account. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ + EntityToken?: EntityTokenResponse; + /** PlayFab unique identifier for this newly created account. */ PlayFabId?: string; - /** - / Unique token identifying the user and game at the server level, for the current session. - */ + /** Unique token identifying the user and game at the server level, for the current session. */ SessionTicket?: string; - /** - / PlayFab unique user name. - */ - Username?: string; - /** - / Settings specific to this user. - */ + /** Settings specific to this user. */ SettingsForUser?: UserSettings; + /** PlayFab unique user name. */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RegisterWithWindowsHelloRequest - */ - export interface RegisterWithWindowsHelloRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. - */ - TitleId: string; - /** - / Player's user named used by Windows Hello. - */ - UserName: string; - /** - / PublicKey generated by Windows Hello. - */ - PublicKey: string; - /** - / Device name. - */ - DeviceName?: string; - /** - / Flags for which pieces of info to return for the user. - */ - InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + export interface RemoveContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface RemoveContactEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveFriendRequest - */ export interface RemoveFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account which is to be removed. - */ + /** PlayFab identifier of the friend account which is to be removed. */ FriendPlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveFriendResult - */ export interface RemoveFriendResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveGenericIDRequest - */ export interface RemoveGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generic service identifier to be removed from the player. - */ + /** Generic service identifier to be removed from the player. */ GenericId: GenericServiceId; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveGenericIDResult - */ export interface RemoveGenericIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveSharedGroupMembersRequest - */ export interface RemoveSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RemoveSharedGroupMembersResult - */ export interface RemoveSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ReportPlayerClientRequest - */ + export interface ReportAdActivityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Type of activity, may be Opened, Closed, Start or End */ + Activity: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique ID of the placement to report for */ + PlacementId: string; + /** Unique ID of the reward the player was offered */ + RewardId: string; + + } + + export interface ReportAdActivityResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface ReportPlayerClientRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab identifier of the reported player. - */ - ReporteeId: string; - /** - / Optional additional comment by reporting player. - */ + /** Optional additional comment by reporting player. */ Comment?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier of the reported player. */ + ReporteeId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ReportPlayerClientResult - */ export interface ReportPlayerClientResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Indicates whether this action completed successfully. - */ - Updated: boolean; - /** - / The number of remaining reports which may be filed today. - */ + /** The number of remaining reports which may be filed today. */ SubmissionsRemaining: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RestoreIOSPurchasesRequest - */ export interface RestoreIOSPurchasesRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. - */ + /** Catalog version of the restored items. If null, defaults to primary catalog. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ ReceiptData: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.RestoreIOSPurchasesResult - */ export interface RestoreIOSPurchasesResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; + + } + + export interface RewardAdActivityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Placement unique ID */ + PlacementId: string; + /** Reward unique ID */ + RewardId: string; + + } + + export interface RewardAdActivityResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayStream Event ID that was generated by this reward (all subsequent events are associated with this event identifier) */ + AdActivityEventId?: string; + /** Debug results from the grants */ + DebugResults?: string[]; + /** Id of the placement the reward was for */ + PlacementId?: string; + /** Name of the placement the reward was for */ + PlacementName?: string; + /** If placement has viewing limits indicates how many views are left */ + PlacementViewsRemaining?: number; + /** If placement has viewing limits indicates when they will next reset */ + PlacementViewsResetMinutes?: number; + /** Reward results */ + RewardResults?: AdRewardResults; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ScriptExecutionError - */ export interface ScriptExecutionError { /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ Error?: string; - /** - / Details about the error - */ + /** Details about the error */ Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ + /** Point during the execution of the script at which the error occurred, if any */ StackTrace?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SendAccountRecoveryEmailRequest - */ export interface SendAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / User email address attached to their account - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ Email: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a + * title has been selected. */ TitleId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SendAccountRecoveryEmailResult - */ export interface SendAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SetFriendTagsRequest - */ export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account to which the tag(s) should be applied. - */ + /** PlayFab identifier of the friend account to which the tag(s) should be applied. */ FriendPlayFabId: string; - /** - / Array of tags to set on the friend account. - */ + /** Array of tags to set on the friend account. */ Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SetFriendTagsResult - */ export interface SetFriendTagsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SharedGroupDataRecord - */ - export interface SharedGroupDataRecord { - /** - / Data stored for the specified group data key. - */ - Value?: string; - /** - / Unique PlayFab identifier of the user to last update this value. - */ - LastUpdatedBy?: string; - /** - / Timestamp for when this data was last updated. - */ - LastUpdated: string; - /** - / Indicates whether this data can be read by all users (public) or only members of the group (private). - */ - Permission?: string; - - } - - type SourceType = "Admin" - | "BackEnd" - | "GameClient" - | "GameServer" - | "Partner"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartGameRequest - */ - export interface StartGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / version information for the build of the game server which is to be started - */ - BuildVersion: string; - /** - / the region to associate this server with for match filtering - */ - Region: string; - /** - / the title-defined game mode this server is to be running (defaults to 0 if there is only one mode) - */ - GameMode: string; - /** - / player statistic for others to use in finding this game. May be null for no stat-based matching - */ - StatisticName?: string; - /** - / character to use for stats based matching. Leave null to use account stats - */ - CharacterId?: string; - /** - / custom command line argument when starting game server process - */ - CustomCommandLineData?: string; + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Base64 encoded body that is encrypted with the Title's public RSA key. */ + EncryptedRequest?: string; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartGameResult - */ - export interface StartGameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / unique identifier for the lobby of the server started - */ - LobbyID?: string; - /** - / server IP address - */ - ServerHostname?: string; - /** - / port on the server to be used for communication - */ - ServerPort?: number; - /** - / unique identifier for the server - */ - Ticket?: string; - /** - / timestamp for when the server should expire, if applicable - */ - Expires?: string; - /** - / password required to log into the server - */ - Password?: string; + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartPurchaseRequest - */ + export interface SharedGroupDataRecord { + /** Timestamp for when this data was last updated. */ + LastUpdated: string; + /** Unique PlayFab identifier of the user to last update this value. */ + LastUpdatedBy?: string; + /** Indicates whether this data can be read by all users (public) or only members of the group (private). */ + Permission?: string; + /** Data stored for the specified group data key. */ + Value?: string; + + } + + type SourceType = "Admin" + + | "BackEnd" + | "GameClient" + | "GameServer" + | "Partner" + | "Custom" + | "API"; + export interface StartPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version for the items to be purchased. Defaults to most recent catalog. - */ + /** Catalog version for the items to be purchased. Defaults to most recent catalog. */ CatalogVersion?: string; - /** - / Store through which to purchase items. If not set, prices will be pulled from the catalog itself. - */ - StoreId?: string; - /** - / Array of items to purchase. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to purchase. */ Items: ItemPurchaseRequest[]; + /** Store through which to purchase items. If not set, prices will be pulled from the catalog itself. */ + StoreId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StartPurchaseResult - */ export interface StartPurchaseResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Purchase order identifier. - */ - OrderId?: string; - /** - / Cart items to be purchased. - */ + /** Cart items to be purchased. */ Contents?: CartItem[]; - /** - / Available methods by which the user can pay. - */ + /** Purchase order identifier. */ + OrderId?: string; + /** Available methods by which the user can pay. */ PaymentOptions?: PaymentOption[]; - /** - / Current virtual currency totals for the user. - */ + /** Current virtual currency totals for the user. */ VirtualCurrencyBalances?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticModel - */ export interface StatisticModel { - /** - / Statistic name - */ + /** Statistic name */ Name?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - Version: number; - /** - / Statistic value - */ + /** Statistic value */ Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticNameVersion - */ export interface StatisticNameVersion { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; - /** - / the version of the statistic to be returned - */ + /** the version of the statistic to be returned */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticUpdate - */ export interface StatisticUpdate { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; + /** statistic value for the player */ + Value: number; /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when setting the statistic value for the first time. + * for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when + * setting the statistic value for the first time. */ Version?: number; - /** - / statistic value for the player - */ - Value: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StatisticValue - */ export interface StatisticValue { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName?: string; - /** - / statistic value for the player - */ + /** statistic value for the player */ Value: number; - /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded - */ + /** for updates to an existing statistic value for a player, the version of the statistic when it was loaded */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SteamPlayFabIdPair - */ + 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 Steam identifier for a user. - */ - SteamStringId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. - */ + /** 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. */ + SteamStringId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StoreItem - */ export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the catalog + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ ItemId: string; - /** - / Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) - */ - VirtualCurrencyPrices?: { [key: string]: number }; - /** - / Override prices for this item for specific currencies - */ + /** Override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / Store specific custom data. The data only exists as part of this store; it is not transferred to item instances - */ - CustomData?: any; - /** - / Intended display position for this item. Note that 0 is the first position - */ - DisplayPosition?: number; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.StoreMarketingModel - */ export interface StoreMarketingModel { - /** - / Display name of a store as it will appear to users. - */ - DisplayName?: string; - /** - / Tagline for a store. - */ + /** Tagline for a store. */ Description?: string; - /** - / Custom data about a store. - */ + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ Metadata?: any; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.SubtractUserVirtualCurrencyRequest - */ + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Name of the virtual currency which is to be decremented. - */ - VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the virtual currency which is to be decremented. */ + VirtualCurrency: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TagModel - */ export interface TagModel { - /** - / Full value of the tag, including namespace - */ + /** Full value of the tag, including namespace */ TagValue?: string; } type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TitleNewsItem - */ export interface TitleNewsItem { - /** - / Date and time when the news items was posted. - */ - Timestamp: string; - /** - / Unique identifier of news item. - */ + /** News item text. */ + Body?: string; + /** Unique identifier of news item. */ NewsId?: string; - /** - / Title of the news item. - */ + /** Date and time when the news item was posted. */ + Timestamp: string; + /** Title of the news item. */ Title?: string; - /** - / News item text. - */ - Body?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TradeInfo - */ export interface TradeInfo { - /** - / Describes the current state of this trade. - */ - Status?: string; - /** - / The identifier for this trade. - */ - TradeId?: string; - /** - / The PlayFabId for the offering player. - */ - OfferingPlayerId?: string; - /** - / The itemInstance Ids that are being offered. - */ - OfferedInventoryInstanceIds?: string[]; - /** - / The catalogItem Ids of the item instances being offered. - */ - OfferedCatalogItemIds?: string[]; - /** - / The catalogItem Ids requested in exchange. - */ - RequestedCatalogItemIds?: string[]; - /** - / An optional list of players allowed to complete this trade. If null, anybody can complete the trade. - */ - AllowedPlayerIds?: string[]; - /** - / The PlayFab ID of the player who accepted the trade. If null, no one has accepted the trade. - */ - AcceptedPlayerId?: string; - /** - / Item instances from the accepting player that are used to fulfill the trade. If null, no one has accepted the trade. - */ + /** Item instances from the accepting player that are used to fulfill the trade. If null, no one has accepted the trade. */ AcceptedInventoryInstanceIds?: string[]; - /** - / The UTC time when this trade was created. - */ - OpenedAt?: string; - /** - / If set, The UTC time when this trade was fulfilled. - */ - FilledAt?: string; - /** - / If set, The UTC time when this trade was canceled. - */ + /** The PlayFab ID of the player who accepted the trade. If null, no one has accepted the trade. */ + AcceptedPlayerId?: string; + /** An optional list of players allowed to complete this trade. If null, anybody can complete the trade. */ + AllowedPlayerIds?: string[]; + /** If set, The UTC time when this trade was canceled. */ CancelledAt?: string; - /** - / If set, The UTC time when this trade was made invalid. - */ + /** If set, The UTC time when this trade was fulfilled. */ + FilledAt?: string; + /** If set, The UTC time when this trade was made invalid. */ InvalidatedAt?: string; + /** The catalogItem Ids of the item instances being offered. */ + OfferedCatalogItemIds?: string[]; + /** The itemInstance Ids that are being offered. */ + OfferedInventoryInstanceIds?: string[]; + /** The PlayFabId for the offering player. */ + OfferingPlayerId?: string; + /** The UTC time when this trade was created. */ + OpenedAt?: string; + /** The catalogItem Ids requested in exchange. */ + RequestedCatalogItemIds?: string[]; + /** Describes the current state of this trade. */ + Status?: string; + /** The identifier for this trade. */ + TradeId?: string; } type TradeStatus = "Invalid" + | "Opening" | "Open" | "Accepting" @@ -5324,6 +5028,7 @@ declare module PlayFabClientModels { | "Cancelled"; type TransactionStatus = "CreateCart" + | "Init" | "Approved" | "Succeeded" @@ -5344,600 +5049,595 @@ declare module PlayFabClientModels { | "Other" | "Failed"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.TwitchPlayFabIdPair - */ + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + export interface TwitchPlayFabIdPair { - /** - / Unique Twitch identifier for a user. - */ - TwitchId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. */ PlayFabId?: string; + /** Unique Twitch identifier for a user. */ + TwitchId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkAndroidDeviceIDRequest - */ export interface UnlinkAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Android device identifier for the user's device. If not specified, the most recently signed in Android Device ID will be used. + * Android device identifier for the user's device. If not specified, the most recently signed in Android Device ID will be + * used. */ AndroidDeviceId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkAndroidDeviceIDResult - */ export interface UnlinkAndroidDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkCustomIDRequest - */ + export interface UnlinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + export interface UnlinkCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Custom unique identifier for the user, generated by the title. If not specified, the most recently signed in Custom ID will be used. + * Custom unique identifier for the user, generated by the title. If not specified, the most recently signed in Custom ID + * will be used. */ CustomId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkCustomIDResult - */ export interface UnlinkCustomIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkFacebookAccountRequest - */ export interface UnlinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkFacebookAccountResult - */ export interface UnlinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGameCenterAccountRequest - */ + export interface UnlinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games identifier for the user. If not specified, the most recently signed in ID will be used. */ + FacebookInstantGamesId?: string; + + } + + export interface UnlinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGameCenterAccountResult - */ export interface UnlinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGoogleAccountRequest - */ export interface UnlinkGoogleAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkGoogleAccountResult - */ export interface UnlinkGoogleAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkIOSDeviceIDRequest - */ + export interface UnlinkGooglePlayGamesServicesAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkGooglePlayGamesServicesAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Vendor-specific iOS identifier for the user's device. If not specified, the most recently signed in iOS Device ID will be used. + * Vendor-specific iOS identifier for the user's device. If not specified, the most recently signed in iOS Device ID will + * be used. */ DeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkIOSDeviceIDResult - */ export interface UnlinkIOSDeviceIDResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkKongregateAccountRequest - */ export interface UnlinkKongregateAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkKongregateAccountResult - */ export interface UnlinkKongregateAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkSteamAccountRequest - */ + export interface UnlinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Nintendo Switch Device identifier for the user. If not specified, the most recently signed in device ID will be used. */ + NintendoSwitchDeviceId?: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkOpenIdConnectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A name that identifies which configured OpenID Connect provider relationship to use. Maximum 100 characters. */ + ConnectionId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UnlinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + export interface UnlinkSteamAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkSteamAccountResult - */ export interface UnlinkSteamAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkTwitchAccountRequest - */ export interface UnlinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Valid token issued by Twitch. Used to specify which twitch account to unlink from the profile. By default it uses the + * one that is present on the profile. + */ + AccessToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkTwitchAccountResult - */ export interface UnlinkTwitchAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkWindowsHelloAccountRequest - */ - export interface UnlinkWindowsHelloAccountRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / SHA256 hash of the PublicKey generated by Windows Hello. - */ - PublicKeyHint: string; + export interface UnlinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlinkWindowsHelloAccountResponse - */ - export interface UnlinkWindowsHelloAccountResponse extends PlayFabModule.IPlayFabResultCommon { + export interface UnlinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerInstanceRequest - */ export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog + * associated with the item instance. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / ItemInstanceId of the container to unlock. - */ + /** ItemInstanceId of the container to unlock. */ ContainerItemInstanceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this parameter is required. + * ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this + * parameter is required. */ KeyItemInstanceId?: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog associated with the item instance. - */ - CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerItemRequest - */ export interface UnlockContainerItemRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Catalog ItemId of the container type to unlock. - */ - ContainerItemId: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary + * catalog. */ CatalogVersion?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Catalog ItemId of the container type to unlock. */ + ContainerItemId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UnlockContainerItemResult - */ export interface UnlockContainerItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the container unlocked. - */ + /** Items granted to the player as a result of unlocking the container. */ + GrantedItems?: ItemInstance[]; + /** Unique instance identifier of the container unlocked. */ UnlockedItemInstanceId?: string; - /** - / Unique instance identifier of the key used to unlock the container, if applicable. - */ + /** Unique instance identifier of the key used to unlock the container, if applicable. */ UnlockedWithItemInstanceId?: string; - /** - / Items granted to the player as a result of unlocking the container. - */ - GrantedItems?: ItemInstance[]; - /** - / Virtual currency granted to the player as a result of unlocking the container. - */ + /** Virtual currency granted to the player as a result of unlocking the container. */ VirtualCurrency?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateAvatarUrlRequest - */ export interface UpdateAvatarUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / URL of the avatar image. If empty, it removes the existing avatar URL. - */ + /** URL of the avatar image. If empty, it removes the existing avatar URL. */ ImageUrl: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterDataRequest - */ export interface UpdateCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterDataResult - */ export interface UpdateCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterStatisticsRequest - */ export interface UpdateCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Statistics to be updated with the provided values. - */ + /** Statistics to be updated with the provided values, in the Key(string), Value(int) pattern. */ CharacterStatistics?: { [key: string]: number }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateCharacterStatisticsResult - */ export interface UpdateCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdatePlayerStatisticsRequest - */ - export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. + */ + ExpectedPropertiesVersion?: number; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; + + } + + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { /** - / Statistics to be updated with the provided values + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ + PropertiesVersion: number; + + } + + export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Statistics to be updated with the provided values */ Statistics: StatisticUpdate[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdatePlayerStatisticsResult - */ export interface UpdatePlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateSharedGroupDataRequest - */ + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; + + } + export interface UpdateSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys in this request. - */ + /** Permission to be applied to all user data keys in this request. */ Permission?: string; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateSharedGroupDataResult - */ export interface UpdateSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. This is used for requests by one player for information about another player; those requests will only return Public keys. + * Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. This is used + * for requests by one player for information about another player; those requests will only return Public keys. */ Permission?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserTitleDisplayNameRequest - */ export interface UpdateUserTitleDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / New title display name for the user - must be between 3 and 25 characters. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** New title display name for the user - must be between 3 and 25 characters. */ DisplayName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UpdateUserTitleDisplayNameResult - */ export interface UpdateUserTitleDisplayNameResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Current title display name for the user (this will be the original display name if the rename attempt failed). - */ + /** Current title display name for the user (this will be the original display name if the rename attempt failed). */ DisplayName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserCustomIdInfo - */ + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; + + } + export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -5954,371 +5654,295 @@ declare module PlayFabClientModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserSettings - */ export interface UserSettings { - /** - / Boolean for whether this player is eligible for ad tracking. - */ + /** Boolean for whether this player is eligible for gathering device info. */ + GatherDeviceInfo: boolean; + /** Boolean for whether this player should report OnFocus play-time tracking. */ + GatherFocusInfo: boolean; + /** Boolean for whether this player is eligible for ad tracking. */ NeedsAttribution: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateAmazonReceiptRequest - */ export interface ValidateAmazonReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / ReceiptId returned by the Amazon App Store in-app purchase API - */ - ReceiptId: string; - /** - / AmazonId of the user making the purchase as returned by the Amazon App Store in-app purchase API - */ - UserId: string; - /** - / Catalog version to use when granting receipt item. If null, defaults to primary catalog. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ CatalogVersion?: string; - /** - / Currency used for the purchase. - */ - CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** Currency used to pay for the purchase (ISO 4217 currency code). */ + CurrencyCode?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** ReceiptId returned by the Amazon App Store in-app purchase API */ + ReceiptId: string; + /** AmazonId of the user making the purchase as returned by the Amazon App Store in-app purchase API */ + UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateAmazonReceiptResult - */ export interface ValidateAmazonReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateGooglePlayPurchaseRequest - */ export interface ValidateGooglePlayPurchaseRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Original JSON string returned by the Google Play IAB API. - */ - ReceiptJson: string; - /** - / Signature returned by the Google Play IAB API. - */ - Signature: string; - /** - / Currency used for the purchase. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ + CatalogVersion?: string; + /** Currency used to pay for the purchase (ISO 4217 currency code). */ CurrencyCode?: string; - /** - / Amount of the stated currency paid for the object. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice?: number; + /** Original JSON string returned by the Google Play IAB API. */ + ReceiptJson: string; + /** Signature returned by the Google Play IAB API. */ + Signature: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateGooglePlayPurchaseResult - */ export interface ValidateGooglePlayPurchaseResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateIOSReceiptRequest - */ export interface ValidateIOSReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. - */ - ReceiptData: string; - /** - / Currency used for the purchase. - */ - CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ + CatalogVersion?: string; + /** Currency used to pay for the purchase (ISO 4217 currency code). */ + CurrencyCode?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ + JwsReceiptData?: string; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** Base64 encoded receipt data, passed back by the App Store as a result of a successful purchase. */ + ReceiptData?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateIOSReceiptResult - */ export interface ValidateIOSReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateWindowsReceiptRequest - */ export interface ValidateWindowsReceiptRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / XML Receipt returned by the Windows App Store in-app purchase API - */ - Receipt: string; - /** - / Catalog version to use when granting receipt item. If null, defaults to primary catalog. - */ + /** Catalog version of the fulfilled items. If null, defaults to the primary catalog. */ CatalogVersion?: string; - /** - / Currency used for the purchase. - */ + /** Currency used to pay for the purchase (ISO 4217 currency code). */ CurrencyCode: string; - /** - / Amount of the stated currency paid for the object. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Amount of the stated currency paid, in centesimal units. */ PurchasePrice: number; + /** XML Receipt returned by the Windows App Store in-app purchase API */ + Receipt: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValidateWindowsReceiptResult - */ export interface ValidateWindowsReceiptResult extends PlayFabModule.IPlayFabResultCommon { + /** Fulfilled inventory items and recorded purchases in fulfillment of the validated receipt transactions. */ + Fulfillments?: PurchaseReceiptFulfillment[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.ValueToDateModel - */ export interface ValueToDateModel { - /** - / ISO 4217 code of the currency used in the purchases - */ + /** ISO 4217 code of the currency used in the purchases */ Currency?: string; /** - / Total value of the purchases in a whole number of 1/100 monetary units. For example 999 indicates nine dollars and ninety-nine cents when Currency is 'USD') + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ TotalValue: number; /** - / Total value of the purchases in a string representation of decimal monetary units (e.g. '9.99' indicates nine dollars and ninety-nine cents when Currency is 'USD')) + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ TotalValueAsDecimal?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.VirtualCurrencyBalanceModel - */ - export interface VirtualCurrencyBalanceModel { - /** - / Name of the virtual currency - */ - Currency?: string; - /** - / Balance of the virtual currency - */ - TotalValue: number; + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteClientCharacterEventRequest - */ export interface WriteClientCharacterEventRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteClientPlayerEventRequest - */ export interface WriteClientPlayerEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteEventResponse - */ export interface WriteEventResponse extends PlayFabModule.IPlayFabResultCommon { /** - / The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to any particular format. + * The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to + * any particular format. */ EventId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Client.Models/PlayFab.Client.Models.WriteTitleEventRequest - */ export interface WriteTitleEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; + + } + + export interface XboxLiveAccountPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Xbox Live identifier. */ + PlayFabId?: string; + /** Unique Xbox Live identifier for a user. */ + XboxLiveAccountId?: string; } diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabCloudScriptApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabCloudScriptApi.d.ts new file mode 100644 index 00000000..38ac8fc3 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabCloudScriptApi.d.ts @@ -0,0 +1,919 @@ +/// + +declare module PlayFabCloudScriptModule { + export interface IPlayFabCloudScript { + ForgetAllCredentials(): void; + + /** + * Cloud Script is one of PlayFab's most versatile features. It allows client code to request execution of any kind of + * custom server-side functionality you can implement, and it can be used in conjunction with virtually anything. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/executeentitycloudscript + */ + ExecuteEntityCloudScript(request: PlayFabCloudScriptModels.ExecuteEntityCloudScriptRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cloud Script is one of PlayFab's most versatile features. It allows client code to request execution of any kind of + * custom server-side functionality you can implement, and it can be used in conjunction with virtually anything. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/executefunction + */ + ExecuteFunction(request: PlayFabCloudScriptModels.ExecuteFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets registered Azure Functions for a given title id and function name. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/getfunction + */ + GetFunction(request: PlayFabCloudScriptModels.GetFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Event Hub triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listeventhubfunctions + */ + ListEventHubFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listfunctions + */ + ListFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered HTTP triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listhttpfunctions + */ + ListHttpFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all currently registered Queue triggered Azure Functions for a given title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/listqueuedfunctions + */ + ListQueuedFunctions(request: PlayFabCloudScriptModels.ListFunctionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate an entity PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforentitytriggeredaction + */ + PostFunctionResultForEntityTriggeredAction(request: PlayFabCloudScriptModels.PostFunctionResultForEntityTriggeredActionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate an entity PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforfunctionexecution + */ + PostFunctionResultForFunctionExecution(request: PlayFabCloudScriptModels.PostFunctionResultForFunctionExecutionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate a player PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforplayertriggeredaction + */ + PostFunctionResultForPlayerTriggeredAction(request: PlayFabCloudScriptModels.PostFunctionResultForPlayerTriggeredActionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Generate a PlayStream event for the provided function result. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/postfunctionresultforscheduledtask + */ + PostFunctionResultForScheduledTask(request: PlayFabCloudScriptModels.PostFunctionResultForScheduledTaskRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers an event hub triggered Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registereventhubfunction + */ + RegisterEventHubFunction(request: PlayFabCloudScriptModels.RegisterEventHubFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers an HTTP triggered Azure function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registerhttpfunction + */ + RegisterHttpFunction(request: PlayFabCloudScriptModels.RegisterHttpFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Registers a queue triggered Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/registerqueuedfunction + */ + RegisterQueuedFunction(request: PlayFabCloudScriptModels.RegisterQueuedFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unregisters an Azure Function with a title. + * https://docs.microsoft.com/rest/api/playfab/cloudscript/server-side-cloud-script/unregisterfunction + */ + UnregisterFunction(request: PlayFabCloudScriptModels.UnregisterFunctionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabCloudScriptModels { + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + type CloudScriptRevisionOption = "Live" + + | "Latest" + | "Specific"; + + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; + + } + + type ContinentCode = "AF" + + | "AN" + | "AS" + | "EU" + | "NA" + | "OC" + | "SA" + | "Unknown"; + + type CountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW" + | "Unknown"; + + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EventHubFunctionModel { + /** The connection string for the event hub. */ + ConnectionString?: string; + /** The name of the event hub that triggers the Azure Function. */ + EventHubName?: string; + /** The name the function was registered under. */ + FunctionName?: string; + + } + + export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; + /** + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. + */ + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; + /** + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. + */ + Logs?: LogStatement[]; + /** + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. + */ + LogsTooLarge?: boolean; + MemoryConsumedBytes: number; + /** + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. + */ + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; + + } + + export interface ExecuteEntityCloudScriptRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the CloudScript function to execute */ + FunctionName: string; + /** Object that is passed in to the function as the first argument */ + FunctionParameter?: any; + /** + * Generate a 'entity_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. + */ + GeneratePlayStreamEvent?: boolean; + /** + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpecificRevision parameter is specified, otherwise it is 'Live'. + */ + RevisionSelection?: string; + /** The specific revision to execute, when RevisionSelection is set to 'Specific' */ + SpecificRevision?: number; + + } + + export interface ExecuteFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the CloudScript function to execute */ + FunctionName: string; + /** Object that is passed in to the function as the FunctionArgument field of the FunctionExecutionContext data structure */ + FunctionParameter?: any; + /** + * Generate a 'entity_executed_cloudscript_function' PlayStream event containing the results of the function execution and + * other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. + */ + GeneratePlayStreamEvent?: boolean; + + } + + export interface ExecuteFunctionResult extends PlayFabModule.IPlayFabResultCommon { + /** Error from the CloudScript Azure Function. */ + Error?: FunctionExecutionError; + /** The amount of time the function took to execute */ + ExecutionTimeMilliseconds: number; + /** The name of the function that executed */ + FunctionName?: string; + /** The object returned from the function, if any */ + FunctionResult?: any; + /** The size in bytes of the object returned from the function, if any */ + FunctionResultSize?: number; + /** Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. */ + FunctionResultTooLarge?: boolean; + + } + + export interface FunctionExecutionError { + /** + * Error code, such as CloudScriptAzureFunctionsExecutionTimeLimitExceeded, CloudScriptAzureFunctionsArgumentSizeExceeded, + * CloudScriptAzureFunctionsReturnSizeExceeded or CloudScriptAzureFunctionsHTTPRequestError + */ + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the function at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface FunctionModel { + /** The address of the function. */ + FunctionAddress?: string; + /** The name the function was registered under. */ + FunctionName?: string; + /** The trigger type for the function. */ + TriggerType?: string; + + } + + export interface GetFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface GetFunctionResult extends PlayFabModule.IPlayFabResultCommon { + /** The connection string for the storage account containing the queue for a queue trigger Azure Function. */ + ConnectionString?: string; + /** The URL to be invoked to execute an HTTP triggered function. */ + FunctionUrl?: string; + /** The name of the queue for a queue trigger Azure Function. */ + QueueName?: string; + /** The trigger type for the function. */ + TriggerType?: string; + + } + + export interface HttpFunctionModel { + /** The name the function was registered under. */ + FunctionName?: string; + /** The URL of the function. */ + FunctionUrl?: string; + + } + + export interface LinkedPlatformAccountModel { + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ + Platform?: string; + /** Unique account identifier of the user on the platform */ + PlatformUserId?: string; + /** Linked account username of the user on the platform, if available */ + Username?: string; + + } + + export interface ListEventHubFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of EventHub triggered functions that are currently registered for the title. */ + Functions?: EventHubFunctionModel[]; + + } + + export interface ListFunctionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of functions that are currently registered for the title. */ + Functions?: FunctionModel[]; + + } + + export interface ListHttpFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of HTTP triggered functions that are currently registered for the title. */ + Functions?: HttpFunctionModel[]; + + } + + export interface ListQueuedFunctionsResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of Queue triggered functions that are currently registered for the title. */ + Functions?: QueuedFunctionModel[]; + + } + + export interface LocationModel { + /** City name. */ + City?: string; + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ + Latitude?: number; + /** Longitude coordinate of the geographic location. */ + Longitude?: number; + + } + + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface LogStatement { + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ + Level?: string; + Message?: string; + + } + + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; + /** + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. + */ + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; + + } + + export interface NameIdentifier { + /** Id Identifier, if present */ + Id?: string; + /** Name Identifier, if present */ + Name?: string; + + } + + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; + /** + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. + */ + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; + /** + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. + */ + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; + + } + + export interface PlayStreamEventEnvelopeModel { + /** The ID of the entity the event is about. */ + EntityId?: string; + /** The type of the entity the event is about. */ + EntityType?: string; + /** Data specific to this event. */ + EventData?: string; + /** The name of the event. */ + EventName?: string; + /** The namespace of the event. */ + EventNamespace?: string; + /** Settings for the event. */ + EventSettings?: string; + + } + + export interface PostFunctionResultForEntityTriggeredActionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + + } + + export interface PostFunctionResultForFunctionExecutionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + + } + + export interface PostFunctionResultForPlayerTriggeredActionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The result of the function execution. */ + FunctionResult: ExecuteFunctionResult; + /** The player profile the function was invoked with. */ + PlayerProfile: PlayerProfileModel; + /** The triggering PlayStream event, if any, that caused the function to be invoked. */ + PlayStreamEventEnvelope?: PlayStreamEventEnvelopeModel; + + } + + export interface PostFunctionResultForScheduledTaskRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The result of the function execution */ + FunctionResult: ExecuteFunctionResult; + /** The id of the scheduled task that invoked the function. */ + ScheduledTaskId: NameIdentifier; + + } + + type PushNotificationPlatform = "ApplePushNotificationService" + + | "GoogleCloudMessaging"; + + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ + NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; + + } + + export interface QueuedFunctionModel { + /** The connection string for the Azure Storage Account that hosts the queue. */ + ConnectionString?: string; + /** The name the function was registered under. */ + FunctionName?: string; + /** The name of the queue that triggers the Azure Function. */ + QueueName?: string; + + } + + export interface RegisterEventHubFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A connection string for the namespace of the event hub for the Azure Function. */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the event hub for the Azure Function. */ + EventHubName: string; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface RegisterHttpFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + /** Full URL for Azure Function that implements the function. */ + FunctionUrl: string; + + } + + export interface RegisterQueuedFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A connection string for the storage account that hosts the queue for the Azure Function. */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + /** The name of the queue for the Azure Function. */ + QueueName: string; + + } + + export interface ScriptExecutionError { + /** + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + */ + Error?: string; + /** Details about the error */ + Message?: string; + /** Point during the execution of the script at which the error occurred, if any */ + StackTrace?: string; + + } + + export interface StatisticModel { + /** Statistic name */ + Name?: string; + /** Statistic value */ + Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; + + } + + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; + + } + + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + + export interface TagModel { + /** Full value of the tag, including namespace */ + TagValue?: string; + + } + + type TriggerType = "HTTP" + + | "Queue" + | "EventHub"; + + export interface UnregisterFunctionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the function to register */ + FunctionName: string; + + } + + export interface ValueToDateModel { + /** ISO 4217 code of the currency used in the purchases */ + Currency?: string; + /** + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') + */ + TotalValue: number; + /** + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. + */ + TotalValueAsDecimal?: string; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabDataApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabDataApi.d.ts new file mode 100644 index 00000000..287d8c21 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabDataApi.d.ts @@ -0,0 +1,297 @@ +/// + +declare module PlayFabDataModule { + export interface IPlayFabData { + ForgetAllCredentials(): void; + + /** + * Abort pending file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/abortfileuploads + */ + AbortFileUploads(request: PlayFabDataModels.AbortFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete files on an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/deletefiles + */ + DeleteFiles(request: PlayFabDataModels.DeleteFilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Finalize file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/finalizefileuploads + */ + FinalizeFileUploads(request: PlayFabDataModels.FinalizeFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves file metadata from an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/getfiles + */ + GetFiles(request: PlayFabDataModels.GetFilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves objects from an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/object/getobjects + */ + GetObjects(request: PlayFabDataModels.GetObjectsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Initiates file uploads to an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/file/initiatefileuploads + */ + InitiateFileUploads(request: PlayFabDataModels.InitiateFileUploadsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets objects on an entity's profile. + * https://docs.microsoft.com/rest/api/playfab/data/object/setobjects + */ + SetObjects(request: PlayFabDataModels.SetObjectsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabDataModels { + export interface AbortFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to have their pending uploads aborted. */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * InitiateFileUploads API or other APIs, you can ensure that the file upload abort operation is performed only if the + * profile has not been updated since you last loaded that version. If the profile for the same entity has been updated, + * the operation will fail with an EntityProfileVersionMismatch error. The conflicting update can be caused by any + * operation that modifies the entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface AbortFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface DeleteFilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be deleted. */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetFiles API or other APIs, you can ensure that the file deletion is performed only if the profile has not been updated + * since you last loaded that version. If the profile for the same entity has been updated, the operation will fail with an + * EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the entity + * profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface DeleteFilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface FinalizeFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be finalized. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + FileNames: string[]; + /** + * Field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * InitiateFileUploads API, you can ensure that the file upload finalization is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion: number; + + } + + export interface FinalizeFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Collection of metadata for the entity's files */ + Metadata?: { [key: string]: GetFileMetadata }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface GetFileMetadata { + /** Checksum value for the file, can be used to check if the file on the server has changed. */ + Checksum?: string; + /** Download URL where the file can be retrieved */ + DownloadUrl?: string; + /** Name of the file */ + FileName?: string; + /** Last UTC time the file was modified */ + LastModified: string; + /** Storage service's reported byte count */ + Size: number; + + } + + export interface GetFilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + + } + + export interface GetFilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Collection of metadata for the entity's files */ + Metadata?: { [key: string]: GetFileMetadata }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface GetObjectsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** + * Determines whether the object will be returned as an escaped JSON string or as a un-escaped JSON object. Default is JSON + * object. + */ + EscapeObject?: boolean; + + } + + export interface GetObjectsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** Requested objects that the calling entity has access to */ + Objects?: { [key: string]: ObjectResult }; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + + } + + export interface InitiateFileUploadMetadata { + /** Name of the file. */ + FileName?: string; + /** Location the data should be sent to via an HTTP PUT operation. */ + UploadUrl?: string; + + } + + export interface InitiateFileUploadsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** Names of the files to be set. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + FileNames: string[]; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetFiles API or other APIs, you can ensure that the file upload initiation is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ProfileVersion?: number; + + } + + export interface InitiateFileUploadsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** Collection of file names and upload urls */ + UploadDetails?: InitiateFileUploadMetadata[]; + + } + + export interface ObjectResult { + /** Un-escaped JSON object, if EscapeObject false or default. */ + DataObject?: any; + /** Escaped string JSON body of the object, if EscapeObject is true. */ + EscapedDataObject?: string; + /** Name of the object. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.' */ + ObjectName?: string; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface SetObject { + /** + * Body of the object to be saved. If empty and DeleteObject is true object will be deleted if it exists, or no operation + * will occur if it does not exist. Only one of Object or EscapedDataObject fields may be used. + */ + DataObject?: any; + /** Flag to indicate that this object should be deleted. Both DataObject and EscapedDataObject must not be set as well. */ + DeleteObject?: boolean; + /** + * Body of the object to be saved as an escaped JSON string. If empty and DeleteObject is true object will be deleted if it + * exists, or no operation will occur if it does not exist. Only one of DataObject or EscapedDataObject fields may be used. + */ + EscapedDataObject?: string; + /** Name of object. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + ObjectName: string; + + } + + export interface SetObjectInfo { + /** Name of the object */ + ObjectName?: string; + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + export interface SetObjectsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetObjects API or other APIs, you can ensure that the object update is performed only if the profile has not been + * updated since you last loaded that version. If the profile for the same entity has been updated, the operation will fail + * with an EntityProfileVersionMismatch error. The conflicting update can be caused by any operation that modifies the + * entity profile, including SetObjects, FinalizeFileUploads, and UpdateStatistics. + */ + ExpectedProfileVersion?: number; + /** Collection of objects to set on the profile. */ + Objects: SetObject[]; + + } + + export interface SetObjectsResponse extends PlayFabModule.IPlayFabResultCommon { + /** New version of the entity profile. */ + ProfileVersion: number; + /** New version of the entity profile. */ + SetResults?: SetObjectInfo[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabEconomyApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabEconomyApi.d.ts new file mode 100644 index 00000000..733020c5 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabEconomyApi.d.ts @@ -0,0 +1,2494 @@ +/// + +declare module PlayFabEconomyModule { + export interface IPlayFabEconomy { + ForgetAllCredentials(): void; + + /** + * Add inventory items. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is uncapped. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/addinventoryitems + */ + AddInventoryItems(request: PlayFabEconomyModels.AddInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new item in the working catalog using provided metadata. Note: SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/createdraftitem + */ + CreateDraftItem(request: PlayFabEconomyModels.CreateDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates one or more upload URLs which can be used by the client to upload raw file data. Content URls and uploaded + * content will be garbage collected after 24 hours if not attached to a draft or published item. Detailed pricing info + * around uploading content can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/pricing/meters/catalog-meters + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/createuploadurls + */ + CreateUploadUrls(request: PlayFabEconomyModels.CreateUploadUrlsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes all reviews, helpfulness votes, and ratings submitted by the entity specified. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/deleteentityitemreviews + */ + DeleteEntityItemReviews(request: PlayFabEconomyModels.DeleteEntityItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete an Inventory Collection. More information about Inventory Collections can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/inventory/collections + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/deleteinventorycollection + */ + DeleteInventoryCollection(request: PlayFabEconomyModels.DeleteInventoryCollectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete inventory items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/deleteinventoryitems + */ + DeleteInventoryItems(request: PlayFabEconomyModels.DeleteInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an item from working catalog and all published versions from the public catalog. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/deleteitem + */ + DeleteItem(request: PlayFabEconomyModels.DeleteItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Execute a list of Inventory Operations. A maximum list of 50 operations can be performed by a single request. There is + * also a limit to 300 items that can be modified/added in a single request. For example, adding a bundle with 50 items + * counts as 50 items modified. All operations must be done within a single inventory collection. This API has a reduced + * RPS compared to an individual inventory operation with Player Entities limited to 60 requests in 90 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/executeinventoryoperations + */ + ExecuteInventoryOperations(request: PlayFabEconomyModels.ExecuteInventoryOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Transfer a list of inventory items. A maximum list of 50 operations can be performed by a single request. When the + * response code is 202, one or more operations did not complete within the timeframe of the request. You can identify the + * pending operations by looking for OperationStatus = 'InProgress'. You can check on the operation status at anytime + * within 1 day of the request by passing the TransactionToken to the GetInventoryOperationStatus API. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/executetransferoperations + */ + ExecuteTransferOperations(request: PlayFabEconomyModels.ExecuteTransferOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the configuration for the catalog. Only Title Entities can call this API. There is a limit of 100 requests in 10 + * seconds for this API. More information about the Catalog Config can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/settings + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getcatalogconfig + */ + GetCatalogConfig(request: PlayFabEconomyModels.GetCatalogConfigRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves an item from the working catalog. This item represents the current working state of the item. GetDraftItem + * does not work off a cache of the Catalog and should be used when trying to get recent item updates. However, please note + * that item references data is cached and may take a few moments for changes to propagate. Note: SAS tokens provided are + * valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getdraftitem + */ + GetDraftItem(request: PlayFabEconomyModels.GetDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a paginated list of the items from the draft catalog. Up to 50 IDs can be retrieved in a single request. + * GetDraftItems does not work off a cache of the Catalog and should be used when trying to get recent item updates. Note: + * SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getdraftitems + */ + GetDraftItems(request: PlayFabEconomyModels.GetDraftItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a paginated list of the items from the draft catalog created by the Entity. Up to 50 items can be returned at + * once. You can use continuation tokens to paginate through results that return greater than the limit. + * GetEntityDraftItems does not work off a cache of the Catalog and should be used when trying to get recent item updates. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getentitydraftitems + */ + GetEntityDraftItems(request: PlayFabEconomyModels.GetEntityDraftItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the submitted review for the specified item by the authenticated entity. Individual ratings and reviews data update + * in near real time with delays within a few seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getentityitemreview + */ + GetEntityItemReview(request: PlayFabEconomyModels.GetEntityItemReviewRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get Inventory Collection Ids. Up to 50 Ids can be returned at once (or 250 with response compression enabled). You can + * use continuation tokens to paginate through results that return greater than the limit. It can take a few seconds for + * new collection Ids to show up. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventorycollectionids + */ + GetInventoryCollectionIds(request: PlayFabEconomyModels.GetInventoryCollectionIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get current inventory items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventoryitems + */ + GetInventoryItems(request: PlayFabEconomyModels.GetInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the status of an inventory operation using an OperationToken. You can check on the operation status at anytime + * within 1 day of the request by passing the TransactionToken to the this API. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/getinventoryoperationstatus + */ + GetInventoryOperationStatus(request: PlayFabEconomyModels.GetInventoryOperationStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves an item from the public catalog. GetItem does not work off a cache of the Catalog and should be used when + * trying to get recent item updates. However, please note that item references data is cached and may take a few moments + * for changes to propagate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitem + */ + GetItem(request: PlayFabEconomyModels.GetItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Search for a given item and return a set of bundles and stores containing the item. Up to 50 items can be returned at + * once. You can use continuation tokens to paginate through results that return greater than the limit. This API is + * intended for tooling/automation scenarios and has a reduced RPS with Player Entities limited to 30 requests in 300 + * seconds and Title Entities limited to 100 requests in 10 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemcontainers + */ + GetItemContainers(request: PlayFabEconomyModels.GetItemContainersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the moderation state for an item, including the concern category and string reason. More information about + * moderation states can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/ugc/moderation + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemmoderationstate + */ + GetItemModerationState(request: PlayFabEconomyModels.GetItemModerationStateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of a publish of an item. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitempublishstatus + */ + GetItemPublishStatus(request: PlayFabEconomyModels.GetItemPublishStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a paginated set of reviews associated with the specified item. Individual ratings and reviews data update in near + * real time with delays within a few seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemreviews + */ + GetItemReviews(request: PlayFabEconomyModels.GetItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a summary of all ratings and reviews associated with the specified item. Summary ratings data is cached with update + * data coming within 15 minutes. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitemreviewsummary + */ + GetItemReviewSummary(request: PlayFabEconomyModels.GetItemReviewSummaryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves items from the public catalog. Up to 50 items can be returned at once. GetItems does not work off a cache of + * the Catalog and should be used when trying to get recent item updates. However, please note that item references data is + * cached and may take a few moments for changes to propagate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/getitems + */ + GetItems(request: PlayFabEconomyModels.GetItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get transaction history for a player. Up to 50 Events can be returned at once (or 250 with response compression + * enabled). You can use continuation tokens to paginate through results that return greater than the limit. Getting + * transaction history has a lower RPS limit than getting a Player's inventory with Player Entities having a limit of 30 + * requests in 300 seconds. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/gettransactionhistory + */ + GetTransactionHistory(request: PlayFabEconomyModels.GetTransactionHistoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Initiates a publish of an item from the working catalog to the public catalog. You can use the GetItemPublishStatus API + * to track the state of the item publish. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/publishdraftitem + */ + PublishDraftItem(request: PlayFabEconomyModels.PublishDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Purchase an item or bundle. Up to 10,000 stacks of items can be added to a single inventory collection. Stack size is + * uncapped. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/purchaseinventoryitems + */ + PurchaseInventoryItems(request: PlayFabEconomyModels.PurchaseInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemappleappstoreinventoryitems + */ + RedeemAppleAppStoreInventoryItems(request: PlayFabEconomyModels.RedeemAppleAppStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemappleappstorewithjwsinventoryitems + */ + RedeemAppleAppStoreWithJwsInventoryItems(request: PlayFabEconomyModels.RedeemAppleAppStoreWithJwsInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemgoogleplayinventoryitems + */ + RedeemGooglePlayInventoryItems(request: PlayFabEconomyModels.RedeemGooglePlayInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items from the Microsoft Store. Supported entitlement types are Developer Manager Consumable and Durable. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemmicrosoftstoreinventoryitems + */ + RedeemMicrosoftStoreInventoryItems(request: PlayFabEconomyModels.RedeemMicrosoftStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemnintendoeshopinventoryitems + */ + RedeemNintendoEShopInventoryItems(request: PlayFabEconomyModels.RedeemNintendoEShopInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemplaystationstoreinventoryitems + */ + RedeemPlayStationStoreInventoryItems(request: PlayFabEconomyModels.RedeemPlayStationStoreInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Redeem items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/redeemsteaminventoryitems + */ + RedeemSteamInventoryItems(request: PlayFabEconomyModels.RedeemSteamInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a report for an item, indicating in what way the item is inappropriate. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reportitem + */ + ReportItem(request: PlayFabEconomyModels.ReportItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a report for a review + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reportitemreview + */ + ReportItemReview(request: PlayFabEconomyModels.ReportItemReviewRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates or updates a review for the specified item. More information around the caching surrounding item ratings and + * reviews can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/ratings#ratings-design-and-caching + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/reviewitem + */ + ReviewItem(request: PlayFabEconomyModels.ReviewItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Executes a search against the public catalog using the provided search parameters and returns a set of paginated + * results. SearchItems uses a cache of the catalog with item updates taking up to a few minutes to propagate. You should + * use the GetItem API for when trying to immediately get recent item updates. More information about the Search API can be + * found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/searchitems + */ + SearchItems(request: PlayFabEconomyModels.SearchItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the moderation state for an item, including the concern category and string reason. More information about + * moderation states can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/ugc/moderation + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/setitemmoderationstate + */ + SetItemModerationState(request: PlayFabEconomyModels.SetItemModerationStateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a vote for a review, indicating whether the review was helpful or unhelpful. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/submititemreviewvote + */ + SubmitItemReviewVote(request: PlayFabEconomyModels.SubmitItemReviewVoteRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subtract inventory items. + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/subtractinventoryitems + */ + SubtractInventoryItems(request: PlayFabEconomyModels.SubtractInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Submit a request to takedown one or more reviews. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/takedownitemreviews + */ + TakedownItemReviews(request: PlayFabEconomyModels.TakedownItemReviewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Transfer inventory items. When transferring across collections, a 202 response indicates that the transfer did not + * complete within the timeframe of the request. You can identify the pending operations by looking for OperationStatus = + * 'InProgress'. You can check on the operation status at anytime within 1 day of the request by passing the + * TransactionToken to the GetInventoryOperationStatus API. More information about item transfer scenarios can be found + * here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/inventory/?tabs=inventory-game-manager#transfer-inventory-items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/transferinventoryitems + */ + TransferInventoryItems(request: PlayFabEconomyModels.TransferInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the configuration for the catalog. Only Title Entities can call this API. There is a limit of 10 requests in 10 + * seconds for this API. More information about the Catalog Config can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/settings + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/updatecatalogconfig + */ + UpdateCatalogConfig(request: PlayFabEconomyModels.UpdateCatalogConfigRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the metadata for an item in the working catalog. Note: SAS tokens provided are valid for 1 hour. + * https://docs.microsoft.com/rest/api/playfab/economy/catalog/updatedraftitem + */ + UpdateDraftItem(request: PlayFabEconomyModels.UpdateDraftItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update inventory items + * https://docs.microsoft.com/rest/api/playfab/economy/inventory/updateinventoryitems + */ + UpdateInventoryItems(request: PlayFabEconomyModels.UpdateInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabEconomyModels { + export interface AddInventoryItemsOperation { + /** The amount to add to the current item amount. */ + Amount?: number; + /** The duration to add to the current item expiration date. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + + } + + export interface AddInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to add for the current item. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The duration to add to the current item expiration date. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + + } + + export interface AddInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface AlternateId { + /** Type of the alternate ID. */ + Type?: string; + /** Value of the alternate ID. */ + Value?: string; + + } + + export interface CatalogAlternateId { + /** Type of the alternate ID. */ + Type?: string; + /** Value of the alternate ID. */ + Value?: string; + + } + + export interface CatalogConfig { + /** A list of player entity keys that will have admin permissions. There is a maximum of 64 entities that can be added. */ + AdminEntities?: EntityKey[]; + /** The set of configuration that only applies to catalog items. */ + Catalog?: CatalogSpecificConfig; + /** A list of deep link formats. Up to 10 can be added. */ + DeepLinkFormats?: DeepLinkFormat[]; + /** + * A list of display properties to index. Up to 5 mappings can be added per Display Property Type. More info on display + * properties can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/content-types-tags-and-properties#displayproperties + */ + DisplayPropertyIndexInfos?: DisplayPropertyIndexInfo[]; + /** The set of configuration that only applies to Files. */ + File?: FileConfig; + /** The set of configuration that only applies to Images. */ + Image?: ImageConfig; + /** Flag defining whether catalog is enabled. */ + IsCatalogEnabled: boolean; + /** + * A list of Platforms that can be applied to catalog items. Each platform can have a maximum character length of 40 and up + * to 128 platforms can be listed. + */ + Platforms?: string[]; + /** The set of configuration that only applies to Ratings and Reviews. */ + Review?: ReviewConfig; + /** A set of player entity keys that are allowed to review content. There is a maximum of 128 entities that can be added. */ + ReviewerEntities?: EntityKey[]; + /** The set of configuration that only applies to user generated contents. */ + UserGeneratedContent?: UserGeneratedContentSpecificConfig; + + } + + export interface CatalogItem { + /** + * The alternate IDs associated with this item. An alternate ID can be set to 'FriendlyId' or any of the supported + * marketplace names. + */ + AlternateIds?: CatalogAlternateId[]; + /** The set of content/files associated with this item. Up to 100 files can be added to an item. */ + Contents?: Content[]; + /** The client-defined type of the item. */ + ContentType?: string; + /** The date and time when this item was created. */ + CreationDate?: string; + /** The ID of the creator of this catalog item. */ + CreatorEntity?: EntityKey; + /** The set of platform specific deep links for this item. */ + DeepLinks?: DeepLink[]; + /** + * The Stack Id that will be used as default for this item in Inventory when an explicit one is not provided. This + * DefaultStackId can be a static stack id or '{guid}', which will generate a unique stack id for the item. If null, + * Inventory's default stack id will be used. + */ + DefaultStackId?: string; + /** + * A dictionary of localized descriptions. Key is language code and localized string is the value. The NEUTRAL locale is + * required. Descriptions have a 10000 character limit per country code. + */ + Description?: { [key: string]: string | null }; + /** + * Game specific properties for display purposes. This is an arbitrary JSON blob. The Display Properties field has a 10000 + * byte limit per item. + */ + DisplayProperties?: any; + /** The user provided version of the item for display purposes. Maximum character length of 50. */ + DisplayVersion?: string; + /** The date of when the item will cease to be available. If not provided then the product will be available indefinitely. */ + EndDate?: string; + /** The current ETag value that can be used for optimistic concurrency in the If-None-Match header. */ + ETag?: string; + /** The unique ID of the item. */ + Id?: string; + /** + * The images associated with this item. Images can be thumbnails or screenshots. Up to 100 images can be added to an item. + * Only .png, .jpg, .gif, and .bmp file types can be uploaded + */ + Images?: Image[]; + /** Indicates if the item is hidden. */ + IsHidden?: boolean; + /** + * The item references associated with this item. For example, the items in a Bundle/Store/Subscription. Every item can + * have up to 50 item references. + */ + ItemReferences?: CatalogItemReference[]; + /** + * A dictionary of localized keywords. Key is language code and localized list of keywords is the value. Keywords have a 50 + * character limit per keyword and up to 32 keywords can be added per country code. + */ + Keywords?: { [key: string]: KeywordSet }; + /** The date and time this item was last updated. */ + LastModifiedDate?: string; + /** The moderation state for this item. */ + Moderation?: ModerationState; + /** The platforms supported by this item. */ + Platforms?: string[]; + /** The prices the item can be purchased for. */ + PriceOptions?: CatalogPriceOptions; + /** Rating summary for this item. */ + Rating?: Rating; + /** The real price the item was purchased for per marketplace. */ + RealMoneyPriceDetails?: RealMoneyPriceDetails; + /** The date of when the item will be available. If not provided then the product will appear immediately. */ + StartDate?: string; + /** Optional details for stores items. */ + StoreDetails?: StoreDetails; + /** The list of tags that are associated with this item. Up to 32 tags can be added to an item. */ + Tags?: string[]; + /** + * A dictionary of localized titles. Key is language code and localized string is the value. The NEUTRAL locale is + * required. Titles have a 512 character limit per country code. + */ + Title?: { [key: string]: string | null }; + /** + * The high-level type of the item. The following item types are supported: bundle, catalogItem, currency, store, ugc, + * subscription. + */ + Type?: string; + + } + + export interface CatalogItemReference { + /** The amount of the catalog item. */ + Amount?: number; + /** The unique ID of the catalog item. */ + Id?: string; + /** The prices the catalog item can be purchased for. */ + PriceOptions?: CatalogPriceOptions; + + } + + export interface CatalogPrice { + /** The amounts of the catalog item price. Each price can have up to 15 item amounts. */ + Amounts?: CatalogPriceAmount[]; + /** The per-unit amount this price can be used to purchase. */ + UnitAmount?: number; + /** The per-unit duration this price can be used to purchase. The maximum duration is 100 years. */ + UnitDurationInSeconds?: number; + + } + + export interface CatalogPriceAmount { + /** The amount of the price. */ + Amount: number; + /** The Item Id of the price. */ + ItemId?: string; + + } + + export interface CatalogPriceAmountOverride { + /** The exact value that should be utilized in the override. */ + FixedValue?: number; + /** The id of the item this override should utilize. */ + ItemId?: string; + /** + * The multiplier that will be applied to the base Catalog value to determine what value should be utilized in the + * override. + */ + Multiplier?: number; + + } + + export interface CatalogPriceOptions { + /** Prices of the catalog item. An item can have up to 15 prices */ + Prices?: CatalogPrice[]; + + } + + export interface CatalogPriceOptionsOverride { + /** The prices utilized in the override. */ + Prices?: CatalogPriceOverride[]; + + } + + export interface CatalogPriceOverride { + /** The currency amounts utilized in the override for a singular price. */ + Amounts?: CatalogPriceAmountOverride[]; + + } + + export interface CatalogSpecificConfig { + /** + * The set of content types that will be used for validation. Each content type can have a maximum character length of 40 + * and up to 128 types can be listed. + */ + ContentTypes?: string[]; + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface CategoryRatingConfig { + /** Name of the category. */ + Name?: string; + + } + + type ConcernCategory = "None" + + | "OffensiveContent" + | "ChildExploitation" + | "MalwareOrVirus" + | "PrivacyConcerns" + | "MisleadingApp" + | "PoorPerformance" + | "ReviewResponse" + | "SpamAdvertising" + | "Profanity"; + + export interface Content { + /** The content unique ID. */ + Id?: string; + /** + * The maximum client version that this content is compatible with. Client Versions can be up to 3 segments separated by + * periods(.) and each segment can have a maximum value of 65535. + */ + MaxClientVersion?: string; + /** + * The minimum client version that this content is compatible with. Client Versions can be up to 3 segments separated by + * periods(.) and each segment can have a maximum value of 65535. + */ + MinClientVersion?: string; + /** + * The list of tags that are associated with this content. Tags must be defined in the Catalog Config before being used in + * content. + */ + Tags?: string[]; + /** The client-defined type of the content. Content Types must be defined in the Catalog Config before being used. */ + Type?: string; + /** The Azure CDN URL for retrieval of the catalog item binary content. */ + Url?: string; + + } + + type CountryCode = "AF" + + | "AX" + | "AL" + | "DZ" + | "AS" + | "AD" + | "AO" + | "AI" + | "AQ" + | "AG" + | "AR" + | "AM" + | "AW" + | "AU" + | "AT" + | "AZ" + | "BS" + | "BH" + | "BD" + | "BB" + | "BY" + | "BE" + | "BZ" + | "BJ" + | "BM" + | "BT" + | "BO" + | "BQ" + | "BA" + | "BW" + | "BV" + | "BR" + | "IO" + | "BN" + | "BG" + | "BF" + | "BI" + | "KH" + | "CM" + | "CA" + | "CV" + | "KY" + | "CF" + | "TD" + | "CL" + | "CN" + | "CX" + | "CC" + | "CO" + | "KM" + | "CG" + | "CD" + | "CK" + | "CR" + | "CI" + | "HR" + | "CU" + | "CW" + | "CY" + | "CZ" + | "DK" + | "DJ" + | "DM" + | "DO" + | "EC" + | "EG" + | "SV" + | "GQ" + | "ER" + | "EE" + | "ET" + | "FK" + | "FO" + | "FJ" + | "FI" + | "FR" + | "GF" + | "PF" + | "TF" + | "GA" + | "GM" + | "GE" + | "DE" + | "GH" + | "GI" + | "GR" + | "GL" + | "GD" + | "GP" + | "GU" + | "GT" + | "GG" + | "GN" + | "GW" + | "GY" + | "HT" + | "HM" + | "VA" + | "HN" + | "HK" + | "HU" + | "IS" + | "IN" + | "ID" + | "IR" + | "IQ" + | "IE" + | "IM" + | "IL" + | "IT" + | "JM" + | "JP" + | "JE" + | "JO" + | "KZ" + | "KE" + | "KI" + | "KP" + | "KR" + | "KW" + | "KG" + | "LA" + | "LV" + | "LB" + | "LS" + | "LR" + | "LY" + | "LI" + | "LT" + | "LU" + | "MO" + | "MK" + | "MG" + | "MW" + | "MY" + | "MV" + | "ML" + | "MT" + | "MH" + | "MQ" + | "MR" + | "MU" + | "YT" + | "MX" + | "FM" + | "MD" + | "MC" + | "MN" + | "ME" + | "MS" + | "MA" + | "MZ" + | "MM" + | "NA" + | "NR" + | "NP" + | "NL" + | "NC" + | "NZ" + | "NI" + | "NE" + | "NG" + | "NU" + | "NF" + | "MP" + | "NO" + | "OM" + | "PK" + | "PW" + | "PS" + | "PA" + | "PG" + | "PY" + | "PE" + | "PH" + | "PN" + | "PL" + | "PT" + | "PR" + | "QA" + | "RE" + | "RO" + | "RU" + | "RW" + | "BL" + | "SH" + | "KN" + | "LC" + | "MF" + | "PM" + | "VC" + | "WS" + | "SM" + | "ST" + | "SA" + | "SN" + | "RS" + | "SC" + | "SL" + | "SG" + | "SX" + | "SK" + | "SI" + | "SB" + | "SO" + | "ZA" + | "GS" + | "SS" + | "ES" + | "LK" + | "SD" + | "SR" + | "SJ" + | "SZ" + | "SE" + | "CH" + | "SY" + | "TW" + | "TJ" + | "TZ" + | "TH" + | "TL" + | "TG" + | "TK" + | "TO" + | "TT" + | "TN" + | "TR" + | "TM" + | "TC" + | "TV" + | "UG" + | "UA" + | "AE" + | "GB" + | "US" + | "UM" + | "UY" + | "UZ" + | "VU" + | "VE" + | "VN" + | "VG" + | "VI" + | "WF" + | "EH" + | "YE" + | "ZM" + | "ZW" + | "Unknown"; + + export interface CreateDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Metadata describing the new catalog item to be created. */ + Item?: CatalogItem; + /** Whether the item should be published immediately. This value is optional, defaults to false. */ + Publish: boolean; + + } + + export interface CreateDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Updated metadata describing the catalog item just created. */ + Item?: CatalogItem; + + } + + export interface CreateUploadUrlsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the files to be uploaded by the client. */ + Files?: UploadInfo[]; + + } + + export interface CreateUploadUrlsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of URLs metadata for the files to be uploaded by the client. */ + UploadUrls?: UploadUrlMetadata[]; + + } + + export interface DeepLink { + /** Target platform for this deep link. */ + Platform?: string; + /** The deep link for this platform. */ + Url?: string; + + } + + export interface DeepLinkFormat { + /** The format of the deep link to return. The format should contain '{id}' to represent where the item ID should be placed. */ + Format?: string; + /** The target platform for the deep link. */ + Platform?: string; + + } + + export interface DeleteEntityItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + + } + + export interface DeleteEntityItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteInventoryCollectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The inventory collection id the request applies to. */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity the request is about. Set to the caller by default. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + + } + + export interface DeleteInventoryCollectionResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteInventoryItemsOperation { + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + + } + + export interface DeleteInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + + } + + export interface DeleteInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** ETags are used for concurrency checking when updating resources. */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface DeleteItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface DeleteItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DisplayPropertyIndexInfo { + /** The property name in the 'DisplayProperties' property to be indexed. */ + Name?: string; + /** The type of the property to be indexed. */ + Type?: string; + + } + + type DisplayPropertyType = "None" + + | "QueryDateTime" + | "QueryDouble" + | "QueryString" + | "SearchString"; + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface ExecuteInventoryOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** + * The operations to run transactionally. The operations will be executed in-order sequentially and will succeed or fail as + * a batch. Up to 50 operations can be added. + */ + Operations?: InventoryOperation[]; + + } + + export interface ExecuteInventoryOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of the transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface ExecuteTransferOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The inventory collection id the request is transferring from. (Default="default") */ + GivingCollectionId?: string; + /** The entity the request is transferring from. Set to the caller by default. */ + GivingEntity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** + * The transfer operations to run transactionally. The operations will be executed in-order sequentially and will succeed + * or fail as a batch. Up to 50 operations can be added. + */ + Operations?: TransferInventoryItemsOperation[]; + /** The inventory collection id the request is transferring to. (Default="default") */ + ReceivingCollectionId?: string; + /** The entity the request is transferring to. Set to the caller by default. */ + ReceivingEntity?: EntityKey; + + } + + export interface ExecuteTransferOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources (before transferring from). This value will be empty if + * the operation has not completed yet. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The ids of transactions that occurred as a result of the request's giving action. */ + GivingTransactionIds?: string[]; + /** The Idempotency ID for this request. */ + IdempotencyId?: string; + /** + * The transfer operation status. Possible values are 'InProgress' or 'Completed'. If the operation has completed, the + * response code will be 200. Otherwise, it will be 202. + */ + OperationStatus?: string; + /** + * The token that can be used to get the status of the transfer operation. This will only have a value if OperationStatus + * is 'InProgress'. + */ + OperationToken?: string; + /** + * ETags are used for concurrency checking when updating resources (before transferring to). This value will be empty if + * the operation has not completed yet. + */ + ReceivingETag?: string; + /** The ids of transactions that occurred as a result of the request's receiving action. */ + ReceivingTransactionIds?: string[]; + + } + + export interface FileConfig { + /** + * The set of content types that will be used for validation. Each content type can have a maximum character length of 40 + * and up to 128 types can be listed. + */ + ContentTypes?: string[]; + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface FilterOptions { + /** + * The OData filter utilized. Mutually exclusive with 'IncludeAllItems'. More info about Filter Complexity limits can be + * found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search#limits + */ + Filter?: string; + /** The flag that overrides the filter and allows for returning all catalog items. Mutually exclusive with 'Filter'. */ + IncludeAllItems?: boolean; + + } + + export interface GetCatalogConfigRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetCatalogConfigResponse extends PlayFabModule.IPlayFabResultCommon { + /** The catalog configuration. */ + Config?: CatalogConfig; + + } + + export interface GetDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Full metadata of the catalog item requested. */ + Item?: CatalogItem; + + } + + export interface GetDraftItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** List of item alternate IDs. */ + AlternateIds?: CatalogAlternateId[]; + /** + * An opaque token used to retrieve the next page of items created by the caller, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count?: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** List of Item Ids. */ + Ids?: string[]; + + } + + export interface GetDraftItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** A set of items created by the entity. */ + Items?: CatalogItem[]; + + } + + export interface GetEntityDraftItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * An opaque token used to retrieve the next page of items created by the caller, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * OData Filter to refine the items returned. CatalogItem properties 'type' can be used in the filter. For example: "type + * eq 'ugc'" + */ + Filter?: string; + + } + + export interface GetEntityDraftItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** A set of items created by the entity. */ + Items?: CatalogItem[]; + + } + + export interface GetEntityItemReviewRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetEntityItemReviewResponse extends PlayFabModule.IPlayFabResultCommon { + /** The review the entity submitted for the requested item. */ + Review?: Review; + + } + + export interface GetInventoryCollectionIdsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An opaque token used to retrieve the next page of collection ids, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. The default value is 10 */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity the request is about. Set to the caller by default. */ + Entity?: EntityKey; + + } + + export interface GetInventoryCollectionIdsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested inventory collection ids. */ + CollectionIds?: string[]; + /** An opaque token used to retrieve the next page of collection ids, if any are available. */ + ContinuationToken?: string; + + } + + export interface GetInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** + * An opaque token used to retrieve the next page of items in the inventory, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Maximum page size is 50. The default value is 10 */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * OData Filter to refine the items returned. InventoryItem properties 'type', 'id', and 'stackId' can be used in the + * filter. For example: "type eq 'currency'" + */ + Filter?: string; + + } + + export interface GetInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The requested inventory items. */ + Items?: InventoryItem[]; + + } + + export interface GetInventoryOperationStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The token to get the status of the inventory operation. */ + OperationToken?: string; + + } + + export interface GetInventoryOperationStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** The inventory operation status. */ + OperationStatus?: string; + + } + + export interface GetItemContainersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** + * An opaque token used to retrieve the next page of items in the inventory, if any are available. Should be null on + * initial request. + */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemContainersResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of Bundles and Stores containing the requested items. */ + Containers?: CatalogItem[]; + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + + } + + export interface GetItemModerationStateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemModerationStateResponse extends PlayFabModule.IPlayFabResultCommon { + /** The current moderation state for the requested item. */ + State?: ModerationState; + + } + + export interface GetItemPublishStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemPublishStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** High level status of the published item. */ + Result?: string; + /** Descriptive message about the current status of the publish. */ + StatusMessage?: string; + + } + + export interface GetItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** The item result. */ + Item?: CatalogItem; + + } + + export interface GetItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + /** + * An OData orderBy used to order the results of the query. Possible values are Helpfulness, Rating, and Submitted (For + * example: "Submitted desc") + */ + OrderBy?: string; + + } + + export interface GetItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** The paginated set of results. */ + Reviews?: Review[]; + + } + + export interface GetItemReviewSummaryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface GetItemReviewSummaryResponse extends PlayFabModule.IPlayFabResultCommon { + /** The least favorable review for this item. */ + LeastFavorableReview?: Review; + /** The most favorable review for this item. */ + MostFavorableReview?: Review; + /** The summary of ratings associated with this item. */ + Rating?: Rating; + /** The total number of reviews associated with this item. */ + ReviewsCount: number; + + } + + export interface GetItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** List of item alternate IDs. */ + AlternateIds?: CatalogAlternateId[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** List of Item Ids. */ + Ids?: string[]; + + } + + export interface GetItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Metadata of set of items. */ + Items?: CatalogItem[]; + + } + + export interface GetTransactionHistoryRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** An opaque token used to retrieve the next page of items, if any are available. Should be null on initial request. */ + ContinuationToken?: string; + /** + * Number of items to retrieve. This value is optional. The default value is 10. The maximum value is 50, or 250 if + * response compression is enabled. + */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * An OData filter used to refine the TransactionHistory. Transaction properties 'timestamp', 'transactionid', 'apiname' + * and 'operationtype' can be used in the filter. Properties 'transactionid', 'apiname', and 'operationtype' cannot be used + * together in a single request. The 'timestamp' property can be combined with 'apiname' or 'operationtype' in a single + * request. For example: "timestamp ge 2023-06-20T23:30Z" or "transactionid eq '10'" or "(timestamp ge 2023-06-20T23:30Z) + * and (apiname eq 'AddInventoryItems')". By default, a 6 month timespan from the current date is used. + */ + Filter?: string; + /** + * An OData orderby to order TransactionHistory results. The only supported values are 'timestamp asc' or 'timestamp desc'. + * Default orderby is 'timestamp asc' + */ + OrderBy?: string; + + } + + export interface GetTransactionHistoryResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. Should be null on initial request. */ + ContinuationToken?: string; + /** The requested inventory transactions. */ + Transactions?: Transaction[]; + + } + + export interface GooglePlayProductPurchase { + /** The Product ID (SKU) of the InApp product purchased from the Google Play store. */ + ProductId?: string; + /** The token provided to the player's device when the product was purchased */ + Token?: string; + + } + + type HelpfulnessVote = "None" + + | "UnHelpful" + | "Helpful"; + + export interface Image { + /** The image unique ID. */ + Id?: string; + /** + * The client-defined tag associated with this image. Tags must be defined in the Catalog Config before being used in + * images + */ + Tag?: string; + /** Images can be defined as either a "thumbnail" or "screenshot". There can only be one "thumbnail" image per item. */ + Type?: string; + /** The URL for retrieval of the image. */ + Url?: string; + + } + + export interface ImageConfig { + /** + * The set of tags that will be used for validation. Each tag can have a maximum character length of 32 and up to 1024 tags + * can be listed. + */ + Tags?: string[]; + + } + + export interface InitialValues { + /** Game specific properties for display purposes. The Display Properties field has a 1000 byte limit. */ + DisplayProperties?: any; + + } + + export interface InventoryItem { + /** The amount of the item. */ + Amount?: number; + /** + * Game specific properties for display purposes. This is an arbitrary JSON blob. The Display Properties field has a 1000 + * byte limit. + */ + DisplayProperties?: any; + /** Only used for subscriptions. The date of when the item will expire in UTC. */ + ExpirationDate?: string; + /** The id of the item. This should correspond to the item id in the catalog. */ + Id?: string; + /** The stack id of the item. */ + StackId?: string; + /** Only used for subscriptions. The date of when the item started in UTC. */ + StartDate?: string; + /** The type of the item. This should correspond to the item type in the catalog. */ + Type?: string; + + } + + export interface InventoryItemReference { + /** The inventory item alternate id the request applies to. */ + AlternateId?: AlternateId; + /** The inventory item id the request applies to. */ + Id?: string; + /** The inventory stack id the request should redeem to. (Default="default") */ + StackId?: string; + + } + + export interface InventoryOperation { + /** The add operation. */ + Add?: AddInventoryItemsOperation; + /** The delete operation. */ + Delete?: DeleteInventoryItemsOperation; + /** The purchase operation. */ + Purchase?: PurchaseInventoryItemsOperation; + /** The subtract operation. */ + Subtract?: SubtractInventoryItemsOperation; + /** The transfer operation. */ + Transfer?: TransferInventoryItemsOperation; + /** The update operation. */ + Update?: UpdateInventoryItemsOperation; + + } + + export interface KeywordSet { + /** A list of localized keywords. */ + Values?: string[]; + + } + + export interface ModerationState { + /** The date and time this moderation state was last updated. */ + LastModifiedDate?: string; + /** The current stated reason for the associated item being moderated. */ + Reason?: string; + /** The current moderation status for the associated item. */ + Status?: string; + + } + + type ModerationStatus = "Unknown" + + | "AwaitingModeration" + | "Approved" + | "Rejected"; + + export interface Permissions { + /** + * The list of ids of Segments that the a player can be in to purchase from the store. When a value is provided, the player + * must be in at least one of the segments listed for the purchase to be allowed. + */ + SegmentIds?: string[]; + + } + + export interface PublishDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETag of the catalog item to published from the working catalog to the public catalog. Used for optimistic concurrency. + * If the provided ETag does not match the ETag in the current working catalog, the request will be rejected. If not + * provided, the current version of the document in the working catalog will be published. + */ + ETag?: string; + /** The unique ID of the item. */ + Id?: string; + + } + + export interface PublishDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + type PublishResult = "Unknown" + + | "Pending" + | "Succeeded" + | "Failed" + | "Canceled"; + + export interface PurchaseInventoryItemsOperation { + /** The amount to purchase. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the operation should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The duration to purchase. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + /** + * The per-item price the item is expected to be purchased at. This must match a value configured in the Catalog or + * specified Store. + */ + PriceAmounts?: PurchasePriceAmount[]; + /** The id of the Store to purchase the item from. */ + StoreId?: string; + + } + + export interface PurchaseInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to purchase. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. + * (Default=false) + */ + DeleteEmptyStacks: boolean; + /** The duration to purchase. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + /** + * The per-item price the item is expected to be purchased at. This must match a value configured in the Catalog or + * specified Store. + */ + PriceAmounts?: PurchasePriceAmount[]; + /** The id of the Store to purchase the item from. */ + StoreId?: string; + + } + + export interface PurchaseInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface PurchaseOverride { + + } + + export interface PurchaseOverridesInfo { + + } + + export interface PurchasePriceAmount { + /** The amount of the inventory item to use in the purchase . */ + Amount: number; + /** The inventory item id to use in the purchase . */ + ItemId?: string; + /** The inventory stack id the to use in the purchase. Set to "default" by default */ + StackId?: string; + + } + + export interface Rating { + /** The average rating for this item. */ + Average?: number; + /** The total count of 1 star ratings for this item. */ + Count1Star?: number; + /** The total count of 2 star ratings for this item. */ + Count2Star?: number; + /** The total count of 3 star ratings for this item. */ + Count3Star?: number; + /** The total count of 4 star ratings for this item. */ + Count4Star?: number; + /** The total count of 5 star ratings for this item. */ + Count5Star?: number; + /** The total count of ratings for this item. */ + TotalCount?: number; + + } + + export interface RealMoneyPriceDetails { + /** The 'AppleAppStore' price amount per CurrencyCode. 'USD' supported only. */ + AppleAppStorePrices?: { [key: string]: number }; + /** The 'GooglePlay' price amount per CurrencyCode. 'USD' supported only. */ + GooglePlayPrices?: { [key: string]: number }; + /** The 'MicrosoftStore' price amount per CurrencyCode. 'USD' supported only. */ + MicrosoftStorePrices?: { [key: string]: number }; + /** The 'NintendoEShop' price amount per CurrencyCode. 'USD' supported only. */ + NintendoEShopPrices?: { [key: string]: number }; + /** The 'PlayStationStore' price amount per CurrencyCode. 'USD' supported only. */ + PlayStationStorePrices?: { [key: string]: number }; + /** The 'Steam' price amount per CurrencyCode. 'USD' supported only. */ + SteamPrices?: { [key: string]: number }; + + } + + export interface RedeemAppleAppStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The receipt provided by the Apple marketplace upon successful purchase. */ + Receipt?: string; + + } + + export interface RedeemAppleAppStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemAppleAppStoreWithJwsInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The JWS representation of a transaction. */ + JWSTransactions: string[]; + + } + + export interface RedeemAppleAppStoreWithJwsInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemGooglePlayInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The list of purchases to redeem */ + Purchases?: GooglePlayProductPurchase[]; + + } + + export interface RedeemGooglePlayInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemMicrosoftStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * Xbox Token used for delegated business partner authentication. Token provided by the Xbox Live SDK method + * GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). + */ + XboxToken?: string; + + } + + export interface RedeemMicrosoftStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemNintendoEShopInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The Nintendo provided token authorizing redemption */ + NintendoServiceAccountIdToken?: string; + + } + + export interface RedeemNintendoEShopInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemPlayStationStoreInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code returned by PlayStation :tm: Network OAuth system. */ + AuthorizationCode?: string; + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code. */ + RedirectUri?: string; + /** Optional Service Label to pass into the request. */ + ServiceLabel?: string; + + } + + export interface RedeemPlayStationStoreInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedeemSteamInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The id of the entity's collection to perform this action on. (Default="default") */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + + } + + export interface RedeemSteamInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of failed redemptions from the external marketplace. */ + Failed?: RedemptionFailure[]; + /** The list of successful redemptions from the external marketplace. */ + Succeeded?: RedemptionSuccess[]; + /** The Transaction IDs associated with the inventory modifications */ + TransactionIds?: string[]; + + } + + export interface RedemptionFailure { + /** The marketplace failure code. */ + FailureCode?: string; + /** The marketplace error details explaining why the offer failed to redeem. */ + FailureDetails?: string; + /** The Marketplace Alternate ID being redeemed. */ + MarketplaceAlternateId?: string; + /** The transaction id in the external marketplace. */ + MarketplaceTransactionId?: string; + + } + + export interface RedemptionSuccess { + /** The timestamp for when the redeem expired. */ + ExpirationTimestamp?: string; + /** The Marketplace Alternate ID being redeemed. */ + MarketplaceAlternateId?: string; + /** The transaction id in the external marketplace. */ + MarketplaceTransactionId?: string; + /** The timestamp for when the redeem was completed. */ + SuccessTimestamp: string; + + } + + export interface ReportItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** Category of concern for this report. */ + ConcernCategory?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + /** The string reason for this report. */ + Reason?: string; + + } + + export interface ReportItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ReportItemReviewRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID of the item associated with the review. */ + AlternateId?: CatalogAlternateId; + /** The reason this review is being reported. */ + ConcernCategory?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The string ID of the item associated with the review. */ + ItemId?: string; + /** The string reason for this report. */ + Reason?: string; + /** The ID of the review to submit a report for. */ + ReviewId?: string; + + } + + export interface ReportItemReviewResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Review { + /** The star rating associated with each selected category in this review. */ + CategoryRatings?: { [key: string]: number }; + /** The number of negative helpfulness votes for this review. */ + HelpfulNegative: number; + /** The number of positive helpfulness votes for this review. */ + HelpfulPositive: number; + /** Indicates whether the review author has the item installed. */ + IsInstalled: boolean; + /** The ID of the item being reviewed. */ + ItemId?: string; + /** The version of the item being reviewed. */ + ItemVersion?: string; + /** The locale for which this review was submitted in. */ + Locale?: string; + /** Star rating associated with this review. */ + Rating: number; + /** The ID of the author of the review. */ + ReviewerEntity?: EntityKey; + /** The ID of the review. */ + ReviewId?: string; + /** The full text of this review. */ + ReviewText?: string; + /** The date and time this review was last submitted. */ + Submitted: string; + /** The title of this review. */ + Title?: string; + + } + + export interface ReviewConfig { + /** A set of categories that can be applied toward ratings and reviews. */ + CategoryRatings?: CategoryRatingConfig[]; + + } + + export interface ReviewItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The unique ID of the item. */ + Id?: string; + /** The review to submit. */ + Review?: Review; + + } + + export interface ReviewItemResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ReviewTakedown { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The ID of the item associated with the review to take down. */ + ItemId?: string; + /** The ID of the review to take down. */ + ReviewId?: string; + + } + + export interface SearchItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** Number of items to retrieve. This value is optional. Maximum page size is 50. Default value is 10. */ + Count: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * An OData filter used to refine the search query (For example: "type eq 'ugc'"). More info about Filter Complexity limits + * can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/search#limits + */ + Filter?: string; + /** The locale to be returned in the result. */ + Language?: string; + /** An OData orderBy used to order the results of the search query. For example: "rating/average asc" */ + OrderBy?: string; + /** The text to search for. */ + Search?: string; + /** + * An OData select query option used to augment the search results. If not defined, the default search result metadata will + * be returned. + */ + Select?: string; + /** The store to restrict the search request to. */ + Store?: StoreReference; + + } + + export interface SearchItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** An opaque token used to retrieve the next page of items, if any are available. */ + ContinuationToken?: string; + /** The paginated set of results for the search query. */ + Items?: CatalogItem[]; + + } + + export interface SetItemModerationStateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID associated with this item. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique ID of the item. */ + Id?: string; + /** The reason for the moderation state change for the associated item. */ + Reason?: string; + /** The status to set for the associated item. */ + Status?: string; + + } + + export interface SetItemModerationStateResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface StoreDetails { + /** The options for the filter in filter-based stores. These options are mutually exclusive with item references. */ + FilterOptions?: FilterOptions; + /** The permissions that control which players can purchase from the store. */ + Permissions?: Permissions; + /** The global prices utilized in the store. These options are mutually exclusive with price options in item references. */ + PriceOptionsOverride?: CatalogPriceOptionsOverride; + + } + + export interface StoreReference { + /** An alternate ID of the store. */ + AlternateId?: CatalogAlternateId; + /** The unique ID of the store. */ + Id?: string; + + } + + export interface SubmitItemReviewVoteRequest extends PlayFabModule.IPlayFabRequestCommon { + /** An alternate ID of the item associated with the review. */ + AlternateId?: CatalogAlternateId; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** The string ID of the item associated with the review. */ + ItemId?: string; + /** The ID of the review to submit a helpfulness vote for. */ + ReviewId?: string; + /** The helpfulness vote of the review. */ + Vote?: string; + + } + + export interface SubmitItemReviewVoteResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SubtractInventoryItemsOperation { + /** The amount to subtract from the current item amount. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. (Default = + * false). + */ + DeleteEmptyStacks: boolean; + /** The duration to subtract from the current item expiration date. */ + DurationInSeconds?: number; + /** The inventory item the operation applies to. */ + Item?: InventoryItemReference; + + } + + export interface SubtractInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to subtract for the current item. */ + Amount?: number; + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. + * (Default=false) + */ + DeleteEmptyStacks: boolean; + /** The duration to subtract from the current item expiration date. */ + DurationInSeconds?: number; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item the request applies to. */ + Item?: InventoryItemReference; + + } + + export interface SubtractInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface TakedownItemReviewsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The set of reviews to take down. */ + Reviews?: ReviewTakedown[]; + + } + + export interface TakedownItemReviewsResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Transaction { + /** The API call that caused this transaction. */ + ApiName?: string; + /** Additional details about the transaction. Null if it was not a clawback operation. */ + ClawbackDetails?: TransactionClawbackDetails; + /** The custom tags associated with this transactions. */ + CustomTags?: { [key: string]: string | null }; + /** The type of item that the the operation occurred on. */ + ItemType?: string; + /** The operations that occurred. */ + Operations?: TransactionOperation[]; + /** The type of operation that was run. */ + OperationType?: string; + /** Additional details about the transaction. Null if it was not a purchase operation. */ + PurchaseDetails?: TransactionPurchaseDetails; + /** Additional details about the transaction. Null if it was not a redeem operation. */ + RedeemDetails?: TransactionRedeemDetails; + /** The time this transaction occurred in UTC. */ + Timestamp: string; + /** The id of the transaction. This should be treated like an opaque token. */ + TransactionId?: string; + /** Additional details about the transaction. Null if it was not a transfer operation. */ + TransferDetails?: TransactionTransferDetails; + + } + + export interface TransactionClawbackDetails { + /** The id of the clawed back operation. */ + TransactionIdClawedback?: string; + + } + + export interface TransactionOperation { + /** The amount of items in this transaction. */ + Amount?: number; + /** The duration modified in this transaction. */ + DurationInSeconds?: number; + /** The friendly id of the items in this transaction. */ + ItemFriendlyId?: string; + /** The item id of the items in this transaction. */ + ItemId?: string; + /** The type of item that the operation occurred on. */ + ItemType?: string; + /** The stack id of the items in this transaction. */ + StackId?: string; + /** The type of the operation that occurred. */ + Type?: string; + + } + + export interface TransactionPurchaseDetails { + /** The friendly id of the item that was purchased. */ + ItemFriendlyId?: string; + /** The id of the item that was purchased. */ + ItemId?: string; + /** The friendly id of the Store the item was purchased from or null. */ + StoreFriendlyId?: string; + /** The id of the Store the item was purchased from or null. */ + StoreId?: string; + + } + + export interface TransactionRedeemDetails { + /** The marketplace that the offer is being redeemed from. */ + Marketplace?: string; + /** The transaction Id returned from the marketplace. */ + MarketplaceTransactionId?: string; + /** The offer Id of the item being redeemed. */ + OfferId?: string; + + } + + export interface TransactionTransferDetails { + /** The collection id the items were transferred from or null if it was the current collection. */ + GivingCollectionId?: string; + /** The entity the items were transferred from or null if it was the current entity. */ + GivingEntity?: EntityKey; + /** The collection id the items were transferred to or null if it was the current collection. */ + ReceivingCollectionId?: string; + /** The entity the items were transferred to or null if it was the current entity. */ + ReceivingEntity?: EntityKey; + /** The id of the transfer that occurred. */ + TransferId?: string; + + } + + export interface TransferInventoryItemsOperation { + /** The amount to transfer. */ + Amount?: number; + /** + * Indicates whether stacks reduced to an amount of 0 during the operation should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The inventory item the operation is transferring from. */ + GivingItem?: InventoryItemReference; + /** The values to apply to a stack newly created by this operation. */ + NewStackValues?: InitialValues; + /** The inventory item the operation is transferring to. */ + ReceivingItem?: InventoryItemReference; + + } + + export interface TransferInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The amount to transfer . */ + Amount?: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates whether stacks reduced to an amount of 0 during the request should be deleted from the inventory. (Default = + * false) + */ + DeleteEmptyStacks: boolean; + /** The inventory collection id the request is transferring from. (Default="default") */ + GivingCollectionId?: string; + /** The entity the request is transferring from. Set to the caller by default. */ + GivingEntity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources (before transferring from). More information about using + * ETags can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The inventory item the request is transferring from. */ + GivingItem?: InventoryItemReference; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** The values to apply to a stack newly created by this request. */ + NewStackValues?: InitialValues; + /** The inventory collection id the request is transferring to. (Default="default") */ + ReceivingCollectionId?: string; + /** The entity the request is transferring to. Set to the caller by default. */ + ReceivingEntity?: EntityKey; + /** The inventory item the request is transferring to. */ + ReceivingItem?: InventoryItemReference; + + } + + export interface TransferInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources (after transferring from). More information about using + * ETags can be found here: https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + GivingETag?: string; + /** The ids of transactions that occurred as a result of the request's giving action. */ + GivingTransactionIds?: string[]; + /** The idempotency id for the request. */ + IdempotencyId?: string; + /** + * The transfer operation status. Possible values are 'InProgress' or 'Completed'. If the operation has completed, the + * response code will be 200. Otherwise, it will be 202. + */ + OperationStatus?: string; + /** + * The token that can be used to get the status of the transfer operation. This will only have a value if OperationStatus + * is 'InProgress'. + */ + OperationToken?: string; + /** The ids of transactions that occurred as a result of the request's receiving action. */ + ReceivingTransactionIds?: string[]; + + } + + export interface UpdateCatalogConfigRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The updated catalog configuration. */ + Config?: CatalogConfig; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateCatalogConfigResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UpdateDraftItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Updated metadata describing the catalog item to be updated. */ + Item?: CatalogItem; + /** Whether the item should be published immediately. This value is optional, defaults to false. */ + Publish: boolean; + + } + + export interface UpdateDraftItemResponse extends PlayFabModule.IPlayFabResultCommon { + /** Updated metadata describing the catalog item just updated. */ + Item?: CatalogItem; + + } + + export interface UpdateInventoryItemsOperation { + /** The inventory item to update with the specified values. */ + Item?: InventoryItem; + + } + + export interface UpdateInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The id of the entity's collection to perform this action on. (Default="default"). The number of inventory collections is + * unlimited. + */ + CollectionId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity?: EntityKey; + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** + * The Idempotency ID for this request. Idempotency IDs can be used to prevent operation replay in the medium term but will + * be garbage collected eventually. + */ + IdempotencyId?: string; + /** The inventory item to update with the specified values. */ + Item?: InventoryItem; + + } + + export interface UpdateInventoryItemsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * ETags are used for concurrency checking when updating resources. More information about using ETags can be found here: + * https://learn.microsoft.com/en-us/gaming/playfab/features/economy-v2/catalog/etags + */ + ETag?: string; + /** The idempotency id used in the request. */ + IdempotencyId?: string; + /** The ids of transactions that occurred as a result of the request. */ + TransactionIds?: string[]; + + } + + export interface UploadInfo { + /** Name of the file to be uploaded. */ + FileName?: string; + + } + + export interface UploadUrlMetadata { + /** Name of the file for which this upload URL was requested. */ + FileName?: string; + /** Unique ID for the binary content to be uploaded to the target URL. */ + Id?: string; + /** URL for the binary content to be uploaded to. */ + Url?: string; + + } + + export interface UserGeneratedContentSpecificConfig { + /** The set of content types that will be used for validation. */ + ContentTypes?: string[]; + /** The set of tags that will be used for validation. */ + Tags?: string[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabEventsApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabEventsApi.d.ts new file mode 100644 index 00000000..6bcc412f --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabEventsApi.d.ts @@ -0,0 +1,384 @@ +/// + +declare module PlayFabEventsModule { + export interface IPlayFabEvents { + ForgetAllCredentials(): void; + + /** + * Creates a new telemetry key for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/createtelemetrykey + */ + CreateTelemetryKey(request: PlayFabEventsModels.CreateTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a Data Connection from a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/deletedataconnection + */ + DeleteDataConnection(request: PlayFabEventsModels.DeleteDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a telemetry key configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/deletetelemetrykey + */ + DeleteTelemetryKey(request: PlayFabEventsModels.DeleteTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves a single Data Connection associated with a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/getdataconnection + */ + GetDataConnection(request: PlayFabEventsModels.GetDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information about a telemetry key configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/gettelemetrykey + */ + GetTelemetryKey(request: PlayFabEventsModels.GetTelemetryKeyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the list of Data Connections associated with a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/listdataconnections + */ + ListDataConnections(request: PlayFabEventsModels.ListDataConnectionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all telemetry keys configured for the title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/listtelemetrykeys + */ + ListTelemetryKeys(request: PlayFabEventsModels.ListTelemetryKeysRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates or updates a Data Connection on a title. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/setdataconnection + */ + SetDataConnection(request: PlayFabEventsModels.SetDataConnectionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets a Data Connection for the title to either the active or deactivated state. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/setdataconnectionactive + */ + SetDataConnectionActive(request: PlayFabEventsModels.SetDataConnectionActiveRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets a telemetry key to the active or deactivated state. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/settelemetrykeyactive + */ + SetTelemetryKeyActive(request: PlayFabEventsModels.SetTelemetryKeyActiveRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Write batches of entity based events to PlayStream. The namespace of the Event must be 'custom' or start with 'custom.'. + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/writeevents + */ + WriteEvents(request: PlayFabEventsModels.WriteEventsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Write batches of entity based events to as Telemetry events (bypass PlayStream). The namespace must be 'custom' or start + * with 'custom.' + * https://docs.microsoft.com/rest/api/playfab/events/playstream-events/writetelemetryevents + */ + WriteTelemetryEvents(request: PlayFabEventsModels.WriteEventsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabEventsModels { + export interface CreateTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the new key. Telemetry key names must be unique within the scope of the title. */ + KeyName: string; + + } + + export interface CreateTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details about the newly created telemetry key. */ + NewKeyDetails?: TelemetryKeyDetails; + + } + + export interface DataConnectionAzureBlobSettings { + /** Name of the storage account. */ + AccountName?: string; + /** Name of the container. */ + ContainerName?: string; + /** Azure Entra Tenant Id. */ + TenantId?: string; + + } + + export interface DataConnectionAzureDataExplorerSettings { + /** The URI of the ADX cluster. */ + ClusterUri?: string; + /** The database to write to. */ + Database?: string; + /** The table to write to. */ + Table?: string; + + } + + export interface DataConnectionDetails { + /** Settings of the data connection. */ + ConnectionSettings: DataConnectionSettings; + /** Whether or not the connection is currently active. */ + IsActive: boolean; + /** The name of the data connection. */ + Name: string; + /** Current status of the data connection, if any. */ + Status?: DataConnectionStatusDetails; + /** The type of data connection. */ + Type: string; + + } + + type DataConnectionErrorState = "OK" + + | "Error"; + + export interface DataConnectionFabricKQLSettings { + /** The URI of the Fabric cluster. */ + ClusterUri?: string; + /** The database to write to. */ + Database?: string; + /** The table to write to. */ + Table?: string; + + } + + export interface DataConnectionSettings { + /** Settings if the type of connection is AzureBlobStorage. */ + AzureBlobSettings?: DataConnectionAzureBlobSettings; + /** Settings if the type of connection is AzureDataExplorer. */ + AzureDataExplorerSettings?: DataConnectionAzureDataExplorerSettings; + /** Settings if the type of connection is FabricKQL. */ + AzureFabricKQLSettings?: DataConnectionFabricKQLSettings; + + } + + export interface DataConnectionStatusDetails { + /** The name of the error affecting the data connection, if any. */ + Error?: string; + /** A description of the error affecting the data connection, if any. This may be empty for some errors. */ + ErrorMessage?: string; + /** The most recent time of the error affecting the data connection, if any. */ + MostRecentErrorTime?: string; + /** Indicates if the connection is in a normal state or error state. */ + State?: string; + + } + + type DataConnectionType = "AzureBlobStorage" + + | "AzureDataExplorer" + | "FabricKQL"; + + export interface DeleteDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to delete. */ + Name: string; + + } + + export interface DeleteDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** Indicates whether or not the connection was deleted as part of the request. */ + WasDeleted: boolean; + + } + + export interface DeleteTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to delete. */ + KeyName: string; + + } + + export interface DeleteTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Indicates whether or not the key was deleted. If false, no key with that name existed. */ + WasKeyDeleted: boolean; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EventContents { + /** + * The optional custom tags associated with the event (e.g. build number, external trace identifiers, etc.). Before an + * event is written, this collection and the base request custom tags will be merged, but not overriden. This enables the + * caller to specify static tags and per event tags. + */ + CustomTags?: { [key: string]: string | null }; + /** Entity associated with the event. If null, the event will apply to the calling entity. */ + Entity?: EntityKey; + /** The namespace in which the event is defined. Allowed namespaces can vary by API. */ + EventNamespace: string; + /** The name of this event. */ + Name: string; + /** + * The original unique identifier associated with this event before it was posted to PlayFab. The value might differ from + * the EventId value, which is assigned when the event is received by the server. + */ + OriginalId?: string; + /** + * The time (in UTC) associated with this event when it occurred. If specified, this value is stored in the + * OriginalTimestamp property of the PlayStream event. + */ + OriginalTimestamp?: string; + /** Arbitrary data associated with the event. Only one of Payload or PayloadJSON is allowed. */ + Payload?: any; + /** + * Arbitrary data associated with the event, represented as a JSON serialized string. Only one of Payload or PayloadJSON is + * allowed. + */ + PayloadJSON?: string; + + } + + export interface GetDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to retrieve. */ + Name: string; + + } + + export interface GetDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The details of the queried Data Connection. */ + DataConnection?: DataConnectionDetails; + + } + + export interface GetTelemetryKeyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to retrieve. */ + KeyName: string; + + } + + export interface GetTelemetryKeyResponse extends PlayFabModule.IPlayFabResultCommon { + /** Details about the requested telemetry key. */ + KeyDetails?: TelemetryKeyDetails; + + } + + export interface ListDataConnectionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListDataConnectionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of existing Data Connections. */ + DataConnections?: DataConnectionDetails[]; + + } + + export interface ListTelemetryKeysRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListTelemetryKeysResponse extends PlayFabModule.IPlayFabResultCommon { + /** The telemetry keys configured for the title. */ + KeyDetails?: TelemetryKeyDetails[]; + + } + + export interface SetDataConnectionActiveRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to set the data connection to active (true) or deactivated (false). */ + Active: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the data connection to update. */ + Name: string; + + } + + export interface SetDataConnectionActiveResponse extends PlayFabModule.IPlayFabResultCommon { + /** The most current details about the data connection that was to be updated. */ + DataConnection?: DataConnectionDetails; + /** + * Indicates whether or not the data connection was updated. If false, the data connection was already in the desired + * state. + */ + WasUpdated: boolean; + + } + + export interface SetDataConnectionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Settings of the data connection. */ + ConnectionSettings: DataConnectionSettings; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Whether or not the connection is currently active. */ + IsActive: boolean; + /** The name of the data connection to update or create. */ + Name: string; + /** The type of data connection. */ + Type: string; + + } + + export interface SetDataConnectionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The details of the Data Connection to be created or updated. */ + DataConnection?: DataConnectionDetails; + + } + + export interface SetTelemetryKeyActiveRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Whether to set the key to active (true) or deactivated (false). */ + Active: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the key to update. */ + KeyName: string; + + } + + export interface SetTelemetryKeyActiveResponse extends PlayFabModule.IPlayFabResultCommon { + /** The most current details about the telemetry key that was to be updated. */ + KeyDetails?: TelemetryKeyDetails; + /** Indicates whether or not the key was updated. If false, the key was already in the desired state. */ + WasKeyUpdated: boolean; + + } + + export interface TelemetryKeyDetails { + /** When the key was created. */ + CreateTime: string; + /** Whether or not the key is currently active. Deactivated keys cannot be used for telemetry ingestion. */ + IsActive: boolean; + /** The key that can be distributed to clients for use during telemetry ingestion. */ + KeyValue?: string; + /** When the key was last updated. */ + LastUpdateTime: string; + /** The name of the key. Telemetry key names are unique within the scope of the title. */ + Name?: string; + + } + + export interface WriteEventsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The collection of events to write. Up to 200 events can be written per request. */ + Events: EventContents[]; + + } + + export interface WriteEventsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The unique identifiers assigned by the server to the events, in the same order as the events in the request. Only + * returned if FlushToPlayStream option is true. + */ + AssignedEventIds?: string[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabExperimentationApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabExperimentationApi.d.ts new file mode 100644 index 00000000..07e0c851 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabExperimentationApi.d.ts @@ -0,0 +1,446 @@ +/// + +declare module PlayFabExperimentationModule { + export interface IPlayFabExperimentation { + ForgetAllCredentials(): void; + + /** + * Creates a new experiment exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/createexclusiongroup + */ + CreateExclusionGroup(request: PlayFabExperimentationModels.CreateExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/createexperiment + */ + CreateExperiment(request: PlayFabExperimentationModels.CreateExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/deleteexclusiongroup + */ + DeleteExclusionGroup(request: PlayFabExperimentationModels.DeleteExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/deleteexperiment + */ + DeleteExperiment(request: PlayFabExperimentationModels.DeleteExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all exclusion groups for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexclusiongroups + */ + GetExclusionGroups(request: PlayFabExperimentationModels.GetExclusionGroupsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all exclusion groups for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexclusiongrouptraffic + */ + GetExclusionGroupTraffic(request: PlayFabExperimentationModels.GetExclusionGroupTrafficRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the details of all experiments for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getexperiments + */ + GetExperiments(request: PlayFabExperimentationModels.GetExperimentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the latest scorecard of the experiment for the title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/getlatestscorecard + */ + GetLatestScorecard(request: PlayFabExperimentationModels.GetLatestScorecardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the treatment assignments for a player for every running experiment in the title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/gettreatmentassignment + */ + GetTreatmentAssignment(request: PlayFabExperimentationModels.GetTreatmentAssignmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Starts an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/startexperiment + */ + StartExperiment(request: PlayFabExperimentationModels.StartExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Stops an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/stopexperiment + */ + StopExperiment(request: PlayFabExperimentationModels.StopExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates an existing exclusion group for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/updateexclusiongroup + */ + UpdateExclusionGroup(request: PlayFabExperimentationModels.UpdateExclusionGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates an existing experiment for a title. + * https://docs.microsoft.com/rest/api/playfab/experimentation/experimentation/updateexperiment + */ + UpdateExperiment(request: PlayFabExperimentationModels.UpdateExperimentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabExperimentationModels { + type AnalysisTaskState = "Waiting" + + | "ReadyForSubmission" + | "SubmittingToPipeline" + | "Running" + | "Completed" + | "Failed" + | "Canceled"; + + export interface CreateExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the exclusion group. */ + Description?: string; + /** Friendly name of the exclusion group. */ + Name: string; + + } + + export interface CreateExclusionGroupResult extends PlayFabModule.IPlayFabResultCommon { + /** Identifier of the exclusion group. */ + ExclusionGroupId?: string; + + } + + export interface CreateExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the experiment. */ + Description?: string; + /** When experiment should end. */ + EndDate?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Friendly name of the experiment. */ + Name: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start. */ + StartDate: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants: Variant[]; + + } + + export interface CreateExperimentResult extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the new experiment. */ + ExperimentId?: string; + + } + + export interface DeleteExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the exclusion group to delete. */ + ExclusionGroupId: string; + + } + + export interface DeleteExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to delete. */ + ExperimentId: string; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface ExclusionGroupTrafficAllocation { + /** Id of the experiment. */ + ExperimentId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + TrafficAllocation: number; + + } + + export interface Experiment { + /** Description of the experiment. */ + Description?: string; + /** When experiment should end/was ended. */ + EndDate?: string; + /** Id of the exclusion group for this experiment. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Id of the experiment. */ + Id?: string; + /** Friendly name of the experiment. */ + Name?: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start/was started. */ + StartDate: string; + /** State experiment is currently in. */ + State?: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants?: Variant[]; + + } + + export interface ExperimentExclusionGroup { + /** Description of the exclusion group. */ + Description?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Friendly name of the exclusion group. */ + Name?: string; + + } + + type ExperimentState = "New" + + | "Started" + | "Stopped" + | "Deleted"; + + type ExperimentType = "Active" + + | "Snapshot"; + + export interface GetExclusionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetExclusionGroupsResult extends PlayFabModule.IPlayFabResultCommon { + /** List of exclusion groups for the title. */ + ExclusionGroups?: ExperimentExclusionGroup[]; + + } + + export interface GetExclusionGroupTrafficRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the exclusion group. */ + ExclusionGroupId: string; + + } + + export interface GetExclusionGroupTrafficResult extends PlayFabModule.IPlayFabResultCommon { + /** List of traffic allocations for the exclusion group. */ + TrafficAllocations?: ExclusionGroupTrafficAllocation[]; + + } + + export interface GetExperimentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetExperimentsResult extends PlayFabModule.IPlayFabResultCommon { + /** List of experiments for the title. */ + Experiments?: Experiment[]; + + } + + export interface GetLatestScorecardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment. */ + ExperimentId?: string; + + } + + export interface GetLatestScorecardResult extends PlayFabModule.IPlayFabResultCommon { + /** Scorecard for the experiment of the title. */ + Scorecard?: Scorecard; + + } + + export interface GetTreatmentAssignmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetTreatmentAssignmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Treatment assignment for the entity. */ + TreatmentAssignment?: TreatmentAssignment; + + } + + export interface MetricData { + /** The upper bound of the confidence interval for the relative delta (Delta.RelativeValue). */ + ConfidenceIntervalEnd: number; + /** The lower bound of the confidence interval for the relative delta (Delta.RelativeValue). */ + ConfidenceIntervalStart: number; + /** The absolute delta between TreatmentStats.Average and ControlStats.Average. */ + DeltaAbsoluteChange: number; + /** The relative delta ratio between TreatmentStats.Average and ControlStats.Average. */ + DeltaRelativeChange: number; + /** The machine name of the metric. */ + InternalName?: string; + /** Indicates if a movement was detected on that metric. */ + Movement?: string; + /** The readable name of the metric. */ + Name?: string; + /** The expectation that a movement is real */ + PMove: number; + /** The p-value resulting from the statistical test run for this metric */ + PValue: number; + /** The threshold for observing sample ratio mismatch. */ + PValueThreshold: number; + /** Indicates if the movement is statistically significant. */ + StatSigLevel?: string; + /** Observed standard deviation value of the metric. */ + StdDev: number; + /** Observed average value of the metric. */ + Value: number; + + } + + export interface Scorecard { + /** Represents the date the scorecard was generated. */ + DateGenerated?: string; + /** Represents the duration of scorecard analysis. */ + Duration?: string; + /** Represents the number of events processed for the generation of this scorecard */ + EventsProcessed: number; + /** Id of the experiment. */ + ExperimentId?: string; + /** Friendly name of the experiment. */ + ExperimentName?: string; + /** Represents the latest compute job status. */ + LatestJobStatus?: string; + /** Represents the presence of a sample ratio mismatch in the scorecard data. */ + SampleRatioMismatch: boolean; + /** Scorecard containing list of analysis. */ + ScorecardDataRows?: ScorecardDataRow[]; + + } + + export interface ScorecardDataRow { + /** Represents whether the variant is control or not. */ + IsControl: boolean; + /** Data of the analysis with the internal name of the metric as the key and an object of metric data as value. */ + MetricDataRows?: { [key: string]: MetricData }; + /** Represents the player count in the variant. */ + PlayerCount: number; + /** Name of the variant of analysis. */ + VariantName?: string; + + } + + export interface StartExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to start. */ + ExperimentId: string; + + } + + export interface StopExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The ID of the experiment to stop. */ + ExperimentId: string; + + } + + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + + export interface UpdateExclusionGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the exclusion group. */ + Description?: string; + /** The ID of the exclusion group to update. */ + ExclusionGroupId: string; + /** Friendly name of the exclusion group. */ + Name: string; + + } + + export interface UpdateExperimentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Description of the experiment. */ + Description?: string; + /** When experiment should end. */ + EndDate?: string; + /** Id of the exclusion group. */ + ExclusionGroupId?: string; + /** Percentage of exclusion group traffic that will see this experiment. */ + ExclusionGroupTrafficAllocation?: number; + /** Type of experiment. */ + ExperimentType?: string; + /** Id of the experiment. */ + Id: string; + /** Friendly name of the experiment. */ + Name: string; + /** Id of the segment to which this experiment applies. Defaults to the 'All Players' segment. */ + SegmentId?: string; + /** When experiment should start. */ + StartDate: string; + /** + * List of title player account IDs that automatically receive treatments in the experiment, but are not included when + * calculating experiment metrics. + */ + TitlePlayerAccountTestIds?: string[]; + /** List of variants for the experiment. */ + Variants: Variant[]; + + } + + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; + + } + + export interface Variant { + /** Description of the variant. */ + Description?: string; + /** Id of the variant. */ + Id?: string; + /** Specifies if variant is control for experiment. */ + IsControl: boolean; + /** Name of the variant. */ + Name: string; + /** Id of the TitleDataOverride to use with this variant. */ + TitleDataOverrideLabel?: string; + /** Percentage of target audience traffic that will see this variant. */ + TrafficPercentage: number; + /** Variables returned by this variant. */ + Variables?: Variable[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabGroupsApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabGroupsApi.d.ts new file mode 100644 index 00000000..2ef182c1 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabGroupsApi.d.ts @@ -0,0 +1,658 @@ +/// + +declare module PlayFabGroupsModule { + export interface IPlayFabGroups { + ForgetAllCredentials(): void; + + /** + * Accepts an outstanding invitation to to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/acceptgroupapplication + */ + AcceptGroupApplication(request: PlayFabGroupsModels.AcceptGroupApplicationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Accepts an invitation to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/acceptgroupinvitation + */ + AcceptGroupInvitation(request: PlayFabGroupsModels.AcceptGroupInvitationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds members to a group or role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/addmembers + */ + AddMembers(request: PlayFabGroupsModels.AddMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Applies to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/applytogroup + */ + ApplyToGroup(request: PlayFabGroupsModels.ApplyToGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Blocks a list of entities from joining a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/blockentity + */ + BlockEntity(request: PlayFabGroupsModels.BlockEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Changes the role membership of a list of entities from one role to another. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/changememberrole + */ + ChangeMemberRole(request: PlayFabGroupsModels.ChangeMemberRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/creategroup + */ + CreateGroup(request: PlayFabGroupsModels.CreateGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a new group role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/createrole + */ + CreateRole(request: PlayFabGroupsModels.CreateGroupRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a group and all roles, invitations, join requests, and blocks associated with it. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/deletegroup + */ + DeleteGroup(request: PlayFabGroupsModels.DeleteGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes an existing role in a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/deleterole + */ + DeleteRole(request: PlayFabGroupsModels.DeleteRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets information about a group and its roles + * https://docs.microsoft.com/rest/api/playfab/groups/groups/getgroup + */ + GetGroup(request: PlayFabGroupsModels.GetGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Invites a player to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/invitetogroup + */ + InviteToGroup(request: PlayFabGroupsModels.InviteToGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Checks to see if an entity is a member of a group or role within the group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/ismember + */ + IsMember(request: PlayFabGroupsModels.IsMemberRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding requests to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupapplications + */ + ListGroupApplications(request: PlayFabGroupsModels.ListGroupApplicationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all entities blocked from joining a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupblocks + */ + ListGroupBlocks(request: PlayFabGroupsModels.ListGroupBlocksRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding invitations for a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupinvitations + */ + ListGroupInvitations(request: PlayFabGroupsModels.ListGroupInvitationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all members for a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listgroupmembers + */ + ListGroupMembers(request: PlayFabGroupsModels.ListGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all groups and roles for an entity + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listmembership + */ + ListMembership(request: PlayFabGroupsModels.ListMembershipRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists all outstanding invitations and group applications for an entity + * https://docs.microsoft.com/rest/api/playfab/groups/groups/listmembershipopportunities + */ + ListMembershipOpportunities(request: PlayFabGroupsModels.ListMembershipOpportunitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an application to join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removegroupapplication + */ + RemoveGroupApplication(request: PlayFabGroupsModels.RemoveGroupApplicationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes an invitation join a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removegroupinvitation + */ + RemoveGroupInvitation(request: PlayFabGroupsModels.RemoveGroupInvitationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes members from a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/removemembers + */ + RemoveMembers(request: PlayFabGroupsModels.RemoveMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unblocks a list of entities from joining a group + * https://docs.microsoft.com/rest/api/playfab/groups/groups/unblockentity + */ + UnblockEntity(request: PlayFabGroupsModels.UnblockEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates non-membership data about a group. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/updategroup + */ + UpdateGroup(request: PlayFabGroupsModels.UpdateGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates metadata about a role. + * https://docs.microsoft.com/rest/api/playfab/groups/groups/updaterole + */ + UpdateRole(request: PlayFabGroupsModels.UpdateGroupRoleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabGroupsModels { + export interface AcceptGroupApplicationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Type of the entity to accept as. Must be the same entity as the claimant or an entity that is a child of the claimant + * entity. + */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface AcceptGroupInvitationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface AddMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** List of entities to add to the group. Only entities of type title_player_account and character may be added to groups. */ + Members: EntityKey[]; + /** + * Optional: The ID of the existing role to add the entities to. If this is not specified, the default member role for the + * group will be used. Role IDs must be between 1 and 64 characters long. + */ + RoleId?: string; + + } + + export interface ApplyToGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional, default true. Automatically accept an outstanding invitation if one exists instead of creating an application */ + AutoAcceptOutstandingInvite?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ApplyToGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** Type of entity that requested membership */ + Entity?: EntityWithLineage; + /** When the application to join will expire and be deleted */ + Expires: string; + /** ID of the group that the entity requesting membership to */ + Group?: EntityKey; + + } + + export interface BlockEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ChangeMemberRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The ID of the role that the entities will become a member of. This must be an existing role. Role IDs must be between 1 + * and 64 characters long. + */ + DestinationRoleId?: string; + /** The identifier of the group */ + Group: EntityKey; + /** + * List of entities to move between roles in the group. All entities in this list must be members of the group and origin + * role. + */ + Members: EntityKey[]; + /** The ID of the role that the entities currently are a member of. Role IDs must be between 1 and 64 characters long. */ + OriginRoleId: string; + + } + + export interface CreateGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the group. This is unique at the title level by default. */ + GroupName: string; + + } + + export interface CreateGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the administrator role for the group. */ + AdminRoleId?: string; + /** The server date and time the group was created. */ + Created: string; + /** The identifier of the group */ + Group: EntityKey; + /** The name of the group. */ + GroupName?: string; + /** The ID of the default member role for the group. */ + MemberRoleId?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles and names that belong to the group. */ + Roles?: { [key: string]: string | null }; + + } + + export interface CreateGroupRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** + * The ID of the role. This must be unique within the group and cannot be changed. Role IDs must be between 1 and 64 + * characters long and are restricted to a-Z, A-Z, 0-9, '(', ')', '_', '-' and '.'. + */ + RoleId: string; + /** + * The name of the role. This must be unique within the group and can be changed later. Role names must be between 1 and + * 100 characters long + */ + RoleName: string; + + } + + export interface CreateGroupRoleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The current version of the group profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** ID for the role */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface DeleteGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of the group or role to remove */ + Group: EntityKey; + + } + + export interface DeleteRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** The ID of the role to delete. Role IDs must be between 1 and 64 characters long. */ + RoleId?: string; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityMemberRole { + /** The list of members in the role */ + Members?: EntityWithLineage[]; + /** The ID of the role. */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface EntityWithLineage { + /** The entity key for the specified entity */ + Key?: EntityKey; + /** Dictionary of entity keys for related entities. Dictionary key is entity type. */ + Lineage?: { [key: string]: EntityKey }; + + } + + export interface GetGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group?: EntityKey; + /** The full name of the group */ + GroupName?: string; + + } + + export interface GetGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** The ID of the administrator role for the group. */ + AdminRoleId?: string; + /** The server date and time the group was created. */ + Created: string; + /** The identifier of the group */ + Group: EntityKey; + /** The name of the group. */ + GroupName?: string; + /** The ID of the default member role for the group. */ + MemberRoleId?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles and names that belong to the group. */ + Roles?: { [key: string]: string | null }; + + } + + export interface GroupApplication { + /** Type of entity that requested membership */ + Entity?: EntityWithLineage; + /** When the application to join will expire and be deleted */ + Expires: string; + /** ID of the group that the entity requesting membership to */ + Group?: EntityKey; + + } + + export interface GroupBlock { + /** The entity that is blocked */ + Entity?: EntityWithLineage; + /** ID of the group that the entity is blocked from */ + Group: EntityKey; + + } + + export interface GroupInvitation { + /** When the invitation will expire and be deleted */ + Expires: string; + /** The group that the entity invited to */ + Group?: EntityKey; + /** The entity that created the invitation */ + InvitedByEntity?: EntityWithLineage; + /** The entity that is invited */ + InvitedEntity?: EntityWithLineage; + /** ID of the role in the group to assign the user to. */ + RoleId?: string; + + } + + export interface GroupRole { + /** ID for the role */ + RoleId?: string; + /** The name of the role */ + RoleName?: string; + + } + + export interface GroupWithRoles { + /** ID for the group */ + Group?: EntityKey; + /** The name of the group */ + GroupName?: string; + /** The current version of the profile, can be used for concurrency control during updates. */ + ProfileVersion: number; + /** The list of roles within the group */ + Roles?: GroupRole[]; + + } + + export interface InviteToGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional, default true. Automatically accept an application if one exists instead of creating an invitation */ + AutoAcceptOutstandingApplication?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + /** + * Optional. ID of an existing a role in the group to assign the user to. The group's default member role is used if this + * is not specified. Role IDs must be between 1 and 64 characters long. + */ + RoleId?: string; + + } + + export interface InviteToGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** When the invitation will expire and be deleted */ + Expires: string; + /** The group that the entity invited to */ + Group?: EntityKey; + /** The entity that created the invitation */ + InvitedByEntity?: EntityWithLineage; + /** The entity that is invited */ + InvitedEntity?: EntityWithLineage; + /** ID of the role in the group to assign the user to. */ + RoleId?: string; + + } + + export interface IsMemberRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + /** + * Optional: ID of the role to check membership of. Defaults to any role (that is, check to see if the entity is a member + * of the group in any capacity) if not specified. + */ + RoleId?: string; + + } + + export interface IsMemberResponse extends PlayFabModule.IPlayFabResultCommon { + /** A value indicating whether or not the entity is a member. */ + IsMember: boolean; + + } + + export interface ListGroupApplicationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupApplicationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of applications to the group. */ + Applications?: GroupApplication[]; + + } + + export interface ListGroupBlocksRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupBlocksResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list blocked entities. */ + BlockedEntities?: GroupBlock[]; + + } + + export interface ListGroupInvitationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface ListGroupInvitationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of group invitations. */ + Invitations?: GroupInvitation[]; + + } + + export interface ListGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** ID of the group to list the members and roles for */ + Group: EntityKey; + + } + + export interface ListGroupMembersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of roles and member entity IDs. */ + Members?: EntityMemberRole[]; + + } + + export interface ListMembershipOpportunitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListMembershipOpportunitiesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of group applications. */ + Applications?: GroupApplication[]; + /** The requested list of group invitations. */ + Invitations?: GroupInvitation[]; + + } + + export interface ListMembershipRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface ListMembershipResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of groups */ + Groups?: GroupWithRoles[]; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface RemoveGroupApplicationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface RemoveGroupInvitationRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface RemoveMembersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The identifier of the group */ + Group: EntityKey; + /** List of entities to remove */ + Members: EntityKey[]; + /** The ID of the role to remove the entities from. */ + RoleId?: string; + + } + + export interface UnblockEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The identifier of the group */ + Group: EntityKey; + + } + + export interface UpdateGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Optional: the ID of an existing role to set as the new administrator role for the group */ + AdminRoleId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetGroup API, you can ensure that the group data update is performed only if the group has not been updated since you + * last loaded that version. If the same group has been updated, the requested update will not occur and the returned + * SetResult value will be None. + */ + ExpectedProfileVersion?: number; + /** The identifier of the group */ + Group: EntityKey; + /** Optional: the new name of the group */ + GroupName?: string; + /** Optional: the ID of an existing role to set as the new member role for the group */ + MemberRoleId?: string; + + } + + export interface UpdateGroupResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** New version of the group data. */ + ProfileVersion: number; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + export interface UpdateGroupRoleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Optional field used for concurrency control. By specifying the previously returned ProfileVersion value from the + * GetGroup API, you can ensure that the group role update is performed only if the group has not been updated since you + * last loaded that version. If the same group has been updated, the requested update will not occur and the returned + * SetResult value will be None. + */ + ExpectedProfileVersion?: number; + /** The identifier of the group */ + Group: EntityKey; + /** ID of the role to update. Role IDs must be between 1 and 64 characters long. */ + RoleId?: string; + /** The new name of the role */ + RoleName: string; + + } + + export interface UpdateGroupRoleResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional reason to explain why the operation was the result that it was. */ + OperationReason?: string; + /** New version of the role data. */ + ProfileVersion: number; + /** Indicates which operation was completed, either Created, Updated, Deleted or None. */ + SetResult?: string; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabInsightsApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabInsightsApi.d.ts new file mode 100644 index 00000000..bdc18b6b --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabInsightsApi.d.ts @@ -0,0 +1,169 @@ +/// + +declare module PlayFabInsightsModule { + export interface IPlayFabInsights { + ForgetAllCredentials(): void; + + /** + * Gets the current values for the Insights performance and data storage retention, list of pending operations, and the + * performance and data storage retention limits. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getdetails + */ + GetDetails(request: PlayFabInsightsModels.InsightsEmptyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the range of allowed values for performance and data storage retention values as well as the submeter details + * for each performance level. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getlimits + */ + GetLimits(request: PlayFabInsightsModels.InsightsEmptyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of a SetPerformance or SetStorageRetention operation. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getoperationstatus + */ + GetOperationStatus(request: PlayFabInsightsModels.InsightsGetOperationStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a list of pending SetPerformance and/or SetStorageRetention operations for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/getpendingoperations + */ + GetPendingOperations(request: PlayFabInsightsModels.InsightsGetPendingOperationsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the Insights performance level value for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/setperformance + */ + SetPerformance(request: PlayFabInsightsModels.InsightsSetPerformanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the Insights data storage retention days value for the title. + * https://docs.microsoft.com/rest/api/playfab/insights/analytics/setstorageretention + */ + SetStorageRetention(request: PlayFabInsightsModels.InsightsSetStorageRetentionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabInsightsModels { + export interface InsightsEmptyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface InsightsGetDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Amount of data (in MB) currently used by Insights. */ + DataUsageMb: number; + /** Details of any error that occurred while retrieving Insights details. */ + ErrorMessage?: string; + /** Allowed range of values for performance level and data storage retention. */ + Limits?: InsightsGetLimitsResponse; + /** List of pending Insights operations for the title. */ + PendingOperations?: InsightsGetOperationStatusResponse[]; + /** Current Insights performance level setting. */ + PerformanceLevel: number; + /** Current Insights data storage retention value in days. */ + RetentionDays: number; + + } + + export interface InsightsGetLimitsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Default Insights performance level. */ + DefaultPerformanceLevel: number; + /** Default Insights data storage retention days. */ + DefaultStorageRetentionDays: number; + /** Maximum allowed data storage retention days. */ + StorageMaxRetentionDays: number; + /** Minimum allowed data storage retention days. */ + StorageMinRetentionDays: number; + /** List of Insights submeter limits for the allowed performance levels. */ + SubMeters?: InsightsPerformanceLevel[]; + + } + + export interface InsightsGetOperationStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the Insights operation. */ + OperationId?: string; + + } + + export interface InsightsGetOperationStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional message related to the operation details. */ + Message?: string; + /** Time the operation was completed. */ + OperationCompletedTime: string; + /** Id of the Insights operation. */ + OperationId?: string; + /** Time the operation status was last updated. */ + OperationLastUpdated: string; + /** Time the operation started. */ + OperationStartedTime: string; + /** The type of operation, SetPerformance or SetStorageRetention. */ + OperationType?: string; + /** The value requested for the operation. */ + OperationValue: number; + /** Current status of the operation. */ + Status?: string; + + } + + export interface InsightsGetPendingOperationsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The type of pending operations requested, or blank for all operation types. */ + OperationType?: string; + + } + + export interface InsightsGetPendingOperationsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of pending Insights operations. */ + PendingOperations?: InsightsGetOperationStatusResponse[]; + + } + + export interface InsightsOperationResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional message related to the operation details. */ + Message?: string; + /** Id of the Insights operation. */ + OperationId?: string; + /** The type of operation, SetPerformance or SetStorageRetention. */ + OperationType?: string; + + } + + export interface InsightsPerformanceLevel { + /** Number of allowed active event exports. This value is always zero. */ + ActiveEventExports: number; + /** Maximum cache size. */ + CacheSizeMB: number; + /** Maximum number of concurrent queries. */ + Concurrency: number; + /** Number of Insights credits consumed per minute. */ + CreditsPerMinute: number; + /** Maximum events per second. */ + EventsPerSecond: number; + /** Performance level. */ + Level: number; + /** Maximum amount of memory allowed per query. */ + MaxMemoryPerQueryMB: number; + /** Amount of compute power allocated for queries and operations. */ + VirtualCpuCores: number; + + } + + export interface InsightsSetPerformanceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Insights performance level to apply to the title. */ + PerformanceLevel: number; + + } + + export interface InsightsSetStorageRetentionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Insights data storage retention value (in days) to apply to the title. */ + RetentionDays: number; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabLocalizationApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabLocalizationApi.d.ts new file mode 100644 index 00000000..f6dc8f6f --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabLocalizationApi.d.ts @@ -0,0 +1,30 @@ +/// + +declare module PlayFabLocalizationModule { + export interface IPlayFabLocalization { + ForgetAllCredentials(): void; + + /** + * Retrieves the list of allowed languages, only accessible by title entities + * https://docs.microsoft.com/rest/api/playfab/localization/localization/getlanguagelist + */ + GetLanguageList(request: PlayFabLocalizationModels.GetLanguageListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabLocalizationModels { + export interface GetLanguageListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetLanguageListResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of allowed languages, in BCP47 two-letter format */ + LanguageList?: string[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabMatchmakerApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabMatchmakerApi.d.ts deleted file mode 100644 index 81067299..00000000 --- a/PlayFabTestingExample/src/typings/PlayFab/PlayFabMatchmakerApi.d.ts +++ /dev/null @@ -1,360 +0,0 @@ -/// - -declare module PlayFabMatchmakerModule { - export interface IPlayFabMatchmaker { - /** - / Validates a user with the PlayFab service - / https://api.playfab.com/Documentation/Matchmaker/method/AuthUser - */ - AuthUser(request: PlayFabMatchmakerModels.AuthUserRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Informs the PlayFab game server hosting service that the indicated user has joined the Game Server Instance specified - / https://api.playfab.com/Documentation/Matchmaker/method/PlayerJoined - */ - PlayerJoined(request: PlayFabMatchmakerModels.PlayerJoinedRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Informs the PlayFab game server hosting service that the indicated user has left the Game Server Instance specified - / https://api.playfab.com/Documentation/Matchmaker/method/PlayerLeft - */ - PlayerLeft(request: PlayFabMatchmakerModels.PlayerLeftRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Instructs the PlayFab game server hosting service to instantiate a new Game Server Instance - / https://api.playfab.com/Documentation/Matchmaker/method/StartGame - */ - StartGame(request: PlayFabMatchmakerModels.StartGameRequest, callback: PlayFabModule.ApiCallback): void; - /** - / Retrieves the relevant details for a specified user, which the external match-making service can then use to compute effective matches - / https://api.playfab.com/Documentation/Matchmaker/method/UserInfo - */ - UserInfo(request: PlayFabMatchmakerModels.UserInfoRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabMatchmakerModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.AuthUserRequest - */ - export interface AuthUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Session Ticket provided by the client. - */ - AuthorizationTicket: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.AuthUserResponse - */ - export interface AuthUserResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Boolean indicating if the user has been authorized to use the external match-making service. - */ - Authorized: boolean; - /** - / PlayFab unique identifier of the account that has been authorized. - */ - PlayFabId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.DeregisterGameRequest - */ - export interface DeregisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the Game Server Instance that is being deregistered. - */ - LobbyId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.DeregisterGameResponse - */ - export interface DeregisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.ItemInstance - */ - export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ - UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ - UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerJoinedRequest - */ - export interface PlayerJoinedRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance the user is joining. - */ - LobbyId: string; - /** - / PlayFab unique identifier for the user joining. - */ - PlayFabId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerJoinedResponse - */ - export interface PlayerJoinedResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerLeftRequest - */ - export interface PlayerLeftRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance the user is leaving. - */ - LobbyId: string; - /** - / PlayFab unique identifier for the user leaving. - */ - PlayFabId: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.PlayerLeftResponse - */ - export interface PlayerLeftResponse extends PlayFabModule.IPlayFabResultCommon { - - } - - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.RegisterGameRequest - */ - export interface RegisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / IP address of the Game Server Instance. - */ - ServerHost: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: string; - /** - / Unique identifier of the build running on the Game Server Instance. - */ - Build: string; - /** - / Region in which the Game Server Instance is running. For matchmaking using non-AWS region names, set this to any AWS region and use Tags (below) to specify your custom region. - */ - Region: string; - /** - / Game Mode the Game Server instance is running. Note that this must be defined in the Game Modes tab in the PlayFab Game Manager, along with the Build ID (the same Game Mode can be defined for multiple Build IDs). - */ - GameMode: string; - /** - / Tags for the Game Server Instance - */ - Tags?: { [key: string]: string }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.RegisterGameResponse - */ - export interface RegisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier generated for the Game Server Instance that is registered. - */ - LobbyId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.StartGameRequest - */ - export interface StartGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the previously uploaded build executable which is to be started. - */ - Build: string; - /** - / Region with which to associate the server, for filtering. - */ - Region: string; - /** - / Game mode for this Game Server Instance. - */ - GameMode: string; - /** - / Custom command line argument when starting game server process. - */ - CustomCommandLineData?: string; - /** - / HTTP endpoint URL for receiving game status events, if using an external matchmaker. When the game ends, PlayFab will make a POST request to this URL with the X-SecretKey header set to the value of the game's secret and an application/json body of { "EventName": "game_ended", "GameID": "" }. - */ - ExternalMatchmakerEventEndpoint: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.StartGameResponse - */ - export interface StartGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the game/lobby in the new Game Server Instance. - */ - GameID?: string; - /** - / IP address of the new Game Server Instance. - */ - ServerHostname?: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.UserInfoRequest - */ - export interface UserInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose information is being requested. - */ - PlayFabId: string; - /** - / Minimum catalog version for which data is requested (filters the results to only contain inventory items which have a catalog version of this or higher). - */ - MinCatalogVersion: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.UserInfoResponse - */ - export interface UserInfoResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose information was requested. - */ - PlayFabId?: string; - /** - / PlayFab unique user name. - */ - Username?: string; - /** - / Title specific display name, if set. - */ - TitleDisplayName?: string; - /** - / Array of inventory items in the user's current inventory. - */ - Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ - VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ - VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; - /** - / Boolean indicating whether the user is a developer. - */ - IsDeveloper: boolean; - /** - / Steam unique identifier, if the user has an associated Steam account. - */ - SteamId?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Matchmaker.Models/PlayFab.Matchmaker.Models.VirtualCurrencyRechargeTime - */ - export interface VirtualCurrencyRechargeTime { - /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. - */ - RechargeMax: number; - - } - - -} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabMultiplayerApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabMultiplayerApi.d.ts new file mode 100644 index 00000000..17112934 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabMultiplayerApi.d.ts @@ -0,0 +1,3802 @@ +/// + +declare module PlayFabMultiplayerModule { + export interface IPlayFabMultiplayer { + ForgetAllCredentials(): void; + + /** + * Cancel all active tickets the player is a member of in a given queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelallmatchmakingticketsforplayer + */ + CancelAllMatchmakingTicketsForPlayer(request: PlayFabMultiplayerModels.CancelAllMatchmakingTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel all active backfill tickets the player is a member of in a given queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelallserverbackfillticketsforplayer + */ + CancelAllServerBackfillTicketsForPlayer(request: PlayFabMultiplayerModels.CancelAllServerBackfillTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel a matchmaking ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelmatchmakingticket + */ + CancelMatchmakingTicket(request: PlayFabMultiplayerModels.CancelMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Cancel a server backfill ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/cancelserverbackfillticket + */ + CancelServerBackfillTicket(request: PlayFabMultiplayerModels.CancelServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildalias + */ + CreateBuildAlias(request: PlayFabMultiplayerModels.CreateBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with a custom container. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithcustomcontainer + */ + CreateBuildWithCustomContainer(request: PlayFabMultiplayerModels.CreateBuildWithCustomContainerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with a managed container. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithmanagedcontainer + */ + CreateBuildWithManagedContainer(request: PlayFabMultiplayerModels.CreateBuildWithManagedContainerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build with the server running as a process. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createbuildwithprocessbasedserver + */ + CreateBuildWithProcessBasedServer(request: PlayFabMultiplayerModels.CreateBuildWithProcessBasedServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/createlobby + */ + CreateLobby(request: PlayFabMultiplayerModels.CreateLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a matchmaking ticket as a client. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/creatematchmakingticket + */ + CreateMatchmakingTicket(request: PlayFabMultiplayerModels.CreateMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a remote user to log on to a VM for a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createremoteuser + */ + CreateRemoteUser(request: PlayFabMultiplayerModels.CreateRemoteUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a backfill matchmaking ticket as a server. A backfill ticket represents an ongoing game. The matchmaking service + * automatically starts matching the backfill ticket against other matchmaking tickets. Backfill tickets cannot match with + * other backfill tickets. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/createserverbackfillticket + */ + CreateServerBackfillTicket(request: PlayFabMultiplayerModels.CreateServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a matchmaking ticket as a server. The matchmaking service automatically starts matching the ticket against other + * matchmaking tickets. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/createservermatchmakingticket + */ + CreateServerMatchmakingTicket(request: PlayFabMultiplayerModels.CreateServerMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a request to change a title's multiplayer server quotas. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/createtitlemultiplayerserversquotachange + */ + CreateTitleMultiplayerServersQuotaChange(request: PlayFabMultiplayerModels.CreateTitleMultiplayerServersQuotaChangeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game asset for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deleteasset + */ + DeleteAsset(request: PlayFabMultiplayerModels.DeleteAssetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuild + */ + DeleteBuild(request: PlayFabMultiplayerModels.DeleteBuildRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuildalias + */ + DeleteBuildAlias(request: PlayFabMultiplayerModels.DeleteBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Removes a multiplayer server build's region. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletebuildregion + */ + DeleteBuildRegion(request: PlayFabMultiplayerModels.DeleteBuildRegionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game certificate. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletecertificate + */ + DeleteCertificate(request: PlayFabMultiplayerModels.DeleteCertificateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a container image repository. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletecontainerimagerepository + */ + DeleteContainerImageRepository(request: PlayFabMultiplayerModels.DeleteContainerImageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/deletelobby + */ + DeleteLobby(request: PlayFabMultiplayerModels.DeleteLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a remote user to log on to a VM for a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deleteremoteuser + */ + DeleteRemoteUser(request: PlayFabMultiplayerModels.DeleteRemoteUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a multiplayer server game secret. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/deletesecret + */ + DeleteSecret(request: PlayFabMultiplayerModels.DeleteSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Enables the multiplayer server feature for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/enablemultiplayerserversfortitle + */ + EnableMultiplayerServersForTitle(request: PlayFabMultiplayerModels.EnableMultiplayerServersForTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Find lobbies which match certain criteria, and which friends are in. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/findfriendlobbies + */ + FindFriendLobbies(request: PlayFabMultiplayerModels.FindFriendLobbiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Find all the lobbies that match certain criteria. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/findlobbies + */ + FindLobbies(request: PlayFabMultiplayerModels.FindLobbiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a URL that can be used to download the specified asset. A sample pre-authenticated url - + * https://sampleStorageAccount.blob.core.windows.net/gameassets/gameserver.zip?sv=2015-04-05&ss=b&srt=sco&sp=rw&st=startDate&se=endDate&spr=https&sig=sampleSig&api-version=2017-07-29 + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getassetdownloadurl + */ + GetAssetDownloadUrl(request: PlayFabMultiplayerModels.GetAssetDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the URL to upload assets to. A sample pre-authenticated url - + * https://sampleStorageAccount.blob.core.windows.net/gameassets/gameserver.zip?sv=2015-04-05&ss=b&srt=sco&sp=rw&st=startDate&se=endDate&spr=https&sig=sampleSig&api-version=2017-07-29 + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getassetuploadurl + */ + GetAssetUploadUrl(request: PlayFabMultiplayerModels.GetAssetUploadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getbuild + */ + GetBuild(request: PlayFabMultiplayerModels.GetBuildRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getbuildalias + */ + GetBuildAlias(request: PlayFabMultiplayerModels.GetBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the credentials to the container registry. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getcontainerregistrycredentials + */ + GetContainerRegistryCredentials(request: PlayFabMultiplayerModels.GetContainerRegistryCredentialsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/getlobby + */ + GetLobby(request: PlayFabMultiplayerModels.GetLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a match. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getmatch + */ + GetMatch(request: PlayFabMultiplayerModels.GetMatchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Get a matchmaking queue configuration. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/getmatchmakingqueue + */ + GetMatchmakingQueue(request: PlayFabMultiplayerModels.GetMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a matchmaking ticket by ticket Id. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getmatchmakingticket + */ + GetMatchmakingTicket(request: PlayFabMultiplayerModels.GetMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server session details for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayerserverdetails + */ + GetMultiplayerServerDetails(request: PlayFabMultiplayerModels.GetMultiplayerServerDetailsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server logs after a server has terminated. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayerserverlogs + */ + GetMultiplayerServerLogs(request: PlayFabMultiplayerModels.GetMultiplayerServerLogsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets multiplayer server logs after a server has terminated. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getmultiplayersessionlogsbysessionid + */ + GetMultiplayerSessionLogsBySessionId(request: PlayFabMultiplayerModels.GetMultiplayerSessionLogsBySessionIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the statistics for a queue. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getqueuestatistics + */ + GetQueueStatistics(request: PlayFabMultiplayerModels.GetQueueStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a remote login endpoint to a VM that is hosting a multiplayer server build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/getremoteloginendpoint + */ + GetRemoteLoginEndpoint(request: PlayFabMultiplayerModels.GetRemoteLoginEndpointRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get a matchmaking backfill ticket by ticket Id. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/getserverbackfillticket + */ + GetServerBackfillTicket(request: PlayFabMultiplayerModels.GetServerBackfillTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the status of whether a title is enabled for the multiplayer server feature. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitleenabledformultiplayerserversstatus + */ + GetTitleEnabledForMultiplayerServersStatus(request: PlayFabMultiplayerModels.GetTitleEnabledForMultiplayerServersStatusRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets a title's server quota change request. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitlemultiplayerserversquotachange + */ + GetTitleMultiplayerServersQuotaChange(request: PlayFabMultiplayerModels.GetTitleMultiplayerServersQuotaChangeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the quotas for a title in relation to multiplayer servers. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/gettitlemultiplayerserversquotas + */ + GetTitleMultiplayerServersQuotas(request: PlayFabMultiplayerModels.GetTitleMultiplayerServersQuotasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Send a notification to invite a player to a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/invitetolobby + */ + InviteToLobby(request: PlayFabMultiplayerModels.InviteToLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join an Arranged lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinarrangedlobby + */ + JoinArrangedLobby(request: PlayFabMultiplayerModels.JoinArrangedLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinlobby + */ + JoinLobby(request: PlayFabMultiplayerModels.JoinLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Join a lobby as a server entity. This is restricted to client lobbies which are using connections. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/joinlobbyasserver + */ + JoinLobbyAsServer(request: PlayFabMultiplayerModels.JoinLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Join a matchmaking ticket. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/joinmatchmakingticket + */ + JoinMatchmakingTicket(request: PlayFabMultiplayerModels.JoinMatchmakingTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Leave a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/leavelobby + */ + LeaveLobby(request: PlayFabMultiplayerModels.LeaveLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Request for server to leave a lobby. This is restricted to client owned lobbies which are using connections. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/leavelobbyasserver + */ + LeaveLobbyAsServer(request: PlayFabMultiplayerModels.LeaveLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists archived multiplayer server sessions for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listarchivedmultiplayerservers + */ + ListArchivedMultiplayerServers(request: PlayFabMultiplayerModels.ListMultiplayerServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game assets for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listassetsummaries + */ + ListAssetSummaries(request: PlayFabMultiplayerModels.ListAssetSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists details of all build aliases for a title. Accepts tokens for title and if game client access is enabled, allows + * game client to request list of builds with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listbuildaliases + */ + ListBuildAliases(request: PlayFabMultiplayerModels.ListBuildAliasesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists summarized details of all multiplayer server builds for a title. Accepts tokens for title and if game client + * access is enabled, allows game client to request list of builds with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listbuildsummariesv2 + */ + ListBuildSummariesV2(request: PlayFabMultiplayerModels.ListBuildSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game certificates for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcertificatesummaries + */ + ListCertificateSummaries(request: PlayFabMultiplayerModels.ListCertificateSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists custom container images for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcontainerimages + */ + ListContainerImages(request: PlayFabMultiplayerModels.ListContainerImagesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists the tags for a custom container image. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listcontainerimagetags + */ + ListContainerImageTags(request: PlayFabMultiplayerModels.ListContainerImageTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. List all matchmaking queue configs. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/listmatchmakingqueues + */ + ListMatchmakingQueues(request: PlayFabMultiplayerModels.ListMatchmakingQueuesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all matchmaking ticket Ids the user is a member of. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/listmatchmakingticketsforplayer + */ + ListMatchmakingTicketsForPlayer(request: PlayFabMultiplayerModels.ListMatchmakingTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server sessions for a build. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listmultiplayerservers + */ + ListMultiplayerServers(request: PlayFabMultiplayerModels.ListMultiplayerServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists quality of service servers for party. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listpartyqosservers + */ + ListPartyQosServers(request: PlayFabMultiplayerModels.ListPartyQosServersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists quality of service servers for the title. By default, servers are only returned for regions where a Multiplayer + * Servers build has been deployed. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listqosserversfortitle + */ + ListQosServersForTitle(request: PlayFabMultiplayerModels.ListQosServersForTitleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists multiplayer server game secrets for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listsecretsummaries + */ + ListSecretSummaries(request: PlayFabMultiplayerModels.ListSecretSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all server backfill ticket Ids the user is a member of. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/listserverbackfillticketsforplayer + */ + ListServerBackfillTicketsForPlayer(request: PlayFabMultiplayerModels.ListServerBackfillTicketsForPlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * List all server quota change requests for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listtitlemultiplayerserversquotachanges + */ + ListTitleMultiplayerServersQuotaChanges(request: PlayFabMultiplayerModels.ListTitleMultiplayerServersQuotaChangesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists virtual machines for a title. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/listvirtualmachinesummaries + */ + ListVirtualMachineSummaries(request: PlayFabMultiplayerModels.ListVirtualMachineSummariesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Remove a matchmaking queue config. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/removematchmakingqueue + */ + RemoveMatchmakingQueue(request: PlayFabMultiplayerModels.RemoveMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Remove a member from a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/removemember + */ + RemoveMember(request: PlayFabMultiplayerModels.RemoveMemberFromLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Request a multiplayer server session. Accepts tokens for title and if game client access is enabled, allows game client + * to request a server with player entity token. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/requestmultiplayerserver + */ + RequestMultiplayerServer(request: PlayFabMultiplayerModels.RequestMultiplayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Request a party session. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/requestpartyservice + */ + RequestPartyService(request: PlayFabMultiplayerModels.RequestPartyServiceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Rolls over the credentials to the container registry. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/rollovercontainerregistrycredentials + */ + RolloverContainerRegistryCredentials(request: PlayFabMultiplayerModels.RolloverContainerRegistryCredentialsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * SDK support is limited to C# and Java for this API. Create or update a matchmaking queue configuration. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking-admin/setmatchmakingqueue + */ + SetMatchmakingQueue(request: PlayFabMultiplayerModels.SetMatchmakingQueueRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Shuts down a multiplayer server session. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/shutdownmultiplayerserver + */ + ShutdownMultiplayerServer(request: PlayFabMultiplayerModels.ShutdownMultiplayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subscribe to lobby resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/subscribetolobbyresource + */ + SubscribeToLobbyResource(request: PlayFabMultiplayerModels.SubscribeToLobbyResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Subscribe to match resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/subscribetomatchmakingresource + */ + SubscribeToMatchmakingResource(request: PlayFabMultiplayerModels.SubscribeToMatchResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unsubscribe from lobby notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/unsubscribefromlobbyresource + */ + UnsubscribeFromLobbyResource(request: PlayFabMultiplayerModels.UnsubscribeFromLobbyResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unsubscribe from match resource notifications. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/matchmaking/unsubscribefrommatchmakingresource + */ + UnsubscribeFromMatchmakingResource(request: PlayFabMultiplayerModels.UnsubscribeFromMatchResourceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Untags a container image. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/untagcontainerimage + */ + UntagContainerImage(request: PlayFabMultiplayerModels.UntagContainerImageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Creates a multiplayer server build alias. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildalias + */ + UpdateBuildAlias(request: PlayFabMultiplayerModels.UpdateBuildAliasRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's name. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildname + */ + UpdateBuildName(request: PlayFabMultiplayerModels.UpdateBuildNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's region. If the region is not yet created, it will be created + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildregion + */ + UpdateBuildRegion(request: PlayFabMultiplayerModels.UpdateBuildRegionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a multiplayer server build's regions. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/updatebuildregions + */ + UpdateBuildRegions(request: PlayFabMultiplayerModels.UpdateBuildRegionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update a lobby. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/updatelobby + */ + UpdateLobby(request: PlayFabMultiplayerModels.UpdateLobbyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Preview: Update fields related to a joined server in the lobby the server is in. Servers can keep a lobby from expiring + * by being the one to "update" the lobby in some way. Servers have no impact on last member leave/last member disconnect + * behavior. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/lobby/updatelobbyasserver + */ + UpdateLobbyAsServer(request: PlayFabMultiplayerModels.UpdateLobbyAsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Uploads a multiplayer server game certificate. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/uploadcertificate + */ + UploadCertificate(request: PlayFabMultiplayerModels.UploadCertificateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Uploads a multiplayer server game secret. + * https://docs.microsoft.com/rest/api/playfab/multiplayer/multiplayerserver/uploadsecret + */ + UploadSecret(request: PlayFabMultiplayerModels.UploadSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabMultiplayerModels { + type AccessPolicy = "Public" + + | "Friends" + | "Private"; + + export interface AssetReference { + /** The asset's file name. This is a filename with the .zip, .tar, or .tar.gz extension. */ + FileName?: string; + /** The asset's mount path. */ + MountPath?: string; + + } + + export interface AssetReferenceParams { + /** The asset's file name. */ + FileName: string; + /** The asset's mount path. */ + MountPath?: string; + + } + + export interface AssetSummary { + /** The asset's file name. This is a filename with the .zip, .tar, or .tar.gz extension. */ + FileName?: string; + /** The metadata associated with the asset. */ + Metadata?: { [key: string]: string | null }; + + } + + type AttributeMergeFunction = "Min" + + | "Max" + | "Average"; + + type AttributeNotSpecifiedBehavior = "UseDefault" + + | "MatchAny"; + + type AttributeSource = "User" + + | "PlayerEntity"; + + type AzureRegion = "AustraliaEast" + + | "AustraliaSoutheast" + | "BrazilSouth" + | "CentralUs" + | "EastAsia" + | "EastUs" + | "EastUs2" + | "JapanEast" + | "JapanWest" + | "NorthCentralUs" + | "NorthEurope" + | "SouthCentralUs" + | "SoutheastAsia" + | "WestEurope" + | "WestUs" + | "SouthAfricaNorth" + | "WestCentralUs" + | "KoreaCentral" + | "FranceCentral" + | "WestUs2" + | "CentralIndia" + | "UaeNorth" + | "UkSouth" + | "SwedenCentral" + | "CanadaCentral" + | "MexicoCentral" + | "WestUs3" + | "CanadaEast" + | "UkWest" + | "FranceSouth" + | "SouthIndia" + | "SpainCentral" + | "GermanyWestCentral" + | "ItalyNorth" + | "IndonesiaCentral" + | "ChileCentral" + | "PolandCentral" + | "NewZealandNorth" + | "BrazilSoutheast" + | "NorwayEast" + | "SwitzerlandNorth" + | "MalaysiaWest" + | "IsraelCentral" + | "QatarCentral" + | "UaeCentral" + | "GermanyNorth" + | "AustriaEast" + | "BelgiumCentral" + | "DenmarkEast" + | "SwitzerlandWest" + | "SwedenSouth" + | "NorwayWest" + | "SouthAfricaWest" + | "MalaysiaSouth"; + + type AzureVmFamily = "A" + + | "Av2" + | "Dv2" + | "Dv3" + | "F" + | "Fsv2" + | "Dasv4" + | "Dav4" + | "Dadsv5" + | "Dadsv6" + | "Eav4" + | "Easv4" + | "Ev4" + | "Esv4" + | "Edsv4" + | "Edsv5" + | "Edsv6" + | "Dsv3" + | "Dsv2" + | "NCasT4_v3" + | "Ddv4" + | "Ddsv4" + | "HBv3" + | "Ddv5" + | "Ddsv5" + | "Ddsv6" + | "Fasv6" + | "Fasv7" + | "Fadsv7" + | "Eadsv5" + | "Eadsv6" + | "Eadsv7" + | "Dadsv7" + | "Dpdsv6"; + + type AzureVmSize = "Standard_A1" + + | "Standard_A2" + | "Standard_A3" + | "Standard_A4" + | "Standard_A1_v2" + | "Standard_A2_v2" + | "Standard_A4_v2" + | "Standard_A8_v2" + | "Standard_D1_v2" + | "Standard_D2_v2" + | "Standard_D3_v2" + | "Standard_D4_v2" + | "Standard_D5_v2" + | "Standard_D2_v3" + | "Standard_D4_v3" + | "Standard_D8_v3" + | "Standard_D16_v3" + | "Standard_F1" + | "Standard_F2" + | "Standard_F4" + | "Standard_F8" + | "Standard_F16" + | "Standard_F2s_v2" + | "Standard_F4s_v2" + | "Standard_F8s_v2" + | "Standard_F16s_v2" + | "Standard_F2as_v6" + | "Standard_F4as_v6" + | "Standard_F8as_v6" + | "Standard_F16as_v6" + | "Standard_F2as_v7" + | "Standard_F4as_v7" + | "Standard_F8as_v7" + | "Standard_F16as_v7" + | "Standard_F2ads_v7" + | "Standard_F4ads_v7" + | "Standard_F8ads_v7" + | "Standard_F16ads_v7" + | "Standard_D2as_v4" + | "Standard_D4as_v4" + | "Standard_D8as_v4" + | "Standard_D16as_v4" + | "Standard_D2a_v4" + | "Standard_D4a_v4" + | "Standard_D8a_v4" + | "Standard_D16a_v4" + | "Standard_D2ads_v5" + | "Standard_D4ads_v5" + | "Standard_D8ads_v5" + | "Standard_D16ads_v5" + | "Standard_D2ads_v6" + | "Standard_D4ads_v6" + | "Standard_D8ads_v6" + | "Standard_D16ads_v6" + | "Standard_D2ads_v7" + | "Standard_D4ads_v7" + | "Standard_D8ads_v7" + | "Standard_D16ads_v7" + | "Standard_E2a_v4" + | "Standard_E4a_v4" + | "Standard_E8a_v4" + | "Standard_E16a_v4" + | "Standard_E2as_v4" + | "Standard_E4as_v4" + | "Standard_E8as_v4" + | "Standard_E16as_v4" + | "Standard_E2ads_v5" + | "Standard_E4ads_v5" + | "Standard_E8ads_v5" + | "Standard_E16ads_v5" + | "Standard_E2ads_v6" + | "Standard_E4ads_v6" + | "Standard_E8ads_v6" + | "Standard_E16ads_v6" + | "Standard_E2ads_v7" + | "Standard_E4ads_v7" + | "Standard_E8ads_v7" + | "Standard_E16ads_v7" + | "Standard_E2ds_v4" + | "Standard_E4ds_v4" + | "Standard_E8ds_v4" + | "Standard_E16ds_v4" + | "Standard_E2ds_v5" + | "Standard_E4ds_v5" + | "Standard_E8ds_v5" + | "Standard_E16ds_v5" + | "Standard_E2ds_v6" + | "Standard_E4ds_v6" + | "Standard_E8ds_v6" + | "Standard_E16ds_v6" + | "Standard_D2s_v3" + | "Standard_D4s_v3" + | "Standard_D8s_v3" + | "Standard_D16s_v3" + | "Standard_DS1_v2" + | "Standard_DS2_v2" + | "Standard_DS3_v2" + | "Standard_DS4_v2" + | "Standard_DS5_v2" + | "Standard_NC4as_T4_v3" + | "Standard_D2d_v4" + | "Standard_D4d_v4" + | "Standard_D8d_v4" + | "Standard_D16d_v4" + | "Standard_D2ds_v4" + | "Standard_D4ds_v4" + | "Standard_D8ds_v4" + | "Standard_D16ds_v4" + | "Standard_HB120_16rs_v3" + | "Standard_HB120_32rs_v3" + | "Standard_HB120_64rs_v3" + | "Standard_HB120_96rs_v3" + | "Standard_HB120rs_v3" + | "Standard_D2d_v5" + | "Standard_D4d_v5" + | "Standard_D8d_v5" + | "Standard_D16d_v5" + | "Standard_D32d_v5" + | "Standard_D2ds_v5" + | "Standard_D4ds_v5" + | "Standard_D8ds_v5" + | "Standard_D16ds_v5" + | "Standard_D32ds_v5" + | "Standard_D2ds_v6" + | "Standard_D4ds_v6" + | "Standard_D8ds_v6" + | "Standard_D16ds_v6" + | "Standard_D2pds_v6" + | "Standard_D4pds_v6" + | "Standard_D8pds_v6" + | "Standard_D16pds_v6"; + + export interface BuildAliasDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The guid string alias Id of the alias to be created or updated. */ + AliasId?: string; + /** The alias name. */ + AliasName?: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + + } + + export interface BuildAliasParams { + /** The guid string alias ID to use for the request. */ + AliasId: string; + + } + + export interface BuildRegion { + /** The current multiplayer server stats for the region. */ + CurrentServerStats?: CurrentServerStats; + /** Optional settings to control dynamic adjustment of standby target */ + DynamicStandbySettings?: DynamicStandbySettings; + /** Whether the game assets provided for the build have been replicated to this region. */ + IsAssetReplicationComplete: boolean; + /** The maximum number of multiplayer servers for the region. */ + MaxServers: number; + /** Regional override for the number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm?: number; + /** The build region. */ + Region?: string; + /** Optional settings to set the standby target to specified values during the supplied schedules */ + ScheduledStandbySettings?: ScheduledStandbySettings; + /** The target number of standby multiplayer servers for the region. */ + StandbyServers: number; + /** + * The status of multiplayer servers in the build region. Valid values are - Unknown, Initialized, Deploying, Deployed, + * Unhealthy, Deleting, Deleted. + */ + Status?: string; + /** Regional override for the VM size the build was created on. */ + VmSize?: string; + + } + + export interface BuildRegionParams { + /** Optional settings to control dynamic adjustment of standby target. If not specified, dynamic standby is disabled */ + DynamicStandbySettings?: DynamicStandbySettings; + /** The maximum number of multiplayer servers for the region. */ + MaxServers: number; + /** Regional override for the number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm?: number; + /** The build region. */ + Region: string; + /** Optional settings to set the standby target to specified values during the supplied schedules */ + ScheduledStandbySettings?: ScheduledStandbySettings; + /** The number of standby multiplayer servers for the region. */ + StandbyServers: number; + /** Regional override for the VM size the build was created on. */ + VmSize?: string; + + } + + export interface BuildSelectionCriterion { + /** Dictionary of build ids and their respective weights for distribution of allocation requests. */ + BuildWeightDistribution?: { [key: string]: number }; + + } + + export interface BuildSummary { + /** The guid string build ID of the build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The configuration and status for each region in the build. */ + RegionConfigurations?: BuildRegion[]; + + } + + export interface CancelAllMatchmakingTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the queue from which a player's tickets should be canceled. */ + QueueName: string; + + } + + export interface CancelAllMatchmakingTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CancelAllServerBackfillTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The name of the queue from which a player's backfill tickets should be canceled. */ + QueueName: string; + + } + + export interface CancelAllServerBackfillTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + type CancellationReason = "Requested" + + | "Internal" + | "Timeout"; + + export interface CancelMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue the ticket is in. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CancelMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface CancelServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue the ticket is in. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CancelServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface Certificate { + /** Base64 encoded string contents of the certificate. */ + Base64EncodedValue: string; + /** A name for the certificate. This is used to reference certificates in build configurations. */ + Name: string; + /** + * If required for your PFX certificate, use this field to provide a password that will be used to install the certificate + * on the container. + */ + Password?: string; + + } + + export interface CertificateSummary { + /** The name of the certificate. */ + Name?: string; + /** The thumbprint for the certificate. */ + Thumbprint?: string; + + } + + export interface ConnectedPlayer { + /** The player ID of the player connected to the multiplayer server. */ + PlayerId?: string; + + } + + type ContainerFlavor = "ManagedWindowsServerCore" + + | "CustomLinux" + | "ManagedWindowsServerCorePreview" + | "Invalid"; + + export interface ContainerImageReference { + /** The container image name. */ + ImageName: string; + /** The container tag. */ + Tag?: string; + + } + + export interface CoreCapacity { + /** The available core capacity for the (Region, VmFamily) */ + Available: number; + /** The AzureRegion */ + Region?: string; + /** The total core capacity for the (Region, VmFamily) */ + Total: number; + /** The AzureVmFamily */ + VmFamily?: string; + + } + + export interface CoreCapacityChange { + /** New quota core limit for the given vm family/region. */ + NewCoreLimit: number; + /** Region to change. */ + Region: string; + /** Virtual machine family to change. */ + VmFamily: string; + + } + + export interface CreateBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The alias name. */ + AliasName: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface CreateBuildWithCustomContainerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The flavor of container to create a build from. */ + ContainerFlavor?: string; + /** The container reference, consisting of the image name and tag. */ + ContainerImageReference?: ContainerImageReference; + /** The container command to run when the multiplayer server has been allocated, including any arguments. */ + ContainerRunCommand?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences?: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** The Linux instrumentation configuration for the build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + + } + + export interface CreateBuildWithCustomContainerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The container command to run when the multiplayer server has been allocated, including any arguments. */ + ContainerRunCommand?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The custom game container image reference information. */ + CustomGameContainerImage?: ContainerImageReference; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** The Linux instrumentation configuration for this build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateBuildWithManagedContainerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The flavor of container to create a build from. */ + ContainerFlavor?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** + * The directory containing the game executable. This would be the start path of the game assets that contain the main game + * server executable. If not provided, a best effort will be made to extract it from the start game command. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for the build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The command to run when the multiplayer server is started, including any arguments. */ + StartMultiplayerServerCommand: string; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + /** The crash dump configuration for the build. */ + WindowsCrashDumpConfiguration?: WindowsCrashDumpConfiguration; + + } + + export interface CreateBuildWithManagedContainerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** + * The directory containing the game executable. This would be the start path of the game assets that contain the main game + * server executable. If not provided, a best effort will be made to extract it from the start game command. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for this build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM (EXPERIMENTAL API) */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** The command to run when the multiplayer server has been allocated, including any arguments. */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateBuildWithProcessBasedServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The build name. */ + BuildName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The list of game assets related to the build. */ + GameAssetReferences: AssetReferenceParams[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReferenceParams[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReferenceParams[]; + /** + * The working directory for the game process. If this is not provided, the working directory will be set based on the + * mount path of the game server executable. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for the Build. Used only if it is a Windows Build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Indicates whether this build will be created using the OS Preview versionPreview OS is recommended for dev builds to + * detect any breaking changes before they are released to retail. Retail builds should set this value to false. + */ + IsOSPreview?: boolean; + /** The Linux instrumentation configuration for the Build. Used only if it is a Linux Build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** + * Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through + * Game Server SDK (GSDK).Constraints: Maximum number of keys: 30, Maximum key length: 50, Maximum value length: 100 + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports to map the build on. */ + Ports: Port[]; + /** The region configurations for the build. */ + RegionConfigurations: BuildRegionParams[]; + /** + * The command to run when the multiplayer server is started, including any arguments. The path to any executable should be + * relative to the root asset folder when unzipped. + */ + StartMultiplayerServerCommand: string; + /** The VM size to create the build on. */ + VmSize?: string; + /** The configuration for the VmStartupScript for the build */ + VmStartupScriptConfiguration?: VmStartupScriptParams; + + } + + export interface CreateBuildWithProcessBasedServerResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID. Must be unique for every build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The flavor of container of the build. */ + ContainerFlavor?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** + * The working directory for the game process. If this is not provided, the working directory will be set based on the + * mount path of the game server executable. + */ + GameWorkingDirectory?: string; + /** The instrumentation configuration for this build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Indicates whether this build will be created using the OS Preview versionPreview OS is recommended for dev builds to + * detect any breaking changes before they are released to retail. Retail builds should set this value to false. + */ + IsOSPreview?: boolean; + /** The Linux instrumentation configuration for this build. */ + LinuxInstrumentationConfiguration?: LinuxInstrumentationConfiguration; + /** The metadata of the build. */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to host on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The type of game server being hosted. */ + ServerType?: string; + /** + * The command to run when the multiplayer server is started, including any arguments. The path to any executable is + * relative to the root asset folder when unzipped. + */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface CreateLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby. At most 30 key-value pairs may be stored + * here, keys are limited to 30 characters and values to 1000. The total size of all lobbyData values may not exceed 4096 + * bytes. Keys are case sensitive. + */ + LobbyData?: { [key: string]: string | null }; + /** The maximum number of players allowed in the lobby. The value must be between 2 and 128. */ + MaxPlayers: number; + /** + * The member initially added to the lobby. Client must specify exactly one member, which is the creator's entity and + * member data. Member PubSubConnectionHandle must be null or empty. Game servers must not specify any members. + */ + Members?: Member[]; + /** The lobby owner. Must be the calling entity. */ + Owner: EntityKey; + /** + * The policy for how a new owner is chosen. May be 'Automatic', 'Manual' or 'None'. Can only be specified by clients. If + * client-owned and 'Automatic' - The Lobby service will automatically assign another connected owner when the current + * owner leaves or disconnects. The useConnections property must be true. If client - owned and 'Manual' - Ownership is + * protected as long as the current owner is connected. If the current owner leaves or disconnects any member may set + * themselves as the current owner. The useConnections property must be true. If client-owned and 'None' - Any member can + * set ownership. The useConnections property can be either true or false. + */ + OwnerMigrationPolicy?: string; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Defaults to false if not specified. + * Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner: boolean; + /** + * The public key-value pairs which allow queries to differentiate between lobbies. Queries will refer to these key-value + * pairs in their filter and order by clauses to retrieve lobbies fitting the specified criteria. At most 30 key-value + * pairs may be stored here. Keys are of the format string_key1, string_key2 ... string_key30 for string values, or + * number_key1, number_key2, ... number_key30 for numeric values.Numeric values are floats. Values can be at most 256 + * characters long. The total size of all searchData values may not exceed 1024 bytes. + */ + SearchData?: { [key: string]: string | null }; + /** + * A setting to control whether connections are used. Defaults to true. When true, notifications are sent to subscribed + * players, disconnect detection removes connectionHandles, only owner migration policies using connections are allowed, + * and lobbies must have at least one connected member to be searchable or be a server hosted lobby with a connected + * server. If false, then notifications are not sent, connections are not allowed, and lobbies do not need connections to + * be searchable. + */ + UseConnections: boolean; + + } + + export interface CreateLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** A field which indicates which lobby the user will be joining. */ + ConnectionString: string; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + + } + + export interface CreateMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The User who created this ticket. */ + Creator: MatchmakingPlayer; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** A list of Entity Keys of other users to match with. */ + MembersToMatchWith?: EntityKey[]; + /** The Id of a match queue. */ + QueueName: string; + + } + + export interface CreateMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CreateRemoteUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of to create the remote user for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The expiration time for the remote user created. Defaults to expiring in one day if not specified. */ + ExpirationTime?: string; + /** The region of virtual machine to create the remote user for. */ + Region: string; + /** The username to create the remote user with. */ + Username: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface CreateRemoteUserResponse extends PlayFabModule.IPlayFabResultCommon { + /** The expiration time for the remote user created. */ + ExpirationTime?: string; + /** The generated password for the remote user that was created. */ + Password?: string; + /** The username for the remote user that was created. */ + Username?: string; + + } + + export interface CreateServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The users who will be part of this ticket, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** The Id of a match queue. */ + QueueName: string; + /** The details of the server the members are connected to. */ + ServerDetails?: ServerDetails; + + } + + export interface CreateServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface CreateServerMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The users who will be part of this ticket. */ + Members: MatchmakingPlayer[]; + /** The Id of a match queue. */ + QueueName: string; + + } + + export interface CreateTitleMultiplayerServersQuotaChangeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A brief description of the requested changes. */ + ChangeDescription?: string; + /** Changes to make to the titles cores quota. */ + Changes: CoreCapacityChange[]; + /** Email to be contacted by our team about this request. Only required when a request is not approved. */ + ContactEmail?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Additional information about this request that our team can use to better understand the requirements. */ + Notes?: string; + /** When these changes would need to be in effect. Only required when a request is not approved. */ + StartDate?: string; + + } + + export interface CreateTitleMultiplayerServersQuotaChangeResponse extends PlayFabModule.IPlayFabResultCommon { + /** Id of the change request that was created. */ + RequestId?: string; + /** Determines if the request was approved or not. When false, our team is reviewing and may respond within 2 business days. */ + WasApproved: boolean; + + } + + export interface CurrentServerStats { + /** The number of active multiplayer servers. */ + Active: number; + /** The number of multiplayer servers still downloading game resources (such as assets). */ + Propping: number; + /** The number of standingby multiplayer servers. */ + StandingBy: number; + /** The total number of multiplayer servers. */ + Total: number; + + } + + export interface CustomDifferenceRuleExpansion { + /** Manually specify the values to use for each expansion interval (this overrides Difference, Delta, and MaxDifference). */ + DifferenceOverrides: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomRegionSelectionRuleExpansion { + /** Manually specify the maximum latency to use for each expansion interval. */ + MaxLatencyOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomSetIntersectionRuleExpansion { + /** Manually specify the values to use for each expansion interval. */ + MinIntersectionSizeOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomTeamDifferenceRuleExpansion { + /** Manually specify the team difference value to use for each expansion interval. */ + DifferenceOverrides: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface CustomTeamSizeBalanceRuleExpansion { + /** Manually specify the team size difference to use for each expansion interval. */ + DifferenceOverrides: OverrideUnsignedInt[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface DeleteAssetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The filename of the asset to delete. */ + FileName: string; + + } + + export interface DeleteBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias ID of the alias to perform the action on. */ + AliasId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface DeleteBuildRegionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The build region to delete. */ + Region: string; + + } + + export interface DeleteBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the build to delete. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface DeleteCertificateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the certificate. */ + Name: string; + + } + + export interface DeleteContainerImageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container image repository we want to delete. */ + ImageName?: string; + + } + + export interface DeleteLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + + } + + export interface DeleteRemoteUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer server where the remote user is to delete. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The region of the multiplayer server where the remote user is to delete. */ + Region: string; + /** The username of the remote user to delete. */ + Username: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface DeleteSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the secret. */ + Name: string; + + } + + export interface DifferenceRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, Difference is ignored. + */ + CustomExpansion?: CustomDifferenceRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). Optional. + */ + DefaultAttributeValue?: number; + /** The allowed difference between any two tickets at the start of matchmaking. */ + Difference: number; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearDifferenceRuleExpansion; + /** How values are treated when there are multiple players in a single ticket. */ + MergeFunction: string; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + type DirectPeerConnectivityOptions = "None" + + | "SamePlatformType" + | "DifferentPlatformType" + | "AnyPlatformType" + | "SameEntityLoginProvider" + | "DifferentEntityLoginProvider" + | "AnyEntityLoginProvider" + | "AnyPlatformTypeAndEntityLoginProvider" + | "OnlyServers"; + + export interface DynamicStandbySettings { + /** + * List of auto standing by trigger values and corresponding standing by multiplier. Defaults to 1.5X at 50%, 3X at 25%, + * and 4X at 5% + */ + DynamicFloorMultiplierThresholds?: DynamicStandbyThreshold[]; + /** When true, dynamic standby will be enabled */ + IsEnabled: boolean; + /** The time it takes to reduce target standing by to configured floor value after an increase. Defaults to 30 minutes */ + RampDownSeconds?: number; + + } + + export interface DynamicStandbyThreshold { + /** When the trigger threshold is reached, multiply by this value */ + Multiplier: number; + /** The multiplier will be applied when the actual standby divided by target standby floor is less than this value */ + TriggerThresholdPercentage: number; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EnableMultiplayerServersForTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface EnableMultiplayerServersForTitleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The enabled status for the multiplayer server features for the title. */ + Status?: string; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FindFriendLobbiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Indicates which other platforms' friends this query should link to. */ + ExternalPlatformFriends?: string; + /** + * OData style string that contains one or more filters. Only the following operators are supported: "and" (logical and), + * "eq" (equal), "ne" (not equals), "ge" (greater than or equal), "gt" (greater than), "le" (less than or equal), and "lt" + * (less than). The left-hand side of each OData logical expression should be either a search property key (e.g. + * string_key1, number_key3, etc) or one of the pre-defined search keys all of which must be prefixed by "lobby/": + * lobby/memberCount (number of players in a lobby), lobby/maxMemberCount (maximum number of players allowed in a lobby), + * lobby/memberCountRemaining (remaining number of players who can be allowed in a lobby), lobby/membershipLock (must equal + * 'Unlocked' or 'Locked'), lobby/amOwner (required to equal "true"), lobby/amMember (required to equal "true"). + */ + Filter?: string; + /** + * OData style string that contains sorting for this query in either ascending ("asc") or descending ("desc") order. + * OrderBy clauses are of the form "number_key1 asc" or the pre-defined search key "lobby/memberCount asc", + * "lobby/memberCountRemaining desc" and "lobby/maxMemberCount desc". To sort by closest, a moniker `distance{number_key1 = + * 5}` can be used to sort by distance from the given number. This field only supports either one sort clause or one + * distance clause. + */ + OrderBy?: string; + /** Request pagination information. */ + Pagination?: PaginationRequest; + /** + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. Only mutual Xbox Live friends + * (where both users follow each other) are included, unlike GetFriendsList which includes all users the caller is + * following. + */ + XboxToken?: string; + + } + + export interface FindFriendLobbiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of lobbies found that matched FindFriendLobbies request. */ + Lobbies: FriendLobbySummary[]; + /** Pagination response for FindFriendLobbies request. */ + Pagination: PaginationResponse; + + } + + export interface FindLobbiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * OData style string that contains one or more filters. Only the following operators are supported: "and" (logical and), + * "eq" (equal), "ne" (not equals), "ge" (greater than or equal), "gt" (greater than), "le" (less than or equal), and "lt" + * (less than). The left-hand side of each OData logical expression should be either a search property key (e.g. + * string_key1, number_key3, etc) or one of the pre-defined search keys all of which must be prefixed by "lobby/": + * lobby/memberCount (number of players in a lobby), lobby/maxMemberCount (maximum number of players allowed in a lobby), + * lobby/memberCountRemaining (remaining number of players who can be allowed in a lobby), lobby/membershipLock (must equal + * 'Unlocked' or 'Locked'), lobby/amOwner (required to equal "true"), lobby/amMember (required to equal "true"). + */ + Filter?: string; + /** + * OData style string that contains sorting for this query in either ascending ("asc") or descending ("desc") order. + * OrderBy clauses are of the form "number_key1 asc" or the pre-defined search key "lobby/memberCount asc", + * "lobby/memberCountRemaining desc" and "lobby/maxMemberCount desc". To sort by closest, a moniker `distance{number_key1 = + * 5}` can be used to sort by distance from the given number. This field only supports either one sort clause or one + * distance clause. + */ + OrderBy?: string; + /** Request pagination information. */ + Pagination?: PaginationRequest; + + } + + export interface FindLobbiesResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of lobbies found that matched FindLobbies request. */ + Lobbies: LobbySummary[]; + /** Pagination response for FindLobbies request. */ + Pagination: PaginationResponse; + + } + + export interface FriendLobbySummary { + /** + * A string used to join the lobby.This field is populated by the Lobby service.Invites are performed by communicating this + * connectionString to other players. + */ + ConnectionString: string; + /** The current number of players in the lobby. */ + CurrentPlayers: number; + /** Friends in Lobby. */ + Friends?: EntityKey[]; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock?: string; + /** The client or server entity which owns this lobby. */ + Owner: EntityKey; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + + } + + export interface GameCertificateReference { + /** + * An alias for the game certificate. The game server will reference this alias via GSDK config to retrieve the game + * certificate. This alias is used as an identifier in game server code to allow a new certificate with different Name + * field to be uploaded without the need to change any game server code to reference the new Name. + */ + GsdkAlias?: string; + /** + * The name of the game certificate. This name should match the name of a certificate that was previously uploaded to this + * title. + */ + Name?: string; + + } + + export interface GameCertificateReferenceParams { + /** + * An alias for the game certificate. The game server will reference this alias via GSDK config to retrieve the game + * certificate. This alias is used as an identifier in game server code to allow a new certificate with different Name + * field to be uploaded without the need to change any game server code to reference the new Name. + */ + GsdkAlias: string; + /** + * The name of the game certificate. This name should match the name of a certificate that was previously uploaded to this + * title. + */ + Name: string; + + } + + export interface GameSecretReference { + /** The name of the game secret. This name should match the name of a secret that was previously added to this title. */ + Name?: string; + + } + + export interface GameSecretReferenceParams { + /** The name of the game secret. This name should match the name of a secret that was previously added to this title. */ + Name: string; + + } + + export interface GetAssetDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The asset's file name to get the download URL for. */ + FileName: string; + + } + + export interface GetAssetDownloadUrlResponse extends PlayFabModule.IPlayFabResultCommon { + /** The asset's download URL. */ + AssetDownloadUrl?: string; + /** The asset's file name to get the download URL for. */ + FileName?: string; + + } + + export interface GetAssetUploadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The asset's file name to get the upload URL for. */ + FileName: string; + + } + + export interface GetAssetUploadUrlResponse extends PlayFabModule.IPlayFabResultCommon { + /** The asset's upload URL. */ + AssetUploadUrl?: string; + /** The asset's file name to get the upload URL for. */ + FileName?: string; + + } + + export interface GetBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias ID of the alias to perform the action on. */ + AliasId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetBuildRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the build to get. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetBuildResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * When true, assets will not be copied for each server inside the VM. All serverswill run from the same set of assets, or + * will have the same assets mounted in the container. + */ + AreAssetsReadonly?: boolean; + /** The guid string build ID of the build. */ + BuildId?: string; + /** The build name. */ + BuildName?: string; + /** The current build status. Valid values are - Deploying, Deployed, DeletingRegion, Unhealthy. */ + BuildStatus?: string; + /** The flavor of container of he build. */ + ContainerFlavor?: string; + /** + * The container command to run when the multiplayer server has been allocated, including any arguments. This only applies + * to custom builds. If the build is a managed build, this field will be null. + */ + ContainerRunCommand?: string; + /** The time the build was created in UTC. */ + CreationTime?: string; + /** The custom game container image for a custom build. */ + CustomGameContainerImage?: ContainerImageReference; + /** The game assets for the build. */ + GameAssetReferences?: AssetReference[]; + /** The game certificates for the build. */ + GameCertificateReferences?: GameCertificateReference[]; + /** The game secrets for the build. */ + GameSecretReferences?: GameSecretReference[]; + /** The instrumentation configuration of the build. */ + InstrumentationConfiguration?: InstrumentationConfiguration; + /** + * Metadata of the build. The keys are case insensitive. The build metadata is made available to the server through Game + * Server SDK (GSDK). + */ + Metadata?: { [key: string]: string | null }; + /** The number of multiplayer servers to hosted on a single VM of the build. */ + MultiplayerServerCountPerVm: number; + /** The OS platform used for running the game process. */ + OsPlatform?: string; + /** The ports the build is mapped on. */ + Ports?: Port[]; + /** The region configuration for the build. */ + RegionConfigurations?: BuildRegion[]; + /** The resource constraints to apply to each server on the VM. */ + ServerResourceConstraints?: ServerResourceConstraintParams; + /** The type of game server being hosted. */ + ServerType?: string; + /** + * The command to run when the multiplayer server has been allocated, including any arguments. This only applies to managed + * builds. If the build is a custom build, this field will be null. + */ + StartMultiplayerServerCommand?: string; + /** The VM size the build was created on. */ + VmSize?: string; + /** The configuration for the VmStartupScript feature for the build */ + VmStartupScriptConfiguration?: VmStartupScriptConfiguration; + + } + + export interface GetContainerRegistryCredentialsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetContainerRegistryCredentialsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The url of the container registry. */ + DnsName?: string; + /** The password for accessing the container registry. */ + Password?: string; + /** The username for accessing the container registry. */ + Username?: string; + + } + + export interface GetLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + + } + + export interface GetLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** The information pertaining to the requested lobby. */ + Lobby: Lobby; + + } + + export interface GetMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Id of the matchmaking queue to retrieve. */ + QueueName?: string; + + } + + export interface GetMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + /** The matchmaking queue config. */ + MatchmakingQueue?: MatchmakingQueueConfig; + + } + + export interface GetMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The name of the queue to find a match for. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** + * The reason why the current ticket was canceled. This field is only set if the ticket is in canceled state. Please retry + * if CancellationReason is RetryRequired. + */ + CancellationReasonString?: string; + /** Change number used for differentiating older matchmaking status updates from newer ones. */ + ChangeNumber?: number; + /** The server date and time at which ticket was created. */ + Created: string; + /** The Creator's entity key. */ + Creator: EntityKey; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The Id of a match. */ + MatchId?: string; + /** A list of Users that have joined this ticket. */ + Members: MatchmakingPlayer[]; + /** A list of PlayFab Ids of Users to match with. */ + MembersToMatchWith?: EntityKey[]; + /** The Id of a match queue. */ + QueueName: string; + /** + * The current ticket status. Possible values are: WaitingForPlayers, WaitingForMatch, WaitingForServer, Canceled and + * Matched. + */ + Status: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetMatchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The Id of a match. */ + MatchId: string; + /** The name of the queue to join. */ + QueueName: string; + /** Determines whether the matchmaking attributes for each user should be returned in the response for match request. */ + ReturnMemberAttributes: boolean; + + } + + export interface GetMatchResult extends PlayFabModule.IPlayFabResultCommon { + /** A string that is used by players that are matched together to join an arranged lobby. */ + ArrangementString?: string; + /** The Id of a match. */ + MatchId: string; + /** A list of Users that are matched together, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** + * A list of regions that the match could be played in sorted by preference. This value is only set if the queue has a + * region selection rule. + */ + RegionPreferences?: string[]; + /** The details of the server that the match has been allocated to. */ + ServerDetails?: ServerDetails; + + } + + export interface GetMultiplayerServerDetailsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The title generated guid string session ID of the multiplayer server to get details for. This is to keep track of + * multiplayer server sessions. + */ + SessionId: string; + + } + + export interface GetMultiplayerServerDetailsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The identity of the build in which the server was allocated. */ + BuildId?: string; + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + FQDN?: string; + /** The public IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The list of public Ipv4 addresses associated with the server. */ + PublicIPV4Addresses?: PublicIpAddress[]; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + export interface GetMultiplayerServerLogsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The server ID of multiplayer server to get logs for. */ + ServerId: string; + + } + + export interface GetMultiplayerServerLogsResponse extends PlayFabModule.IPlayFabResultCommon { + /** URL for logs download. */ + LogDownloadUrl?: string; + + } + + export interface GetMultiplayerSessionLogsBySessionIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The server ID of multiplayer server to get logs for. */ + SessionId: string; + + } + + export interface GetQueueStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the queue. */ + QueueName: string; + + } + + export interface GetQueueStatisticsResult extends PlayFabModule.IPlayFabResultCommon { + /** The current number of players in the matchmaking queue, who are waiting to be matched. */ + NumberOfPlayersMatching?: number; + /** Statistics representing the time (in seconds) it takes for tickets to find a match. */ + TimeToMatchStatisticsInSeconds?: Statistics; + + } + + export interface GetRemoteLoginEndpointRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer server to get remote login information for. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The region of the multiplayer server to get remote login information for. */ + Region: string; + /** The virtual machine ID the multiplayer server is located on. */ + VmId: string; + + } + + export interface GetRemoteLoginEndpointResponse extends PlayFabModule.IPlayFabResultCommon { + /** The remote login IPV4 address of multiplayer server. */ + IPV4Address?: string; + /** The remote login port of multiplayer server. */ + Port: number; + + } + + export interface GetServerBackfillTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the matchmaking attributes will be returned as an escaped JSON string or as an un-escaped JSON + * object. + */ + EscapeObject: boolean; + /** The name of the queue to find a match for. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetServerBackfillTicketResult extends PlayFabModule.IPlayFabResultCommon { + /** The reason why the current ticket was canceled. This field is only set if the ticket is in canceled state. */ + CancellationReasonString?: string; + /** The server date and time at which ticket was created. */ + Created: string; + /** How long to attempt matching this ticket in seconds. */ + GiveUpAfterSeconds: number; + /** The Id of a match. */ + MatchId?: string; + /** A list of Users that are part of this ticket, along with their team assignments. */ + Members: MatchmakingPlayerWithTeamAssignment[]; + /** The Id of a match queue. */ + QueueName: string; + /** The details of the server the members are connected to. */ + ServerDetails: ServerDetails; + /** The current ticket status. Possible values are: WaitingForMatch, Canceled and Matched. */ + Status: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface GetTitleEnabledForMultiplayerServersStatusRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetTitleEnabledForMultiplayerServersStatusResponse extends PlayFabModule.IPlayFabResultCommon { + /** The enabled status for the multiplayer server features for the title. */ + Status?: string; + + } + + export interface GetTitleMultiplayerServersQuotaChangeRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the change request to get. */ + RequestId: string; + + } + + export interface GetTitleMultiplayerServersQuotaChangeResponse extends PlayFabModule.IPlayFabResultCommon { + /** The change request for this title. */ + Change?: QuotaChange; + + } + + export interface GetTitleMultiplayerServersQuotasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface GetTitleMultiplayerServersQuotasResponse extends PlayFabModule.IPlayFabResultCommon { + /** The various quotas for multiplayer servers for the title. */ + Quotas?: TitleMultiplayerServersQuotas; + + } + + export interface InstrumentationConfiguration { + /** Designates whether windows instrumentation configuration will be enabled for this Build */ + IsEnabled?: boolean; + /** + * This property is deprecated, use IsEnabled. The list of processes to be monitored on a VM for this build. Providing + * processes will turn on performance metrics collection for this build. Process names should not include extensions. If + * the game server process is: GameServer.exe; then, ProcessesToMonitor = [ GameServer ] + */ + ProcessesToMonitor?: string[]; + + } + + export interface InviteToLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity invited to the lobby. */ + InviteeEntity?: EntityKey; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity sending the invite. Must be a member of the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface JoinArrangedLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** + * A field which indicates which lobby the user will be joining. This field is opaque to everyone except the Lobby service + * and the creator of the arrangementString (Matchmaking). This string defines a unique identifier for the arranged lobby + * as well as the title and member the string is valid for. Arrangement strings have an expiration. + */ + ArrangementString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The maximum number of players allowed in the lobby. The value must be between 2 and 128. */ + MaxPlayers: number; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Visible to all + * entities in the lobby. At most 30 key-value pairs may be stored here, keys are limited to 30 characters and values to + * 1000. The total size of all memberData values may not exceed 4096 bytes. Keys are case sensitive. + */ + MemberData?: { [key: string]: string | null }; + /** The member entity who is joining the lobby. The first member to join will be the lobby owner. */ + MemberEntity: EntityKey; + /** + * The policy for how a new owner is chosen. May be 'Automatic', 'Manual' or 'None'. Can only be specified by clients. If + * client-owned and 'Automatic' - The Lobby service will automatically assign another connected owner when the current + * owner leaves or disconnects. The useConnections property must be true. If client - owned and 'Manual' - Ownership is + * protected as long as the current owner is connected. If the current owner leaves or disconnects any member may set + * themselves as the current owner. The useConnections property must be true. If client-owned and 'None' - Any member can + * set ownership. The useConnections property can be either true or false. + */ + OwnerMigrationPolicy?: string; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Defaults to false if not specified. + * Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner: boolean; + /** + * A setting to control whether connections are used. Defaults to true. When true, notifications are sent to subscribed + * players, disconnect detection removes connectionHandles, only owner migration policies using connections are allowed, + * and lobbies must have at least one connected member to be searchable or be a server hosted lobby with a connected + * server. If false, then notifications are not sent, connections are not allowed, and lobbies do not need connections to + * be searchable. + */ + UseConnections: boolean; + + } + + export interface JoinLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * A field which indicates which lobby the game_server will be joining. This field is opaque to everyone except the Lobby + * service. + */ + ConnectionString: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby but can only be modified by the joined + * server.At most 30 key - value pairs may be stored here, keys are limited to 30 characters and values to 1000.The total + * size of all serverData values may not exceed 4096 bytes. + */ + ServerData?: { [key: string]: string | null }; + /** + * The game_server entity which is joining the Lobby. If a different game_server entity has already joined the request will + * fail unless the joined entity is disconnected, in which case the incoming game_server entity will replace the + * disconnected entity. + */ + ServerEntity: EntityKey; + + } + + export interface JoinLobbyAsServerResult extends PlayFabModule.IPlayFabResultCommon { + /** Successfully joined lobby's id. */ + LobbyId: string; + + } + + export interface JoinLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** A field which indicates which lobby the user will be joining. This field is opaque to everyone except the Lobby service. */ + ConnectionString?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Visible to all + * entities in the lobby. At most 30 key-value pairs may be stored here, keys are limited to 30 characters and values to + * 1000. The total size of all memberData values may not exceed 4096 bytes.Keys are case sensitive. + */ + MemberData?: { [key: string]: string | null }; + /** The member entity who is joining the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface JoinLobbyResult extends PlayFabModule.IPlayFabResultCommon { + /** Successfully joined lobby's id. */ + LobbyId: string; + + } + + export interface JoinMatchmakingTicketRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The User who wants to join the ticket. Their Id must be listed in PlayFabIdsToMatchWith. */ + Member: MatchmakingPlayer; + /** The name of the queue to join. */ + QueueName: string; + /** The Id of the ticket to find a match for. */ + TicketId: string; + + } + + export interface JoinMatchmakingTicketResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LeaveLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId: string; + /** + * The game_server entity leaving the lobby. If the game_server was subscribed to notifications, it will be unsubscribed. + * If a the given game_server entity is not in the lobby, it will fail. + */ + ServerEntity: EntityKey; + + } + + export interface LeaveLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity leaving the lobby. */ + MemberEntity?: EntityKey; + + } + + export interface LinearDifferenceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearRegionSelectionRuleExpansion { + /** This value gets added to MaxLatency at every expansion interval. */ + Delta: number; + /** Once the max Latency reaches this value, expansion stops. */ + Limit: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearSetIntersectionRuleExpansion { + /** This value gets added to MinIntersectionSize at every expansion interval. */ + Delta: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearTeamDifferenceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinearTeamSizeBalanceRuleExpansion { + /** This value gets added to Difference at every expansion interval. */ + Delta: number; + /** Once the total difference reaches this value, expansion stops. Optional. */ + Limit?: number; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface LinuxInstrumentationConfiguration { + /** Designates whether Linux instrumentation configuration will be enabled for this Build */ + IsEnabled: boolean; + + } + + export interface ListAssetSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListAssetSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of asset summaries. */ + AssetSummaries?: AssetSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListBuildAliasesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListBuildAliasesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of build aliases for the title */ + BuildAliases?: BuildAliasDetailsResponse[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListBuildSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListBuildSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of build summaries for a title. */ + BuildSummaries?: BuildSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListCertificateSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListCertificateSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of game certificates. */ + CertificateSummaries?: CertificateSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListContainerImagesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListContainerImagesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of container images. */ + Images?: string[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListContainerImageTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container images we want to list tags for. */ + ImageName?: string; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListContainerImageTagsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** The list of tags for a particular container image. */ + Tags?: string[]; + + } + + export interface ListMatchmakingQueuesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListMatchmakingQueuesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of matchmaking queue configs for this title. */ + MatchMakingQueues?: MatchmakingQueueConfig[]; + + } + + export interface ListMatchmakingTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The name of the queue to find a match for. */ + QueueName: string; + + } + + export interface ListMatchmakingTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of ticket Ids the user is a member of. */ + TicketIds: string[]; + + } + + export interface ListMultiplayerServersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the multiplayer servers to list. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The region the multiplayer servers to list. */ + Region: string; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListMultiplayerServersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of multiplayer server summary details. */ + MultiplayerServerSummaries?: MultiplayerServerSummary[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListPartyQosServersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListPartyQosServersResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of QoS servers. */ + QosServers?: QosServer[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListQosServersForTitleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates that the response should contain Qos servers for all regions, including those where there are no builds + * deployed for the title. + */ + IncludeAllRegions?: boolean; + /** Indicates the Routing Preference used by the Qos servers. The default Routing Preference is Microsoft */ + RoutingPreference?: string; + + } + + export interface ListQosServersForTitleResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of QoS servers. */ + QosServers?: QosServer[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListSecretSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListSecretSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The list of game secret. */ + SecretSummaries?: SecretSummary[]; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListServerBackfillTicketsForPlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The name of the queue the tickets are in. */ + QueueName: string; + + } + + export interface ListServerBackfillTicketsForPlayerResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of backfill ticket Ids the user is a member of. */ + TicketIds: string[]; + + } + + export interface ListTitleMultiplayerServersQuotaChangesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface ListTitleMultiplayerServersQuotaChangesResponse extends PlayFabModule.IPlayFabResultCommon { + /** All change requests for this title. */ + Changes?: QuotaChange[]; + + } + + export interface ListVirtualMachineSummariesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string build ID of the virtual machines to list. */ + BuildId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The region of the virtual machines to list. */ + Region: string; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListVirtualMachineSummariesResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** The list of virtual machine summaries. */ + VirtualMachines?: VirtualMachineSummary[]; + + } + + export interface Lobby { + /** A setting indicating who is allowed to join this lobby, as well as see it in queries. */ + AccessPolicy: string; + /** A number that increments once for each request that modifies the lobby. */ + ChangeNumber: number; + /** + * A string used to join the lobby. This field is populated by the Lobby service. Invites are performed by communicating + * this connectionString to other players. + */ + ConnectionString: string; + /** Lobby data. */ + LobbyData?: { [key: string]: string | null }; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** Array of all lobby members. */ + Members?: Member[]; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock: string; + /** The client or server entity which owns this lobby. */ + Owner?: EntityKey; + /** A setting indicating the owner migration policy. If server owned, this field is not present. */ + OwnerMigrationPolicy?: string; + /** + * An opaque string stored on a SubscribeToLobbyResource call, which indicates the connection an owner or member has with + * PubSub. + */ + PubSubConnectionHandle?: string; + /** + * A setting that controls lobby invites. When true only owners can invite new players, when false all members area allowed + * to invite. + */ + RestrictInvitesToLobbyOwner: boolean; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + /** Preview: Lobby joined server. This is not the server owner, rather the server that has joined a client owned lobby. */ + Server?: LobbyServer; + /** A flag which determines if connections are used. Defaults to true. Only set on create. */ + UseConnections: boolean; + + } + + export interface LobbyEmptyResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface LobbyServer { + /** Opaque string, stored on a Subscribe call, which indicates the connection a joined server has with PubSub. */ + PubSubConnectionHandle?: string; + /** Key-value pairs specific to the joined server. */ + ServerData?: { [key: string]: string | null }; + /** The server entity key. */ + ServerEntity?: EntityKey; + + } + + export interface LobbySummary { + /** + * A string used to join the lobby.This field is populated by the Lobby service.Invites are performed by communicating this + * connectionString to other players. + */ + ConnectionString: string; + /** The current number of players in the lobby. */ + CurrentPlayers: number; + /** Id to uniquely identify a lobby. */ + LobbyId: string; + /** The maximum number of players allowed in the lobby. */ + MaxPlayers: number; + /** A setting indicating whether members are allowed to join this lobby. When Locked new members are prevented from joining. */ + MembershipLock?: string; + /** The client or server entity which owns this lobby. */ + Owner: EntityKey; + /** Search data. */ + SearchData?: { [key: string]: string | null }; + + } + + export interface MatchmakingPlayer { + /** The user's attributes custom to the title. */ + Attributes?: MatchmakingPlayerAttributes; + /** The entity key of the matchmaking user. */ + Entity: EntityKey; + + } + + export interface MatchmakingPlayerAttributes { + /** A data object representing a user's attributes. */ + DataObject?: any; + /** An escaped data object representing a user's attributes. */ + EscapedDataObject?: string; + + } + + export interface MatchmakingPlayerWithTeamAssignment { + /** + * The user's attributes custom to the title. These attributes will be null unless the request has ReturnMemberAttributes + * flag set to true. + */ + Attributes?: MatchmakingPlayerAttributes; + /** The entity key of the matchmaking user. */ + Entity: EntityKey; + /** The Id of the team the User is assigned to. */ + TeamId?: string; + + } + + export interface MatchmakingQueueConfig { + /** This is the buildAlias that will be used to allocate the multiplayer server for the match. */ + BuildAliasParams?: BuildAliasParams; + /** This is the buildId that will be used to allocate the multiplayer server for the match. */ + BuildId?: string; + /** List of difference rules used to find an optimal match. */ + DifferenceRules?: DifferenceRule[]; + /** List of match total rules used to find an optimal match. */ + MatchTotalRules?: MatchTotalRule[]; + /** Maximum number of players in a match. */ + MaxMatchSize: number; + /** Maximum number of players in a ticket. Optional. */ + MaxTicketSize?: number; + /** Minimum number of players in a match. */ + MinMatchSize: number; + /** Unique identifier for a Queue. Chosen by the developer. */ + Name: string; + /** Region selection rule used to find an optimal match. */ + RegionSelectionRule?: RegionSelectionRule; + /** Boolean flag to enable server allocation for the queue. */ + ServerAllocationEnabled: boolean; + /** List of set intersection rules used to find an optimal match. */ + SetIntersectionRules?: SetIntersectionRule[]; + /** Controls which statistics are visible to players. */ + StatisticsVisibilityToPlayers?: StatisticsVisibilityToPlayers; + /** List of string equality rules used to find an optimal match. */ + StringEqualityRules?: StringEqualityRule[]; + /** List of team difference rules used to find an optimal match. */ + TeamDifferenceRules?: TeamDifferenceRule[]; + /** The team configuration for a match. This may be null if there are no teams. */ + Teams?: MatchmakingQueueTeam[]; + /** Team size balance rule used to find an optimal match. */ + TeamSizeBalanceRule?: TeamSizeBalanceRule; + /** Team ticket size similarity rule used to find an optimal match. */ + TeamTicketSizeSimilarityRule?: TeamTicketSizeSimilarityRule; + + } + + export interface MatchmakingQueueTeam { + /** The maximum number of players required for the team. */ + MaxTeamSize: number; + /** The minimum number of players required for the team. */ + MinTeamSize: number; + /** A name to identify the team. This is case insensitive. */ + Name: string; + + } + + export interface MatchTotalRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** Collection of fields relating to expanding this rule at set intervals. */ + Expansion?: MatchTotalRuleExpansion; + /** The maximum total value for a group. Must be >= Min. */ + Max: number; + /** The minimum total value for a group. Must be >=2. */ + Min: number; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface MatchTotalRuleExpansion { + /** Manually specify the values to use for each expansion interval. When this is set, Max is ignored. */ + MaxOverrides?: OverrideDouble[]; + /** Manually specify the values to use for each expansion interval. When this is set, Min is ignored. */ + MinOverrides?: OverrideDouble[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface Member { + /** Key-value pairs specific to member. */ + MemberData?: { [key: string]: string | null }; + /** The member entity key. */ + MemberEntity?: EntityKey; + /** Opaque string, stored on a Subscribe call, which indicates the connection an owner or member has with PubSub. */ + PubSubConnectionHandle?: string; + + } + + type MembershipLock = "Unlocked" + + | "Locked"; + + export interface MultiplayerServerSummary { + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The title generated guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + type OsPlatform = "Windows" + + | "Linux"; + + export interface OverrideDouble { + /** The custom expansion value. */ + Value: number; + + } + + export interface OverrideUnsignedInt { + /** The custom expansion value. */ + Value: number; + + } + + type OwnerMigrationPolicy = "None" + + | "Automatic" + | "Manual" + | "Server"; + + export interface PaginationRequest { + /** Continuation token returned as a result in a previous FindLobbies call. Cannot be specified by clients. */ + ContinuationToken?: string; + /** The number of lobbies that should be retrieved. Cannot be specified by servers, clients may specify any value up to 50 */ + PageSizeRequested?: number; + + } + + export interface PaginationResponse { + /** Continuation token returned by server call. Not returned for clients */ + ContinuationToken?: string; + /** The number of lobbies that matched the search request. */ + TotalMatchedLobbyCount?: number; + + } + + export interface PartyInvitationConfiguration { + /** + * The list of PlayFab EntityKeys that the invitation allows to authenticate into the network. If this list is empty, all + * users are allowed to authenticate using the invitation's identifier. This list may contain no more than 1024 items. + */ + EntityKeys?: EntityKey[]; + /** The invite identifier for this party. If this value is specified, it must be no longer than 127 characters. */ + Identifier?: string; + /** Controls which participants can revoke this invite. */ + Revocability?: string; + + } + + type PartyInvitationRevocability = "Creator" + + | "Anyone"; + + export interface PartyNetworkConfiguration { + /** Controls whether and how to support direct peer-to-peer connection attempts among devices in the network. */ + DirectPeerConnectivityOptions?: string; + /** The maximum number of devices allowed to connect to the network. Must be between 1 and 128, inclusive. */ + MaxDevices: number; + /** The maximum number of devices allowed per user. Must be greater than 0. */ + MaxDevicesPerUser: number; + /** The maximum number of endpoints allowed per device. Must be between 0 and 32, inclusive. */ + MaxEndpointsPerDevice: number; + /** The maximum number of unique users allowed in the network. Must be greater than 0. */ + MaxUsers: number; + /** The maximum number of users allowed per device. Must be between 1 and 8, inclusive. */ + MaxUsersPerDevice: number; + /** + * An optionally-specified configuration for the initial invitation for this party. If not provided, default configuration + * values will be used: a title-unique invitation identifier will be generated, the revocability will be Anyone, and the + * EntityID list will be empty. + */ + PartyInvitationConfiguration?: PartyInvitationConfiguration; + + } + + export interface Port { + /** The name for the port. */ + Name: string; + /** The number for the port. */ + Num: number; + /** The protocol for the port. */ + Protocol: string; + + } + + type ProtocolType = "TCP" + + | "UDP"; + + export interface PublicIpAddress { + /** FQDN of the public IP */ + FQDN: string; + /** Server IP Address */ + IpAddress: string; + /** Routing Type of the public IP. */ + RoutingType: string; + + } + + export interface QosServer { + /** The region the QoS server is located in. */ + Region?: string; + /** The QoS server URL. */ + ServerUrl?: string; + + } + + export interface QueueRuleAttribute { + /** Specifies which attribute in a ticket to use. */ + Path: string; + /** Specifies which source the attribute comes from. */ + Source: string; + + } + + export interface QuotaChange { + /** A brief description of the requested changes. */ + ChangeDescription?: string; + /** Requested changes to make to the titles cores quota. */ + Changes?: CoreCapacityChange[]; + /** Whether or not this request is pending a review. */ + IsPendingReview: boolean; + /** Additional information about this request that our team can use to better understand the requirements. */ + Notes?: string; + /** Id of the change request. */ + RequestId?: string; + /** Comments by our team when a request is reviewed. */ + ReviewComments?: string; + /** Whether or not this request was approved. */ + WasApproved: boolean; + + } + + export interface RegionSelectionRule { + /** + * Controls how the Max Latency parameter expands over time. Only one expansion can be set per rule. When this is set, + * MaxLatency is ignored. + */ + CustomExpansion?: CustomRegionSelectionRuleExpansion; + /** Controls how the Max Latency parameter expands over time. Only one expansion can be set per rule. */ + LinearExpansion?: LinearRegionSelectionRuleExpansion; + /** Specifies the maximum latency that is allowed between the client and the selected server. The value is in milliseconds. */ + MaxLatency: number; + /** Friendly name chosen by developer. */ + Name: string; + /** Specifies which attribute in a ticket to use. */ + Path: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface RemoveMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The Id of the matchmaking queue to remove. */ + QueueName?: string; + + } + + export interface RemoveMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface RemoveMemberFromLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId?: string; + /** The member entity to be removed from the lobby. */ + MemberEntity?: EntityKey; + /** If true, removed member can never rejoin this lobby. */ + PreventRejoin: boolean; + + } + + export interface RequestMultiplayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The identifiers of the build alias to use for the request. */ + BuildAliasParams?: BuildAliasParams; + /** The guid string build ID of the multiplayer server to request. */ + BuildId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Initial list of players (potentially matchmade) allowed to connect to the game. This list is passed to the game server + * when requested (via GSDK) and can be used to validate players connecting to it. + */ + InitialPlayers?: string[]; + /** + * The preferred regions to request a multiplayer server from. The Multiplayer Service will iterate through the regions in + * the specified order and allocate a server from the first one that has servers available. + */ + PreferredRegions: string[]; + /** + * Data encoded as a string that is passed to the game server when requested. This can be used to communicate information + * such as game mode or map through the request flow. Maximum size is 8KB + */ + SessionCookie?: string; + /** A guid string session ID created track the multiplayer server session over its life. */ + SessionId: string; + + } + + export interface RequestMultiplayerServerResponse extends PlayFabModule.IPlayFabResultCommon { + /** The identity of the build in which the server was allocated. */ + BuildId?: string; + /** The connected players in the multiplayer server. */ + ConnectedPlayers?: ConnectedPlayer[]; + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + FQDN?: string; + /** The public IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The time (UTC) at which a change in the multiplayer server state was observed. */ + LastStateTransitionTime?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The list of public Ipv4 addresses associated with the server. */ + PublicIPV4Addresses?: PublicIpAddress[]; + /** The region the multiplayer server is located in. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + /** The guid string session ID of the multiplayer server. */ + SessionId?: string; + /** The state of the multiplayer server. */ + State?: string; + /** The virtual machine ID that the multiplayer server is located on. */ + VmId?: string; + + } + + export interface RequestPartyServiceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The network configuration for this request. */ + NetworkConfiguration: PartyNetworkConfiguration; + /** A guid string party ID created track the party session over its life. */ + PartyId?: string; + /** A player entity Id on behalf of whom the request is being made. */ + PlayFabId?: string; + /** + * The preferred regions to request a party session from. The party service will iterate through the regions in the + * specified order and allocate a party session from the first one that is available. + */ + PreferredRegions: string[]; + + } + + export interface RequestPartyServiceResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The invitation identifier supplied in the PartyInvitationConfiguration, or the PlayFab-generated guid if none was + * supplied. + */ + InvitationId?: string; + /** The guid string party ID of the party session. */ + PartyId?: string; + /** The region the party session is located in. */ + Region?: string; + /** A base-64 encoded string containing the serialized network descriptor for this party. */ + SerializedNetworkDescriptor?: string; + + } + + export interface RolloverContainerRegistryCredentialsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface RolloverContainerRegistryCredentialsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The url of the container registry. */ + DnsName?: string; + /** The password for accessing the container registry. */ + Password?: string; + /** The username for accessing the container registry. */ + Username?: string; + + } + + type RoutingType = "Microsoft" + + | "Internet"; + + export interface Schedule { + /** A short description about this schedule. For example, "Game launch on July 15th". */ + Description?: string; + /** + * The date and time in UTC at which the schedule ends. If IsRecurringWeekly is true, this schedule will keep renewing for + * future weeks until disabled or removed. + */ + EndTime: string; + /** Disables the schedule. */ + IsDisabled: boolean; + /** If true, the StartTime and EndTime will get renewed every week. */ + IsRecurringWeekly: boolean; + /** The date and time in UTC at which the schedule starts. */ + StartTime: string; + /** The standby target to maintain for the duration of the schedule. */ + TargetStandby: number; + + } + + export interface ScheduledStandbySettings { + /** When true, scheduled standby will be enabled */ + IsEnabled: boolean; + /** A list of non-overlapping schedules */ + ScheduleList?: Schedule[]; + + } + + export interface Secret { + /** Optional secret expiration date. */ + ExpirationDate?: string; + /** A name for the secret. This is used to reference secrets in build configurations. */ + Name: string; + /** Secret value. */ + Value: string; + + } + + export interface SecretSummary { + /** Optional secret expiration date. */ + ExpirationDate?: string; + /** The name of the secret. */ + Name?: string; + /** The secret version auto-generated after upload. */ + Version?: string; + + } + + export interface ServerDetails { + /** The fully qualified domain name of the virtual machine that is hosting this multiplayer server. */ + Fqdn?: string; + /** The IPv4 address of the virtual machine that is hosting this multiplayer server. */ + IPV4Address?: string; + /** The ports the multiplayer server uses. */ + Ports?: Port[]; + /** The server's region. */ + Region?: string; + /** The string server ID of the multiplayer server generated by PlayFab. */ + ServerId?: string; + + } + + export interface ServerResourceConstraintParams { + /** The maximum number of cores that each server is allowed to use. */ + CpuLimit: number; + /** + * The maximum number of GiB of memory that each server is allowed to use. WARNING: After exceeding this limit, the server + * will be killed + */ + MemoryLimitGB: number; + + } + + type ServerType = "Container" + + | "Process"; + + export interface SetIntersectionRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, MinIntersectionSize is ignored. + */ + CustomExpansion?: CustomSetIntersectionRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is UseDefault). Values must be unique. + */ + DefaultAttributeValue?: string[]; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearSetIntersectionRuleExpansion; + /** The minimum number of values that must match between sets. */ + MinIntersectionSize: number; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface SetMatchmakingQueueRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The matchmaking queue config. */ + MatchmakingQueue: MatchmakingQueueConfig; + + } + + export interface SetMatchmakingQueueResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface ShutdownMultiplayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** A guid string session ID of the multiplayer server to shut down. */ + SessionId: string; + + } + + export interface Statistics { + /** The average. */ + Average: number; + /** The 50th percentile. */ + Percentile50: number; + /** The 90th percentile. */ + Percentile90: number; + /** The 99th percentile. */ + Percentile99: number; + + } + + export interface StatisticsVisibilityToPlayers { + /** Whether to allow players to view the current number of players in the matchmaking queue. */ + ShowNumberOfPlayersMatching: boolean; + /** Whether to allow players to view statistics representing the time it takes for tickets to find a match. */ + ShowTimeToMatch: boolean; + + } + + export interface StringEqualityRule { + /** Description of the attribute used by this rule to match tickets. */ + Attribute: QueueRuleAttribute; + /** + * Describes the behavior when an attribute is not specified in the ticket creation request or in the user's entity + * profile. + */ + AttributeNotSpecifiedBehavior: string; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). + */ + DefaultAttributeValue?: string; + /** + * Collection of fields relating to expanding this rule at set intervals. For StringEqualityRules, this is limited to + * turning the rule off or on during different intervals. + */ + Expansion?: StringEqualityRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + /** The relative weight of this rule compared to others. */ + Weight: number; + + } + + export interface StringEqualityRuleExpansion { + /** List of bools specifying whether the rule is applied during this expansion. */ + EnabledOverrides: boolean[]; + /** How many seconds before this rule is expanded. */ + SecondsBetweenExpansions: number; + + } + + export interface SubscribeToLobbyResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the subscription. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** + * The name of the resource to subscribe to. For LobbyChange subscriptions this is the lobbyId. For LobbyInvite + * subscriptions this should always be "@me". + */ + ResourceId: string; + /** Version number for the subscription of this resource. */ + SubscriptionVersion: number; + /** + * Subscription type. "LobbyChange" subscriptions allow a member or owner to receive notifications of lobby data, member or + * owner changes. "LobbyInvite" subscriptions allow a player to receive invites to lobbies. A player does not need to be a + * member of a lobby to receive lobby invites. + */ + Type: string; + + } + + export interface SubscribeToLobbyResourceResult extends PlayFabModule.IPlayFabResultCommon { + /** Topic will be returned in all notifications that are the result of this subscription. */ + Topic: string; + + } + + export interface SubscribeToMatchResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the subscription. The entity must be authorized to use this connectionHandle. */ + EntityKey: EntityKey; + /** + * Opaque string, given to a client upon creating a connection with PubSub. Notifications will be sent to the connection + * associated with this handle. + */ + PubSubConnectionHandle: string; + /** + * The name of the resource to subscribe to. It follows the format {queueName}|{ticketId} for MatchTicketStatusChange. For + * MatchInvite, ResourceId is @me. + */ + ResourceId: string; + /** Version number for the subscription of this resource. Current supported version must be 1. */ + SubscriptionVersion: number; + /** + * Subscription type. MatchInvite subscriptions are per-player. MatchTicketStatusChange subscriptions are per-ticket. + * Subscribe calls are idempotent. Subscribing on the same resource for the same connection results in success. + */ + Type: string; + + } + + export interface SubscribeToMatchResourceResult extends PlayFabModule.IPlayFabResultCommon { + /** Matchmaking resource */ + Topic: string; + + } + + type SubscriptionType = "LobbyChange" + + | "LobbyInvite"; + + export interface TeamDifferenceRule { + /** Description of the attribute used by this rule to match teams. */ + Attribute: QueueRuleAttribute; + /** + * Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. When this + * is set, Difference is ignored. + */ + CustomExpansion?: CustomTeamDifferenceRuleExpansion; + /** + * The default value assigned to tickets that are missing the attribute specified by AttributePath (assuming that + * AttributeNotSpecifiedBehavior is false). + */ + DefaultAttributeValue: number; + /** The allowed difference between any two teams at the start of matchmaking. */ + Difference: number; + /** Collection of fields relating to expanding this rule at set intervals. Only one expansion can be set per rule. */ + LinearExpansion?: LinearTeamDifferenceRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + export interface TeamSizeBalanceRule { + /** + * Controls how the Difference parameter expands over time. Only one expansion can be set per rule. When this is set, + * Difference is ignored. + */ + CustomExpansion?: CustomTeamSizeBalanceRuleExpansion; + /** The allowed difference in team size between any two teams. */ + Difference: number; + /** Controls how the Difference parameter expands over time. Only one expansion can be set per rule. */ + LinearExpansion?: LinearTeamSizeBalanceRuleExpansion; + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + export interface TeamTicketSizeSimilarityRule { + /** Friendly name chosen by developer. */ + Name: string; + /** + * How many seconds before this rule is no longer enforced (but tickets that comply with this rule will still be + * prioritized over those that don't). Leave blank if this rule is always enforced. + */ + SecondsUntilOptional?: number; + + } + + type TitleMultiplayerServerEnabledStatus = "Initializing" + + | "Enabled" + | "Disabled"; + + export interface TitleMultiplayerServersQuotas { + /** The core capacity for the various regions and VM Family */ + CoreCapacities?: CoreCapacity[]; + + } + + export interface UnsubscribeFromLobbyResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity which performed the subscription. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** The name of the resource to unsubscribe from. */ + ResourceId: string; + /** Version number passed for the subscription of this resource. */ + SubscriptionVersion: number; + /** Subscription type. */ + Type: string; + + } + + export interface UnsubscribeFromMatchResourceRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity performing the unsubscription. The entity must be authorized to use this connectionHandle. */ + EntityKey: EntityKey; + /** Opaque string, given to a client upon creating a connection with PubSub. */ + PubSubConnectionHandle: string; + /** + * The name of the resource to unsubscribe from. It follows the format {queueName}|{ticketId} for MatchTicketStatusChange. + * For MatchInvite, ResourceId is @me. + */ + ResourceId: string; + /** Version number for the unsubscription from this resource. */ + SubscriptionVersion: number; + /** Type of the subscription to be canceled. */ + Type: string; + + } + + export interface UnsubscribeFromMatchResourceResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UntagContainerImageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The container image which tag we want to remove. */ + ImageName?: string; + /** The tag we want to remove. */ + Tag?: string; + + } + + export interface UpdateBuildAliasRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string alias Id of the alias to be updated. */ + AliasId: string; + /** The alias name. */ + AliasName?: string; + /** Array of build selection criteria. */ + BuildSelectionCriteria?: BuildSelectionCriterion[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildNameRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update the name of. */ + BuildId: string; + /** The build name. */ + BuildName: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildRegionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The updated region configuration that should be applied to the specified build. */ + BuildRegion: BuildRegionParams; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateBuildRegionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The guid string ID of the build we want to update regions for. */ + BuildId: string; + /** The updated region configuration that should be applied to the specified build. */ + BuildRegions: BuildRegionParams[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + + } + + export interface UpdateLobbyAsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The id of the lobby. */ + LobbyId: string; + /** + * The private key-value pairs which are visible to all entities in the lobby and modifiable by the joined server. + * Optional. Sets or updates key-value pairs on the lobby. Only the current lobby lobby server can set serverData. Keys may + * be an arbitrary string of at most 30 characters. The total size of all serverData values may not exceed 4096 bytes. + * Values are not individually limited. There can be up to 30 key-value pairs stored here. Keys are case sensitive. + */ + ServerData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby serverData. Optional. Optional. Deletes key-value pairs on the lobby. Only the current + * joined lobby server can delete serverData. All the specified keys will be removed from the serverData. Keys that do not + * exist in the lobby are a no-op. If the key to delete exists in the serverData (same request) it will result in a bad + * request. + */ + ServerDataToDelete?: string[]; + /** + * The lobby server. Optional. Set a different server as the joined server of the lobby (there can only be 1 joined + * server). When changing the server the previous server will automatically be unsubscribed. + */ + ServerEntity?: EntityKey; + + } + + export interface UpdateLobbyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * The policy indicating who is allowed to join the lobby, and the visibility to queries. May be 'Public', 'Friends' or + * 'Private'. Public means the lobby is both visible in queries and any player may join, including invited players. Friends + * means that users who are bidirectional friends of members in the lobby may search to find friend lobbies, to retrieve + * its connection string. Private means the lobby is not visible in queries, and a player must receive an invitation to + * join. Defaults to 'Public' on creation. Can only be changed by the lobby owner. + */ + AccessPolicy?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The private key-value pairs which are visible to all entities in the lobby. Optional. Sets or updates key-value pairs on + * the lobby. Only the current lobby owner can set lobby data. Keys may be an arbitrary string of at most 30 characters. + * The total size of all lobbyData values may not exceed 4096 bytes. Values are not individually limited. There can be up + * to 30 key-value pairs stored here. Keys are case sensitive. + */ + LobbyData?: { [key: string]: string | null }; + /** The keys to delete from the lobby LobbyData. Optional. Behaves similar to searchDataToDelete, but applies to lobbyData. */ + LobbyDataToDelete?: string[]; + /** The id of the lobby. */ + LobbyId?: string; + /** + * The maximum number of players allowed in the lobby. Updates the maximum allowed number of players in the lobby. Only the + * current lobby owner can set this. If set, the value must be greater than or equal to the number of members currently in + * the lobby. + */ + MaxPlayers?: number; + /** + * The private key-value pairs used by the member to communicate information to other members and the owner. Optional. Sets + * or updates new key-value pairs on the caller's member data. New keys will be added with their values and existing keys + * will be updated with the new values. Visible to all entities in the lobby. At most 30 key-value pairs may be stored + * here, keys are limited to 30 characters and values to 1000. The total size of all memberData values may not exceed 4096 + * bytes. Keys are case sensitive. Servers cannot specifiy this. + */ + MemberData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby MemberData. Optional. Deletes key-value pairs on the caller's member data. All the + * specified keys will be removed from the caller's member data. Keys that do not exist are a no-op. If the key to delete + * exists in the memberData (same request) it will result in a bad request. Servers cannot specifiy this. + */ + MemberDataToDelete?: string[]; + /** The member entity whose data is being modified. Servers cannot specify this. */ + MemberEntity?: EntityKey; + /** + * A setting indicating whether the lobby is locked. May be 'Unlocked' or 'Locked'. When Locked new members are not allowed + * to join. Defaults to 'Unlocked' on creation. Can only be changed by the lobby owner. + */ + MembershipLock?: string; + /** + * The lobby owner. Optional. Set to transfer ownership of the lobby. If client - owned and 'Automatic' - The Lobby service + * will automatically assign another connected owner when the current owner leaves or disconnects. useConnections must be + * true. If client - owned and 'Manual' - Ownership is protected as long as the current owner is connected. If the current + * owner leaves or disconnects any member may set themselves as the current owner. The useConnections property must be + * true. If client-owned and 'None' - Any member can set ownership. The useConnections property can be either true or + * false. For all client-owned lobbies when the owner leaves and a new owner can not be automatically selected - The owner + * field is set to null. For all client-owned lobbies when the owner disconnects and a new owner can not be automatically + * selected - The owner field remains unchanged and the current owner retains all owner abilities for the lobby. If + * server-owned (must be 'Server') - Any server can set ownership. The useConnections property must be true. + */ + Owner?: EntityKey; + /** + * A setting that controls whether only the lobby owner can send invites to join the lobby. When true, only the lobby owner + * can send invites. When false or not specified, any member can send invites. Will not modify current configuration if not + * specified. Restricted to client owned lobbies. + */ + RestrictInvitesToLobbyOwner?: boolean; + /** + * The public key-value pairs which allow queries to differentiate between lobbies. Optional. Sets or updates key-value + * pairs on the lobby for use with queries. Only the current lobby owner can set search data. New keys will be added with + * their values and existing keys will be updated with the new values. There can be up to 30 key-value pairs stored here. + * Keys are of the format string_key1, string_key2... string_key30 for string values, or number_key1, number_key2, ... + * number_key30 for numeric values. Numeric values are floats. Values can be at most 256 characters long. The total size of + * all searchData values may not exceed 1024 bytes.Keys are case sensitive. + */ + SearchData?: { [key: string]: string | null }; + /** + * The keys to delete from the lobby SearchData. Optional. Deletes key-value pairs on the lobby. Only the current lobby + * owner can delete search data. All the specified keys will be removed from the search data. Keys that do not exist in the + * lobby are a no-op.If the key to delete exists in the searchData (same request) it will result in a bad request. + */ + SearchDataToDelete?: string[]; + + } + + export interface UploadCertificateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Forces the certificate renewal if the certificate already exists. Default is false */ + ForceUpdate?: boolean; + /** The game certificate to upload. */ + GameCertificate: Certificate; + + } + + export interface UploadSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Forces the secret renewal if the secret already exists. Default is false */ + ForceUpdate?: boolean; + /** The game secret to add. */ + GameSecret: Secret; + + } + + export interface VirtualMachineSummary { + /** The virtual machine health status. */ + HealthStatus?: string; + /** The virtual machine state. */ + State?: string; + /** The virtual machine ID. */ + VmId?: string; + + } + + export interface VmStartupScriptConfiguration { + /** Optional port requests (name/protocol) that will be used by the VmStartupScript. Max of 5 requests. */ + PortRequests?: VmStartupScriptPortRequest[]; + /** Asset which contains the VmStartupScript script and any other required files. */ + VmStartupScriptAssetReference: AssetReference; + + } + + export interface VmStartupScriptParams { + /** Optional port requests (name/protocol) that will be used by the VmStartupScript. Max of 5 requests. */ + PortRequests?: VmStartupScriptPortRequestParams[]; + /** Asset which contains the VmStartupScript script and any other required files. */ + VmStartupScriptAssetReference: AssetReferenceParams; + + } + + export interface VmStartupScriptPortRequest { + /** The name for the port. */ + Name: string; + /** The protocol for the port. */ + Protocol: string; + + } + + export interface VmStartupScriptPortRequestParams { + /** The name for the port. */ + Name: string; + /** The protocol for the port. */ + Protocol: string; + + } + + export interface WindowsCrashDumpConfiguration { + /** See https://docs.microsoft.com/en-us/windows/win32/wer/collecting-user-mode-dumps for valid values. */ + CustomDumpFlags?: number; + /** See https://docs.microsoft.com/en-us/windows/win32/wer/collecting-user-mode-dumps for valid values. */ + DumpType?: number; + /** Designates whether automatic crash dump capturing will be enabled for this Build. */ + IsEnabled: boolean; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabProfilesApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabProfilesApi.d.ts new file mode 100644 index 00000000..ce708bfc --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabProfilesApi.d.ts @@ -0,0 +1,370 @@ +/// + +declare module PlayFabProfilesModule { + export interface IPlayFabProfiles { + ForgetAllCredentials(): void; + + /** + * Gets the global title access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getglobalpolicy + */ + GetGlobalPolicy(request: PlayFabProfilesModels.GetGlobalPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the entity's profile. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getprofile + */ + GetProfile(request: PlayFabProfilesModels.GetEntityProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the entity's profile. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/getprofiles + */ + GetProfiles(request: PlayFabProfilesModels.GetEntityProfilesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title player accounts associated with the given master player account. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/gettitleplayersfrommasterplayeraccountids + */ + GetTitlePlayersFromMasterPlayerAccountIds(request: PlayFabProfilesModels.GetTitlePlayersFromMasterPlayerAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Retrieves the title player accounts associated with the given XUIDs. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/gettitleplayersfromxboxliveids + */ + GetTitlePlayersFromXboxLiveIDs(request: PlayFabProfilesModels.GetTitlePlayersFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the display name of the entity + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setdisplayname + */ + SetDisplayName(request: PlayFabProfilesModels.SetDisplayNameRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the global title access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setglobalpolicy + */ + SetGlobalPolicy(request: PlayFabProfilesModels.SetGlobalPolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the entity's language. The precedence hierarchy for communication to the player is Title Player Account + * language, Master Player Account language, and then title default language if the first two aren't set or supported. + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setprofilelanguage + */ + SetProfileLanguage(request: PlayFabProfilesModels.SetProfileLanguageRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Sets the profiles access policy + * https://docs.microsoft.com/rest/api/playfab/profiles/account-management/setprofilepolicy + */ + SetProfilePolicy(request: PlayFabProfilesModels.SetEntityProfilePolicyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabProfilesModels { + type EffectType = "Allow" + + | "Deny"; + + export interface EntityDataObject { + /** Un-escaped JSON object, if DataAsObject is true. */ + DataObject?: any; + /** Escaped string JSON body of the object, if DataAsObject is default or false. */ + EscapedDataObject?: string; + /** Name of this object. */ + ObjectName?: string; + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLineage { + /** The Character Id of the associated entity. */ + CharacterId?: string; + /** The Group Id of the associated entity. */ + GroupId?: string; + /** The Master Player Account Id of the associated entity. */ + MasterPlayerAccountId?: string; + /** The Namespace Id of the associated entity. */ + NamespaceId?: string; + /** The Title Id of the associated entity. */ + TitleId?: string; + /** The Title Player Account Id of the associated entity. */ + TitlePlayerAccountId?: string; + + } + + export interface EntityPermissionStatement { + /** The action this statement effects. May be 'Read', 'Write' or '*' for both read and write. */ + Action: string; + /** A comment about the statement. Intended solely for bookkeeping and debugging. */ + Comment?: string; + /** Additional conditions to be applied for entity resources. */ + Condition?: any; + /** The effect this statement will have. It may be either Allow or Deny */ + Effect: string; + /** The principal this statement will effect. */ + Principal: any; + /** The resource this statements effects. Similar to 'pfrn:data--title![Title ID]/Profile/*' */ + Resource: string; + + } + + export interface EntityProfileBody { + /** Avatar URL for the entity. */ + AvatarUrl?: string; + /** The creation time of this profile in UTC. */ + Created: string; + /** + * The display name of the entity. This field may serve different purposes for different entity types. i.e.: for a title + * player account it could represent the display name of the player, whereas on a character it could be character's name. + */ + DisplayName?: string; + /** The entity id and type. */ + Entity?: EntityKey; + /** The chain of responsibility for this entity. Use Lineage. */ + EntityChain?: string; + /** The experiment variants of this profile. */ + ExperimentVariants?: string[]; + /** The files on this profile. */ + Files?: { [key: string]: EntityProfileFileMetadata }; + /** The language on this profile. */ + Language?: string; + /** The lineage of this profile. */ + Lineage?: EntityLineage; + /** The objects on this profile. */ + Objects?: { [key: string]: EntityDataObject }; + /** + * The permissions that govern access to this entity profile and its properties. Only includes permissions set on this + * profile, not global statements from titles and namespaces. + */ + Permissions?: EntityPermissionStatement[]; + /** The statistics on this profile. */ + Statistics?: { [key: string]: EntityStatisticValue }; + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + StatisticsColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** + * The version number of the profile in persistent storage at the time of the read. Used for optional optimistic + * concurrency during update. + */ + VersionNumber: number; + + } + + export interface EntityProfileFileMetadata { + /** Checksum value for the file, can be used to check if the file on the server has changed. */ + Checksum?: string; + /** Name of the file */ + FileName?: string; + /** Last UTC time the file was modified */ + LastModified: string; + /** Storage service's reported byte count */ + Size: number; + + } + + export interface EntityStatisticValue { + /** Metadata associated with the Statistic. */ + Metadata?: string; + /** Statistic name */ + Name?: string; + /** Statistic scores */ + Scores?: string[]; + /** Statistic version */ + Version: number; + + } + + export interface GetEntityProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the objects will be returned as an escaped JSON string or as a un-escaped JSON object. Default is + * JSON string. + */ + DataAsObject?: boolean; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Determines whether the entity statistics will be returned in the entity profile. Default is false. */ + IncludeStatistics: boolean; + + } + + export interface GetEntityProfileResponse extends PlayFabModule.IPlayFabResultCommon { + /** Entity profile */ + Profile?: EntityProfileBody; + + } + + export interface GetEntityProfilesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Determines whether the objects will be returned as an escaped JSON string or as a un-escaped JSON object. Default is + * JSON string. + */ + DataAsObject?: boolean; + /** Entity keys of the profiles to load. Must be between 1 and 25 */ + Entities: EntityKey[]; + /** Determines whether the entity statistics will be returned in the entity profile. Default is false. */ + IncludeStatistics: boolean; + + } + + export interface GetEntityProfilesResponse extends PlayFabModule.IPlayFabResultCommon { + /** Entity profiles */ + Profiles?: EntityProfileBody[]; + + } + + export interface GetGlobalPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + + } + + export interface GetGlobalPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** The permissions that govern access to all entities under this title or namespace. */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface GetTitlePlayersFromMasterPlayerAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Master player account ids. */ + MasterPlayerAccountIds: string[]; + /** Id of title to get players from. */ + TitleId?: string; + + } + + export interface GetTitlePlayersFromMasterPlayerAccountIdsResponse extends PlayFabModule.IPlayFabResultCommon { + /** Optional id of title to get players from, required if calling using a master_player_account. */ + TitleId?: string; + /** Dictionary of master player ids mapped to title player entity keys and id pairs */ + TitlePlayerAccounts?: { [key: string]: EntityKey }; + + } + + export interface GetTitlePlayersFromProviderIDsResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * Dictionary of provider identifiers mapped to title_player_account lineage. Missing lineage indicates the player either + * doesn't exist or doesn't play the requested title. + */ + TitlePlayerAccounts?: { [key: string]: EntityLineage }; + + } + + export interface GetTitlePlayersFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Xbox Sandbox the players had on their Xbox tokens. */ + Sandbox: string; + /** Optional ID of title to get players from, required if calling using a master_player_account. */ + TitleId?: string; + /** List of Xbox Live XUIDs */ + XboxLiveIds: string[]; + + } + + type OperationTypes = "Created" + + | "Updated" + | "Deleted" + | "None"; + + export interface SetDisplayNameRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new value to be set on Entity Profile's display name */ + DisplayName?: string; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The expected version of a profile to perform this update on */ + ExpectedVersion?: number; + + } + + export interface SetDisplayNameResponse extends PlayFabModule.IPlayFabResultCommon { + /** The type of operation that occured on the profile's display name */ + OperationResult?: string; + /** The updated version of the profile after the display name update */ + VersionNumber?: number; + + } + + export interface SetEntityProfilePolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity to perform this action on. */ + Entity: EntityKey; + /** The statements to include in the access policy. */ + Statements: EntityPermissionStatement[]; + + } + + export interface SetEntityProfilePolicyResponse extends PlayFabModule.IPlayFabResultCommon { + /** + * The permissions that govern access to this entity profile and its properties. Only includes permissions set on this + * profile, not global statements from titles and namespaces. + */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface SetGlobalPolicyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The permissions that govern access to all entities under this title or namespace. */ + Permissions?: EntityPermissionStatement[]; + + } + + export interface SetGlobalPolicyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SetProfileLanguageRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The expected version of a profile to perform this update on */ + ExpectedVersion?: number; + /** The language to set on the given entity. Deletes the profile's language if passed in a null string. */ + Language?: string; + + } + + export interface SetProfileLanguageResponse extends PlayFabModule.IPlayFabResultCommon { + /** The type of operation that occured on the profile's language */ + OperationResult?: string; + /** The updated version of the profile after the language update */ + VersionNumber?: number; + + } + + type StatisticAggregationMethod = "Last" + + | "Min" + | "Max" + | "Sum"; + + export interface StatisticColumn { + /** Aggregation method for calculating new value of a statistic. */ + AggregationMethod: string; + /** Name of the statistic column, as originally configured. */ + Name: string; + + } + + export interface StatisticColumnCollection { + /** Columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabProgressionApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabProgressionApi.d.ts new file mode 100644 index 00000000..00230005 --- /dev/null +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabProgressionApi.d.ts @@ -0,0 +1,815 @@ +/// + +declare module PlayFabProgressionModule { + export interface IPlayFabProgression { + ForgetAllCredentials(): void; + + /** + * Creates a new leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/createleaderboarddefinition + */ + CreateLeaderboardDefinition(request: PlayFabProgressionModels.CreateLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Create a new entity statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/createstatisticdefinition + */ + CreateStatisticDefinition(request: PlayFabProgressionModels.CreateStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes a leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/deleteleaderboarddefinition + */ + DeleteLeaderboardDefinition(request: PlayFabProgressionModels.DeleteLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Deletes the specified entries from the given leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/deleteleaderboardentries + */ + DeleteLeaderboardEntries(request: PlayFabProgressionModels.DeleteLeaderboardEntriesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete an entity statistic definition. Will delete all statistics on entity profiles and leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/deletestatisticdefinition + */ + DeleteStatisticDefinition(request: PlayFabProgressionModels.DeleteStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Delete statistics on an entity profile. This will remove all rankings from associated leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/deletestatistics + */ + DeleteStatistics(request: PlayFabProgressionModels.DeleteStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the friend leaderboard for the specified entity. A maximum of 25 friend entries are listed in the leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getfriendleaderboardforentity + */ + GetFriendLeaderboardForEntity(request: PlayFabProgressionModels.GetFriendLeaderboardForEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard for a specific entity type and statistic. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboard + */ + GetLeaderboard(request: PlayFabProgressionModels.GetEntityLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard around a specific entity. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboardaroundentity + */ + GetLeaderboardAroundEntity(request: PlayFabProgressionModels.GetLeaderboardAroundEntityRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets the specified leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboarddefinition + */ + GetLeaderboardDefinition(request: PlayFabProgressionModels.GetLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get the leaderboard limited to a set of entities. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/getleaderboardforentities + */ + GetLeaderboardForEntities(request: PlayFabProgressionModels.GetLeaderboardForEntitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get current statistic definition information + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatisticdefinition + */ + GetStatisticDefinition(request: PlayFabProgressionModels.GetStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets statistics for the specified entity. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatistics + */ + GetStatistics(request: PlayFabProgressionModels.GetStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Gets statistics for the specified collection of entities. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/getstatisticsforentities + */ + GetStatisticsForEntities(request: PlayFabProgressionModels.GetStatisticsForEntitiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Increment a leaderboard version. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/incrementleaderboardversion + */ + IncrementLeaderboardVersion(request: PlayFabProgressionModels.IncrementLeaderboardVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Increment an entity statistic definition version. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/incrementstatisticversion + */ + IncrementStatisticVersion(request: PlayFabProgressionModels.IncrementStatisticVersionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Lists the leaderboard definitions defined for the Title. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/listleaderboarddefinitions + */ + ListLeaderboardDefinitions(request: PlayFabProgressionModels.ListLeaderboardDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Get all current statistic definitions information + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/liststatisticdefinitions + */ + ListStatisticDefinitions(request: PlayFabProgressionModels.ListStatisticDefinitionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks an aggregation source from a statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/unlinkaggregationsourcefromstatistic + */ + UnlinkAggregationSourceFromStatistic(request: PlayFabProgressionModels.UnlinkAggregationSourceFromStatisticRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks a leaderboard definition from it's linked statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/unlinkleaderboardfromstatistic + */ + UnlinkLeaderboardFromStatistic(request: PlayFabProgressionModels.UnlinkLeaderboardFromStatisticRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates a leaderboard definition. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/updateleaderboarddefinition + */ + UpdateLeaderboardDefinition(request: PlayFabProgressionModels.UpdateLeaderboardDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds or updates entries on the specified leaderboard. + * https://docs.microsoft.com/rest/api/playfab/progression/leaderboards/updateleaderboardentries + */ + UpdateLeaderboardEntries(request: PlayFabProgressionModels.UpdateLeaderboardEntriesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update an existing entity statistic definition. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/updatestatisticdefinition + */ + UpdateStatisticDefinition(request: PlayFabProgressionModels.UpdateStatisticDefinitionRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update statistics on an entity profile. Depending on the statistic definition, this may result in entity being ranked on + * various leaderboards. + * https://docs.microsoft.com/rest/api/playfab/progression/statistics/updatestatistics + */ + UpdateStatistics(request: PlayFabProgressionModels.UpdateStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + + } +} + +declare module PlayFabProgressionModels { + export interface CreateLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * Leaderboard columns describing the sort directions, cannot be changed after creation. A maximum of 5 columns are + * allowed. + */ + Columns: LeaderboardColumn[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface CreateStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** + * [In Preview]: The list of statistic definition names whose scores must be aggregated towards this stat. If + * AggregationSource is specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, + * only one aggregation source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. A maximum of 5 columns are allowed. */ + Columns?: StatisticColumn[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entity type allowed to have score(s) for this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Name of the statistic. Must be less than 150 characters. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + Name: string; + /** The version reset configuration for the statistic definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface DeleteLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard definition to delete. */ + Name: string; + + } + + export interface DeleteLeaderboardEntriesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The unique Ids of the entries to delete from the leaderboard. */ + EntityIds?: string[]; + /** The name of the leaderboard. */ + Name: string; + + } + + export interface DeleteStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic to delete. */ + Name: string; + + } + + export interface DeleteStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Collection of statistics to remove from this entity. */ + Statistics: StatisticDelete[]; + + } + + export interface DeleteStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The entity id and type. */ + Entity?: EntityKey; + + } + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityLeaderboardEntry { + /** Entity's display name. */ + DisplayName?: string; + /** Entity identifier. */ + Entity?: EntityKey; + /** The time at which the last update to the entry was recorded on the server. */ + LastUpdated: string; + /** An opaque blob of data stored on the leaderboard entry. Note that the metadata is not used for ranking purposes. */ + Metadata?: string; + /** Position on the leaderboard. */ + Rank: number; + /** Scores for the entry. */ + Scores?: string[]; + + } + + export interface EntityStatistics { + /** The entity for which the statistics are returned. */ + EntityKey?: EntityKey; + /** The statistics for the given entity key. */ + Statistics?: EntityStatisticValue[]; + + } + + export interface EntityStatisticValue { + /** Metadata associated with the Statistic. */ + Metadata?: string; + /** Statistic name */ + Name?: string; + /** Statistic scores */ + Scores?: string[]; + /** Statistic version */ + Version: number; + + } + + type EventType = "None" + + | "Telemetry" + | "PlayStream"; + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface GetEntityLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Maximum number of results to return from the leaderboard. Minimum 1, maximum 100. */ + PageSize: number; + /** Index position to start from. 1 is beginning of leaderboard. */ + StartingPosition?: number; + /** Optional version of the leaderboard, defaults to current version. */ + Version?: number; + + } + + export interface GetEntityLeaderboardResponse extends PlayFabModule.IPlayFabResultCommon { + /** Leaderboard columns describing the sort directions. */ + Columns?: LeaderboardColumn[]; + /** The number of entries on the leaderboard. */ + EntryCount: number; + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ + NextReset?: string; + /** Individual entity rankings in the leaderboard, in sorted order by rank. */ + Rankings?: EntityLeaderboardEntry[]; + /** Version of the leaderboard being returned. */ + Version: number; + + } + + export interface GetFriendLeaderboardForEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalFriendSources?: string; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Optional version of the leaderboard, defaults to current version. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; + + } + + export interface GetLeaderboardAroundEntityRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** + * Number of surrounding entries to return (in addition to specified entity). In general, the number of ranks above and + * below will be split into half. For example, if the specified value is 10, 5 ranks above and 5 ranks below will be + * retrieved. However, the numbers will get skewed in either direction when the specified entity is towards the top or + * bottom of the leaderboard. Also, the number of entries returned can be lower than the value specified for entries at the + * bottom of the leaderboard. + */ + MaxSurroundingEntries: number; + /** Optional version of the leaderboard, defaults to current. */ + Version?: number; + + } + + export interface GetLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard to retrieve the definition for. */ + Name: string; + + } + + export interface GetLeaderboardDefinitionResponse extends PlayFabModule.IPlayFabResultCommon { + /** Sort direction of the leaderboard columns, cannot be changed after creation. */ + Columns: LeaderboardColumn[]; + /** Created time, in UTC */ + Created: string; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** Last time, in UTC, leaderboard version was incremented. */ + LastResetTime?: string; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** Latest Leaderboard version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration: VersionConfiguration; + + } + + export interface GetLeaderboardForEntitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Collection of Entity IDs to include in the leaderboard. */ + EntityIds: string[]; + /** Name of the leaderboard. */ + LeaderboardName: string; + /** Optional version of the leaderboard, defaults to current. */ + Version?: number; + + } + + export interface GetStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic. Must be less than 150 characters. */ + Name: string; + + } + + export interface GetStatisticDefinitionResponse extends PlayFabModule.IPlayFabResultCommon { + /** The list of statistic definitions names this definition aggregates to. */ + AggregationDestinations?: string[]; + /** + * The list of statistic definitions names whose values must be aggregated towards this stat. If AggregationSource is + * specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, only one aggregation + * source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + /** Created time, in UTC */ + Created: string; + /** The entity type that can have this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Last time, in UTC, statistic version was incremented. */ + LastResetTime?: string; + /** The list of leaderboards that are linked to this statistic definition. */ + LinkedLeaderboardNames?: string[]; + /** Name of the statistic. */ + Name?: string; + /** Statistic version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface GetStatisticsForEntitiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Collection of Entity IDs to retrieve statistics for. */ + Entities: EntityKey[]; + /** The list of statistics to return for the user. If set to null, the current version of all statistics are returned. */ + StatisticNames?: string[]; + + } + + export interface GetStatisticsForEntitiesResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** List of entities mapped to their statistics. Only the latest version of a statistic is returned. */ + EntitiesStatistics?: EntityStatistics[]; + + } + + export interface GetStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** The list of statistics to return for the user. If set to null, the current version of all statistics are returned. */ + StatisticNames?: string[]; + + } + + export interface GetStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** The entity id and type. */ + Entity?: EntityKey; + /** List of statistics keyed by Name. Only the latest version of a statistic is returned. */ + Statistics?: { [key: string]: EntityStatisticValue }; + + } + + export interface IncrementLeaderboardVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard to increment the version for. */ + Name: string; + + } + + export interface IncrementLeaderboardVersionResponse extends PlayFabModule.IPlayFabResultCommon { + /** New Leaderboard version. */ + Version: number; + + } + + export interface IncrementStatisticVersionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Name of the statistic to increment the version of. */ + Name: string; + + } + + export interface IncrementStatisticVersionResponse extends PlayFabModule.IPlayFabResultCommon { + /** New statistic version. */ + Version: number; + + } + + export interface LeaderboardColumn { + /** + * If the value for this column is sourced from a statistic, details of the linked column. Null if the leaderboard is not + * linked. + */ + LinkedStatisticColumn?: LinkedStatisticColumn; + /** A name for the leaderboard column, unique per leaderboard definition. */ + Name: string; + /** The sort direction for this column. */ + SortDirection: string; + + } + + export interface LeaderboardDefinition { + /** Sort direction of the leaderboard columns, cannot be changed after creation. */ + Columns: LeaderboardColumn[]; + /** Created time, in UTC */ + Created: string; + /** + * The entity type being represented on the leaderboard. If it doesn't correspond to the PlayFab entity types, use + * 'external' as the type. + */ + EntityType: string; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** Last time, in UTC, leaderboard version was incremented. */ + LastResetTime?: string; + /** A name for the leaderboard, unique per title. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit: number; + /** Latest Leaderboard version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration: VersionConfiguration; + + } + + export interface LeaderboardEntityRankOnVersionEndConfig { + /** The type of event to emit when the leaderboard version end. */ + EventType: string; + /** The maximum number of entity to return on leaderboard version end. Range is 1 to 1000. */ + RankLimit: number; + + } + + export interface LeaderboardEntryUpdate { + /** The unique Id for the entry. If using PlayFab Entities, this would be the entityId of the entity. */ + EntityId: string; + /** Arbitrary metadata to store along side the leaderboard entry, will be returned by all Leaderboard APIs. */ + Metadata?: string; + /** + * The scores for the leaderboard. The number of values provided here must match the number of columns in the Leaderboard + * definition. + */ + Scores?: string[]; + + } + + export interface LeaderboardEventEmissionConfig { + /** This event emits the top ranks of the leaderboard when the leaderboard version end. */ + EntityRankOnVersionEndConfig?: LeaderboardEntityRankOnVersionEndConfig; + /** This event is emitted when the leaderboard version end. */ + VersionEndConfig?: LeaderboardVersionEndConfig; + + } + + type LeaderboardSortDirection = "Descending" + + | "Ascending"; + + export interface LeaderboardVersionEndConfig { + /** The type of event to emit when the leaderboard version end. */ + EventType: string; + + } + + export interface LinkedStatisticColumn { + /** The name of the statistic column that this leaderboard column is sourced from. */ + LinkedStatisticColumnName: string; + /** The name of the statistic. */ + LinkedStatisticName: string; + + } + + export interface ListLeaderboardDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListLeaderboardDefinitionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** List of leaderboard definitions for the title. */ + LeaderboardDefinitions?: LeaderboardDefinition[]; + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + + } + + export interface ListStatisticDefinitionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The page size for the request. */ + PageSize?: number; + /** The skip token for the paged request. */ + SkipToken?: string; + + } + + export interface ListStatisticDefinitionsResponse extends PlayFabModule.IPlayFabResultCommon { + /** The page size on the response. */ + PageSize: number; + /** The skip token for the paged response. */ + SkipToken?: string; + /** List of statistic definitions for the title. */ + StatisticDefinitions?: StatisticDefinition[]; + + } + + type ResetInterval = "Manual" + + | "Hour" + | "Day" + | "Week" + | "Month"; + + type StatisticAggregationMethod = "Last" + + | "Min" + | "Max" + | "Sum"; + + export interface StatisticColumn { + /** Aggregation method for calculating new value of a statistic. */ + AggregationMethod: string; + /** Name of the statistic column, as originally configured. */ + Name: string; + + } + + export interface StatisticColumnCollection { + /** Columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + + } + + export interface StatisticDefinition { + /** The list of statistic definitions names this definition aggregates to. */ + AggregationDestinations?: string[]; + /** + * The list of statistic definitions names whose values must be aggregated towards this stat. If AggregationSource is + * specified, the entityType of this definition MUST be Title (making it a CommunityStat). Currently, only one aggregation + * source can be specified. + */ + AggregationSources?: string[]; + /** The columns for the statistic defining the aggregation method for each column. */ + Columns?: StatisticColumn[]; + /** Created time, in UTC */ + Created: string; + /** The entity type that can have this statistic. */ + EntityType?: string; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Last time, in UTC, statistic version was incremented. */ + LastResetTime?: string; + /** The list of leaderboards that are linked to this statistic definition. */ + LinkedLeaderboardNames?: string[]; + /** Name of the statistic. */ + Name?: string; + /** Statistic version. */ + Version: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface StatisticDelete { + /** Name of the statistic, as originally configured. */ + Name: string; + + } + + export interface StatisticsEventEmissionConfig { + /** Emitted when statistics are updated. */ + UpdateEventConfig?: StatisticsUpdateEventConfig; + + } + + export interface StatisticsUpdateEventConfig { + /** The event type to emit when statistics are updated. */ + EventType: string; + + } + + export interface StatisticUpdate { + /** + * A list of entities to which the statistic update must be aggregated to, in addition to the entity being updated. For + * example, for Group stats where the stat value is aggregated based on the group members, this would refer to the Group + * entity. For a community stat that's aggregated at the Title, it is not required to populate this property (Title is the + * default). + */ + AggregationTargetEntityKeys?: EntityKey[]; + /** Arbitrary metadata to store along side the statistic, will be returned by all Leaderboard APIs. */ + Metadata?: string; + /** Name of the statistic, as originally configured. */ + Name: string; + /** + * Statistic scores for the entity. This will be used in accordance with the aggregation method configured for the + * statistics.The maximum value allowed for each individual score is 9223372036854775807. The minimum value for each + * individual score is -9223372036854775807The values are formatted as strings to avoid interop issues with client + * libraries unable to handle 64bit integers. + */ + Scores?: string[]; + /** Optional field to indicate the version of the statistic to set. When empty defaults to the statistic's current version. */ + Version?: number; + + } + + export interface UnlinkAggregationSourceFromStatisticRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the statistic to unlink. */ + Name: string; + /** The name of the aggregation source statistic to unlink. */ + SourceStatisticName: string; + + } + + export interface UnlinkLeaderboardFromStatisticRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the leaderboard definition to unlink. */ + Name: string; + /** The name of the statistic definition to unlink. */ + StatisticName: string; + + } + + export interface UpdateLeaderboardDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** [In Preview]: The configuration for the events emitted by this leaderboard. If not specified, no events will be emitted. */ + EventEmissionConfig?: LeaderboardEventEmissionConfig; + /** The name of the leaderboard to update the definition for. */ + Name: string; + /** Maximum number of entries on this leaderboard */ + SizeLimit?: number; + /** The version reset configuration for the leaderboard definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface UpdateLeaderboardEntriesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The entries to add or update on the leaderboard. */ + Entries?: LeaderboardEntryUpdate[]; + /** The name of the leaderboard. */ + LeaderboardName: string; + + } + + export interface UpdateStatisticDefinitionRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** [In Preview]: Configurations for different Statistics events that can be emitted by the service. */ + EventEmissionConfig?: StatisticsEventEmissionConfig; + /** Name of the statistic. Must be less than 150 characters. Restricted to a-Z, 0-9, '(', ')', '_', '-' and '.'. */ + Name: string; + /** The version reset configuration for the statistic definition. */ + VersionConfiguration?: VersionConfiguration; + + } + + export interface UpdateStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The optional entity to perform this action on. Defaults to the currently logged in entity. */ + Entity?: EntityKey; + /** Collection of statistics to update, maximum 50. */ + Statistics: StatisticUpdate[]; + /** Optional transactionId of this update which can be used to ensure idempotence. */ + TransactionId?: string; + + } + + export interface UpdateStatisticsResponse extends PlayFabModule.IPlayFabResultCommon { + /** A mapping of statistic name to the columns defined in the corresponding definition. */ + ColumnDetails?: { [key: string]: StatisticColumnCollection }; + /** The entity id and type. */ + Entity?: EntityKey; + /** Updated entity profile statistics. */ + Statistics?: { [key: string]: EntityStatisticValue }; + + } + + export interface VersionConfiguration { + /** The maximum number of versions of this leaderboard/statistic that can be queried. */ + MaxQueryableVersions: number; + /** + * Reset interval that statistics or leaderboards will reset on. When using Manual intervalthe reset can only be increased + * by calling the Increase version API. When using Hour interval the resetwill occur at the start of the next hour UTC + * time. When using Day interval the reset will occur at thestart of the next day in UTC time. When using the Week interval + * the reset will occur at the start ofthe next Monday in UTC time. When using Month interval the reset will occur at the + * start of the nextmonth in UTC time. + */ + ResetInterval: string; + + } + + +} diff --git a/PlayFabTestingExample/src/typings/PlayFab/PlayFabServerApi.d.ts b/PlayFabTestingExample/src/typings/PlayFab/PlayFabServerApi.d.ts index ccbb636b..dbde1d7a 100644 --- a/PlayFabTestingExample/src/typings/PlayFab/PlayFabServerApi.d.ts +++ b/PlayFabTestingExample/src/typings/PlayFab/PlayFabServerApi.d.ts @@ -2,1163 +2,1319 @@ declare module PlayFabServerModule { export interface IPlayFabServer { + ForgetAllCredentials(): void; + /** - / Validated a client's session ticket, and if successful, returns details for that user - / https://api.playfab.com/Documentation/Server/method/AuthenticateSessionTicket + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the character's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/addcharactervirtualcurrency */ - AuthenticateSessionTicket(request: PlayFabServerModels.AuthenticateSessionTicketRequest, callback: PlayFabModule.ApiCallback): void; + AddCharacterVirtualCurrency(request: PlayFabServerModels.AddCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Bans users by PlayFab ID with optional IP address, or MAC address for the provided game. - / https://api.playfab.com/Documentation/Server/method/BanUsers + * Adds the Friend user to the friendlist of the user with PlayFabId. At least one of + * FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/addfriend */ - BanUsers(request: PlayFabServerModels.BanUsersRequest, callback: PlayFabModule.ApiCallback): void; + AddFriend(request: PlayFabServerModels.AddFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. - / https://api.playfab.com/Documentation/Server/method/GetPlayFabIDsFromFacebookIDs + * Adds the specified generic service identifier to the player's PlayFab account. This is designed to allow for a PlayFab + * ID lookup of any arbitrary service identifier a title wants to add. This identifier should never be used as + * authentication credentials, as the intent is that it is easily accessible by other players. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/addgenericid */ - GetPlayFabIDsFromFacebookIDs(request: PlayFabServerModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback): void; + AddGenericID(request: PlayFabServerModels.AddGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile IDs for the user accounts, available as SteamId in the Steamworks Community API calls. - / https://api.playfab.com/Documentation/Server/method/GetPlayFabIDsFromSteamIDs + * Adds or updates a contact email to the specified player's profile. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/addorupdatecontactemail */ - GetPlayFabIDsFromSteamIDs(request: PlayFabServerModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback): void; + AddOrUpdateContactEmail(request: PlayFabServerModels.AddOrUpdateContactEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the relevant details for a specified user - / https://api.playfab.com/Documentation/Server/method/GetUserAccountInfo + * Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/addplayertag */ - GetUserAccountInfo(request: PlayFabServerModels.GetUserAccountInfoRequest, callback: PlayFabModule.ApiCallback): void; + AddPlayerTag(request: PlayFabServerModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Gets all bans for a user. - / https://api.playfab.com/Documentation/Server/method/GetUserBans + * Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users + * in the group (and the server) can add new members. Shared Groups are designed for sharing data between a very small + * number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/addsharedgroupmembers */ - GetUserBans(request: PlayFabServerModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback): void; + AddSharedGroupMembers(request: PlayFabServerModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans for a user. - / https://api.playfab.com/Documentation/Server/method/RevokeAllBansForUser + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Increments the user's balance of the specified virtual currency by the stated amount + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/adduservirtualcurrency */ - RevokeAllBansForUser(request: PlayFabServerModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback): void; + AddUserVirtualCurrency(request: PlayFabServerModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revoke all active bans specified with BanId. - / https://api.playfab.com/Documentation/Server/method/RevokeBans + * Validated a client's session ticket, and if successful, returns details for that user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/authenticatesessionticket */ - RevokeBans(request: PlayFabServerModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback): void; + AuthenticateSessionTicket(request: PlayFabServerModels.AuthenticateSessionTicketRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sends an iOS/Android Push Notification to a specific user, if that user's device has been configured for Push Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. - / https://api.playfab.com/Documentation/Server/method/SendPushNotification + * Awards the specified users the specified Steam achievements + * https://docs.microsoft.com/rest/api/playfab/server/platform-specific-methods/awardsteamachievement */ - SendPushNotification(request: PlayFabServerModels.SendPushNotificationRequest, callback: PlayFabModule.ApiCallback): void; + AwardSteamAchievement(request: PlayFabServerModels.AwardSteamAchievementRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Update the avatar URL of the specified player - / https://api.playfab.com/Documentation/Server/method/UpdateAvatarUrl + * Bans users by PlayFab ID with optional IP address for the provided game. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/banusers */ - UpdateAvatarUrl(request: PlayFabServerModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback): void; + BanUsers(request: PlayFabServerModels.BanUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates information of a list of existing bans specified with Ban Ids. - / https://api.playfab.com/Documentation/Server/method/UpdateBans + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's + * inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/consumeitem */ - UpdateBans(request: PlayFabServerModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback): void; + ConsumeItem(request: PlayFabServerModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the users for the provided game. Deletes custom data, all account linkages, and statistics. - / https://api.playfab.com/Documentation/Server/method/DeleteUsers + * Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the + * group. When created by a server, the group will initially have no members. Shared Groups are designed for sharing data + * between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/createsharedgroup */ - DeleteUsers(request: PlayFabServerModels.DeleteUsersRequest, callback: PlayFabModule.ApiCallback): void; + CreateSharedGroup(request: PlayFabServerModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked friends of the given player for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetFriendLeaderboard + * Deletes the specific character ID from the specified user. + * https://docs.microsoft.com/rest/api/playfab/server/characters/deletecharacterfromuser */ - GetFriendLeaderboard(request: PlayFabServerModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + DeleteCharacterFromUser(request: PlayFabServerModels.DeleteCharacterFromUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetLeaderboard + * Removes a user's player account from a title and deletes all associated data + * https://docs.microsoft.com/rest/api/playfab/server/account-management/deleteplayer */ - GetLeaderboard(request: PlayFabServerModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayer(request: PlayFabServerModels.DeletePlayerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked users for the given statistic, centered on the currently signed-in user - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardAroundUser + * Deletes title-specific custom properties for a player + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/deleteplayercustomproperties */ - GetLeaderboardAroundUser(request: PlayFabServerModels.GetLeaderboardAroundUserRequest, callback: PlayFabModule.ApiCallback): void; + DeletePlayerCustomProperties(request: PlayFabServerModels.DeletePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Returns whatever info is requested in the response for the user. Note that PII (like email address, facebook id) may be returned. All parameters default to false. - / https://api.playfab.com/Documentation/Server/method/GetPlayerCombinedInfo + * Deletes push notification template for title + * https://docs.microsoft.com/rest/api/playfab/server/account-management/deletepushnotificationtemplate */ - GetPlayerCombinedInfo(request: PlayFabServerModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback): void; + DeletePushNotificationTemplate(request: PlayFabServerModels.DeletePushNotificationTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current version and values for the indicated statistics, for the local player. - / https://api.playfab.com/Documentation/Server/method/GetPlayerStatistics + * Deletes a shared group, freeing up the shared group ID to be reused for a new group. Shared Groups are designed for + * sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/deletesharedgroup */ - GetPlayerStatistics(request: PlayFabServerModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + DeleteSharedGroup(request: PlayFabServerModels.DeleteSharedGroupRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the information on the available versions of the specified statistic. - / https://api.playfab.com/Documentation/Server/method/GetPlayerStatisticVersions + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Returns the result of an evaluation of a Random Result Table - the ItemId from the game Catalog which would + * have been added to the player inventory, if the Random Result Table were added via a Bundle or a call to + * UnlockContainer. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/evaluaterandomresulttable */ - GetPlayerStatisticVersions(request: PlayFabServerModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback): void; + EvaluateRandomResultTable(request: PlayFabServerModels.EvaluateRandomResultTableRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetUserData + * Executes a CloudScript function, with the 'currentPlayerId' set to the PlayFab ID of the authenticated player. The + * PlayFab ID is the entity ID of the player's master_player_account entity. + * https://docs.microsoft.com/rest/api/playfab/server/server-side-cloud-script/executecloudscript */ - GetUserData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExecuteCloudScript(request: PlayFabServerModels.ExecuteCloudScriptServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetUserInternalData + * Starts an export for the player profiles in a segment. This API creates a snapshot of all the player profiles which + * match the segment definition at the time of the API call. Profiles which change while an export is in progress will not + * be reflected in the results. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/exportplayersinsegment */ - GetUserInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + ExportPlayersInSegment(request: PlayFabServerModels.ExportPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherData + * Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as + * ExportPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not + * change. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getallsegments */ - GetUserPublisherData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllSegments(request: PlayFabServerModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherInternalData + * Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be + * evaluated with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/server/characters/getalluserscharacters */ - GetUserPublisherInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetAllUsersCharacters(request: PlayFabServerModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetUserPublisherReadOnlyData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified version of the title's catalog of virtual goods, including all defined properties + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getcatalogitems */ - GetUserPublisherReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCatalogItems(request: PlayFabServerModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetUserReadOnlyData + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterdata */ - GetUserReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the user - / https://api.playfab.com/Documentation/Server/method/UpdatePlayerStatistics + * Retrieves the title-specific custom data for the user's character which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterinternaldata */ - UpdatePlayerStatistics(request: PlayFabServerModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterInternalData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserData + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified character's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getcharacterinventory */ - UpdateUserData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterInventory(request: PlayFabServerModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserInternalData + * Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/characters/getcharacterleaderboard */ - UpdateUserInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterLeaderboard(request: PlayFabServerModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherData + * Retrieves the title-specific custom data for the user's character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/getcharacterreadonlydata */ - UpdateUserPublisherData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterReadOnlyData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherInternalData + * Retrieves the details of all title-specific statistics for the specific character + * https://docs.microsoft.com/rest/api/playfab/server/characters/getcharacterstatistics */ - UpdateUserPublisherInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback): void; + GetCharacterStatistics(request: PlayFabServerModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the publisher-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserPublisherReadOnlyData + * This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned + * URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the + * content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, + * the query to retrieve the data will fail. See this post for more information: + * https://community.playfab.com/hc/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, + * please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. + * https://docs.microsoft.com/rest/api/playfab/server/content/getcontentdownloadurl */ - UpdateUserPublisherReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetContentDownloadUrl(request: PlayFabServerModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateUserReadOnlyData + * Retrieves a list of ranked friends of the given player for the given statistic, starting from the indicated point in the + * leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getfriendleaderboard */ - UpdateUserReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback): void; + GetFriendLeaderboard(request: PlayFabServerModels.GetFriendLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified version of the title's catalog of virtual goods, including all defined properties - / https://api.playfab.com/Documentation/Server/method/GetCatalogItems + * Retrieves the current friends for the user with PlayFabId, constrained to users who have PlayFab accounts. Friends from + * linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/getfriendslist */ - GetCatalogItems(request: PlayFabServerModels.GetCatalogItemsRequest, callback: PlayFabModule.ApiCallback): void; + GetFriendsList(request: PlayFabServerModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Server/method/GetPublisherData + * Retrieves a list of ranked users for the given statistic, starting from the indicated point in the leaderboard + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getleaderboard */ - GetPublisherData(request: PlayFabServerModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboard(request: PlayFabServerModels.GetLeaderboardRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current server time - / https://api.playfab.com/Documentation/Server/method/GetTime + * Retrieves a list of ranked characters for the given statistic, centered on the requested user + * https://docs.microsoft.com/rest/api/playfab/server/characters/getleaderboardaroundcharacter */ - GetTime(request: PlayFabServerModels.GetTimeRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardAroundCharacter(request: PlayFabServerModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/GetTitleData + * Retrieves a list of ranked users for the given statistic, centered on the currently signed-in user + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getleaderboardarounduser */ - GetTitleData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardAroundUser(request: PlayFabServerModels.GetLeaderboardAroundUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the key-value store of custom internal title settings - / https://api.playfab.com/Documentation/Server/method/GetTitleInternalData + * Retrieves a list of all of the user's characters for the given statistic. + * https://docs.microsoft.com/rest/api/playfab/server/characters/getleaderboardforusercharacters */ - GetTitleInternalData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetLeaderboardForUserCharacters(request: PlayFabServerModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title news feed, as configured in the developer portal - / https://api.playfab.com/Documentation/Server/method/GetTitleNews + * Returns whatever info is requested in the response for the user. Note that PII (like email address, facebook id) may be + * returned. All parameters default to false. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayercombinedinfo */ - GetTitleNews(request: PlayFabServerModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCombinedInfo(request: PlayFabServerModels.GetPlayerCombinedInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom publisher settings - / https://api.playfab.com/Documentation/Server/method/SetPublisherData + * Retrieves a title-specific custom property value for a player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayercustomproperty */ - SetPublisherData(request: PlayFabServerModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerCustomProperty(request: PlayFabServerModels.GetPlayerCustomPropertyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/SetTitleData + * Retrieves the player's profile + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayerprofile */ - SetTitleData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerProfile(request: PlayFabServerModels.GetPlayerProfileRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value store of custom title settings - / https://api.playfab.com/Documentation/Server/method/SetTitleInternalData + * List all segments that a player currently belongs to at this moment in time. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getplayersegments */ - SetTitleInternalData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerSegments(request: PlayFabServerModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the character's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/AddCharacterVirtualCurrency + * Retrieves the current version and values for the indicated statistics, for the local player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayerstatistics */ - AddCharacterVirtualCurrency(request: PlayFabServerModels.AddCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatistics(request: PlayFabServerModels.GetPlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Increments the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/AddUserVirtualCurrency + * Retrieves the information on the available versions of the specified statistic. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getplayerstatisticversions */ - AddUserVirtualCurrency(request: PlayFabServerModels.AddUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerStatisticVersions(request: PlayFabServerModels.GetPlayerStatisticVersionsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Consume uses of a consumable item. When all uses are consumed, it will be removed from the player's inventory. - / https://api.playfab.com/Documentation/Server/method/ConsumeItem + * Get all tags with a given Namespace (optional) from a player profile. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getplayertags */ - ConsumeItem(request: PlayFabServerModels.ConsumeItemRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayerTags(request: PlayFabServerModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Returns the result of an evaluation of a Random Result Table - the ItemId from the game Catalog which would have been added to the player inventory, if the Random Result Table were added via a Bundle or a call to UnlockContainer. - / https://api.playfab.com/Documentation/Server/method/EvaluateRandomResultTable + * Retrieves the unique PlayFab identifiers for the given set of Battle.net account identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrombattlenetaccountids */ - EvaluateRandomResultTable(request: PlayFabServerModels.EvaluateRandomResultTableRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromBattleNetAccountIds(request: PlayFabServerModels.GetPlayFabIDsFromBattleNetAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified character's current inventory of virtual goods - / https://api.playfab.com/Documentation/Server/method/GetCharacterInventory + * Retrieves the unique PlayFab identifiers for the given set of Facebook identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromfacebookids */ - GetCharacterInventory(request: PlayFabServerModels.GetCharacterInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookIDs(request: PlayFabServerModels.GetPlayFabIDsFromFacebookIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the configuration information for the specified random results tables for the title, including all ItemId values and weights - / https://api.playfab.com/Documentation/Server/method/GetRandomResultTables + * Retrieves the unique PlayFab identifiers for the given set of Facebook Instant Games identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromfacebookinstantgamesids */ - GetRandomResultTables(request: PlayFabServerModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromFacebookInstantGamesIds(request: PlayFabServerModels.GetPlayFabIDsFromFacebookInstantGamesIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the specified user's current inventory of virtual goods - / https://api.playfab.com/Documentation/Server/method/GetUserInventory + * Retrieves the unique PlayFab identifiers for the given set of generic service identifiers. A generic identifier is the + * service name plus the service-specific ID for the player, as specified by the title when the generic identifier was + * added to the player account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromgenericids */ - GetUserInventory(request: PlayFabServerModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromGenericIDs(request: PlayFabServerModels.GetPlayFabIDsFromGenericIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified character's inventory - / https://api.playfab.com/Documentation/Server/method/GrantItemsToCharacter + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Service Account identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromnintendoserviceaccountids */ - GrantItemsToCharacter(request: PlayFabServerModels.GrantItemsToCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoServiceAccountIds(request: PlayFabServerModels.GetPlayFabIDsFromNintendoServiceAccountIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user's inventory - / https://api.playfab.com/Documentation/Server/method/GrantItemsToUser + * Retrieves the unique PlayFab identifiers for the given set of Nintendo Switch Device identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromnintendoswitchdeviceids */ - GrantItemsToUser(request: PlayFabServerModels.GrantItemsToUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromNintendoSwitchDeviceIds(request: PlayFabServerModels.GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the specified items to the specified user inventories - / https://api.playfab.com/Documentation/Server/method/GrantItemsToUsers + * Retrieves the unique PlayFab identifiers for the given set of OpenId subject identifiers. A OpenId subject identifier is + * the OpenId issuer plus the OpenId subject for the player, as specified by the title when the OpenId identifier was added + * to the player account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromopenidsubjectidentifiers */ - GrantItemsToUsers(request: PlayFabServerModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromOpenIdSubjectIdentifiers(request: PlayFabServerModels.GetPlayFabIDsFromOpenIdsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Modifies the number of remaining uses of a player's inventory item - / https://api.playfab.com/Documentation/Server/method/ModifyItemUses + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrompsnaccountids */ - ModifyItemUses(request: PlayFabServerModels.ModifyItemUsesRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNAccountIDs(request: PlayFabServerModels.GetPlayFabIDsFromPSNAccountIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a character's inventory into another of the users's character's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToCharacterFromCharacter + * Retrieves the unique PlayFab identifiers for the given set of PlayStation :tm: Network identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfrompsnonlineids */ - MoveItemToCharacterFromCharacter(request: PlayFabServerModels.MoveItemToCharacterFromCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromPSNOnlineIDs(request: PlayFabServerModels.GetPlayFabIDsFromPSNOnlineIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a user's inventory into their character's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToCharacterFromUser + * Retrieves the associated PlayFab account identifiers for the given set of server custom player identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromservercustomids */ - MoveItemToCharacterFromUser(request: PlayFabServerModels.MoveItemToCharacterFromUserRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromServerCustomIDs(request: PlayFabServerModels.GetPlayFabIDsFromServerCustomIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Moves an item from a character's inventory into the owning user's inventory. - / https://api.playfab.com/Documentation/Server/method/MoveItemToUserFromCharacter + * Retrieves the unique PlayFab identifiers for the given set of Steam identifiers. The Steam identifiers are the profile + * IDs for the user accounts, available as SteamId in the Steamworks Community API calls. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromsteamids */ - MoveItemToUserFromCharacter(request: PlayFabServerModels.MoveItemToUserFromCharacterRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamIDs(request: PlayFabServerModels.GetPlayFabIDsFromSteamIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the Economy->Catalogs tab in the PlayFab Game Manager. - / https://api.playfab.com/Documentation/Server/method/RedeemCoupon + * 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 */ - RedeemCoupon(request: PlayFabServerModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromSteamNames(request: PlayFabServerModels.GetPlayFabIDsFromSteamNamesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Submit a report about a player (due to bad bahavior, etc.) on behalf of another player, so that customer service representatives for the title can take action concerning potentially toxic players. - / https://api.playfab.com/Documentation/Server/method/ReportPlayer + * 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). + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromtwitchids */ - ReportPlayer(request: PlayFabServerModels.ReportPlayerServerRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromTwitchIDs(request: PlayFabServerModels.GetPlayFabIDsFromTwitchIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Revokes access to an item in a user's inventory - / https://api.playfab.com/Documentation/Server/method/RevokeInventoryItem + * Retrieves the unique PlayFab identifiers for the given set of XboxLive identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getplayfabidsfromxboxliveids */ - RevokeInventoryItem(request: PlayFabServerModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback): void; + GetPlayFabIDsFromXboxLiveIDs(request: PlayFabServerModels.GetPlayFabIDsFromXboxLiveIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the character's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/SubtractCharacterVirtualCurrency + * Retrieves the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getpublisherdata */ - SubtractCharacterVirtualCurrency(request: PlayFabServerModels.SubtractCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetPublisherData(request: PlayFabServerModels.GetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Decrements the user's balance of the specified virtual currency by the stated amount - / https://api.playfab.com/Documentation/Server/method/SubtractUserVirtualCurrency + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the configuration information for the specified random results tables for the title, including all + * ItemId values and weights + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getrandomresulttables */ - SubtractUserVirtualCurrency(request: PlayFabServerModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback): void; + GetRandomResultTables(request: PlayFabServerModels.GetRandomResultTablesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Opens a specific container (ContainerItemInstanceId), with a specific key (KeyItemInstanceId, when required), and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Server/method/UnlockContainerInstance + * Retrieves the result of an export started by ExportPlayersInSegment API. If the ExportPlayersInSegment is successful and + * complete, this API returns the IndexUrl from which the index file can be downloaded. The index file has a list of urls + * from which the files containing the player profile data can be downloaded. Otherwise, it returns the current 'State' of + * the export + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getsegmentexport */ - UnlockContainerInstance(request: PlayFabServerModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentExport(request: PlayFabServerModels.GetPlayersInSegmentExportRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Searches Player or Character inventory for any ItemInstance matching the given CatalogItemId, if necessary unlocks it using any appropriate key, and returns the contents of the opened container. If the container (and key when relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. - / https://api.playfab.com/Documentation/Server/method/UnlockContainerItem + * Returns the total number of players in a given segment. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/getsegmentplayercount */ - UnlockContainerItem(request: PlayFabServerModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback): void; + GetSegmentPlayerCount(request: PlayFabServerModels.GetSegmentPlayerCountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the key-value pair data tagged to the specified item, which is read-only from the client. - / https://api.playfab.com/Documentation/Server/method/UpdateUserInventoryItemCustomData + * Retrieves the associated PlayFab account identifiers for the given set of server custom identifiers. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getservercustomidsfromplayfabids */ - UpdateUserInventoryItemCustomData(request: PlayFabServerModels.UpdateUserInventoryItemDataRequest, callback: PlayFabModule.ApiCallback): void; + GetServerCustomIDsFromPlayFabIDs(request: PlayFabServerModels.GetServerCustomIDsFromPlayFabIDsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds the Friend user to the friendlist of the user with PlayFabId. At least one of FriendPlayFabId,FriendUsername,FriendEmail, or FriendTitleDisplayName should be initialized. - / https://api.playfab.com/Documentation/Server/method/AddFriend + * Retrieves data stored in a shared group object, as well as the list of members in the group. The server can access all + * public and private group data. Shared Groups are designed for sharing data between a very small number of players, + * please see our guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/getsharedgroupdata */ - AddFriend(request: PlayFabServerModels.AddFriendRequest, callback: PlayFabModule.ApiCallback): void; + GetSharedGroupData(request: PlayFabServerModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the current friends for the user with PlayFabId, constrained to users who have PlayFab accounts. Friends from linked accounts (Facebook, Steam) are also included. You may optionally exclude some linked services' friends. - / https://api.playfab.com/Documentation/Server/method/GetFriendsList + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the set of items defined for the specified store, including all prices defined, for the specified + * player + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/getstoreitems */ - GetFriendsList(request: PlayFabServerModels.GetFriendsListRequest, callback: PlayFabModule.ApiCallback): void; + GetStoreItems(request: PlayFabServerModels.GetStoreItemsServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes the specified friend from the the user's friend list - / https://api.playfab.com/Documentation/Server/method/RemoveFriend + * Retrieves the current server time + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettime */ - RemoveFriend(request: PlayFabServerModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback): void; + GetTime(request: PlayFabServerModels.GetTimeRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the tag list for a specified user in the friend list of another user - / https://api.playfab.com/Documentation/Server/method/SetFriendTags + * Retrieves the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitledata */ - SetFriendTags(request: PlayFabServerModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Inform the matchmaker that a Game Server Instance is removed. - / https://api.playfab.com/Documentation/Server/method/DeregisterGame + * Retrieves the key-value store of custom internal title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitleinternaldata */ - DeregisterGame(request: PlayFabServerModels.DeregisterGameRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleInternalData(request: PlayFabServerModels.GetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Informs the PlayFab match-making service that the user specified has left the Game Server Instance - / https://api.playfab.com/Documentation/Server/method/NotifyMatchmakerPlayerLeft + * Retrieves the title news feed, as configured in the developer portal + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/gettitlenews */ - NotifyMatchmakerPlayerLeft(request: PlayFabServerModels.NotifyMatchmakerPlayerLeftRequest, callback: PlayFabModule.ApiCallback): void; + GetTitleNews(request: PlayFabServerModels.GetTitleNewsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Validates a Game Server session ticket and returns details about the user - / https://api.playfab.com/Documentation/Server/method/RedeemMatchmakerTicket + * Retrieves the relevant details for a specified user + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getuseraccountinfo */ - RedeemMatchmakerTicket(request: PlayFabServerModels.RedeemMatchmakerTicketRequest, callback: PlayFabModule.ApiCallback): void; + GetUserAccountInfo(request: PlayFabServerModels.GetUserAccountInfoRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set the state of the indicated Game Server Instance. Also update the heartbeat for the instance. - / https://api.playfab.com/Documentation/Server/method/RefreshGameServerInstanceHeartbeat + * Gets all bans for a user. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/getuserbans */ - RefreshGameServerInstanceHeartbeat(request: PlayFabServerModels.RefreshGameServerInstanceHeartbeatRequest, callback: PlayFabModule.ApiCallback): void; + GetUserBans(request: PlayFabServerModels.GetUserBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Inform the matchmaker that a new Game Server Instance is added. - / https://api.playfab.com/Documentation/Server/method/RegisterGame + * Retrieves the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserdata */ - RegisterGame(request: PlayFabServerModels.RegisterGameRequest, callback: PlayFabModule.ApiCallback): void; + GetUserData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Sets the custom data of the indicated Game Server Instance - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceData + * Retrieves the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserinternaldata */ - SetGameServerInstanceData(request: PlayFabServerModels.SetGameServerInstanceDataRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set the state of the indicated Game Server Instance. - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceState + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Retrieves the specified user's current inventory of virtual goods + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/getuserinventory */ - SetGameServerInstanceState(request: PlayFabServerModels.SetGameServerInstanceStateRequest, callback: PlayFabModule.ApiCallback): void; + GetUserInventory(request: PlayFabServerModels.GetUserInventoryRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Set custom tags for the specified Game Server Instance - / https://api.playfab.com/Documentation/Server/method/SetGameServerInstanceTags + * Retrieves the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherdata */ - SetGameServerInstanceTags(request: PlayFabServerModels.SetGameServerInstanceTagsRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Awards the specified users the specified Steam achievements - / https://api.playfab.com/Documentation/Server/method/AwardSteamAchievement + * Retrieves the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherinternaldata */ - AwardSteamAchievement(request: PlayFabServerModels.AwardSteamAchievementRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherInternalData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a character-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WriteCharacterEvent + * Retrieves the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserpublisherreadonlydata */ - WriteCharacterEvent(request: PlayFabServerModels.WriteServerCharacterEventRequest, callback: PlayFabModule.ApiCallback): void; + GetUserPublisherReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a player-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WritePlayerEvent + * Retrieves the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/getuserreadonlydata */ - WritePlayerEvent(request: PlayFabServerModels.WriteServerPlayerEventRequest, callback: PlayFabModule.ApiCallback): void; + GetUserReadOnlyData(request: PlayFabServerModels.GetUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Writes a title-based event into PlayStream. - / https://api.playfab.com/Documentation/Server/method/WriteTitleEvent + * Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated + * with the parent PlayFabId to guarantee uniqueness. + * https://docs.microsoft.com/rest/api/playfab/server/characters/grantcharactertouser */ - WriteTitleEvent(request: PlayFabServerModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback): void; + GrantCharacterToUser(request: PlayFabServerModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds users to the set of those able to update both the shared data, as well as the set of users in the group. Only users in the group (and the server) can add new members. - / https://api.playfab.com/Documentation/Server/method/AddSharedGroupMembers + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified character's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstocharacter */ - AddSharedGroupMembers(request: PlayFabServerModels.AddSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToCharacter(request: PlayFabServerModels.GrantItemsToCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Requests the creation of a shared group object, containing key/value pairs which may be updated by all members of the group. When created by a server, the group will initially have no members. - / https://api.playfab.com/Documentation/Server/method/CreateSharedGroup + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstouser */ - CreateSharedGroup(request: PlayFabServerModels.CreateSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUser(request: PlayFabServerModels.GrantItemsToUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes a shared group, freeing up the shared group ID to be reused for a new group - / https://api.playfab.com/Documentation/Server/method/DeleteSharedGroup + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the specified items to the specified user inventories + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/grantitemstousers */ - DeleteSharedGroup(request: PlayFabServerModels.DeleteSharedGroupRequest, callback: PlayFabModule.ApiCallback): void; + GrantItemsToUsers(request: PlayFabServerModels.GrantItemsToUsersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves data stored in a shared group object, as well as the list of members in the group. The server can access all public and private group data. - / https://api.playfab.com/Documentation/Server/method/GetSharedGroupData + * Links the Battle.net account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkbattlenetaccount */ - GetSharedGroupData(request: PlayFabServerModels.GetSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + LinkBattleNetAccount(request: PlayFabServerModels.LinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the group can remove members. If as a result of the call, zero users remain with access, the group and its associated data will be deleted. - / https://api.playfab.com/Documentation/Server/method/RemoveSharedGroupMembers + * Links the Nintendo account associated with the token to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoserviceaccount */ - RemoveSharedGroupMembers(request: PlayFabServerModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccount(request: PlayFabServerModels.LinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated or added in this call will be readable by users not in the group. By default, data permissions are set to Private. Regardless of the permission setting, only members of the group (and the server) can update the data. - / https://api.playfab.com/Documentation/Server/method/UpdateSharedGroupData + * Links the Nintendo account associated with the Nintendo Service Account subject or id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoserviceaccountsubject */ - UpdateSharedGroupData(request: PlayFabServerModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoServiceAccountSubject(request: PlayFabServerModels.LinkNintendoServiceAccountSubjectRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Executes a CloudScript function, with the 'currentPlayerId' variable set to the specified PlayFabId parameter value. - / https://api.playfab.com/Documentation/Server/method/ExecuteCloudScript + * Links the NintendoSwitchDeviceId to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linknintendoswitchdeviceid */ - ExecuteCloudScript(request: PlayFabServerModels.ExecuteCloudScriptServerRequest, callback: PlayFabModule.ApiCallback): void; + LinkNintendoSwitchDeviceId(request: PlayFabServerModels.LinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / This API retrieves a pre-signed URL for accessing a content file for the title. A subsequent HTTP GET to the returned URL will attempt to download the content. A HEAD query to the returned URL will attempt to retrieve the metadata of the content. Note that a successful result does not guarantee the existence of this content - if it has not been uploaded, the query to retrieve the data will fail. See this post for more information: https://community.playfab.com/hc/en-us/community/posts/205469488-How-to-upload-files-to-PlayFab-s-Content-Service. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply. - / https://api.playfab.com/Documentation/Server/method/GetContentDownloadUrl + * Links the PlayStation :tm: Network account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkpsnaccount */ - GetContentDownloadUrl(request: PlayFabServerModels.GetContentDownloadUrlRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNAccount(request: PlayFabServerModels.LinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Deletes the specific character ID from the specified user. - / https://api.playfab.com/Documentation/Server/method/DeleteCharacterFromUser + * Links the PlayStation :tm: Network account associated with the provided user id to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkpsnid */ - DeleteCharacterFromUser(request: PlayFabServerModels.DeleteCharacterFromUserRequest, callback: PlayFabModule.ApiCallback): void; + LinkPSNId(request: PlayFabServerModels.LinkPSNIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Lists all of the characters that belong to a specific user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Server/method/GetAllUsersCharacters + * Links the custom server identifier, generated by the title, to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkservercustomid */ - GetAllUsersCharacters(request: PlayFabServerModels.ListUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + LinkServerCustomId(request: PlayFabServerModels.LinkServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, starting from the indicated point in the leaderboard - / https://api.playfab.com/Documentation/Server/method/GetCharacterLeaderboard + * Links the Steam account associated with the provided Steam ID to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linksteamid */ - GetCharacterLeaderboard(request: PlayFabServerModels.GetCharacterLeaderboardRequest, callback: PlayFabModule.ApiCallback): void; + LinkSteamId(request: PlayFabServerModels.LinkSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the details of all title-specific statistics for the specific character - / https://api.playfab.com/Documentation/Server/method/GetCharacterStatistics + * Links the Twitch account associated with the token to the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linktwitchaccount */ - GetCharacterStatistics(request: PlayFabServerModels.GetCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LinkTwitchAccount(request: PlayFabServerModels.LinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of ranked characters for the given statistic, centered on the requested user - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardAroundCharacter + * Links the Xbox Live account associated with the provided access code to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkxboxaccount */ - GetLeaderboardAroundCharacter(request: PlayFabServerModels.GetLeaderboardAroundCharacterRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxAccount(request: PlayFabServerModels.LinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves a list of all of the user's characters for the given statistic. - / https://api.playfab.com/Documentation/Server/method/GetLeaderboardForUserCharacters + * Links the Xbox Live account associated with the provided Xbox ID and Sandbox to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/linkxboxid */ - GetLeaderboardForUserCharacters(request: PlayFabServerModels.GetLeaderboardForUsersCharactersRequest, callback: PlayFabModule.ApiCallback): void; + LinkXboxId(request: PlayFabServerModels.LinkXboxIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Grants the specified character type to the user. CharacterIds are not globally unique; characterId must be evaluated with the parent PlayFabId to guarantee uniqueness. - / https://api.playfab.com/Documentation/Server/method/GrantCharacterToUser + * Retrieves title-specific custom property values for a player. + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/listplayercustomproperties */ - GrantCharacterToUser(request: PlayFabServerModels.GrantCharacterToUserRequest, callback: PlayFabModule.ApiCallback): void; + ListPlayerCustomProperties(request: PlayFabServerModels.ListPlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the values of the specified title-specific statistics for the specific character - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterStatistics + * Signs the user in using the Android device identifier, returning a session identifier that can subsequently be used for + * API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithandroiddeviceid */ - UpdateCharacterStatistics(request: PlayFabServerModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithAndroidDeviceID(request: PlayFabServerModels.LoginWithAndroidDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterData + * Sign in the user with a Battle.net identity token + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithbattlenet */ - GetCharacterData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithBattleNet(request: PlayFabServerModels.LoginWithBattleNetRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user's character which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterInternalData + * Signs the user in using a custom unique identifier generated by the title, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithcustomid */ - GetCharacterInternalData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithCustomID(request: PlayFabServerModels.LoginWithCustomIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves the title-specific custom data for the user's character which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/GetCharacterReadOnlyData + * Signs the user in using the iOS device identifier, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithiosdeviceid */ - GetCharacterReadOnlyData(request: PlayFabServerModels.GetCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithIOSDeviceID(request: PlayFabServerModels.LoginWithIOSDeviceIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's chjaracter which is readable and writable by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterData + * Signs the user in using a PlayStation :tm: Network authentication code, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithpsn */ - UpdateCharacterData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithPSN(request: PlayFabServerModels.LoginWithPSNRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's character which cannot be accessed by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterInternalData + * Securely login a game client from an external server backend using a custom identifier for that player. Server Custom ID + * and Client Custom ID are mutually exclusive and cannot be used to retrieve the same player account. + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithservercustomid */ - UpdateCharacterInternalData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithServerCustomId(request: PlayFabServerModels.LoginWithServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Updates the title-specific custom data for the user's character which can only be read by the client - / https://api.playfab.com/Documentation/Server/method/UpdateCharacterReadOnlyData + * Signs the user in using an Steam ID, returning a session identifier that can subsequently be used for API calls which + * require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithsteamid */ - UpdateCharacterReadOnlyData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithSteamId(request: PlayFabServerModels.LoginWithSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Adds a given tag to a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Server/method/AddPlayerTag + * Sign in the user with a Twitch access token + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithtwitch */ - AddPlayerTag(request: PlayFabServerModels.AddPlayerTagRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithTwitch(request: PlayFabServerModels.LoginWithTwitchRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieve a list of all PlayStream actions groups. - / https://api.playfab.com/Documentation/Server/method/GetAllActionGroups + * Signs the user in using a Xbox Live Token from an external server backend, returning a session identifier that can + * subsequently be used for API calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithxbox */ - GetAllActionGroups(request: PlayFabServerModels.GetAllActionGroupsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXbox(request: PlayFabServerModels.LoginWithXboxRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Retrieves an array of player segment definitions. Results from this can be used in subsequent API calls such as GetPlayersInSegment which requires a Segment ID. While segment names can change the ID for that segment will not change. - / https://api.playfab.com/Documentation/Server/method/GetAllSegments + * Signs the user in using an Xbox ID and Sandbox ID, returning a session identifier that can subsequently be used for API + * calls which require an authenticated user + * https://docs.microsoft.com/rest/api/playfab/server/authentication/loginwithxboxid */ - GetAllSegments(request: PlayFabServerModels.GetAllSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + LoginWithXboxId(request: PlayFabServerModels.LoginWithXboxIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / List all segments that a player currently belongs to at this moment in time. - / https://api.playfab.com/Documentation/Server/method/GetPlayerSegments + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Modifies the number of remaining uses of a player's inventory item + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/modifyitemuses */ - GetPlayerSegments(request: PlayFabServerModels.GetPlayersSegmentsRequest, callback: PlayFabModule.ApiCallback): void; + ModifyItemUses(request: PlayFabServerModels.ModifyItemUsesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Allows for paging through all players in a given segment. This API creates a snapshot of all player profiles that match the segment definition at the time of its creation and lives through the Total Seconds to Live, refreshing its life span on each subsequent use of the Continuation Token. Profiles that change during the course of paging will not be reflected in the results. AB Test segments are currently not supported by this operation. - / https://api.playfab.com/Documentation/Server/method/GetPlayersInSegment + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a character's inventory into another of the users's character's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtocharacterfromcharacter */ - GetPlayersInSegment(request: PlayFabServerModels.GetPlayersInSegmentRequest, callback: PlayFabModule.ApiCallback): void; + MoveItemToCharacterFromCharacter(request: PlayFabServerModels.MoveItemToCharacterFromCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Get all tags with a given Namespace (optional) from a player profile. - / https://api.playfab.com/Documentation/Server/method/GetPlayerTags + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a user's inventory into their character's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtocharacterfromuser */ - GetPlayerTags(request: PlayFabServerModels.GetPlayerTagsRequest, callback: PlayFabModule.ApiCallback): void; + MoveItemToCharacterFromUser(request: PlayFabServerModels.MoveItemToCharacterFromUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. - / https://api.playfab.com/Documentation/Server/method/RemovePlayerTag + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Moves an item from a character's inventory into the owning user's inventory. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/moveitemtouserfromcharacter */ - RemovePlayerTag(request: PlayFabServerModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback): void; - - } -} - -declare module PlayFabServerModels { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ActionsOnPlayersInSegmentTaskSummary - */ - export interface ActionsOnPlayersInSegmentTaskSummary { + MoveItemToUserFromCharacter(request: PlayFabServerModels.MoveItemToUserFromCharacterRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / ID of the task instance. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Adds the virtual goods associated with the coupon to the user's inventory. Coupons can be generated via the + * Economy->Catalogs tab in the PlayFab Game Manager. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/redeemcoupon */ - TaskInstanceId?: string; + RedeemCoupon(request: PlayFabServerModels.RedeemCouponRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Identifier of the task this instance belongs to. + * Removes the specified friend from the the user's friend list + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/removefriend */ - TaskIdentifier?: NameIdentifier; + RemoveFriend(request: PlayFabServerModels.RemoveFriendRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task started. + * Removes the specified generic service identifier from the player's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/removegenericid */ - StartedAt: string; + RemoveGenericID(request: PlayFabServerModels.RemoveGenericIDRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC timestamp when the task completed. + * Remove a given tag from a player profile. The tag's namespace is automatically generated based on the source of the tag. + * https://docs.microsoft.com/rest/api/playfab/server/playstream/removeplayertag */ - CompletedAt?: string; + RemovePlayerTag(request: PlayFabServerModels.RemovePlayerTagRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Current status of the task instance. + * Removes users from the set of those able to update the shared data and the set of users in the group. Only users in the + * group can remove members. If as a result of the call, zero users remain with access, the group and its associated data + * will be deleted. Shared Groups are designed for sharing data between a very small number of players, please see our + * guide: https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/removesharedgroupmembers */ - Status?: string; + RemoveSharedGroupMembers(request: PlayFabServerModels.RemoveSharedGroupMembersRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Progress represented as percentage. + * Submit a report about a player (due to bad bahavior, etc.) on behalf of another player, so that customer service + * representatives for the title can take action concerning potentially toxic players. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/reportplayer */ - PercentComplete?: number; + ReportPlayer(request: PlayFabServerModels.ReportPlayerServerRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Estimated time remaining in seconds. + * Revoke all active bans for a user. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/revokeallbansforuser */ - EstimatedSecondsRemaining?: number; + RevokeAllBansForUser(request: PlayFabServerModels.RevokeAllBansForUserRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / If manually scheduled, ID of user who scheduled the task. + * Revoke all active bans specified with BanId. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/revokebans */ - ScheduledByUserId?: string; + RevokeBans(request: PlayFabServerModels.RevokeBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Error message for last processing attempt, if an error occured. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access to an item in a user's inventory + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/revokeinventoryitem */ - ErrorMessage?: string; + RevokeInventoryItem(request: PlayFabServerModels.RevokeInventoryItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Flag indicating if the error was fatal, if false job will be retried. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Revokes access for up to 25 items across multiple users and characters. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/revokeinventoryitems */ - ErrorWasFatal?: boolean; + RevokeInventoryItems(request: PlayFabServerModels.RevokeInventoryItemsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total players in segment when task was started. + * Saves push notification template for title + * https://docs.microsoft.com/rest/api/playfab/server/account-management/savepushnotificationtemplate */ - TotalPlayersInSegment?: number; + SavePushNotificationTemplate(request: PlayFabServerModels.SavePushNotificationTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Total number of players that have had the actions applied to. + * Forces an email to be sent to the registered contact email address for the user's account based on an account recovery + * email template + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendcustomaccountrecoveryemail */ - TotalPlayersProcessed?: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AdCampaignAttribution - */ - export interface AdCampaignAttribution { + SendCustomAccountRecoveryEmail(request: PlayFabServerModels.SendCustomAccountRecoveryEmailRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Sends an email based on an email template to a player's contact email + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendemailfromtemplate */ - Platform?: string; + SendEmailFromTemplate(request: PlayFabServerModels.SendEmailFromTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Sends an iOS/Android Push Notification to a specific user, if that user's device has been configured for Push + * Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendpushnotification */ - CampaignId?: string; + SendPushNotification(request: PlayFabServerModels.SendPushNotificationRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Sends an iOS/Android Push Notification template to a specific user, if that user's device has been configured for Push + * Notifications in PlayFab. If a user has linked both Android and iOS devices, both will be notified. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/sendpushnotificationfromtemplate */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AdCampaignAttributionModel - */ - export interface AdCampaignAttributionModel { + SendPushNotificationFromTemplate(request: PlayFabServerModels.SendPushNotificationFromTemplateRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution network name + * Updates the tag list for a specified user in the friend list of another user + * https://docs.microsoft.com/rest/api/playfab/server/friend-list-management/setfriendtags */ - Platform?: string; + SetFriendTags(request: PlayFabServerModels.SetFriendTagsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Attribution campaign identifier + * Sets the player's secret if it is not already set. Player secrets are used to sign API requests. To reset a player's + * secret use the Admin or Server API method SetPlayerSecret. + * https://docs.microsoft.com/rest/api/playfab/server/authentication/setplayersecret */ - CampaignId?: string; + SetPlayerSecret(request: PlayFabServerModels.SetPlayerSecretRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / UTC time stamp of attribution + * Updates the key-value store of custom publisher settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/setpublisherdata */ - AttributedAt: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddCharacterVirtualCurrencyRequest - */ - export interface AddCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { + SetPublisherData(request: PlayFabServerModels.SetPublisherDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / PlayFab unique identifier of the user whose virtual currency balance is to be incremented. + * Updates the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/settitledata */ - PlayFabId: string; + SetTitleData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Updates the key-value store of custom title settings + * https://docs.microsoft.com/rest/api/playfab/server/title-wide-data-management/settitleinternaldata */ - CharacterId: string; + SetTitleInternalData(request: PlayFabServerModels.SetTitleDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Name of the virtual currency which is to be incremented. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the character's balance of the specified virtual currency by the stated amount. It is possible to + * make a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/subtractcharactervirtualcurrency */ - VirtualCurrency: string; + SubtractCharacterVirtualCurrency(request: PlayFabServerModels.SubtractCharacterVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Amount to be added to the character balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Decrements the user's balance of the specified virtual currency by the stated amount. It is possible to make + * a VC balance negative with this API. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/subtractuservirtualcurrency */ - Amount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddFriendRequest - */ - export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { + SubtractUserVirtualCurrency(request: PlayFabServerModels.SubtractUserVirtualCurrencyRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / PlayFab identifier of the player to add a new friend. + * Unlinks the related Apple account from the specified user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkapple */ - PlayFabId: string; + UnlinkApple(request: PlayFabServerModels.UnlinkAppleRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / The PlayFab identifier of the user being added. + * Unlinks the related Battle.net account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkbattlenetaccount */ - FriendPlayFabId?: string; + UnlinkBattleNetAccount(request: PlayFabServerModels.UnlinkBattleNetAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / The PlayFab username of the user being added + * Unlinks the related Facebook account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkfacebookaccount */ - FriendUsername?: string; + UnlinkFacebookAccount(request: PlayFabServerModels.UnlinkFacebookAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Email address of the user being added. + * Unlinks the related Facebook Instant Games identifier from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkfacebookinstantgamesid */ - FriendEmail?: string; + UnlinkFacebookInstantGamesId(request: PlayFabServerModels.UnlinkFacebookInstantGamesIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; /** - / Title-specific display name of the user to being added. + * Unlinks the related Game Center account from the specified user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkgamecenteraccount */ - FriendTitleDisplayName?: string; + UnlinkGameCenterAccount(request: PlayFabServerModels.UnlinkGameCenterAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Nintendo account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinknintendoserviceaccount + */ + UnlinkNintendoServiceAccount(request: PlayFabServerModels.UnlinkNintendoServiceAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related NintendoSwitchDeviceId from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinknintendoswitchdeviceid + */ + UnlinkNintendoSwitchDeviceId(request: PlayFabServerModels.UnlinkNintendoSwitchDeviceIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related PlayStation :tm: Network account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkpsnaccount + */ + UnlinkPSNAccount(request: PlayFabServerModels.UnlinkPSNAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the custom server identifier from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkservercustomid + */ + UnlinkServerCustomId(request: PlayFabServerModels.UnlinkServerCustomIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the Steam account associated with the provided Steam ID to the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinksteamid + */ + UnlinkSteamId(request: PlayFabServerModels.UnlinkSteamIdRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Twitch account from the user's PlayFab account. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinktwitchaccount + */ + UnlinkTwitchAccount(request: PlayFabServerModels.UnlinkTwitchAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Unlinks the related Xbox Live account from the user's PlayFab account + * https://docs.microsoft.com/rest/api/playfab/server/account-management/unlinkxboxaccount + */ + UnlinkXboxAccount(request: PlayFabServerModels.UnlinkXboxAccountRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Opens a specific container (ContainerItemInstanceId), with a specific key (KeyItemInstanceId, when + * required), and returns the contents of the opened container. If the container (and key when relevant) are consumable + * (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/unlockcontainerinstance + */ + UnlockContainerInstance(request: PlayFabServerModels.UnlockContainerInstanceRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Searches Player or Character inventory for any ItemInstance matching the given CatalogItemId, if necessary + * unlocks it using any appropriate key, and returns the contents of the opened container. If the container (and key when + * relevant) are consumable (RemainingUses > 0), their RemainingUses will be decremented, consistent with the operation of + * ConsumeItem. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/unlockcontaineritem + */ + UnlockContainerItem(request: PlayFabServerModels.UnlockContainerItemRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Update the avatar URL of the specified player + * https://docs.microsoft.com/rest/api/playfab/server/account-management/updateavatarurl + */ + UpdateAvatarUrl(request: PlayFabServerModels.UpdateAvatarUrlRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates information of a list of existing bans specified with Ban Ids. + * https://docs.microsoft.com/rest/api/playfab/server/account-management/updatebans + */ + UpdateBans(request: PlayFabServerModels.UpdateBansRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterdata + */ + UpdateCharacterData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterinternaldata + */ + UpdateCharacterInternalData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user's character which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/character-data/updatecharacterreadonlydata + */ + UpdateCharacterReadOnlyData(request: PlayFabServerModels.UpdateCharacterDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the values of the specified title-specific statistics for the specific character + * https://docs.microsoft.com/rest/api/playfab/server/characters/updatecharacterstatistics + */ + UpdateCharacterStatistics(request: PlayFabServerModels.UpdateCharacterStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom property values for a player + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateplayercustomproperties + */ + UpdatePlayerCustomProperties(request: PlayFabServerModels.UpdatePlayerCustomPropertiesRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the values of the specified title-specific statistics for the user + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateplayerstatistics + */ + UpdatePlayerStatistics(request: PlayFabServerModels.UpdatePlayerStatisticsRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Adds, updates, and removes data keys for a shared group object. If the permission is set to Public, all fields updated + * or added in this call will be readable by users not in the group. By default, data permissions are set to Private. + * Regardless of the permission setting, only members of the group (and the server) can update the data. Shared Groups are + * designed for sharing data between a very small number of players, please see our guide: + * https://docs.microsoft.com/gaming/playfab/features/social/groups/using-shared-group-data + * https://docs.microsoft.com/rest/api/playfab/server/shared-group-data/updatesharedgroupdata + */ + UpdateSharedGroupData(request: PlayFabServerModels.UpdateSharedGroupDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserdata + */ + UpdateUserData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserinternaldata + */ + UpdateUserInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * _NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for + * version 2._ Updates the key-value pair data tagged to the specified item, which is read-only from the client. + * https://docs.microsoft.com/rest/api/playfab/server/player-item-management/updateuserinventoryitemcustomdata + */ + UpdateUserInventoryItemCustomData(request: PlayFabServerModels.UpdateUserInventoryItemDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which is readable and writable by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherdata + */ + UpdateUserPublisherData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which cannot be accessed by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherinternaldata + */ + UpdateUserPublisherInternalData(request: PlayFabServerModels.UpdateUserInternalDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the publisher-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserpublisherreadonlydata + */ + UpdateUserPublisherReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Updates the title-specific custom data for the user which can only be read by the client + * https://docs.microsoft.com/rest/api/playfab/server/player-data-management/updateuserreadonlydata + */ + UpdateUserReadOnlyData(request: PlayFabServerModels.UpdateUserDataRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a character-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writecharacterevent + */ + WriteCharacterEvent(request: PlayFabServerModels.WriteServerCharacterEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a player-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writeplayerevent + */ + WritePlayerEvent(request: PlayFabServerModels.WriteServerPlayerEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; + /** + * Writes a title-based event into PlayStream. + * https://docs.microsoft.com/rest/api/playfab/server/analytics/writetitleevent + */ + WriteTitleEvent(request: PlayFabServerModels.WriteTitleEventRequest, callback: PlayFabModule.ApiCallback, customData?: any, extraHeaders?: { [key: string]: string }): Promise>; } +} - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddPlayerTagRequest - */ - export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { +declare module PlayFabServerModels { + export interface AdCampaignAttributionModel { + /** UTC time stamp of attribution */ + AttributedAt: string; + /** Attribution campaign identifier */ + CampaignId?: string; + /** Attribution network name */ + Platform?: string; + + } + + export interface AddCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Amount to be added to the character balance of the specified virtual currency. Maximum VC balance is Int32 + * (2,147,483,647). Any increase over this value will be discarded. */ + Amount: number; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be incremented. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Name of the virtual currency which is to be incremented. */ + VirtualCurrency: string; + + } + + export interface AddFriendRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Email address of the user being added. */ + FriendEmail?: string; + /** The PlayFab identifier of the user being added. */ + FriendPlayFabId?: string; + /** Title-specific display name of the user to being added. */ + FriendTitleDisplayName?: string; + /** The PlayFab username of the user being added */ + FriendUsername?: string; + /** PlayFab identifier of the player to add a new friend. */ + PlayFabId: string; + + } + + export interface AddGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Generic service identifier to add to the player account. */ + GenericId: GenericServiceId; + /** PlayFabId of the user to link. */ + PlayFabId: string; + + } + + export interface AddOrUpdateContactEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The new contact email to associate with the player. */ + EmailAddress: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface AddOrUpdateContactEmailResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface AddPlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddPlayerTagResult - */ export interface AddPlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddSharedGroupMembersRequest - */ export interface AddSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddSharedGroupMembersResult - */ export interface AddSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AddUserVirtualCurrencyRequest - */ export interface AddUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / PlayFab unique identifier of the user whose virtual currency balance is to be increased. + * Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). + * Any increase over this value will be discarded. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be increased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be incremented. - */ + /** Name of the virtual currency which is to be incremented. */ VirtualCurrency: string; + + } + + export interface AdvancedPushPlatformMsg { /** - / Amount to be added to the user balance of the specified virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. + * Stops GoogleCloudMessaging notifications from including both notification and data properties and instead only sends the + * data property. */ - Amount: number; + GCMDataOnly?: boolean; + /** The Json the platform should receive. */ + Json: string; + /** The platform that should receive the Json. */ + Platform: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AuthenticateSessionTicketRequest - */ export interface AuthenticateSessionTicketRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Session ticket as issued by a PlayFab client login API. - */ + /** Session ticket as issued by a PlayFab client login API. */ SessionTicket: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AuthenticateSessionTicketResult - */ export interface AuthenticateSessionTicketResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account info for the user whose session ticket was supplied. - */ + /** Indicates if token was expired at request time. */ + IsSessionTicketExpired?: boolean; + /** Account info for the user whose session ticket was supplied. */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementItem - */ export interface AwardSteamAchievementItem { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique Steam achievement name. - */ + /** Unique Steam achievement name. */ AchievementName: string; - /** - / Result of the award attempt (only valid on response, not on request). - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Result of the award attempt (only valid on response, not on request). */ Result: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementRequest - */ export interface AwardSteamAchievementRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Array of achievements to grant and the users to whom they are to be granted. - */ + /** Array of achievements to grant and the users to whom they are to be granted. */ Achievements: AwardSteamAchievementItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.AwardSteamAchievementResult - */ export interface AwardSteamAchievementResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of achievements granted. - */ + /** Array of achievements granted. */ AchievementResults?: AwardSteamAchievementItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanInfo - */ export interface BanInfo { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / The unique Ban Id associated with this ban. - */ + /** The active state of this ban. Expired bans may still have this value set to true but they will have no effect. */ + Active: boolean; + /** The unique Ban Id associated with this ban. */ BanId?: string; - /** - / The IP address on which the ban was applied. May affect multiple players. - */ - IPAddress?: string; - /** - / The MAC address on which the ban was applied. May affect multiple players. - */ - MACAddress?: string; - /** - / The time when this ban was applied. - */ + /** The time when this ban was applied. */ Created?: string; - /** - / The time when this ban expires. Permanent bans do not have expiration date. - */ + /** The time when this ban expires. Permanent bans do not have expiration date. */ Expires?: string; - /** - / The reason why this ban was applied. - */ + /** The IP address on which the ban was applied. May affect multiple players. */ + IPAddress?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** The reason why this ban was applied. */ Reason?: string; - /** - / The active state of this ban. Expired bans may still have this value set to true but they will have no effect. - */ - Active: boolean; + /** The family type of the user that is included in the ban. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanRequest - */ - export interface BanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / IP address to be banned. May affect multiple players. - */ + export interface BanRequest { + /** The duration in hours for the ban. Leave this blank for a permanent ban. */ + DurationInHours?: number; + /** IP address to be banned. May affect multiple players. */ IPAddress?: string; - /** - / MAC address to be banned. May affect multiple players. - */ - MACAddress?: string; - /** - / The reason for this ban. Maximum 140 characters. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The reason for this ban. Maximum 140 characters. */ Reason?: string; - /** - / The duration in hours for the ban. Leave this blank for a permanent ban. - */ - DurationInHours?: number; + /** The family type of the user that should be included in the ban if applicable. May affect multiple players. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanUsersRequest - */ export interface BanUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of ban requests to be applied. Maximum 100. - */ + /** List of ban requests to be applied. Maximum 100. */ Bans: BanRequest[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.BanUsersResult - */ export interface BanUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were applied - */ + /** Information on the bans that were applied */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItem - */ + export interface BattleNetAccountPlayFabIdPair { + /** Unique Battle.net account identifier for a user. */ + BattleNetAccountId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Battle.net account identifier. */ + PlayFabId?: string; + + } + export interface CatalogItem { /** - / unique identifier for this item - */ - ItemId: string; - /** - / class to which the item belongs - */ - ItemClass?: string; - /** - / catalog version for this item + * defines the bundle properties for the item - bundles are items which contain other items, including random drop tables + * and virtual currencies */ + Bundle?: CatalogItemBundleInfo; + /** if true, then an item instance of this type can be used to grant a character to a user. */ + CanBecomeCharacter: boolean; + /** catalog version for this item */ CatalogVersion?: string; + /** defines the consumable properties (number of uses, timeout) for the item */ + Consumable?: CatalogItemConsumableInfo; /** - / text name for the item, to show in-game + * defines the container properties for the item - what items it contains, including random drop tables and virtual + * currencies, and what item (if any) is required to open it via the UnlockContainerItem API */ + Container?: CatalogItemContainerInfo; + /** game specific custom data */ + CustomData?: string; + /** text description of item, to show in-game */ + Description?: string; + /** text name for the item, to show in-game */ DisplayName?: string; /** - / text description of item, to show in-game + * If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited + * edition item, this value determines the total number of instances to allocate for the title. Once this limit has been + * reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of + * false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less + * than zero, it will be ignored. */ - Description?: string; + InitialLimitedEditionCount: number; + /** BETA: If true, then only a fixed number can ever be granted. */ + IsLimitedEdition: boolean; /** - / price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) + * if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. + * RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded */ - VirtualCurrencyPrices?: { [key: string]: number }; + IsStackable: boolean; + /** if true, then an item instance of this type can be traded between players using the trading APIs */ + IsTradable: boolean; + /** class to which the item belongs */ + ItemClass?: string; + /** unique identifier for this item */ + ItemId: string; /** - / override prices for this item for specific currencies + * URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP + * URL. */ + ItemImageUrl?: string; + /** override prices for this item for specific currencies */ RealCurrencyPrices?: { [key: string]: number }; - /** - / list of item tags - */ + /** list of item tags */ Tags?: string[]; + /** price of this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface CatalogItemBundleInfo { + /** unique ItemId values for all items which will be added to the player inventory when the bundle is added */ + BundledItems?: string[]; /** - / game specific custom data + * unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and + * add the relevant items to the player inventory when the bundle is added) */ - CustomData?: string; + BundledResultTables?: string[]; + /** virtual currency types and balances which will be added to the player inventory when the bundle is added */ + BundledVirtualCurrencies?: { [key: string]: number }; + + } + + export interface CatalogItemConsumableInfo { + /** number of times this object can be used, after which it will be removed from the player inventory */ + UsageCount?: number; /** - / defines the consumable properties (number of uses, timeout) for the item + * duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed + * (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on + * this item's details have completed) */ - Consumable?: CatalogItemConsumableInfo; + UsagePeriod?: number; /** - / defines the container properties for the item - what items it contains, including random drop tables and virtual currencies, and what item (if any) is required to open it via the UnlockContainerItem API + * all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values + * added together, and share the result - when that period has elapsed, all the items in the group will be removed */ - Container?: CatalogItemContainerInfo; + UsagePeriodGroup?: string; + + } + + export interface CatalogItemContainerInfo { + /** unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked */ + ItemContents?: string[]; /** - / defines the bundle properties for the item - bundles are items which contain other items, including random drop tables and virtual currencies + * ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will + * open the container, adding the contents to the player inventory and currency balances) */ - Bundle?: CatalogItemBundleInfo; + KeyItemId?: string; /** - / if true, then an item instance of this type can be used to grant a character to a user. - */ - CanBecomeCharacter: boolean; - /** - / if true, then only one item instance of this type will exist and its remaininguses will be incremented instead. RemainingUses will cap out at Int32.Max (2,147,483,647). All subsequent increases will be discarded - */ - IsStackable: boolean; - /** - / if true, then an item instance of this type can be traded between players using the trading APIs - */ - IsTradable: boolean; - /** - / URL to the item image. For Facebook purchase to display the image on the item purchase page, this must be set to an HTTP URL. - */ - ItemImageUrl?: string; - /** - / BETA: If true, then only a fixed number can ever be granted. - */ - IsLimitedEdition: boolean; - /** - / If the item has IsLImitedEdition set to true, and this is the first time this ItemId has been defined as a limited edition item, this value determines the total number of instances to allocate for the title. Once this limit has been reached, no more instances of this ItemId can be created, and attempts to purchase or grant it will return a Result of false for that ItemId. If the item has already been defined to have a limited edition count, or if this value is less than zero, it will be ignored. - */ - InitialLimitedEditionCount: number; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemBundleInfo - */ - export interface CatalogItemBundleInfo { - /** - / unique ItemId values for all items which will be added to the player inventory when the bundle is added - */ - BundledItems?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the bundle (random tables will be resolved and add the relevant items to the player inventory when the bundle is added) - */ - BundledResultTables?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the bundle is added - */ - BundledVirtualCurrencies?: { [key: string]: number }; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemConsumableInfo - */ - export interface CatalogItemConsumableInfo { - /** - / number of times this object can be used, after which it will be removed from the player inventory - */ - UsageCount?: number; - /** - / duration in seconds for how long the item will remain in the player inventory - once elapsed, the item will be removed (recommended minimum value is 5 seconds, as lower values can cause the item to expire before operations depending on this item's details have completed) - */ - UsagePeriod?: number; - /** - / all inventory item instances in the player inventory sharing a non-null UsagePeriodGroup have their UsagePeriod values added together, and share the result - when that period has elapsed, all the items in the group will be removed - */ - UsagePeriodGroup?: string; - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CatalogItemContainerInfo - */ - export interface CatalogItemContainerInfo { - /** - / ItemId for the catalog item used to unlock the container, if any (if not specified, a call to UnlockContainerItem will open the container, adding the contents to the player inventory and currency balances) - */ - KeyItemId?: string; - /** - / unique ItemId values for all items which will be added to the player inventory, once the container has been unlocked - */ - ItemContents?: string[]; - /** - / unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables will be resolved and add the relevant items to the player inventory) + * unique TableId values for all RandomResultTable objects which are part of the container (once unlocked, random tables + * will be resolved and add the relevant items to the player inventory) */ ResultTableContents?: string[]; - /** - / virtual currency types and balances which will be added to the player inventory when the container is unlocked - */ + /** virtual currency types and balances which will be added to the player inventory when the container is unlocked */ VirtualCurrencyContents?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterInventory - */ export interface CharacterInventory { - /** - / The id of this character. - */ + /** The id of this character. */ CharacterId?: string; - /** - / The inventory of this character. - */ + /** The inventory of this character. */ Inventory?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterLeaderboardEntry - */ export interface CharacterLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. - */ + /** PlayFab unique identifier of the character that belongs to the user for this leaderboard entry. */ CharacterId?: string; - /** - / Title-specific display name of the character for this leaderboard entry. - */ + /** Title-specific display name of the character for this leaderboard entry. */ CharacterName?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Name of the character class for this entry. - */ + /** Name of the character class for this entry. */ CharacterType?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ Position: number; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CharacterResult - */ - export interface CharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The id for this character on this player. - */ + export interface CharacterResult { + /** The id for this character on this player. */ CharacterId?: string; - /** - / The name of this character. - */ + /** The name of this character. */ CharacterName?: string; - /** - / The type-string that was given to this character on creation. - */ + /** The type-string that was given to this character on creation. */ CharacterType?: string; } type CloudScriptRevisionOption = "Live" + | "Latest" | "Specific"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ConsumeItemRequest - */ export interface ConsumeItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique instance identifier of the item to be consumed. - */ - ItemInstanceId: string; - /** - / Number of uses to consume from the item. - */ - ConsumeCount: number; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** Number of uses to consume from the item. */ + ConsumeCount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be consumed. */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ConsumeItemResult - */ export interface ConsumeItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ + /** Unique instance identifier of the item with uses consumed. */ ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ + /** Number of uses remaining on the item. */ RemainingUses: number; } + export interface ContactEmailInfoModel { + /** The email address */ + EmailAddress?: string; + /** The name of the email info data */ + Name?: string; + /** The verification status of the email */ + VerificationStatus?: string; + + } + type ContinentCode = "AF" + | "AN" | "AS" | "EU" | "NA" | "OC" - | "SA"; + | "SA" + | "Unknown"; type CountryCode = "AF" + | "AX" | "AL" | "DZ" @@ -1406,31 +1562,23 @@ declare module PlayFabServerModels { | "EH" | "YE" | "ZM" - | "ZW"; + | "ZW" + | "Unknown"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CreateSharedGroupRequest - */ export interface CreateSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). - */ + /** Unique identifier for the shared group (a random identifier will be assigned, if one is not specified). */ SharedGroupId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.CreateSharedGroupResult - */ export interface CreateSharedGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the shared group. - */ + /** Unique identifier for the shared group. */ SharedGroupId?: string; } type Currency = "AED" + | "AFN" | "ALL" | "AMD" @@ -1593,3614 +1741,4295 @@ declare module PlayFabServerModels { | "ZMW" | "ZWD"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteCharacterFromUserRequest - */ + export interface CustomPropertyDetails { + /** The custom property's name. */ + Name?: string; + /** The custom property's value. */ + Value?: any; + + } + export interface DeleteCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / If true, the character's inventory will be transferred up to the owning user; otherwise, this request will purge those items. + * If true, the character's inventory will be transferred up to the owning user; otherwise, this request will purge those + * items. */ SaveCharacterInventory: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteCharacterFromUserResult - */ export interface DeleteCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteSharedGroupRequest - */ - export interface DeleteSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; + export interface DeletedPropertyDetails { + /** The name of the property which was requested to be deleted. */ + Name?: string; + /** Indicates whether or not the property was deleted. If false, no property with that name existed. */ + WasDeleted: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteUsersRequest - */ - export interface DeleteUsersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface DeletePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. + * Optional field used for concurrency control. One can ensure that the delete operation will only be performed if the + * player's properties have not been updated by any other clients since the last version. */ - PlayFabIds: string[]; + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** A list of property names denoting which properties should be deleted. */ + PropertyNames: string[]; + + } + + export interface DeletePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** The list of properties requested to be deleted. */ + DeletedProperties?: DeletedPropertyDetails[]; + /** PlayFab unique identifier of the user whose properties were deleted. */ + PlayFabId?: string; /** - / Unique identifier for the title, found in the Settings > Game Properties section of the PlayFab developer site when a title has been selected. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - TitleId: string; + PropertiesVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeleteUsersResult - */ - export interface DeleteUsersResult extends PlayFabModule.IPlayFabResultCommon { + export interface DeletePlayerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeregisterGameRequest - */ - export interface DeregisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the Game Server Instance that is being deregistered. - */ - LobbyId: string; + export interface DeletePlayerResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeletePushNotificationTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Id of the push notification template to be deleted. */ + PushNotificationTemplateId: string; + + } + + export interface DeletePushNotificationTemplateResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface DeleteSharedGroupRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.DeregisterGameResponse - */ - export interface DeregisterGameResponse extends PlayFabModule.IPlayFabResultCommon { + type EmailVerificationStatus = "Unverified" + + | "Pending" + | "Confirmed"; + + export interface EmptyResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EmptyResult - */ export interface EmptyResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EvaluateRandomResultTableRequest - */ + export interface EntityKey { + /** Unique ID of the entity. */ + Id: string; + /** Entity type. See https://docs.microsoft.com/gaming/playfab/features/data/entities/available-built-in-entity-types */ + Type?: string; + + } + + export interface EntityTokenResponse { + /** The entity id and type. */ + Entity?: EntityKey; + /** The token used to set X-EntityToken for all entity based API calls. */ + EntityToken?: string; + /** The time the token will expire, if it is an expiring token, in UTC. */ + TokenExpiration?: string; + + } + export interface EvaluateRandomResultTableRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / The unique identifier of the Random Result Table to use. - */ - TableId: string; - /** - / Specifies the catalog version that should be used to evaluate the Random Result Table. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to evaluate the Random Result Table. If unspecified, uses + * default/primary catalog. */ CatalogVersion?: string; + /** The unique identifier of the Random Result Table to use. */ + TableId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.EvaluateRandomResultTableResult - */ export interface EvaluateRandomResultTableResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for the item returned from the Random Result Table evaluation, for the given catalog. - */ + /** Unique identifier for the item returned from the Random Result Table evaluation, for the given catalog. */ ResultItemId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ExecuteCloudScriptResult - */ export interface ExecuteCloudScriptResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The name of the function that executed - */ + /** Number of PlayFab API requests issued by the CloudScript function */ + APIRequestsIssued: number; + /** Information about the error, if any, that occurred during execution */ + Error?: ScriptExecutionError; + ExecutionTimeSeconds: number; + /** The name of the function that executed */ FunctionName?: string; + /** The object returned from the CloudScript function, if any */ + FunctionResult?: any; /** - / The revision of the CloudScript that executed - */ - Revision: number; - /** - / The object returned from the CloudScript function, if any + * Flag indicating if the FunctionResult was too large and was subsequently dropped from this event. This only occurs if + * the total event size is larger than 350KB. */ - FunctionResult?: any; + FunctionResultTooLarge?: boolean; + /** Number of external HTTP requests issued by the CloudScript function */ + HttpRequestsIssued: number; /** - / Entries logged during the function execution. These include both entries logged in the function code using log.info() and log.error() and error entries for API and HTTP request failures. + * Entries logged during the function execution. These include both entries logged in the function code using log.info() + * and log.error() and error entries for API and HTTP request failures. */ Logs?: LogStatement[]; - ExecutionTimeSeconds: number; /** - / Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP requests. + * Flag indicating if the logs were too large and were subsequently dropped from this event. This only occurs if the total + * event size is larger than 350KB after the FunctionResult was removed. */ - ProcessorTimeSeconds: number; + LogsTooLarge?: boolean; MemoryConsumedBytes: number; /** - / Number of PlayFab API requests issued by the CloudScript function - */ - APIRequestsIssued: number; - /** - / Number of external HTTP requests issued by the CloudScript function - */ - HttpRequestsIssued: number; - /** - / Information about the error, if any, that occured during execution + * Processor time consumed while executing the function. This does not include time spent waiting on API calls or HTTP + * requests. */ - Error?: ScriptExecutionError; + ProcessorTimeSeconds: number; + /** The revision of the CloudScript that executed */ + Revision: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ExecuteCloudScriptServerRequest - */ export interface ExecuteCloudScriptServerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The unique user identifier for the player on whose behalf the script is being run - */ - PlayFabId: string; - /** - / The name of the CloudScript function to execute - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The name of the CloudScript function to execute */ FunctionName: string; - /** - / Object that is passed in to the function as the first argument - */ + /** Object that is passed in to the function as the first argument */ FunctionParameter?: any; /** - / Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' executes the current live, published revision, and 'Specific' executes the specified revision. The default value is 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. + * Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other + * contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. */ - RevisionSelection?: string; + GeneratePlayStreamEvent?: boolean; + /** The unique user identifier for the player on whose behalf the script is being run */ + PlayFabId: string; /** - / The specivic revision to execute, when RevisionSelection is set to 'Specific' + * Option for which revision of the CloudScript to execute. 'Latest' executes the most recently created revision, 'Live' + * executes the current live, published revision, and 'Specific' executes the specified revision. The default value is + * 'Specific', if the SpeificRevision parameter is specified, otherwise it is 'Live'. */ + RevisionSelection?: string; + /** The specivic revision to execute, when RevisionSelection is set to 'Specific' */ SpecificRevision?: number; - /** - / Generate a 'player_executed_cloudscript' PlayStream event containing the results of the function execution and other contextual information. This event will show up in the PlayStream debugger console for the player in Game Manager. - */ - GeneratePlayStreamEvent?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.FacebookPlayFabIdPair - */ + export interface ExportPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the requested segment. */ + SegmentId: string; + + } + + export interface ExportPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId?: string; + /** Unique identifier of the requested Segment. */ + SegmentId?: string; + + } + + type ExternalFriendSources = "None" + + | "Steam" + | "Facebook" + | "Xbox" + | "Psn" + | "All"; + + export interface FacebookInstantGamesPlayFabIdPair { + /** Unique Facebook Instant Games identifier for a user. */ + FacebookInstantGamesId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook Instant Games identifier. */ + PlayFabId?: string; + + } + export interface FacebookPlayFabIdPair { - /** - / Unique Facebook identifier for a user. - */ + /** Unique Facebook identifier for a user. */ FacebookId?: string; - /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. - */ + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Facebook identifier. */ PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.FriendInfo - */ export interface FriendInfo { - /** - / PlayFab unique identifier for this friend. - */ + /** Available Facebook information (if the user and connected Facebook friend both have PlayFab Accounts in the same title). */ + FacebookInfo?: UserFacebookInfo; + /** PlayFab unique identifier for this friend. */ FriendPlayFabId?: string; /** - / PlayFab unique username for this friend. - */ - Username?: string; - /** - / Title-specific display name for this friend. - */ - TitleDisplayName?: string; - /** - / Tags which have been associated with this friend. - */ - Tags?: string[]; - /** - / Unique lobby identifier of the Game Server Instance to which this player is currently connected. + * Available Game Center information (if the user and connected Game Center friend both have PlayFab Accounts in the same + * title). */ - CurrentMatchmakerLobbyId?: string; - /** - / Available Facebook information (if the user and PlayFab friend are also connected in Facebook). - */ - FacebookInfo?: UserFacebookInfo; + GameCenterInfo?: UserGameCenterInfo; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; /** - / Available Steam information (if the user and PlayFab friend are also connected in Steam). + * Available PlayStation :tm: Network information, if the user connected PlayStation :tm Network friend both have PlayFab + * Accounts in the same title. */ + PSNInfo?: UserPsnInfo; + /** Available Steam information (if the user and connected Steam friend both have PlayFab Accounts in the same title). */ SteamInfo?: UserSteamInfo; - /** - / Available Game Center information (if the user and PlayFab friend are also connected in Game Center). - */ - GameCenterInfo?: UserGameCenterInfo; + /** Tags which have been associated with this friend. */ + Tags?: string[]; + /** Title-specific display name for this friend. */ + TitleDisplayName?: string; + /** PlayFab unique username for this friend. */ + Username?: string; + /** Available Xbox information, (if the user and connected Xbox Live friend both have PlayFab Accounts in the same title). */ + XboxInfo?: UserXboxInfo; } - type GameInstanceState = "Open" - | "Closed"; - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetActionGroupResult - */ - export interface GetActionGroupResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Action Group name - */ - Name: string; - /** - / Action Group ID - */ - Id?: string; + type GenericErrorCodes = "Success" + + | "UnkownError" + | "InvalidParams" + | "AccountNotFound" + | "AccountBanned" + | "InvalidUsernameOrPassword" + | "InvalidTitleId" + | "InvalidEmailAddress" + | "EmailAddressNotAvailable" + | "InvalidUsername" + | "InvalidPassword" + | "UsernameNotAvailable" + | "InvalidSteamTicket" + | "AccountAlreadyLinked" + | "LinkedAccountAlreadyClaimed" + | "InvalidFacebookToken" + | "AccountNotLinked" + | "FailedByPaymentProvider" + | "CouponCodeNotFound" + | "InvalidContainerItem" + | "ContainerNotOwned" + | "KeyNotOwned" + | "InvalidItemIdInTable" + | "InvalidReceipt" + | "ReceiptAlreadyUsed" + | "ReceiptCancelled" + | "GameNotFound" + | "GameModeNotFound" + | "InvalidGoogleToken" + | "UserIsNotPartOfDeveloper" + | "InvalidTitleForDeveloper" + | "TitleNameConflicts" + | "UserisNotValid" + | "ValueAlreadyExists" + | "BuildNotFound" + | "PlayerNotInGame" + | "InvalidTicket" + | "InvalidDeveloper" + | "InvalidOrderInfo" + | "RegistrationIncomplete" + | "InvalidPlatform" + | "UnknownError" + | "SteamApplicationNotOwned" + | "WrongSteamAccount" + | "TitleNotActivated" + | "RegistrationSessionNotFound" + | "NoSuchMod" + | "FileNotFound" + | "DuplicateEmail" + | "ItemNotFound" + | "ItemNotOwned" + | "ItemNotRecycleable" + | "ItemNotAffordable" + | "InvalidVirtualCurrency" + | "WrongVirtualCurrency" + | "WrongPrice" + | "NonPositiveValue" + | "InvalidRegion" + | "RegionAtCapacity" + | "ServerFailedToStart" + | "NameNotAvailable" + | "InsufficientFunds" + | "InvalidDeviceID" + | "InvalidPushNotificationToken" + | "NoRemainingUses" + | "InvalidPaymentProvider" + | "PurchaseInitializationFailure" + | "DuplicateUsername" + | "InvalidBuyerInfo" + | "NoGameModeParamsSet" + | "BodyTooLarge" + | "ReservedWordInBody" + | "InvalidTypeInBody" + | "InvalidRequest" + | "ReservedEventName" + | "InvalidUserStatistics" + | "NotAuthenticated" + | "StreamAlreadyExists" + | "ErrorCreatingStream" + | "StreamNotFound" + | "InvalidAccount" + | "PurchaseDoesNotExist" + | "InvalidPurchaseTransactionStatus" + | "APINotEnabledForGameClientAccess" + | "NoPushNotificationARNForTitle" + | "BuildAlreadyExists" + | "BuildPackageDoesNotExist" + | "CustomAnalyticsEventsNotEnabledForTitle" + | "InvalidSharedGroupId" + | "NotAuthorized" + | "MissingTitleGoogleProperties" + | "InvalidItemProperties" + | "InvalidPSNAuthCode" + | "InvalidItemId" + | "PushNotEnabledForAccount" + | "PushServiceError" + | "ReceiptDoesNotContainInAppItems" + | "ReceiptContainsMultipleInAppItems" + | "InvalidBundleID" + | "JavascriptException" + | "InvalidSessionTicket" + | "UnableToConnectToDatabase" + | "InternalServerError" + | "InvalidReportDate" + | "DatabaseThroughputExceeded" + | "InvalidGameTicket" + | "ExpiredGameTicket" + | "GameTicketDoesNotMatchLobby" + | "LinkedDeviceAlreadyClaimed" + | "DeviceAlreadyLinked" + | "DeviceNotLinked" + | "PartialFailure" + | "PublisherNotSet" + | "ServiceUnavailable" + | "VersionNotFound" + | "RevisionNotFound" + | "InvalidPublisherId" + | "DownstreamServiceUnavailable" + | "APINotIncludedInTitleUsageTier" + | "DAULimitExceeded" + | "APIRequestLimitExceeded" + | "InvalidAPIEndpoint" + | "BuildNotAvailable" + | "ConcurrentEditError" + | "ContentNotFound" + | "CharacterNotFound" + | "CloudScriptNotFound" + | "ContentQuotaExceeded" + | "InvalidCharacterStatistics" + | "PhotonNotEnabledForTitle" + | "PhotonApplicationNotFound" + | "PhotonApplicationNotAssociatedWithTitle" + | "InvalidEmailOrPassword" + | "FacebookAPIError" + | "InvalidContentType" + | "KeyLengthExceeded" + | "DataLengthExceeded" + | "TooManyKeys" + | "FreeTierCannotHaveVirtualCurrency" + | "MissingAmazonSharedKey" + | "AmazonValidationError" + | "InvalidPSNIssuerId" + | "PSNInaccessible" + | "ExpiredAuthToken" + | "FailedToGetEntitlements" + | "FailedToConsumeEntitlement" + | "TradeAcceptingUserNotAllowed" + | "TradeInventoryItemIsAssignedToCharacter" + | "TradeInventoryItemIsBundle" + | "TradeStatusNotValidForCancelling" + | "TradeStatusNotValidForAccepting" + | "TradeDoesNotExist" + | "TradeCancelled" + | "TradeAlreadyFilled" + | "TradeWaitForStatusTimeout" + | "TradeInventoryItemExpired" + | "TradeMissingOfferedAndAcceptedItems" + | "TradeAcceptedItemIsBundle" + | "TradeAcceptedItemIsStackable" + | "TradeInventoryItemInvalidStatus" + | "TradeAcceptedCatalogItemInvalid" + | "TradeAllowedUsersInvalid" + | "TradeInventoryItemDoesNotExist" + | "TradeInventoryItemIsConsumed" + | "TradeInventoryItemIsStackable" + | "TradeAcceptedItemsMismatch" + | "InvalidKongregateToken" + | "FeatureNotConfiguredForTitle" + | "NoMatchingCatalogItemForReceipt" + | "InvalidCurrencyCode" + | "NoRealMoneyPriceForCatalogItem" + | "TradeInventoryItemIsNotTradable" + | "TradeAcceptedCatalogItemIsNotTradable" + | "UsersAlreadyFriends" + | "LinkedIdentifierAlreadyClaimed" + | "CustomIdNotLinked" + | "TotalDataSizeExceeded" + | "DeleteKeyConflict" + | "InvalidXboxLiveToken" + | "ExpiredXboxLiveToken" + | "ResettableStatisticVersionRequired" + | "NotAuthorizedByTitle" + | "NoPartnerEnabled" + | "InvalidPartnerResponse" + | "APINotEnabledForGameServerAccess" + | "StatisticNotFound" + | "StatisticNameConflict" + | "StatisticVersionClosedForWrites" + | "StatisticVersionInvalid" + | "APIClientRequestRateLimitExceeded" + | "InvalidJSONContent" + | "InvalidDropTable" + | "StatisticVersionAlreadyIncrementedForScheduledInterval" + | "StatisticCountLimitExceeded" + | "StatisticVersionIncrementRateExceeded" + | "ContainerKeyInvalid" + | "CloudScriptExecutionTimeLimitExceeded" + | "NoWritePermissionsForEvent" + | "CloudScriptFunctionArgumentSizeExceeded" + | "CloudScriptAPIRequestCountExceeded" + | "CloudScriptAPIRequestError" + | "CloudScriptHTTPRequestError" + | "InsufficientGuildRole" + | "GuildNotFound" + | "OverLimit" + | "EventNotFound" + | "InvalidEventField" + | "InvalidEventName" + | "CatalogNotConfigured" + | "OperationNotSupportedForPlatform" + | "SegmentNotFound" + | "StoreNotFound" + | "InvalidStatisticName" + | "TitleNotQualifiedForLimit" + | "InvalidServiceLimitLevel" + | "ServiceLimitLevelInTransition" + | "CouponAlreadyRedeemed" + | "GameServerBuildSizeLimitExceeded" + | "GameServerBuildCountLimitExceeded" + | "VirtualCurrencyCountLimitExceeded" + | "VirtualCurrencyCodeExists" + | "TitleNewsItemCountLimitExceeded" + | "InvalidTwitchToken" + | "TwitchResponseError" + | "ProfaneDisplayName" + | "UserAlreadyAdded" + | "InvalidVirtualCurrencyCode" + | "VirtualCurrencyCannotBeDeleted" + | "IdentifierAlreadyClaimed" + | "IdentifierNotLinked" + | "InvalidContinuationToken" + | "ExpiredContinuationToken" + | "InvalidSegment" + | "InvalidSessionId" + | "SessionLogNotFound" + | "InvalidSearchTerm" + | "TwoFactorAuthenticationTokenRequired" + | "GameServerHostCountLimitExceeded" + | "PlayerTagCountLimitExceeded" + | "RequestAlreadyRunning" + | "ActionGroupNotFound" + | "MaximumSegmentBulkActionJobsRunning" + | "NoActionsOnPlayersInSegmentJob" + | "DuplicateStatisticName" + | "ScheduledTaskNameConflict" + | "ScheduledTaskCreateConflict" + | "InvalidScheduledTaskName" + | "InvalidTaskSchedule" + | "SteamNotEnabledForTitle" + | "LimitNotAnUpgradeOption" + | "NoSecretKeyEnabledForCloudScript" + | "TaskNotFound" + | "TaskInstanceNotFound" + | "InvalidIdentityProviderId" + | "MisconfiguredIdentityProvider" + | "InvalidScheduledTaskType" + | "BillingInformationRequired" + | "LimitedEditionItemUnavailable" + | "InvalidAdPlacementAndReward" + | "AllAdPlacementViewsAlreadyConsumed" + | "GoogleOAuthNotConfiguredForTitle" + | "GoogleOAuthError" + | "UserNotFriend" + | "InvalidSignature" + | "InvalidPublicKey" + | "GoogleOAuthNoIdTokenIncludedInResponse" + | "StatisticUpdateInProgress" + | "LeaderboardVersionNotAvailable" + | "StatisticAlreadyHasPrizeTable" + | "PrizeTableHasOverlappingRanks" + | "PrizeTableHasMissingRanks" + | "PrizeTableRankStartsAtZero" + | "InvalidStatistic" + | "ExpressionParseFailure" + | "ExpressionInvokeFailure" + | "ExpressionTooLong" + | "DataUpdateRateExceeded" + | "RestrictedEmailDomain" + | "EncryptionKeyDisabled" + | "EncryptionKeyMissing" + | "EncryptionKeyBroken" + | "NoSharedSecretKeyConfigured" + | "SecretKeyNotFound" + | "PlayerSecretAlreadyConfigured" + | "APIRequestsDisabledForTitle" + | "InvalidSharedSecretKey" + | "PrizeTableHasNoRanks" + | "ProfileDoesNotExist" + | "ContentS3OriginBucketNotConfigured" + | "InvalidEnvironmentForReceipt" + | "EncryptedRequestNotAllowed" + | "SignedRequestNotAllowed" + | "RequestViewConstraintParamsNotAllowed" + | "BadPartnerConfiguration" + | "XboxBPCertificateFailure" + | "XboxXASSExchangeFailure" + | "InvalidEntityId" + | "StatisticValueAggregationOverflow" + | "EmailMessageFromAddressIsMissing" + | "EmailMessageToAddressIsMissing" + | "SmtpServerAuthenticationError" + | "SmtpServerLimitExceeded" + | "SmtpServerInsufficientStorage" + | "SmtpServerCommunicationError" + | "SmtpServerGeneralFailure" + | "EmailClientTimeout" + | "EmailClientCanceledTask" + | "EmailTemplateMissing" + | "InvalidHostForTitleId" + | "EmailConfirmationTokenDoesNotExist" + | "EmailConfirmationTokenExpired" + | "AccountDeleted" + | "PlayerSecretNotConfigured" + | "InvalidSignatureTime" + | "NoContactEmailAddressFound" + | "InvalidAuthToken" + | "AuthTokenDoesNotExist" + | "AuthTokenExpired" + | "AuthTokenAlreadyUsedToResetPassword" + | "MembershipNameTooLong" + | "MembershipNotFound" + | "GoogleServiceAccountInvalid" + | "GoogleServiceAccountParseFailure" + | "EntityTokenMissing" + | "EntityTokenInvalid" + | "EntityTokenExpired" + | "EntityTokenRevoked" + | "InvalidProductForSubscription" + | "XboxInaccessible" + | "SubscriptionAlreadyTaken" + | "SmtpAddonNotEnabled" + | "APIConcurrentRequestLimitExceeded" + | "XboxRejectedXSTSExchangeRequest" + | "VariableNotDefined" + | "TemplateVersionNotDefined" + | "FileTooLarge" + | "TitleDeleted" + | "TitleContainsUserAccounts" + | "TitleDeletionPlayerCleanupFailure" + | "EntityFileOperationPending" + | "NoEntityFileOperationPending" + | "EntityProfileVersionMismatch" + | "TemplateVersionTooOld" + | "MembershipDefinitionInUse" + | "PaymentPageNotConfigured" + | "FailedLoginAttemptRateLimitExceeded" + | "EntityBlockedByGroup" + | "RoleDoesNotExist" + | "EntityIsAlreadyMember" + | "DuplicateRoleId" + | "GroupInvitationNotFound" + | "GroupApplicationNotFound" + | "OutstandingInvitationAcceptedInstead" + | "OutstandingApplicationAcceptedInstead" + | "RoleIsGroupDefaultMember" + | "RoleIsGroupAdmin" + | "RoleNameNotAvailable" + | "GroupNameNotAvailable" + | "EmailReportAlreadySent" + | "EmailReportRecipientBlacklisted" + | "EventNamespaceNotAllowed" + | "EventEntityNotAllowed" + | "InvalidEntityType" + | "NullTokenResultFromAad" + | "InvalidTokenResultFromAad" + | "NoValidCertificateForAad" + | "InvalidCertificateForAad" + | "DuplicateDropTableId" + | "MultiplayerServerError" + | "MultiplayerServerTooManyRequests" + | "MultiplayerServerNoContent" + | "MultiplayerServerBadRequest" + | "MultiplayerServerUnauthorized" + | "MultiplayerServerForbidden" + | "MultiplayerServerNotFound" + | "MultiplayerServerConflict" + | "MultiplayerServerInternalServerError" + | "MultiplayerServerUnavailable" + | "ExplicitContentDetected" + | "PIIContentDetected" + | "InvalidScheduledTaskParameter" + | "PerEntityEventRateLimitExceeded" + | "TitleDefaultLanguageNotSet" + | "EmailTemplateMissingDefaultVersion" + | "FacebookInstantGamesIdNotLinked" + | "InvalidFacebookInstantGamesSignature" + | "FacebookInstantGamesAuthNotConfiguredForTitle" + | "EntityProfileConstraintValidationFailed" + | "TelemetryIngestionKeyPending" + | "TelemetryIngestionKeyNotFound" + | "StatisticChildNameInvalid" + | "DataIntegrityError" + | "VirtualCurrencyCannotBeSetToOlderVersion" + | "VirtualCurrencyMustBeWithinIntegerRange" + | "EmailTemplateInvalidSyntax" + | "EmailTemplateMissingCallback" + | "PushNotificationTemplateInvalidPayload" + | "InvalidLocalizedPushNotificationLanguage" + | "MissingLocalizedPushNotificationMessage" + | "PushNotificationTemplateMissingPlatformPayload" + | "PushNotificationTemplatePayloadContainsInvalidJson" + | "PushNotificationTemplateContainsInvalidIosPayload" + | "PushNotificationTemplateContainsInvalidAndroidPayload" + | "PushNotificationTemplateIosPayloadMissingNotificationBody" + | "PushNotificationTemplateAndroidPayloadMissingNotificationBody" + | "PushNotificationTemplateNotFound" + | "PushNotificationTemplateMissingDefaultVersion" + | "PushNotificationTemplateInvalidSyntax" + | "PushNotificationTemplateNoCustomPayloadForV1" + | "NoLeaderboardForStatistic" + | "TitleNewsMissingDefaultLanguage" + | "TitleNewsNotFound" + | "TitleNewsDuplicateLanguage" + | "TitleNewsMissingTitleOrBody" + | "TitleNewsInvalidLanguage" + | "EmailRecipientBlacklisted" + | "InvalidGameCenterAuthRequest" + | "GameCenterAuthenticationFailed" + | "CannotEnablePartiesForTitle" + | "PartyError" + | "PartyRequests" + | "PartyNoContent" + | "PartyBadRequest" + | "PartyUnauthorized" + | "PartyForbidden" + | "PartyNotFound" + | "PartyConflict" + | "PartyInternalServerError" + | "PartyUnavailable" + | "PartyTooManyRequests" + | "PushNotificationTemplateMissingName" + | "CannotEnableMultiplayerServersForTitle" + | "WriteAttemptedDuringExport" + | "MultiplayerServerTitleQuotaCoresExceeded" + | "AutomationRuleNotFound" + | "EntityAPIKeyLimitExceeded" + | "EntityAPIKeyNotFound" + | "EntityAPIKeyOrSecretInvalid" + | "EconomyServiceUnavailable" + | "EconomyServiceInternalError" + | "QueryRateLimitExceeded" + | "EntityAPIKeyCreationDisabledForEntity" + | "ForbiddenByEntityPolicy" + | "UpdateInventoryRateLimitExceeded" + | "StudioCreationRateLimited" + | "StudioCreationInProgress" + | "DuplicateStudioName" + | "StudioNotFound" + | "StudioDeleted" + | "StudioDeactivated" + | "StudioActivated" + | "TitleCreationRateLimited" + | "TitleCreationInProgress" + | "DuplicateTitleName" + | "TitleActivationRateLimited" + | "TitleActivationInProgress" + | "TitleDeactivated" + | "TitleActivated" + | "CloudScriptAzureFunctionsExecutionTimeLimitExceeded" + | "CloudScriptAzureFunctionsArgumentSizeExceeded" + | "CloudScriptAzureFunctionsReturnSizeExceeded" + | "CloudScriptAzureFunctionsHTTPRequestError" + | "VirtualCurrencyBetaGetError" + | "VirtualCurrencyBetaCreateError" + | "VirtualCurrencyBetaInitialDepositSaveError" + | "VirtualCurrencyBetaSaveError" + | "VirtualCurrencyBetaDeleteError" + | "VirtualCurrencyBetaRestoreError" + | "VirtualCurrencyBetaSaveConflict" + | "VirtualCurrencyBetaUpdateError" + | "InsightsManagementDatabaseNotFound" + | "InsightsManagementOperationNotFound" + | "InsightsManagementErrorPendingOperationExists" + | "InsightsManagementSetPerformanceLevelInvalidParameter" + | "InsightsManagementSetStorageRetentionInvalidParameter" + | "InsightsManagementGetStorageUsageInvalidParameter" + | "InsightsManagementGetOperationStatusInvalidParameter" + | "DuplicatePurchaseTransactionId" + | "EvaluationModePlayerCountExceeded" + | "CloudScriptFunctionNameSizeExceeded" + | "PaidInsightsFeaturesNotEnabled" + | "CloudScriptAzureFunctionsQueueRequestError" + | "EvaluationModeTitleCountExceeded" + | "InsightsManagementTitleNotInFlight" + | "LimitNotFound" + | "LimitNotAvailableViaAPI" + | "InsightsManagementSetStorageRetentionBelowMinimum" + | "InsightsManagementSetStorageRetentionAboveMaximum" + | "AppleNotEnabledForTitle" + | "InsightsManagementNewActiveEventExportLimitInvalid" + | "InsightsManagementSetPerformanceRateLimited" + | "PartyRequestsThrottledFromRateLimiter" + | "XboxServiceTooManyRequests" + | "NintendoSwitchNotEnabledForTitle" + | "RequestMultiplayerServersThrottledFromRateLimiter" + | "TitleDataOverrideNotFound" + | "DuplicateKeys" + | "WasNotCreatedWithCloudRoot" + | "LegacyMultiplayerServersDeprecated" + | "VirtualCurrencyCurrentlyUnavailable" + | "SteamUserNotFound" + | "ElasticSearchOperationFailed" + | "NotImplemented" + | "PublisherNotFound" + | "PublisherDeleted" + | "ApiDisabledForMigration" + | "ResourceNameUpdateNotAllowed" + | "ApiNotEnabledForTitle" + | "DuplicateTitleNameForPublisher" + | "AzureTitleCreationInProgress" + | "TitleConstraintsPublisherDeletion" + | "InvalidPlayerAccountPoolId" + | "PlayerAccountPoolNotFound" + | "PlayerAccountPoolDeleted" + | "TitleCleanupInProgress" + | "AzureResourceConcurrentOperationInProgress" + | "TitlePublisherUpdateNotAllowed" + | "AzureResourceManagerNotSupportedInStamp" + | "ApiNotIncludedInAzurePlayFabFeatureSet" + | "GoogleServiceAccountFailedAuth" + | "GoogleAPIServiceUnavailable" + | "GoogleAPIServiceUnknownError" + | "NoValidIdentityForAad" + | "PlayerIdentityLinkNotFound" + | "PhotonApplicationIdAlreadyInUse" + | "CloudScriptUnableToDeleteProductionRevision" + | "CustomIdNotFound" + | "AutomationInvalidInput" + | "AutomationInvalidRuleName" + | "AutomationRuleAlreadyExists" + | "AutomationRuleLimitExceeded" + | "InvalidGooglePlayGamesServerAuthCode" + | "PlayStreamConnectionFailed" + | "InvalidEventContents" + | "InsightsV1Deprecated" + | "AnalysisSubscriptionNotFound" + | "AnalysisSubscriptionFailed" + | "AnalysisSubscriptionFoundAlready" + | "AnalysisSubscriptionManagementInvalidInput" + | "InvalidGameCenterId" + | "InvalidNintendoSwitchAccountId" + | "EntityAPIKeysNotSupported" + | "IpAddressBanned" + | "EntityLineageBanned" + | "NamespaceMismatch" + | "InvalidServiceConfiguration" + | "InvalidNamespaceMismatch" + | "LeaderboardColumnLengthMismatch" + | "InvalidStatisticScore" + | "LeaderboardColumnsNotSpecified" + | "LeaderboardMaxSizeTooLarge" + | "InvalidAttributeStatisticsSpecified" + | "LeaderboardNotFound" + | "TokenSigningKeyNotFound" + | "LeaderboardNameConflict" + | "LinkedStatisticColumnMismatch" + | "NoLinkedStatisticToLeaderboard" + | "StatDefinitionAlreadyLinkedToLeaderboard" + | "LinkingStatsNotAllowedForEntityType" + | "LeaderboardCountLimitExceeded" + | "LeaderboardSizeLimitExceeded" + | "LeaderboardDefinitionModificationNotAllowedWhileLinked" + | "StatisticDefinitionModificationNotAllowedWhileLinked" + | "LeaderboardUpdateNotAllowedWhileLinked" + | "CloudScriptAzureFunctionsEventHubRequestError" + | "ExternalEntityNotAllowedForTier" + | "InvalidBaseTimeForInterval" + | "EntityTypeMismatchWithStatDefinition" + | "SpecifiedVersionLeaderboardNotFound" + | "LeaderboardColumnLengthMismatchWithStatDefinition" + | "DuplicateColumnNameFound" + | "LinkedStatisticColumnNotFound" + | "LinkedStatisticColumnRequired" + | "MultipleLinkedStatisticsNotAllowed" + | "DuplicateLinkedStatisticColumnNameFound" + | "AggregationTypeNotAllowedForMultiColumnStatistic" + | "MaxQueryableVersionsValueNotAllowedForTier" + | "StatisticDefinitionHasNullOrEmptyVersionConfiguration" + | "StatisticColumnLengthMismatch" + | "InvalidExternalEntityId" + | "UpdatingStatisticsUsingTransactionIdNotAvailableForFreeTier" + | "TransactionAlreadyApplied" + | "ReportDataNotRetrievedSuccessfully" + | "ResetIntervalCannotBeModified" + | "VersionIncrementRateExceeded" + | "InvalidSteamUsername" + | "InvalidVersionResetForLinkedLeaderboard" + | "BattleNetNotEnabledForTitle" + | "ReportNotProcessed" + | "DataNotAvailable" + | "InvalidReportName" + | "ResourceNotModified" + | "StudioCreationLimitExceeded" + | "StudioDeletionInitiated" + | "ProductDisabledForTitle" + | "PreconditionFailed" + | "CannotEnableAnonymousPlayerCreation" + | "ParentCustomerAccountNotFound" + | "AccountLinkedToABannedPlayer" + | "AzureSubscriptionNotEligibleForLinking" + | "EntityIsNotAMember" + | "IPAddressNotFound" + | "PSNNextGenNotConfiguredForTitle" + | "InvalidNintendoIssuer" + | "MatchmakingEntityInvalid" + | "MatchmakingPlayerAttributesInvalid" + | "MatchmakingQueueNotFound" + | "MatchmakingMatchNotFound" + | "MatchmakingTicketNotFound" + | "MatchmakingAlreadyJoinedTicket" + | "MatchmakingTicketAlreadyCompleted" + | "MatchmakingQueueConfigInvalid" + | "MatchmakingMemberProfileInvalid" + | "NintendoSwitchDeviceIdNotLinked" + | "MatchmakingNotEnabled" + | "MatchmakingPlayerAttributesTooLarge" + | "MatchmakingNumberOfPlayersInTicketTooLarge" + | "MatchmakingAttributeInvalid" + | "MatchmakingPlayerHasNotJoinedTicket" + | "MatchmakingRateLimitExceeded" + | "MatchmakingTicketMembershipLimitExceeded" + | "MatchmakingUnauthorized" + | "MatchmakingQueueLimitExceeded" + | "MatchmakingRequestTypeMismatch" + | "MatchmakingBadRequest" + | "PubSubFeatureNotEnabledForTitle" + | "PubSubTooManyRequests" + | "PubSubConnectionNotFoundForEntity" + | "PubSubConnectionHandleInvalid" + | "PubSubSubscriptionLimitExceeded" + | "TitleConfigNotFound" + | "TitleConfigUpdateConflict" + | "TitleConfigSerializationError" + | "CatalogApiNotImplemented" + | "CatalogEntityInvalid" + | "CatalogTitleIdMissing" + | "CatalogPlayerIdMissing" + | "CatalogClientIdentityInvalid" + | "CatalogOneOrMoreFilesInvalid" + | "CatalogItemMetadataInvalid" + | "CatalogItemIdInvalid" + | "CatalogSearchParameterInvalid" + | "CatalogFeatureDisabled" + | "CatalogConfigInvalid" + | "CatalogItemTypeInvalid" + | "CatalogBadRequest" + | "CatalogTooManyRequests" + | "InvalidCatalogItemConfiguration" + | "LegacyEconomyDisabled" + | "ExportInvalidStatusUpdate" + | "ExportInvalidPrefix" + | "ExportBlobContainerDoesNotExist" + | "ExportNotFound" + | "ExportCouldNotUpdate" + | "ExportInvalidStorageType" + | "ExportAmazonBucketDoesNotExist" + | "ExportInvalidBlobStorage" + | "ExportKustoException" + | "ExportKustoConnectionFailed" + | "ExportUnknownError" + | "ExportCantEditPendingExport" + | "ExportLimitExports" + | "ExportLimitEvents" + | "ExportInvalidPartitionStatusModification" + | "ExportCouldNotCreate" + | "ExportNoBackingDatabaseFound" + | "ExportCouldNotDelete" + | "ExportCannotDetermineEventQuery" + | "ExportInvalidQuerySchemaModification" + | "ExportQuerySchemaMissingRequiredColumns" + | "ExportCannotParseQuery" + | "ExportControlCommandsNotAllowed" + | "ExportQueryMissingTableReference" + | "ExportInsightsV1Deprecated" + | "ExplorerBasicInvalidQueryName" + | "ExplorerBasicInvalidQueryDescription" + | "ExplorerBasicInvalidQueryConditions" + | "ExplorerBasicInvalidQueryStartDate" + | "ExplorerBasicInvalidQueryEndDate" + | "ExplorerBasicInvalidQueryGroupBy" + | "ExplorerBasicInvalidQueryAggregateType" + | "ExplorerBasicInvalidQueryAggregateProperty" + | "ExplorerBasicLoadQueriesError" + | "ExplorerBasicLoadQueryError" + | "ExplorerBasicCreateQueryError" + | "ExplorerBasicDeleteQueryError" + | "ExplorerBasicUpdateQueryError" + | "ExplorerBasicSavedQueriesLimit" + | "ExplorerBasicSavedQueryNotFound" + | "TenantShardMapperShardNotFound" + | "TitleNotEnabledForParty" + | "PartyVersionNotFound" + | "MultiplayerServerBuildReferencedByMatchmakingQueue" + | "MultiplayerServerBuildReferencedByBuildAlias" + | "MultiplayerServerBuildAliasReferencedByMatchmakingQueue" + | "PartySerializationError" + | "ExperimentationExperimentStopped" + | "ExperimentationExperimentRunning" + | "ExperimentationExperimentNotFound" + | "ExperimentationExperimentNeverStarted" + | "ExperimentationExperimentDeleted" + | "ExperimentationClientTimeout" + | "ExperimentationInvalidVariantConfiguration" + | "ExperimentationInvalidVariableConfiguration" + | "ExperimentInvalidId" + | "ExperimentationNoScorecard" + | "ExperimentationTreatmentAssignmentFailed" + | "ExperimentationTreatmentAssignmentDisabled" + | "ExperimentationInvalidDuration" + | "ExperimentationMaxExperimentsReached" + | "ExperimentationExperimentSchedulingInProgress" + | "ExperimentationInvalidEndDate" + | "ExperimentationInvalidStartDate" + | "ExperimentationMaxDurationExceeded" + | "ExperimentationExclusionGroupNotFound" + | "ExperimentationExclusionGroupInsufficientCapacity" + | "ExperimentationExclusionGroupCannotDelete" + | "ExperimentationExclusionGroupInvalidTrafficAllocation" + | "ExperimentationExclusionGroupInvalidName" + | "ExperimentationLegacyExperimentInvalidOperation" + | "ExperimentationExperimentStopFailed" + | "ExperimentationExperimentDeleteFailed" + | "ExperimentationExperimentStartFailed" + | "MaxActionDepthExceeded" + | "TitleNotOnUpdatedPricingPlan" + | "SegmentManagementTitleNotInFlight" + | "SegmentManagementNoExpressionTree" + | "SegmentManagementTriggerActionCountOverLimit" + | "SegmentManagementSegmentCountOverLimit" + | "SegmentManagementInvalidSegmentId" + | "SegmentManagementInvalidInput" + | "SegmentManagementInvalidSegmentName" + | "DeleteSegmentRateLimitExceeded" + | "CreateSegmentRateLimitExceeded" + | "UpdateSegmentRateLimitExceeded" + | "GetSegmentsRateLimitExceeded" + | "AsyncExportNotInFlight" + | "AsyncExportNotFound" + | "AsyncExportRateLimitExceeded" + | "AnalyticsSegmentCountOverLimit" + | "GetSegmentPlayerCountNotInFlight" + | "GetSegmentPlayerCountRateLimitExceeded" + | "SnapshotNotFound" + | "InventoryApiNotImplemented" + | "InventoryCollectionDeletionDisallowed" + | "LobbyDoesNotExist" + | "LobbyRateLimitExceeded" + | "LobbyPlayerAlreadyJoined" + | "LobbyNotJoinable" + | "LobbyMemberCannotRejoin" + | "LobbyCurrentPlayersMoreThanMaxPlayers" + | "LobbyPlayerNotPresent" + | "LobbyBadRequest" + | "LobbyPlayerMaxLobbyLimitExceeded" + | "LobbyNewOwnerMustBeConnected" + | "LobbyCurrentOwnerStillConnected" + | "LobbyMemberIsNotOwner" + | "LobbyServerMismatch" + | "LobbyServerNotFound" + | "LobbyDifferentServerAlreadyJoined" + | "LobbyServerAlreadyJoined" + | "LobbyIsNotClientOwned" + | "LobbyDoesNotUseConnections" + | "EventSamplingInvalidRatio" + | "EventSamplingInvalidEventNamespace" + | "EventSamplingInvalidEventName" + | "EventSamplingRatioNotFound" + | "TelemetryKeyNotFound" + | "TelemetryKeyInvalidName" + | "TelemetryKeyAlreadyExists" + | "TelemetryKeyInvalid" + | "TelemetryKeyCountOverLimit" + | "TelemetryKeyDeactivated" + | "TelemetryKeyLongInsightsRetentionNotAllowed" + | "EventSinkConnectionInvalid" + | "EventSinkConnectionUnauthorized" + | "EventSinkRegionInvalid" + | "EventSinkLimitExceeded" + | "EventSinkSasTokenInvalid" + | "EventSinkNotFound" + | "EventSinkNameInvalid" + | "EventSinkSasTokenPermissionInvalid" + | "EventSinkSecretInvalid" + | "EventSinkTenantNotFound" + | "EventSinkAadNotFound" + | "EventSinkDatabaseNotFound" + | "EventSinkTitleUnauthorized" + | "EventSinkInsufficientRoleAssignment" + | "EventSinkContainerNotFound" + | "EventSinkTenantIdInvalid" + | "EventSinkResourceMisconfigured" + | "EventSinkAccessDenied" + | "EventSinkWriteConflict" + | "EventSinkResourceNotFound" + | "EventSinkResourceFeatureNotSupported" + | "EventSinkBucketNameInvalid" + | "EventSinkResourceUnavailable" + | "OperationCanceled" + | "InvalidDisplayNameRandomSuffixLength" + | "AllowNonUniquePlayerDisplayNamesDisableNotAllowed" + | "PartitionedEventInvalid" + | "PartitionedEventCountOverLimit" + | "ManageEventNamespaceInvalid" + | "ManageEventNameInvalid" + | "ManagedEventNotFound" + | "ManageEventsInvalidRatio" + | "ManagedEventInvalid" + | "PlayerCustomPropertiesPropertyNameTooLong" + | "PlayerCustomPropertiesPropertyNameIsInvalid" + | "PlayerCustomPropertiesStringPropertyValueTooLong" + | "PlayerCustomPropertiesValueIsInvalidType" + | "PlayerCustomPropertiesVersionMismatch" + | "PlayerCustomPropertiesPropertyCountTooHigh" + | "PlayerCustomPropertiesDuplicatePropertyName" + | "PlayerCustomPropertiesPropertyDoesNotExist" + | "AddonAlreadyExists" + | "AddonDoesntExist" + | "TrueSkillUnauthorized" + | "TrueSkillInvalidTitleId" + | "TrueSkillInvalidScenarioId" + | "TrueSkillInvalidModelId" + | "TrueSkillInvalidModelName" + | "TrueSkillInvalidPlayerIds" + | "TrueSkillInvalidEntityKey" + | "TrueSkillInvalidConditionKey" + | "TrueSkillInvalidConditionValue" + | "TrueSkillInvalidConditionAffinityWeight" + | "TrueSkillInvalidEventName" + | "TrueSkillMatchResultCreated" + | "TrueSkillMatchResultAlreadySubmitted" + | "TrueSkillBadPlayerIdInMatchResult" + | "TrueSkillInvalidBotIdInMatchResult" + | "TrueSkillDuplicatePlayerInMatchResult" + | "TrueSkillNoPlayerInMatchResultTeam" + | "TrueSkillPlayersInMatchResultExceedingLimit" + | "TrueSkillInvalidPreMatchPartyInMatchResult" + | "TrueSkillInvalidTimestampInMatchResult" + | "TrueSkillStartTimeMissingInMatchResult" + | "TrueSkillEndTimeMissingInMatchResult" + | "TrueSkillInvalidPlayerSecondsPlayedInMatchResult" + | "TrueSkillNoTeamInMatchResult" + | "TrueSkillNotEnoughTeamsInMatchResult" + | "TrueSkillInvalidRanksInMatchResult" + | "TrueSkillNoWinnerInMatchResult" + | "TrueSkillMissingRequiredCondition" + | "TrueSkillMissingRequiredEvent" + | "TrueSkillUnknownEventName" + | "TrueSkillInvalidEventCount" + | "TrueSkillUnknownConditionKey" + | "TrueSkillUnknownConditionValue" + | "TrueSkillScenarioConfigDoesNotExist" + | "TrueSkillUnknownModelId" + | "TrueSkillNoModelInScenario" + | "TrueSkillNotSupportedForTitle" + | "TrueSkillModelIsNotActive" + | "TrueSkillUnauthorizedToQueryOtherPlayerSkills" + | "TrueSkillInvalidMaxIterations" + | "TrueSkillEndTimeBeforeStartTime" + | "TrueSkillInvalidJobId" + | "TrueSkillInvalidMetadataId" + | "TrueSkillMissingBuildVerison" + | "TrueSkillJobAlreadyExists" + | "TrueSkillJobNotFound" + | "TrueSkillOperationCanceled" + | "TrueSkillActiveModelLimitExceeded" + | "TrueSkillTotalModelLimitExceeded" + | "TrueSkillUnknownInitialModelId" + | "TrueSkillUnauthorizedForJob" + | "TrueSkillInvalidScenarioName" + | "TrueSkillConditionStateIsRequired" + | "TrueSkillEventStateIsRequired" + | "TrueSkillDuplicateEvent" + | "TrueSkillDuplicateCondition" + | "TrueSkillInvalidAnomalyThreshold" + | "TrueSkillConditionKeyLimitExceeded" + | "TrueSkillConditionValuePerKeyLimitExceeded" + | "TrueSkillInvalidTimestamp" + | "TrueSkillEventLimitExceeded" + | "TrueSkillInvalidPlayers" + | "TrueSkillTrueSkillPlayerNull" + | "TrueSkillInvalidPlayerId" + | "TrueSkillInvalidSquadSize" + | "TrueSkillConditionSetNotInModel" + | "TrueSkillModelStateInvalidForOperation" + | "TrueSkillScenarioContainsActiveModel" + | "TrueSkillInvalidConditionRank" + | "TrueSkillTotalScenarioLimitExceeded" + | "TrueSkillInvalidConditionsList" + | "GameSaveManifestNotFound" + | "GameSaveManifestVersionAlreadyExists" + | "GameSaveConflictUpdatingManifest" + | "GameSaveManifestUpdatesNotAllowed" + | "GameSaveFileAlreadyExists" + | "GameSaveManifestVersionNotFinalized" + | "GameSaveUnknownFileInManifest" + | "GameSaveFileExceededReportedSize" + | "GameSaveFileNotUploaded" + | "GameSaveBadRequest" + | "GameSaveOperationNotAllowed" + | "GameSaveDataStorageQuotaExceeded" + | "GameSaveNewerManifestExists" + | "GameSaveBaseVersionNotAvailable" + | "GameSaveManifestVersionQuarantined" + | "GameSaveManifestUploadProgressUpdateNotAllowed" + | "GameSaveNotFinalizedManifestNotEligibleAsKnownGood" + | "GameSaveNoUpdatesRequested" + | "GameSaveTitleDoesNotExist" + | "GameSaveOperationNotAllowedForTitle" + | "GameSaveManifestFilesLimitExceeded" + | "GameSaveManifestDescriptionUpdateNotAllowed" + | "GameSaveTitleConfigNotFound" + | "GameSaveTitleAlreadyOnboarded" + | "GameSaveServiceNotEnabledForTitle" + | "GameSaveServiceOnboardingPending" + | "GameSaveManifestNotEligibleAsConflictingVersion" + | "GameSaveServiceUnavailable" + | "GameSaveConflict" + | "GameSaveManifestNotEligibleForRollback" + | "GameSaveTitleClientAnonymousAccountCreationNotDisabled" + | "GameSaveTitleConfigNoUpdatesRequested" + | "GameSavePlayerNotEligibleForTransfer" + | "GameSaveAlreadyAutoRolledBack" + | "GameSaveManifestNotEligibleForRestore" + | "GameSaveManifestArchived" + | "StateShareForbidden" + | "StateShareTitleNotInFlight" + | "StateShareStateNotFound" + | "StateShareLinkNotFound" + | "StateShareStateRedemptionLimitExceeded" + | "StateShareStateRedemptionLimitNotUpdated" + | "StateShareCreatedStatesLimitExceeded" + | "StateShareIdMissingOrMalformed" + | "PlayerCreationDisabled" + | "AccountAlreadyExists" + | "TagInvalid" + | "TagTooLong" + | "StatisticColumnAggregationMismatch" + | "StatisticResetIntervalMismatch" + | "VersionConfigurationCannotBeSpecifiedForLinkedStat" + | "VersionConfigurationIsRequired" + | "InvalidEntityTypeForAggregation" + | "MultiLevelAggregationNotAllowed" + | "AggregationTypeNotAllowedForLinkedStat" + | "OperationDeniedDueToDefinitionPolicy" + | "StatisticUpdateNotAllowedWhileLinked" + | "UnsupportedEntityType" + | "EntityTypeSpecifiedRequiresAggregationSource" + | "PlayFabErrorEventNotSupportedForEntityType" + | "MetadataLengthExceeded" + | "MaxQueryableVersionsExceeded" + | "StatisticVersionIncrementNotAllowedWhileLinked" + | "StoreMetricsRequestInvalidInput" + | "StoreMetricsErrorRetrievingMetrics"; + + export interface GenericPlayFabIdPair { + /** Unique generic service identifier for a user. */ + GenericId?: GenericServiceId; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the given generic identifier. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllActionGroupsRequest - */ - export interface GetAllActionGroupsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GenericServiceId { + /** Name of the service for which the player has a unique identifier. */ + ServiceName: string; + /** Unique identifier of the player in that service. */ + UserId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllActionGroupsResult - */ - export interface GetAllActionGroupsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / List of Action Groups. - */ - ActionGroups: GetActionGroupResult[]; + export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllSegmentsRequest - */ - export interface GetAllSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { - - } - - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetAllSegmentsResult - */ export interface GetAllSegmentsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of segments for this title. - */ + /** Array of segments for this title. */ Segments?: GetSegmentResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCatalogItemsRequest - */ export interface GetCatalogItemsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Which catalog is being requested. If null, uses the default catalog. - */ + /** Which catalog is being requested. If null, uses the default catalog. */ CatalogVersion?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCatalogItemsResult - */ export interface GetCatalogItemsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items which can be purchased. - */ + /** Array of items which can be purchased. */ Catalog?: CatalogItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterDataRequest - */ export interface GetCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterDataResult - */ export interface GetCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. - */ - DataVersion: number; - /** - / User specific data for this title. - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** User specific data for this title. */ Data?: { [key: string]: UserDataRecord }; /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ - CharacterId?: string; + DataVersion: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterInventoryRequest - */ export interface GetCharacterInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Used to limit results to only those from a specific catalog version. - */ + /** Used to limit results to only those from a specific catalog version. */ CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterInventoryResult - */ export interface GetCharacterInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique identifier of the character for this inventory. - */ + /** Unique identifier of the character for this inventory. */ CharacterId?: string; - /** - / Array of inventory items belonging to the character. - */ + /** Array of inventory items belonging to the character. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the character. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the character. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterLeaderboardRequest - */ export interface GetCharacterLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterLeaderboardResult - */ export interface GetCharacterLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterStatisticsRequest - */ export interface GetCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetCharacterStatisticsResult - */ export interface GetCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose character statistics are being returned. - */ - PlayFabId?: string; - /** - / Unique identifier of the character for the statistics. - */ + /** Unique identifier of the character for the statistics. */ CharacterId?: string; - /** - / Character statistics for the requested user. - */ + /** Character statistics for the requested user. */ CharacterStatistics?: { [key: string]: number }; + /** PlayFab unique identifier of the user whose character statistics are being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetContentDownloadUrlRequest - */ export interface GetContentDownloadUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Key of the content item to fetch, usually formatted as a path, e.g. images/a.png - */ - Key: string; - /** - / HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. - */ + /** HTTP method to fetch item - GET or HEAD. Use HEAD when only fetching metadata. Default is GET. */ HttpMethod?: string; + /** Key of the content item to fetch, usually formatted as a path, e.g. images/a.png */ + Key: string; /** - / True if download through CDN. CDN provides better download bandwidth and time. However, if you want latest, non-cached version of the content, set this to false. Default is true. + * True to download through CDN. CDN provides higher download bandwidth and lower latency. However, if you want the latest, + * non-cached version of the content during development, set this to false. Default is true. */ ThruCDN?: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetContentDownloadUrlResult - */ export interface GetContentDownloadUrlResult extends PlayFabModule.IPlayFabResultCommon { - /** - / URL for downloading content via HTTP GET or HEAD method. The URL will expire in 1 hour. - */ + /** URL for downloading content via HTTP GET or HEAD method. The URL will expire in approximately one hour. */ URL?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendLeaderboardRequest - */ export interface GetFriendLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The player whose friend leaderboard to get + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. */ + ExternalPlatformFriends?: string; + /** Maximum number of entries to retrieve. */ + MaxResultsCount: number; + /** The player whose friend leaderboard to get */ PlayFabId: string; /** - / Statistic used to rank friends for this leaderboard. - */ - StatisticName: string; - /** - / Position in the leaderboard to start this listing (defaults to the first entry). + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Position in the leaderboard to start this listing (defaults to the first entry). */ StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; - /** - / Indicates whether Steam service friends should be included in the response. Default is true. - */ - IncludeSteamFriends?: boolean; - /** - / Indicates whether Facebook friends should be included in the response. Default is true. - */ - IncludeFacebookFriends?: boolean; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. - */ - UseSpecificVersion: boolean; - /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; + /** Statistic used to rank friends for this leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; + /** Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. */ + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendsListRequest - */ export interface GetFriendsListRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** + * Indicates which other platforms' friends should be included in the response. In HTTP, it is represented as a + * comma-separated list of platforms. + */ + ExternalPlatformFriends?: string; /** - / PlayFab identifier of the player whose friend list to get. + * If true, include friends from the same namespace even if they have not logged in to the current title. Defaults to + * false. */ + NamespaceWide?: boolean; + /** PlayFab identifier of the player whose friend list to get. */ PlayFabId: string; /** - / Indicates whether Steam service friends should be included in the response. Default is true. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - IncludeSteamFriends?: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; /** - / Indicates whether Facebook friends should be included in the response. Default is true. + * Xbox token if Xbox friends should be included. Requires Xbox be configured on PlayFab. When provided, all Xbox Live + * users the caller is following are included regardless of whether they follow the caller back. */ - IncludeFacebookFriends?: boolean; + XboxToken?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetFriendsListResult - */ export interface GetFriendsListResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of friends found. - */ + /** Array of friends found. */ Friends?: FriendInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundCharacterRequest - */ export interface GetLeaderboardAroundCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Optional character type on which to filter the leaderboard entries. - */ - CharacterType?: string; - /** - / Maximum number of entries to retrieve. - */ + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundCharacterResult - */ export interface GetLeaderboardAroundCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundUserRequest - */ export interface GetLeaderboardAroundUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Maximum number of entries to retrieve. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardAroundUserResult - */ export interface GetLeaderboardAroundUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardForUsersCharactersRequest - */ export interface GetLeaderboardForUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Maximum number of entries to retrieve. - */ - MaxResultsCount: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardForUsersCharactersResult - */ export interface GetLeaderboardForUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered list of leaderboard entries. - */ + /** Ordered list of leaderboard entries. */ Leaderboard?: CharacterLeaderboardEntry[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardRequest - */ export interface GetLeaderboardRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the title-specific statistic for the leaderboard. - */ - StatisticName: string; - /** - / First entry in the leaderboard to be retrieved. - */ - StartPosition: number; - /** - / Maximum number of entries to retrieve. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Maximum number of entries to retrieve. */ MaxResultsCount: number; /** - / If non-null, this determines which properties of the profile to return. If null, playfab will only include display names. On client, only ShowDisplayName, ShowStatistics, ShowAvatarUrl are allowed. - */ - ProfileConstraints?: number; - /** - / The version of the leaderboard to get, when UseSpecificVersion is true. - */ - Version: number; - /** - / If true, uses the specified version. If false, gets the most recent version. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UseSpecificVersion: boolean; + ProfileConstraints?: PlayerProfileViewConstraints; + /** First entry in the leaderboard to be retrieved. */ + StartPosition: number; + /** Unique identifier for the title-specific statistic for the leaderboard. */ + StatisticName: string; + /** The version of the leaderboard to get. */ + Version?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetLeaderboardResult - */ export interface GetLeaderboardResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Ordered listing of users and their positions in the requested leaderboard. - */ + /** Ordered listing of users and their positions in the requested leaderboard. */ Leaderboard?: PlayerLeaderboardEntry[]; - /** - / The version of the leaderboard returned. - */ - Version: number; - /** - / The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. - */ + /** The time the next scheduled reset will occur. Null if the leaderboard does not reset on a schedule. */ NextReset?: string; + /** The version of the leaderboard returned. */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoRequest - */ export interface GetPlayerCombinedInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the user whose data will be returned - */ - PlayFabId: string; - /** - / Flags for which pieces of info to return for the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ InfoRequestParameters: GetPlayerCombinedInfoRequestParams; + /** PlayFabId of the user whose data will be returned */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoRequestParams - */ export interface GetPlayerCombinedInfoRequestParams { - /** - / Whether to get the player's account Info. Defaults to false - */ + /** Whether to get character inventories. Defaults to false. */ + GetCharacterInventories: boolean; + /** Whether to get the list of characters. Defaults to false. */ + GetCharacterList: boolean; + /** Whether to get player profile. Defaults to false. Has no effect for a new player. */ + GetPlayerProfile: boolean; + /** Whether to get player statistics. Defaults to false. */ + GetPlayerStatistics: boolean; + /** Whether to get title data. Defaults to false. */ + GetTitleData: boolean; + /** Whether to get the player's account Info. Defaults to false */ GetUserAccountInfo: boolean; - /** - / Whether to get the player's inventory. Defaults to false - */ + /** Whether to get the player's custom data. Defaults to false */ + GetUserData: boolean; + /** Whether to get the player's inventory. Defaults to false */ GetUserInventory: boolean; - /** - / Whether to get the player's virtual currency balances. Defaults to false - */ + /** Whether to get the player's read only data. Defaults to false */ + GetUserReadOnlyData: boolean; + /** Whether to get the player's virtual currency balances. Defaults to false */ GetUserVirtualCurrency: boolean; - /** - / Whether to get the player's custom data. Defaults to false - */ - GetUserData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false - */ + /** Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false */ + PlayerStatisticNames?: string[]; + /** Specifies the properties to return from the player profile. Defaults to returning the player's display name. */ + ProfileConstraints?: PlayerProfileViewConstraints; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false */ + TitleDataKeys?: string[]; + /** Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserData is false */ UserDataKeys?: string[]; /** - / Whether to get the player's read only data. Defaults to false - */ - GetUserReadOnlyData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is false + * Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetUserReadOnlyData is + * false */ UserReadOnlyDataKeys?: string[]; - /** - / Whether to get character inventories. Defaults to false. - */ - GetCharacterInventories: boolean; - /** - / Whether to get the list of characters. Defaults to false. - */ - GetCharacterList: boolean; - /** - / Whether to get title data. Defaults to false. - */ - GetTitleData: boolean; - /** - / Specific keys to search for in the custom data. Leave null to get all keys. Has no effect if GetTitleData is false - */ - TitleDataKeys?: string[]; - /** - / Whether to get player statistics. Defaults to false. - */ - GetPlayerStatistics: boolean; - /** - / Specific statistics to retrieve. Leave null to get all keys. Has no effect if GetPlayerStatistics is false - */ - PlayerStatisticNames?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoResult - */ export interface GetPlayerCombinedInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Results for requested info. - */ + /** Results for requested info. */ InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerCombinedInfoResultPayload - */ export interface GetPlayerCombinedInfoResultPayload { - /** - / Account information for the user. This is always retrieved. - */ + /** Account information for the user. This is always retrieved. */ AccountInfo?: UserAccountInfo; + /** Inventories for each character for the user. */ + CharacterInventories?: CharacterInventory[]; + /** List of characters for the user. */ + CharacterList?: CharacterResult[]; /** - / Array of inventory items in the user's current inventory. + * The profile of the players. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ + PlayerProfile?: PlayerProfileModel; + /** List of statistics for this player. */ + PlayerStatistics?: StatisticValue[]; + /** Title data for this title. */ + TitleData?: { [key: string]: string | null }; + /** User specific custom data. */ + UserData?: { [key: string]: UserDataRecord }; + /** The version of the UserData that was returned. */ + UserDataVersion: number; + /** Array of inventory items in the user's current inventory. */ UserInventory?: ItemInstance[]; - /** - / Dictionary of virtual currency balance(s) belonging to the user. - */ + /** User specific read-only data. */ + UserReadOnlyData?: { [key: string]: UserDataRecord }; + /** The version of the Read-Only UserData that was returned. */ + UserReadOnlyDataVersion: number; + /** Dictionary of virtual currency balance(s) belonging to the user. */ UserVirtualCurrency?: { [key: string]: number }; - /** - / Dictionary of remaining times and timestamps for virtual currencies. - */ + /** Dictionary of remaining times and timestamps for virtual currencies. */ UserVirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; + + } + + export interface GetPlayerCustomPropertyRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Specific property name to search for in the player's properties. */ + PropertyName: string; + + } + + export interface GetPlayerCustomPropertyResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; /** - / User specific custom data. - */ - UserData?: { [key: string]: UserDataRecord }; - /** - / The version of the UserData that was returned. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - UserDataVersion: number; + PropertiesVersion: number; + /** Player specific property and its corresponding value. */ + Property?: CustomPropertyDetails; + + } + + export interface GetPlayerProfileRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; /** - / User specific read-only data. + * If non-null, this determines which properties of the resulting player profiles to return. For API calls from the client, + * only the allowed client profile properties for the title may be requested. These allowed properties are configured in + * the Game Manager "Client Profile Options" tab in the "Settings" section. */ - UserReadOnlyData?: { [key: string]: UserDataRecord }; + ProfileConstraints?: PlayerProfileViewConstraints; + + } + + export interface GetPlayerProfileResult extends PlayFabModule.IPlayFabResultCommon { /** - / The version of the Read-Only UserData that was returned. + * The profile of the player. This profile is not guaranteed to be up-to-date. For a new player, this profile will not + * exist. */ - UserReadOnlyDataVersion: number; + PlayerProfile?: PlayerProfileModel; + + } + + export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + /** Array of segments the requested player currently belongs to. */ + Segments?: GetSegmentResult[]; + + } + + export interface GetPlayersInSegmentExportRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the export for the requested Segment. */ + ExportId: string; + + } + + export interface GetPlayersInSegmentExportResponse extends PlayFabModule.IPlayFabResultCommon { + /** Url from which the index file can be downloaded. */ + IndexUrl?: string; + /** Shows the current status of the export */ + State?: string; + + } + + export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** user for whom statistics are being requested */ + PlayFabId: string; + /** statistics to return */ + StatisticNames?: string[]; /** - / List of characters for the user. + * statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be + * returned) */ - CharacterList?: CharacterResult[]; + StatisticNameVersions?: StatisticNameVersion[]; + + } + + export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose statistics are being returned */ + PlayFabId?: string; + /** User statistics for the requested user. */ + Statistics?: StatisticValue[]; + + } + + export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** unique name of the statistic */ + StatisticName?: string; + + } + + export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { + /** version change history of the statistic */ + StatisticVersions?: PlayerStatisticVersion[]; + + } + + export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Optional namespace to filter results by */ + Namespace?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Canonical tags (including namespace and tag's name) for the requested user */ + Tags: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Inventories for each character for the user. + * Array of unique Battle.net account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 10 in length. */ - CharacterInventories?: CharacterInventory[]; + BattleNetAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromBattleNetAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Battle.net account identifiers to PlayFab identifiers. */ + Data?: BattleNetAccountPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Title data for this title. + * Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - TitleData?: { [key: string]: string }; + FacebookIDs: string[]; + + } + + export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook identifiers to PlayFab identifiers. */ + Data?: FacebookPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromFacebookInstantGamesIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / List of statistics for this player. + * Array of unique Facebook Instant Games identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - PlayerStatistics?: StatisticValue[]; + FacebookInstantGamesIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerSegmentsResult - */ - export interface GetPlayerSegmentsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromFacebookInstantGamesIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Facebook Instant Games identifiers to PlayFab identifiers. */ + Data?: FacebookInstantGamesPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromGenericIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of segments the requested player currently belongs to. + * Array of unique generic service identifiers for which the title needs to get PlayFab identifiers. Currently limited to a + * maximum of 10 in a single request. */ - Segments?: GetSegmentResult[]; + GenericIDs: GenericServiceId[]; + + } + + export interface GetPlayFabIDsFromGenericIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of generic service identifiers to PlayFab identifiers. */ + Data?: GenericPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersInSegmentRequest - */ - export interface GetPlayersInSegmentRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromNintendoServiceAccountIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier for this segment. + * Nintendo NSA issuer URL identifying the environment. When provided, only accounts registered in that environment are + * returned. If null or empty, falls back to the default environment. */ - SegmentId: string; + Issuer?: string; /** - / Number of seconds to keep the continuation token active. After token expiration it is not possible to continue paging results. Default is 300 (5 minutes). Maximum is 1,800 (30 minutes). + * Array of unique Nintendo Switch Account identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - SecondsToLive?: number; + NintendoAccountIds: string[]; + + } + + export interface GetPlayFabIDsFromNintendoServiceAccountIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Service Account identifiers to PlayFab identifiers. */ + Data?: NintendoServiceAccountPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Maximum number of profiles to load. Default is 1,000. Maximum is 10,000. + * Array of unique Nintendo Switch Device identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - MaxBatchSize?: number; + NintendoSwitchDeviceIds: string[]; + + } + + export interface GetPlayFabIDsFromNintendoSwitchDeviceIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Nintendo Switch Device identifiers to PlayFab identifiers. */ + Data?: NintendoSwitchPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromOpenIdsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Continuation token if retrieving subsequent pages of results. + * Array of unique OpenId Connect identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed + * 10 in length. */ - ContinuationToken?: string; + OpenIdSubjectIdentifiers: OpenIdSubjectIdentifier[]; + + } + + export interface GetPlayFabIDsFromOpenIdsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of OpenId Connect identifiers to PlayFab identifiers. */ + Data?: OpenIdSubjectIdentifierPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersInSegmentResult - */ - export interface GetPlayersInSegmentResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromPSNAccountIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Count of profiles matching this segment. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - ProfilesInSegment: number; + IssuerId?: number; /** - / Continuation token to use to retrieve subsequent pages of results. If token returns null there are no more results. + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - ContinuationToken?: string; + PSNAccountIDs: string[]; /** - / Array of player profiles in this segment. + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - PlayerProfiles?: PlayerProfile[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayersSegmentsRequest - */ - export interface GetPlayersSegmentsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; + export interface GetPlayFabIDsFromPSNAccountIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticsRequest - */ - export interface GetPlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromPSNOnlineIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / user for whom statistics are being requested + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signed in under, otherwise the lookup returns a null PlayFabId rather than an error. */ - PlayFabId: string; + IssuerId?: number; /** - / statistics to return + * Array of unique PlayStation :tm: Network identifiers for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - StatisticNames?: string[]; + PSNOnlineIDs: string[]; /** - / statistics to return, if StatisticNames is not set (only statistics which have a version matching that provided will be returned) + * The PlayStation :tm: Network sandbox the account is keyed under. Sandbox membership is per account, not per title: + * supply this only for accounts that sign in from a sandbox, and omit it for accounts that do not, including all retail + * accounts. Supplying a sandbox id that an account is not keyed under, or omitting one that it is, returns a null + * PlayFabId rather than an error. */ - StatisticNameVersions?: StatisticNameVersion[]; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticsResult - */ - export interface GetPlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / PlayFab unique identifier of the user whose statistics are being returned - */ - PlayFabId?: string; - /** - / User statistics for the requested user. - */ - Statistics?: StatisticValue[]; + export interface GetPlayFabIDsFromPSNOnlineIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of PlayStation :tm: Network identifiers to PlayFab identifiers. */ + Data?: PSNOnlinePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticVersionsRequest - */ - export interface GetPlayerStatisticVersionsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromServerCustomIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / unique name of the statistic + * Array of unique server custom player identifiers for which the title needs to get PlayFab identifiers. Cannot contain + * more than 25 identifiers. */ - StatisticName?: string; + ServerCustomIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerStatisticVersionsResult - */ - export interface GetPlayerStatisticVersionsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / version change history of the statistic - */ - StatisticVersions?: PlayerStatisticVersion[]; + export interface GetPlayFabIDsFromServerCustomIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of server custom identifiers to PlayFab identifiers. */ + Data?: ServerCustomIDPlayFabIDPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerTagsRequest - */ - export interface GetPlayerTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; + export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Optional namespace to filter results by + * Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. The array + * cannot exceed 25 in length. */ - Namespace?: string; + SteamStringIDs?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayerTagsResult - */ - export interface GetPlayerTagsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Canonical tags (including namespace and tag's name) for the requested user - */ - Tags: string[]; + export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromFacebookIDsRequest - */ - export interface GetPlayFabIDsFromFacebookIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromSteamNamesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Facebook identifiers for which the title needs to get PlayFab identifiers. + * Array of unique Steam identifiers for which the title needs to get PlayFab identifiers. The array cannot exceed 25 in + * length. */ - FacebookIDs: string[]; + SteamNames: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromFacebookIDsResult - */ - export interface GetPlayFabIDsFromFacebookIDsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Mapping of Facebook identifiers to PlayFab identifiers. - */ - Data?: FacebookPlayFabIdPair[]; + export interface GetPlayFabIDsFromSteamNamesResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Steam identifiers to PlayFab identifiers. */ + Data?: SteamNamePlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromSteamIDsRequest - */ - export interface GetPlayFabIDsFromSteamIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface GetPlayFabIDsFromTwitchIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Array of unique Steam identifiers (Steam profile IDs) for which the title needs to get PlayFab identifiers. + * Array of unique Twitch identifiers (Twitch's _id) for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - SteamStringIDs?: string[]; + TwitchIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPlayFabIDsFromSteamIDsResult - */ - export interface GetPlayFabIDsFromSteamIDsResult extends PlayFabModule.IPlayFabResultCommon { + export interface GetPlayFabIDsFromTwitchIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Twitch identifiers to PlayFab identifiers. */ + Data?: TwitchPlayFabIdPair[]; + + } + + export interface GetPlayFabIDsFromXboxLiveIDsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The ID of Xbox Live sandbox. */ + Sandbox?: string; /** - / Mapping of Steam identifiers to PlayFab identifiers. + * Array of unique Xbox Live account identifiers for which the title needs to get PlayFab identifiers. The array cannot + * exceed 25 in length. */ - Data?: SteamPlayFabIdPair[]; + XboxLiveAccountIDs: string[]; + + } + + export interface GetPlayFabIDsFromXboxLiveIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of Xbox Live identifiers to PlayFab identifiers. */ + Data?: XboxLiveAccountPlayFabIdPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPublisherDataRequest - */ export interface GetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / array of keys to get back data from the Publisher data blob, set by the admin tools - */ + /** array of keys to get back data from the Publisher data blob, set by the admin tools */ Keys: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetPublisherDataResult - */ export interface GetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetRandomResultTablesRequest - */ export interface GetRandomResultTablesRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Specifies the catalog version that should be used to retrieve the Random Result Tables. If unspecified, uses default/primary catalog. + * Specifies the catalog version that should be used to retrieve the Random Result Tables. If unspecified, uses + * default/primary catalog. */ CatalogVersion?: string; - /** - / The unique identifier of the Random Result Table to use. - */ + /** The unique identifier of the Random Result Table to use. */ TableIDs: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetRandomResultTablesResult - */ export interface GetRandomResultTablesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / array of random result tables currently available - */ + /** array of random result tables currently available */ Tables?: { [key: string]: RandomResultTableListing }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSegmentResult - */ - export interface GetSegmentResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier for this segment. - */ + export interface GetSegmentPlayerCountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier for the requested segment. */ + SegmentId: string; + + } + + export interface GetSegmentPlayerCountResult extends PlayFabModule.IPlayFabResultCommon { + /** Count of profiles matching this segment. */ + ProfilesInSegment: number; + + } + + export interface GetSegmentResult { + /** Identifier of the segments AB Test, if it is attached to one. */ + ABTestParent?: string; + /** Unique identifier for this segment. */ Id: string; - /** - / Segment name. - */ + /** Segment name. */ Name?: string; + + } + + export interface GetServerCustomIDsFromPlayFabIDsRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Identifier of the segments AB Test, if it is attached to one. + * Array of unique PlayFab player identifiers for which the title needs to get server custom identifiers. Cannot contain + * more than 25 identifiers. */ - ABTestParent?: string; + PlayFabIDs: string[]; + + } + + export interface GetServerCustomIDsFromPlayFabIDsResult extends PlayFabModule.IPlayFabResultCommon { + /** Mapping of server custom player identifiers to PlayFab identifiers. */ + Data?: ServerCustomIDPlayFabIDPair[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSharedGroupDataRequest - */ export interface GetSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** If true, return the list of all members of the shared group. */ + GetMembers?: boolean; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array indicates that no keys should be returned). + * Specific keys to retrieve from the shared group (if not specified, all keys will be returned, while an empty array + * indicates that no keys should be returned). */ Keys?: string[]; - /** - / If true, return the list of all members of the shared group. - */ - GetMembers?: boolean; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetSharedGroupDataResult - */ export interface GetSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Data for the requested keys. - */ + /** Data for the requested keys. */ Data?: { [key: string]: SharedGroupDataRecord }; + /** List of PlayFabId identifiers for the members of this group, if requested. */ + Members?: string[]; + + } + + export interface GetStoreItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** The base catalog that this store is a part of. */ + CatalogVersion?: string; + /** Additional data about the store. */ + MarketingData?: StoreMarketingModel; + /** How the store was last updated (Admin or a third party). */ + Source?: string; + /** Array of items which can be purchased from this store. */ + Store?: StoreItem[]; + /** The ID of this store. */ + StoreId?: string; + + } + + export interface GetStoreItemsServerRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version to store items from. Use default catalog version if null */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / List of PlayFabId identifiers for the members of this group, if requested. + * Optional identifier for the player to use in requesting the store information - if used, segment overrides will be + * applied */ - Members?: string[]; + PlayFabId?: string; + /** Unqiue identifier for the store which is being requested */ + StoreId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTimeRequest - */ export interface GetTimeRequest extends PlayFabModule.IPlayFabRequestCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTimeResult - */ export interface GetTimeResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Current server time when the request was received, in UTC - */ + /** Current server time when the request was received, in UTC */ Time: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleDataRequest - */ export interface GetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific keys to search for in the title data (leave null to get all keys) */ + Keys?: string[]; /** - / Specific keys to search for in the title data (leave null to get all keys) + * Optional field that specifies the name of an override. This value is ignored when used by the game client; otherwise, + * the overrides are applied automatically to the title data. */ - Keys?: string[]; + OverrideLabel?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleDataResult - */ export interface GetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { - /** - / a dictionary object of key / value pairs - */ - Data?: { [key: string]: string }; + /** a dictionary object of key / value pairs */ + Data?: { [key: string]: string | null }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleNewsRequest - */ export interface GetTitleNewsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Limits the results to the last n entries. Defaults to 10 if not set. - */ + /** Limits the results to the last n entries. Defaults to 10 if not set. */ Count?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetTitleNewsResult - */ export interface GetTitleNewsResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of news items. - */ + /** Array of localized news items. */ News?: TitleNewsItem[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserAccountInfoRequest - */ export interface GetUserAccountInfoRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserAccountInfoResult - */ export interface GetUserAccountInfoResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Account details for the user whose information was requested. - */ + /** Account details for the user whose information was requested. */ UserInfo?: UserAccountInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserBansRequest - */ export interface GetUserBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserBansResult - */ export interface GetUserBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information about the bans - */ + /** Information about the bans */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserDataRequest - */ export interface GetUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Specific keys to search for in the custom user data. - */ - Keys?: string[]; - /** - / The version that currently exists according to the caller. The call will return the data for all of the keys if the version in the system is greater than this. + * The version that currently exists according to the caller. The call will return the data for all of the keys if the + * version in the system is greater than this. */ IfChangedFromDataVersion?: number; + /** Specific keys to search for in the custom user data. */ + Keys?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserDataResult - */ export interface GetUserDataResult extends PlayFabModule.IPlayFabResultCommon { + /** User specific data for this title. */ + Data?: { [key: string]: UserDataRecord }; /** - / PlayFab unique identifier of the user whose custom data is being returned. - */ - PlayFabId?: string; - /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; - /** - / User specific data for this title. - */ - Data?: { [key: string]: UserDataRecord }; + /** PlayFab unique identifier of the user whose custom data is being returned. */ + PlayFabId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserInventoryRequest - */ export interface GetUserInventoryRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GetUserInventoryResult - */ export interface GetUserInventoryResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Array of inventory items belonging to the user. - */ + /** Array of inventory items belonging to the user. */ Inventory?: ItemInstance[]; - /** - / Array of virtual currency balance(s) belonging to the user. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Array of virtual currency balance(s) belonging to the user. */ VirtualCurrency?: { [key: string]: number }; - /** - / Array of remaining times and timestamps for virtual currencies. - */ + /** Array of remaining times and timestamps for virtual currencies. */ VirtualCurrencyRechargeTimes?: { [key: string]: VirtualCurrencyRechargeTime }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantCharacterToUserRequest - */ export interface GrantCharacterToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Non-unique display name of the character being granted. - */ + /** Non-unique display name of the character being granted (1-40 characters in length). */ CharacterName: string; - /** - / Type of the character being granted; statistics can be sliced based on this value. - */ + /** Type of the character being granted; statistics can be sliced based on this value. */ CharacterType: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantCharacterToUserResult - */ export interface GrantCharacterToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier tagged to this character. - */ + /** Unique identifier tagged to this character. */ CharacterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantedItemInstance - */ export interface GrantedItemInstance { + /** Game specific comment associated with this instance when it was added to the user inventory. */ + Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ + BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Result of this operation. - */ - Result: boolean; - /** - / Unique identifier for the inventory item, as defined in the catalog. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ + DisplayName?: string; + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ + /** Unique item identifier for this specific instance of the item. */ ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId?: string; + /** Timestamp for when this instance was purchased. */ PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ + /** Total number of remaining uses, if this is a consumable item. */ RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ - Annotation?: string; - /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. - */ - BundleParent?: string; - /** - / CatalogItem.DisplayName at the time this item was purchased. - */ - DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Result of this operation. */ + Result: boolean; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToCharacterRequest - */ export interface GrantItemsToCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** String detailing any additional information concerning this operation. */ + Annotation?: string; + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / String detailing any additional information concerning this operation. - */ - Annotation?: string; - /** - / Array of itemIds to grant to the user. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of itemIds to grant to the user. */ ItemIds?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToCharacterResult - */ export interface GrantItemsToCharacterResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUserRequest - */ export interface GrantItemsToUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ - CatalogVersion?: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / String detailing any additional information concerning this operation. - */ + /** String detailing any additional information concerning this operation. */ Annotation?: string; - /** - / Array of itemIds to grant to the user. - */ + /** Catalog version from which items are to be granted. */ + CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of itemIds to grant to the user. */ ItemIds: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUserResult - */ export interface GrantItemsToUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUsersRequest - */ export interface GrantItemsToUsersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Catalog version from which items are to be granted. - */ + /** Catalog version from which items are to be granted. */ CatalogVersion?: string; - /** - / Array of items to grant and the users to whom the items are to be granted. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Array of items to grant and the users to whom the items are to be granted. */ ItemGrants: ItemGrant[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.GrantItemsToUsersResult - */ export interface GrantItemsToUsersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Array of items granted to users. - */ + /** Array of items granted to users. */ ItemGrantResults?: GrantedItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ItemGrant - */ export interface ItemGrant { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the catalog item to be granted to the user. - */ - ItemId: string; - /** - / String detailing any additional information concerning this operation. - */ + /** String detailing any additional information concerning this operation. */ Annotation?: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; + /** Unique identifier of the catalog item to be granted to the user. */ + ItemId: string; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ItemInstance - */ export interface ItemInstance { - /** - / Unique identifier for the inventory item, as defined in the catalog. - */ - ItemId?: string; - /** - / Unique item identifier for this specific instance of the item. - */ - ItemInstanceId?: string; - /** - / Class name for the inventory item, as defined in the catalog. - */ - ItemClass?: string; - /** - / Timestamp for when this instance was purchased. - */ - PurchaseDate?: string; - /** - / Timestamp for when this instance will expire. - */ - Expiration?: string; - /** - / Total number of remaining uses, if this is a consumable item. - */ - RemainingUses?: number; - /** - / The number of uses that were added or removed to this item in this call. - */ - UsesIncrementedBy?: number; - /** - / Game specific comment associated with this instance when it was added to the user inventory. - */ + /** Game specific comment associated with this instance when it was added to the user inventory. */ Annotation?: string; + /** Array of unique items that were awarded when this catalog item was purchased. */ + BundleContents?: string[]; /** - / Catalog version for the inventory item, when this instance was created. - */ - CatalogVersion?: string; - /** - / Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or container. + * Unique identifier for the parent inventory item, as defined in the catalog, for object which were added from a bundle or + * container. */ BundleParent?: string; + /** Catalog version for the inventory item, when this instance was created. */ + CatalogVersion?: string; /** - / CatalogItem.DisplayName at the time this item was purchased. + * A set of custom key-value pairs on the instance of the inventory item, which is not to be confused with the catalog + * item's custom data. */ + CustomData?: { [key: string]: string | null }; + /** CatalogItem.DisplayName at the time this item was purchased. */ DisplayName?: string; - /** - / Currency type for the cost of the catalog item. - */ + /** Timestamp for when this instance will expire. */ + Expiration?: string; + /** Class name for the inventory item, as defined in the catalog. */ + ItemClass?: string; + /** Unique identifier for the inventory item, as defined in the catalog. */ + ItemId?: string; + /** Unique item identifier for this specific instance of the item. */ + ItemInstanceId?: string; + /** Timestamp for when this instance was purchased. */ + PurchaseDate?: string; + /** Total number of remaining uses, if this is a consumable item. */ + RemainingUses?: number; + /** Currency type for the cost of the catalog item. Not available when granting items. */ UnitCurrency?: string; - /** - / Cost of the catalog item in the given currency. - */ + /** Cost of the catalog item in the given currency. Not available when granting items. */ UnitPrice: number; - /** - / Array of unique items that were awarded when this catalog item was purchased. - */ - BundleContents?: string[]; - /** - / A set of custom key-value pairs on the inventory item. - */ - CustomData?: { [key: string]: string }; + /** The number of uses that were added or removed to this item in this call. */ + UsesIncrementedBy?: number; + + } + + export interface LinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Battle.net account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LinkedPlatformAccountModel - */ export interface LinkedPlatformAccountModel { - /** - / Authentication platform - */ + /** Linked account email of the user on the platform, if available */ + Email?: string; + /** Authentication platform */ Platform?: string; - /** - / Unique account identifier of the user on the platform - */ + /** Unique account identifier of the user on the platform */ PlatformUserId?: string; - /** - / Linked account username of the user on the platform, if available - */ + /** Linked account username of the user on the platform, if available */ Username?: string; - /** - / Linked account email of the user on the platform, if available - */ - Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ListUsersCharactersRequest - */ - export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Switch account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * The JSON Web token (JWT) returned by Nintendo after login. Used to validate the request and find the user ID (Nintendo + * Switch subject) to link with. */ + IdentityToken: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ListUsersCharactersResult - */ - export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { - /** - / The requested list of characters. - */ - Characters?: CharacterResult[]; + export interface LinkNintendoServiceAccountSubjectRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to a specific Nintendo Service Account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The Nintendo Service Account subject or id to link to the PlayFab user. */ + Subject: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LocationModel - */ - export interface LocationModel { - /** - / The two-character continent code for this location - */ - ContinentCode?: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode?: string; - /** - / City name. - */ - City?: string; - /** - / Latitude coordinate of the geographic location. - */ - Latitude?: number; - /** - / Longitude coordinate of the geographic location. - */ - Longitude?: number; + export interface LinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the Nintendo Switch Device ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Nintendo Switch unique identifier for the user's device. */ + NintendoSwitchDeviceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - type LoginIdentityProvider = "Unknown" - | "PlayFab" - | "Custom" - | "GameCenter" - | "GooglePlay" - | "Steam" - | "XBoxLive" - | "PSN" - | "Kongregate" - | "Facebook" - | "IOSDevice" - | "AndroidDevice" - | "Twitch" - | "WindowsHello"; + export interface LinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.LogStatement - */ - export interface LogStatement { - /** - / 'Debug', 'Info', or 'Error' - */ - Level?: string; - Message?: string; + } + + export interface LinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Authentication code provided by the PlayStation :tm: Network. */ + AuthCode: string; /** - / Optional object accompanying the message as contextual information + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". */ - Data?: any; + AuthVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyCharacterVirtualCurrencyResult - */ - export interface ModifyCharacterVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface LinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyItemUsesRequest - */ - export interface ModifyItemUsesRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface LinkPSNIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; /** - / PlayFab unique identifier of the user whose item is being modified. + * Id of the PlayStation :tm: Network issuer environment. If null, defaults to the production environment. This must match + * the issuer the account signs in under, otherwise the link will not be resolved by that sign in. */ + IssuerId?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; + /** Id of the PlayStation :tm: Network user. Also known as the PSN Account Id. */ + PSNUserId: string; /** - / Unique instance identifier of the item to be modified. - */ - ItemInstanceId: string; - /** - / Number of uses to add to the item. Can be negative to remove uses. + * The PlayStation :tm: Network sandbox to key the link under. Sandbox membership is per account, not per title: supply + * this only when the account signs in from a sandbox, and omit it otherwise, including for all retail accounts. This must + * match the sandbox the account signs in from, otherwise the link will not be resolved by that sign in. */ - UsesToAdd: number; + SandboxId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyItemUsesResult - */ - export interface ModifyItemUsesResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the item with uses consumed. - */ - ItemInstanceId?: string; - /** - / Number of uses remaining on the item. - */ - RemainingUses: number; + export interface LinkPSNIdResponse extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ModifyUserVirtualCurrencyResult - */ - export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { - /** - / User currency was subtracted from. - */ - PlayFabId?: string; - /** - / Name of the virtual currency which was modified. - */ - VirtualCurrency?: string; - /** - / Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase over this value will be discarded. - */ - BalanceChange: number; - /** - / Balance of the virtual currency after modification. - */ - Balance: number; + export interface LinkServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the custom ID, unlink the other user and re-link. */ + ForceLink?: boolean; + /** Unique PlayFab identifier. */ + PlayFabId: string; + /** Unique server custom identifier for this player. */ + ServerCustomId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromCharacterRequest - */ - export interface MoveItemToCharacterFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique identifier of the character that currently has the item. - */ - GivingCharacterId: string; - /** - / Unique identifier of the character that will be receiving the item. - */ - ReceivingCharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + export interface LinkServerCustomIdResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromCharacterResult - */ - export interface MoveItemToCharacterFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; + /** Unique Steam identifier for a user. */ + SteamId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromUserRequest - */ - export interface MoveItemToCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + export interface LinkSteamIdResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToCharacterFromUserResult - */ - export interface MoveItemToCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Twitch access token for authentication. */ + AccessToken: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToUserFromCharacterRequest - */ - export interface MoveItemToUserFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface LinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ - CharacterId: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ - ItemInstanceId: string; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.MoveItemToUserFromCharacterResult - */ - export interface MoveItemToUserFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + export interface LinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NameIdentifier - */ - export interface NameIdentifier { - Name?: string; - Id?: string; + export interface LinkXboxIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** If another user is already linked to the account, unlink the other user and re-link. */ + ForceLink?: boolean; + /** PlayFab unique identifier of the user to link. */ + PlayFabId: string; + /** The id of Xbox Live sandbox. */ + Sandbox: string; + /** Unique Xbox identifier for a user. */ + XboxId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NotifyMatchmakerPlayerLeftRequest - */ - export interface NotifyMatchmakerPlayerLeftRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Instance the user is leaving. - */ - LobbyId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface ListPlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.NotifyMatchmakerPlayerLeftResult - */ - export interface NotifyMatchmakerPlayerLeftResult extends PlayFabModule.IPlayFabResultCommon { + export interface ListPlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties are being returned. */ + PlayFabId?: string; + /** Player specific properties and their corresponding values for this title. */ + Properties?: CustomPropertyDetails[]; /** - / State of user leaving the Game Server Instance. + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - PlayerState?: string; + PropertiesVersion: number; } - type PlayerConnectionState = "Unassigned" - | "Connecting" - | "Participating" - | "Participated"; + export interface ListUsersCharactersRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLeaderboardEntry - */ - export interface PlayerLeaderboardEntry { - /** - / PlayFab unique identifier of the user for this leaderboard entry. - */ - PlayFabId?: string; - /** - / Title-specific display name of the user for this leaderboard entry. - */ - DisplayName?: string; - /** - / Specific value of the user's statistic. - */ - StatValue: number; - /** - / User's overall position in the leaderboard. - */ - Position: number; - /** - / The profile of the user, if requested. - */ - Profile?: PlayerProfileModel; + } + + export interface ListUsersCharactersResult extends PlayFabModule.IPlayFabResultCommon { + /** The requested list of characters. */ + Characters?: CharacterResult[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLinkedAccount - */ - export interface PlayerLinkedAccount { - /** - / Authentication platform - */ - Platform?: string; - /** - / Platform user identifier - */ - PlatformUserId?: string; - /** - / Linked account's username - */ - Username?: string; - /** - / Linked account's email - */ - Email?: string; + export interface LocalizedPushNotificationProperties { + /** Message of the localized push notification template. */ + Message?: string; + /** Subject of the localized push notification template. */ + Subject?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerLocation - */ - export interface PlayerLocation { - /** - / The two-character continent code for this location - */ - ContinentCode: string; - /** - / The two-character ISO 3166-1 country code for the country associated with the location - */ - CountryCode: string; - /** - / City of the player's geographic location. - */ + export interface LocationModel { + /** City name. */ City?: string; - /** - / Latitude coordinate of the player's geographic location. - */ + /** The two-character continent code for this location */ + ContinentCode?: string; + /** The two-character ISO 3166-1 country code for the country associated with the location */ + CountryCode?: string; + /** Latitude coordinate of the geographic location. */ Latitude?: number; - /** - / Longitude coordinate of the player's geographic location. - */ + /** Longitude coordinate of the geographic location. */ Longitude?: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfile - */ - export interface PlayerProfile { - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Player record created - */ - Created?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / Banned until UTC Date. If permanent ban this is set for 20 years after the original ban date. - */ - BannedUntil?: string; - /** - / Image URL of the player's avatar. - */ - AvatarUrl?: string; - /** - / Dictionary of player's statistics using only the latest version's value - */ - Statistics?: { [key: string]: number }; - /** - / A sum of player's total purchases in USD across all currencies. - */ - TotalValueToDateInUSD?: number; - /** - / Dictionary of player's total purchases by currency. - */ - ValuesToDate?: { [key: string]: number }; - /** - / List of player's tags for segmentation. - */ - Tags?: string[]; - /** - / Dictionary of player's locations by type. - */ - Locations?: { [key: string]: PlayerLocation }; - /** - / Dictionary of player's virtual currency balances - */ - VirtualCurrencyBalances?: { [key: string]: number }; - /** - / Array of ad campaigns player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttribution[]; - /** - / Array of configured push notification end points - */ - PushNotificationRegistrations?: PushNotificationRegistration[]; - /** - / Array of third party accounts linked to this player - */ - LinkedAccounts?: PlayerLinkedAccount[]; - /** - / Array of player statistics - */ - PlayerStatistics?: PlayerStatistic[]; + type LoginIdentityProvider = "Unknown" + + | "PlayFab" + | "Custom" + | "GameCenter" + | "GooglePlay" + | "Steam" + | "XBoxLive" + | "PSN" + | "Kongregate" + | "Facebook" + | "IOSDevice" + | "AndroidDevice" + | "Twitch" + | "WindowsHello" + | "GameServer" + | "CustomServer" + | "NintendoSwitch" + | "FacebookInstantGames" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; + + export interface LoginWithAndroidDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Specific model of the user's device. */ + AndroidDevice?: string; + /** Android device identifier for the user's device. */ + AndroidDeviceId: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + + } + + export interface LoginWithBattleNetRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The JSON Web Token (JWT) returned by Battle.net after login */ + IdentityToken: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + + } + + export interface LoginWithCustomIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** Custom unique identifier for the user, generated by the title. */ + CustomId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + + } + + export interface LoginWithIOSDeviceIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Vendor-specific iOS identifier for the user's device. */ + DeviceId: string; + /** Specific model of the user's device. */ + DeviceModel?: string; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Specific Operating System version for the user's device. */ + OS?: string; + + } + + export interface LoginWithPSNRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Auth code provided by the PlayStation :tm: Network OAuth provider. */ + AuthCode: string; + /** + * Optional PlayStation :tm: Network auth version. Controls which PlayStation :tm: Network auth version is used. Accepted + * values are "v2" and "v3". + */ + AuthVersion?: string; + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Id of the PlayStation :tm: Network issuer environment. If null, defaults to production environment. */ + IssuerId?: number; + /** Redirect URI supplied to PlayStation :tm: Network when requesting an auth code */ + RedirectUri: string; + + } + + export interface LoginWithServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** The backend server identifier for this player. */ + ServerCustomId: string; + + } + + export interface LoginWithSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Unique Steam identifier for a user. */ + SteamId: string; + + } + + export interface LoginWithTwitchRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Twitch access token for authentication. */ + AccessToken: string; + /** If true, create a new PlayFab account if one does not exist. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Parameters for requesting additional player info. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Player secret for additional authentication. */ + PlayerSecret?: string; + /** PlayFab unique identifier of the user. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfileModel - */ - export interface PlayerProfileModel { - /** - / Publisher this player belongs to - */ - PublisherId?: string; - /** - / Title ID this profile applies to - */ - TitleId?: string; - /** - / PlayFab Player ID - */ - PlayerId?: string; - /** - / Player record created - */ - Created?: string; - /** - / Player account origination - */ - Origination?: string; - /** - / Last login - */ - LastLogin?: string; - /** - / If the player is currently banned, the UTC Date when the ban expires - */ - BannedUntil?: string; - /** - / List of geographic locations where the player has logged-in - */ - Locations?: LocationModel[]; - /** - / Player Display Name - */ - DisplayName?: string; - /** - / Image URL of the player's avatar - */ - AvatarUrl?: string; - /** - / List of player's tags for segmentation - */ - Tags?: TagModel[]; - /** - / List of configured end points registered for sending the player push notifications - */ - PushNotificationRegistrations?: PushNotificationRegistrationModel[]; - /** - / List of third party accounts linked to this player - */ - LinkedAccounts?: LinkedPlatformAccountModel[]; - /** - / List of advertising campaigns the player has been attributed to - */ - AdCampaignAttributions?: AdCampaignAttributionModel[]; - /** - / A sum of player's total purchases across all real-money currencies, converted to US Dollars equivalent - */ - TotalValueToDateInUSD?: number; - /** - / List of player's total lifetime real-money purchases by currency - */ - ValuesToDate?: ValueToDateModel[]; - /** - / List of player's virtual currency balances - */ - VirtualCurrencyBalances?: VirtualCurrencyBalanceModel[]; - /** - / List of leaderboard statistic values for the player - */ - Statistics?: StatisticModel[]; + export interface LoginWithXboxIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** The id of Xbox Live sandbox. */ + Sandbox: string; + /** Unique Xbox identifier for a user. */ + XboxId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerProfileViewConstraints - */ - export interface PlayerProfileViewConstraints { - /** - / Whether to show the display name. Defaults to false - */ - ShowDisplayName: boolean; - /** - / Whether to show the created date. Defaults to false - */ - ShowCreated: boolean; - /** - / Whether to show origination. Defaults to false - */ - ShowOrigination: boolean; - /** - / Whether to show the last login time. Defaults to false - */ - ShowLastLogin: boolean; - /** - / Whether to show the banned until time. Defaults to false - */ - ShowBannedUntil: boolean; - /** - / Whether to show statistics, the most recent version of each stat. Defaults to false - */ - ShowStatistics: boolean; - /** - / Whether to show campaign attributions. Defaults to false - */ - ShowCampaignAttributions: boolean; - /** - / Whether to show push notification registrations. Defaults to false - */ - ShowPushNotificationRegistrations: boolean; - /** - / Whether to show the linked accounts. Defaults to false - */ - ShowLinkedAccounts: boolean; - /** - / Whether to show the total value to date in usd. Defaults to false - */ - ShowTotalValueToDateInUsd: boolean; - /** - / Whether to show the values to date. Defaults to false - */ - ShowValuesToDate: boolean; - /** - / Whether to show tags. Defaults to false - */ - ShowTags: boolean; - /** - / Whether to show player's locations. Defaults to false - */ - ShowLocations: boolean; - /** - / Whether to show player's avatar URL. Defaults to false - */ - ShowAvatarUrl: boolean; + export interface LoginWithXboxRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Automatically create a PlayFab account if one is not currently linked to this ID. */ + CreateAccount?: boolean; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Flags for which pieces of info to return for the user. */ + InfoRequestParameters?: GetPlayerCombinedInfoRequestParams; + /** Token provided by the Xbox Live SDK/XDK method GetTokenAndSignatureAsync("POST", "https://playfabapi.com/", ""). */ + XboxToken: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerStatistic - */ - export interface PlayerStatistic { - /** - / Statistic ID - */ - Id?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - StatisticVersion: number; - /** - / Current statistic value - */ - StatisticValue: number; - /** - / Statistic name - */ - Name?: string; + export interface LogStatement { + /** Optional object accompanying the message as contextual information */ + Data?: any; + /** 'Debug', 'Info', or 'Error' */ + Level?: string; + Message?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PlayerStatisticVersion - */ - export interface PlayerStatisticVersion { - /** - / name of the statistic when the version became active - */ - StatisticName?: string; + export interface MembershipModel { + /** Whether this membership is active. That is, whether the MembershipExpiration time has been reached. */ + IsActive: boolean; + /** The time this membership expires */ + MembershipExpiration: string; + /** The id of the membership */ + MembershipId?: string; /** - / version of the statistic + * Membership expirations can be explicitly overridden (via game manager or the admin api). If this membership has been + * overridden, this will be the new expiration time. */ - Version: number; - /** - / time at which the statistic version was scheduled to become active, based on the configured ResetInterval - */ - ScheduledActivationTime?: string; - /** - / time when the statistic version became active - */ - ActivationTime: string; - /** - / time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval - */ - ScheduledDeactivationTime?: string; - /** - / time when the statistic version became inactive due to statistic version incrementing - */ - DeactivationTime?: string; + OverrideExpiration?: string; + /** The list of subscriptions that this player has for this membership */ + Subscriptions?: SubscriptionModel[]; } - type PushNotificationPlatform = "ApplePushNotificationService" - | "GoogleCloudMessaging"; + export interface ModifyCharacterVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; + + } + + export interface ModifyItemUsesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique instance identifier of the item to be modified. */ + ItemInstanceId: string; + /** PlayFab unique identifier of the user whose item is being modified. */ + PlayFabId: string; + /** Number of uses to add to the item. Can be negative to remove uses. */ + UsesToAdd: number; + + } + + export interface ModifyItemUsesResult extends PlayFabModule.IPlayFabResultCommon { + /** Unique instance identifier of the item with uses consumed. */ + ItemInstanceId?: string; + /** Number of uses remaining on the item. */ + RemainingUses: number; + + } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PushNotificationRegistration - */ - export interface PushNotificationRegistration { + export interface ModifyUserVirtualCurrencyResult extends PlayFabModule.IPlayFabResultCommon { + /** Balance of the virtual currency after modification. */ + Balance: number; /** - / Push notification platform + * Amount added or subtracted from the user's virtual currency. Maximum VC balance is Int32 (2,147,483,647). Any increase + * over this value will be discarded. */ - Platform?: string; + BalanceChange: number; + /** User currency was subtracted from. */ + PlayFabId?: string; + /** Name of the virtual currency which was modified. */ + VirtualCurrency?: string; + + } + + export interface MoveItemToCharacterFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique identifier of the character that currently has the item. */ + GivingCharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Unique identifier of the character that will be receiving the item. */ + ReceivingCharacterId: string; + + } + + export interface MoveItemToCharacterFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface MoveItemToCharacterFromUserRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface MoveItemToCharacterFromUserResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface MoveItemToUserFromCharacterRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface MoveItemToUserFromCharacterResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface NintendoServiceAccountPlayFabIdPair { + /** Unique Nintendo Switch Service Account identifier for a user. */ + NintendoServiceAccountId?: string; /** - / Notification configured endpoint + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Service Account + * identifier. */ - NotificationEndpointARN?: string; + PlayFabId?: string; + + } + + export interface NintendoSwitchPlayFabIdPair { + /** Unique Nintendo Switch Device identifier for a user. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Nintendo Switch Device identifier. */ + PlayFabId?: string; + + } + + export interface OpenIdSubjectIdentifier { + /** The issuer URL for the OpenId Connect provider, or the override URL if an override exists. */ + Issuer: string; + /** The unique subject identifier within the context of the issuer. */ + Subject: string; + + } + + export interface OpenIdSubjectIdentifierPlayFabIdPair { + /** Unique OpenId Connect identifier for a user. */ + OpenIdSubjectIdentifier?: OpenIdSubjectIdentifier; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the OpenId Connect identifier. */ + PlayFabId?: string; + + } + + export interface PlayerLeaderboardEntry { + /** Title-specific display name of the user for this leaderboard entry. */ + DisplayName?: string; + /** PlayFab unique identifier of the user for this leaderboard entry. */ + PlayFabId?: string; + /** User's overall position in the leaderboard. */ + Position: number; + /** The profile of the user, if requested. */ + Profile?: PlayerProfileModel; + /** Specific value of the user's statistic. */ + StatValue: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.PushNotificationRegistrationModel - */ - export interface PushNotificationRegistrationModel { + export interface PlayerProfileModel { + /** List of advertising campaigns the player has been attributed to */ + AdCampaignAttributions?: AdCampaignAttributionModel[]; + /** URL of the player's avatar image */ + AvatarUrl?: string; + /** If the player is currently banned, the UTC Date when the ban expires */ + BannedUntil?: string; + /** List of all contact email info associated with the player account */ + ContactEmailAddresses?: ContactEmailInfoModel[]; + /** Player record created */ + Created?: string; + /** Player display name */ + DisplayName?: string; /** - / Push notification platform + * List of experiment variants for the player. Note that these variants are not guaranteed to be up-to-date when returned + * during login because the player profile is updated only after login. Instead, use the LoginResult.TreatmentAssignment + * property during login to get the correct variants and variables. */ - Platform?: string; + ExperimentVariants?: string[]; + /** UTC time when the player most recently logged in to the title */ + LastLogin?: string; + /** List of all authentication systems linked to this player account */ + LinkedAccounts?: LinkedPlatformAccountModel[]; + /** List of geographic locations from which the player has logged in to the title */ + Locations?: LocationModel[]; + /** List of memberships for the player, along with whether are expired. */ + Memberships?: MembershipModel[]; + /** Player account origination */ + Origination?: string; + /** PlayFab player account unique identifier */ + PlayerId?: string; + /** Publisher this player belongs to */ + PublisherId?: string; + /** List of configured end points registered for sending the player push notifications */ + PushNotificationRegistrations?: PushNotificationRegistrationModel[]; + /** List of leaderboard statistic values for the player */ + Statistics?: StatisticModel[]; + /** List of player's tags for segmentation */ + Tags?: TagModel[]; + /** Title ID this player profile applies to */ + TitleId?: string; /** - / Notification configured endpoint + * Sum of the player's purchases made with real-money currencies, converted to US dollars equivalent and represented as a + * whole number of cents (1/100 USD). For example, 999 indicates nine dollars and ninety-nine cents. */ - NotificationEndpointARN?: string; + TotalValueToDateInUSD?: number; + /** List of the player's lifetime purchase totals, summed by real-money currency */ + ValuesToDate?: ValueToDateModel[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RandomResultTableListing - */ - export interface RandomResultTableListing { - /** - / Catalog version this table is associated with - */ - CatalogVersion?: string; - /** - / Unique name for this drop table - */ - TableId: string; - /** - / Child nodes that indicate what kind of drop table item this actually is. - */ - Nodes: ResultTableNode[]; + export interface PlayerProfileViewConstraints { + /** Whether to show player's avatar URL. Defaults to false */ + ShowAvatarUrl: boolean; + /** Whether to show the banned until time. Defaults to false */ + ShowBannedUntil: boolean; + /** Whether to show campaign attributions. Defaults to false */ + ShowCampaignAttributions: boolean; + /** Whether to show contact email addresses. Defaults to false */ + ShowContactEmailAddresses: boolean; + /** Whether to show the created date. Defaults to false */ + ShowCreated: boolean; + /** Whether to show the display name. Defaults to false */ + ShowDisplayName: boolean; + /** Whether to show player's experiment variants. Defaults to false */ + ShowExperimentVariants: boolean; + /** Whether to show the last login time. Defaults to false */ + ShowLastLogin: boolean; + /** Whether to show the linked accounts. Defaults to false */ + ShowLinkedAccounts: boolean; + /** Whether to show player's locations. Defaults to false */ + ShowLocations: boolean; + /** Whether to show player's membership information. Defaults to false */ + ShowMemberships: boolean; + /** Whether to show origination. Defaults to false */ + ShowOrigination: boolean; + /** Whether to show push notification registrations. Defaults to false */ + ShowPushNotificationRegistrations: boolean; + /** Reserved for future development */ + ShowStatistics: boolean; + /** Whether to show tags. Defaults to false */ + ShowTags: boolean; + /** Whether to show the total value to date in usd. Defaults to false */ + ShowTotalValueToDateInUsd: boolean; + /** Whether to show the values to date. Defaults to false */ + ShowValuesToDate: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemCouponRequest - */ - export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Generated coupon code to redeem. - */ - CouponCode: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Catalog version of the coupon. - */ - CatalogVersion?: string; - /** - / Optional identifier for the Character that should receive the item. If null, item is added to the player - */ - CharacterId?: string; + export interface PlayerStatisticVersion { + /** time when the statistic version became active */ + ActivationTime: string; + /** time when the statistic version became inactive due to statistic version incrementing */ + DeactivationTime?: string; + /** time at which the statistic version was scheduled to become active, based on the configured ResetInterval */ + ScheduledActivationTime?: string; + /** time at which the statistic version was scheduled to become inactive, based on the configured ResetInterval */ + ScheduledDeactivationTime?: string; + /** name of the statistic when the version became active */ + StatisticName?: string; + /** version of the statistic */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemCouponResult - */ - export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { + export interface PSNAccountPlayFabIdPair { /** - / Items granted to the player as a result of redeeming the coupon. + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - GrantedItems?: ItemInstance[]; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNAccountId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemMatchmakerTicketRequest - */ - export interface RedeemMatchmakerTicketRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Server authorization ticket passed back from a call to Matchmake or StartGame. - */ - Ticket: string; + export interface PSNOnlinePlayFabIdPair { /** - / Unique identifier of the Game Server Instance that is asking for validation of the authorization ticket. + * Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the PlayStation :tm: Network + * identifier. */ - LobbyId: string; + PlayFabId?: string; + /** Unique PlayStation :tm: Network identifier for a user. */ + PSNOnlineId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RedeemMatchmakerTicketResult - */ - export interface RedeemMatchmakerTicketResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Boolean indicating whether the ticket was validated by the PlayFab service. - */ - TicketIsValid: boolean; - /** - / Error value if the ticket was not validated. - */ - Error?: string; - /** - / User account information for the user validated. - */ - UserInfo?: UserAccountInfo; + export interface PushNotificationPackage { + /** Numerical badge to display on App icon (iOS only) */ + Badge: number; + /** This must be a JSON formatted object. For use with developer-created custom Push Notification plugins */ + CustomData?: string; + /** Icon file to display with the message (Not supported for iOS) */ + Icon?: string; + /** Content of the message (all platforms) */ + Message: string; + /** Sound file to play with the message (all platforms) */ + Sound?: string; + /** Title/Subject of the message. Not supported for iOS */ + Title: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RefreshGameServerInstanceHeartbeatRequest - */ - export interface RefreshGameServerInstanceHeartbeatRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance for which the heartbeat is updated. - */ - LobbyId: string; + type PushNotificationPlatform = "ApplePushNotificationService" - } + | "GoogleCloudMessaging"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RefreshGameServerInstanceHeartbeatResult - */ - export interface RefreshGameServerInstanceHeartbeatResult extends PlayFabModule.IPlayFabResultCommon { + export interface PushNotificationRegistrationModel { + /** Notification configured endpoint */ + NotificationEndpointARN?: string; + /** Push notification platform */ + Platform?: string; } - type Region = "USCentral" - | "USEast" - | "EUWest" - | "Singapore" - | "Japan" - | "Brazil" - | "Australia"; + export interface RandomResultTableListing { + /** Catalog version this table is associated with */ + CatalogVersion?: string; + /** Child nodes that indicate what kind of drop table item this actually is. */ + Nodes: ResultTableNode[]; + /** Unique name for this drop table */ + TableId: string; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RegisterGameRequest - */ - export interface RegisterGameRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / IP address of the Game Server Instance. - */ - ServerHost: string; - /** - / Port number for communication with the Game Server Instance. - */ - ServerPort: string; - /** - / Unique identifier of the build running on the Game Server Instance. - */ - Build: string; - /** - / Region in which the Game Server Instance is running. For matchmaking using non-AWS region names, set this to any AWS region and use Tags (below) to specify your custom region. - */ - Region: string; - /** - / Game Mode the Game Server instance is running. Note that this must be defined in the Game Modes tab in the PlayFab Game Manager, along with the Build ID (the same Game Mode can be defined for multiple Build IDs). - */ - GameMode: string; - /** - / Tags for the Game Server Instance - */ - Tags?: { [key: string]: string }; + } + + export interface RedeemCouponRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Catalog version of the coupon. */ + CatalogVersion?: string; + /** Optional identifier for the Character that should receive the item. If null, item is added to the player */ + CharacterId?: string; + /** Generated coupon code to redeem. */ + CouponCode: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RegisterGameResponse - */ - export interface RegisterGameResponse extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique identifier generated for the Game Server Instance that is registered. - */ - LobbyId?: string; + export interface RedeemCouponResult extends PlayFabModule.IPlayFabResultCommon { + /** Items granted to the player as a result of redeeming the coupon. */ + GrantedItems?: ItemInstance[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveFriendRequest - */ export interface RemoveFriendRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the friend account which is to be removed. - */ + /** PlayFab identifier of the friend account which is to be removed. */ FriendPlayFabId: string; - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RemoveGenericIDRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Generic service identifier to be removed from the player. */ + GenericId: GenericServiceId; + /** PlayFabId of the user to remove. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemovePlayerTagRequest - */ export interface RemovePlayerTagRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique tag for player profile. - */ + /** Unique tag for player profile. */ TagName: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemovePlayerTagResult - */ export interface RemovePlayerTagResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveSharedGroupMembersRequest - */ export interface RemoveSharedGroupMembersRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / An array of unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** An array of unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabIds: string[]; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RemoveSharedGroupMembersResult - */ export interface RemoveSharedGroupMembersResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ReportPlayerServerRequest - */ export interface ReportPlayerServerRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the reporting player. - */ - ReporterId: string; - /** - / PlayFabId of the reported player. - */ - ReporteeId: string; - /** - / Title player was reported in, optional if report not for specific title. - */ - TitleId?: string; - /** - / Optional additional comment by reporting player. - */ + /** Optional additional comment by reporting player. */ Comment?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier of the reported player. */ + ReporteeId: string; + /** PlayFabId of the reporting player. */ + ReporterId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ReportPlayerServerResult - */ export interface ReportPlayerServerResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Indicates whether this action completed successfully. - */ - Updated: boolean; - /** - / The number of remaining reports which may be filed today by this reporting player. - */ + /** The number of remaining reports which may be filed today by this reporting player. */ SubmissionsRemaining: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ResultTableNode - */ export interface ResultTableNode { - /** - / Whether this entry in the table is an item or a link to another table - */ - ResultItemType: string; - /** - / Either an ItemId, or the TableId of another random result table - */ + /** Either an ItemId, or the TableId of another random result table */ ResultItem: string; - /** - / How likely this is to be rolled - larger numbers add more weight - */ + /** Whether this entry in the table is an item or a link to another table */ + ResultItemType: string; + /** How likely this is to be rolled - larger numbers add more weight */ Weight: number; } type ResultTableNodeType = "ItemId" + | "TableId"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeAllBansForUserRequest - */ export interface RevokeAllBansForUserRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeAllBansForUserResult - */ export interface RevokeAllBansForUserResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked. - */ + /** Information on the bans that were revoked. */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeBansRequest - */ export interface RevokeBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Ids of the bans to be revoked. Maximum 100. - */ + /** Ids of the bans to be revoked. Maximum 100. */ BanIds: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeBansResult - */ export interface RevokeBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were revoked - */ + /** Information on the bans that were revoked */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeInventoryItemRequest - */ - export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ + export interface RevokeInventoryItem { + /** Unique PlayFab assigned ID for a specific character owned by a user */ + CharacterId?: string; + /** Unique PlayFab assigned instance identifier of the item */ + ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + + } + + export interface RevokeInventoryItemRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Unique PlayFab assigned instance identifier of the item - */ + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface RevokeInventoryItemsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Array of player items to revoke, between 1 and 25 items. */ + Items: RevokeInventoryItem[]; + + } + + export interface RevokeInventoryItemsResult extends PlayFabModule.IPlayFabResultCommon { + /** Collection of any errors that occurred during processing. */ + Errors?: RevokeItemError[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.RevokeInventoryResult - */ export interface RevokeInventoryResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ScriptExecutionError - */ + export interface RevokeItemError { + /** Specific error that was encountered. */ + Error?: string; + /** Item information that failed to be revoked. */ + Item?: RevokeInventoryItem; + + } + + export interface SavePushNotificationTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Android JSON for the notification template. */ + AndroidPayload?: string; + /** Id of the push notification template. */ + Id?: string; + /** IOS JSON for the notification template. */ + IOSPayload?: string; + /** Dictionary of localized push notification templates with the language as the key. */ + LocalizedPushNotificationTemplates?: { [key: string]: LocalizedPushNotificationProperties }; + /** Name of the push notification template. */ + Name: string; + + } + + export interface SavePushNotificationTemplateResult extends PlayFabModule.IPlayFabResultCommon { + /** Id of the push notification template that was saved. */ + PushNotificationTemplateId?: string; + + } + export interface ScriptExecutionError { /** - / Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError + * Error code, such as CloudScriptNotFound, JavascriptException, CloudScriptFunctionArgumentSizeExceeded, + * CloudScriptAPIRequestCountExceeded, CloudScriptAPIRequestError, or CloudScriptHTTPRequestError */ Error?: string; - /** - / Details about the error - */ + /** Details about the error */ Message?: string; - /** - / Point during the execution of the script at which the error occurred, if any - */ + /** Point during the execution of the script at which the error occurred, if any */ StackTrace?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SendPushNotificationRequest - */ - export interface SendPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFabId of the recipient of the push notification. - */ - Recipient: string; - /** - / Text of message to send. - */ - Message: string; - /** - / Subject of message to send (may not be displayed in all platforms. - */ - Subject?: string; + export interface SendCustomAccountRecoveryEmailRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** User email address attached to their account */ + Email?: string; + /** The email template id of the account recovery email template to send. */ + EmailTemplateId: string; + /** The user's username requesting an account recovery. */ + Username?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SendPushNotificationResult - */ - export interface SendPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { + export interface SendCustomAccountRecoveryEmailResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetFriendTagsRequest - */ - export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab identifier of the player whose friend is to be updated. - */ + export interface SendEmailFromTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** The email template id of the email template to send. */ + EmailTemplateId: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; - /** - / PlayFab identifier of the friend account to which the tag(s) should be applied. - */ - FriendPlayFabId: string; - /** - / Array of tags to set on the friend account. - */ - Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceDataRequest - */ - export interface SetGameServerInstanceDataRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface SendEmailFromTemplateResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface SendPushNotificationFromTemplateRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Id of the push notification template. */ + PushNotificationTemplateId: string; + /** PlayFabId of the push notification recipient. */ + Recipient: string; + + } + + export interface SendPushNotificationRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique identifier of the Game Instance to be updated, in decimal format. + * Allows you to provide precisely formatted json to target devices. This is an advanced feature, allowing you to deliver + * to custom plugin logic, fields, or functionality not natively supported by PlayFab. */ - LobbyId: string; + AdvancedPlatformDelivery?: AdvancedPushPlatformMsg[]; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Text of message to send. */ + Message?: string; /** - / Custom data to set for the specified game server instance. + * Defines all possible push attributes like message, title, icon, etc. Some parameters are device specific - please see + * the PushNotificationPackage documentation for details. */ - GameServerData: string; + Package?: PushNotificationPackage; + /** PlayFabId of the recipient of the push notification. */ + Recipient: string; + /** Subject of message to send (may not be displayed in all platforms) */ + Subject?: string; + /** Target Platforms that should receive the Message or Package. If omitted, we will send to all available platforms. */ + TargetPlatforms?: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceDataResult - */ - export interface SetGameServerInstanceDataResult extends PlayFabModule.IPlayFabResultCommon { + export interface SendPushNotificationResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceStateRequest - */ - export interface SetGameServerInstanceStateRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Instance to be updated, in decimal format. - */ - LobbyId: string; + export interface ServerCustomIDPlayFabIDPair { + /** Unique PlayFab identifier. */ + PlayFabId?: string; + /** Unique server custom identifier for this player. */ + ServerCustomId?: string; + + } + + export interface ServerLoginResult extends PlayFabModule.IPlayFabResultCommon { /** - / State to set for the specified game server instance. + * If LoginTitlePlayerAccountEntity flag is set on the login request the title_player_account will also be logged in and + * returned. */ - State: string; + EntityToken?: EntityTokenResponse; + /** Results for requested info. */ + InfoResultPayload?: GetPlayerCombinedInfoResultPayload; + /** The time of this user's previous login. If there was no previous login, then it's DateTime.MinValue */ + LastLoginTime?: string; + /** True if the master_player_account was newly created on this login. */ + NewlyCreated: boolean; + /** Player's unique PlayFabId. */ + PlayFabId?: string; + /** Unique token authorizing the user and game at the server level, for the current session. */ + SessionTicket?: string; + /** Settings specific to this user. */ + SettingsForUser?: UserSettings; + /** The experimentation treatments for this user at the time of login. */ + TreatmentAssignment?: TreatmentAssignment; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceStateResult - */ - export interface SetGameServerInstanceStateResult extends PlayFabModule.IPlayFabResultCommon { + export interface SetFriendTagsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** PlayFab identifier of the friend account to which the tag(s) should be applied. */ + FriendPlayFabId: string; + /** PlayFab identifier of the player whose friend is to be updated. */ + PlayFabId: string; + /** Array of tags to set on the friend account. */ + Tags: string[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceTagsRequest - */ - export interface SetGameServerInstanceTagsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique identifier of the Game Server Instance to be updated. - */ - LobbyId: string; - /** - / Tags to set for the specified Game Server Instance. Note that this is the complete list of tags to be associated with the Game Server Instance. - */ - Tags: { [key: string]: string }; + export interface SetPlayerSecretRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Player secret that is used to verify API request signatures. */ + PlayerSecret?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetGameServerInstanceTagsResult - */ - export interface SetGameServerInstanceTagsResult extends PlayFabModule.IPlayFabResultCommon { + export interface SetPlayerSecretResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetPublisherDataRequest - */ export interface SetPublisherDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetPublisherDataResult - */ export interface SetPublisherDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetTitleDataRequest - */ export interface SetTitleDataRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. + * key we want to set a value on (note, this is additive - will only replace an existing key's value if they are the same + * name.) Keys are trimmed of whitespace. Keys may not begin with the '!' character. */ Key: string; - /** - / new value to set. Set to null to remove a value - */ + /** new value to set. Set to null to remove a value */ Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SetTitleDataResult - */ export interface SetTitleDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SharedGroupDataRecord - */ export interface SharedGroupDataRecord { - /** - / Data stored for the specified group data key. - */ - Value?: string; - /** - / PlayFabId of the user to last update this value. - */ - LastUpdatedBy?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; - /** - / Indicates whether this data can be read by all users (public) or only members of the group (private). - */ + /** PlayFabId of the user to last update this value. */ + LastUpdatedBy?: string; + /** Indicates whether this data can be read by all users (public) or only members of the group (private). */ Permission?: string; + /** Data stored for the specified group data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticModel - */ + type SourceType = "Admin" + + | "BackEnd" + | "GameClient" + | "GameServer" + | "Partner" + | "Custom" + | "API"; + export interface StatisticModel { - /** - / Statistic name - */ + /** Statistic name */ Name?: string; - /** - / Statistic version (0 if not a versioned statistic) - */ - Version: number; - /** - / Statistic value - */ + /** Statistic value */ Value: number; + /** Statistic version (0 if not a versioned statistic) */ + Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticNameVersion - */ export interface StatisticNameVersion { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; - /** - / the version of the statistic to be returned - */ + /** the version of the statistic to be returned */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticUpdate - */ export interface StatisticUpdate { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName: string; + /** statistic value for the player */ + Value: number; /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when setting the statistic value for the first time. + * for updates to an existing statistic value for a player, the version of the statistic when it was loaded. Null when + * setting the statistic value for the first time. */ Version?: number; - /** - / statistic value for the player - */ - Value: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.StatisticValue - */ export interface StatisticValue { - /** - / unique name of the statistic - */ + /** unique name of the statistic */ StatisticName?: string; - /** - / statistic value for the player - */ + /** statistic value for the player */ Value: number; - /** - / for updates to an existing statistic value for a player, the version of the statistic when it was loaded - */ + /** for updates to an existing statistic value for a player, the version of the statistic when it was loaded */ Version: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SteamPlayFabIdPair - */ + 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 Steam identifier for a user. - */ + /** 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. */ SteamStringId?: string; + + } + + export interface StoreItem { + /** Store specific custom data. The data only exists as part of this store; it is not transferred to item instances */ + CustomData?: any; + /** Intended display position for this item. Note that 0 is the first position */ + DisplayPosition?: number; /** - / Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam identifier. + * Unique identifier of the item as it exists in the catalog - note that this must exactly match the ItemId from the + * catalog */ - PlayFabId?: string; + ItemId: string; + /** Override prices for this item for specific currencies */ + RealCurrencyPrices?: { [key: string]: number }; + /** Override prices for this item in virtual currencies and "RM" (the base Real Money purchase price, in USD pennies) */ + VirtualCurrencyPrices?: { [key: string]: number }; + + } + + export interface StoreMarketingModel { + /** Tagline for a store. */ + Description?: string; + /** Display name of a store as it will appear to users. */ + DisplayName?: string; + /** Custom data about a store. */ + Metadata?: any; + + } + + export interface SubscriptionModel { + /** When this subscription expires. */ + Expiration: string; + /** The time the subscription was orignially purchased */ + InitialSubscriptionTime: string; + /** Whether this subscription is currently active. That is, if Expiration > now. */ + IsActive: boolean; + /** The status of this subscription, according to the subscription provider. */ + Status?: string; + /** The id for this subscription */ + SubscriptionId?: string; + /** The item id for this subscription from the primary catalog */ + SubscriptionItemId?: string; + /** The provider for this subscription. Apple or Google Play are supported today. */ + SubscriptionProvider?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SubtractCharacterVirtualCurrencyRequest - */ + type SubscriptionProviderStatus = "NoError" + + | "Cancelled" + | "UnknownError" + | "BillingError" + | "ProductUnavailable" + | "CustomerDidNotAcceptPriceChange" + | "FreeTrial" + | "PaymentPending"; + export interface SubtractCharacterVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.SubtractUserVirtualCurrencyRequest - */ export interface SubtractUserVirtualCurrencyRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / PlayFab unique identifier of the user whose virtual currency balance is to be decreased. - */ + /** Amount to be subtracted from the user balance of the specified virtual currency. */ + Amount: number; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user whose virtual currency balance is to be decreased. */ PlayFabId: string; - /** - / Name of the virtual currency which is to be decremented. - */ + /** Name of the virtual currency which is to be decremented. */ VirtualCurrency: string; - /** - / Amount to be subtracted from the user balance of the specified virtual currency. - */ - Amount: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.TagModel - */ export interface TagModel { - /** - / Full value of the tag, including namespace - */ + /** Full value of the tag, including namespace */ TagValue?: string; } - type TaskInstanceStatus = "Succeeded" - | "Starting" - | "InProgress" - | "Failed" - | "Aborted" - | "Pending"; - type TitleActivationStatus = "None" + | "ActivatedTitleKey" | "PendingSteam" | "ActivatedSteam" | "RevokedSteam"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.TitleNewsItem - */ export interface TitleNewsItem { - /** - / Date and time when the news items was posted. - */ - Timestamp: string; - /** - / Unique identifier of news item. - */ + /** News item body. */ + Body?: string; + /** Unique identifier of news item. */ NewsId?: string; - /** - / Title of the news item. - */ + /** Date and time when the news item was posted. */ + Timestamp: string; + /** Title of the news item. */ Title?: string; - /** - / News item text. - */ - Body?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerInstanceRequest - */ - export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface TreatmentAssignment { + /** List of the experiment variables. */ + Variables?: Variable[]; + /** List of the experiment variants. */ + Variants?: string[]; + + } + + export interface TwitchPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Twitch identifier. */ + PlayFabId?: string; + /** Unique Twitch identifier for a user. */ + TwitchId?: string; + + } + + export interface UnlinkAppleRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkAppleResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkBattleNetAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkFacebookInstantGamesIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Facebook Instant Games identifier for the user. If not specified, the most recently linked identifier will be used. */ + FacebookInstantGamesId?: string; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkFacebookInstantGamesIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkGameCenterAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkGameCenterAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkNintendoServiceAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Nintendo Switch Device identifier for the user. If not specified, the most recently signed in device ID will be used. */ + NintendoSwitchDeviceId?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkNintendoSwitchDeviceIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkPSNAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + + } + + export interface UnlinkPSNAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkServerCustomIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier. */ + PlayFabId: string; + /** Unique server custom identifier for this player. */ + ServerCustomId: string; + + } + + export interface UnlinkServerCustomIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkSteamIdRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Steam account. */ + PlayFabId: string; + + } + + export interface UnlinkSteamIdResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlinkTwitchAccountRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Valid token issued by Twitch. Used to specify which twitch account to unlink from the profile. By default it uses the + * one that is present on the profile. */ + AccessToken?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ + PlayFabId: string; + + } + + export interface UnlinkXboxAccountRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** PlayFab unique identifier of the user to unlink. */ PlayFabId: string; + + } + + export interface UnlinkXboxAccountResult extends PlayFabModule.IPlayFabResultCommon { + + } + + export interface UnlockContainerInstanceRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog + * associated with the item instance. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / ItemInstanceId of the container to unlock. - */ + /** ItemInstanceId of the container to unlock. */ ContainerItemInstanceId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this parameter is required. + * ItemInstanceId of the key that will be consumed by unlocking this container. If the container requires a key, this + * parameter is required. */ KeyItemInstanceId?: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses catalog associated with the item instance. - */ - CatalogVersion?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerItemRequest - */ export interface UnlockContainerItemRequest extends PlayFabModule.IPlayFabRequestCommon { /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user + * Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary + * catalog. */ + CatalogVersion?: string; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; - /** - / Catalog ItemId of the container type to unlock. - */ + /** Catalog ItemId of the container type to unlock. */ ContainerItemId: string; - /** - / Specifies the catalog version that should be used to determine container contents. If unspecified, uses default/primary catalog. - */ - CatalogVersion?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UnlockContainerItemResult - */ export interface UnlockContainerItemResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Unique instance identifier of the container unlocked. - */ + /** Items granted to the player as a result of unlocking the container. */ + GrantedItems?: ItemInstance[]; + /** Unique instance identifier of the container unlocked. */ UnlockedItemInstanceId?: string; - /** - / Unique instance identifier of the key used to unlock the container, if applicable. - */ + /** Unique instance identifier of the key used to unlock the container, if applicable. */ UnlockedWithItemInstanceId?: string; - /** - / Items granted to the player as a result of unlocking the container. - */ - GrantedItems?: ItemInstance[]; - /** - / Virtual currency granted to the player as a result of unlocking the container. - */ + /** Virtual currency granted to the player as a result of unlocking the container. */ VirtualCurrency?: { [key: string]: number }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateAvatarUrlRequest - */ export interface UpdateAvatarUrlRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / URL of the avatar image. If empty, it removes the existing avatar URL. - */ + /** URL of the avatar image. If empty, it removes the existing avatar URL. */ ImageUrl: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBanRequest - */ - export interface UpdateBanRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / The id of the ban to be updated. - */ + export interface UpdateBanRequest { + /** The updated active state for the ban. Null for no change. */ + Active?: boolean; + /** The id of the ban to be updated. */ BanId: string; - /** - / The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. - */ - Reason?: string; - /** - / The updated expiration date for the ban. Null for no change. - */ + /** The updated expiration date for the ban. Null for no change. */ Expires?: string; - /** - / The updated IP address for the ban. Null for no change. - */ + /** The updated IP address for the ban. Null for no change. */ IPAddress?: string; - /** - / The updated MAC address for the ban. Null for no change. - */ - MACAddress?: string; - /** - / Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. - */ + /** Whether to make this ban permanent. Set to true to make this ban permanent. This will not modify Active state. */ Permanent?: boolean; - /** - / The updated active state for the ban. Null for no change. - */ - Active?: boolean; + /** The updated reason for the ban to be updated. Maximum 140 characters. Null for no change. */ + Reason?: string; + /** The updated family type of the user that should be included in the ban. Null for no change. */ + UserFamilyType?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBansRequest - */ export interface UpdateBansRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / List of bans to be updated. Maximum 100. - */ + /** List of bans to be updated. Maximum 100. */ Bans: UpdateBanRequest[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateBansResult - */ export interface UpdateBansResult extends PlayFabModule.IPlayFabResultCommon { - /** - / Information on the bans that were updated - */ + /** Information on the bans that were updated */ BanData?: BanInfo[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterDataRequest - */ export interface UpdateCharacterDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterDataResult - */ export interface UpdateCharacterDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterStatisticsRequest - */ export interface UpdateCharacterStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; - /** - / Statistics to be updated with the provided values. - */ + /** Statistics to be updated with the provided values. */ CharacterStatistics?: { [key: string]: number }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateCharacterStatisticsResult - */ export interface UpdateCharacterStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdatePlayerStatisticsRequest - */ - export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + export interface UpdatePlayerCustomPropertiesRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. + * Optional field used for concurrency control. One can ensure that the update operation will only be performed if the + * player's properties have not been updated by any other clients since last the version. */ + ExpectedPropertiesVersion?: number; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ PlayFabId: string; + /** Collection of properties to be set for a player. */ + Properties: UpdateProperty[]; + + } + + export interface UpdatePlayerCustomPropertiesResult extends PlayFabModule.IPlayFabResultCommon { + /** PlayFab unique identifier of the user whose properties were updated. */ + PlayFabId?: string; /** - / Statistics to be updated with the provided values + * Indicates the current version of a player's properties that have been set. This is incremented after updates and + * deletes. This version can be provided in update and delete calls for concurrency control. */ - Statistics: StatisticUpdate[]; + PropertiesVersion: number; + + } + + export interface UpdatePlayerStatisticsRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Indicates whether the statistics provided should be set, regardless of the aggregation method set on the statistic. Default is false. + * Indicates whether the statistics provided should be set, regardless of the aggregation method set on the statistic. + * Default is false. */ ForceUpdate?: boolean; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** Statistics to be updated with the provided values */ + Statistics: StatisticUpdate[]; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdatePlayerStatisticsResult - */ export interface UpdatePlayerStatisticsResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateSharedGroupDataRequest - */ + export interface UpdateProperty { + /** Name of the custom property. Can contain Unicode letters and digits. They are limited in size. */ + Name: string; + /** Value of the custom property. Limited to booleans, numbers, and strings. */ + Value: any; + + } + export interface UpdateSharedGroupDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique identifier for the shared group. - */ - SharedGroupId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys in this request. - */ + /** Permission to be applied to all user data keys in this request. */ Permission?: string; + /** Unique identifier for the shared group. */ + SharedGroupId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateSharedGroupDataResult - */ export interface UpdateSharedGroupDataResult extends PlayFabModule.IPlayFabResultCommon { } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserDataRequest - */ export interface UpdateUserDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; - /** - / Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. - */ + /** Permission to be applied to all user data keys written in this request. Defaults to "private" if not set. */ Permission?: string; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserDataResult - */ export interface UpdateUserDataResult extends PlayFabModule.IPlayFabResultCommon { /** - / Indicates the current version of the data that has been set. This is incremented with every set call for that type of data (read-only, internal, etc). This version can be provided in Get calls to find updated data. + * Indicates the current version of the data that has been set. This is incremented with every set call for that type of + * data (read-only, internal, etc). This version can be provided in Get calls to find updated data. */ DataVersion: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserInternalDataRequest - */ export interface UpdateUserInternalDataRequest extends PlayFabModule.IPlayFabRequestCommon { + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ - Data?: { [key: string]: string }; + Data?: { [key: string]: string | null }; /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UpdateUserInventoryItemDataRequest - */ export interface UpdateUserInventoryItemDataRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId?: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned instance identifier of the item + * Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may + * not begin with a '!' character or be null. */ + Data?: { [key: string]: string | null }; + /** Unique PlayFab assigned instance identifier of the item */ ItemInstanceId: string; /** - / Key-value pairs to be written to the custom data. Note that keys are trimmed of whitespace, are limited in size, and may not begin with a '!' character. - */ - Data?: { [key: string]: string }; - /** - / Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language constraints. Use this to delete the keys directly. + * Optional list of Data-keys to remove from UserData. Some SDKs cannot insert null-values into Data due to language + * constraints. Use this to delete the keys directly. */ KeysToRemove?: string[]; + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserAccountInfo - */ export interface UserAccountInfo { - /** - / Unique identifier for the user account - */ - PlayFabId?: string; - /** - / Timestamp indicating when the user account was created - */ + /** User Android device information, if an Android device has been linked */ + AndroidDeviceInfo?: UserAndroidDeviceInfo; + /** Sign in with Apple account information, if an Apple account has been linked */ + AppleAccountInfo?: UserAppleIdInfo; + /** Battle.net account information, if a Battle.net account has been linked */ + BattleNetAccountInfo?: UserBattleNetInfo; + /** Timestamp indicating when the user account was created */ Created: string; - /** - / User account name in the PlayFab service - */ - Username?: string; - /** - / Title-specific information for the user account - */ - TitleInfo?: UserTitleInfo; - /** - / Personal information for the user which is considered more sensitive - */ - PrivateInfo?: UserPrivateAccountInfo; - /** - / User Facebook information, if a Facebook account has been linked - */ + /** Custom ID information, if a custom ID has been assigned */ + CustomIdInfo?: UserCustomIdInfo; + /** User Facebook information, if a Facebook account has been linked */ FacebookInfo?: UserFacebookInfo; - /** - / User Steam information, if a Steam account has been linked - */ - SteamInfo?: UserSteamInfo; - /** - / User Gamecenter information, if a Gamecenter account has been linked - */ + /** Facebook Instant Games account information, if a Facebook Instant Games account has been linked */ + FacebookInstantGamesIdInfo?: UserFacebookInstantGamesIdInfo; + /** User Gamecenter information, if a Gamecenter account has been linked */ GameCenterInfo?: UserGameCenterInfo; - /** - / User iOS device information, if an iOS device has been linked - */ + /** User Google account information, if a Google account has been linked */ + GoogleInfo?: UserGoogleInfo; + /** User Google Play Games account information, if a Google Play Games account has been linked */ + GooglePlayGamesInfo?: UserGooglePlayGamesInfo; + /** User iOS device information, if an iOS device has been linked */ IosDeviceInfo?: UserIosDeviceInfo; - /** - / User Android device information, if an Android device has been linked - */ - AndroidDeviceInfo?: UserAndroidDeviceInfo; - /** - / User Kongregate account information, if a Kongregate account has been linked - */ + /** User Kongregate account information, if a Kongregate account has been linked */ KongregateInfo?: UserKongregateInfo; - /** - / User Twitch account information, if a Twitch account has been linked - */ - TwitchInfo?: UserTwitchInfo; - /** - / User PSN account information, if a PSN account has been linked - */ + /** Nintendo Switch account information, if a Nintendo Switch account has been linked */ + NintendoSwitchAccountInfo?: UserNintendoSwitchAccountIdInfo; + /** Nintendo Switch device information, if a Nintendo Switch device has been linked */ + NintendoSwitchDeviceIdInfo?: UserNintendoSwitchDeviceIdInfo; + /** OpenID Connect information, if any OpenID Connect accounts have been linked */ + OpenIdInfo?: UserOpenIdInfo[]; + /** Unique identifier for the user account */ + PlayFabId?: string; + /** Personal information for the user which is considered more sensitive */ + PrivateInfo?: UserPrivateAccountInfo; + /** User PlayStation :tm: Network account information, if a PlayStation :tm: Network account has been linked */ PsnInfo?: UserPsnInfo; - /** - / User Google account information, if a Google account has been linked - */ - GoogleInfo?: UserGoogleInfo; - /** - / User XBox account information, if a XBox account has been linked - */ + /** Server Custom ID information, if a server custom ID has been assigned */ + ServerCustomIdInfo?: UserServerCustomIdInfo; + /** User Steam information, if a Steam account has been linked */ + SteamInfo?: UserSteamInfo; + /** Title-specific information for the user account */ + TitleInfo?: UserTitleInfo; + /** User Twitch account information, if a Twitch account has been linked */ + TwitchInfo?: UserTwitchInfo; + /** User account name in the PlayFab service */ + Username?: string; + /** User XBox account information, if a XBox account has been linked */ XboxInfo?: UserXboxInfo; - /** - / Custom ID information, if a custom ID has been assigned - */ - CustomIdInfo?: UserCustomIdInfo; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserAndroidDeviceInfo - */ export interface UserAndroidDeviceInfo { - /** - / Android device ID - */ + /** Android device ID */ AndroidDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserCustomIdInfo - */ + export interface UserAppleIdInfo { + /** Apple subject ID */ + AppleSubjectId?: string; + + } + + export interface UserBattleNetInfo { + /** Battle.net identifier */ + BattleNetAccountId?: string; + /** Battle.net display name */ + BattleNetBattleTag?: string; + + } + export interface UserCustomIdInfo { - /** - / Custom ID - */ + /** Custom ID */ CustomId?: string; } type UserDataPermission = "Private" + | "Public"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserDataRecord - */ export interface UserDataRecord { - /** - / Data stored for the specified user data key. - */ - Value?: string; - /** - / Timestamp for when this data was last updated. - */ + /** Timestamp for when this data was last updated. */ LastUpdated: string; /** - / Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData requests being made by one player about another player. + * Indicates whether this data can be read by all users (public) or only the user (private). This is used for GetUserData + * requests being made by one player about another player. */ Permission?: string; + /** Data stored for the specified user data key. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserFacebookInfo - */ export interface UserFacebookInfo { - /** - / Facebook identifier - */ + /** Facebook identifier */ FacebookId?: string; - /** - / Facebook full name - */ + /** Facebook full name */ FullName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserGameCenterInfo - */ + export interface UserFacebookInstantGamesIdInfo { + /** Facebook Instant Games ID */ + FacebookInstantGamesId?: string; + + } + + type UserFamilyType = "None" + + | "Xbox" + | "Steam"; + export interface UserGameCenterInfo { - /** - / Gamecenter identifier - */ + /** Gamecenter identifier */ GameCenterId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserGoogleInfo - */ export interface UserGoogleInfo { - /** - / Google ID - */ - GoogleId?: string; - /** - / Email address of the Google account - */ + /** Email address of the Google account */ GoogleEmail?: string; - /** - / Locale of the Google account - */ - GoogleLocale?: string; - /** - / Gender information of the Google account - */ + /** Gender information of the Google account */ GoogleGender?: string; + /** Google ID */ + GoogleId?: string; + /** Locale of the Google account */ + GoogleLocale?: string; + /** Name of the Google account user */ + GoogleName?: string; + + } + + export interface UserGooglePlayGamesInfo { + /** Avatar image url of the Google Play Games player */ + GooglePlayGamesPlayerAvatarImageUrl?: string; + /** Display name of the Google Play Games player */ + GooglePlayGamesPlayerDisplayName?: string; + /** Google Play Games player ID */ + GooglePlayGamesPlayerId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserIosDeviceInfo - */ export interface UserIosDeviceInfo { - /** - / iOS device ID - */ + /** iOS device ID */ IosDeviceId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserKongregateInfo - */ export interface UserKongregateInfo { - /** - / Kongregate ID - */ + /** Kongregate ID */ KongregateId?: string; - /** - / Kongregate Username - */ + /** Kongregate Username */ KongregateName?: string; } + export interface UserNintendoSwitchAccountIdInfo { + /** Nintendo Switch account subject ID */ + NintendoSwitchAccountSubjectId?: string; + + } + + export interface UserNintendoSwitchDeviceIdInfo { + /** Nintendo Switch Device ID */ + NintendoSwitchDeviceId?: string; + + } + + export interface UserOpenIdInfo { + /** OpenID Connection ID */ + ConnectionId?: string; + /** OpenID Issuer */ + Issuer?: string; + /** OpenID Subject */ + Subject?: string; + + } + type UserOrigination = "Organic" + | "Steam" | "Google" | "Amazon" @@ -5217,248 +6046,213 @@ declare module PlayFabServerModels { | "XboxLive" | "Parse" | "Twitch" - | "WindowsHello"; + | "ServerCustomId" + | "NintendoSwitchDeviceId" + | "FacebookInstantGamesId" + | "OpenIdConnect" + | "Apple" + | "NintendoSwitchAccount" + | "GooglePlayGames" + | "XboxMobileStore" + | "King" + | "BattleNet"; - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserPrivateAccountInfo - */ export interface UserPrivateAccountInfo { - /** - / user email address - */ + /** user email address */ Email?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserPsnInfo - */ export interface UserPsnInfo { /** - / PSN account ID + * Id of the PlayStation :tm: Network issuer environment this account is keyed under. Supply this value as IssuerId when + * looking the account up. */ + IssuerId?: number; + /** PlayStation :tm: Network account ID */ PsnAccountId?: string; - /** - / PSN online ID - */ + /** PlayStation :tm: Network online ID */ PsnOnlineId?: string; + /** PlayStation :tm: Network sandbox ID */ + PsnSandboxId?: string; + + } + + export interface UserServerCustomIdInfo { + /** Custom ID */ + CustomId?: string; + + } + + export interface UserSettings { + /** Boolean for whether this player is eligible for gathering device info. */ + GatherDeviceInfo: boolean; + /** Boolean for whether this player should report OnFocus play-time tracking. */ + GatherFocusInfo: boolean; + /** Boolean for whether this player is eligible for ad tracking. */ + NeedsAttribution: boolean; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserSteamInfo - */ export interface UserSteamInfo { - /** - / Steam identifier - */ - SteamId?: string; - /** - / the country in which the player resides, from Steam data - */ + /** what stage of game ownership the user is listed as being in, from Steam */ + SteamActivationStatus?: string; + /** the country in which the player resides, from Steam data */ SteamCountry?: string; - /** - / currency type set in the user Steam account - */ + /** currency type set in the user Steam account */ SteamCurrency?: string; - /** - / what stage of game ownership the user is listed as being in, from Steam - */ - SteamActivationStatus?: string; + /** Steam identifier */ + SteamId?: string; + /** Steam display name */ + SteamName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserTitleInfo - */ export interface UserTitleInfo { + /** URL to the player's avatar. */ + AvatarUrl?: string; /** - / name of the user, as it is displayed in-game - */ - DisplayName?: string; - /** - / source by which the user first joined the game, if known - */ - Origination?: string; - /** - / timestamp indicating when the user was first associated with this game (this can differ significantly from when the user first registered with PlayFab) + * timestamp indicating when the user was first associated with this game (this can differ significantly from when the user + * first registered with PlayFab) */ Created: string; + /** name of the user, as it is displayed in-game */ + DisplayName?: string; /** - / timestamp for the last user login for this title - */ - LastLogin?: string; - /** - / timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other events, such as issuing a beta key to the user, can associate the title to the user) + * timestamp indicating when the user first signed into this game (this can differ from the Created timestamp, as other + * events, such as issuing a beta key to the user, can associate the title to the user) */ FirstLogin?: string; - /** - / boolean indicating whether or not the user is currently banned for a title - */ + /** boolean indicating whether or not the user is currently banned for a title */ isBanned?: boolean; - /** - / URL to the player's avatar. - */ - AvatarUrl?: string; + /** timestamp for the last user login for this title */ + LastLogin?: string; + /** source by which the user first joined the game, if known */ + Origination?: string; + /** Title player account entity for this user */ + TitlePlayerAccount?: EntityKey; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserTwitchInfo - */ export interface UserTwitchInfo { - /** - / Twitch ID - */ + /** Twitch ID */ TwitchId?: string; - /** - / Twitch Username - */ + /** Twitch Username */ TwitchUserName?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.UserXboxInfo - */ export interface UserXboxInfo { - /** - / XBox user ID - */ + /** XBox user ID */ XboxUserId?: string; + /** XBox user sandbox */ + XboxUserSandbox?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.ValueToDateModel - */ export interface ValueToDateModel { - /** - / ISO 4217 code of the currency used in the purchases - */ + /** ISO 4217 code of the currency used in the purchases */ Currency?: string; /** - / Total value of the purchases in a whole number of 1/100 monetary units. For example 999 indicates nine dollars and ninety-nine cents when Currency is 'USD') + * Total value of the purchases in a whole number of 1/100 monetary units. For example, 999 indicates nine dollars and + * ninety-nine cents when Currency is 'USD') */ TotalValue: number; /** - / Total value of the purchases in a string representation of decimal monetary units (e.g. '9.99' indicates nine dollars and ninety-nine cents when Currency is 'USD')) + * Total value of the purchases in a string representation of decimal monetary units. For example, '9.99' indicates nine + * dollars and ninety-nine cents when Currency is 'USD'. */ TotalValueAsDecimal?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.VirtualCurrencyBalanceModel - */ - export interface VirtualCurrencyBalanceModel { - /** - / Name of the virtual currency - */ - Currency?: string; - /** - / Balance of the virtual currency - */ - TotalValue: number; + export interface Variable { + /** Name of the variable. */ + Name: string; + /** Value of the variable. */ + Value?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.VirtualCurrencyRechargeTime - */ export interface VirtualCurrencyRechargeTime { /** - / Time remaining (in seconds) before the next recharge increment of the virtual currency. - */ - SecondsToRecharge: number; - /** - / Server timestamp in UTC indicating the next time the virtual currency will be incremented. - */ - RechargeTime: string; - /** - / Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen below this value. + * Maximum value to which the regenerating currency will automatically increment. Note that it can exceed this value + * through use of the AddUserVirtualCurrency API call. However, it will not regenerate automatically until it has fallen + * below this value. */ RechargeMax: number; + /** Server timestamp in UTC indicating the next time the virtual currency will be incremented. */ + RechargeTime: string; + /** Time remaining (in seconds) before the next recharge increment of the virtual currency. */ + SecondsToRecharge: number; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteEventResponse - */ export interface WriteEventResponse extends PlayFabModule.IPlayFabResultCommon { /** - / The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to any particular format. + * The unique identifier of the event. The values of this identifier consist of ASCII characters and are not constrained to + * any particular format. */ EventId?: string; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteServerCharacterEventRequest - */ export interface WriteServerCharacterEventRequest extends PlayFabModule.IPlayFabRequestCommon { - /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / Unique PlayFab assigned ID for a specific character owned by a user - */ + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** Unique PlayFab assigned ID for a specific character owned by a user */ CharacterId: string; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteServerPlayerEventRequest - */ export interface WriteServerPlayerEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / Unique PlayFab assigned ID of the user on whom the operation will be performed. - */ - PlayFabId: string; - /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** Unique PlayFab assigned ID of the user on whom the operation will be performed. */ + PlayFabId: string; + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom data properties associated with the event. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; } - /** - / https://api.playfab.com/Documentation/Client/datatype/PlayFab.Server.Models/PlayFab.Server.Models.WriteTitleEventRequest - */ export interface WriteTitleEventRequest extends PlayFabModule.IPlayFabRequestCommon { + /** Custom event properties. Each property consists of a name (string) and a value (JSON object). */ + Body?: { [key: string]: any }; + /** The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.). */ + CustomTags?: { [key: string]: string | null }; /** - / The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it commonly follows the subject_verb_object pattern (e.g. player_logged_in). + * The name of the event, within the namespace scoped to the title. The naming convention is up to the caller, but it + * commonly follows the subject_verb_object pattern (e.g. player_logged_in). */ EventName: string; - /** - / The time (in UTC) associated with this event. The value dafaults to the current time. - */ + /** The time (in UTC) associated with this event. The value defaults to the current time. */ Timestamp?: string; - /** - / Custom event properties. Each property consists of a name (string) and a value (JSON object). - */ - Body?: { [key: string]: any }; + + } + + export interface XboxLiveAccountPlayFabIdPair { + /** Unique PlayFab identifier for a user, or null if no PlayFab account is linked to the Xbox Live identifier. */ + PlayFabId?: string; + /** Unique Xbox Live identifier for a user. */ + XboxLiveAccountId?: string; } diff --git a/README.md b/README.md index 816efe01..76bd1f1b 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,18 @@ -JavaScriptSDK README -======== -1. Overview: ----- +# JavaScriptSDK README + + +## 1. Overview: JavaScriptSDK for the Client API of PlayFab -This SDK can alternatively be used via our CDN. Additional details can be found [here](https://playfab.com/playfab-now-serving-javascript-sdk-via-cdn/). +This SDK can alternatively be used via our CDN. Additional details can be found [here](https://blog.playfab.com/blog/playfab-now-serving-javascript-sdk-via-cdn). If you want to start coding right away, check out our [JavaScript Getting Started Guide](JavaScriptGettingStarted.md) -2. Prerequisites: ----- -* Users should be very familiar with the topics covered in our [getting started guide](https://playfab.com/docs/getting-started-with-playfab/). +## 2. Prerequisites: + +* Users should be very familiar with the topics covered in our [getting started guide](https://api.playfab.com/docs/general-getting-started). To connect to the PlayFab service, your machine must be running TLS v1.2 or better. * For Windows, this means Windows 7 and above @@ -20,8 +20,7 @@ To connect to the PlayFab service, your machine must be running TLS v1.2 or bett * [Support for SSL/TLS protocols on Windows](http://blogs.msdn.com/b/kaushal/archive/2011/10/02/support-for-ssl-tls-protocols-on-windows.aspx) -3. Example Project (UNDER CONSTRUCTION) ----- +## 3. Example Project (UNDER CONSTRUCTION) The Example project is being revised for the upcoming 1.0 release @@ -31,8 +30,8 @@ Please read about the testTitleData.json format, and purpose here: * [testTitleData.md](https://github.com/PlayFab/SDKGenerator/blob/master/JenkinsConsoleUtility/testTitleData.md) must be created and placed in the root of the example (beside index.html & PlayFabApiTest.ts), and must be named "testTitleData.json" -4. Troubleshooting: ----- +## 4. Troubleshooting: + For a complete list of available APIs, check out the [online documentation](http://api.playfab.com/Documentation/). #### Contact Us @@ -43,14 +42,22 @@ Our Developer Success Team can assist with answering any questions as well as pr [Forums, Support and Knowledge Base](https://community.playfab.com/index.html) +## 7. NPM support: +You may install JavaScript SDK with npm by running : + +`npm install playfab-web-sdk` + +Notice that it will install web JavaScript package as opposed to `npm install playfab-sdk` which will install NodeJS SDK. + +While npm is generally used for server side packages, you may use one of popular build tools to mix NPM installed packages into your clientside JS codebase. Consider Babel, Webpack, Gulp or Grunt for different approaches to building and automation. + +## 6. Acknowledgements -5. Acknowledgements ----- [dylanh724](https://www.github.com/dylanh724) - The previous tutorial before the current [Getting Started Guide](JavaScriptGettingStarted.md) -6. Copyright and Licensing Information: ----- +## 7. Copyright and Licensing Information: + Apache License -- Version 2.0, January 2004 http://www.apache.org/licenses/ diff --git a/TypeScriptGettingStarted.md b/TypeScriptGettingStarted.md index 6e636627..8d6ce77f 100644 --- a/TypeScriptGettingStarted.md +++ b/TypeScriptGettingStarted.md @@ -118,7 +118,7 @@ The HTML file has a few important lines: ``` -This line loads the Client-SDK from the local PlayFabSDK file. The latest version of this file is also available from [our CDN](https://download.playfab.com/PlayFabClientApi.js). For more information read our [CDN blog post](https://playfab.com/playfab-now-serving-javascript-sdk-via-cdn/). +This line loads the Client-SDK from the local PlayFabSDK file. The latest version of this file is also available from [our CDN](https://download.playfab.com/PlayFabClientApi.js). For more information read our [CDN blog post](https://blog.playfab.com/blog/playfab-now-serving-javascript-sdk-via-cdn/). The other important HTML lines: ```HTML diff --git a/genConfig.json b/genConfig.json new file mode 100644 index 00000000..ece638b4 --- /dev/null +++ b/genConfig.json @@ -0,0 +1,7 @@ +{ + "default": { + "buildFlags": "requiresoptionalvaluesupport", + "templateFolder": "javascript", + "versionKey": "javascript" + } +} \ No newline at end of file diff --git a/licenses/qunit-license.txt b/licenses/qunit-license.txt index 13cef369..d7fa09de 100644 --- a/licenses/qunit-license.txt +++ b/licenses/qunit-license.txt @@ -1,35 +1,9 @@ -Copyright jQuery Foundation and other contributors, https://jquery.org/ +Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com -This software consists of voluntary contributions made by many -individuals. For exact contribution history, see the revision history -available at https://github.com/jquery/qunit +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -The following license applies to all parts of this software except as -documented below: +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -==== +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -==== - -All files located in the node_modules directory are externally maintained -libraries used by this software which have their own licenses; we -recommend you read them, as their terms may differ from the terms above. \ No newline at end of file +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.