MCPcopy Index your code
hub / github.com/1Panel-dev/1Panel / testByInfo

Function testByInfo

frontend/src/api/modules/terminal.ts:26–33  ·  view source on GitHub ↗
(params: Host.HostConnTest)

Source from the content-addressed store, hash-verified

24 return http.postLocalNode<Host.HostOperate>(`/hosts`, request);
25};
26export const testByInfo = (params: Host.HostConnTest) => {
27 let request = deepCopy(params) as Host.HostOperate;
28 encodeBase64Fields(request, ['password', 'privateKey']);
29 if (params.isLocal) {
30 return http.post<boolean>(`/settings/ssh/check/info`, request);
31 }
32 return http.postLocalNode<boolean>(`/hosts/test/byinfo`, request);
33};
34export const testByID = (id: number) => {
35 return http.postLocalNode<boolean>(`/hosts/test/byid`, { id: id });
36};

Callers

nothing calls this directly

Calls 4

deepCopyFunction · 0.90
encodeBase64FieldsFunction · 0.90
postMethod · 0.80
postLocalNodeMethod · 0.80

Tested by

no test coverage detected