Skip to main content

Helper functions for Odoo server operations via internalized JSON-RPC.

Project description

OdooRPC Toolbox

Language / Sprache: DE | EN


Deutsche Dokumentation

Projektübersicht

Ein Python-Paket mit Hilfsfunktionen und Utilities für Odoo-Server-Operationen. Die OdooRPC-Funktionalität ist vollständig internalisiert (JSON-RPC 2.0). Es vereinfacht häufige Odoo-Operationen wie Partner-Verwaltung, Bundesland/Länder-Abfragen, Dateioperationen und Sequenzverwaltung.

Autor: Equitania Software GmbH - Pforzheim - Germany Lizenz: GNU Affero General Public License v3 Python: >= 3.10

Funktionen

  • Einfache Verbindungsverwaltung mit YAML-Konfiguration
  • Hilfsfunktionen für häufige Odoo-Operationen:
    • Partner-Verwaltung (Suchen, Erstellen, Aktualisieren)
    • Bundesland- und Länderabfragen
    • Dateioperationen (Bilder, Anhänge)
    • Sequenzverwaltung
    • Produkt- und Lageroperationen

Installation

pip install odoorpc-toolbox

Konfiguration

Erstellen Sie eine YAML-Konfigurationsdatei (z.B. odoo_config.yaml):

Server:
  url: your.odoo.server.com
  port: 8069
  protocol: jsonrpc
  database: your_database
  user: your_username
  password: your_password

Verwendung

from odoorpc_toolbox import EqOdooConnection

# Verbindung initialisieren
connection = EqOdooConnection('odoo_config.yaml')

# Hilfsfunktionen verwenden
state_id = connection.get_state_id(country_id=21, state_name="Bayern")
partner_id = connection.get_res_partner_id(customerno="KUND001")

Partner-Operationen

# Partner suchen
partner_id = connection.get_res_partner_id(supplierno="LIEF001", customerno="KUND001")

# Partner-Kategorien abrufen oder erstellen
category_id = connection.get_res_partner_category_id("Einzelhandel")

# Partner-Titel abrufen
title_id = connection.get_res_partner_title_id("Herr")

Standort-Operationen

# Bundesland-ID abrufen
state_id = connection.get_state_id(country_id=21, state_name="Bayern")

# Adresse parsen
strasse, hausnr = connection.extract_street_address_part("Hauptstraße 123")

Datei-Operationen

# Bilder laden und kodieren
image_data = connection.get_picture("/pfad/zum/bild.jpg")

Abhängigkeiten

  • Python >= 3.10
  • PyYAML >= 6.0
  • OdooRPC-Funktionalität ist vollständig internalisiert (keine externe Abhängigkeit)

English Documentation

Project Overview

A Python package providing helper functions and utilities for Odoo server operations. The OdooRPC functionality is fully internalized (JSON-RPC 2.0). It simplifies common Odoo operations like partner management, state/country lookups, file operations, and sequence management.

Author: Equitania Software GmbH - Pforzheim - Germany License: GNU Affero General Public License v3 Python: >= 3.10

Features

  • Easy connection management with YAML configuration
  • Helper functions for common Odoo operations:
    • Partner management (search, create, update)
    • State and country lookups
    • File operations (images, attachments)
    • Sequence management
    • Product and inventory operations

Installation

pip install odoorpc-toolbox

Configuration

Create a YAML configuration file (e.g., odoo_config.yaml):

Server:
  url: your.odoo.server.com
  port: 8069
  protocol: jsonrpc
  database: your_database
  user: your_username
  password: your_password

Usage

from odoorpc_toolbox import EqOdooConnection

# Initialize connection
connection = EqOdooConnection('odoo_config.yaml')

# Use helper functions
state_id = connection.get_state_id(country_id=21, state_name="California")
partner_id = connection.get_res_partner_id(customerno="CUST001")

Partner Operations

# Search for partners
partner_id = connection.get_res_partner_id(supplierno="SUP001", customerno="CUST001")

# Get or create partner categories
category_id = connection.get_res_partner_category_id("Retail")

# Get partner titles
title_id = connection.get_res_partner_title_id("Mr.")

Location Operations

# Get state/province ID
state_id = connection.get_state_id(country_id=21, state_name="California")

# Parse address
street, house_no = connection.extract_street_address_part("123 Main Street")

File Operations

# Load and encode images
image_data = connection.get_picture("/path/to/image.jpg")

Requirements

  • Python >= 3.10
  • PyYAML >= 6.0
  • OdooRPC functionality is fully internalized (no external dependency)

Contributing / Mitwirken

Contributions are welcome! Please feel free to submit a Pull Request.

Beiträge sind willkommen! Bitte zögern Sie nicht, einen Pull Request einzureichen.

License / Lizenz

This project is licensed under the GNU Affero General Public License v3 - see the LICENSE.txt file for details.

Dieses Projekt ist unter der GNU Affero General Public License v3 lizenziert - siehe LICENSE.txt für Details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

odoorpc_toolbox-0.6.0.tar.gz (54.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

odoorpc_toolbox-0.6.0-py3-none-any.whl (50.2 kB view details)

Uploaded Python 3

File details

Details for the file odoorpc_toolbox-0.6.0.tar.gz.

File metadata

  • Download URL: odoorpc_toolbox-0.6.0.tar.gz
  • Upload date:
  • Size: 54.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.9

File hashes

Hashes for odoorpc_toolbox-0.6.0.tar.gz
Algorithm Hash digest
SHA256 b9aceb97f6711ff8e5aa17cbcb31cbb6e9fa6bf5db88c474484348b21c84ceef
MD5 1b20e7e73137e79e6ef65b13c04dca7c
BLAKE2b-256 e195ebc5ac46c748d0a6337cc4dc1df0513a8c5f9bd3351e24ca42f31fbd54d1

See more details on using hashes here.

File details

Details for the file odoorpc_toolbox-0.6.0-py3-none-any.whl.

File metadata

File hashes

Hashes for odoorpc_toolbox-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b3c8df8d518956c6a21a8aca98cd0a6cd14d8542e1b99b529e9a3b8815a77c13
MD5 56ad02e898909be28f36cd7a0f761295
BLAKE2b-256 d5dc00f1014621f0f898aaf26ea70702c063d1f00fe039d82b7a86692fa96891

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page