[Freeipa-devel] Communicating with FreeIPA via curl

Adam Young ayoung at redhat.com
Wed Jul 21 20:13:12 UTC 2010


The web UI uses  JSON RPC to talk to the server.  As I look at implement 
more and more functionality, I find I want to see the JSON messages much 
the same way that the ipa command line can show the XML-RPC messages.  A 
little trial and error and I got it working:


curl -v  \
          -H "Content-Type:application/json" \
          -H "Accept:applicaton/json"\
          --negotiate -u : \
          --cacert /etc/ipa/ca.crt  \
          -d "{\"method\":\"user_find\",\"params\":[[\"\"],{}],\"id\":0}"   \
          -X POST       https://`hostname`/ipa/json


Here's the explanation if you want it.

http://adam.younglogic.com/?p=897




More information about the Freeipa-devel mailing list