brainCloud Product Updates logo
Back to Homepage Subscribe to Updates

Product Updates

See the latest features, improvements, and product updates

Labels

  • All Posts
  • release
  • Announcement
  • Improvement
  • Fix
  • blog

Jump to Month

  • March 2025
  • January 2025
  • November 2024
  • September 2024
  • May 2024
  • February 2024
  • November 2023
  • September 2023
  • July 2023
  • April 2023
  • March 2023
  • February 2023
  • January 2023
  • December 2022
  • November 2022
  • July 2022
  • June 2022
  • April 2022
  • March 2022
  • February 2022
  • December 2021
  • November 2021
  • October 2021
  • September 2021
  • June 2021
  • May 2021
  • March 2021
  • November 2020
  • September 2020
  • July 2020
  • April 2020
  • February 2020
  • December 2019
  • November 2019
  • September 2019
  • June 2019
  • May 2019
  • February 2019
  • December 2018
  • October 2018
  • July 2018
  • March 2018
  • January 2018
  • December 2017
  • October 2017
  • July 2017
  • June 2017
  • April 2017
  • March 2017
  • February 2017
  • January 2017
  • October 2016
  • August 2016
  • July 2016
  • June 2016
  • May 2016
  • April 2016
  • March 2016
  • January 2016
  • December 2015
  • November 2015
  • October 2015
  • September 2015
  • August 2015
  • July 2015
  • June 2015
  • May 2015
  • April 2015
  • March 2015
  • February 2015
  • January 2015
  • December 2014
  • November 2014
  • October 2014
  • September 2014
  • August 2014
  • June 2014
  • May 2014
Changelog byAnnounceKit

Create yours, for free!

releaseAnnouncement
5 years ago

Release 4.0 is Live!

Release Highlights

RTT Official Launch!

With 4.0, we officially take the beta label off of RTT, and release it to the world!

As you know, RTT adds a bi-directional channel for real-time communications to the brainCloud platform, greatly expanding the types of experiences that can be delivered without additional tech.

The list of great new features that RTT has already enabled includes:

  • Real-time Events
  • Online Chat
  • Real-time Messaging
  • Online Matchmaking
  • Lobbies

For 4.0 we are pleased to add:

  • Async Matches
    • we’ve RTT-enabled Async Matches. So now you can use the Async API in real-time! (Don’t worry, you can still use it offline if you would like).
    • Oh, and while we were at it, we’ve made async matches automatically delete themselves after 90 days. So your apps no longer have to do the cleanup manually if they don’t want to.
  • Integrated Hosting
    • we have integrated our new Hosting features with our RTT Lobby service

Plus we have officially launched our RTT-enabled Plus subscription plans that make these great features available at all usage levels.

Hosting (beta)

Did we mention hosting?

In brainCloud 3.8, we introduced support for custom Room Servers (i.e. game or experience servers) that integrate with our Lobby Service for matching up users.

The cool thing is that you have full freedom to custom code your Room Server yourself, in any technology. The not-as-cool thing was that you had to host (or arrange for hosting) of the servers yourself, plus you also had to code up a Room Server Manager, for us to integrate with (it was responsible for spinning up your servers and managing them). Suffice to say, that’s a bit more complicated than most people want.

So for 4.0 we’re pleased to announce that we can host your custom Room Servers for you – all managed by our built-in Room Server Manager. It’s truly as simple as giving us the name of the Docker image to use for your service. We handle the rest, spinning up servers and containers as needed – and charging you for the server cycles used.

Relay Servers (beta)

Even simpler than hosting a custom-built Room Server, is hosting our new built-in Relay Servers!

We have used our new RTT + Hosting infrastructure to add built-in Relay Server support to brainCloud.

Now building a real-time or near-real-time multiplayer experience on brainCloud is as simple as:

  • Configure the relay servers on the new Design | Cloud Code | My Servers page
  • Connect the relay server to your lobby via the Design | Multiplayer | Lobbies page
  • Utilize our new Relay Communications APIs in your Unity apps!  (note – Unreal and other libraries will be supported soon!) 

New Billing Plans

With all this new infrastructure, there has to be some way to pay for them! Sorry! 🙂

But it’s not all bad news. Not only have we launched new Plus plans that add support for RTT and Hosting, but we are also introducing new lower-cost Lite plans! Plus we have significantly lowered the API usage costs (as you scale up) across all plans!

Also note that we have added a new Development Plusplan, which is a $5 / month plan that gives your apps in development access to Hosting features (i.e. hosted Room Servers and Relay Servers).

For full details on our updated billing plans, see our billing announcement.

And a bunch more!

And that’s not even all of it. brainCloud 4 also brings:

  • [New!] brainCloud Bombers RTT
    • Our new example game fully demonstrates RTT and Relay Servers
    • Play it on Steam!
  • [New!] Forums!
    • brainCloud now has forums for our development community. Check them out here!
  • [Updated!] Tic-Tac-Toe example
    • Now supports the new RTT-enabled Async Match API
  • DataStream Enhancements
    • Our DataStream service now pushes more events, including:
      • Tournament events
      • Group events
      • Chat events
      • Lobby Events
  • Updated Facebook Integration
    • We now support Graph API 2.9

And be sure to check the API Changes below for a smattering of new APIs.  


Portal Changes

We’ve made the following updates to the portal:

Team

  • Home | Start
    • We’ve added a link to the new brainCloud Forums!
  • Manage | Apps
    • Go Live! reworked to support the new V4 billing plans
    • New Change Plan action menu item allows you to dynamically swap the plan for your app at any time
    • To terminate service for your app, just choose Delete from the action menu. The system will now automatically expire your subscription. You will be invoiced at the end of the month, on a pro-rated basis, for the amount of service your app used.
    • We have also added a new Plan column to the display to make it easier to tell exactly which plan your app is using

Design

  • Core App Info | Advanced
    • Restore Checkpoints – brainCloud creates a checkpoint each time you deploy to an app and/or import to it. This new feature allows you to easily restore an app’s meta-data to a recent checkpoint.
  • Authentication | Email Authentication
    • brainCloud can now send confirmations to users after they have successfully changed their passwords. Configure the emails here.  
  • Cloud Code | My Servers
    • This is the screen formerly known as “S2S Config”
    • The screen has been expanded to support the configuration of multiple server types:
      • Custom Servers – these are the old S2S Configs-style servers
      • Relay Servers – deploy your own set of brainCloud Relay Servers
      • Room Servers – configure brainCloud to host your custom Room Server images
      • Room Server Managers – for integrating with a custom-developed, externally-hosted Room Server Manager
  • Multiplayer | Lobbies
    • Room Server selection updated to use the new My Servers configurations (instead of referring to servers from Web Services, which 3.X did) 

Monitoring

  • User Monitoring | User Summary
    • You can now trigger the sending of a password reset email to Universal Identity users (if they have a contact email stored against their profile). Click the mail button to send.
  • User Monitoring | Recent Users
    • The New column has been replaced by a new “Logins” column – which shows the number of times that user had logged in. Much more informative!

Reports

  • Reporting | Analytics
    • We have added a new section that reports the # of Dormant Users in your app. Dormant Users are defined as users who have not logged into your app in 180 days.
  • Reporting | API Usage
    • We have added new RTTand Hosting usage statatistics

General

  • DOCS top menu
    • We’ve added a Forums link to the DOCS menu. Hmm, maybe we should rename the menu to HELP?

API Changes

Important: The 4.0 libraries (especially Unity) contain changes that will be breaking for some apps. As always, the older libs continue to work for existing apps. We recommend all devs upgrade at their earliest convenience. 

The following changes/additions have affected the brainCloud API:

  • Authentication
    • New ResetUniversalIdPassword() and ResetUniversalIdPasswordAdvanced() calls allow users to reset the passwords for their Universal IDs (via an email sent to them). Note that the contact email of the user must be set for this to work.
  • Cloud Code Bridge
    • Added new GetSessionCacheObject() and SetSessionCacheObject() methods for saving custom objects in the user session. This is quite helpful if you want to cache frequently accessed data for use by multiple cloud code scripts.
  • Global Statistics
    • Support for new MIN and MAX operations. Very useful for keeping track of the personal high scores of a player.
  • Lobby
    • New CancelFindRequest() cancels an asynchronous FindLobby request.
    • New JoinLobby() call allows a user to skip matchmaking and immediately join the specified lobby instance (potentially with party members).
  • Player Statistics
    • Support for new MIN and MAX operations. For details, see the updated Statistics Grammar page.
  • RTTService
    • Migrated the RTT Initialization methods (EnableRTT(), RegisterRTTChatCallback(), etc.) to the RTTService for better API coherency

We have also deprecated the following methods:

  • Wrapper
    • Removed the deprecated singletonmode
    • Removed EnableRTT(), RegisterRTTChatCallback(), etc. – and moved them to the RTT Service
  • Client
    • Removed EnableRTT(), RegisterRTTChatCallback(), etc. – and moved them to the RTT Service

Finally, a few miscellaneous changes have been made:

  • We are now wrapping all 3rd party libraries in a brainCloud namespace in the Unity / C# libraries
  • We have renamed the Settings plugin in the Unity library

For more details and migration steps, see the V4 Client Changes blog post.


