ProjectSpaces API

This serves as documentation for the Beta version of ProjectSpaces's API. If you need additional information please feel to contact our support team.

The base URL for the API would correspond to the PS instance being queried or modified, ie http://myprojects.projectspaces.com/. The API itself is a REST-based interface using well-formed XML payloads to represent Projectspaces records.

To access your API key, login to your ProjectSpaces account and click the Manage: "all projects" link at the top of the screen.  Then click the "Customize" link found just below the tabs for one of your projects.  Finally on the next page is a link for "ProjectSpaces API."  Here you can generate API keys for use in the methods detailed below.

User Methods


Listing Users

Queries the instance for a list of users, optionally filtered by project or organization.

URL & Method GET /api-1.0/user/list/
Parameters: (required) key - api key
(optional) project_id - integer id of a project in the instance.
(optional) organization_id - integer id of an organization in the instance
Returns:
Returns a collection of user profiles (see Viewing User Details below)

Viewing User Details

Returns information about a specific user.

URL & Method GET /api-1.0/user/detail/
Parameters: (required) key - api key
Also one of the following is required:
id - user's internal integer id
email - user's email address
username - user's login name
Returns:
Returns an XML structure representing the User's profile and includes all fields from the user's profile, the project's that the user belongs to, and the groups the user belongs to.

Creating a User Profile

Updates a user's profile, which includes their name, email, and other contact information.

URL & Method
POST /api-1.0/user/create/
POST Fields The following fields should be passed via POST to create a user:
Required:
key - api key
(string) - email, username, password*
Optional
(string) : name, first name, last name, title, email, organization, address1, address2, city, state, zip, country, phone, fax, password*, mobile_phone, home_phone, username, profile
(integer) : organization id (see List Organizations)
* password field will be encrypted one-way using mysql's CRYPT function
Returns: Returns an XML structure with the integer id of the new record.

Updating User Profile

Updates a user's profile, which includes their name, email, and other contact information.

URL & Method
POST /api-1.0/user/update/
Parameters: (required) key - api key
Also one of the following is required:
id - user's internal integer id
email - user's email address
username - user's login name
POST Fields Any field that should be updated must be passed via POST. If a field is omitted, it will not be changed. To clear a field, pass in an empty string. These fields include:
(string) : name, first name, last name, title, email, organization, address1, address2, city, state, zip, country, phone, fax, password*, mobile_phone, home_phone, username, profile
(integer) : organization id (see List Organizations)
Returns: Returns boolean true or false.

Adding a User to a Project

Add a User to a project.

URL & Method POST /api-1.0/user/addToProject/
POST Fields: All of the following is required:
key - api key
user_id - user's internal integer id
project_id - integer id of the project to add user's to
access_level - user's role on the project 'project admin', 'content editor', or 'guest'
groups - and additional list of project group names to add the user to. If a group does not exist, it will be created.
Returns:
Returns boolean true on success or false on failure.

Removing a User from a Project

Remove a user from a project and from all groups associated to that project.

URL & Method
POST /api-1.0/user/removeFromProject/
POST Fields: All of the following is required:
key - api key
user_id - user's internal integer id
project_id - integer id of the project to add user's to
Returns: Returns boolean true on success or false on failure.

Organization Methods


Listing Organizations

Queries the instance for a list of organizations, optionally filtered by project.

URL & Method GET /api-1.0/organization/list/
Parameters: (required) key - api key
(optional) (integer) project_id - id of a project in the instance
Returns: Returns a collection of organization records (see Viewing Organization Details below)

Viewing Organization Details

Returns information about a specific organization.

URL & Method GET /api-1.0/organization/detail/
Parameters: The following is required:
key - api key
id - (integer) organization's internal id
Returns: Returns an XML structure representing an Organization Record and includes all fields from the organization model, a list of user's associated with the organization, and a list of projects associated with the organization.

Creating an Organization Record

Creates a new organization record in the repository.

URL & Method POST /api-1.0/organization/create/
POST Fields The following fields can be passed to create an organization:
Required:
key - api key
(string) - name*
Optional
(string) - address1, address1, address2, city, state, zip, country, phone, fax, website
Returns: Returns an XML structure with the integer id of the new record.

Updating an Organization Record

Updates an organization record, which includes the entity's name, website, and other contact information.

URL & Method POST /api-1.0/organization/create/
POST Fields The following fields can be passed to update an organization. If a field is omitted, it will not be changed. To clear a field, pass in an empty string.
Required:
key - api key
(string) - organization's internal id
Optional
(string) - address1, address1, address2, city, state, zip, country, phone, fax, website
Returns: Returns an XML structure with the integer id of the new record.

Project Methods


Listing Projects

Queries the instance for a list of projects, optionally filtered by user or organization.

URL & Method GET /api-1.0/project/list/
Parameters: (required) key - api key
(optional) organization_id - integer id of an organization in the instance.
(optional) user_id - integer id of a user in the instance
Returns:
Returns a collection of project records (see Viewing Project Details)

Viewing Project Details

Returns information about a specific organization.

URL & Method
GET /api-1.0/project/detail/
Parameters: (required) key - api key
Also one of the following is required:
id - project internal integer id
Returns: Returns an XML structure representing an Organization Record and includes all fields from the organization model, a list of user's associated with the organization, and a list of projects associated with the organization.

Creating a Project Record

Creates a new Project record in the repository.

URL & Method
POST /api-1.0/project/create/
POST Fields The following fields can be passed to create a project:
Required:
key - api key
(string) - name*
Optional
(string) - address1, address1, address2, city, state, zip, country, phone, fax, website
Returns: Returns an XML structure with the integer id of the new record.

Updating a Project Record

Updates a Project record, which includes the project name, status, and description.

URL & Method POST /api-1.0/project/create/
POST Fields The following fields can be passed to update a project. If a field is omitted, it will not be changed. To clear a field, pass in an empty string.
Required:
key - api key
(string) - project's internal id
Optional
(string) - welcome headline, description
(string) - status can be one of 'open', 'closed', or 'archived'
Returns: Returns an XML structure with the integer id of the new record.
.