BBM Social Platform – Drawing Users in with the Profile Box



BlackBerry® Messenger (BBM™) is more than just chat! With the release of the BBM Social Platform, we have released a comprehensive set of tools to easily add the power of BBM to your app. This blog post is one in a series focusing on how to easily add social networking features to your app – and there’s no better time to use this knowledge to update your app so that it’s ready for submission to the 2011 BlackBerry® Developer Challenge (particularly the Most Addictive social app using the BBM Social Platform category).

People love to share their accomplishments with their peers. You can design your app to incorporate levels of recognition for various accomplishments by use of some sort of award (e.g. badge, statement, icon, trophy, et cetera). Incorporating awards in your app can be a great way to enable users to promote your app to their peers.

Awards generally consist of an icon and a text string and should convey why they were awarded. The BBM Social Platform easily enables achievement sharing as can be seen in the screenshot below, where you can specify the icon and text for the achievement. The platform then automatically groups them under your application’s custom profile box.

BBM profile box

If achievements are not a good fit for your application, there are plenty of situations where users have content that they want to share with their friends that may be more suitable in their profile box as opposed to their status message. This could include their current location as a user travels, the current song a user is listening to, or the current book a user is reading. Other use cases include apps that leverage other platform services; for example, apps that are using BlackBerry Push Service may want to post updates for things like a win from a favorite sports team or an alert for extreme weather conditions. Apps that are using Payment Service for in-app purchase may want to allow the user to share items they bought which may encourage other users to purchase the same items. Alternatively, the achievements themselves, may not necessarily be application achievements but rather personal achievements, such as achieving a fitness or weight loss goal, a career goal, or even a financial goal. The possibilities are endless – and I’m sure you can find a way to leverage this feature in your application!

As a developer, all you need to do is pass an optional (but highly recommended) icon and a string to the platform and, provided that the user has given your app permission to post, the profile box will appear under your app for that user. The profile box is visible to all BBM users whether they have the app or not. Any user who clicks the box without having the app installed will be prompted to download it, expanding your user base through viral distribution. Users who already have the app installed will be prompted to launch it, increasing user engagement.

In the screenshot above, you can see that Nicole has a profile box entitled “Always Happy!” letting everyone know that the application (in this case the BBM SDK Demo) has seen fit to award her with this achievement. The code to accomplish this is seen below in Java® and BlackBerry® WebWorks™.


UserProfile userProfile = platformContext.getUserProfile();
UserProfileBox profileBox = userProfile.getProfileBox();
if (profileBox.isAccessible()) // Ensure that we have permission to access the box
	// Each icon used by your application must have a unique ID
int iconId = 1;
EncodedImage icon = EncodedImage.getEncodedImageResource("smiley.png");
profileBox.registerIcon(iconId, icon);
profileBox.addItem(iconId, “Always Happy!");
// A third parameter, cookie (String), can be added to give your app context when launched via the BBMPlatformContextListener listener.

BlackBerry WebWorks

// Add an item with icon, text, and a cookie
var iconID = { id:1, uri:”local:///profilebox/smiley.jpg”};
var options = {text:”Always Happy!”, iconId:iconID};

To access the tools and get information about other features of the BBM Social Platform, visit our BlackBerry Messenger Developer site. To access the complete sample app demonstrating the code shown here, check out the Knowledge Base article “BBM Social Platform – Drawing Users in with the Profile Box”.

Join the conversation

Show comments Hide comments
+ -