Policy web services

To control policy period referral reasons and activities from an external system, use the PolicyAPI web service.

Add a referral reason

The PolicyAPI method addReferralReasonToPolicyPeriod adds a period referral reason to the policy period. For example, if a claim management system notices a lot of claims on a policy, it could notify PolicyCenter of the issue. PolicyCenter could associate the issue with the appropriate policy period. The renewal workflow could set risk-related properties on the policy period before authorizing renewal of that policy.

function addReferralReason(policyId : String, issueTypeCode : String, issueKey : String,
   shortDescription : String, longDescription : String, value : String) : String

The method accepts the following arguments.

  • Policy ID (String)
  • Issue type code (String)
  • Issue key (String)
  • Short description (String)
  • Long description (String)
  • Referral reason, which must be valid for the comparator of the UWIssueType.

The method returns the public ID of the new or existing referral reason. PolicyCenter sets the status of the new referral reason to Open.

Close a referral reason

The closeReferralReason method closes a referral reason.

function closeReferralReason(policyId : String, issueTypeCode : String, issueKey : String)

The method accepts the following arguments.

  • Policy period public ID
  • Code that matches the UWIssueType.Code of the referral reason to close
  • Issue key identifier for the referral reason

The method has no return value.

Add activity from pattern

There are several methods for adding activities from patterns and assigning them.

Add activity and auto-assign

To add an activity using an activity pattern from an external system and auto-assign the activity, call the IPolicyAPI web service method addActivityFromPatternAndAutoAssign.

function addActivityFromPatternAndAutoAssign(policyId : String, activityType : ActivityType,
   activityPatternCode : String, activityFields : Activity) : String {

The activityfields argument contains an Activity object, which is not the Guidewire entity. Instead, it is a XML type defined using the Guidewire XML (GX) modeler.

Set the important properties for a new activity, such as the Subject and the Description properties. PolicyCenter copies over non-null fields form the activityfields argument to the new activity.

The addActivityFromPatternAndAutoAssign method performs the following operations.

  1. Try to generate an activity from the specified activity pattern.
  2. Initialize the activity with the following fields from the activity pattern: Pattern, Type, Subject, Description, Mandatory, Priority, Recurring, and Command.
  3. Calculate the target date using the following properties from the pattern: TargetStartPoint, TargetDays, TargetHours, and TargetIncludeDays.
  4. Calculate the escalation date using the following properties from the pattern EscalationStartPt, EscalationDays, EscalationHours, and EscalationInclDays. If the activity does not use those properties, PolicyCenter does not set the target and/or escalation date. If the target date after the escalation date, then PolicyCenter sets the target date to the escalation date.
  5. PolicyCenter sets the activity policy ID to the specified policy ID. The previous user ID for the activity (the previousUserId property) is set to the current user.
  6. PolicyCenter assigns the newly created activity to a group and/or user using the Assignment Engine.

    This step is the auto-assignment step.

  7. PolicyCenter saves the activity in the database.
  8. The method returns the ID of the newly created activity.

Add activity and assign to user

If you want to assign the new activity to a specific group and user, call the addActivityFromPatternAndAssignToUser method.

function addActivityFromPatternAndAssignToUser(policyId : String, userId : String, groupId : String,
  activityType : ActivityType, activityPatternCode : String, activityFields : Activity) : String {

The method performs the same operations as the related addActivityFromPatternAndAutoAssign method, except that it assigns the activity to the specified group and user.

Add activity and assign to queue

If you want to assign the new activity to a specific group and user, call the addActivityFromPatternAndAssignToQueue method.

function addActivityFromPatternAndAssignToQueue(policyId : String, queueId : String, 
  activityType : ActivityType, activityPatternCode : String, activityFields : Activity) : String {

The method performs the same operations as the related addActivityFromPatternAndAutoAssign method, except that it assigns the activity to the specified queue.