mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-15 15:41:27 +00:00
Fixed service token bug
This commit is contained in:
@@ -37,6 +37,7 @@ export const useCreateServiceToken = () => {
|
||||
return useMutation<CreateServiceTokenRes, {}, CreateServiceTokenDTO>({
|
||||
mutationFn: async (body) => {
|
||||
const { data } = await apiRequest.post('/api/v2/service-token/', body);
|
||||
data.serviceToken += `.${ body.randomBytes}`;
|
||||
return data;
|
||||
},
|
||||
onSuccess: ({ serviceTokenData: { workspace } }) => {
|
||||
|
||||
@@ -18,6 +18,7 @@ export type CreateServiceTokenDTO = {
|
||||
encryptedKey: string;
|
||||
iv: string;
|
||||
tag: string;
|
||||
randomBytes: string;
|
||||
};
|
||||
|
||||
export type CreateServiceTokenRes = {
|
||||
|
||||
Reference in New Issue
Block a user