---
title: Update a chat user
slug: import-test-pdf/update-a-chat-user
createdAt: 2025-10-28T16:28:34.256Z
---

{
  "id": "9mp6mw15Ww6Ky31p9FOcH",
  "type": "api-oas-v2",
  "data": {
    "method": "PATCH",
    "url": "/api/v1/chat-users/{uid}",
    "servers": [],
    "name": "Update a chat user",
    "description": "<p>Verify or activate/deactivate a ChatUser</p>",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "required",
          "name": "body",
          "type": "object",
          "description": "",
          "schema": [
            {
              "name": "is_verifeid",
              "kind": "optional",
              "type": "boolean",
              "description": "If the chat user actually exists in Comet Chat.",
              "example": ""
            },
            {
              "name": "is_active",
              "kind": "optional",
              "type": "boolean",
              "description": "If the current user is active or inactive.",
              "example": ""
            }
          ],
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "successful operation",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "schema": [
              {
                "name": "data",
                "kind": "optional",
                "type": "object",
                "description": "User Data for CometChat",
                "modelRef": "#/components/schemas/ChatUser",
                "customType": "ChatUser",
                "schema": [
                  {
                    "name": "name",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "DVM Sarah Connolly"
                  },
                  {
                    "name": "uid",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "e58ed763-928c-4155-bee9-fdbaaadc15f3"
                  },
                  {
                    "name": "is_active",
                    "kind": "optional",
                    "type": "boolean",
                    "description": "If the user is active in comet-chat",
                    "example": true
                  },
                  {
                    "name": "is_verified",
                    "kind": "optional",
                    "type": "boolean",
                    "description": "If the user has a verified comet-chat account",
                    "example": true
                  },
                  {
                    "name": "user",
                    "kind": "optional",
                    "type": "object",
                    "description": "One of the following: Vet, Clinic, PetParent",
                    "example": "",
                    "schema": []
                  }
                ]
              }
            ],
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "example-0-curl",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request PATCH \\\n     --url /api/v1/chat-users/{uid} \\\n     --header 'accept: application/json'"
        },
        {
          "id": "example-1-javascript",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar requestOptions = {\n   method: 'PATCH',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"/api/v1/chat-users/{uid}\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "example-2-ruby",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"/api/v1/chat-users/{uid}\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Patch.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "example-3-python",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"/api/v1/chat-users/{uid}\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"PATCH\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "example-0-curl"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// successful operation\n{\n  \"data\": {\n    \"name\": \"DVM Sarah Connolly\",\n    \"uid\": \"e58ed763-928c-4155-bee9-fdbaaadc15f3\",\n    \"is_active\": true,\n    \"is_verified\": true,\n    \"user\": {}\n  }\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}