Miscellaneous Changes / Fixes

  • Updated libraries
    • All libraries have been updated to include all 4.0 APIs, with the exception of the Relay Service
    • The new Relay Service APIs are currently available in the Unity / C# libraries only. Unreal + other libraries will follow soon.
  • Documentation updates
    • TBC
  • Important Fixes
    • BCLD-4679 – Duplicate leaderboard config issues (leaderboard Duplicate, new “MOCK” division set instance creation) if Enrol or Announcement minutes and called when rotation minutes remaining < (Enrol + Announce + Buffer) minutes
    • BCLD-4651 – Permissions issue with groups – ReadGroup() vs. ReadGroupData() with other=1
    • BCLD-4415 – [Documentation] – More documentation support for the parameter ‘isOpenGroup‘ for the ‘AutoJoin’ operation
    • BCLD-4650 – Issue in the UpdateGroupACL cloud code proxy
    • BCLD-4645 – UK Area code is missing from Authy
    • BCLD-4494 – Add documentation for ‘UpdateEntityIndexedId’ call in both API and S2S Explorer in the API Reference Docs.
    • BCLD-4524 – Add Server Session support for Leaderboard Service operations that are currently only supported for Player Session
    • BCLD-4337 – Sending null match state on create Async Match should not clobber the summary!
    • BCLD-3192 – ‘GetSharedEntityForProfileId’ returns positive log response without entering the profileID
    • BCLD-4307 – Improve speed of ChildEntity – UpdateEntity using updateFields instead of update
    • BCLD-4293 – Operations are not alphabetized on the APIHooks screen – should be
    • BCLD-3250 – PostScoreToLeaderboard has wrong name in Javascript example
    • BCLD-3232 – Client API – ‘ReadServerTime’ Operation returns a definite response, despite entering incorrect app ID
    • BCLD-4483 – DataStream Push Notifications – new safe mode to reduce excessive DataStream-related usage charges
    • BCLD-4499 – PostTournamentScoreWithResults is missing in the Unreal Client
    • BCLD-4503 – resetCurrency is missing from the virtual currency service
    • BCLD-4448 – Defect being seen in async match profile urls
    • BCLD-4498 – If a company is in a Suspended state, they are unable to edit their billing information to get out of that state…
    • BCLD-4488 – User can create Leaderboards with spaces and special characters using the ‘CreateLeaderboard’ API call
    • BCLD-4449 –  User can create Leaderboard with spaces and special characters using the ‘PostScoreToDynamicLeaderboard’ API call.
    • BCLD-4454 – StartTime matches Registration time for Monthly Tournament in ‘GetTournamentStatus’ call
    • BCLD-4228 – API: Updated player names and picture urls not reflected in turn-by-turn match summary
    • BCLD-4358 – Inconsistency between comms initialize parameter order and wrapper order for java android and desktop
    • BCLD-3200 – JSON error when saving a quest with an already existing name
    • BCLD-4268 – Attaching an email identity overwrites an exisiting contact email
    • BCLD-3470 – Monitoring -> Global Entities -> Bulk options -> Export should be disabled when there are no global entites for the app
    • BCLD-4294 – Missing data in the new AppStore VerifyPurchase() call…
    • BCLD-2788 – Portal: deleting an image in [Achievements] without saving the achievement causes a missing image
    • BCLD-3968 – Errors handing $and in Where clauses
    • BCLD-3969 – getRandomEntitiesMatching sometimes returns 0 items for max 1, even when items match
    • BCLD-3977 – Log processor is incorrectly attributing mongo log collection write failures (too to large log sizes) to a particular app
    • BCLD-3927 – Clicking on resetpassword email link twice gets user to a valid looking reset password screen
    • BCLD-4111 – Design Portal should not be able to configure invalid Steam product info
    • BCLD-4105 – Add the missing readUserStatsSubset() cloud code method
    • BCLD-4108 – Global Entities: allow filtering and sorting on entityId, version, and expiresAt
    • BCLD-3989 – File Storage being reported on the API Usage page appears to always show 0.0
    • BCLD-4118 – When we do a SwitchToChildProfile(), we should add a login log entry for the child profile
  • Plus miscellaneous fixes and performance enhancements…
Announcement
5 years ago

brainCloud 4 Billing Plans

The Plan plan

brainCloud 4 is fast approaching – and it is bringing a slew of new capabilities to the platform, including the official release of RTT (Real-time events, Chat, Messaging, Online Matchmaking, Lobbies, Presence and more!) as well as brand-new Hosting capabilities (Relay Servers and Room Servers).

As these new capabilities bring additional costs to running our infrastructure – we will be introducing revised pricing plans in coordination with brainCloud 4.

The good news is that if you aren’t using these features, nothing much changes — in fact, we’ve revised the API pricing tiers downward, so your overall costs should go down!

For the folks taking advantage of these great new capabilities, we have added new Plus plans, and have worked hard to keep the pricing reasonable and in-line with the costs to provide the service.

We are also introducing new discounted Lite plans – perfect for apps with lower usage requirements.

V4 Plans

When 4.0 launches, the new plan lineup will look like this:

  • Development (Free) – access to all features, except hosting. Limited to 100 DAU, 1000 accounts. Includes 10 CCx.
  • Development Plus! ($5 /month) – All features, including hosting. Limited to 200 DAU, 2000 accounts. Includes 20 CCx.
  • Lite ($15 /month) – Core features. Includes 1M API.
  • Lite Plus ($25 /month) – Core features + RTT + Hosting. Includes 1M API, 50 CCx.
  • Standard ($30 /month) – Core features. Includes 6M API.
  • Standard Plus ($50 /month) – Core features + RTT + Hosting. Includes 6M API, 100 CCx.
  • Business ($99 /month) – Core + Enterprise features. Includes 10M API.
  • Business Plus ($199 /month) – All features. Includes 15M API, 250 CCx.
    We are confident that we have a plan to fit every app!

API Usage

As we were putting together our new set of plans, we decided to simplify and standardize the API Usage Tier Pricing.

All V4 plans use the same discounting tiers as they scale (it used to differ by plan). So no matter what plan you start with, as you get to 15M total API calls for the month, the cost per M drops to $10.00.

One side effect of this standardization is that the cost of additional usage for Business Plan customers now starts at $10.25 / M API, instead of $10.00 / M API from the old plan. To make up for this, we have bumped up the Business Plan to include 10M API for free (instead of 9M)  – so it is a net win.

We have also made our API Usage pricing tiers more aggressive. In the old plans, you needed to hit 300M+ API calls to get to $9.90 / M pricing. In the new plans, we drop the price to $9.75 / M API at just 25M+ API calls.

We have accelerated the API discounting across the board, resulting in savings of  5-10% at high usage levels.

New Plus Plans

The new Plus plans make RTT and Hosting features available to apps at all usage levels.

Features available to Plus plans include:

  • Async Match with RTT
  • Chat
  • Lobbies
  • Online Matchmaking
  • Presence
  • Real-time Events
  • Real-time Messaging
  • Relay Server Hosting
  • Room Server Hosting

And more!

We have worked hard to keep the incremental costs of the Plus plans low – so that as many developers as possible can integrate these great new features into their apps.

Note – Plus plans are subject to RTT Usage and Hosting Usage costs. More details in the sections that follow.

New Lite Plans

A frequent request has been for lower-cost, lower-usage plans.

We are pleased to present our new Lite and Lite Plus plans. These plans offer the all the same features as their Standard plan equivalents, but at lower 1M API usage levels.

These plans, which start at just $15 and $25 /month respectively, are great for indie developers, the development of smaller experimental apps, and even for more ambitious apps in the long-tail phase of their product lifecycle.

RTT Usage

brainCloud’s RTT features require a nailed-up TCP or WebSocket connection for every client device. The costs to brainCloud are in maintaining connections (CCx) from our servers, and delivering the millions of real-time events to your users as they participate in chat, messaging, lobbies, etc.

To account for this utilization, we simply convert these resources to API counts.

Every RTT plan comes with a number of Concurrent Connections (CCx) that are free per hour. For example, the Standard Plus plan includes 100 CCx. That means that a peak of 100 Users can be concurrently online without additional CCx usage fees. Assuming your average play session is 12 minutes, that might actually equate to 500 users per hour, or 12K users per day. And that’s if RTT is enabled for the full time that users are in your app. Optimize your app to only initialize RTT when you need it, and 100 CCx could equate to thousands of users per hour.

Above that, apps are charged at a rate of 10 API calls per CCx per hour. So – lets say your app was averaging double that – or 200 CCx. The additional costs would be 100  x 10 API/CCx x 24 hours x 30 days = 720,000 API counts. At ~ $10 / M API, that’s about $7.20 in usage.

The other component of RTT Usage is event delivery. RTT is great for chat and lobby operations – where one operation may fan out to dozens (or thousands) of recipients. That’s great functionality wise – but those deliveries can really add up!

The good news is that RTT is very efficient at delivering events – so we are charging at a bulk ratio of 100:1 – that is, your app is charged just 1 API count for each 100 events delivered!

Hosting Usage

brainCloud now supports hosting of Relay Servers and custom Room Servers. This really opens up the sort of experiences that can be accommodated in a pure brainCloud environment.

The good news is that you aren’t charged for API calls / messaging / etc to your hosted servers — even if the server is one of our Relay Servers (using our new Relay Protocol).

 That said, we do of course need to pass along the cloud costs of hosting the servers, and the data transfer usage associated with it, from the cloud provider.

For pricing, brainCloud is simply marking up the hosting costs by 15%, and adding 1.5 cents per hour for managing the servers.

To help keep costs low, brainCloud will automatically spin up / down servers as required. There are a complete set of parameters that can be customized to allow Teams to fine tune the best balance between server cost and performance. 

And those are the new plans!

