I've tried to use server action the same as in https://19.react.dev/reference/rsc/server-actions#creating-a-server-action-from-a-server-component but always get this error Error: Only plain objects, and a few built-ins, can be passed to Server Actions. Classes or null prototypes are not supported.
It works when used in action prop but not in onClick - here's repo with both cases https://dub.sh/JYXdozO