@onkernel/sdk 0.24.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +38 -0
- package/LICENSE +1 -1
- package/README.md +9 -4
- package/client.d.mts +6 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +6 -6
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/package.json +2 -2
- package/resources/agents/agents.d.mts +2 -2
- package/resources/agents/agents.d.mts.map +1 -1
- package/resources/agents/agents.d.ts +2 -2
- package/resources/agents/agents.d.ts.map +1 -1
- package/resources/agents/agents.js.map +1 -1
- package/resources/agents/agents.mjs.map +1 -1
- package/resources/agents/auth/auth.d.mts +135 -126
- package/resources/agents/auth/auth.d.mts.map +1 -1
- package/resources/agents/auth/auth.d.ts +135 -126
- package/resources/agents/auth/auth.d.ts.map +1 -1
- package/resources/agents/auth/auth.js +2 -18
- package/resources/agents/auth/auth.js.map +1 -1
- package/resources/agents/auth/auth.mjs +2 -18
- package/resources/agents/auth/auth.mjs.map +1 -1
- package/resources/agents/auth/index.d.mts +2 -2
- package/resources/agents/auth/index.d.mts.map +1 -1
- package/resources/agents/auth/index.d.ts +2 -2
- package/resources/agents/auth/index.d.ts.map +1 -1
- package/resources/agents/auth/index.js.map +1 -1
- package/resources/agents/auth/index.mjs.map +1 -1
- package/resources/agents/auth/invocations.d.mts +28 -33
- package/resources/agents/auth/invocations.d.mts.map +1 -1
- package/resources/agents/auth/invocations.d.ts +28 -33
- package/resources/agents/auth/invocations.d.ts.map +1 -1
- package/resources/agents/auth/invocations.js +5 -20
- package/resources/agents/auth/invocations.js.map +1 -1
- package/resources/agents/auth/invocations.mjs +5 -20
- package/resources/agents/auth/invocations.mjs.map +1 -1
- package/resources/agents/index.d.mts +1 -1
- package/resources/agents/index.d.mts.map +1 -1
- package/resources/agents/index.d.ts +1 -1
- package/resources/agents/index.d.ts.map +1 -1
- package/resources/agents/index.js.map +1 -1
- package/resources/agents/index.mjs.map +1 -1
- package/resources/browsers/browsers.d.mts +84 -3
- package/resources/browsers/browsers.d.mts.map +1 -1
- package/resources/browsers/browsers.d.ts +84 -3
- package/resources/browsers/browsers.d.ts.map +1 -1
- package/resources/browsers/browsers.js +13 -0
- package/resources/browsers/browsers.js.map +1 -1
- package/resources/browsers/browsers.mjs +13 -0
- package/resources/browsers/browsers.mjs.map +1 -1
- package/resources/browsers/index.d.mts +2 -2
- package/resources/browsers/index.d.mts.map +1 -1
- package/resources/browsers/index.d.ts +2 -2
- package/resources/browsers/index.d.ts.map +1 -1
- package/resources/browsers/index.js.map +1 -1
- package/resources/browsers/index.mjs.map +1 -1
- package/resources/browsers/process.d.mts +52 -1
- package/resources/browsers/process.d.mts.map +1 -1
- package/resources/browsers/process.d.ts +52 -1
- package/resources/browsers/process.d.ts.map +1 -1
- package/resources/browsers/process.js +19 -0
- package/resources/browsers/process.js.map +1 -1
- package/resources/browsers/process.mjs +19 -0
- package/resources/browsers/process.mjs.map +1 -1
- package/resources/credentials.d.mts +107 -16
- package/resources/credentials.d.mts.map +1 -1
- package/resources/credentials.d.ts +107 -16
- package/resources/credentials.d.ts.map +1 -1
- package/resources/credentials.js +33 -14
- package/resources/credentials.js.map +1 -1
- package/resources/credentials.mjs +33 -14
- package/resources/credentials.mjs.map +1 -1
- package/resources/index.d.mts +3 -3
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -3
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/proxies.d.mts +153 -1
- package/resources/proxies.d.mts.map +1 -1
- package/resources/proxies.d.ts +153 -1
- package/resources/proxies.d.ts.map +1 -1
- package/resources/proxies.js +6 -0
- package/resources/proxies.js.map +1 -1
- package/resources/proxies.mjs +6 -0
- package/resources/proxies.mjs.map +1 -1
- package/src/client.ts +8 -0
- package/src/resources/agents/agents.ts +0 -4
- package/src/resources/agents/auth/auth.ts +146 -136
- package/src/resources/agents/auth/index.ts +0 -3
- package/src/resources/agents/auth/invocations.ts +31 -39
- package/src/resources/agents/index.ts +0 -2
- package/src/resources/browsers/browsers.ts +104 -0
- package/src/resources/browsers/index.ts +4 -0
- package/src/resources/browsers/process.ts +68 -0
- package/src/resources/credentials.ts +127 -18
- package/src/resources/index.ts +4 -0
- package/src/resources/proxies.ts +248 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/src/resources/proxies.ts
CHANGED
|
@@ -37,6 +37,13 @@ export class Proxies extends APIResource {
|
|
|
37
37
|
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
38
38
|
});
|
|
39
39
|
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Run a health check on the proxy to verify it's working.
|
|
43
|
+
*/
|
|
44
|
+
check(id: string, options?: RequestOptions): APIPromise<ProxyCheckResponse> {
|
|
45
|
+
return this._client.post(path`/proxies/${id}/check`, options);
|
|
46
|
+
}
|
|
40
47
|
}
|
|
41
48
|
|
|
42
49
|
/**
|
|
@@ -61,6 +68,11 @@ export interface ProxyCreateResponse {
|
|
|
61
68
|
| ProxyCreateResponse.MobileProxyConfig
|
|
62
69
|
| ProxyCreateResponse.CustomProxyConfig;
|
|
63
70
|
|
|
71
|
+
/**
|
|
72
|
+
* IP address that the proxy uses when making requests.
|
|
73
|
+
*/
|
|
74
|
+
ip_address?: string;
|
|
75
|
+
|
|
64
76
|
/**
|
|
65
77
|
* Timestamp of the last health check performed on this proxy.
|
|
66
78
|
*/
|
|
@@ -281,6 +293,11 @@ export interface ProxyRetrieveResponse {
|
|
|
281
293
|
| ProxyRetrieveResponse.MobileProxyConfig
|
|
282
294
|
| ProxyRetrieveResponse.CustomProxyConfig;
|
|
283
295
|
|
|
296
|
+
/**
|
|
297
|
+
* IP address that the proxy uses when making requests.
|
|
298
|
+
*/
|
|
299
|
+
ip_address?: string;
|
|
300
|
+
|
|
284
301
|
/**
|
|
285
302
|
* Timestamp of the last health check performed on this proxy.
|
|
286
303
|
*/
|
|
@@ -504,6 +521,11 @@ export namespace ProxyListResponse {
|
|
|
504
521
|
| ProxyListResponseItem.MobileProxyConfig
|
|
505
522
|
| ProxyListResponseItem.CustomProxyConfig;
|
|
506
523
|
|
|
524
|
+
/**
|
|
525
|
+
* IP address that the proxy uses when making requests.
|
|
526
|
+
*/
|
|
527
|
+
ip_address?: string;
|
|
528
|
+
|
|
507
529
|
/**
|
|
508
530
|
* Timestamp of the last health check performed on this proxy.
|
|
509
531
|
*/
|
|
@@ -703,6 +725,231 @@ export namespace ProxyListResponse {
|
|
|
703
725
|
}
|
|
704
726
|
}
|
|
705
727
|
|
|
728
|
+
/**
|
|
729
|
+
* Configuration for routing traffic through a proxy.
|
|
730
|
+
*/
|
|
731
|
+
export interface ProxyCheckResponse {
|
|
732
|
+
/**
|
|
733
|
+
* Proxy type to use. In terms of quality for avoiding bot-detection, from best to
|
|
734
|
+
* worst: `mobile` > `residential` > `isp` > `datacenter`.
|
|
735
|
+
*/
|
|
736
|
+
type: 'datacenter' | 'isp' | 'residential' | 'mobile' | 'custom';
|
|
737
|
+
|
|
738
|
+
id?: string;
|
|
739
|
+
|
|
740
|
+
/**
|
|
741
|
+
* Configuration specific to the selected proxy `type`.
|
|
742
|
+
*/
|
|
743
|
+
config?:
|
|
744
|
+
| ProxyCheckResponse.DatacenterProxyConfig
|
|
745
|
+
| ProxyCheckResponse.IspProxyConfig
|
|
746
|
+
| ProxyCheckResponse.ResidentialProxyConfig
|
|
747
|
+
| ProxyCheckResponse.MobileProxyConfig
|
|
748
|
+
| ProxyCheckResponse.CustomProxyConfig;
|
|
749
|
+
|
|
750
|
+
/**
|
|
751
|
+
* IP address that the proxy uses when making requests.
|
|
752
|
+
*/
|
|
753
|
+
ip_address?: string;
|
|
754
|
+
|
|
755
|
+
/**
|
|
756
|
+
* Timestamp of the last health check performed on this proxy.
|
|
757
|
+
*/
|
|
758
|
+
last_checked?: string;
|
|
759
|
+
|
|
760
|
+
/**
|
|
761
|
+
* Readable name of the proxy.
|
|
762
|
+
*/
|
|
763
|
+
name?: string;
|
|
764
|
+
|
|
765
|
+
/**
|
|
766
|
+
* Protocol to use for the proxy connection.
|
|
767
|
+
*/
|
|
768
|
+
protocol?: 'http' | 'https';
|
|
769
|
+
|
|
770
|
+
/**
|
|
771
|
+
* Current health status of the proxy.
|
|
772
|
+
*/
|
|
773
|
+
status?: 'available' | 'unavailable';
|
|
774
|
+
}
|
|
775
|
+
|
|
776
|
+
export namespace ProxyCheckResponse {
|
|
777
|
+
/**
|
|
778
|
+
* Configuration for a datacenter proxy.
|
|
779
|
+
*/
|
|
780
|
+
export interface DatacenterProxyConfig {
|
|
781
|
+
/**
|
|
782
|
+
* ISO 3166 country code. Defaults to US if not provided.
|
|
783
|
+
*/
|
|
784
|
+
country?: string;
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
/**
|
|
788
|
+
* Configuration for an ISP proxy.
|
|
789
|
+
*/
|
|
790
|
+
export interface IspProxyConfig {
|
|
791
|
+
/**
|
|
792
|
+
* ISO 3166 country code. Defaults to US if not provided.
|
|
793
|
+
*/
|
|
794
|
+
country?: string;
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
/**
|
|
798
|
+
* Configuration for residential proxies.
|
|
799
|
+
*/
|
|
800
|
+
export interface ResidentialProxyConfig {
|
|
801
|
+
/**
|
|
802
|
+
* Autonomous system number. See https://bgp.potaroo.net/cidr/autnums.html
|
|
803
|
+
*/
|
|
804
|
+
asn?: string;
|
|
805
|
+
|
|
806
|
+
/**
|
|
807
|
+
* City name (no spaces, e.g. `sanfrancisco`). If provided, `country` must also be
|
|
808
|
+
* provided.
|
|
809
|
+
*/
|
|
810
|
+
city?: string;
|
|
811
|
+
|
|
812
|
+
/**
|
|
813
|
+
* ISO 3166 country code.
|
|
814
|
+
*/
|
|
815
|
+
country?: string;
|
|
816
|
+
|
|
817
|
+
/**
|
|
818
|
+
* @deprecated Operating system of the residential device.
|
|
819
|
+
*/
|
|
820
|
+
os?: 'windows' | 'macos' | 'android';
|
|
821
|
+
|
|
822
|
+
/**
|
|
823
|
+
* Two-letter state code.
|
|
824
|
+
*/
|
|
825
|
+
state?: string;
|
|
826
|
+
|
|
827
|
+
/**
|
|
828
|
+
* US ZIP code.
|
|
829
|
+
*/
|
|
830
|
+
zip?: string;
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
/**
|
|
834
|
+
* Configuration for mobile proxies.
|
|
835
|
+
*/
|
|
836
|
+
export interface MobileProxyConfig {
|
|
837
|
+
/**
|
|
838
|
+
* Autonomous system number. See https://bgp.potaroo.net/cidr/autnums.html
|
|
839
|
+
*/
|
|
840
|
+
asn?: string;
|
|
841
|
+
|
|
842
|
+
/**
|
|
843
|
+
* Mobile carrier.
|
|
844
|
+
*/
|
|
845
|
+
carrier?:
|
|
846
|
+
| 'a1'
|
|
847
|
+
| 'aircel'
|
|
848
|
+
| 'airtel'
|
|
849
|
+
| 'att'
|
|
850
|
+
| 'celcom'
|
|
851
|
+
| 'chinamobile'
|
|
852
|
+
| 'claro'
|
|
853
|
+
| 'comcast'
|
|
854
|
+
| 'cox'
|
|
855
|
+
| 'digi'
|
|
856
|
+
| 'dt'
|
|
857
|
+
| 'docomo'
|
|
858
|
+
| 'dtac'
|
|
859
|
+
| 'etisalat'
|
|
860
|
+
| 'idea'
|
|
861
|
+
| 'kyivstar'
|
|
862
|
+
| 'meo'
|
|
863
|
+
| 'megafon'
|
|
864
|
+
| 'mtn'
|
|
865
|
+
| 'mtnza'
|
|
866
|
+
| 'mts'
|
|
867
|
+
| 'optus'
|
|
868
|
+
| 'orange'
|
|
869
|
+
| 'qwest'
|
|
870
|
+
| 'reliance_jio'
|
|
871
|
+
| 'robi'
|
|
872
|
+
| 'sprint'
|
|
873
|
+
| 'telefonica'
|
|
874
|
+
| 'telstra'
|
|
875
|
+
| 'tmobile'
|
|
876
|
+
| 'tigo'
|
|
877
|
+
| 'tim'
|
|
878
|
+
| 'verizon'
|
|
879
|
+
| 'vimpelcom'
|
|
880
|
+
| 'vodacomza'
|
|
881
|
+
| 'vodafone'
|
|
882
|
+
| 'vivo'
|
|
883
|
+
| 'zain'
|
|
884
|
+
| 'vivabo'
|
|
885
|
+
| 'telenormyanmar'
|
|
886
|
+
| 'kcelljsc'
|
|
887
|
+
| 'swisscom'
|
|
888
|
+
| 'singtel'
|
|
889
|
+
| 'asiacell'
|
|
890
|
+
| 'windit'
|
|
891
|
+
| 'cellc'
|
|
892
|
+
| 'ooredoo'
|
|
893
|
+
| 'drei'
|
|
894
|
+
| 'umobile'
|
|
895
|
+
| 'cableone'
|
|
896
|
+
| 'proximus'
|
|
897
|
+
| 'tele2'
|
|
898
|
+
| 'mobitel'
|
|
899
|
+
| 'o2'
|
|
900
|
+
| 'bouygues'
|
|
901
|
+
| 'free'
|
|
902
|
+
| 'sfr'
|
|
903
|
+
| 'digicel';
|
|
904
|
+
|
|
905
|
+
/**
|
|
906
|
+
* City name (no spaces, e.g. `sanfrancisco`). If provided, `country` must also be
|
|
907
|
+
* provided.
|
|
908
|
+
*/
|
|
909
|
+
city?: string;
|
|
910
|
+
|
|
911
|
+
/**
|
|
912
|
+
* ISO 3166 country code
|
|
913
|
+
*/
|
|
914
|
+
country?: string;
|
|
915
|
+
|
|
916
|
+
/**
|
|
917
|
+
* Two-letter state code.
|
|
918
|
+
*/
|
|
919
|
+
state?: string;
|
|
920
|
+
|
|
921
|
+
/**
|
|
922
|
+
* US ZIP code.
|
|
923
|
+
*/
|
|
924
|
+
zip?: string;
|
|
925
|
+
}
|
|
926
|
+
|
|
927
|
+
/**
|
|
928
|
+
* Configuration for a custom proxy (e.g., private proxy server).
|
|
929
|
+
*/
|
|
930
|
+
export interface CustomProxyConfig {
|
|
931
|
+
/**
|
|
932
|
+
* Proxy host address or IP.
|
|
933
|
+
*/
|
|
934
|
+
host: string;
|
|
935
|
+
|
|
936
|
+
/**
|
|
937
|
+
* Proxy port.
|
|
938
|
+
*/
|
|
939
|
+
port: number;
|
|
940
|
+
|
|
941
|
+
/**
|
|
942
|
+
* Whether the proxy has a password.
|
|
943
|
+
*/
|
|
944
|
+
has_password?: boolean;
|
|
945
|
+
|
|
946
|
+
/**
|
|
947
|
+
* Username for proxy authentication.
|
|
948
|
+
*/
|
|
949
|
+
username?: string;
|
|
950
|
+
}
|
|
951
|
+
}
|
|
952
|
+
|
|
706
953
|
export interface ProxyCreateParams {
|
|
707
954
|
/**
|
|
708
955
|
* Proxy type to use. In terms of quality for avoiding bot-detection, from best to
|
|
@@ -913,6 +1160,7 @@ export declare namespace Proxies {
|
|
|
913
1160
|
type ProxyCreateResponse as ProxyCreateResponse,
|
|
914
1161
|
type ProxyRetrieveResponse as ProxyRetrieveResponse,
|
|
915
1162
|
type ProxyListResponse as ProxyListResponse,
|
|
1163
|
+
type ProxyCheckResponse as ProxyCheckResponse,
|
|
916
1164
|
type ProxyCreateParams as ProxyCreateParams,
|
|
917
1165
|
};
|
|
918
1166
|
}
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.26.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.26.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.26.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.26.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|