This page contains information on the factors common across all or most of the Crowd REST APIs. Another page contains the details of the specific REST resources.
The Crowd 2.0 experimental REST APIs are deprecated
Crowd 2.0 introduced the experimental 'admin
' REST APIs, allowing interactions with the Crowd Administration Console. In the upcoming release of Crowd 2.1, we will replace these with a new set of REST APIs for use by applications connecting to Crowd. This JIRA issue has the details - see the description and the comments: CWD-1912. We will be delighted with your feedback on the JIRA issue too.
URIs for a Crowd REST API resource have the following structure: With context:
1 2http://host:port/context/rest/api-name/api-version/resource-name
Or without context:
1 2http://host:port/rest/api-name/api-version/resource-name
In Crowd 2.0, the only api-name
available is admin
. This is the API that allows interaction with the Crowd Administration Console.
1 2http://myhost.com:8095/crowd/rest/admin/1/directory http://localhost:8095/crowd/rest/admin/latest/directory
Or without context:
1 2http://crowd.myhost.com:8095/rest/admin/1/directory http://crowd.myhost.com:8095/rest/admin/latest/directory
Here is an explanation for each part of the URI:
host
and port
define the host and port where the Crowd application lives.context
is the servlet context of the Crowd installation. For example, the context might be crowd
. Omit this section if your URI does not include a context.rest
denotes the REST API.api-name
identifies a specific Crowd API. For example, admin
is the API that allows interaction with the Crowd Administration Console. (This is the path declared in the REST module type in the REST plugin descriptor.)api-version
is the API version number, e.g. 1
or 2
. See the section on CROWD:API version control.resource-name
identifies the required resource. In some cases, this may be a generic resource name such as /foo
. In other cases, this may include a generic resource name and key. For example, /foo
returns a list of the foo
items and /foo/{key
} returns the full content of the foo
identified by the given key
.Refer to the details of the specific REST resources.
The Crowd REST APIs return HTTP responses in one of the following formats:
Response Format | Requested via... |
---|---|
JSON | Requested via one of the following:
|
XML | Requested via one of the following:
|
The Crowd REST APIs are subject to version control. The version number of an API appears in its URI. For example, use this URI structure to request version 1 of the 'admin' API:
1 2http://host:port/context/rest/admin/1/...
To get the latest version of the API, you can also use the latest
key-word. For example, if versions 1 and 2 of the 'admin' API are available, the following two URIs will point to the same resources:
1 2http://host:port/context/rest/admin/latest/...
1 2http://host:port/context/rest/admin/2/...
Notes:
1
or 2
.Access to all resources (using any method) requires the client to be authenticated, via basic authentication. See RFC 2617.
For example, the following cURL request searches for a user called 'smith', with basic authentication where the username and password are both 'admin':
1 2curl http://localhost:8095/crowd/rest/admin/latest/directory/atlassian%20crowd/user?search=smith -u admin:admin
An error condition will return an HTTP error code as described in the Atlassian REST Guidelines.
You will use the standard HTTP methods to access Crowd via the REST APIs. Please refer to the resource descriptions to see the HTTP methods available for each resource.
Deprecated - Crowd Admin REST Resources
Overview of the Crowd REST APIs
Crowd Developer Documentation
Rate this page: