Package org.apache.camel.component.slack
Class CustomSlackHttpClient
- java.lang.Object
-
- com.slack.api.util.http.SlackHttpClient
-
- org.apache.camel.component.slack.CustomSlackHttpClient
-
- All Implemented Interfaces:
AutoCloseable
public class CustomSlackHttpClient extends com.slack.api.util.http.SlackHttpClient
Slack-api-client use the OkHttpClient v4.x.x We need to override the SlackHttpClient to force the function postJsonBody to work with the v3.x.x
-
-
Constructor Summary
Constructors Constructor Description CustomSlackHttpClient()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description okhttp3.Response
postJsonBody(String url, Object obj)
-
Methods inherited from class com.slack.api.util.http.SlackHttpClient
buildOkHttpClient, buildOkHttpClient, buildSlackHttpClient, buildSlackHttpClient, close, delete, get, getConfig, patchCamelCaseJsonBodyWithBearerHeader, postCamelCaseJsonBodyWithBearerHeader, postForm, postFormWithAuthorizationHeader, postFormWithBearerHeader, postMultipart, putCamelCaseJsonBodyWithBearerHeader, runHttpResponseListeners, setConfig
-
-
-
-
Method Detail
-
postJsonBody
public okhttp3.Response postJsonBody(String url, Object obj) throws IOException
- Overrides:
postJsonBody
in classcom.slack.api.util.http.SlackHttpClient
- Throws:
IOException
-
-