I am creating a WCF webservice with WcF Authentication Service and the first set of functions I need is to manage an inbox for a client. The client will be determined by the authentication.
This is my attempt at a RESTful design of the API:
https://api.mydomain.com/v1/inbox/messages (GET)
Returns a page of results in the inbox with an optional search filter applied
- Count - number of records per page
- Page - page to start on
- Sort - (optional) field to sort on
- Search - (optional) text to search for
https://api.mydomain.com/v1/inbox/mark (POST)
Marks one or more messages read or unread
- Action - MarkRead or MarkUnread
- MessageIDs - list of Message IDs to mark
https://api.mydomain.com/v1/inbox/archive (POST)
Archives one or more messages
- MessageIDs - list of Message IDs to archive
Am I doing this right? If not, what would be a better way to design this interface?