Versions Compared

Key

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

General Information

...

ServiceAPIMethod
urac/admin/group/edit
GET
POST


Data Model: %Link to Data Model% Groups

Workflow: %Link to Architecture Page% Edit Group Flow

Input

...

Type: application/json
NameSourceMandatoryTypeSpecial FormatDescription
 
gIdQueryYESStringN/AThe Group ID
nameBodyYESStringN/A
descriptionBodyYESStringN/A



NameSourceMandatoryTypeSpecial FormatDescription
gIdQueryYESStringN/AThe Group ID
nameBodyYESStringN/A
descriptionBodyYESStringN/A
configBodyYESObjectN/A

allowedPackages
YESObjectN/A


^([A-Za-z0-9]+)$
YESArray of strings

Then keys should follow the pattern : 

...


^([A-Za-z0-9]+)$

The key is the product code.
The strings inside the array are the package codes.


allowedEnvironments
NOObjectN/A


^([A-Za-z]+)$
NOObjectN/AThe environment code with empty object for now 


Output

...

Valid Response

Code Block
languagejs
titleValid Response Sample
{
	"result": true,
	"data": {
		"..."	
	}true
}

...


Invalid Response

Code Block
languagejs
titleError Response Sample
{
    "result":false,
    "errors":{
        "codes":[400417],
        "details":[
            {
                "code":400417,
                "message":"ProblemInvalid withgroup theid provided password"
            }
        ]
    }
}



Error Codes



 

Code
Description
400Database Error
417Invalid group id provided
418Unable to edit Group.


Example (CURL)

...

Request

Code Block
languagebash
titleCalling YOUR Edit Group API
 > CURL -X POST http://127.0.0.1:4000/...

Response

Code Block
languagejs
titleYOUR API response
{
	"result": true,
	"data/urac/admin/group/edit?gId=5 -d '{
	"name": "Silver Group",
	"description": "grp description",
	"config": {
		"allowedPackages": {
			"_idprod": ["57063608622c47b5c097d19bpack"]
		},
	"allowedEnvironments": {
			"..."PROD": {}
		}
	}
}'

Response

Code Block
languagejs
titleEdit Group API response
{
	"result": true,
	"data": true
}