#odooexternalapi
How to list records using Odoo external API using XML-RPC, this short video details listing records in odoo.
Records can be listed and filtered via search().
external-api code:
url = ”
db = ‘test_local_enterprise_db’
username = ’14’
password = ’14’
import xmlrpc.client
common = xmlrpc.client.ServerProxy(‘{}/xmlrpc/2/common’.format(url))
version = common.version()
print(“version”, version)
uid = common.authenticate(db, username, password, {})
print(“uid = “,uid)
models = xmlrpc.client.ServerProxy(‘{}/xmlrpc/2/object’.format(url))
partner = models.execute_kw(db, uid, password,’res.partner’, ‘search’,[[]])
print(“partner=”,partner)
company = models.execute_kw(db, uid, password,’res.partner’, ‘search’,[[[‘is_company’, ‘=’, True]]])
print(“company=”,company)
#List #Records #Odoo #External #API #XMLRPC