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

# Update a tenant

> Updates the Tenant resource.

<sup>Required permissions: `tenant:manager`</sup>



## OpenAPI

````yaml patch /tenants/{id}
openapi: 3.1.0
info:
  title: Fynn API
  description: ''
  termsOfService: https://www.fynn.eu/tos
  contact:
    name: Fynn UG (haftungsbeschränkt)
    url: https://www.fynn.eu
    email: hi@fynn.eu
  license:
    name: Proprietary
    url: https://www.fynn.eu/license
  version: 0.0.0
servers:
  - url: https://coreapi.io
    description: Production
  - url: https://preview.coreapi.io
    description: Sandbox
security:
  - JWT: []
tags: []
paths:
  /tenants/{id}:
    parameters: []
    patch:
      tags:
        - Tenant
      summary: Update a tenant
      description: |-
        Updates the Tenant resource.

        <sup>Required permissions: `tenant:manager`</sup>
      operationId: updateTenant
      parameters:
        - name: id
          in: path
          description: Tenant identifier
          required: true
          deprecated: false
          schema:
            type: string
          style: simple
          explode: false
      requestBody:
        description: The updated Tenant resource
        content:
          application/merge-patch+json:
            schema:
              $ref: '#/components/schemas/Tenant-TenantUpdate'
          application/vnd.api+json:
            schema:
              $ref: '#/components/schemas/Tenant-TenantUpdate'
        required: true
      responses:
        '200':
          description: Tenant resource updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Tenant-TenantRead'
            text/html:
              schema:
                $ref: '#/components/schemas/Tenant-TenantRead'
          links: {}
        '400':
          description: Invalid input
        '404':
          description: Resource not found
        '422':
          description: Unprocessable entity
      deprecated: false
      security:
        - JWT:
            - tenant:manager
