Publish Layer dynamically with new parameters

Hi everyone, I am trying to publish the layer dynamically which is not already published, is this possible?

each and every time I need to pass different set of parameters and get the related data on the fly, please suggest if any solutions.

Which software are you using? Wasn’t clear from your post.