throw new ZendeskApiException(e);
}
}
public IndividualTopicSubscriptionResponse createTopicSubscription(long userId, long topicId) throws ZendeskApiException {
TopicSubscription topicSubscription = new TopicSubscription();
topicSubscription.setUserId(userId);
topicSubscription.setTopicId(topicId);
IndividualTopicSubscriptionResponse individualTopicSubscriptionResponse = new IndividualTopicSubscriptionResponse();
individualTopicSubscriptionResponse.setTopicSubscription(topicSubscription);
try {
return genericPost("topic_subscription.json", individualTopicSubscriptionResponse, IndividualTopicSubscriptionResponse.class);
} catch (Exception e) {