@@ -42,10 +42,19 @@ export class Proxies extends APIResource {
4242 }
4343
4444 /**
45- * Run a health check on the proxy to verify it's working.
45+ * Run a health check on the proxy to verify it's working. Optionally specify a URL
46+ * to test reachability against a specific target. For ISP and datacenter proxies,
47+ * this reliably tests whether the target site is reachable from the proxy's stable
48+ * exit IP. For residential and mobile proxies, the exit node varies between
49+ * requests, so this validates proxy configuration and connectivity rather than
50+ * guaranteeing site-specific reachability.
4651 */
47- check ( id : string , options ?: RequestOptions ) : APIPromise < ProxyCheckResponse > {
48- return this . _client . post ( path `/proxies/${ id } /check` , options ) ;
52+ check (
53+ id : string ,
54+ body : ProxyCheckParams | null | undefined = { } ,
55+ options ?: RequestOptions ,
56+ ) : APIPromise < ProxyCheckResponse > {
57+ return this . _client . post ( path `/proxies/${ id } /check` , { body, ...options } ) ;
4958 }
5059}
5160
@@ -1183,12 +1192,29 @@ export namespace ProxyCreateParams {
11831192 }
11841193}
11851194
1195+ export interface ProxyCheckParams {
1196+ /**
1197+ * An optional URL to test reachability against. If provided, the proxy check will
1198+ * test connectivity to this URL instead of the default test URLs. Only HTTP and
1199+ * HTTPS schemes are allowed, and the URL must resolve to a public IP address. For
1200+ * ISP and datacenter proxies, the exit IP is stable, so a successful check
1201+ * reliably indicates that subsequent browser sessions will reach the target site
1202+ * with the same IP. For residential and mobile proxies, the exit node changes
1203+ * between requests, so a successful check validates proxy configuration but does
1204+ * not guarantee that a subsequent browser session will use the same exit IP or
1205+ * reach the same site — it is useful for verifying credentials and connectivity,
1206+ * not for predicting site-specific behavior.
1207+ */
1208+ url ?: string ;
1209+ }
1210+
11861211export declare namespace Proxies {
11871212 export {
11881213 type ProxyCreateResponse as ProxyCreateResponse ,
11891214 type ProxyRetrieveResponse as ProxyRetrieveResponse ,
11901215 type ProxyListResponse as ProxyListResponse ,
11911216 type ProxyCheckResponse as ProxyCheckResponse ,
11921217 type ProxyCreateParams as ProxyCreateParams ,
1218+ type ProxyCheckParams as ProxyCheckParams ,
11931219 } ;
11941220}
0 commit comments