Skip to main content

Begins the process for linking an identity with the Rivet Hub.

Importance of Linking Identities

When an identity is created via rivet.api.identity#SetupIdentity, the identity is temporary and is not shared with other games the user plays.

In order to make the identity permanent and synchronize the identity with other games, the identity must be linked with the hub.

Linking Process

The linking process works by opening identity_link_url in a browser then polling rivet.api.identity#GetGameLink to wait for it to complete.

This is designed to be as flexible as possible so identity_link_url can be opened on any device. For example, when playing a console game, the user can scan a QR code for identity_link_url to authenticate on their phone.

Responses

PrepareGameLink 200 response

Schema
  • identity_link_token string required

    Pass this to rivet.api.identity#GetGameLink to get the linking status.

    Valid for 15 minutes.

  • identity_link_url string required

    The URL that the user should visit to link their Rivet account.

  • expire_ts date-time required

    Timestamp (in milliseconds) at which the link will expire.