back to top

Start a Sales Process for an Opportunity via the SData API in Infor CRM

If you’re using SData to create Opportunity records, you’ll likely need to also start sales processes for those opportunities as well. Sales processes in Infor CRM (SalesLogix) is a mess with all the XML etc. Luckily, there’s an out of the box business rule we can use that does all the messy stuff for us. Let’s take a look at how to do this via the Infor CRM SData API.

Note: We’ll be using the DotNetSDataClient library in this example.

In a nutshell, we’ll need a few things to accomplish this:

  1. First, you’ll need the plugin ID for the sales process you want to start. You can find the Sales Processes in the Plugin table. Sales processes have a TYPE=1, so you can use the following to find the one you want: select * from sysdba.plugin where type = 1
  2. Next, in your code, you’ll create a new/empty SalesProcesses entity via SData
  3. Last, you’ll call the InitSalesProcesess business rule on that new entity and provide the plugin ID for the sales process you want to start and the opportunity ID for the opp you’re starting it for

The complete code to do all of this looks like the following:

// create the SData client 
var client = new SDataClient("http://localhost:3333/sdata/slx/dynamic/-/")
{
    UserName = "admin",
    Password = ""
};

// first create a new/empty salesprocess record
var salesProcess = client.Post(new {}, "salesProcesses");

// now call the InitSalesProcess business rule to start the process and 
// attach it to the opportunity. We'll pass into the rule the new
// salesprocess entity we created along with the plugin ID of the 
// process and the opportunity ID we're attaching it to.

var processPluginId = "p6UJ9A000501"; // ID of the process in the plugin table
var opportunityId = "ODEMOA0000CR"; // ID of the oppportunity we're attaching it to 

// create the payload for the business rule
var initProcessRule = new
{
    Request = new
    {
        entity = salesProcess,
        pluginId = processPluginId,
        entityId = opportunityId
    }
};

// execute the business rule 
client.Post(initProcessRule, "salesProcesses/$service/InitSalesProcess");

That’s it. You can go to the opportunity and you’ll see the sales process started for it. BTW, this code is even simpler if you’re in the Infor CRM client itself (and not working via SData), for example from some form or other business rule/entity event. The steps are the same, but there’s a bit less to do:

var salesProcess = Sage.Platform.EntityFactory.Create<ISalesProcesses>();
salesProcess.InitSalesProcess(pluginID, opportunityId);

Lastly, I should mention, if you’re using a completely external application (and not using SData), I do also have an open source library that does all this using Sublogix as well. See that code and get the DLL here: CustomerFX/SalesProcessAdapter (works with all versions of Infor CRM/SalesLogix and great for LAN environments).

Contact Customer FX for your CRM project
We let our expertise speak for itself - let us know how our all-star team can help on your CRM project
About the Author
Ryan Farley
Ryan Farleyhttps://customerfx.com/article/author/ryanfarley/
Ryan Farley is the Director of Development for Customer FX and creator of slxdeveloper.com. He's been blogging regularly about SalesLogix, now Infor CRM, since 2001 and believes in sharing with the community. His new passion for CRM is Creatio, formerly bpm'online. He loves C#, Javascript, web development, open source, and Linux. He also loves his hobby as an amateur filmmaker.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Infor CRM Sync for Exchange: Action Required by August 31, 2026

Using Infor CRM Sync for Exchange with Microsoft 365? Your Exchange administrator must update tenant settings by August 31, 2026 to prevent sync disruption.

[Webinar] What’s Coming Next for Infor CRM SLX and Why v10 Matters

See what’s coming next for Infor CRM SLX, including new marketing workflows, automation improvements, and reasons to consider upgrading to v10.

Disable Caching in Infor CRM SLX Web Client

In the rare case caching is causing issues in the Infor CRM SLX web client, it is possible to disable specific types of caching by making edits using Application Architect, and then deploying.

Exploring AI Options for Infor CRM v10

I've started taking a closer look at the AI capabilities built into Infor CRM v10. Over the next several posts, I'll share what I learn. From the built-in features and supported AI providers to implementation considerations, costs, and practical use cases.

Infor CRM SLX 10.0: Delegate Ownership Changes for “Everyone” Records

Learn how the new EveryoneOwnerAssignment secured action in Infor CRM SLX 10.0 allows designated users to change ownership of Everyone-owned records without requiring Administrator access.

Related Articles

Infor CRM Sync for Exchange: Action Required by August 31, 2026

Using Infor CRM Sync for Exchange with Microsoft 365? Your Exchange administrator must update tenant settings by August 31, 2026 to prevent sync disruption.

[Webinar] What’s Coming Next for Infor CRM SLX and Why v10 Matters

See what’s coming next for Infor CRM SLX, including new marketing workflows, automation improvements, and reasons to consider upgrading to v10.

Disable Caching in Infor CRM SLX Web Client

In the rare case caching is causing issues in the Infor CRM SLX web client, it is possible to disable specific types of caching by making edits using Application Architect, and then deploying.

Exploring AI Options for Infor CRM v10

I've started taking a closer look at the AI capabilities built into Infor CRM v10. Over the next several posts, I'll share what I learn. From the built-in features and supported AI providers to implementation considerations, costs, and practical use cases.

Related Videos