Those are the billing changes for v 4.0.

We appreciate that brainCloud’s adherence to elastic pricing can seem a bit complicated. It is certainly more complicated than traditional per-MAU pricing. But in the great majority of cases, it is also much better value.

Our overall goal when designing our pricing models is to ensure that the pricing you are charged reflects the costs that we incur in providing the service.

We feel this approach aligns our interests. The more server resources your apps consume, the higher our costs, and the higher the price to you. But the more efficiently you can build your app, the lower our costs, and the lower the pricing for you. It’s win:win – and we are on the same side!

If you have any questions or feedback, please reach out to us via the Green Chat widget. We are always happy to hear from you!

releaseAnnouncement
6 years ago

Release 3.11 is live!

Release 3.11 provides some key feature requests with some under-the-hood improvements that will be delivered upon in Release 4.0 (coming soon!).

Release Highlights

SendGrid Dynamic Templates

We have updated our Mail APIs and integration code to work with Sendgrid’s new Dynamic Template format, which includes support for Handlebars syntax.

This means that you can:

  • Use Dynamic Templates for brainCloud’s Email Authentication and Tournament Notification 
  • Use Dynamic Templates with brainCloud’s SendAdvancedEmail*() APIs
  • Take advantage of the Handlebars syntax (with substitution, conditions and iterations) in your templates
  • Even send attachments!

And of course, Sendgrid’s legacy templates still work.

Please note – the substitution parameter format of SendGrid’s API for new dynamic templates is different. So if you are using the SendAdvancedEmail*() calls and are changing from legacy → dynamic templates, you’ll need to modify the serviceParams JSON that is provided with the call.

UniversalId Wildcard Searching

If your app supports looking up other users (for friends, challenges, etc), we highly recommend that you identify and lookup users by UniversalId instead of by user name.

UniversalIds are better than user name because:

  • They guarantee uniqueness
  • They are case insensitive
  • Searching is 3 – 5 times faster! (because they are unique, case insensitive, and we anchor all searches at the beginning)

But… until now we really weren’t providing you with enough search flexibility. Which is why we have added some new methods:

  • FindUserByUniversalIdStartingWith() – use for wildcard-like searches
  • FindUserByExactUniversalId() – use for exact searches

And remember, we do provide a handy method that allows your app to use UniversalId’s (to identify/lookup users) without using them as authentication methods – check out AttachNonLoginUniversalId().

A few notes:

  • We have deprecated the old FindUserByUniversalId() – its spec was pretty misleading (looked like an exact search – but performed like a wildcard search – and an unoptimized one at that!). Note – it will still work if your app was already using it.
  • For those of you stuck with already-implemented user name searching, we’ve added some improvements as well: 
    • FindUsersBySubstrName() is now 10-20% faster 
    • FindUsersByNameStartingWith() (new!) is ~50% faster than FindUsersBySubstrName() – so switch to this one if you can! 

Improved Cloud Code Debugging

Good news for you cloud code developers – we’ve added some new smarts to the API Explorer and Cloud Code Editor that makes it a lot easier to trace and debug your scripts!

The two big additions are:

  • Activity Window Logs – log entries that your script creates are now visible in the activity window on the right-hand-side of the Cloud Code Editor and API Explorers
  • Debug Log-level – we have also added a new debug log level that only prints to the Activity Window log. This is perfect for analyzing and debugging your scripts, without unnecessarily clogging up your logs otherwise.
  • New JSON context methods– we have also expanded to provided Logging APIs to provide new methods that allow you to log JSON contexts directly (without stringifying them first)
  • Bridge access– finally, we have added all these new logging methods directly to the bridgefor maximum convenience!

Check out the GIF below to get a feeling for how the new script logging works.

Miscellaneous

Plus a few more shiny features, including:

  • Lobby Event Optimizations – a bunch of the data in the Lobby RTT events was unnecessary – we’ve trimmed it down to be more efficient
  • Faster user name lookups in the Design Portal
  • View WebHooks calls in the Server Logs
  • Filter the Server Logs
  • Export a user’s data from the User Summary page
  • and more!

Portal Changes

Design

  • Cloud Code | API Explorer
    • Activity pane now shows log messages
  • Cloud Code | Scripts | Script Editor
    • Activity pane now shows log messages
  • Segmentation | Segments
    • Page should load faster now

Monitoring

  • Global Monitoring | Server Logs
    • Incoming WebHooks calls are now captured here
    • Added ability to Filter the logs shown by type, source, date, etc.
  • User Monitoring | User Summary
    • Select User– faster searching by user name! ← Popular Customer Request!
    • (beta!) Debug data export – new ability to export a user’s data. Very useful for debugging!

API Changes

Client API

The following changes/additions have affected the client API:

  • Client
    • isRTTEnabled() convenience method added to allow apps to check their RTT state
  • Entity
    • GetSharedEntityListForProfileId()and GetSharedEntitiesForProfileId()now return entityListCount for convenience 
  • Friend
    • New Universal ID searches: 
      • FindUserByExactUniversalId()
      • FindUsersByUniversalIdStartingWith()
    • New name search methods
      • FindUsersByNameStartingWith()
  • Group
    • ReadGroupMembers() – now returns the profile picture URL (if present) for each member
  • Identity
    • SwitchToChildProfile() and SwitchToSingletonChildProfile() cloud code methods have been simplified to align with the client versions of these calls. To clarify, the new methods no longer require you to pass in values for platform, language, etc – these values are all inherited from the current session.

Cloud Code

  • Bridge
    • Added logging calls to the bridge for convenience – LogInfo(), LogInfoJson(), LogWarning(), LogWarningJson(), LogError()and LogErrorJson()
    • Also added new debug log calls – LogDebug()and LogDebugJson(). Note these calls are not available on the logging service itself, because they do write to the persistent logs. 
    • Added new context calls – getScriptName(), getAppName(), and getEnvironmentName().
  • HttpClient
    • Added new PostJsonOffboard() call – for efficient posting of HTTP requests in scenarios where it isn’t necessary to wait for the result
  • Logging
    • Added new JSON-context calls – LogInfoJson(), LogWarningJson(), and LogErrorJson()

RTT (Beta) Events

We have made some small changes to the Lobby events being returned – essentially just removing some redundant / unnecessary fields.

We largely removed:

  • Nested and redundant id information (i.e. nested fields like id, seq, appId, etc.)
  • lobbyTypeDev, settings, connectDataand occasionally members fields from events that didn’t require them 

Note – although RTT is still in beta, we don’t take changes like this lightly. Rest assured, we have reached out to our live RTT customers separately to give them a heads up re: these changes. 


Miscellaneous Changes / Fixes

  • Updated libraries 
    • All client libraries have been updated for this release. Be sure to grab them!
    • We have added additional killswitch code to prevent errant apps from endlessly spamming our servers on authentication failures. As a rule folks, retrying an operation in an endless loop is bad form! Do not do that! 🙂  
  • Updated examples 
    • Unity assets – we have recently updated brainCloud Space Shooter and brainCloud Bombers for Photon on the Unity Asset Store 
  • Documentation updates 
    • Improvements to content and accuracy of code examples 
  • Important Fixes 
    • BCLD-4163 – Presence cloud code proxies missing some methods
    • BCLD-4989 – File storage being reported on API Usage page as 0.0 or NaN
    • BCLD-4139 – Import script issue
    • BCLD-4105 – Added missing readUserStatsSubset() cloud code method
    • BCLD-4112 – Portal not editing / saving Steam IAP products properly in some cases
    • BCLD-4160 – lobbyService.switchTeam() can result in an NPE
    • BCLD-4159 – Improve speed of Use Monitoring – Select User – Search by Name
    • BCLD-4147 – Unable to save rewards in tasks (milestones) embedded in Quests in some circumstances
    • BCLD-4148 – Deleting an embedded task (milestone) from a Quest results in an orphaned Milestone
    • BCLD-4108 – Global Entities should allow filtering and sorting on entityId, version and expiresAt
    • BCLD-4118 – When performing SwitchToChildProfile(), a login log entry is now added for the child profile
    • BCLD-3969 – getRandomEntitiiesMatching() sometimes returns 0 items for max 1, even when items match – fixed.
    • BCLD-3267 – getChannelId() should confirm that a channel exists before returning the constructed id
    • And many, many more! 
  • Plus miscellaneous fixes and performance improvements
releaseAnnouncement
6 years ago

Release 3.10 - Holiday Edition!

Release 3.10 is a modest release that fulfills a number of customer requests before the holidays. We hope that you find something you like!

Release Highlights

Chat Profanity Filter

We have added profanity filter support to our chat service. With it, you can automatically filter profane words (across multiple languages), as well as email and web urls from chat conversations. Offending word segments will be replaced with the character that you specify.

You can configure this via the Design | Messaging | Chat page in the Design Portal. Note that you must have signed up for WebPurify and configured it via the Design | Integrations | Manage Integrations page first.

Email Validation Enhancements

We have added two new features to make incorporating email verification into your apps easier.

  • Validation hooks – brainCloud can now automatically trigger a cloud code script to run when a user clicks on the validation URL included in the verification email. The script to be called is configured with the Design | Cloud Code | API Hooks page – just choose the EmailAuth service and assign scripts to Post and/or PostFail.
  • Continue button – we have also added a configurable [Continue] button to the web screen that pops up for email validation. This button is configured to send the user to the web URL of your choice when clicked. Very useful if you want to bring the user to your site login (or back into your app) after validating their email.

The continue button is enabled by configuring a validation hook script (see above) that returns results in the following format when run:

