FAForever Lobby Server API 1.0.0

WebSocket-based bidirectional messaging protocol for the FAForever lobby server. All messages are JSON objects separated by newlines, with a command field identifying the message type.

This spec covers:

  • Lobby messages between the client and the lobby server
  • Game messages between the game client and the server (wrapped in lobby messages with target: "game")

Servers

  • wss://ws.faforever.com/wssproduction
  • wss://ws.faforever.xyz/wsstest
  • ws://localhost/wslocal

Operations

  • RECEIVE

    Server receives authentication request with OAuth token

    Operation IDserverAuthenticate

    Available only on servers:

    • #auth

    Accepts the following message:

    Authenticate with OAuth token
    Message IDAuthenticateRequest
    object

    Examples

  • RECEIVE

    Server receives request for a session ID

    Operation IDserverRequestSession

    Available only on servers:

    • #auth

    Accepts the following message:

    Request a session ID
    Message IDSessionRequest
    object

    Examples

  • RECEIVE

    Server receives request to host a game

    Operation IDserverHostGame

    Available only on servers:

    • #game

    Accepts the following message:

    Request to host a game
    Message IDHostGameRequest
    object

    Examples

  • RECEIVE

    Server receives request to join a game

    Operation IDserverJoinGame

    Available only on servers:

    • #game

    Accepts the following message:

    Request to join a game
    Message IDJoinGameRequest
    object

    Examples

  • RECEIVE

    Server receives request to restore a game session

    Operation IDserverRestoreGameSession

    Available only on servers:

    • #game

    Accepts the following message:

    Request to restore a game session
    Message IDRestoreGameSessionRequest

    Reconnect to an existing game that is still in lobby or live state

    object

    Examples

  • RECEIVE

    Server receives request to join or leave a matchmaking queue

    Operation IDserverSetMatchmakingStatus

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Request to join or leave a matchmaking queue
    Message IDGameMatchmakingRequest
    object

    Examples

  • RECEIVE

    Server receives response to match readiness check

    Operation IDserverGetIsReady

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Response to match readiness check
    Message IDIsReadyResponse
    object

    Examples

  • RECEIVE

    Server receives request for latest matchmaker queue info

    Operation IDserverGetMatchmakerInfo

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Request matchmaker queue information
    Message IDMatchmakerInfoRequest
    object

    Examples

  • RECEIVE

    Server receives request to set map vetoes

    Operation IDserverSetPlayerVetoes

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Request to set map vetoes for matchmaking
    Message IDSetPlayerVetoesRequest
    object

    Examples

  • RECEIVE

    Server receives request to add a friend or foe

    Operation IDserverAddSocial

    Available only on servers:

    • #social

    Accepts the following message:

    Request to add a friend or foe
    Message IDSocialAddRequest

    Exactly one of friend or foe must be provided.

    object

    Examples

  • RECEIVE

    Server receives request to remove a friend or foe

    Operation IDserverRemoveSocial

    Available only on servers:

    • #social

    Accepts the following message:

    Request to remove a friend or foe
    Message IDSocialRemoveRequest

    Exactly one of friend or foe must be provided.

    object

    Examples

  • RECEIVE

    Server receives avatar list or select request

    Operation IDserverAvatarRequest

    Available only on servers:

    • #social

    Accepts the following message:

    Request to list or select an avatar
    Message IDAvatarRequest
    object

    Examples

  • RECEIVE

    Server receives admin action (requires appropriate permissions)

    Operation IDserverAdminAction

    Available only on servers:

    • #admin

    Accepts the following message:

    Admin commands
    Message IDAdminRequest

    Requires appropriate server permissions (ADMIN_KICK_SERVER, ADMIN_BROADCAST_MESSAGE, ADMIN_JOIN_CHANNEL)

    object

    Examples

  • RECEIVE

    Server receives request to invite a player to a party

    Operation IDserverInviteToParty

    Available only on servers:

    • #party

    Accepts the following message:

    Invite a player to your party
    Message IDInviteToPartyRequest
    object

    Examples

  • RECEIVE

    Server receives request to accept a party invite

    Operation IDserverAcceptInviteToParty

    Available only on servers:

    • #party

    Accepts the following message:

    Accept a party invitation
    Message IDAcceptInviteToPartyRequest
    object

    Examples

  • RECEIVE

    Server receives request to kick a player from a party

    Operation IDserverKickPlayerFromParty

    Available only on servers:

    • #party

    Accepts the following message:

    Kick a player from your party
    Message IDKickPlayerFromPartyRequest
    object

    Examples

  • RECEIVE

    Server receives request to leave a party

    Operation IDserverLeaveParty

    Available only on servers:

    • #party

    Accepts the following message:

    Leave your current party
    Message IDLeavePartyRequest
    object

    Examples

  • RECEIVE

    Server receives request to unready a party

    Operation IDserverUnreadyParty

    Available only on servers:

    • #party

    Accepts the following message:

    Unready your party
    Message IDUnreadyPartyRequest
    object

    Examples

  • RECEIVE

    Server receives request to set party faction preferences

    Operation IDserverSelectPartyFactions

    Available only on servers:

    • #party

    Accepts the following message:

    Set faction preferences for matchmaking
    Message IDSelectPartyFactionsRequest
    object

    Examples

  • RECEIVE

    Server receives request for cooperative mission list

    Operation IDserverCoopList

    Available only on servers:

    • #coop

    Accepts the following message:

    Request cooperative mission list
    Message IDCoopListRequest

    Server responds with one coop_info message per mission

    object

    Examples

  • RECEIVE

    Server receives mod vault request (DEPRECATED - use FAF API instead)

    Operation IDserverModVault

    Available only on servers:

    • #vault

    Accepts the following message:

    Mod vault operations (DEPRECATED)
    Message IDModVaultRequest

    DEPRECATED: Use the FAF API instead

    object

    Examples

  • RECEIVE

    Server receives ICE servers request (DEPRECATED - handled outside lobby server)

    Operation IDserverIceServers

    Available only on servers:

    • #deprecated

    Accepts the following message:

    Request ICE servers (DEPRECATED)
    Message IDIceServersRequest

    DEPRECATED: ICE servers are handled outside of the lobby server. Response will always be an empty list.

    object

    Examples

  • RECEIVE

    Ping received from client

    Operation IDserverPing

    Available only on servers:

    • #heartbeat

    Accepts the following message:

    Ping
    Message IDPingMessage
    object

    Examples

  • RECEIVE

    Pong received from client

    Operation IDserverPong

    Available only on servers:

    • #heartbeat

    Accepts the following message:

    Pong
    Message IDPongMessage
    object

    Examples

  • SEND

    Server sends welcome message after successful authentication

    Operation IDclientWelcome

    Available only on servers:

    • #auth

    Accepts the following message:

    Welcome message after successful login
    Message IDWelcomeMessage

    Sent immediately after successful authentication. Contains the player's own info.

    object

    Examples

  • SEND

    Server sends session ID in response to ask_session

    Operation IDclientSession

    Available only on servers:

    • #auth

    Accepts the following message:

    Session ID response
    Message IDSessionMessage
    object

    Examples

  • SEND

    Server sends authentication failure message

    Operation IDclientAuthenticationFailed

    Available only on servers:

    • #auth

    Accepts the following message:

    Authentication failure
    Message IDAuthenticationFailedMessage
    object

    Examples

  • SEND

    Server sends player information (on login and broadcast updates)

    Operation IDclientPlayerInfo

    Available only on servers:

    • #player

    Accepts the following message:

    Player information update
    Message IDPlayerInfoMessage

    Sent after login with all online players, and periodically broadcast when player data changes (ratings, avatar, state, etc.)

    object

    Examples

  • SEND

    Server sends game information (on login and broadcast updates)

    Operation IDclientGameInfo

    Available only on servers:

    • #game

    Accepts the following message:

    Game information update
    Message IDGameInfoMessage

    Sent after login with all visible open games, and periodically broadcast when game data changes (players join/leave, state changes, etc.)

    object

    Examples

  • SEND

    Server sends friend/foe list and channel info after login

    Operation IDclientSocial

    Available only on servers:

    • #social

    Accepts the following message:

    Social data (friends, foes, channels)
    Message IDSocialMessage

    Sent after login with friend/foe lists and auto-join channels

    object

    Examples

  • SEND

    Server tells client to launch the game

    Operation IDclientGameLaunch

    Available only on servers:

    • #game

    Accepts the following message:

    Launch game
    Message IDGameLaunchMessage

    Tells the client to launch the game executable. Sent when hosting, joining, or starting a matchmaker game.

    object

    Examples

  • SEND

    Server notifies client that joining a game failed

    Operation IDclientGameJoinFailed

    Available only on servers:

    • #game

    Accepts the following message:

    Game join failed
    Message IDGameJoinFailedMessage
    object

    Examples

  • SEND

    Server sends matchmaker queue information

    Operation IDclientMatchmakerInfo

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Matchmaker queue information
    Message IDMatchmakerInfoMessage

    Sent in response to matchmaker_info request and periodically broadcast

    object

    Examples

  • SEND

    Server sends matchmaking search status update

    Operation IDclientSearchInfo

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Matchmaking search status
    Message IDSearchInfoMessage
    object

    Examples

  • SEND

    Server sends matchmaking timeout information for violated players

    Operation IDclientSearchTimeout

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Matchmaking search timeout
    Message IDSearchTimeoutMessage

    Sent when players have violations that prevent them from searching

    object

    Examples

  • SEND

    Server sends violation info when a player fails to connect to a match

    Operation IDclientSearchViolation

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Matchmaking violation recorded
    Message IDSearchViolationMessage

    Sent when a player fails to connect to a matchmaker game

    object

    Examples

  • SEND

    Server notifies client that a match has been found

    Operation IDclientMatchFound

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Match found
    Message IDMatchFoundMessage

    Sent to all players in a match when the matchmaker finds a game

    object

    Examples

  • SEND

    Server notifies client that a match was cancelled (e.g. player failed to connect)

    Operation IDclientMatchCancelled

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Match cancelled
    Message IDMatchCancelledMessage

    Sent when a matchmaker game fails to start (e.g. player didn't connect in time)

    object

    Examples

  • SEND

    Server sends party state update to all party members

    Operation IDclientUpdateParty

    Available only on servers:

    • #party

    Accepts the following message:

    Party state update
    Message IDUpdatePartyMessage

    Broadcast to all party members when party state changes

    object

    Examples

  • SEND

    Server sends party invitation to a player

    Operation IDclientPartyInvite

    Available only on servers:

    • #party

    Accepts the following message:

    Party invitation received
    Message IDPartyInviteMessage
    object

    Examples

  • SEND

    Server notifies player they were kicked from a party

    Operation IDclientKickedFromParty

    Available only on servers:

    • #party

    Accepts the following message:

    Kicked from party
    Message IDKickedFromPartyMessage
    object

    Examples

  • SEND

    Server sends current map veto information

    Operation IDclientVetoesInfo

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Map veto information
    Message IDVetoesInfoMessage

    Sent when veto state changes or is requested

    object

    Examples

  • SEND

    Server sends cooperative mission information

    Operation IDclientCoopInfo

    Available only on servers:

    • #coop

    Accepts the following message:

    Co-op mission information
    Message IDCoopInfoMessage

    One message per co-op mission, sent in response to coop_list request

    object

    Examples

  • SEND

    Server sends list of available avatars for the player

    Operation IDclientAvatarList

    Available only on servers:

    • #social

    Accepts the following message:

    Avatar list response
    Message IDAvatarListMessage

    Sent in response to avatar list_avatar request

    object

    Examples

  • SEND

    Server sends mod vault information (DEPRECATED - use FAF API)

    Operation IDclientModVaultInfo

    Available only on servers:

    • #vault

    Accepts the following message:

    Mod vault information (DEPRECATED)
    Message IDModVaultInfoMessage

    DEPRECATED: Use the FAF API instead

    object

    Examples

  • SEND

    Server sends updated achievement data

    Operation IDclientUpdatedAchievements

    Available only on servers:

    • #player

    Accepts the following message:

    Achievement update
    Message IDUpdatedAchievementsMessage
    object

    Examples

  • SEND

    Server sends IRC password (DEPRECATED - data is meaningless)

    Operation IDclientIrcPassword

    Available only on servers:

    • #deprecated

    Accepts the following message:

    IRC password (DEPRECATED)
    Message IDIrcPasswordMessage

    DEPRECATED: IRC passwords are handled outside of the lobby server. The password field is meaningless.

    object

    Examples

  • SEND

    Server sends ICE server list (DEPRECATED - always empty)

    Operation IDclientIceServers

    Available only on servers:

    • #deprecated

    Accepts the following message:

    ICE servers response (DEPRECATED)
    Message IDIceServersMessage

    DEPRECATED: ICE servers are handled outside of the lobby server. The list is always empty.

    object

    Examples

  • SEND

    Server sends a notification or error message

    Operation IDclientNotice

    Available only on servers:

    • #notification

    Accepts the following message:

    Notification or error message
    Message IDNoticeMessage

    Generic notification message. The style field indicates severity:

    • "info": informational message
    • "error": error that may cause disconnection
    • "kick": player is being kicked
    • "kill": game process should be terminated
    object

    Examples

  • SEND

    Server sends invalid command response

    Operation IDclientInvalid

    Available only on servers:

    • #notification

    Accepts the following message:

    Invalid command
    Message IDInvalidMessage

    Sent when the server encounters an unhandled exception processing a command

    object

    Examples

  • SEND

    Server notifies that a command is currently disabled

    Operation IDclientDisabled

    Available only on servers:

    • #notification

    Accepts the following message:

    Command is disabled
    Message IDDisabledMessage

    Sent when a client sends a command that is currently disabled on the server

    object

    Examples

  • SEND

    Server sends periodic ping to keep connection alive

    Operation IDclientPing

    Available only on servers:

    • #heartbeat

    Accepts the following message:

    Ping
    Message IDPingMessage
    object

    Examples

  • SEND

    Server responds to client ping

    Operation IDclientPong

    Available only on servers:

    • #heartbeat

    Accepts the following message:

    Pong
    Message IDPongMessage
    object

    Examples

  • SEND

    Server asks client if ready for a tournament or galactic war game

    Operation IDclientIsReady

    Available only on servers:

    • #matchmaker

    Accepts the following message:

    Readiness check
    Message IDIsReadyMessage

    Server asks the client if it is ready for a tournament or galactic war game. Client should respond with is_ready_response. NOTE: Not currently sent by the server (reserved for future use).

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a state change (Idle, Lobby, Launching, Ended)

    Operation IDgameStateReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Game state change
    Message IDGameStateCommand

    Sent by the game when the state of LobbyComm changes

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game host sets a game option

    Operation IDgameOptionReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Set game option
    Message IDGameOptionCommand

    Sent by the host to set a game option

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game host reports active game mods

    Operation IDgameModsReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Set active game mods
    Message IDGameModsCommand

    Sent by the host to report active mods

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game host sets a player option

    Operation IDplayerOptionReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Set player option
    Message IDPlayerOptionCommand

    Sent by the host to set a player option (e.g. Team, Faction, StartSpot)

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game host sets an AI option

    Operation IDaiOptionReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Set AI option
    Message IDAIOptionCommand

    Sent by the host to set an AI player option

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game host clears a game slot

    Operation IDclearSlotReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Clear game slot
    Message IDClearSlotCommand

    Sent by the host to clear a game slot

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a result for an army

    Operation IDgameResultReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Report game result
    Message IDGameResultCommand

    Reports the result for an army. The result string format is: "[metadata...] result_type score" (space-separated). Result types include: victory, defeat, draw, mutual_draw, etc.

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports co-op mission completion

    Operation IDoperationCompleteReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Co-op mission completion
    Message IDOperationCompleteCommand

    Sent when a co-op mission is completed

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports army statistics in JSON format

    Operation IDjsonStatsReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Game statistics
    Message IDJsonStatsCommand

    Game army statistics in JSON format

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports that rating should be enforced

    Operation IDenforceRatingReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Enforce rating
    Message IDEnforceRatingCommand

    Signals that the game's rating should be enforced

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Player manually reports a teamkill

    Operation IDteamkillReportReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Manual teamkill report
    Message IDTeamkillReportCommand

    Sent when a player clicks the "Report" button after being teamkilled

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game automatically reports a teamkill event

    Operation IDteamkillHappenedReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Automatic teamkill notification
    Message IDTeamkillHappenedCommand

    Sent automatically by the game when a teamkill occurs

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game sends an ICE negotiation message to forward to a peer

    Operation IDgameIceMsgReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    ICE message (game to server)
    Message IDGameIceMsgCommand

    ICE negotiation message to be forwarded to a peer via the server

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a desynchronization event

    Operation IDdesyncReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Desynchronization
    Message IDDesyncCommand

    Sent when a desynchronization is detected in the game

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports launch status (e.g. Rejected for mismatched settings)

    Operation IDlaunchStatusReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Launch status
    Message IDLaunchStatusCommand

    Reports launch status. "Rejected" indicates a matchmaker game failed due to differing settings.

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a data bottleneck (player falling behind)

    Operation IDbottleneckReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Data bottleneck
    Message IDBottleneckCommand

    Sent when a player is getting behind on data, slowing down the game

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports that a bottleneck has been resolved

    Operation IDbottleneckClearedReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Bottleneck cleared
    Message IDBottleneckClearedCommand

    Sent when the game is no longer being slowed down by a data bottleneck

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a player disconnection

    Operation IDdisconnectedReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Player disconnected
    Message IDDisconnectedCommand

    Sent when a player disconnects from the game

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports a chat message from the game lobby

    Operation IDchatReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    In-game chat message
    Message IDChatCommand

    Sent when a player sends a chat message in the game lobby

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports that all game slots are full

    Operation IDgameFullReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Game is full
    Message IDGameFullCommand

    Sent when all game slots are occupied

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports that the simulation has ended

    Operation IDgameEndedReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Simulation ended
    Message IDGameEndedCommand

    Signals that the game simulation has ended

    object

    Examples

  • RECEIVE

    These messages are wrapped inside the lobby WebSocket connection with "target": "game". The game command is in the command field and arguments in the args array.

    Game reports that the user has rehosted the game

    Operation IDrehostReceive

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Game rehosted
    Message IDRehostCommand

    Signals that the user has rehosted the game

    object

    Examples

  • SEND

    These messages are sent to the game client with "target": "game". The game command is in the command field and arguments in the args array.

    Server tells game to start hosting and listening for connections

    Operation IDgameHostGameSend

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Host a game
    Message IDHostGameCommand

    Tells the game to start listening for incoming connections as a host

    object

    Examples

  • SEND

    These messages are sent to the game client with "target": "game". The game command is in the command field and arguments in the args array.

    Server tells game to join the host

    Operation IDgameJoinGameSend

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Join a game
    Message IDJoinGameCommand

    Tells the game to connect to the host

    object

    Examples

  • SEND

    These messages are sent to the game client with "target": "game". The game command is in the command field and arguments in the args array.

    Server tells game to connect to a peer for syncing

    Operation IDgameConnectToPeerSend

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Connect to a peer
    Message IDConnectToPeerCommand

    Tells the game to establish a connection with another player for syncing

    object

    Examples

  • SEND

    These messages are sent to the game client with "target": "game". The game command is in the command field and arguments in the args array.

    Server tells game to disconnect from a peer

    Operation IDgameDisconnectFromPeerSend

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    Disconnect from a peer
    Message IDDisconnectFromPeerCommand

    Tells the game to disconnect from a specific peer

    object

    Examples

  • SEND

    These messages are sent to the game client with "target": "game". The game command is in the command field and arguments in the args array.

    Server forwards an ICE negotiation message from another peer

    Operation IDgameIceMsgSend

    Available only on servers:

    • #gpgnet

    Accepts the following message:

    ICE message (server to game)
    Message IDServerIceMsgCommand

    Forwards an ICE negotiation message from another peer

    object

    Examples

Messages

  • #1Authenticate with OAuth token
    Message IDAuthenticateRequest
    object
  • #2Request a session ID
    Message IDSessionRequest
    object
  • #3Request to host a game
    Message IDHostGameRequest
    object
  • #4Request to join a game
    Message IDJoinGameRequest
    object
  • #5Request to restore a game session
    Message IDRestoreGameSessionRequest

    Reconnect to an existing game that is still in lobby or live state

    object
  • #6Request to join or leave a matchmaking queue
    Message IDGameMatchmakingRequest
    object
  • #7Response to match readiness check
    Message IDIsReadyResponse
    object
  • #8Request matchmaker queue information
    Message IDMatchmakerInfoRequest
    object
  • #9Request to set map vetoes for matchmaking
    Message IDSetPlayerVetoesRequest
    object
  • #10Request to add a friend or foe
    Message IDSocialAddRequest

    Exactly one of friend or foe must be provided.

    object
  • #11Request to remove a friend or foe
    Message IDSocialRemoveRequest

    Exactly one of friend or foe must be provided.

    object
  • #12Request to list or select an avatar
    Message IDAvatarRequest
    object
  • #13Admin commands
    Message IDAdminRequest

    Requires appropriate server permissions (ADMIN_KICK_SERVER, ADMIN_BROADCAST_MESSAGE, ADMIN_JOIN_CHANNEL)

    object
  • #14Invite a player to your party
    Message IDInviteToPartyRequest
    object
  • #15Accept a party invitation
    Message IDAcceptInviteToPartyRequest
    object
  • #16Kick a player from your party
    Message IDKickPlayerFromPartyRequest
    object
  • #17Leave your current party
    Message IDLeavePartyRequest
    object
  • #18Unready your party
    Message IDUnreadyPartyRequest
    object
  • #19Set faction preferences for matchmaking
    Message IDSelectPartyFactionsRequest
    object
  • #20Request cooperative mission list
    Message IDCoopListRequest

    Server responds with one coop_info message per mission

    object
  • #21Mod vault operations (DEPRECATED)
    Message IDModVaultRequest

    DEPRECATED: Use the FAF API instead

    object
  • #22Request ICE servers (DEPRECATED)
    Message IDIceServersRequest

    DEPRECATED: ICE servers are handled outside of the lobby server. Response will always be an empty list.

    object
  • #23Ping
    Message IDPingMessage
    object
  • #24Pong
    Message IDPongMessage
    object
  • #25Welcome message after successful login
    Message IDWelcomeMessage

    Sent immediately after successful authentication. Contains the player's own info.

    object
  • #26Session ID response
    Message IDSessionMessage
    object
  • #27Authentication failure
    Message IDAuthenticationFailedMessage
    object
  • #28Player information update
    Message IDPlayerInfoMessage

    Sent after login with all online players, and periodically broadcast when player data changes (ratings, avatar, state, etc.)

    object
  • #29Game information update
    Message IDGameInfoMessage

    Sent after login with all visible open games, and periodically broadcast when game data changes (players join/leave, state changes, etc.)

    object
  • #30Social data (friends, foes, channels)
    Message IDSocialMessage

    Sent after login with friend/foe lists and auto-join channels

    object
  • #31Launch game
    Message IDGameLaunchMessage

    Tells the client to launch the game executable. Sent when hosting, joining, or starting a matchmaker game.

    object
  • #32Game join failed
    Message IDGameJoinFailedMessage
    object
  • #33Matchmaker queue information
    Message IDMatchmakerInfoMessage

    Sent in response to matchmaker_info request and periodically broadcast

    object
  • #34Matchmaking search status
    Message IDSearchInfoMessage
    object
  • #35Matchmaking search timeout
    Message IDSearchTimeoutMessage

    Sent when players have violations that prevent them from searching

    object
  • #36Matchmaking violation recorded
    Message IDSearchViolationMessage

    Sent when a player fails to connect to a matchmaker game

    object
  • #37Match found
    Message IDMatchFoundMessage

    Sent to all players in a match when the matchmaker finds a game

    object
  • #38Match cancelled
    Message IDMatchCancelledMessage

    Sent when a matchmaker game fails to start (e.g. player didn't connect in time)

    object
  • #39Party state update
    Message IDUpdatePartyMessage

    Broadcast to all party members when party state changes

    object
  • #40Party invitation received
    Message IDPartyInviteMessage
    object
  • #41Kicked from party
    Message IDKickedFromPartyMessage
    object
  • #42Map veto information
    Message IDVetoesInfoMessage

    Sent when veto state changes or is requested

    object
  • #43Co-op mission information
    Message IDCoopInfoMessage

    One message per co-op mission, sent in response to coop_list request

    object
  • #44Avatar list response
    Message IDAvatarListMessage

    Sent in response to avatar list_avatar request

    object
  • #45Mod vault information (DEPRECATED)
    Message IDModVaultInfoMessage

    DEPRECATED: Use the FAF API instead

    object
  • #46Achievement update
    Message IDUpdatedAchievementsMessage
    object
  • #47IRC password (DEPRECATED)
    Message IDIrcPasswordMessage

    DEPRECATED: IRC passwords are handled outside of the lobby server. The password field is meaningless.

    object
  • #48ICE servers response (DEPRECATED)
    Message IDIceServersMessage

    DEPRECATED: ICE servers are handled outside of the lobby server. The list is always empty.

    object
  • #49Notification or error message
    Message IDNoticeMessage

    Generic notification message. The style field indicates severity:

    • "info": informational message
    • "error": error that may cause disconnection
    • "kick": player is being kicked
    • "kill": game process should be terminated
    object
  • #50Invalid command
    Message IDInvalidMessage

    Sent when the server encounters an unhandled exception processing a command

    object
  • #51Command is disabled
    Message IDDisabledMessage

    Sent when a client sends a command that is currently disabled on the server

    object
  • #52Readiness check
    Message IDIsReadyMessage

    Server asks the client if it is ready for a tournament or galactic war game. Client should respond with is_ready_response. NOTE: Not currently sent by the server (reserved for future use).

    object
  • #53Game state change
    Message IDGameStateCommand

    Sent by the game when the state of LobbyComm changes

    object
  • #54Set game option
    Message IDGameOptionCommand

    Sent by the host to set a game option

    object
  • #55Set active game mods
    Message IDGameModsCommand

    Sent by the host to report active mods

    object
  • #56Set player option
    Message IDPlayerOptionCommand

    Sent by the host to set a player option (e.g. Team, Faction, StartSpot)

    object
  • #57Set AI option
    Message IDAIOptionCommand

    Sent by the host to set an AI player option

    object
  • #58Clear game slot
    Message IDClearSlotCommand

    Sent by the host to clear a game slot

    object
  • #59Report game result
    Message IDGameResultCommand

    Reports the result for an army. The result string format is: "[metadata...] result_type score" (space-separated). Result types include: victory, defeat, draw, mutual_draw, etc.

    object
  • #60Co-op mission completion
    Message IDOperationCompleteCommand

    Sent when a co-op mission is completed

    object
  • #61Game statistics
    Message IDJsonStatsCommand

    Game army statistics in JSON format

    object
  • #62Enforce rating
    Message IDEnforceRatingCommand

    Signals that the game's rating should be enforced

    object
  • #63Manual teamkill report
    Message IDTeamkillReportCommand

    Sent when a player clicks the "Report" button after being teamkilled

    object
  • #64Automatic teamkill notification
    Message IDTeamkillHappenedCommand

    Sent automatically by the game when a teamkill occurs

    object
  • #65ICE message (game to server)
    Message IDGameIceMsgCommand

    ICE negotiation message to be forwarded to a peer via the server

    object
  • #66Desynchronization
    Message IDDesyncCommand

    Sent when a desynchronization is detected in the game

    object
  • #67Launch status
    Message IDLaunchStatusCommand

    Reports launch status. "Rejected" indicates a matchmaker game failed due to differing settings.

    object
  • #68Data bottleneck
    Message IDBottleneckCommand

    Sent when a player is getting behind on data, slowing down the game

    object
  • #69Bottleneck cleared
    Message IDBottleneckClearedCommand

    Sent when the game is no longer being slowed down by a data bottleneck

    object
  • #70Player disconnected
    Message IDDisconnectedCommand

    Sent when a player disconnects from the game

    object
  • #71In-game chat message
    Message IDChatCommand

    Sent when a player sends a chat message in the game lobby

    object
  • #72Game is full
    Message IDGameFullCommand

    Sent when all game slots are occupied

    object
  • #73Simulation ended
    Message IDGameEndedCommand

    Signals that the game simulation has ended

    object
  • #74Game rehosted
    Message IDRehostCommand

    Signals that the user has rehosted the game

    object
  • #75Host a game
    Message IDHostGameCommand

    Tells the game to start listening for incoming connections as a host

    object
  • #76Join a game
    Message IDJoinGameCommand

    Tells the game to connect to the host

    object
  • #77Connect to a peer
    Message IDConnectToPeerCommand

    Tells the game to establish a connection with another player for syncing

    object
  • #78Disconnect from a peer
    Message IDDisconnectFromPeerCommand

    Tells the game to disconnect from a specific peer

    object
  • #79ICE message (server to game)
    Message IDServerIceMsgCommand

    Forwards an ICE negotiation message from another peer

    object

Schemas

  • object

    Player information object

  • object

    Game information object

  • object

    Matchmaker queue information