@tapis/tapisui-api
Version:
Typescript library for making api calls with react query
21 lines (18 loc) • 510 B
text/typescript
import { Pods } from '@tapis/tapis-typescript';
import { apiGenerator, errorDecoder } from '../utils';
const getPodSecrets = (
params: Pods.GetPodCredentialsRequest,
basePath: string,
jwt: string
): Promise<Pods.PodCredentialsResponse> => {
const api: Pods.CredentialsApi = apiGenerator<Pods.CredentialsApi>(
Pods,
Pods.CredentialsApi,
basePath,
jwt
);
return errorDecoder<Pods.PodCredentialsResponse>(() =>
api.getPodCredentials(params)
);
};
export default getPodSecrets;