---
title: "REST API: Spaces"
type: "wiki"
space: "Axero Documentation"
author: "Anonymous User"
created: 2011-03-13T07:59:55Z
updated: 2026-09-07T20:03:22Z
tags: ["API"]
url: "https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/372/rest-api-spaces"
---

# REST API: Spaces

[Open API Guide](https://my.axerosolutions.com/spaces/5/axero-documentation/api-guide?id=372)

Create, configure, and manage spaces that organize content, members, and permissions into distinct areas of the site. Control access, customize navigation, manage wall posts, and automate space provisioning.

## Available Endpoints

| Method | Endpoint | Description |
| :--- | :--- | :--- |
| POST | [Add Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/529/api)<br>`/api/spaces/{SpaceID}/roles` | Adds a new role to the space |
| POST | [Add Space User](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/511/api)<br>`/api/spaces/{SpaceID}/users` | Adds a new user to the space |
| PUT | [Approve/Decline Space User](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/526/api)<br>`/api/spaces/{SpaceID}/users/{UserID}/membership/status` | Users need approval to join moderated spaces. This join request goes to the space admin; who can approve or decline the request. |
| POST | [Assign Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/512/api)<br>`/api/users/{UserID}/spaces/{SpaceID}/roles` | Assign a space role to an existing space user |
| POST | [Bulk Add Users to Spaces](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/29455/api)<br>`/api/spaces/users` | Adds multiple users to several spaces |
| GET | [Check Space Moderation](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/519/api)<br>`/api/spaces/{SpaceID}/moderation/status` | Check if the space is moderated or not |
| GET | [Check Space Name Availability](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/518/api)<br>`/api/spaces/availability` | Check if the desired space name is available or not |
| POST | [Create Space](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/508/api)<br>`/api/spaces` | Establish a brand new Space for collaboration. This is the first step in creating a new team or project area. |
| DELETE | [Delete All Space Roles of User](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/66962/api)<br>`/api/users/{UserID}/spaces/{SpaceID}/roles` | Remove every space role the user holds in the space. Returns JSON indicating whether or not the roles removal was successful. |
| DELETE | [Delete Space](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/510/api)<br>`/api/spaces/{spaceid}` | Retire a Space. The space is marked for deletion \(StatusID 13, ToBeDeleted\) rather than removed at once, and Get Space still returns it until it is purged. |
| DELETE | [Delete Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/531/api)<br>`/api/spaces/{spaceid}/roles/{roleid}` | Delete a space role. Returns JSON indicating whether or not the specified role was actually deleted. |
| DELETE | [Delete User from Space](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/525/api)<br>`/api/spaces/{SpaceID}/users/{UserID}` | Remove a user from a space. |
| GET | [Get All Spaces](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4772/api)<br>`/api/spaces` | Browse the entire directory of public Spaces. This helps users discover new teams, projects, or interest groups they might want to join. |
| GET | [Get Child Spaces](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4771/api)<br>`/api/spaces/child` | Finds all the spaces created under the parent space. |
| GET | [Get My Spaces](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/66959/api)<br>`/api/spaces/me` | Enables administrators and developers to programmatically retrieve a list of the logged in user's spaces. |
| GET | [Get Space](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4773/api)<br>`/api/spaces/{SpaceID}` | Get a space's details. SpaceID 0 returns the top level community. |
| GET | [Get Space Directories](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4877/api)<br>`/api/spaces/{SpaceID}/file/directories/{ParentDirectoryID}` | Enables administrators and developers to programmatically retrieve a list of directories based on the space ID and parent directory ID. |
| GET | [Get Space Features](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/86155/api)<br>`/api/spaces/{SpaceID}/features` | Get the features switched on for a space, or for the site when SpaceID is 0. |
| GET | [Get Space Files](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4910/api)<br>`/api/files/space` | Enables administrators and developers to programmatically retrieve a list of files in a space. |
| GET | [Get Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/522/api)<br>`/api/spaces/{SpaceID}/roles/{RoleID}` | Get a space role. |
| GET | [Get Space Role by Role Name](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/5801/api)<br>`/api/spaces/{SpaceID}/roles` | Get a space role by its name. |
| GET | [Get Space Roles](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/66963/api)<br>`/api/spaces/{SpaceID}/roles` | Enables administrators and developers to programmatically retrieve all roles for a specific space. |
| GET | [Get Space Root Directory](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/42913/api)<br>`/api/spaces/{SpaceID}/files/directories/root` | Enables administrators and developers to programmatically retrieve the root directory of a particular space. |
| GET | [Get Space URL](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/4774/api)<br>`/api/spaces/{SpaceID}/url` | Fetches the space url based on the Space ID. |
| GET | [Get Space Users](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/29968/api)<br>`/api/spaces/{SpaceID}/users` | Get the members of a space, or with SpaceID 0 the site's users. |
| GET | [Get User Membership Status](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/520/api)<br>`/api/users/{UserID}/spaces/{SpaceID}/membership/status` | Enables administrators and developers to programmatically retrieve user's space membership status. ResponseData is the status name: Member, Pending, or NonMember \(also NonMember when either ID is 0\). |
| GET | [Get User Space IDs](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/514/api)<br>`/api/users/{UserID}/spaces/ids` | Fetches all the space IDs of the user. |
| GET | [Get User Space Roles](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/524/api)<br>`/api/spaces/{SpaceID}/roles` | Get the space roles a user holds in a space. |
| GET | [Get User Spaces](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/29969/api)<br>`/api/spaces/me` | List all the groups you belong to. These "Spaces" are where the collaboration happens. |
| PUT | [Set Space Status](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/527/api)<br>`/api/spaces/{SpaceID}/status` | Sets the status of an existing space specified by Space ID and Status ID. Returns JSON indicating whether or not the specified space status was actually updated. |
| DELETE | [Unassign Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/5621/api)<br>`/api/users/{UserID}/spaces/{SpaceID}/roles/{RoleID}` | Remove a space role from a user in a space. ResponseData is true when the role was removed, otherwise false. |
| PUT | [Update Space](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/509/api)<br>`/api/spaces/{spaceid}` | Edit the details of an existing Space. Change descriptions, rename teams, or adjust security settings as needs evolve. |
| POST | [Update Space Image](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/1806/api)<br>`/api/spaces/{SpaceID}/image` | Set or replace a space's image from the raw bytes of the request body. |
| PUT | [Update Space Role](https://my.axerosolutions.com/spaces/5/axero-documentation/wiki/view/530/api)<br>`/api/spaces/{SpaceID}/roles/{RoleID}` | Update a space role's name or description. ResponseData is true when the role was saved. |
