Metadata-Version: 2.4
Name: mangono-addon-json2_report_controller
Version: 19.0.1.1.0
Project-URL: Homepage, https://www.mangono.fr
Author-Email: Mangono <opensource+odoo@mangono.fr>
License-Expression: AGPL-3.0
Classifier: Development Status :: 5 - Production/Stable
Classifier: Framework :: Odoo
Classifier: Framework :: Odoo :: 19.0
Classifier: License :: OSI Approved :: GNU Affero General Public License v3
Classifier: Programming Language :: Python
Description-Content-Type: text/markdown

# List all reports with json2
```python
res = requests.post(
    f"{BASE_URL}/json/2/ir.actions.report/search_read",
    headers=headers,
    json={
        "context": {"lang": "fr_FR"},
        "fields": ['name', "report_name", "model", "report_type"],
    }
)
res.raise_for_status()
data = res.json()
print(data)
```

# Get a report with json2
```python
res = requests.get(
    f"{BASE_URL}/json/2/report/pdf/stock.action_report_picking/1",
    headers=headers
)
res.raise_for_status()
print(res.content)
```
