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

# Modify contact

> Edits the provided fields for the contact with the given id.



## OpenAPI

````yaml PATCH /v1/contacts/{contactId}
openapi: 3.1.0
info:
  title: infinity.swiss Open API
  version: '1.0'
  summary: ''
servers:
  - url: https://api.infinity.swiss
security:
  - apiKey: []
paths:
  /v1/contacts/{contactId}:
    parameters:
      - schema:
          type: string
        name: contactId
        in: path
        description: The id of the specific contact
        required: true
    patch:
      tags: []
      summary: Modify contact
      description: Edits the provided fields for the contact with the given id.
      operationId: modify-contact-by-id-v1
      requestBody:
        description: >-
          Provide the changes to save to the contact in the request body. Any
          fields that are not provided are left unchanged.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Contact'
      responses:
        '200':
          description: Changes saved successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  contact:
                    $ref: '#/components/schemas/Contact'
                    x-stoplight:
                      id: zc3nvbleo2tg5
        '401':
          $ref: '#/components/responses/Unauthorised'
components:
  schemas:
    Contact:
      type: object
      x-examples:
        Example 1:
          id: 6474bb0cccc5b63aae56fa15
          companyName: Complex GmbH
          firstName: Claudia
          lastName: Röthlisberger
          streetName: Frutigenstrasse
          buildingNumber: '24'
          townName: Spiez
          postCode: '3700'
          country: Schweiz
          position: Leiterin Bereich Metallurgie
          email: test@test.com
          mobile: 079 111 22 33
          phone: 052 111 22 33
          website: complex.swiss
          category: clients
          formOfAddress: ''
          note: Kontakt durch Startup-Nights.
          vatNumber: CHE 123.456.789 MWST
          customerIdentification: C-12345
      title: Contact
      description: Represents a contact, such as a supplier, client, partner, lead, etc.
      properties:
        id:
          type: string
          example: 68234731e6074232892d18c4
          description: A unique hex identifier for the transaction.
          readOnly: true
        companyName:
          type: string
          description: >-
            The company name associated with this contact.


            For contacts which represent companies, this is used as the name of
            the contact.
          maxLength: 48
        firstName:
          type: string
          description: The given name of this contact.
          maxLength: 48
        lastName:
          type: string
          description: The surname of this contact.
          maxLength: 48
        streetName:
          type: string
          description: The street name of the contact's address.
          maxLength: 48
        buildingNumber:
          type: string
          description: The building number of the contact's address.
          maxLength: 24
        townName:
          type: string
          description: The town or city name of the contact's address.
          maxLength: 48
        postCode:
          type: string
          description: The postal code of the contact's address.
          maxLength: 24
          example: '3700'
        position:
          type: string
          description: The position of the contact person within their company.
          maxLength: 48
        email:
          type: string
          description: >-
            The email address of the contact person. Must be a valid e-mail
            address or empty.
          format: email
          maxLength: 48
        mobile:
          type: string
          description: The mobile phone number of the contact person.
          maxLength: 24
        phone:
          type: string
          description: The phone number of the contact person.
          maxLength: 24
        website:
          type: string
          description: The website of this contact. Must be a valid URL.
          maxLength: 128
        category:
          description: An optional category to associate this contact with.
          enum:
            - clients
            - suppliers
            - partners
            - team
            - leads
        formOfAddress:
          type: string
          description: The form of address of the contact person, e.g. “Dr. med.“
          maxLength: 24
        note:
          type: string
          description: A custom plain-text note for this contact. May be multi-line.
          maxLength: 2000
        vatNumber:
          type: string
          maxLength: 24
          description: >-
            An optional VAT registry number for this company. Is not validated
            for any specific format to allow entering values for formats of
            arbitrary countries.
        country:
          type: string
          maxLength: 24
          description: Display name of the country of this contact.
        secondaryAddressLine:
          type: string
          x-stoplight:
            id: 0nsdd0stpefm7
          description: An optional secondary address line for the location of this contact.
          maxLength: 48
        customerIdentification:
          type: string
          description: An optional customer identification number for this contact.
          maxLength: 16
      examples:
        - id: 6474bb0cccc5b63aae56fa15
          companyName: Complex GmbH
          firstName: Claudia
          lastName: Röthlisberger
          streetName: Frutigenstrasse
          buildingNumber: '24'
          townName: Spiez
          postCode: '3700'
          country: Schweiz
          position: Leiterin Bereich Metallurgie
          email: test@test.com
          mobile: 079 111 22 33
          phone: 052 111 22 33
          website: complex.swiss
          category: clients
          formOfAddress: ''
          note: Kontakt durch Startup-Nights.
          vatNumber: CHE 123.456.789 MWST
          customerIdentification: C-12345
  responses:
    Unauthorised:
      description: >-
        An unauthorised request was submitted. You may be using an incorrect or
        expired API token, or are attempting to access a document outside of the
        scope of the token.
      content:
        application/json:
          schema:
            type: object
            properties:
              code:
                type: string
                x-stoplight:
                  id: 08hkw8ukmi2lp
                description: Specific error code
          examples:
            Unauthorised request:
              value:
                code: general/unauthorised
  securitySchemes:
    apiKey:
      name: x-api-token
      type: apiKey
      in: header
      description: >-
        API token for authentication. Obtain from your Infinity account
        settings.

````