---
title: Get Approved User List for Group
slug: single-connect-api-3-2-0/get-approved-user-list-for-group
description: Learn how to use the curl command to effortlessly make a POST request and fetch a complete list of approved group users from a specific URL in this comprehensive code example. This tutorial demonstrates setting the appropriate headers ('Accept' and 'Conte
docTags: 
createdAt: 2022-11-10T14:24:52.000Z
---

{
  "id": "uEBYJH2sfyVzIgBDBnCII",
  "data": {
    "url": "{{url}}/aioc-rest-web/rest/sc/sapm/getApprovedUserListForGroup",
    "method": "POST",
    "request": {
      "pathParameters": [],
      "queryParameters": [],
      "headerParameters": [
        {
          "name": "X-XSRF-TOKEN",
          "type": "string",
          "example": "{{csrftoken}}",
          "description": ""
        }
      ],
      "bodyDataParameters": [
        {
          "name": "body",
          "type": "string",
          "example": "{\n\t\"dbId\":85202\n}",
          "description": ""
        }
      ],
      "formDataParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "",
        "jsonExample": ""
      }
    ],
    "contentType": "application/json",
    "description": "This API allows you to get list of approved user list of the SAPM group you sent dbId of. You will get response for this API if you are allowed to see this list.",
    "examples": {
      "languages": [
        {
          "id": "LCF1fwoLU1ISJ9ZSUECXQ",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request POST \\\n     --url {{url}}/aioc-rest-web/rest/sc/sapm/getApprovedUserListForGroup \\\n     --header 'accept: application/json'"
        },
        {
          "id": "MRd4anoYCQdpZiis4t5bn",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\n\nvar requestOptions = {\n   method: 'POST',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"{{url}}/aioc-rest-web/rest/sc/sapm/getApprovedUserListForGroup\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "l4Yrk95jWyvuKe2Io8T-5",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"net/http\"\n\nurl = URI(\"{{url}}/aioc-rest-web/rest/sc/sapm/getApprovedUserListForGroup\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Post.new(url)\nrequest[\"accept\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "TsldnEJnJRZXVfnX5YW8f",
          "language": "python",
          "label": "Python",
          "code": "import requests\n\nurl = \"{{url}}/aioc-rest-web/rest/sc/sapm/getApprovedUserListForGroup\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "LCF1fwoLU1ISJ9ZSUECXQ"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": ""
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "type": "api-oas-v2",
  "children": [
    {
      "text": ""
    }
  ]
}