{"id":46274333,"url":"https://github.com/spejder/odoo-client","last_synced_at":"2026-03-04T04:02:32.153Z","repository":{"id":42054861,"uuid":"279993202","full_name":"spejder/odoo-client","owner":"spejder","description":"An Odoo client for PHP","archived":false,"fork":false,"pushed_at":"2025-11-17T05:04:11.000Z","size":155,"stargazers_count":8,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-11-17T07:14:03.619Z","etag":null,"topics":["hacktoberfest","odoo","php"],"latest_commit_sha":null,"homepage":"https://packagist.org/packages/spejder/odoo-client","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/spejder.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-07-15T22:23:10.000Z","updated_at":"2025-11-17T05:03:59.000Z","dependencies_parsed_at":"2025-05-09T21:38:42.308Z","dependency_job_id":"422d8ad0-7aa6-4416-983c-ab44e91d2e5a","html_url":"https://github.com/spejder/odoo-client","commit_stats":{"total_commits":76,"total_committers":6,"mean_commits":"12.666666666666666","dds":0.618421052631579,"last_synced_commit":"6ef8cad2451e7ce363b568d5f797101483b2cd26"},"previous_names":[],"tags_count":70,"template":false,"template_full_name":null,"purl":"pkg:github/spejder/odoo-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spejder%2Fodoo-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spejder%2Fodoo-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spejder%2Fodoo-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spejder%2Fodoo-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/spejder","download_url":"https://codeload.github.com/spejder/odoo-client/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spejder%2Fodoo-client/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30071670,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T03:25:38.285Z","status":"ssl_error","status_checked_at":"2026-03-04T03:25:05.086Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest","odoo","php"],"created_at":"2026-03-04T04:02:25.564Z","updated_at":"2026-03-04T04:02:32.147Z","avatar_url":"https://github.com/spejder.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OdooClient\n\nOdooClient is an Odoo client for PHP. It is inspired on [OpenERP\nAPI][1] from simbigo and uses a more or less similar API. Instead of\nan own XML-RPC client it depends on the XML-RPC and XML libraries from\nLaminas (formerly Zend Framework).\n\n:information_source: This is a fork of the inactive\n[jacobsteringa/odoo-client](https://packagist.org/packages/jacobsteringa/odoo-client).\nDependencies have been updated and code style modernized to\nPSR-12. Actual credit for the code goes to\n[@jacobsteringa](https://github.com/jacobsteringa) :heart:\n\n## Supported versions\n\nThis library should work with Odoo 8 and 9. If you find any any\nincompatibilities, please create an issue or submit a pull request.\n\n### Known issues\n\n- The `Odoo::getReport()` method in v0.2.2 and lower does not work with Odoo 9.\n\n## Usage\n\nInstantiate a new client.\n\n```php\nuse Spejder\\Odoo\\Odoo;\n\n$url = 'example.odoo.com/xmlrpc/2';\n$database = 'example-database';\n$user = 'user@email.com';\n$password = 'yourpassword';\n\n$client = new Odoo($url, $database, $user, $password);\n```\n\nFor the client to work you have to include the `/xmlrpc/2` part of the\nurl.\n\nWhen you need to tweak the HTTP client used by the XML-RPC client, you\ncan inject a custom HTTP client via the constructor or the\n`Odoo::setHttpClient` method.\n\n```php\nuse Spejder\\Odoo\\Odoo;\nuse Laminas\\Http\\Client as HttpClient;\n\n$httpClient = new HttpClient(null, [\n    'sslverifypeer' =\u003e false,\n]);\n\n// constructor argument\n$client = new Odoo($url, $database, $user, $password, $httpClient);\n\n// or setter\n$client = new Odoo($url, $database, $user, $password);\n$client-\u003esetHttpClient($httpClient);\n```\n\n### xmlrpc/2/common endpoint\n\nGetting version information.\n\n```php\n$client-\u003eversion();\n```\n\nGetting timezone information.\n\n```php\n$client-\u003etimezone();\n```\n\nThere is no login/authenticate method. The client does authentication\nfor you, that is why the credentials are passed as constructor\narguments.\n\n### xmlrpc/2/object endpoint\n\nSearch for records.\n\n```php\n$criteria = [\n  ['customer', '=', true],\n];\n$limit = 10;\n$offset = 0;\n\n$client-\u003esearch('res.partner', $criteria, $offset, $limit);\n```\n\nReading records.\n\n```php\n$ids = $client-\u003esearch('res.partner', [['customer', '=', true]], 0, 10);\n\n$fields = ['name', 'email', 'customer'];\n\n$customers = $client-\u003eread('res.partner', $ids, $fields);\n```\n\nCreating records.\n\n```php\n$data = [\n  'name' =\u003e 'John Doe',\n  'email' =\u003e 'foo@bar.com',\n];\n\n$id = $client-\u003ecreate('res.partner', $data);\n```\n\nUpdating records.\n\n```php\n// change email address of user with current email address foo@bar.com\n$ids = $client-\u003esearch('res.partner', [['email', '=', 'foo@bar.com']], 0, 1);\n\n$client-\u003ewrite('res.partner', $ids, ['email' =\u003e 'baz@quux.com']);\n\n// 'uncustomer' the first 10 customers\n$ids = $client-\u003esearch('res.partner', [['customer', '=', true]], 0, 10);\n\n$client-\u003ewrite('res.partner', $ids, ['customer' =\u003e false]);\n```\n\nDeleting records.\n\n```php\n$ids = $client-\u003esearch('res.partner', [['email', '=', 'baz@quuz.com']], 0, 1);\n\n$client-\u003eunlink('res.partner', $ids);\n```\n\nTrigger custom Odoo methods.\n\n```php\n$client-\u003eexecute('sale.order', 'action_confirm', $ids);\n```\n\nGet report in base64 format.\n\n```php\n$ids = $client-\u003esearch('res.partner', [['customer', '=', true]], 0, 10);\n\n$report = $client-\u003egetReport('res.partner', $ids);\n```\n\n[1]: https://bitbucket.org/simbigo/openerp-api\n\n## License\n\nMIT License. Copyright (c) 2014 Jacob Steringa.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspejder%2Fodoo-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspejder%2Fodoo-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspejder%2Fodoo-client/lists"}