EntityBroker support for Profile2

EntityBroker support for Profile2

For full descriptions and info on how to use these entities, see http://your.sakai.server/direct/profile/describe

Since v1.2

Profile feeds:
/direct/profile/{userid} [xml | json]
/direct/profile/{userid}/minimal [xml | json]
/direct/profile/{userid}/academic [xml | json]

Formatted profile feeds:
Returns a HTML representation of the profile, with image like a business card, fully div'd and styled ready for further styling or for use directly
/direct/profile/{userid}/formatted
/direct/profile/{userid}/minimal/formatted
/direct/profile/{userid}/academic/formatted

Profile image:
/direct/profile/{userid}/image
/direct/profile/{userid}/image/thumb

Connections:
/direct/profile/{userid}/connections [xml | json]

Privacy record:
/direct/profile-privacy/{userid} [xml | json]
Once logged in, can request anyone's record.

Preferences record:
/direct/profile-preferences/{userid} [xml | json]
Once logged in, can request anyones but only get the public bits like email notification settings. If logged in and request own, get full record.

Status record:
/direct/profile-status/{userid} [xml | json]
Once logged in can request anyones status but their privacy settings might restrict it so you might get nothing.

For the New and Edit entities you can only update/create a record when logged in as the user you want to update/create the record for.

Since 1.3.10

You can now append ?siteId={siteId} to the profile image entity provider to list an optional site you want to check permissions for. So if an instructor has the roster.viewofficialphoto permission in that site then they will be able to see the users' image.

Since v1.4

Direct links:
/direct/my/profile - takes you to your own profile
/direct/my/profile/{userid} - takes you to the view of userId's profile. Could be same as logged in user or different
/direct/my/messages - takes you to your messages page in Profile2
/direct/my/messages/{threadid} - takes you to a specific thread view of the messages page in Profile2
/direct/my/connections - takes you to your connections page in Profile2

Connection actions:
/direct/profile/{userid}/requestFriend?friendId={friendUserId}
/direct/profile/{userid}/removeFriend?friendId={friendUserId}
/direct/profile/{userid}/confirmFriendRequest?friendId={friendUserId}
/direct/profile/{userid}/ignoreFriendRequest?friendId={friendUserId}
/direct/profile/{userid}/friendStatus?friendId={friendUserId}

Since v1.5

Profile image (more endpoints):
/direct/profile/{userid}/image/avatar
/direct/profile/{userid}/image/official