{

  "action": "continue",

  "label": "Continue",

  "hover": "Return to Login",

  "targetUrl": "http://myapp/login"

}

 

Hand-off API

There are times when it is handy to share a brainCloud login when traversing across multiple software systems (or apps) in real-time. For example, a user logs into App A, but to perform some action needs to be passed to a separate user flow in App B.

Accomplishing this in brainCloud is possible, but challenging. All three potential solutions have drawbacks:

  1. Passing the user’s credentials from one system to another <- major security concern
  2. Asking the user to login again <- usability issue
  3. Passing the active brainCloud sessionId to the other system <- doesn’t work due to packetId synchronization

So – we have created a new way to do this, which we call Handoff. The idea is pretty simple:

  1. App A: The user is logged into brainCloud normally, and a session created
  2. App A: The app calls the new CreateHandoffId() method, that creates a temporary handoffIdand securityTokenthat can be used to remotely log that user in. This id + token is only valid for a short period (~ one hour) and can only be used once.
  3. App A: The handoffId + securityToken is passed to the other app/system. How that is done is app-specific. It could be as simple as passing it along in a URL. You could even separate the data – send the id in an email with a clickable link, but text the user the token so that they have to manually enter it <- useful for more security intensive use cases
  4. App B: The app calls the new AuthenticateHandoff() API call to log the user into brainCloud

Voila!

Pro-tip: Hand-off can be combined with the Email Validation Enhancements above to redirect the user back into your app’s registration flow!

Non-login Universal IDs

The brainCloud profile nameproperty is a handy way for users to identify themselves. It is used throughout brainCloud (and brainCloud apps) for displaying player names in leaderboards, chat, lists of friends, etc.

Although handy, the nameproperty does have some inherent limitations:

  1. Names are not unique. Like in the real world, multiple people can have the same name.
  2. Searches can be slow. Searching through non-unique collections is slower.

We have long-advocated that developers assign Universal Identities to user accounts to easily enforce uniqueness and make them more searchable. To keep users from being able to inadvertently login via these ids, a generated GUID can be used as the password.

We have now taken the next step and implemented direct support for non-login Universal IDs.

Usage is simple:

  • Call AttachNonLoginUsername( ) to create a Universal Identity and attach it to the current profile. It will return an error if the username is not unique.
  • Later you can call UpdateUniversalIdLogin() to update the username if the user desires
  • To search for the user via the api, use GetProfileInfoForCredential( “anId”, “Universal”)
  • Finally, in the Design Portal search by Universal ID — not by Name! — to find the user.

Pro-tip: brainCloud just uses a string for universal identities. They are pretty free-form (i.e. can have spaces, in front, in back, special characters, etc.) If you want to be more restrictive, be sure to filter them and apply your restrictions before creating them!

 

S2S Library

We have always had a handy https-based S2S (Server-to-Server) API – but up until now we’ve left the heavy lifting of calling it to your custom server code.

Enter our new S2S Client Javascript libraries! You can grab them from our GitHub repo, or from npm.

They are fairly minimal – you still need to specify raw service and operation, together with a properly constructed data object for the parameters (use the S2S Explorer as your guide to how to format things). We just handle the drudgery of forming the actual requests and sending them to brainCloud servers. And we use the more optimal S2S session-based protocol – so your communications are more efficient and cost you less! It’s win-win!

Server Logs

Finally, we are working to make brainCloud’s server-to-server interactions a lot more understandable / debuggable.  As a first step in that, we are now logging all incoming S2S requests to a new log that can be viewed on the Monitoring | Global Monitoring | Server Logs page.

This page is currently limited to only a maximum of the last 100 requests. It will be enhanced significantly in upcoming releases.


Portal Changes

Design

  • Cloud Code | API Explorer
    • There are new API Calls available in the Authentication, Identity, and HttpClient services.
  • Cloud Code | API Hooks
    • Added the new EmailAuth hook for automatically triggering scripts when a user clicks on the link in the validation email.
  • Messaging | Chat
    • Added new Profanity Filtering config settings. Note that you need to configure the WebPurify integration from the Integrations | Manage Integrations screen first.
  • Segmentation | Segments
    • Improved the performance of retrieving the list of Segments

Monitoring

  • [New!] Global Monitoring | Server Logs
    • New page collects S2S requests and responses for easier debugging of server scenarios
    • Note – currently a beta page – will be enhanced soon with pagination features (and later with filtering!)

 


API Changes

Client API

The following changes/additions have affected the client API:

  • Authentication
    • New Handoff Authentication call added: AuthenticateHandoff()
  • Identity
    • New API for creating handoff ids: CreateHandoffId()
    • New AttachNonLoginUniversalId() API has been added.
  • HttpClient
    • Added a new PostJsonResponseText() method for those weird APIs slack that post in JSON but return the result as a string? I mean really – who does that? 🙂
    • The existing PostJsonResponseJson() method also more gracefully handles text-only returns – enclosing them in a JSON object with the text in a field called jsonString.

Miscellaneous Changes / Fixes

  • Updated Client libraries
    • The following libraries have been updated with the new 3.10 feature set:
      • Unity + C# libraries
      • Java libraries
      • Javascript libraries
      • Objective-C + Swift libraries
      • Unreal
      • ActionScript (minus RTT features)
    • Additional notes
      • Javascript
        • We have combined our two node.js packages (one for node.js server, one for react) into a single package!
        • Our Javascript library now directly supports NPM. Include “braincloud-js” to grab it!
      • C++ (PS4)
        • FileUploader in place.
      • Objective-C
        • Chat and Lobby services updated.
      • Unreal
        • Unreal wrapper handling smart switching better.
    • We highly recommend that all apps update to the latest libs!
  • Miscellaneous changes
    • Improved handling of anonymous device ids
      • Certain scenarios, like profile merges, result in dormant anonymous ids being associated with a user’s profile.
      • brainCloud will now limit the maximum # of device ids per profile, and if there are more, delete then oldest of them at each login – eventually returning the user to the proper maximum.
      • The default maximum has been set to 10.
    • Page performance
      • Improved the performance of the Design | Segmentation | Segments and Design | Core App Info | Admin pages.
  • Documentation updates
    • Improvements to content and accuracy of code examples.
  • Important Fixes
    • BCLD-3715 – Fix to SendMessage to allow passing in full jsonContext
    • BCLD-3860 – Scripts: Double-slashes in example parameters were not being preserved during export/import
    • BCLD-3737 – Chat service NPE when attempting to retrieve group chat listeners for a group
    • BCLD-3861 – NPE in lobby service runMatchmaker() API
    • And many, many more!
  • Plus miscellaneous fixes and performance improvements.
releaseAnnouncement
6 years ago

brainCloud Release 3.9.0

brainCloud 3.9 is here! Check out the new hotness! 

Release Highlights

Online Presence

Online Presence allows an app’s users to know which of their friends are currently online and available for collaboration.

Presence builds upon brainCloud RTT to deliver a rich solution which communicates:

  • online status – which users (friends, group members) are currently online
  • activity – customizable, rich activity data

In addition, presence supports:

  • real-time notification of status changes
  • ability of subjects to appear invisible (i.e. offline)

For more information, see the Presence Service API Reference.

Note – Online Presence requires brainCloud RTT.

Tournament Divisions

brainCloud already allows games to increase player engagement through global tournaments, which reward prizes (currency, xp, etc.) to users for their play in recurring and/or adhoc tournaments.

Unfortunately, the lure of tournaments diminish as the number of participants grow and the player’s chance of winning decreases. It is tough to motivate players when they need to rank at the top of a leaderboard with thousands of players.

That is where Divisions come in. Divisions horizontally divide your players into separate leaderboards (which we call division instances) of a set size – say 100 players each.

The advantages are significant:

  • Greater engagement – players are playing against a smaller set of opponents, and are more motivated because they have a greater chance of winning
  • Greater control – there is a greater ability to tune the risk / reward structure of the contest, since the numbers are constrained
  • Greater liquidity – divisions hide the actual size of your tournament pool, which can be advantageous when your app is still growing

For more information, see the new Division APIs in the Tournament Service API Reference.

Note – Divisions are available to Business Plan customers and above.

 

Refactored Currency and In-App Purchase APIs

We have completely refactored the Currency, Purchase, and Product / Pricing / Promotions APIs that were previously jammed together in our old Product Service.

We’ve created two shiny new services to contain the new goodness:

  • AppStore Service – houses the new purchase and Product / Pricing / Promotions APIs. The Purchase APIs have been completely re-designed for the new service.
  • VirtualCurrency Service – handles all the currency APIs (other than the move, the APIs are barely changed).

Have no worries – we will ensure that the legacy Product Service continues to work until July 1, 2020, but we strongly suggest that new apps move to the new APIs now, and older apps migrate when they can.

For more information, see the new AppStore Service and VirtualCurrency Service API References.

Customer Requests

We have also added a handful of features to satisfy key customer requests. Hopefully you’ll find yours here!

  • Global Pre-hooks
    • You can now set up a single pre-hook that gets invoked before any API call – which is especially useful if you want to significantly restrict the calls that can be made from the client, without having to individually configure the hook for each service + operation combination.
  • Global Properties
    • New JSON support – you can now directly add/edit JSON in your properties!
    • Deployment Enhancements – you can now preserve the values of select Global Properties though deploys. This is especially useful if you need to accomodate alternate property values in development vs. production, for example.  (Admittedly, using a JSON structure for the value, indexed by AppId is a decent solution for that as well!) 
  • Facebook
    • We’ve updated our Facebook libraries to support Graph API v 2.8
  • Improved Script Engine
    • Turns out our cloud code implementation had an issue where objects being passed and returned from scripts were being set to read-only – even though they were copies. This resulted in issues invoking certain methods on the objects, and of course not being able to modify them without performing another deep-copy within your script. This has been resolved. This result is fully back-wards compatible.

