I have this scenario with SLA's where I want to apply the SLA to the case in the case creation plugin based on the contact's time zone.
So, I have setup 2 SLA's, one for EST and one for PST working hours.
Scenario 1:
Contact is in US Eastern Time Zone, so I want to apply the SLA with working hours from 8am - 5pm ET.
Scenario 2:
Contact is in US Pacific Time Zone, so I want to apply the SLA with working hours from 9am - 5pm PT
This is useful so that the customer in the ET gets paused at 5pm ET and starts again in the morning, and similarly for the customer in the PT.
I can see in the SDK where you can create a new SLAKPIInstance and associate that with the regarding case / incident, but I can't see where the relationship between that instance and the SLA it selects is.
I've reviewed the entitlements way to do this, but that could cause a lot more maintenance because you have to apply it to ALL your account or contact records, of which we have many thousands.
Seems like you should be able to query the appropriate SLA record, then apply it to the case when it gets created?