---
title: Get User Details By Id
slug: single-connect-api-3-2-0/get-user-details-by-id
description: Learn how to retrieve user details using cURL with this helpful code example. Follow along as we guide you through making a successful GET request, including the required headers for JSON data. Simply replace the user ID variable with the specific user ID
docTags: 
createdAt: 2022-11-10T14:24:52.000Z
---

{
  "id": "qgSgpBI3YDOXTvFUBbrcc",
  "data": {
    "url": "{{url}}/aioc-rest-web/rest/user/detail/USERID",
    "method": "GET",
    "request": {
      "pathParameters": [],
      "queryParameters": [],
      "headerParameters": [
        {
          "name": "Content-Type",
          "type": "string",
          "example": "application/json",
          "description": ""
        },
        {
          "name": "X-XSRF-TOKEN",
          "type": "string",
          "example": "{{csrftoken}}",
          "description": ""
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "Get User Details By Id",
        "jsonExample": "{\n    \"id\": \"a177be61-8850-4f03-be1c-3ce275f02c1f\",\n    \"eid\": \"testuser\",\n    \"personelId\": \"123123\",\n    \"name\": \"test\",\n    \"passwordAlgorithm\": \"MD5\",\n    \"password\": \"202cb962ac59075b964b07152d234b70\",\n    \"email\": \"test@test.com\",\n    \"surname\": \"user\",\n    \"internal\": true,\n    \"properties\": {\n        \"phoneNumber\": \"5550000000\",\n        \"ubaThreshold\": \"50\",\n        \"forcePasswordChangeOnNextLogin\": \"true\"\n    },\n    \"groups\": [\n        \"DEFAULT_GROUP_SYSYEM_ADMINS\",\n        \"DEFAULT_GROUP_SYSYEM_USERS\"\n    ],\n    \"managerGroups\": [],\n    \"lastLogin\": null,\n    \"lastLoginIp\": \"10.20.50.66\",\n    \"recordLimit4Search\": null,\n    \"passwordDirty\": false,\n    \"passwordAutoGenerated\": false,\n    \"phoneNumber\": \"5550000000\",\n    \"forceChangePasswordOnNextLogin\": true,\n    \"lockReason\": null,\n    \"unlockOnPasswordChanged\": false,\n    \"unlockTime\": null,\n    \"tempUserEndTime\": null,\n    \"tempUserStartTime\": null,\n    \"tempUser\": false,\n    \"externalDirectorySource\": null,\n    \"userPropertyKey4Search\": null,\n    \"userPropertyValue4Search\": null,\n    \"locked\": false\n}"
      }
    ],
    "contentType": "application/json",
    "description": "<p>This method returns information about a chosen User in Single Connect.</p>\n<p>Put user id to end of get url\n<a href=\"http://hostname/aioc-rest-web/rest/user/detail/USERID\" target=\"_blank\">http://hostname/aioc-rest-web/rest/user/detail/USERID</a></p>",
    "examples": {
      "languages": [
        {
          "id": "-GUfMp5SP6guNWLRisB-O",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url {{url}}/aioc-rest-web/rest/user/detail/USERID \\\n     --header 'accept: application/json'"
        },
        {
          "id": "TMTKz5YjSeIPjnAITMwaI",
          "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: 'GET',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"{{url}}/aioc-rest-web/rest/user/detail/USERID\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "6-gTmHyhmcRj1ov0qTE4s",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"{{url}}/aioc-rest-web/rest/user/detail/USERID\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Get.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "XKn5uRzfcqfdEmXpMuXgd",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"{{url}}/aioc-rest-web/rest/user/detail/USERID\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "-GUfMp5SP6guNWLRisB-O"
    },
    "results": {
      "languages": [
        {
          "id": "C-otXjo8z5ZFanbLoUwFA",
          "language": "200",
          "code": "{\n    \"id\": \"a177be61-8850-4f03-be1c-3ce275f02c1f\",\n    \"eid\": \"testuser\",\n    \"personelId\": \"123123\",\n    \"name\": \"test\",\n    \"passwordAlgorithm\": \"MD5\",\n    \"password\": \"202cb962ac59075b964b07152d234b70\",\n    \"email\": \"test@test.com\",\n    \"surname\": \"user\",\n    \"internal\": true,\n    \"properties\": {\n        \"phoneNumber\": \"5550000000\",\n        \"ubaThreshold\": \"50\",\n        \"forcePasswordChangeOnNextLogin\": \"true\"\n    },\n    \"groups\": [\n        \"DEFAULT_GROUP_SYSYEM_ADMINS\",\n        \"DEFAULT_GROUP_SYSYEM_USERS\"\n    ],\n    \"managerGroups\": [],\n    \"lastLogin\": null,\n    \"lastLoginIp\": \"10.20.50.66\",\n    \"recordLimit4Search\": null,\n    \"passwordDirty\": false,\n    \"passwordAutoGenerated\": false,\n    \"phoneNumber\": \"5550000000\",\n    \"forceChangePasswordOnNextLogin\": true,\n    \"lockReason\": null,\n    \"unlockOnPasswordChanged\": false,\n    \"unlockTime\": null,\n    \"tempUserEndTime\": null,\n    \"tempUserStartTime\": null,\n    \"tempUser\": false,\n    \"externalDirectorySource\": null,\n    \"userPropertyKey4Search\": null,\n    \"userPropertyValue4Search\": null,\n    \"locked\": false\n}"
        }
      ],
      "selectedLanguageId": "C-otXjo8z5ZFanbLoUwFA"
    }
  },
  "type": "api-oas-v2",
  "children": [
    {
      "text": ""
    }
  ]
}