Product

A rule of thumbs is always use product.product model unless you're creating a new product (product.template) or updating base field like name any other than that please use product.product

Add Product

{
    "id": "some_id",
    "action": "create",
    "model_id": "product.template",
    "keyword": {
        "context": {
            "allowed_company_ids": [1],
            "default_company_id": 1,
            "tz": "Asia/Singapore"
        }
    },
    "params": [
        [
            {
                "name": "250 gr Patty",
                "uom_id": 1,
                "uom_po_id": 1
            }
        ]
    ],
    "odoo_instance": {
        "url": "YOUR_ODOO_INSTANCE_URL",
        "user_id": INT(YOUR_USER_ID),
        "db": "YOUR_ODOO_DB",
        "api_key": "YOUR_ODOO_API_KEY"
    }
}

Querying Products

This operation is quite expensive there are some calculated fields you might need to opt-out for querying unless you know the exact products what you were looking for

Last updated