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

# Replace buyer settings

> Replace a buyer's communication preferences. Set the language and formality Tilta uses for the automated emails it sends on your behalf.

Use this endpoint to set the language and formality level Tilta applies to every automated email it sends to a buyer.

<Tip>
  Match the language to the buyer's `business_address_country` so that onboarding invitations and payment reminders arrive in
  the language the buyer's finance team works in. `FORMAL` is the appropriate formality for most B2B communication.
</Tip>


## OpenAPI

````yaml PUT /v1/buyers/{external_id}/settings
openapi: 3.0.0
info:
  version: 0.0.1
  title: Tilta API
  description: Tilta API documentation
servers:
  - url: https://api.tilta.io
    description: Tilta Production API
  - url: https://api.tilta-sandbox.io
    description: Tilta Sandbox API
security: []
paths:
  /v1/buyers/{external_id}/settings:
    put:
      tags:
        - Buyers
      summary: Replace buyer settings
      description: >-
        Replaces a buyer's communication settings. This is a full-replacement
        update: both `language` and `formality` must be provided.

        Send `null` on either field to clear it.
      parameters:
        - schema:
            type: string
            maxLength: 100
            pattern: ^[a-zA-Z0-9-_]+$
            description: Unique identifier of a buyer.
          required: true
          description: Unique identifier of a buyer.
          name: external_id
          in: path
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                language:
                  type: string
                  nullable: true
                  enum:
                    - AR
                    - BG
                    - CS
                    - DA
                    - DE
                    - EL
                    - EN
                    - ES
                    - ET
                    - FI
                    - FR
                    - GA
                    - HR
                    - HU
                    - IT
                    - JA
                    - LT
                    - LV
                    - MT
                    - NL
                    - 'NO'
                    - PL
                    - PT
                    - RO
                    - RU
                    - SK
                    - SL
                    - SV
                    - TR
                    - UK
                    - ZH
                  description: >-
                    Buyer's preferred communication language. Send `null` to
                    clear.
                formality:
                  type: string
                  nullable: true
                  enum:
                    - NEUTRAL
                    - FORMAL
                    - INFORMAL
                  description: >-
                    Buyer's preferred communication formality. Send `null` to
                    clear.
              required:
                - language
                - formality
              additionalProperties: false
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  language:
                    type: string
                    nullable: true
                    enum:
                      - AR
                      - BG
                      - CS
                      - DA
                      - DE
                      - EL
                      - EN
                      - ES
                      - ET
                      - FI
                      - FR
                      - GA
                      - HR
                      - HU
                      - IT
                      - JA
                      - LT
                      - LV
                      - MT
                      - NL
                      - 'NO'
                      - PL
                      - PT
                      - RO
                      - RU
                      - SK
                      - SL
                      - SV
                      - TR
                      - UK
                      - ZH
                    description: >-
                      Buyer's preferred communication language. Send `null` to
                      clear.
                  formality:
                    type: string
                    nullable: true
                    enum:
                      - NEUTRAL
                      - FORMAL
                      - INFORMAL
                    description: >-
                      Buyer's preferred communication formality. Send `null` to
                      clear.
                required:
                  - language
                  - formality
                additionalProperties: false
                description: Buyer's communication preferences.
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/badRequestSchema'
        '401':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/unauthorizedRequestSchema'
      security:
        - bearerAuth: []
components:
  schemas:
    badRequestSchema:
      type: object
      properties:
        code:
          type: string
          description: Error code
          example: BAD_REQUEST
        error:
          type: string
          description: Error message for debugging purposes
          example: Request validation failed. 1 issue found.
        issues:
          type: array
          items:
            type: object
            properties:
              code:
                type: string
                description: Issue code
                example: INVALID_TYPE
              path:
                type: string
                description: Issue path starting with body, params, querystring, or headers
                example: body.registered_at
              message:
                type: string
                description: Issue message for debugging purposes
                example: Invalid type
            required:
              - code
              - path
              - message
          description: List of issues
          example:
            - code: INVALID_TYPE
              path: body.registered_at
              message: Invalid type
      required:
        - code
        - error
        - issues
      description: Bad Request, see error message for details.
      example:
        code: BAD_REQUEST
        error: Request validation failed. 1 issue found.
        issues:
          - code: INVALID_TYPE
            path: body.registered_at
            message: Invalid type
    unauthorizedRequestSchema:
      type: object
      properties:
        error:
          type: string
          description: Error details.
          example: Unauthorized
        code:
          type: string
          description: Error code.
          example: UNAUTHORIZED
      required:
        - error
        - code
      description: Unauthorized Request.
      example:
        error: Unauthorized
        code: UNAUTHORIZED
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Your Tilta API key, sent as `Bearer <key>`.

````