virtualmin Remote.cgi and creating domain issue?

I am attempting to take advantage of the remote API for virtualmin. When I attempt to create a non-existing domain it gives me that it exists for some reason.

why or what did I do wrong? here is the url to create it:

https://localhost:10000/virtual-server/remote.cgi?program=create-domain&domain=foo.com&pass=smeg&desc=The server for foo&unix&dir&webmin&web&dns&mail&limits-from-plan&json=1

1 Reply

Unless whatever library you're using to make the request is automatically encoding your URL, your "desc" line is going to cause incorrect behavior. It needs to be quoted and encoded, if it has more than one word.

Try your request without the desc, and see if it behaves correctly. If so, then you'll just need to get it quoted and encoded properly (space is encoded as %20).

If that doesn't straighten it out, bring it over to us in the Virtualmin.com forums, along with the exact error message you're getting, and we'll help get it figured out. Also check the Webmin logs for clues (miniserv.error and webmin.log in /var/webmin).

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct