> ## Documentation Index
> Fetch the complete documentation index at: https://docs.summerengine.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Replace player preferences

> Replace both preferences using the version returned by GET.



## OpenAPI

````yaml scripts/reference/sources/openapi/player.json PUT /v1/identity/me/preferences
openapi: 3.1.0
info:
  title: Summer Player Game Platform API
  version: summer.player.games/v1
  description: >-
    Public Summer Games store reads, the connected-app OAuth endpoints, and the
    signed-in player's profile and preferences.
servers:
  - url: https://api.summer.games
security:
  - playerBearer: []
paths:
  /v1/identity/me/preferences:
    put:
      description: >-
        Replace both preferences using the version returned by GET. On conflict
        or uncertain delivery reload before reconciling. Values never authorize
        pricing, age eligibility or service routing. Responses are no-store.
      operationId: replacePlayerPreferences
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              additionalProperties: false
              required:
                - language
                - contentRegion
                - expectedVersion
              properties:
                language:
                  $ref: '#/components/schemas/PreferredLanguageInput'
                contentRegion:
                  type: string
                  description: >-
                    Case-insensitive africa, americas, asia, europe or oceania;
                    empty resets to the product default.
                  maxLength: 8
                expectedVersion:
                  type: integer
                  minimum: 0
                  maximum: 9007199254740990
      responses:
        '200':
          description: Saved preferences with incremented version
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PlayerPreferences'
        '400':
          description: Invalid fields or unsupported values
        '401':
          description: Authentication missing or account inactive
        '403':
          description: Player identity.read permission required
        '409':
          description: version_conflict; GET authoritative state before reconciling
        '503':
          description: Preferences unavailable; reconcile uncertain writes with GET
components:
  schemas:
    PreferredLanguageInput:
      type: string
      maxLength: 21
      description: >-
        Empty means device fallback. Accepted bounded language tags are
        lowercased; whitespace is rejected.
      pattern: ^([a-zA-Z]{2,3}(-[a-zA-Z0-9]{2,8}){0,2})?$
    PlayerPreferences:
      type: object
      additionalProperties: false
      required:
        - language
        - contentRegion
        - version
      properties:
        language:
          type: string
          maxLength: 21
          pattern: ^([a-z]{2,3}(-[a-z0-9]{2,8}){0,2})?$
        contentRegion:
          type: string
          enum:
            - ''
            - africa
            - americas
            - asia
            - europe
            - oceania
        version:
          type: integer
          minimum: 0
          maximum: 9007199254740991
  securitySchemes:
    playerBearer:
      type: http
      scheme: bearer
      description: >-
        A player access token. Store reads need no token. Other apps get a token
        through connected-app OAuth: register the client, let the player approve
        it on summer.games, then exchange the code at the token endpoint.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.