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

# Set a conversation person's locale

> Set (or clear) a person's stored ``locale`` — the operator override the rendering layer
resolves text against, winning over the channel-seeded value on every later turn. ``locale``
is a BCP 47 tag (canonicalized here — ``he-il`` stores as ``he-IL``); ``null`` clears it back
to no-locale-known. A blank ``person_id`` or a malformed ``locale`` is a 400; an unknown
person a 404; no backend a loud 501. Returns the updated person.



## OpenAPI

````yaml /openapi.json put /api/conversations/persons/{person_id}/locale
openapi: 3.1.0
info:
  description: The operator HTTP surface served under /api/*.
  title: tai42-skeleton API
  version: 14.0.2
servers: []
security: []
paths:
  /api/conversations/persons/{person_id}/locale:
    put:
      tags:
        - conversations
      summary: Set a conversation person's locale
      description: >-
        Set (or clear) a person's stored ``locale`` — the operator override the
        rendering layer

        resolves text against, winning over the channel-seeded value on every
        later turn. ``locale``

        is a BCP 47 tag (canonicalized here — ``he-il`` stores as ``he-IL``);
        ``null`` clears it back

        to no-locale-known. A blank ``person_id`` or a malformed ``locale`` is a
        400; an unknown

        person a 404; no backend a loud 501. Returns the updated person.
      operationId: put_api_conversations_persons_person_id_locale
      parameters:
        - in: path
          name: person_id
          required: true
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  data:
                    $ref: '#/components/schemas/Person'
                required:
                  - data
                type: object
          description: Success.
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Malformed request.
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Missing or invalid api key.
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Resource not found.
        '501':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Error.
      security:
        - ApiKeyAuth: []
components:
  schemas:
    Person:
      description: >-
        A single identity on one target: the one-or-more :class:`PersonAddress`
        rows the

        platform treats as the same person for a ``(target_kind, target_name)``
        pair.


        A provisional person carries exactly ONE address — its first contact.
        Explicit pair-code

        redemption merges two persons into one (the union of their addresses);
        persons never

        cross targets. There is NO greeted flag: the row's existence is itself
        the first-contact

        marker, so a caller learns a first contact from whether it created the
        row. Runtime state

        that lives only in the deployment's Redis — deliberately NOT a backup
        section, the same

        family as a conversation record. Frozen.
      properties:
        addresses:
          items:
            $ref: '#/components/schemas/PersonAddress'
          minItems: 1
          title: Addresses
          type: array
        created_at:
          format: date-time
          title: Created At
          type: string
        locale:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Locale
        person_id:
          minLength: 1
          title: Person Id
          type: string
        target_kind:
          enum:
            - agent
            - tool
          title: Target Kind
          type: string
        target_name:
          minLength: 1
          title: Target Name
          type: string
      required:
        - person_id
        - target_kind
        - target_name
        - created_at
        - addresses
      title: Person
      type: object
    Error:
      properties:
        code:
          description: >-
            Stable machine-readable reason a client keys a dedicated error state
            on, present on refusals that opt in (e.g. a 501 not-configured
            refusal). Optional: absent when the error carries only a
            human-readable message.
          type: string
        error:
          type: string
      required:
        - error
      type: object
    PersonAddress:
      description: >-
        One reachable endpoint of a :class:`Person` on a single target — one
        channel address

        (or api caller address) the platform folds into that person's identity.


        A ``channel``-door address carries the registry ``channel`` name plus
        the

        ``our_identity`` the medium is texted at; an ``api``-door address
        carries ``None`` for

        both — the api caller address is the composed ``caller/end-user``
        string, which has no

        channel identity. ``routes`` is EVERY route name this address has
        written under on the

        target (ordered, deduped): one address can legally reach one target
        through several

        routes (N api routes; a channel identity re-routed under a new route
        name), and the

        aggregated person-thread read enumerates the person's routes straight
        off these rows, so

        a scalar here would silently drop legs. ``address`` is the canonical
        form the bridge

        already keys threads by. Frozen.
      properties:
        address:
          minLength: 1
          title: Address
          type: string
        channel:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Channel
        door:
          enum:
            - api
            - channel
          title: Door
          type: string
        linked_at:
          format: date-time
          title: Linked At
          type: string
        our_identity:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Our Identity
        routes:
          items:
            type: string
          minItems: 1
          title: Routes
          type: array
      required:
        - door
        - routes
        - address
        - linked_at
      title: PersonAddress
      type: object
  securitySchemes:
    ApiKeyAuth:
      in: header
      name: x-api-key
      type: apiKey

````