{"id":21638,"library":"odoorpc","title":"OdooRPC Client","description":"OdooRPC is a Python package providing an easy way to pilot your Odoo servers through RPC. It supports Odoo versions 8.0 through 17.0+ and handles authentication, model operations, and RPC calls. Current version: 0.10.1. Release cadence: irregular, maintained by OCA.","status":"active","version":"0.10.1","language":"python","source_language":"en","source_url":"https://github.com/OCA/odoorpc","tags":["odoo","rpc","erp","client"],"install":[{"cmd":"pip install odoorpc","lang":"bash","label":"Install OdooRPC"}],"dependencies":[{"reason":"Handles XML-RPC communication when using XML-RPC protocol (default)","package":"suds-community","optional":false}],"imports":[{"note":"Class is named ODOO (all caps) not OdooRPC","wrong":"from odoorpc import OdooRPC","symbol":"ODOO","correct":"from odoorpc import ODOO"},{"note":"Method is .login(), not .authenticate()","wrong":"odoo.authenticate('db', 'user', 'pass')","symbol":"login method","correct":"odoo.login('db', 'user', 'pass')"}],"quickstart":{"code":"from odoorpc import ODOO\n\nodoo = ODOO('localhost', port=8069, protocol='jsonrpc')\nodoo.login('database_name', 'user', 'password')\nuser = odoo.env.user\nprint(user.name)\n# Search records\npartners = odoo.env['res.partner'].search([('is_company', '=', True)])\nprint(partners)","lang":"python","description":"Connect to an Odoo server, authenticate, access environment, and perform basic operations."},"warnings":[{"fix":"Explicitly pass protocol='jsonrpc' when creating the ODOO instance.","message":"The default protocol 'xmlrpc' is deprecated. Use 'jsonrpc' instead.","severity":"deprecated","affected_versions":">=0.8"},{"fix":"Use \"from odoorpc import ODOO\" (uppercase).","message":"The class name is ODOO (all caps), not OdooRPC or Odoo. Many users incorrectly import from odoorpc import Odoo.","severity":"gotcha","affected_versions":"all"},{"fix":"Call odoo.login(database, username, password).","message":"The login method is .login(), not .authenticate() or .connect(). Confusion arises from other Odoo libraries.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Replace 'from odoorpc import OdooRPC' with 'from odoorpc import ODOO'.","cause":"Using incorrect import name; class is ODOO (all caps).","error":"ImportError: cannot import name 'OdooRPC' from 'odoorpc'"},{"fix":"Use .login(database, username, password) instead of .authenticate().","cause":"Method name is .login(), not .authenticate().","error":"AttributeError: 'ODOO' object has no attribute 'authenticate'"},{"fix":"Specify protocol='jsonrpc' when creating ODOO object.","cause":"Using deprecated XML-RPC protocol with Odoo 12+; JSON-RPC is recommended.","error":"xmlrpc.client.Fault: <Fault -2: 'Wrong server block size'>"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}