Hi @ChrisPiasecki,
I can get the active stage id and specific process stage just fine, but I'm not sure how to filter the client data.
For example: I've created a Lead Record below which is currently in the first stage.

I then perform a request to get the relevant data: (which I actually just used XRM Toolbox to do so it's quicker)
https://{crm-url}/api/data/v9.2/processstages?$expand=processstage_leadtoopportunitysalesprocess($filter=(_leadid_value eq {lead-guid}))&$filter=(processstage_leadtoopportunitysalesprocess/any(o1:(o1/_leadid_value eq {lead-guid})))&$top=10
From this I'll get the clientdata of the Active Stage which looks like the below: (with guids ommitted)
{
"DisplayName": "Existing Contact?",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "parentcontactid",
"IsRequired": false
}
},
{
"DisplayName": "Existing Account?",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "parentaccountid",
"IsRequired": false
}
},
{
"DisplayName": "Purchase Timeframe",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "purchasetimeframe",
"IsRequired": false
}
},
{
"DisplayName": "Estimated Budget",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "budgetamount",
"IsRequired": false
}
},
{
"DisplayName": "Purchase Process",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "purchaseprocess",
"IsRequired": false
}
},
{
"DisplayName": "Identify Decision Maker",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "decisionmaker",
"IsRequired": false
}
},
{
"DisplayName": "Capture Summary",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "description",
"IsRequired": false
}
},
{
"DisplayName": "Customer Need",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "customerneed",
"IsRequired": false
}
},
{
"DisplayName": "Proposed Solution",
"DisplayLabelId": "guid",
"Type": "Field",
"Field": {
"AttributeName": "proposedsolution",
"IsRequired": false
}
..... cutoff so it isn't too long.
But from this there's no way to tell whether Customer Need and Proposed Solution are part of the current active stage or not and from the screenshot we clearly know they aren't (they are for sure in the next stage and this continues on for all stages).
Please let me know if I have misunderstood something or this is still unclear.
I've read through the documentation but it doesn't really give me an answer for this scenario.
Thanks.