I am thinking for a possibility, I have some clients and they want to execute some powershell query remotely but i am not willing to share the credentials. Is there any way i can do this, means anything like generating a public or private key or any other way, which i will give to them and then can execute the query remotely?
Take a look at System Frontier. It works across any version of PowerShell and has a very flexible RBAC model that can be configured through a web GUI. You just import your script, configure users to roles and now they can run your code without having any direct access to the remote targets or admin credentials.
It will even build a GUI for you to capture user input and map it to command-line parameters.