Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

General Information

...

ServiceAPIMethodData ModelsWorkflow
urac/admin/group/listgroupsGET

Data Model: Groups

...

Description

This API lists all group records that exist in the tenant that has the external key sent in the request headers.

Input

...

Type: application/json

...


Output

This API doesn't require input.


Output

...

Response

SOAJS has a unified response. Check out this link to understand more the schema of SOAJS response 

Valid Response

Code Block
languagejs
titleValid Response Sample
linenumberstrue
collapsetrue
{ 	"
  result": true,
 	" data": []
}

Invalid Response

Code Block
languagejs
titleError Response Sample

  {
    _id: "result":false,5d95da834dcd8a4d1d822ef5",
    code: "AAAA",
    name: "errors":{
   Unit test",
    description: "Added by unit test importer.",
    "codes":[415],config: {
        "details":[allowedPackages: {
            {DSBRD: [
                "code":415,DSBRD_DEVOP"
            ]
        "message":"Unable to find group."},
        allowedEnvironments: {
     }       DEV: {
]
    } }

...

Code
Description
415Unable to find group.

...

Request

Code Block
languagebash
titleCalling List Groups API
 > CURL -X GET http://127.0.0.1:4000/urac/admin/group/list

Response

Code Block
languagejs
titleList Groups API response
{   }
"result": true,    "data": [  }
    {},
    	"_id": ObjectId('5d382063be668052c9cab94e'),tenant: {
        	id: "locked": true,5d9321f8b40e09438afbd0c9",
        	"code": "ownertest",
    	"owner": true,    pin: {
            	"name"code: "Owner Group1235",
    	"description": "this is the owner group that owns the dashboard",allowed: true
    	"config": {   }
 	   }
"allowedPackages": { }
]
}

Invalid Response

Code Block
languagejs
titleError Response Sample
linenumberstrue
collapsetrue
{
 	   "result":false,
    "DSBRDerrors":{
[        	"codes":[602],
        "DSBRD_OWNERdetails":[
       	     {
  	]        	 	}    		 } "code":602,
    	"tenant": {            		"message"id:"Model error: "5c0e74ba9acc3c5a84a51259",+ %model_error%"
        	"code": "TES0"   }
 	} 	  }    ]
    }
}

Response schema

Follow this link to check out the response JSON Schema

SOAJS Error Codes



Code
Description
400

Business logic required data are missing

602Model error: + %model_error%