For the Box Java SDK 4.x-style interface using com.box.sdk.BoxAPIConnection, configure the connection that the application passes to its resource operations:

var api = new com.box.sdk.BoxAPIConnection(accessToken);
api.setProxy(new java.net.Proxy(
    java.net.Proxy.Type.HTTP,
    new java.net.InetSocketAddress("proxy.example", 8080)));

Use the application’s existing Box accessToken. If the proxy requires an account, set it through api.setProxyUsername and api.setProxyPassword; those credentials authenticate the intermediary.

The Box API remains the HTTPS destination, reached through an HTTP proxy tunnel; the HTTP proxy list provides public endpoint candidates for that route. Keep resource calls on this configured api instance.

Finish configuration before concurrent operations begin and keep the route stable for the workload. Generated Box clients expose a different configuration interface from the BoxAPIConnection generation shown here.

Artiglyn mynjee