Miscellaneous

Last but not least, we have a few more improvements under-the-hood:

  • Improved Cloud Code performance
    • we’ve improved the caching of cloud code scripts for even better performance!
  • Improved Leaderboard caching
    • as part of our Tournament Division work, we improved the caching of leaderboard configuration data. The improvement will be most noticeable for apps with lots of leaderboards.
  • Improved Design Portal performance
    • We’ve been reworking our core Design Portal tech. You should notice improved zippiness all around when using the portal!

Portal Changes

We have made the following portal changes:

Design

  • Core App Info | Application IDs
    • Added a new Bundle Id field in Apple platform settings, which if filled in, is used to perform additional receipt validation in the new AppStore Service.
  • Core App Info | Advanced Settings
    • A new compatibility flag, [x] Enable legacy Purchase Collection support, has been added. It defaults to enabled for both new and existing apps.
      • Apps with existing purchases should keep this enabled – it will allow the new purchase APIs and old purchase APIs to coexist nicely
      • New apps can feel free to disable this and use the new APIs only.
  • Cloud Code | API Hooks
    • We have added new Dispatcher and S2SDispatcher support for pre-hooks.
    • Configuring a pre-hook against those services will cause the pre-hook script to run before any client or S2S call respectively.
  • Custom Config | Global Properties
    • When creating / editing a property, you can now configure the editor for String or JSON editing. Note that the underlying value is still stored as a String.
    • You can also choose whether the property value should be protected from being overwritten during deploys. This is useful for values that are set uniquely per brainCloud app instance (i.e. the profileId of a system user, a to tell the client that this is a prod vs. debug instance, that sort of thing).
    • Note that during deployment, the deploy process obeys the configuration specified in the source app, not the target app.
  • Leaderboards | Leaderboard Configs
    • You can now flag tournament-enabled leaderboards to act as templates for Divisions. Template tournament/leaderboards do not appear in the regular leaderboard lists, and cannot be joined.
    • You can also now quickly clone leaderboards by choosing the Duplicate option from the action menu.
  • Loaderboards | Tournament Templates
    • Quickly clone tournament templates by choosing the Duplicate option from the action menu.
  • Leaderboards | Division Sets
    • Jump into our new Tournament Divisions feature by defining Division Sets!
    • Division Sets allow you to break tournaments into random sub-tournaments for greater engagement.
    • To configure a division:
      1. First create a tournament-enabled Leaderboard to act as a template (setting the template flag to enabled)
      2. Then create the division set, selecting the Leaderboard template and configuring the maximum # of players per division instance
      3. Use the new Tournament Division APIs to join the tournament!
  • Marketplace | Products
    • We have made a bunch of under-the-hood changes to allow for easier integration of new AppStores in the future
    • The screen should work largely as before – let us know if you experience any issues!
  • Messaging | Presence
    • New screen for configuring the new Presence service
    • Once enabled, any RTT connection established by a client will contain basic presence info (i.e. online/offline) as well
    • From there, rich activity and real-time updates can be enabled as well

Monitoring

  • Global Monitoring | Leaderboards
    • We have added a “Choose a division…” option to the Leaderboard selection menu (for apps that are using Divisions). Use it to view the leaderboard results for a Division instance.
    • Rationale – division instances are hidden from the Leaderboard lists (because there may be hundreds of them).
    • Pro-tip – You can use the API explorer to find the division instances related to a particular player
      • Go to Monitoring | User Monitoring, and find the player in question
      • If the Live Lock banner is showing, click the lock to unlock it
      • Click on [Login as User] to login as this user in the API explorer
      • Choose the Tournament service, and the GetMyDivisions() operation, and click [Run].
      • Voila – a list of the division ids instances for that player. Note that each id contains both the division set code, and the instance id (a number).
  • User Monitoring
    • We’ve added a new Recent Users tab to make it easier to find users that have recently logged into your app
    • Note that this is a log, so you may see the same user listed multiple times (only really noticeable at low activity counts)
  • User Monitoring | Transactions
    • Updated to support the new purchase services and transaction formats
    • You can now view purchase receipts, and even delete purchases if you would like (useful during testing)

General

  • Improved Portal Tech
    • We’ve been doing some work under-the-covers to improve our Portal technology
    • The first thing you should notice is a performance boost – yay!
    • You may also notice a few CSS-related bugs. Feel free to report those so that we can stamp them out!

API Changes

The following changes/additions have affected the brainCloud API:

  • AppStore Service
    • New AppStore Service for querying products / pricing / promotions, and performing in-app purchases.
    • The product / pricing / promotions APIs are identical to the Product Service versions – but the IAP APIs are all new!
  • Group Service
    • Users can now call RejectGroupJoinRequest() to reject a join request that they have made
    • New APIs for managing groups: SetGroupOpen() and UpdateGroupACL()
  • Leaderboard Service
    • New versioned social leaderboard calls – GetSocialLeaderboardByVersion(), GetPlayersSocialLeaderboardByVersion()
  • Product Service
    • Important: The Product Service is being deprecated in favour of the new AppStore and VirtualCurrency services.
    • The service and its APIs will continue to work until July 1st, 2020.
    • There is a new compatibility flag in the portal under Design | Core App Info | Advanced Settings, which controls how purchase transactions are written to the database. Keep [x] Enable legacy Purchase Collection support checked if your app uses the old Product APIs, or a mixture of the old Productand new AppStoreAPIs. New apps that will only use the new AppStore APIs can feel free to clear that flag.
    • Although deprecated, we did add the missing cloud-code version of the VerifyItunesReceipt() back to the service (for those who need it!)
  • Presence Service
    • There is an all-new Presence service. Check it out!
  • Tournament Service
    • New Division Set calls have been added – mostly used when querying and joining a Division Set instance.
    • The new calls are: GetDivisionInfo(), GetMyDivisions(), JoinDivision() and LeaveDivisionInstance()
  • VirtualCurrency Service
    • New VirtualCurrency Service for currency operations. The operations are largely the same, with a bit of clean-up.

Miscellaneous Changes / Fixes

  • Updated libraries
    • All libraries have been updated with the latest API enhancements (with a few exceptions). Go get ’em!
      • C# / Unity – fully up-to-date for 3.9
      • Unreal – fully up-to-date for 3.9
      • C++ – fully up-to-date for 3.9 (though UWP and Nuget packages are outstanding)
      • Java – fully up-to-date for 3.9
      • JavaScript – fully up-to-date for 3.9
      • Objective-C / Swift – fully up-to-date for 3.9
      • AS3 – does not include RTT or RTT-related features (Chat, Presence, Lobbies) but otherwise supports all 3.9 APIs
  • Documentation updates
    • API references have been updated for 3.9
  • Important Fixes
    • BCLD-3513 – Calling RemoveMember on a lobby instance that only has 1 member causes a null pointer exception
    • BCLD-3388 – When receiving a peer currency reward from an xp upgrade, the peer currency balances were not being returned
    • BCLD-3321 – Wrong error code returned for invalid lobby id
    • BCLD-3265 – Unreal and objective-C – fix set profileId after merge call
    • BCLD-3348 – ‘View tutorials’ link in Portal was broken
    • BCLD-3217 – Improved RETRY and PACKET_IN_PROGRESS handling for Unity client library
    • BCLD-3211 – Improved RETRY and PACKET_IN_PROGRESS handling for JavaScript client library
  • Plus miscellaneous fixes and performance enhancements…
releaseAnnouncement
6 years ago

Release 3.8 - RTT!

brainCloud 3.8 marks the beta release of our new Real-time Tech, which we ingeniously call brainCloud RTT.

The brainCloud Platform is built upon a request + response foundation – which provides great flexibility and reliability, together with incredible performance and scalability. There are times, however, when more adhoc communications are desirable (online gaming, chat, monitoring, etc) – and that is where RTT comes in.

brainCloud RTT adds a real-time channel to our client API. This channel allows clients to listen for and react to real-time events – without polling.

This enables a whole suite of new brainCloud features – the first of which you’ll see in brainCloud 3.8!

Note – brainCloud RTT is available to customers using the Business Plan and above <- this has changed – see below! Usage pricing above the initial set of included concurrent users will be announced soon! 

To enable RTT, check [x] Real-time Tech (RTT) Enabled on the Design | Core App Info | Advanced Settings page.  

Update – As of 4.0, brainCloud now supports Plus Plans – which provide RTT features across a variety of usage levels. For more information on Plus Plans, see our 4.0 plan announcement.

Release Highlights

Chat

Thanks to RTT, brainCloud now supports online chat!

We have focused primarily on supporting chat for groups, but we also provide support for global chat channels – which are available to all users of an app.

Chat offers the following features:

  • global and group channel types
  • simple or rich content messages (developer defined)
  • caching of recent chat history
  • support for system messages (from the app, instead of an end-user)
  • support for hidden (semantic) messages
  • ability to edit / delete chat messages

Note – Chat requires brainCloud RTT to be enabled for the app.

For more info, check out the Chat API page, and try out our example chat app – bcChat!

Messaging

