Documentation

CreateBuildWithCustomContainer

Creates a multiplayer server build with a custom container.

Request Details

Creates a multiplayer server build with a custom container and returns information about the build creation request.

CreateBuildWithCustomContainerRequest
Request Properties
BuildName (required) String

The build name.

ContainerFlavor ContainerFlavor

The flavor of container to create a build from.

ContainerImageReference ContainerImageReference

The container reference, consisting of the image name and tag.

ContainerRunCommand String

The container command to run when the multiplayer server has been allocated, including any arguments.

GameAssetReferences List<AssetReferenceParams>

The list of game assets related to the build.

GameCertificateReferences List<GameCertificateReferenceParams>

The game certificates for the build.

Metadata Dict<String, String>

Metadata to tag the build. The keys are case insensitive. The build metadata is made available to the server through Game Server SDK (GSDK).

MultiplayerServerCountPerVm (required) int32

The number of multiplayer servers to host on a single VM.

Ports (required) List<Port>

The ports to map the build on.

RegionConfigurations (required) List<BuildRegionParams>

The region configurations for the build.

VmSize AzureVmSize

The VM size to create the build on.

POST https://{{TitleID}}.playfabapi.com/MultiplayerServer/CreateBuildWithCustomContainer
    Content-Type: application/json
{
  "ContainerRunCommand": "/data/Assets -startserver",
  "GameAssetReferences": [
    {
      "FileName": "gameserver.zip",
      "MountPath": "/data/Assets"
    }
  ],
  "ContainerImageReference": {
    "ImageName": "ContainerImageName",
    "Tag": "ContainerTag"
  },
  "ContainerFlavor": "CustomLinux",
  "BuildName": "GameBuildName",
  "Metadata": {
    "MetadataKey": "MetadataValue"
  },
  "VmSize": "Standard_D2_v2",
  "MultiplayerServerCountPerVm": 10,
  "Ports": [
    {
      "Name": "PortName",
      "Num": 1243,
      "Protocol": "TCP"
    }
  ],
  "RegionConfigurations": [
    {
      "Region": "EastUs",
      "MaxServers": 10,
      "StandbyServers": 5
    },
    {
      "Region": "WestUs",
      "MaxServers": 12,
      "StandbyServers": 8
    },
    {
      "Region": "NorthEurope",
      "MaxServers": 7,
      "StandbyServers": 3
    }
  ],
  "GameCertificateReferences": [
    {
      "Name": "CertName",
      "GsdkAlias": "CertGsdkAlias"
    }
  ]
}
        

Response Details

CreateBuildWithCustomContainerResponse
Result Properties
BuildId String

The guid string build ID. Must be unique for every build.

BuildName String

The build name.

ContainerFlavor ContainerFlavor

The flavor of container of the build.

ContainerRunCommand String

The container command to run when the multiplayer server has been allocated, including any arguments.

CreationTime DateTime

The time the build was created in UTC.

CustomGameContainerImage ContainerImageReference

The custom game container image reference information.

GameAssetReferences List<AssetReference>

The game assets for the build.

GameCertificateReferences List<GameCertificateReference>

The game certificates for the build.

Metadata Dict<String, String>

The metadata of the build.

MultiplayerServerCountPerVm (required) int32

The number of multiplayer servers to host on a single VM of the build.

Ports List<Port>

The ports the build is mapped on.

RegionConfigurations List<BuildRegion>

The region configuration for the build.

VmSize AzureVmSize

The VM size the build was created on.

Sample Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
{
  "code": 200,
  "status": "OK",
  "data": {
    "ContainerRunCommand": "/data/Assets -startserver",
    "BuildId": "21781fa8-096d-4d9c-b699-75433d579285",
    "BuildName": "GameBuildName",
    "CreationTime": "2014-04-07T09:04:28Z",
    "Metadata": {
      "MetadataKey": "MetadataValue"
    },
    "VmSize": "Standard_D2_v2",
    "ContainerFlavor": "CustomLinux",
    "Ports": [
      {
        "Name": "PortName",
        "Num": 1243,
        "Protocol": "TCP"
      }
    ],
    "RegionConfigurations": [
      {
        "Region": "EastUs",
        "Status": "Initialized",
        "MaxServers": 10,
        "StandbyServers": 5
      },
      {
        "Region": "WestUs",
        "Status": "Deployed",
        "MaxServers": 12,
        "StandbyServers": 8
      },
      {
        "Region": "NorthEurope",
        "Status": "Unhealthy",
        "MaxServers": 7,
        "StandbyServers": 3
      }
    ],
    "GameAssetReferences": [
      {
        "FileName": "gameserver.zip",
        "MountPath": "/data/Assets"
      }
    ],
    "GameCertificateReferences": [
      {
        "Name": "CertName",
        "GsdkAlias": "CertGsdkAlias"
      }
    ],
    "MultiplayerServerCountPerVm": 10
  }
}

Authentication

EntityToken

Possible Error Codes

Name Code
MultiplayerServerBadRequest 1382
MultiplayerServerConflict 1386
MultiplayerServerForbidden 1384
MultiplayerServerInternalServerError 1387
MultiplayerServerUnauthorized 1383