Skip to content
ShiftSpace edited this page Sep 13, 2010 · 4 revisions

The ShiftSpace REST API specification is directly inspired by the CouchDB HTTP REST API. This document is intended for developers. Developers who would like to reimplement the backend atop another language and database will find this document particularly useful. In addition to this document developers should look at the ShiftServerTest suite in the repository to test the validity of their implementation.

Terms

When we refer to the “user” we mean the logged in user. For clarity we use the capitalized form for the document type even when referring to instances of that document type.

Return Types

Data

{data: ... }

Ack

{message: "ok"}

Error

{error: messageString, type: errorTypeString}

Document Types

User Spec
Shift Spec
Stream Spec
Event Spec
Permission Spec
Group Spec

Error Types

  • AlreadyLoggedInError
  • AlreadyLoggedOutError
  • InvalidUserNameError
  • IncorrectPasswordError
  • UserNotLoggedInError
  • NoEmailError
  • MissingUserNameError
  • ShortUserNameError
  • UserNameAlreadyExistsError
  • MissingPasswordError
  • MissingPasswordVerifyError
  • PasswordMatchError
  • FollowError
  • UserDoesNotExistError
  • PermissionError
  • ResourceDoesNotExistError
  • NoDataError
  • CreateEventError
  • CreatePermissionError
  • AlreadySubscribedError
  • NotSubscribedError
  • AlreadyBeingNotifiedError
  • NotBeingNotifiedError