Skip to main content

WireViz-Web

https://github.com/wireviz/wireviz-web/workflows/Tests/badge.svg https://codecov.io/gh/wireviz/wireviz-web/branch/main/graph/badge.svg https://img.shields.io/pypi/v/wireviz-web.svg https://pepy.tech/badge/wireviz-web/month https://img.shields.io/pypi/pyversions/wireviz-web.svg https://img.shields.io/pypi/status/wireviz-web.svg https://img.shields.io/github/license/wireviz/wireviz-web

About

WireViz-Web is a wrapper around the excellent WireViz by Daniel Rojas for bringing it to the web.

Originally, it has been conceived within a WireViz fork by Jürgen Key. For compatibility with PlantUML, it includes a PlantUML Text Encoding format decoder by Dyno Fu and Rudi Yardley.

Thanks!

Details

WireViz

WireViz is a tool for easily documenting cables, wiring harnesses and connector pinouts. It takes plain text, YAML-formatted files as input and produces beautiful graphical output (SVG, PNG, …) thanks to Graphviz. It handles automatic BOM (Bill of Materials) creation and has a lot of extra features.

WireViz-Web

WireViz-Web wraps WireViz with a REST API using Flask. It also provides specific rendering endpoints for PlantUML.

Setup

Install prerequisites:

{apt,brew,dnf,yum,zypper} install python3 graphviz

Install package:

pip install wireviz-web

Container

Use Docker or Podman:

docker run --rm --publish 3005:3005 ghcr.io/wireviz/wireviz-web:latest --listen 0.0.0.0:3005

Use Docker Compose or Podman Compose:

services:
  wireviz-web:
    image: ghcr.io/wireviz/wireviz-web:latest
    environment:
      WIREVIZ_LISTEN: 0.0.0.0:3005
    ports:
      - "3005:3005"
    healthcheck:
      test: [ "CMD", "curl", "--fail", "http://localhost:3005/status" ]
      start_period: 2s
      interval: 10s

Usage

Run server:

wireviz-web

Run server, listening on all interfaces:

wireviz-web --listen=0.0.0.0:3005

Invoke requests:

# Acquire WireViz YAML file.
wget https://raw.githubusercontent.com/wireviz/wireviz-web/main/tests/demo01.yaml

# Render HTML page with SVG image and BOM table.
http --form http://localhost:3005/render yml_file@demo01.yaml Accept:text/html

# Render images.
http --form http://localhost:3005/render yml_file@demo01.yaml Accept:image/svg+xml
http --form http://localhost:3005/render yml_file@demo01.yaml Accept:image/png

# Render BOM in TSV format.
http --form http://localhost:3005/render yml_file@demo01.yaml Accept:text/plain

# Render BOM in JSON format.
http --form http://localhost:3005/render yml_file@demo01.yaml Accept:application/json

# Render a PlantUML request.
http http://localhost:3005/plantuml/svg/SyfFKj2rKt3CoKnELR1Io4ZDoSa700==
http http://localhost:3005/plantuml/png/SyfFKj2rKt3CoKnELR1Io4ZDoSa700==

For visiting the Swagger OpenAPI spec, go to http://localhost:3005/doc.

Project information

Contributions

Every kind of contribution, feedback, or patch, is much welcome. Create an issue or submit a patch if you think we should include a new feature, or to report or fix a bug.

In order to follow the general development discussion, please see Bringing WireViz to the Web.

Development

In order to setup a development environment on your workstation, please head over to the development sandbox documentation. When you see the software tests succeed, you should be ready to start hacking.

Resources

License

The project is licensed under the terms of the GNU AGPL license.

Metadata

Release files for wireviz-web 0.4.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for wireviz-web 0.4.3
File Size Uploaded Provenance
wireviz_web-0.4.3.tar.gz 26.5 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for wireviz-web 0.4.3
File Interpreter ABI Platform
wireviz_web-0.4.3-py3-none-any.whl Python 3 none any Details

Total release size: 48.9 kB

Release files / wireviz_web-0.4.3.tar.gz

Download URL wireviz_web-0.4.3.tar.gz
Size 26.5 kB
Tags Source
SHA-256 checksum
How to use checksums
73943f4d35225c288763dbb644a20754e67def47753fc6e759ee433aa5aee049
BLAKE2b-256 checksum
How to use checksums
624c30e3da17d2070a7e559a302e57a9439421dde96c0037d6656220241f9c9f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.11

Release files / wireviz_web-0.4.3-py3-none-any.whl

Download URL wireviz_web-0.4.3-py3-none-any.whl
Size 22.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9f367a5f76a0d9e56c06fc4749f60036e315507a7d90b4800894d369c744278c
BLAKE2b-256 checksum
How to use checksums
0e5e4059295ba9eabad2407434a0f854246be873a5c4cc0c5b15f58df111f6e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.11

Security for wireviz-web 0.4.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page