Class ZendeskRequestInterceptor



  • public class ZendeskRequestInterceptor
    extends java.lang.Object
    This request interceptor will add headers to all requests that are made through the means of a retrofit2.Retrofit
    • Adds a User-Agent header to requests
    • Adds an Accept header with value application/json to all requests
    • Adds a Client-Identifier header to requests if it is available
    • Constructor Summary

      Constructors 
      Constructor and Description
      ZendeskRequestInterceptor(java.lang.String oauthId, java.lang.String userAgent, java.lang.String zendeskLocaleTag) 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      Response intercept(Chain chain) 
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ZendeskRequestInterceptor

        public ZendeskRequestInterceptor(java.lang.String oauthId,
                                         java.lang.String userAgent,
                                         java.lang.String zendeskLocaleTag)
    • Method Detail

      • intercept

        public Response intercept(Chain chain)
                           throws java.io.IOException
        Throws:
        java.io.IOException