---
title: Get User Details By Id
slug: single-connect-api-3-0-3/get-user-details-by-id
description: Learn how to use cURL to fetch user details from a specific URL in this comprehensive code example. This document demonstrates how to structure a GET request and includes essential headers for working with JSON data, ensuring smooth and efficient data ret
docTags: 
createdAt: 2022-11-10T14:21:49.000Z
---

{
  "id": "36zmd6iuFZsBJq5FWuhNb",
  "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": "0ArpuPE29-me0Pm2WcitA",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url {{url}}/aioc-rest-web/rest/user/detail/USERID \\\n     --header 'accept: application/json'"
        },
        {
          "id": "LfV9FoQ8W0I__hIjnE8cq",
          "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": "XvAOpjGAfTbn3b9961nAP",
          "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": "7fAr0glQXX8367kImXog6",
          "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": "0ArpuPE29-me0Pm2WcitA"
    },
    "results": {
      "languages": [
        {
          "id": "O80BnJ3K_JgQHlheswF6g",
          "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": "O80BnJ3K_JgQHlheswF6g"
    }
  },
  "type": "api-oas-v2",
  "children": [
    {
      "text": ""
    }
  ]
}