CRM

The CRM Service Type is used to expose CRM entities in a Microsoft Dynamics CRM Organization as SmartObjects.

An instance of this Service Broker is configured during the K2 installation process if CRM integration information is entered in the relevant installer screens. You can also create additional instances manually to target additional CRM Servers or Organizations. The CRM Service Type works in conjunction with the CRM Functions Service Type. Note that the CRM Functions broker does not require an instance per CRM Organization, since it works dynamically across any CRM instance.

Service Authentication

The table below describes the Authentication Modes that may be used with the CRM Service Type.

CRM On-premises CRM in the Cloud
  • Impersonate (including Enforce Impersonate)
  • Service Account
  • SSO
  • Static
  • SSO
  • Static
  • Impersonate
  • Enforce Impersonate
  • Service Account
  • SSO
  • Static
  • SSO
  • Static

Service Keys (Service Instance Configuration Settings)

Key Can be modified Data Type Sample Value Notes
CRMServerURL Yes
(required)
Text https://portal.denallix.com/CRM Provide the CRM Server's URL
OrganizationName Yes
(required)
Text denallix Provide the CRM Organization Name for the organization defined in CRM that will be associated with this Service Instance. See Organization Name in Microsoft Dynamics CRM 2011.
When registering a Service Instance for a CRM Online site, use the root of the Discovery Service URL (e.g. http://crm2013srv1:5555 or https://disco.crm.dynamics.com) listed in the Developer Resources tab (Settings > Customizations > Developer Resources) on the CRM site for the CRMServerURL key. Use the Organization Unique Name listed on the Developer Resources tab for the OrganizationName key.

Service Objects

The CRM Service typically exposes multiple Service Objects for the entities discovered when a Service Instance is registered. The list of exposed entities and methods can be seen in the following embedded Excel spreadsheet: CRM_MethodMatrix.xlsx . The CRM Service Broker exposes certain Entities (as described in the Excel sheet) and ]within each resulting ServiceObject, only certain methods are exposed. Not all Entity fields are created all the time. As per Microsoft's recommended best practice, the CRM API SdkMessageFilter is used to determine which methods to expose.

Each field in an entity has the following properties:

When describing the methods and creating the resulting ServiceObjects, the service broker filters out all fields whose value is false for the above mentioned properties, to avoid runtime exceptions. The SdkMessageFilter is then used to determine which methods it should expose for each entity. This is why certain Entities have all the methods and other Entities have only some of the methods.

The screenshot below shows some typical entities that are exposed when registering an instance of the CRM service, though the entities available in your environment may be different.

SmartObjects

If a CRM environment is configured during installation, K2 automatically generates SmartObjects for these Service Objects. SmartObjects are automatically created when selecting the Generate SmartObjects for this Service Instance check box when creating a new Service Instance. Designers may use the available Service Objects in this service to create advanced SmartObjects using the available K2 SmartObject design tools. It is recommended to use the K2 Design tools to create SmartObjects rather than generating SmartObjects, since this allows better control over the naming, behavior and design of the SmartObject and its methods and properties.

Considerations