How to resolve "403:The request is understood, but it has been refused." exception.

How to resolve "403:The request is understood, but it has been refused." exception.

book

Article ID: KB0081997

calendar_today

Updated On:

Products Versions
TIBCO ActiveMatrix BusinessWorks Plug-in for Twitter 1.0.0

Description

When TwitterPublish activity of TIBCO ActiveMatrix BusinessWorks Plug-in for Twitter is executed, it fails to connect to the Twitter server and returns the following exception.​ See attached snapshot.

------
403:The request is understood, but it has been refused. An accompanying error message will explain why. This code is used when requests are being denied due to update limits (https://support.twitter.com/articles/15364-about-twitter-limits-update-api-dm-and-following).
message - SSL is required
code - 92
.
    at com.tibco.plugin.twitter.activities.TwitterPublishActivity.postTweet(TwitterPublishActivity.java:209)
    at com.tibco.plugin.twitter.activities.TwitterPublishActivity.eval(TwitterPublishActivity.java:98)
    at com.tibco.pe.plugin.Activity.eval(Unknown Source)
    at com.tibco.pe.core.TaskImpl.eval(Unknown Source)
    at com.tibco.pe.core.Job.a(Unknown Source)
    at com.tibco.pe.core.Job.k(Unknown Source)
    at com.tibco.pe.core.JobDispatcher$JobCourier.a(Unknown Source)
    at com.tibco.pe.core.JobDispatcher$JobCourier.run(Unknown Source)
<?xml version="1.0" encoding="UTF-8"?>

<Data>
    <ns0:TwitterAPIException xmlns:ns0="http://schemas.tibco.com/bw/plugins/twitter/TwitterExceptions">
        <msg>403:The request is understood, but it has been refused. An accompanying error message will explain why. This code is used when requests are being denied due to update limits (https://support.twitter.com/articles/15364-about-twitter-limits-update-api-dm-and-following).
message - SSL is required
code - 92
.</msg>
        <msgCode>BW-TW-100403</msgCode>
    </ns0:TwitterAPIException>
</Data> 
---------

Issue/Introduction

Add the property "java.property.twitter4j.http.useSSL=true" in the designer.tra file.

Environment

All supported platforms

Resolution

This issue is due to only SSL connections are allowed in Twitter API endpoints. Therefore a SSL connection is required to be initialized from TIBCO ActiveMatrix BusinessWorks Plug-in for Twitter.

To resolve this issue, Add the property "java.property.twitter4j.http.useSSL=true" in the designer.tra file to change the communication from HTTP to HTTPS.

Attachments

How to resolve "403:The request is understood, but it has been refused." exception. get_app