Microsoft CRM 2015 Online U1 Deprecated Message Requests

Microsoft CRM 2015 has a few built in tools to allow you to assign records and update their record status.  For example, you can assign an Opportunity to a particular sales manager or you can close an Opportunity as won/lost using native buttons in the command bar:

If you need this to happen in the background based on your business logic, your CRM admin can create a process using the built in workflow interface.  For example, they can create a workflow to assign an Opportunity to a sales manager based on territory or they can create a workflow to close an Opportunity based on a stage change.

However, if you have complex business logic that can’t be performed using the native CRM tools or perhaps you have a custom portal that needs to make these updates from outside of CRM, a developer has the ability to code the same functionality. Prior to CRM 2015 Online U1, a developer would call the AssignRequest to change ownership of a record and call the SetStateRequest to change the state/status of a record (e.g., Won, Lost, Deactivated).  In CRM 2015 Online U1, this has been deprecated and simplified for developers. Instead of needing to call a special message request to perform these actions, you can do it within an UpdateRequest, as you normally would do so to update standard fields on a record:

Entity myEntity = new Entity(context.PrimaryEntityName);
myEntity.Id = context.PrimaryEntityId;
myEntity[“ownerid”] = new EntityReference { LogicalName = SystemUser.EntityLogicalName, Id = myUserGUID };
UpdateRequest updateReq = new UpdateRequest() { Target = myEntity };

The impact of this change is that if you combine the UpdateRequest with an ownership/status update and standard field updates, the code will execute twice.  For CRM 2015 online organizations that currently utilize the specialized message requests, they will continue to work (for now), but you should get in touch with a developer as soon as possible to update your code. Microsoft is planning to release their new web API in the near future which will only support the UpdateRequest.  Please note that this change only applies to CRM 2015 Online with U1 or newer.  For more information on this and other specialized message requests that have been deprecated, please see:

For assistance in updating your code, please contact Beringer, a Microsoft Gold Certified Partner.