components:
  schemas:
    Tenant-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      required:
        - name
        - legalCompanyName
        - commercialRegister
        - commercialRegisterNumber
      properties:
        name:
          minLength: 2
          maxLength: 255
          description: The name of the tenant
          example: ACME
          type: string
        vatNumber:
          example: DE123456789
          type:
            - string
            - 'null'
        legalCompanyName:
          example: Acme Inc.
          type: string
        city:
          example: Cologne
          type: string
        zip:
          example: '50667'
          type: string
        street:
          example: Domstraße
          type: string
        housenumber:
          example: '1'
          type: string
        countryCode:
          example: DE
          type: string
        website:
          example: https://acme.com
          type:
            - string
            - 'null'
        commercialRegister:
          example: Berlin Charlottenburg
          type:
            - string
            - 'null'
        commercialRegisterNumber:
          example: HRB 123456
          type:
            - string
            - 'null'
        phone:
          example: +49 123 456 789
          type:
            - string
            - 'null'
        email:
          example: info@acme.de
          type: string
        ceo:
          example: Max Mustermann
          type:
            - string
            - 'null'
        iban:
          description: The IBAN will be displayed on the invoice
          example: DE89370400440532013000
          type: string
        appearance:
          anyOf:
            - $ref: '#/components/schemas/Appearance-TenantUpdate'
            - type: 'null'
        documentSettings:
          anyOf:
            - $ref: '#/components/schemas/DocumentSettings-TenantUpdate'
            - type: 'null'
        timeZone:
          readOnly: true
          default: Europe/Berlin
          example: Europe/Berlin
          type: string
        readOnlyCustomers:
          description: If true, customers are read-only in the frontend
          type: boolean
    Tenant-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        id:
          readOnly: true
          example: 01F9Z3ZJXZQZJZJZJZJZJZJZJZ
          type: string
        name:
          minLength: 2
          maxLength: 255
          description: The name of the tenant
          example: ACME
          type: string
        username:
          readOnly: true
          example: acme
          type: string
        vatNumber:
          example: DE123456789
          type:
            - string
            - 'null'
        owner:
          readOnly: true
          nullable: false
        legalCompanyName:
          example: Acme Inc.
          type: string
        city:
          example: Cologne
          type: string
        zip:
          example: '50667'
          type: string
        street:
          example: Domstraße
          type: string
        housenumber:
          example: '1'
          type: string
        countryCode:
          example: DE
          type: string
        website:
          example: https://acme.com
          type:
            - string
            - 'null'
        commercialRegister:
          example: Berlin Charlottenburg
          type:
            - string
            - 'null'
        commercialRegisterNumber:
          example: HRB 123456
          type:
            - string
            - 'null'
        phone:
          example: +49 123 456 789
          type:
            - string
            - 'null'
        email:
          example: info@acme.de
          type: string
        ceo:
          example: Max Mustermann
          type:
            - string
            - 'null'
        iban:
          description: The IBAN will be displayed on the invoice
          example: DE89370400440532013000
          type: string
        environment:
          readOnly: true
          type: string
          enum:
            - sandbox
            - production
        appearance:
          anyOf:
            - $ref: '#/components/schemas/Appearance-TenantRead'
            - type: 'null'
        documentSettings:
          anyOf:
            - $ref: '#/components/schemas/DocumentSettings-TenantRead'
            - type: 'null'
        timeZone:
          readOnly: true
          default: Europe/Berlin
          example: Europe/Berlin
          type: string
        readOnlyCustomers:
          description: If true, customers are read-only in the frontend
          type: boolean
        createdAt:
          readOnly: true
          description: The date and time when the resource was created.
          example: '2021-01-01T00:00:00+00:00'
          type: string
          format: date-time
        updatedAt:
          readOnly: true
          description: The date and time when the resource was last updated.
          example: '2021-01-01T00:00:00+00:00'
          type: string
          format: date-time
      required:
        - name
        - legalCompanyName
        - commercialRegister
        - commercialRegisterNumber
    Appearance-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      properties:
        logoUrl:
          oneOf:
            - format: uri
            - pattern: ^(data:image/[a-z]+;base64,.*)$
          description: >-
            The url will be used in pdf documents, checkout and emails. The
            value can either be a url or a base64 string.
          example: https://example.com/logo.png
        primaryColor:
          description: >-
            The primary color will be used in the pdf documents, checkout and
            emails.
          default: '#000000'
          example: '#000000'
          type: string
        secondaryColor:
          description: >-
            The secondary color will be used in the pdf documents, checkout and
            emails.
          default: '#000000'
          example: '#000000'
          type: string
        privacyUrl:
          format: uri
          description: The privacy url will be shown in the checkout and self-service.
          externalDocs:
            url: https://schema.org/url
          example: https://example.com/privacy
          type:
            - string
            - 'null'
        conditionsUrl:
          format: uri
          description: >-
            The terms and conditions url will be shown in the checkout and
            self-service.
          externalDocs:
            url: https://schema.org/url
          example: https://example.com/terms-and-conditions
          type:
            - string
            - 'null'
      required:
        - primaryColor
    DocumentSettings-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      required:
        - logoPosition
      properties:
        logoPosition:
          description: |-
            The position of the logo in the pdf documents.

            Possible values:
             * `left`: The logo will be placed on the left side of the document.
             * `right`: The logo will be placed on the right side of the document.
             * `center`: The logo will be placed in the center of the document.
          default: left
          example: left
        footer:
          anyOf:
            - $ref: '#/components/schemas/DocumentFooter-TenantUpdate'
            - type: 'null'
    Appearance-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        id:
          readOnly: true
          example: ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b
          type: string
        logoUrl:
          oneOf:
            - format: uri
            - pattern: ^(data:image/[a-z]+;base64,.*)$
          description: >-
            The url will be used in pdf documents, checkout and emails. The
            value can either be a url or a base64 string.
          example: https://example.com/logo.png
        primaryColor:
          description: >-
            The primary color will be used in the pdf documents, checkout and
            emails.
          default: '#000000'
          example: '#000000'
          type: string
        secondaryColor:
          description: >-
            The secondary color will be used in the pdf documents, checkout and
            emails.
          default: '#000000'
          example: '#000000'
          type: string
        privacyUrl:
          format: uri
          description: The privacy url will be shown in the checkout and self-service.
          externalDocs:
            url: https://schema.org/url
          example: https://example.com/privacy
          type:
            - string
            - 'null'
        conditionsUrl:
          format: uri
          description: >-
            The terms and conditions url will be shown in the checkout and
            self-service.
          externalDocs:
            url: https://schema.org/url
          example: https://example.com/terms-and-conditions
          type:
            - string
            - 'null'
        createdAt:
          readOnly: true
          type: string
          format: date-time
        updatedAt:
          readOnly: true
          type: string
          format: date-time
      required:
        - primaryColor
    DocumentSettings-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        id:
          readOnly: true
          type: string
        logoPosition:
          description: |-
            The position of the logo in the pdf documents.

            Possible values:
             * `left`: The logo will be placed on the left side of the document.
             * `right`: The logo will be placed on the right side of the document.
             * `center`: The logo will be placed in the center of the document.
          default: left
          example: left
        footer:
          anyOf:
            - $ref: '#/components/schemas/DocumentFooter-TenantRead'
            - type: 'null'
      required:
        - logoPosition
    DocumentFooter-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      required:
        - translations
      properties:
        translations:
          minItems: 1
          description: The translations of the document footer. The locale is used as key.
          type: object
          additionalProperties:
            $ref: '#/components/schemas/DocumentFooterTranslation-TenantUpdate'
    DocumentFooter-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        id:
          readOnly: true
          type: string
        translations:
          minItems: 1
          description: The translations of the document footer. The locale is used as key.
          type: object
          additionalProperties:
            $ref: '#/components/schemas/DocumentFooterTranslation-TenantRead'
      required:
        - translations
    DocumentFooterTranslation-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      properties:
        locale:
          minLength: 2
          maxLength: 2
          example: en
          type: string
        column1:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantUpdate'
        column2:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantUpdate'
        column3:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantUpdate'
        column4:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantUpdate'
    DocumentFooterTranslation-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        locale:
          minLength: 2
          maxLength: 2
          example: en
          type: string
        column1:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantRead'
        column2:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantRead'
        column3:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantRead'
        column4:
          $ref: '#/components/schemas/DocumentFooterColumn-TenantRead'
    DocumentFooterColumn-TenantUpdate:
      type: object
      description: ''
      deprecated: false
      properties:
        line1:
          maxLength: 255
          type:
            - string
            - 'null'
        line2:
          maxLength: 255
          type:
            - string
            - 'null'
        line3:
          maxLength: 255
          type:
            - string
            - 'null'
        line4:
          maxLength: 255
          type:
            - string
            - 'null'
        line5:
          maxLength: 255
          type:
            - string
            - 'null'
    DocumentFooterColumn-TenantRead:
      type: object
      description: ''
      deprecated: false
      properties:
        line1:
          maxLength: 255
          type:
            - string
            - 'null'
        line2:
          maxLength: 255
          type:
            - string
            - 'null'
        line3:
          maxLength: 255
          type:
            - string
            - 'null'
        line4:
          maxLength: 255
          type:
            - string
            - 'null'
        line5:
          maxLength: 255
          type:
            - string
            - 'null'
  securitySchemes:
    JWT:
      type: http
      scheme: bearer

````