import { useQueryClient } from '@tanstack/react-query';
import { useSeamMutation, } from '../use-seam-mutation.js';
export function useCreateAccessCode() {
    const queryClient = useQueryClient();
    return useSeamMutation('/access_codes/create', {
        onSuccess: (data) => {
            queryClient.setQueryData(['access_codes', 'get', { access_code_id: data.access_code_id }], data);
            void queryClient.invalidateQueries({ queryKey: ['access_codes', 'list'] });
        },
    });
}
//# sourceMappingURL=use-create-access-code.js.map