@Override
    public PutContactPolicyResult putContactPolicy(PutContactPolicyRequest request) {
        request = beforeClientExecution(request);
        return executePutContactPolicy(request);
    }
<p>
Adds a resource policy to the specified contact or escalation plan. The resource policy is used to share the
contact or escalation plan using Resource Access Manager (RAM). For more information about cross-account sharing,
see <a href="https://docs.aws.amazon.com/incident-manager/latest/userguide/xa.html">Setting up cross-account
functionality</a>.
</p>

@param putContactPolicyRequest
@return Result of the PutContactPolicy operation returned by the service.
@throws AccessDeniedException
        You don't have sufficient access to perform this operation.
@throws ConflictException
        Updating or deleting a resource causes an inconsistent state.
@throws ValidationException
        The input fails to satisfy the constraints specified by an Amazon Web Services service.
@throws ResourceNotFoundException
        Request references a resource that doesn't exist.
@throws ThrottlingException
        The request was denied due to request throttling.
@throws InternalServerException
        Unexpected error occurred while processing the request.
@sample AWSSSMContacts.PutContactPolicy
@see <a href="http://docs.aws.amazon.com/goto/WebAPI/ssm-contacts-2021-05-03/PutContactPolicy" target="_top">AWS
     API Documentation</a>
aws-java-sdk-ssmcontacts/src/main/java/com/amazonaws/services/ssmcontacts/AWSSSMContactsClient.java