I want to generate a rest api in odoo so that it can be used in other languages. I have used below api's
- http://URL_with_PORT/{}/xmlrpc/2/common
- http://URL_with_PORT/{}/xmlrpc/2/object
but when I validated it using postman it is giving me error.
I want to generate a rest api in odoo so that it can be used in other languages. I have used below api's
but when I validated it using postman it is giving me error.
You don't need the curly braces in the URL. Just send it to the xmlrpc/2/common
endpoint, as per...
http://<server:?port>/xmlrpc/2/common
You need to set the verb to POST
, and the body to raw
with XML
.
Then send in the following XML in the form as per the documentation.
<?xml version='1.0'?>
<methodCall>
<methodName>version</methodName>
</methodCall>
This will return the server version info as per the examples used in the External API documentation in an XML response.
Postman isn't the best client to use XML-RPC calls, take a look at XML RPC GUI for developers in Windows?. You have to create a raw request and then send it. Using SoapUI would be much easier.