brainCloud now provides a Messaging service as well. Messaging is different from chat, in that:

  • recipients are addressed directly (i.e. not via channels)
  • message history is managed on a user-by-user basis (i.e. not by channel)
  • RTT is optional; if enabled, users will receive real-time notification of new messages

Messaging features:

  • Support for multiple recipients
  • Messages are organized into incoming (“inbox”) and sent (“sent”) messageboxes
  • Support for readvs. unreadmessages
  • Support for system messages (from the app, instead of an end-user)
  • Automatic clean-up / deletion of expired messages (important to keep storage utilization low)

For more info, check out the Messaging API page.

RTT Online

With RTT, brainCloud now directly supports the development and integration of custom servers for shared experiences – such as online games (async or otherwise), online meetings, shared document editing, etc.

Room Servers

Room Servers are custom servers used to provide a shared experience (i.e. an online game, online meeting, etc.) to a set of users.

These servers are light-weight and simple to develop, and can easily integrate with brainCloud’s new Lobby and Online Matchmaking services.

In 3.8, Custom Room Servers must be hosted outside of brainCloud, but future brainCloud releases will support hosting the services directly under brainCloud via Docker containers.

Lobbies

Lobbies are used to gather up users prior to launching Room Servers. They provide an online matchmaking service (as opposed to the offline strategy provided by our existing Matchmaking service).

Lobbies provide:

  • support for multiple teams – with min/max # of users
  • automatic assignment of users to teams (users can switch afterwards)
  • management of user settingsand readystatus
  • support for multiple lobby types
  • support for calling an external room server managerto launch a room serverwhen the lobby is ready

Lobby Matchmaking

Online matchmaking is used to match up users with lobbies, in preparation for entering Room Servers.

The Lobby Matchmaking APIs allow the developer to:

  • specify the type of lobby / room to match with
  • specify the player rating to target
  • specify an algorithm to use when escalatingthe search
  • provide a custom filter script to use to filter out candidates

For more info, check out the Lobby API page.

On Demand Tournaments

We have greatly enhanced our Leaderboard and Tournament systems to make the scheduling of tournaments more flexible.

brainCloud previously supported only regularly recurring tournaments – which are tournaments that happen daily, weekly, monthly, etc… (i.e. at preset intervals). brainCloud 3.8 introduces new On Demand / Adhoc Tournaments – to support irregularly scheduled tournaments (i.e. major holidays, new releases, etc.)

To create an adhoc tournament, create a leaderboard and choose the “Adhoc Tournaments” rotation type. Then manually add each tournament period.

Cloud Code Import / Export

Finally, we are reworking our cloud code management sytems. As part of this, we have created a new serialization format for cloud code scripts, that makes it easier to export the scripts, edit them locally on your workstation, and upload them back to us.

The handy cloud-code method below allows you to post a score to multiple leaderboards:

var result = {};
result.posted = 0;
result.errors = 0;
result.errorsList = [];

// Grab the parameters
var leaderboards = data.leaderboards;
var score = data.score;
var extras = data.extras;

var _leaderboard = bridge.getLeaderboardServiceProxy();
var postResult = {};

// Loop through the leaderboards
for (var i = 0; i < leaderboards.length; i++ ) {
    
   // Post the score
   postResult = _leaderboard.postScoreToLeaderboard(leaderboards[i], score, extras);
   if (postResult.status == 200) {
     result.posted++;
   } else {
     result.errors++;
     result.errorsList.push(postResult);
   }
    
}

// Return the results
result;
//*** ------------- brainCloud meta-data begins now - do not hand-edit -----------------
// "scriptName":"PostToLeaderboards",
// "clientCallable":true,
// "s2sCallable":false,
// "peerCallable":false,
// "scriptTimeout":10,
// "description":"Posts a score to multiple leaderboards",
// "parms":"{\n  \"leaderboards\": [\"weekly\", \"alltime\"],\n  \"score\": 1000,\n  \"extras\": {}\n}",
// "version":3,
// "updatedAt":1530799500264

To import it into your app:

  • Click here to download the serialized version of the cloud code script to your workstation
  • Launch the Design Portal, and go to Design | Cloud Code | Scripts, and choose the Import Script option from the Import / Export menu button
  • Navigate to your download directory, and choose the PostToLeaderboards.cloudcode.js.zip script
  • Click okay – and voila, you should now have the script, with all settings intact.

This new serialization format is the first step to a bunch of new features that we hope will make creating and managing cloud code scripts a lot easier for devs. We hope you like it!


Portal Changes

The following additions and changes have been made to the Design Portal:

Design

  • Core App Info | Advanced Settings
    • Added a new setting to enable RTT to the App Settings section.
  • Cloud Code | Scripts
    • Added new options for importing and exporting Cloud Code scripts.
  • Leaderboards | Leaderboard Configs
    • This dialog has been completely re-designed to better handle Tournament scenarios, including new On Demand Tournaments.
    • One tournaments are enabled, a new Tournament Periods section appears – allowing the developer to select and edit the settings of a specific tournament rotation.
    • Recurring tournaments will always show the current period, followed by the next (recurring) period. Changes to either period will affect all periods that follow.
    • Adhoc tournaments will show the the current period (if there is one) and any future periods. Adhoc tournament periods do not repeat – you must individually schedule each one.
  • Messaging | Chat
    • Used to enable and configure the new Chat service.
    • The settings determine how much chat history is preserved.
  • Messaging | Chat Channels
    • Used to configure the list of Global Chat Channels for the app.
  • Messaging | Messaging
    • Used to enable and configure the Messaging service.
    • The settings determine message retention, and whether outgoing copies of messages are saved.
  • Multiplayer | Lobbies
    • Used to enable the Lobby service, and configure the list of Lobby Types.
    • Lobby type settings include:
      • team definitions – including min / max number of participants
      • progression rules – including timing and ready-up percentages
      • matchmaking filter – used to customize matchmaking beyond the built-in skill, lobby-type and team space algorithm
      • room server manager – the web call to make to allocate a room server for the experience
      • custom config – custom json parameters to pass onto the room server at the start of the experience

Monitoring

  • Global Monitoring | Leaderboards
    • Updated the leaderboard viewer to view On Demand / Adhoc Tournaments

API Changes

The following changes/additions have been made to the brainCloud API:

  • [New!] Chat
    • Add online chat to your app quickly and easily!
    • Check out the Client and S2S Chat APIs.
  • Client
    • [New!] EnableRTT() – Used to establish the RTT connection from the client.
    • [New!] DisableRTT() – Disconnect from RTT.
    • Plus methods for registering and de-registering RTT listeners for Chat, Events, Messaging and Lobbies.
  • Event
    • No more polling! SendEvent() now sends a realtime event to the recipient if they are currently online, and RTT is enabled.
    • See the RegisterRTTEventCallback() API for details.
  • GlobalEntity
    • Made the following system entity calls available from client session cloud-code scripts (they were previously S2S only)
      • CreateSystemEntity(), GetSystemEntityList(), GetSystemEntityListCount(), GetSystemEntityPage(), GetSystemEntityPageOffset(), and ReadSystemEntity().
    • GetListByIndexedId() now returns entityListCount in addition to the list of items.
  • [New!] Lobby
    • Add online matchmaking, full lobby support and easy custom server integration to your app.
    • Check out the Client and S2S Lobby APIs.
  • [New!] Messaging
    • Add user-to-user messaging to your app, with optional real-time delivery via RTT.
    • Check out the Client and S2S Messaging APIs.
  • Product
    • Added the missing VerifyItunesReceipt() call to Cloud Code.

In addition, all brainCloud file downloads (global and user) are now resumable (we have added the “Accept-Ranges” header).


Miscellaneous Changes / Fixes

  • Updated libraries
    • RTT support, with Chat, Messaging and Lobby APIs, have been added to the Unity, Java and Javascript libraries. More libraries will follow soon!
    • All libraries have been updated with improved retry and packet-in-progress handling
    • Our Javascript library now directly supports NPM. Include braincloud-js to grab it.
  • Documentation updates
    • We have updated the docs to reflect the new brainCloud services
  • Plus miscellaneous fixes and performance improvements
releaseAnnouncement
7 years ago

Release 3.7.0

We are happy to present Release 3.7.0. It’s a mid-sized update that satisfies some key customer requests and incorporates some foundational changes that we will be leveraging in upcoming releases!

Release Highlights

Inherited Friends!

The Shared Accounts feature in brainCloud allows developers to build relationships between apps – so that users can log into a single master account (i.e. parent profile), and utilize that account (and data) across a suite of related apps. The user data from each app is still stored independently (allowing independent save state, achievements, scores/leaderboards, etc.) in a separate sub-account (i.e. child profile).

We have now extended this mechanism to better support social relationships between users. So, instead of having to manage a set of friends individually for each app, child apps can now inherit friends from their parents. This is a great boon for social leaderboards – and means that new entrants in a suite of apps can easily extend the social graph of related apps.

If you are already using Shared Accounts, you can enable Inherited Friends by going to the Design | Authentication | Shared Accounts page and checking the [x] Include Friends of Parents option.

The ListFriends(), GetSocialLeaderboard(), GetPlayersSocialLeaderboard() and GetMultiSocialLeaderboard() APIs have all been enhanced to utilize inherited friends.

More Flexible Matchmaking

Our matchmaking service has been enhanced to offer more flexibility – namely support for overriding the player’s ranking that is the basis of the search, and the ability to substitute in a different matchmaking filter.

The new API methods are: FindPlayersUsingScript() and FindPlayersWithAttributesUsingScript().

