1.1.0 • Published 10 months ago

odoo-jsonrpc-extended v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

Node-Odoo-Jsonrpc

OdooRPC for node.js Inspired from node-odoo-jsonrpc

Installation

Functions list

  • login(db, user, pass)
  • setCookie(session_id)
  • logout(force)
  • getDbList()
  • searchRead(model, domain, fields, limit, offset, context)
  • call(model, method, args, kwargs)

How to use

Import Odoo

import { Odoo } from "node-odoo-jsonrpc";

Initialize configuration in constructor of component

const odooRPC = new Odoo();
odooRPC.init({
  odoo_server: "https://odoo-server-example",
  http_auth: "username:password", // optional
});
try {
  await odooRPC.login("db_example", "username", "password");
  console.log("login success");
} catch (err) {
  console.error("login failed", err);
}
1.1.0

10 months ago