Skip to content

Commit

Permalink
Creating REST contract
Browse files Browse the repository at this point in the history
  • Loading branch information
benbosman authored Dec 18, 2018
1 parent 84c2cc1 commit 29ad374
Showing 1 changed file with 70 additions and 0 deletions.
70 changes: 70 additions & 0 deletions epersongroups.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# EPerson groups Endpoints
[Back to the list of all defined endpoints](endpoints.md)

## Main Endpoint
**GET /api/eperson/groups**

## Single EPerson Group
**GET /api/eperson/groups/<:uuid>**

```json
{
"id": "617cf46b-535c-42d5-9d22-327ce2eff6dc",
"uuid": "617cf46b-535c-42d5-9d22-327ce2eff6dc",
"name": "Administrator",
"handle": null,
"metadata": [
{
"key": "dc.title",
"value": "Administrator",
"language": null
}
],
"permanent": true,
"type": "group",
"_links": {
"groups": {
"href": "https://dspace7-internal.atmire.com/rest/api/eperson/groups/617cf46b-535c-42d5-9d22-327ce2eff6dc/groups"
},
"self": {
"href": "https://dspace7-internal.atmire.com/rest/api/eperson/groups/617cf46b-535c-42d5-9d22-327ce2eff6dc"
}
},
"_embedded": {
"groups": {
"_embedded": {
"groups": []
},
"_links": {
"self": {
"href": "https://dspace7-internal.atmire.com/rest/api/eperson/groups/617cf46b-535c-42d5-9d22-327ce2eff6dc/groups"
}
},
"page": {
"number": 0,
"size": 0,
"totalPages": 1,
"totalElements": 0
}
}
}
}
```

## Create new EPerson Group

**POST /api/eperson/groups**

To create a new EPerson Group, perform a post with the JSON below to the epersons endpoint when logged in as admin.

```json
{
"name": "Administrator",
"metadata": [
{
"key": "dc.title",
"value": "Administrator"
}
]
}
```

0 comments on commit 29ad374

Please sign in to comment.