Note – for security purposes, these new calls are cloud-code only.

Updated Developer Roles / Permissions

We have tweaked the permissions associated with the default development roles of the system to incorporate customer feedback.

The following changes have been applied:

  • Support role
    • Removed write access to all of Global Monitoring, except for Leaderboards. 
    • Removed access to Reporting | API Usage – leaving only access to Reporting | Error Analytics
    • Full read+write access to User Monitoring remains
    • Limited read+write access to Design remains as is
  • Read-onlyrole 
    • Removed access to Design | Core App Info (all sections) and Design | Integrations 

Change E-mail Identity

We’ve added a new api that allows you to change the email address associated with a user’s EmailIdentity.

The new ChangeEmailIdentity() call takes as parameters the existing email and password (for security purposes), and the new email address to use. You can also optionally tell the method to update the user’s contact email as well (recommended).

Note – this method does not currently support our email verification system, so no verification email (with link to confirm) is sent. We plan to add that support in a future release.


Portal Changes

We’ve made the following portal changes:

Design

  • Authentication | Shared Accounts
    • Added the new [x] Include Friends of Parents option
  • Leaderboard | Leaderboard Configs
    • You can no longer add Tournaments to the active rotation of a leaderboard if it already has scores. The tournament will be queued to activate on the next rotation

Monitoring

  • Global Monitoring | Leaderboards
    • Now showing the status of the Tournament auto-claim and auto-join settings per leaderboard rotation

Team

  • Home | Audit Log
    • We now log any password reset requests for security purposes…

API Changes

The following changes/additions have affected the brainCloud API:

  • Identity
    • New ChangeIdentityEmail() method for changing the email address that a user uses to login.
  • Matchmaking
    • Two new cloud code APIs allow you to override the player rating and filter script used in matchmaking – FindPlayersUsingScript() and FindPlayersWithAttributesUsingScript()

Plus the ReadProperties() method is now available from the S2S API.

 


Miscellaneous Changes / Fixes

  • Updated libraries
    • All libraries have been updated with the new APIs. We recommend that all apps upgrade!
  • Documentation updates
    • We have updated the docs to reflect the new API calls
  • Important Fixes
    • BCLD-2777 – Portal: when adding to the [Job Queue], the “Save” button becomes available without selecting a script
    • BCLD-2783 – Changing apps while on the script page causes the Peer Script Service not to update in the API Explorer
    • BCLD-2790 – Portal: [Monitoring] –> [Group Entities]: the data for a group entity is shown as an escaped JSON string, not nicely printed
    • BCLD-2904 – User Attributes don’t reset on reset
    • BCLD-2927 – fixed duplicate HTML ids across all pages
    • BCLD-2985 – User Monitoring | Friends – need space between friend name and email
    • BCLD-3003 – Team Select Screen – When the User adds a new team it does not appear in the select team drop down
  • Plus miscellaneous fixes and performance enhancements…
releaseAnnouncement
7 years ago

Release 3.6.6

This release is a minor update with some key optimizations and defect fixes.

Feature Highlights

Faster Leaderboards and Tournaments

We’ve spent considerable time profiling and optimizing key tournament and leaderboard APIs – we think you’ll like the results:

  • GetGlobalLeaderboardView() is now up to 25X faster! This is especially apparent for leaderboards of 50K or more users where the player doing the retrieval is near the end of the leaderboard
  • PostTournamentScoreWithResults() is also up to 50X faster! We had recently pulled that call out-of-service due to performance issues – we hope to reinstate it in a few days after we’ve got more real-world data

Miscellaneous Fixes

The following defects have been addressed in 3.6.6:

  • BCLD-2782 – Portal: Trying to “View Team” from Super > Users switches to random team instead of the selected team
  • BCLD-2777 – Portal: When adding to the Job Queue, the “Save” button becomes available without selecting a script
  • BCLD-2793 – Portal: Super – System Properties’ Categories drop-down does not function properly once a category is selected
  • BCLD-2847 – Portal: Part of WebHook URL changes to “null” after saving and re-opening it
  • BCLD-2821 – Portal: User Monitoring | Statistics – always shows “0 records”
  • BCLD-2802 – Portal: dropdown/context menu on Design | Custom Config | Files appears partly off the right side of screen
  • BCLD-2861 – Portal: Core App Info | Admin Tools – Deployment: Checkbox of second option gets checked while clicking on the text of the third option.
  • BCLD-2786 – Portal: Mouse-over texgt is either missing or incorrect (multiple locations)
  • BCLD-2856 – API: In some cases, non-shareable files can be downloaded without a session
  • BCLD-2826 – API: Leaderboard: GetGlobalLeaderboardView ranges now working properly with duplicate scores
  • BCLD-2830 – API: PostTournamentScoreWithResults reports the wrong error if a player is not registered
  • BCLD-2813 – Portal: Super user cannot perform “Sys Enable” action to enable an app that has been previously disabled
  • BCLD-2824 – Portal: Design | Integrations – the first three fields for SendGrid integration should have * next to titles to indicate required
  • BCLD-2825 – API: PostScoreToLeaderboard fails on any leaderboard that ever had a tournament attached

Portal Changes

There are no changes to the portal in this release.


API Changes

The following changes/additions have affected the brainCloud API:

  • Tournament
    • PostTournamentScoreWithResults() – we have removed the previousLeaderboard section of the returned JSON. It was debugging information that mistakenly got left in the response during initial development.
  • Client Library
    • We have added a new IGNORE_SSL_CHECK compiler directive to the C# library. Useful for when connecting an app to a developer-deployed brainCloud instance.

Miscellaneous Changes / Fixes

  • Updated libraries
    • All libraries have been updated with the refactoring and latest API enhancements. We recommend that all apps upgrade!
  • Important Fixes
    • See the list in the Feature section
  • Plus miscellaneous fixes and performance enhancements…
AnnouncementImprovement
7 years ago

Wrappers, Clients and Inconvenient Singletons

   

 With release 3.6.5, brainCloud is breaking away from the singletons that were previously a key aspect of our client libraries.

We thought we’d take a moment to discuss the pros and cons of the design, and explain where and why we are going a different route.

Background

To start, lets review the purpose and design of the client library.

The goal of the client library is to simplify development of brainCloud-based applications. It does this by:

  • providing local implementation of brainCloud client calls (instead of forcing the client app to use Raw REST calls)
  • automating communications with the server (bundling of messages for efficiency, packet security, and more)
  • performing standard error handling

The library is actually organized into two major components:

  • the brainCloud Client Library – a pure, platform-independent wrapper of the brainCloud client-server protocol
  • the brainCloud Wrapper – simplifies aspects of the API (especially authentication) by incorporating more client-side functionality, like saving and restoring anonymousIds and profileIds.

Use of the client library is required by apps. Use of the wrapper is highly recommended, but optional. Note – originally we only had the client library. The wrapper was added later as an aid to app developers. 


Delving deeper into the design, you can see that the client object maintains a list of services and internal components that work together to provide the client functionality. The wrapper on the other hand is quite simple, and merely adds an additional simplification layer to the API.

Of significance here is the use of singletons. There are two singletons in play – one for the client, and one for the wrapper. Not only are the singletons used as the reference from the client to the wrapper and/or client library objects – but they are also used for communications between BrainCloudWrapper and BrainCloudClient.

In hindsight, although our intentions were good – this usage of singletons was a mistake.

The cons (as we now see them) are:

  • Complicates the client code (calling the static class methods to retrieve a reference to the wrapper and or client object is more painful than using a direct global of some sort)
  • Complicates the documented code examples
  • Restricts a client to have one-and-only-one connection to the brainCloud server [ this is a crippling restriction for some use cases – couch co-op anyone? ]

The fix

And so, we are fixing this.

The changes to the new client libraries are three-fold:

  • BrainCloudWrapper objects now have their own reference to their associated BrainCloudClient companions
  • BrainCloudWrapper objects also now provide direct methods for accessing the client services: you no longer have to call wrapper → client → service → operation, instead it is simply wrapper → service → operation

The result is that instead of your client code looking like this:

BrainCloudWrapper.Instance.GetBC().LeaderboardService.ListAllLeaderboards( ApiSuccess, ApiError);

It can look like this:

_bc.LeaderboardService.ListAllLeaderboards( ApiSuccess, ApiError);

The Changes

So – more flexibility and clearer code? What’s the catch?

The catch is that you need to make a few changes to your client to get this goodness. For new apps it’s no big deal at all – this could be a pain for existing apps though, so we are still including a legacy singleton mode in the client libraries – but that needs to be specifically enabled.

Update: Legacy Singleton Mode has been removed from brainCloud client libraries beginning with 4.0. 

Here are the steps to getting your app working using the updated libraries

  1. Grab the latest brainCloud client library from the portal via the Team | Client Libs page.
  2. Create an instance of BrainCloudWrapper and save it to a global accessible throughout your client app. In our documentation examples we use _bc, but it can be anything
  3. Adjust any client code to use this new reference – try searching and replacing
    1. “BrainCloudWrapper.Client.” → “_bc.”
    2. “BrainCloudClient.Instance.” → “_bc.”

And that’s about it.

Note – you can optionally specify a _wrapperName to use creating the wrapper. This name will be used as a key when storing data about the session, like the anonymousId and profileId.

You only need to specify the _wrapperName if you are implementing a client with multiple concurrent connections to the brainCloud server (to help keep the session data separate). In particular, if you are updating an existing app, do not specify a profile-name – this ensures that the user does not lose their saved profile references when they upgrade to the latest version of your app!

