Info | ||
---|---|---|
| ||
Spaces Resources are identified by the following resource name: /spaces/{spaceName} where "spaceName" is the name of the space. The collection of Spaces is denoted by /spaces/ |
Tip | ||
---|---|---|
| ||
The Resources API examples should map to the use cases presented in previous sections. |
List Spaces
HTTP Component | HTTP Component Value | Description |
---|---|---|
Method | GET |
|
Body | None |
|
Encoding | None |
|
Accept | text/html | Currently we only support returning via HTML. Future versions could support Atom or RSS |
Response Code | 200 | Success |
| 403 | Unauthorized |
| 401 | Authentication |
Example HTTP Request
Code Block |
---|
GET /spaces/ HTTP/1.1 Host: registry.rutgers.edu |
Example HTTP Response
Code Block | ||||
---|---|---|---|---|
| ||||
HTTP/1.1 200 OK <ul> <li><a href="http://registry.rutgers.edu/spaces/IdM">IdM</a></li> <li><a href="http://registry.rutgers.edu/spaces/ESS">ESS</a></li> <li><a href="http://registry.rutgers.edu/spaces/MySpace">MySpace</a></li> </ul> |
Create a Space
HTTP Component | HTTP Component Value | Description |
---|---|---|
Method | PUT |
|
Body | Set of owner Ids |
|
Encoding | www-url-form-encoded | Currently we accept www-url-form-encoded. Future versions could accept XML, RSS, Atom, etc. |
Response Code | 201 | Created |
| 403 | Unauthorized |
| 400 | Bad Request |
| ??? | Already Exists |
| 401 | Authentication |
Example HTTP Request
Code Block |
---|
PUT /spaces/IdM HTTP/1.1 Host: registry.rutgers.edu owner_id=567&owner_id=568&owner_id=123 |
Example HTTP Response
Code Block |
---|
HTTP/1.1 201 Created |
Delete a Space
HTTP Component | HTTP Component Value | Description |
---|---|---|
Method | DELETE |
|
Body | None |
|
Response Code | 200 | Success |
| 403 | Unauthorized |
| 404 | Space never existed |
| 401 | Authentication |
Example HTTP Request
Code Block |
---|
DELETE /spaces/IdM HTTP/1.1 Host: registry.rutgers.edu |
Example HTTP Response
Code Block |
---|
HTTP/1.1 200 OK Space "IdM" was successfully deleted. |
Rename a Space
HTTP Component | HTTP Component Value | Description |
---|---|---|
Method | PUT |
|
Body | the new space name |
|
Encoding | www-url-form-encoded | Currently we accept www-url-form-encoded. Future versions could accept XML, RSS, Atom, etc. |
Response Code | 204 | Success |
| 403 | Unauthorized |
| 404 | Not found |
| 400 | Bad User Request |
| 401 | Authentication |
Example HTTP Request
Code Block |
---|
PUT /spaces/IdM HTTP/1.1 Host: registry.rutgers.edu newSpaceName=IdMs |
Example HTTP Response
Code Block |
---|
HTTP/1.1 204 No Content Location: http://registry.rutgers.edu/spaces/IdMs |