Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
d33e582
chore(wsdl): Update wsdl folders from remote (https://github.com/onvi…
kaburagisec Oct 2, 2026
b5a117e
docs: Update operation docs based on wsdl change
kaburagisec Oct 2, 2026
5a594b8
refactor(media2): Rename `SetEQPreset` to `SetEQPresetConfiguration` …
kaburagisec Oct 2, 2026
2bf1e50
style: Run `black` on `Media2`
kaburagisec Oct 2, 2026
06a50a6
feat(client): Add support for user-provided `Zeep` plugins as attribu…
kaburagisec Oct 3, 2026
2d24b95
chore: Add `codespell` to dev dependencies (#116)
kaburagisec Oct 3, 2026
b3a4f54
ci: Update workflow to include `codespell` check
kaburagisec Oct 3, 2026
bf0fd3e
ci: Add action versions comment in Python publish workflow
kaburagisec Oct 3, 2026
56cfff1
docs: Correct misspelling and typo in services docstring (#118)
kaburagisec Oct 3, 2026
6cf314a
test: Complete tests for core modules (#119)
kaburagisec Oct 3, 2026
3a74116
ci: Include `pyproject.toml` in CI/CD workflow (#121)
kaburagisec Oct 3, 2026
085a3b7
chore: Add `pylint-pytest` to development dependencies (#120)
kaburagisec Oct 3, 2026
77347da
test: Complete tests for utilities modules (#122)
kaburagisec Oct 3, 2026
8d18808
fix(cli): Correct boolean evaluation for auto-debug mode (#123)
kaburagisec Oct 3, 2026
b25d0c1
fix(cli): Remove unused imports and clean up CLI `__init__.py` (#125)
kaburagisec Oct 3, 2026
1ed9659
test: Complete tests for CLI modules (#124)
kaburagisec Oct 3, 2026
78e3173
test: Expand Zeep and WSDL utility tests (#126)
kaburagisec Oct 3, 2026
4647147
ci: Add cross-platform CLI testing workflow (#127)
kaburagisec Oct 3, 2026
f33c863
ci: Update coverage thresholds in workflow (#128)
kaburagisec Oct 3, 2026
b5d76ab
ci: Add workflow for documentation deployment (#129)
kaburagisec Oct 3, 2026
c56b55b
ci: Ensure Codacy coverage is reported for latest commits (#130)
kaburagisec Oct 3, 2026
f795da6
feat(operator): Add `legacy_call` method for compatibility with renam…
kaburagisec Oct 4, 2026
094335f
feat(services): Implement `deprecated` decorator to mark functions as…
kaburagisec Oct 4, 2026
e1aad97
refactor(media2): Add deprecated `SetEQPreset` method for legacy comp…
kaburagisec Oct 4, 2026
8400b1d
ci: Add documentation preview workflow for pull requests (#134)
kaburagisec Oct 4, 2026
0381b0b
ci: Update CLI test job names for clarity and consistency (#135)
kaburagisec Oct 4, 2026
849595c
ci: Fix PR documentation preview deployment (#137)
kaburagisec Oct 4, 2026
aa3aa88
docs: Improve badge visibility and remove deprecated images (#136)
kaburagisec Oct 4, 2026
61bbd9a
chore: Pin dependency versions for stability (#138)
kaburagisec Oct 4, 2026
ffcad11
chore: Update LICENSE and NOTICE files for project compliance (#139)
kaburagisec Oct 4, 2026
3afd1e9
ci: Remove conditional check for closed PR in documentation preview w…
kaburagisec Oct 4, 2026
1a79169
ci: Refactor workflow names and improve coverage settings (#141)
kaburagisec Oct 4, 2026
6d99383
chore: Update .gitattributes and .gitignore for improved file trackin…
kaburagisec Oct 4, 2026
0a5b594
chore: Update pyproject.toml for improved metadata and dependency man…
kaburagisec Oct 4, 2026
ea4b057
docs: Update README and docs index (#144)
kaburagisec Oct 4, 2026
156712a
test: Enhance client and exceptions tests (#145)
kaburagisec Oct 4, 2026
2fb2e6e
refactor(uitls): Add future annotations import for improved type hint…
kaburagisec Oct 4, 2026
d050d0c
docs: Miscellaneous documentation fixes and improvements (#147)
kaburagisec Oct 4, 2026
22d07fc
docs: Update badges position in README
kaburagisec Oct 4, 2026
9f25246
docs: Update badges positions in index.md
kaburagisec Oct 4, 2026
e6ee494
refactor(cli): Refactor interactive shell into modular components (#148)
kaburagisec Oct 5, 2026
4adee04
test(cli): Complete tests for interactive shell modules (#149)
kaburagisec Oct 5, 2026
80ef9de
chore: Bump version 0.4.2 → 0.4.3 (#150)
kaburagisec Oct 5, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
onvif/wsdl/** linguist-generated=true
onvif/** linguist-generated=true
onvif/wsdl/** linguist-generated
onvif/db/** linguist-generated
assets/** linguist-generated
docs/** linguist-documentation
50 changes: 50 additions & 0 deletions .github/workflows/cli-cross-platform.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: CLI Cross-Platform

on:
push:
branches: [ "main" ]
paths:
- "onvif/**"
- "pyproject.toml"
pull_request:
branches: [ "main", "dev" ]
paths:
- "onvif/**"
- "pyproject.toml"

env:
MIN_PYTHON_VERSION: "3.10"

jobs:
cli-test:

runs-on: ${{ matrix.os }}

strategy:
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-latest
- ubuntu-24.04-arm

steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Set up Python ${{ env.MIN_PYTHON_VERSION }} (${{ matrix.os }})
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: ${{ env.MIN_PYTHON_VERSION }}

- name: Install package (${{ matrix.os }})
run: |
python -m pip install --upgrade pip
pip install .

- name: Test CLI Help (${{ matrix.os }})
run: onvif --help

- name: Test CLI Discovery (${{ matrix.os }})
run: |
python -c "import subprocess, sys; result = subprocess.run(['onvif', '--discover', '--interactive']); sys.exit(0 if result.returncode == 1 else result.returncode)"
10 changes: 3 additions & 7 deletions .github/workflows/coverage-reporter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@ name: Codacy Coverage Reporter

on:
push:
# Codacy always requests the latest coverage report
# from the most recent commit, even if it is out of context.
branches: [ "main", "dev" ]
paths:
- "onvif/**"
- "tests/**"
- "examples/**"

permissions:
contents: read
Expand All @@ -15,12 +13,10 @@ env:
MIN_PYTHON_VERSION: "3.10" # Use the minimum supported Python version for coverage generation

jobs:
codacy-coverage-reporter:
reporter:

runs-on: ubuntu-latest

name: codacy-coverage-reporter

steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

Expand Down
56 changes: 56 additions & 0 deletions .github/workflows/documentation-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Documentation Preview

on:
pull_request:
types:
- opened
- synchronize
- reopened
- closed
paths:
- "docs/**"
- "onvif/**"
- "mkdocs.yml"
- "pyproject.toml"

permissions:
contents: write
pull-requests: write

concurrency:
group: preview-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
preview:

runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Set up Python
if: github.event.action != 'closed'
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.12"

- name: Install documentation dependencies
if: github.event.action != 'closed'
run: |
python -m pip install --upgrade pip
pip install -e ".[docs]"

- name: Build documentation
if: github.event.action != 'closed'
run: |
mkdocs build --strict

- name: Deploy PR preview
uses: rossjrw/pr-preview-action@ffa7509e91a3ec8dfc2e5536c4d5c1acdf7a6de9 # v1.8.1
with:
source-dir: site/
preview-branch: gh-pages
umbrella-dir: pr-preview
wait-for-pages-deployment: true
37 changes: 37 additions & 0 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Documentation

on:
push:
branches:
- main
paths:
- "docs/**"
- "onvif/**"
- "mkdocs.yml"
- "pyproject.toml"
workflow_dispatch:

permissions:
contents: write

jobs:
deploy:

runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1

- name: Set up Python
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.12"

- name: Install documentation dependencies
run: |
python -m pip install --upgrade pip
pip install ".[docs]"

- name: Deploy documentation
run: mkdocs gh-deploy --force
23 changes: 14 additions & 9 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,26 @@
name: Python Application

on:
push:
branches: [ "main" ]
paths:
- "onvif/**"
- "tests/**"
- "examples/**" # to enforce lint and format standard
- "pyproject.toml"
pull_request:
branches: [ "main", "dev" ]
paths:
- "onvif/**"
- "tests/**"
- "examples/**"
- "examples/**" # to enforce lint and format standard
- "pyproject.toml"

permissions:
contents: read

env:
COVERAGE_FAIL_UNDER: 49 # Will be raised gradually (in percentage)
MIN_PYTHON_VERSION: "3.10" # Use the minimum supported Python version for coverage generation
COVERAGE_FAIL_UNDER: 85 # Will be raised gradually (in percentage)

jobs:
build:
Expand Down Expand Up @@ -46,16 +53,14 @@ jobs:
- name: Check imports order with isort
run: isort --check-only .

- name: Check spelling with codespell
run: codespell .

- name: Lint with pylint
run: pylint .

- name: Type check with mypy
run: mypy .

- name: Test and coverage check with pytest
run: |
if [ "${{ matrix.python-version }}" = "${{ env.MIN_PYTHON_VERSION }}" ]; then
pytest --cov=onvif --cov-fail-under=${{ env.COVERAGE_FAIL_UNDER }} --cov-report=term-missing
else
pytest .
fi
run: pytest --cov=onvif --cov-fail-under=${{ env.COVERAGE_FAIL_UNDER }} --cov-report=term-missing
10 changes: 5 additions & 5 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python 3.x
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97
uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
with:
python-version: "3.x"

Expand All @@ -25,7 +25,7 @@ jobs:
python -m build

- name: Upload distributions
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: release-dists
path: dist/
Expand All @@ -46,12 +46,12 @@ jobs:

steps:
- name: Retrieve release distributions
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: release-dists
path: dist/

- name: Publish release distributions to PyPI
uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33
uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2
with:
packages-dir: dist/
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ site/
.coverage
coverage.xml
codacy-coverage.sh
result.json

# Python cache
__pycache__/
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.md → LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
The MIT License (MIT)
MIT License

Copyright (c) 2025-2026 Nirsimetri Technologies®

Expand Down
3 changes: 0 additions & 3 deletions MANIFEST.in

This file was deleted.

11 changes: 11 additions & 0 deletions NOTICE
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
This project is an independent open-source implementation of the ONVIF (https://www.onvif.org) specifications. It is not affiliated with, endorsed by, or sponsored by ONVIF or its member companies.

- The name “ONVIF” and the ONVIF logo are registered trademarks of the ONVIF organization.
- Any references to ONVIF within this project are made strictly for the purpose of describing interoperability with ONVIF-compliant devices and services.
- Use of the ONVIF trademark in this repository is solely nominative and does not imply any partnership, certification, or official status.
- This project includes WSDL/XSD/HTML files from the official ONVIF specifications.
- These files are © ONVIF and are redistributed here for interoperability purposes.
- The WSDL files in the https://github.com/nirsimetri/onvif-python/tree/main/onvif/wsdl folder are distributed under the ONVIF Contributor License Agreement and Apache License 2.0. See https://github.com/nirsimetri/onvif-python/tree/main/onvif/wsdl/LICENSE for details.
- All rights to the ONVIF specifications are reserved by ONVIF.

If you require certified ONVIF-compliant devices or clients, please refer to the official https://www.onvif.org/conformant-products. For authoritative reference and the latest official ONVIF specifications, please consult the https://www.onvif.org/profiles/specifications/specification-history.
25 changes: 10 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,15 @@
<h1 align="center">ONVIF Python</h1>
# ONVIF Python

<div align="center">
<a href="https://app.codacy.com/gh/nirsimetri/onvif-python/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade"><img src="https://img.shields.io/codacy/grade/bff08a94e4d447b690cea49c6594826d?style=plastic&logo=codacy&label=Code%20Quality"/></a>
<a href="https://pypi.org/project/onvif-python/"><img alt="PyPI Version" src="https://img.shields.io/badge/Version-0.4.2-orange?logo=python&logoColor=white&color=yellow&style=plastic"></a>
<a href="https://pepy.tech/projects/onvif-python"><img alt="Pepy Total Downloads" src="https://img.shields.io/pepy/dt/onvif-python?logo=pypi&logoColor=white&label=Downloads&color=red&style=plastic"></a>
[![Python Version](https://img.shields.io/pypi/pyversions/onvif-python?logo=python&logoColor=white&color=blue&style=plastic&label=Python)](https://pypi.org/project/onvif-python)
[![PyPI Version](https://img.shields.io/pypi/v/onvif-python?logo=pypi&logoColor=white&color=blue&style=plastic&label=PyPI)](https://pypi.org/project/onvif-python/)
[![Quality](https://img.shields.io/codacy/grade/bff08a94e4d447b690cea49c6594826d?style=plastic&logo=codacy&label=Quality)](https://app.codacy.com/gh/nirsimetri/onvif-python/dashboard)
[![Coverage](https://img.shields.io/codacy/coverage/bff08a94e4d447b690cea49c6594826d?style=plastic&logo=codacy&label=Coverage)](https://app.codacy.com/gh/nirsimetri/onvif-python/coverage)
[![Downloads](https://img.shields.io/pepy/dt/onvif-python?label=Downloads&color=red&style=plastic)](https://pepy.tech/projects/onvif-python)
<br>
<a href="https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml"><img alt="Build" src="https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml/badge.svg?branch=main"></a>
<a href="https://github.com/nirsimetri/onvif-python/actions/workflows/python-publish.yml"><img alt="Upload Python Package" src="https://github.com/nirsimetri/onvif-python/actions/workflows/python-publish.yml/badge.svg"></a>
</div>
[![Build](https://img.shields.io/github/actions/workflow/status/nirsimetri/onvif-python/python-app.yml?logo=github&style=plastic&label=Build)](https://github.com/nirsimetri/onvif-python/actions/workflows/python-app.yml)
[![Upload Python](https://img.shields.io/github/actions/workflow/status/nirsimetri/onvif-python/python-publish.yml?logo=github&style=plastic&label=Upload%20Package)](https://github.com/nirsimetri/onvif-python/actions/workflows/python-publish.yml)
[![CLI Cross-Platform](https://img.shields.io/github/actions/workflow/status/nirsimetri/onvif-python/cli-cross-platform.yml?logo=github&style=plastic&label=CLI%20Cross-Platform)](https://github.com/nirsimetri/onvif-python/actions/workflows/cli-cross-platform.yml)

<h1 align="center">
<img src="https://raw.githubusercontent.com/nirsimetri/onvif-python/refs/heads/main/assets/images/carbon_onvif.png" alt="onvif" width="700px">
<br>
</h1>

**This project provides a comprehensive and developer-friendly Python library for working with ONVIF-compliant devices.** It is designed to be reliable, easy to integrate, and flexible enough to support a wide range of ONVIF profiles and services.

**[ONVIF](https://www.onvif.org) (Open Network Video Interface Forum)** is a global standard for the interface of IP-based physical security products, including network cameras, video recorders, and related systems.

Expand Down Expand Up @@ -59,4 +54,4 @@ For complete guide, including usage examples and API references, please visit th

## License

This project is licensed under the MIT License. See [LICENSE](./LICENSE.md) for details.
This project is licensed under the MIT License. See [LICENSE](./LICENSE) for details.
Binary file removed assets/images/carbon_onvif.png
Binary file not shown.
Binary file removed assets/images/onvif_discovery.png
Binary file not shown.
15 changes: 9 additions & 6 deletions docs/core/onvif_cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ This library includes a powerful command-line interface (CLI) for interacting wi
[--health-check-interval HEALTH_CHECK_INTERVAL] [--output OUTPUT] [--version]
[service] [method] [params ...]

ONVIF Terminal Client — v0.4.2
ONVIF Terminal Client — v0.4.3
https://github.com/nirsimetri/onvif-python

positional arguments:
Expand Down Expand Up @@ -137,7 +137,7 @@ This library includes a powerful command-line interface (CLI) for interacting wi
??? abstract "Interactive Shell"

```shell
ONVIF Interactive Shell — v0.4.2
ONVIF Interactive Shell — v0.4.3
https://github.com/nirsimetri/onvif-python

Basic Commands:
Expand Down Expand Up @@ -304,10 +304,13 @@ onvif media GetProfiles -d -u admin -p password
1. **Automatic Network Scanning**: Sends a WS-Discovery Probe message to the multicast address `239.255.255.250:3702`
2. **Device Detection**: Listens for ProbeMatch responses from ONVIF devices (default timeout: 4 seconds)
3. **Interactive Selection**: Displays a numbered list of discovered devices with their details:
- Device UUID (Endpoint Reference)
- XAddrs (ONVIF service URLs)
- Device Types (e.g., NetworkVideoTransmitter)
- Scopes (name, location, hardware, profile information)
- Device UUID (Endpoint Reference)
- Hostname (hostname of the device)
- XAddrs (ONVIF service URLs)
- Date & Time (in UTC and/or Local)
- Device Types (e.g., NetworkVideoTransmitter)
- Services (available services on device)
- Scopes (name, location, hardware, profile information)
4. **Connection**: Once you select a device, the CLI automatically connects using the discovered host and port

#### Example Discovery Output
Expand Down
Loading
Loading