_bc = new BrainCloudWrapper(); // optionally pass in a _wrapperName
_bc.initialize(_appId, _secret, _appVersion);

_bc = go.AddComponent();
_bc.WrapperName = "_example"; // optionally set a wrapper-name
_bc.Init();

Legacy Singleton Mode

Update: Legacy Singleton Mode has been removed from brainCloud client libraries beginning with 4.0. 

Want to move to the new libraries, but change as little code as possible? No worries, we have you covered. Here’s what you do:

  1. Grab the latest brainCloud client library from the portal via the Team | Client Libs page.
  2. Turn on legacy singleton mode via the BrainCloudClient.EnableSingletonMode() API call. Put the call in your code right before you initialize the library.
  3. Unity only (and only if you were using the Client static class accessor):
    Adjust any calls to BrainCloudWrapper.Client.aService().anOperation() to use BrainCloudWrapper.Instance.Client.aService().anOperation() instead (Note the additional Instance step).

The following code snippet shows how to enable singleton mode in various languages:

BrainCloudClient.EnableSingletonMode = true;  // Turn on legacy singleton mode
BrainCloudWrapper.getInstance().initialize(_appId, _secret, _appVersion);

BrainCloudClient.EnableSingletonMode = true;  // Turn on legacy singleton mode
BrainCloudWrapper.getInstance().Init();


Conclusion

Anyway, thats the summary of what we have changed, and why.

We hope you agree that the improvements to functionality and readability are worth it.

If you have any feedback or concerns, feel free to hit the chat link and let us know.

Cheers!

releaseAnnouncement
7 years ago

Release 3.6.5

We are pleased to present release 3.6.5 – just in time for the holidays!

Note that there are some breaking changes in the client libraries – but they are pretty simple to accomodate, and of course will not affect your app until you update. For more details, see the Refactored Client Libraries section below.


Feature Highlights

Fresher Matchmaking

We have added a new expiry feature to keep your matchmaking fresh. It is implemented via a nightly process that will disable the matchmaking flag for users that haven’t logged into the app within the specified number of days.

 

Enabling this feature will ensure that players don’t get matched with opponents who haven’t recently logged into your game.

Important notes:

  • The nightly process only runs for Live apps. This feature does not affect apps still in development. (This saves server cycles, plus while in development it is tough to get enough players to match against already!)
  • Auto-Expiry is turned OFF by default for existing apps.
  • Auto-Expiry is turned ON by default for new apps (with expiry set to 30 days).
  • Important: brainCloud will not automatically re-enable matchmaking for a disabled user once they login. Apps using this feature should directly call EnableMatchmaking() whenever a user launches the app.

Batch Scripts

A common customer request has been a way to iterate through the population of an app’s users, performing some operations on each user’s account. It has taken some time to find a proper way to do this that is scalable and safe – but we are pleased to announce that the first evolution of this is now in place.

We have introduced a new S2S Script Service method called RunBatchUserScript(). This script can be called via the S2S Explorer or from an external server – and queues the specified script to be run against each of the users in a app (or optionally, against particular segments). Although the RunBatchUserScript() is triggered from the S2S context, each individual script is run in the context of the current player – so it is as if the script was called by that user’s logged-in session – greatly simplifying the script code.

Here’s an example script that writes a global entity (singleton) for each player it is run upon:

var result;

_globalEntityService = bridge.getGlobalEntityServiceProxy();

var acl = { "other": 1 };
var customData = { "test": "info" };

result = _globalEntityService.createEntity(data.entityType, null, acl, customData );

result;

You can call it via the S2S Explorer like this:

Note that the scripts get queued to run on the users in the background – and depending upon the app’s population may take several minutes or potentially several hours to complete.

Refactored Client Libraries

The brainCloud client libraries have been refactored for greater simplicity and flexibility. Key improvements with these changes are:

  • Support for multiple connections per device ← useful for devices that require multiple concurrent user logins – couch co-op, anyone?
  • Saved wrapper data is now differentiated with a wrapperName value ← necessary to support multiple connections
  • Access to all client services from the wrapper ← means the wrapper becomes largely invisible
  • Simpler client code ← yay!

Key API changes

The key change that allows this is the deprecation of the singleton behaviour of the brainCloud client libraries. As you may or may not know, for convenience the brainCloud client libraries declared singletons for both the BrainCloudWrapper and BrainCloudClient library classes. This provided a bit of convenience for developers – but at considerable costs to flexibility (and frankly, some code readability issues). We are hereby deprecating this behaviour.

In addition, we are making the client services callable directly from the wrapper – which greatly simplifies calling them (and abstracts whether you are calling via the wrapper or directly from the client).

For comparison – here are what two calls to the leaderboard API look like – before and after this API change:

// Old: Call leaderboard API via the wrapper singleton, to the leaderboard service via the BrainCloudClient object
BrainCloudWrapper.GetBC().getLeaderboardService.ListAllLeaderboards( ApiSuccess, ApiError);

// New: Same call. Note that whether _bc is an instance of BrainCloudWrapper or BrainCloudClient, this code looks the same. Simpler, eh?
_bc.LeaderboardService.ListAllLeaderboards( ApiSuccess, ApiError );

These improvements mean that some client code has to change – but the changes are pretty simple, and we believe well worth-it (see below).

Existing apps have the following options available to them:

  • No changes – stay with brainCloud libraries earlier than 3.6.5
  • Minimal changes – move to brainCloud library 3.6.5, but turn the legacy singleton mode on
  • Full changes – move to brainCloud library 3.6.5, initialize the brainCloud wrapper to your own global(s), and adjust your calling code accordingly

We highly recommend that new apps use the new paradigm – your code will be simpler for it.

For more information, see our blog post with the full details and rationale.


Portal Changes

We’ve made the following portal changes for this release:

Team

  • Navigation
    • We have restructured the Team navigation menu to better group the features. In particular, all of the Admin-management features are now located under the Manage menu.

Design

  • Core App Info | Advanced Settings
    • Disable Live Lock – Live Lock helps to protect your live apps by forcing you to unlock them before editing. You can now disable this behaviour if you would like (Note – not recommended for production apps!)
  • Integrations | Sendgrid
    • Fixed an issue where test emails were no longer being sent when the [Test] button was pressed.
  • Multiplayer | Matchmaking
    • Expire matchmaking – Automatically expire (disable) a user’s eligibility for matchmaking after days without logging in. Helps to ensure that your players are matched with fresh opponents, instead of players who may no longer be active in your app!

Monitoring

  • User Monitoring | Logs
    • New Export feature exports requests and responses in their entirety… (before was limited to request and response summaries)

General

  • User Settings
    • Language and Timezone settings are now stored to the developers account profile (instead of local web storage). Also addressed an issue with daylight savings time.
  • Entity Editors
    • Global Entity Editor, Group Entity Editor and User Entity Editor have all been updated to handle Long values better.

API Changes

The following changes/additions have affected the brainCloud API:

  • Client
    • EnableSingletonMode setting – if you wish to use the brainCloud singleton mode, it is still available, but it must be explicitely enabled. You can do so by setting BrainCloudClient.EnableSingletonMode = true in your app.
  • Multiplayer
    • <New!> IncrementShield() – allows you to increment the shield setting without reading it first. Especially useful when extending a shield that is already in place.
  • Script Service
    • <New!> RunBatchUserScript() – allows you to queue a script to be run against all of your apps’s users! (or select segments)
  • Wrapper
    • Singleton behaviour is now deprecated, but can be re-enabled using the EnableSingletonMode setting of the Client.
    • All of the brainCloudClient service accessors (except AuthenticationService) have been added to the wrapper.
    • Unity: Removed static class method Client() (which returned the client singleton) and replaced it an instance-level Client() get / set accessor (which returns the client object associated with this wrapper instance).

Miscellaneous Changes / Fixes

  • Updated libraries
    • All libraries have been updated with the refactoring and latest API enhancements. We recommend that all apps upgrade!
  • Documentation updates
    • We have updated the docs to reflect the new client calling conventions
  • Miscellaneous updates
    • We have updated brainCloud to use version 2.7 of the Facebook Graph API
  • Important Fixes
    • BCLD-2756 – Losing verification code on merging Email account into another account
    • BCLD-2746 – PostTournamentScore/WithResults should auto-join player if Auto Join enabled for leaderboard config
    • BCLD-2742 – Rank added to postTournamentScoreWithResults
    • BCLD-2739 – Fix to before and after handling of postTournamentScoreWithResults
    • BCLD-2721 – When attaching an Email identity and app email feature Send Verification Email is checked , we aren’t updating player emailAddress when should be
    • BCLD-2710 – PostTournamentScore(WithResults) – Null pointer exception when posting score to a leaderboard with tournament configured but not active until Next Cycle
    • BCLD-2699 – GlobalEntity Raw Export fails to import when is 0 (Integer vs. Long)
    • BCLD-2696 – Portal – If you switch apps while editing a web service the page does not update
    • BCLD-2662 – Non Admin Users see the Remove option in the actions menu of the Members page
    • BCLD-2607 – Disable the [Go Live] button once the user clicks it
    • BCLD-2597 – Portal – If data field for an Entity contains an integer that is too high show a proper error dialog
    • BCLD-2594 – Segment country-code not standardized as UPPERCASE
    • BCLD-2593 – BigInteger web defect – GlobalEntity, ChildEntity, Group and GroupEntity editors
    • BCLD-2646 – Fix the banner in Safari
  • Plus miscellaneous fixes and performance enhancements…