title: Configuring admin APIs in client project
body: <p>I need to use admin API in my client project. How do I create/inject the adminAPI bean into the client project.</p>
  <p>Here is the Admin API:</p>
  <pre><code>@Configuration
  public class QOCAdminConfig
  {
   
      @Bean
      public QOCAdminSettings qocAdminSettings()
      {
          return new QOCAdminSettings();
      }
      
      @Bean
      public QOCAdminEndpoint qocAdminEndpoint()
      {
          QOCAdminSettings settings = qocAdminSettings();
          AccessTokenSource serviceAuth = new ServiceAuth(settings.authUrl, settings.authUser, settings.authSecret);
          EndpointConfig config = EndpointConfig.builder()
                  .withBaseUrl(settings.partnerAdminUrl)
                  .withServiceAuth(serviceAuth)
                  .withFailureHandler(new PartnerAdminFailureHandler())
                  .build();
          return new QOCAdminEndpoint(config);
      }
     
      public static class QOCAdminSettings
      {
          @Value(&quot;${qoc.gatewayService.auth.user}&quot;)
          private String authUser;
          
          @Value(&quot;${qoc.gatewayService.auth.secret}&quot;)
          private String authSecret;
          
          @Value(&quot;${qoc.gatewayService.auth.url}&quot;)
          private String authUrl;
          
          @Value(&quot;${qoc.partnerAdmin.url}&quot;)
          private String partnerAdminUrl;
  
          @Override
          public String toString()
          {
              return &quot;QOCAdminSettings [authUser=&quot; + authUser + &quot;, authSecret=&quot; + authSecret + &quot;, authUrl=&quot;
                      + authUrl + &quot;, partnerAdminUrl=&quot; + partnerAdminUrl + &quot;]&quot;;
          }
         
          
      }
  }
  </code></pre>
  <p>In my client code I need to use the endpoint methods like,the client project is using old spring version4.1.5.RELEASE</p>
  <pre><code>@Autowired
   QOCAdminEndpoint endpoint;
  
  endpoint.getSelectedEndpoint();
  </code></pre>
  <p>How to define these configs in my client code.</p>