@@ -17,34 +17,34 @@ import {
1717
1818export const groupService = {
1919 getGroups : ( params : GetGroupsRequest ) : Promise < PaginationResponse < Group > > => {
20- return axiosInstance . get ( 'groups' , { params } ) ;
20+ return axiosInstance . get ( 'v1/ groups' , { params } ) ;
2121 } ,
2222
2323 getGroup : ( { id } : GetGroupRequest ) : Promise < Group > => {
24- return axiosInstance . get ( `groups/${ id } ` ) ;
24+ return axiosInstance . get ( `v1/ groups/${ id } ` ) ;
2525 } ,
2626
2727 createGroup : ( data : CreateGroupRequest ) : Promise < GroupData > => {
28- return axiosInstance . post ( `groups` , data ) ;
28+ return axiosInstance . post ( `v1/ groups` , data ) ;
2929 } ,
3030
3131 updateGroup : ( { id, ...data } : UpdateGroupRequest ) : Promise < GroupData > => {
32- return axiosInstance . put ( `groups/${ id } ` , data ) ;
32+ return axiosInstance . put ( `v1/ groups/${ id } ` , data ) ;
3333 } ,
3434
3535 getGroupUsers : ( { id } : GetGroupUsersRequest ) : Promise < PaginationResponse < GroupUser > > => {
36- return axiosInstance . get ( `groups/${ id } /users` ) ;
36+ return axiosInstance . get ( `v1/ groups/${ id } /users` ) ;
3737 } ,
3838
3939 addGroupUser : ( { groupId, userId, ...data } : AddGroupUserRequest ) : Promise < null > => {
40- return axiosInstance . post ( `groups/${ groupId } /users/${ userId } ` , data ) ;
40+ return axiosInstance . post ( `v1/ groups/${ groupId } /users/${ userId } ` , data ) ;
4141 } ,
4242
4343 updateGroupUser : ( { groupId, userId, ...data } : UpdateGroupUserRequest ) : Promise < null > => {
44- return axiosInstance . put ( `groups/${ groupId } /users/${ userId } ` , data ) ;
44+ return axiosInstance . put ( `v1/ groups/${ groupId } /users/${ userId } ` , data ) ;
4545 } ,
4646
4747 deleteGroupUser : ( { groupId, userId } : DeleteGroupUserRequest ) : Promise < null > => {
48- return axiosInstance . delete ( `groups/${ groupId } /users/${ userId } ` ) ;
48+ return axiosInstance . delete ( `v1/ groups/${ groupId } /users/${ userId } ` ) ;
4949 } ,
5050} ;
0 commit comments