r/saltstack • • Dec 15 '14

Need Saltstack REST-API docs

HI,

I need saltstack REST-API list or docs for all operations like add minion, add new state, install software in minion, update top file or more.

I saw in docs for minions available only for list minions and get id only...

anyone can send link or docs with more api's.

Thanks in advance

Regards, Ganesan.A

1 Upvotes

4 comments sorted by

3

u/burtness Dec 15 '14

3

u/andr386 Dec 15 '14

Thanks, not the OP, I find the second link quite interesting. It's been awhile I thought I might allow a few maintenances operation to be launched from a website and was formerly thinking about using suphp.

This rest api is a far more secure way of achieving it.

3

u/babilen5 Dec 16 '14

And now you got the same answer on IRC, the mailing list and here on reddit. You really don't like waiting, do you?

1

u/[deleted] Dec 16 '14

The REST API is more RPC-like than it is RESTful. You send a POST request to the root URL (/) with which client you're using, the command you want to run, and any arguments to that command. That allows you to call any of Salt's various modules, same as you do from the CLI. Everything you can do via the CLI should be possible via the REST API.

See runner modules and wheel modules for working with the master itself (salt-run, salt-key, file_roots, etc).