You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+31-5Lines changed: 31 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -69,13 +69,39 @@ String apiSecret = "YOUR API SECRET";
69
69
OpenTok opentok =newOpenTok(apiKey, apiSecret)
70
70
```
71
71
72
-
#### Additional Configurations
73
-
`.requestTimeout(int)` - Change the default HTTP request timeout, default is 60 seconds.
74
-
`.apiUrl(String)` - Change the domain that the SDK points to. Useful when needing to select a specific datacenter or point to a mock version of the API for testing.
75
-
`.proxy(Proxy)` - Using a `Proxy` object, you can configure a proxy server that the http client should use when accessing the OpenTok URLs.
72
+
#### Advanced configuration options
76
73
74
+
You can use `OpenTok.Builder` to set advanced options. This class
75
+
includes the following methods:
77
76
78
-
And make sure you call `close` when you are done to prevent leaked file descriptors.
77
+
-`.requestTimeout(int)` -- Call this to specify the timeout for HTTP requests
78
+
(in seconds). The default timeout is 60 seconds.
79
+
80
+
-`.proxy(Proxy)` -- Using a `java.net.Proxy` object, you can configure a proxy server
81
+
that the HTTP client will use when call the OpenTok REST API.
82
+
83
+
Call the `OpenTok.Builder()` constructor, passing in your API key and secret,
84
+
to instantiate an `OpenTok.Builder` object. Then call the `requestTimeout()`
85
+
or `proxy()` methods (or both). Then call the `build()` method to return an
86
+
OpenTok object.
87
+
88
+
For example, the following code instantiates an OpenTok object, with the
0 commit comments