{"id":28995086,"url":"https://github.com/axiscommunications/acap-rs","last_synced_at":"2025-06-25T04:06:31.892Z","repository":{"id":237240230,"uuid":"784643949","full_name":"AxisCommunications/acap-rs","owner":"AxisCommunications","description":"Experimental Rust wrappers and example code for APIs and features in AXIS Camera Application Platform (ACAP)","archived":false,"fork":false,"pushed_at":"2025-05-28T06:39:40.000Z","size":687,"stargazers_count":7,"open_issues_count":6,"forks_count":5,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-28T07:36:10.244Z","etag":null,"topics":["acap","analytics","axis","camera","edge","experimental","rust","video"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AxisCommunications.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-04-10T09:02:54.000Z","updated_at":"2025-05-28T06:39:44.000Z","dependencies_parsed_at":"2024-06-24T17:01:48.123Z","dependency_job_id":"ea18d993-8ad7-4f19-af76-e04fb55f8176","html_url":"https://github.com/AxisCommunications/acap-rs","commit_stats":null,"previous_names":["axiscommunications/acap-rs"],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/AxisCommunications/acap-rs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AxisCommunications%2Facap-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AxisCommunications%2Facap-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AxisCommunications%2Facap-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AxisCommunications%2Facap-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AxisCommunications","download_url":"https://codeload.github.com/AxisCommunications/acap-rs/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AxisCommunications%2Facap-rs/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261801988,"owners_count":23211664,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["acap","analytics","axis","camera","edge","experimental","rust","video"],"created_at":"2025-06-25T04:06:29.811Z","updated_at":"2025-06-25T04:06:31.864Z","avatar_url":"https://github.com/AxisCommunications.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ACAP for Rust\n\n_Easy and safe [ACAP] apps using [Rust]_\n\n\u003e [!IMPORTANT]\n\u003e This project is an experiment provided \"as is\".\n\u003e While we strive to maintain it, there's no guarantee of ongoing support, and it may become\n\u003e unmaintained in the future.\n\u003e Your contributions are appreciated, and feel free to fork and continue the journey if needed.\n\nThis repository provides the developer tools, libraries, and documentation that form ACAP for Rust platform.\nTo quickly start a new app, see [acap-rs-app-template](https://github.com/AxisCommunications/acap-rs-app-template).\n\n## Table of Contents\n\n- [**Getting started**](#getting-started)\n  - [Dev container](#dev-container)\n  - [Non-dev container](#non-dev-container)\n  - [Without container](#without-container)\n- [**Developer tools**](#developer-tools)\n  - [Porcelain programs](#porcelain-programs)\n  - [Plumbing programs](#plumbing-programs)\n- [**Libraries**](#libraries)\n  - [ACAP Native API bindings](#acap-native-api-bindings)\n  - [VAPIX API bindings](#vapix-api-bindings)\n  - [Other library crates](#other-library-crates)\n- [**Documentation**](#documentation)\n  - [Example applications](#example-applications)\n  - [Articles](#articles)\n- [**Troubleshooting**](#troubleshooting)\n\n## Getting started\n\nThe recommended setup is using the [dev container](#dev-container) and the most recent LTS version of AXIS OS [^1].\n\n### Dev container\n\nThe quickest way to build the `hello_world` example is to launch the dev container and\nrun `make build AXIS_PACKAGE=hello_world`.\nOnce it completes there should be an `.eap` file in `target/acap`:\n\n```console\n$ ls -1 target/acap\nhello_world_1_0_0_aarch64.eap\n```\n\nThis works with any of the [example applications](#example-applications).\n\nImportant workflows are documented in the [Makefile](./Makefile) and can now be listed with\n`make help`.\n\n### Non-dev container\n\nIf you prefer to not use dev containers, or the implementation in your favorite IDE is buggy, the\napp can be built using\nonly `docker`:\n\n```sh\ndocker build --file .devcontainer/Dockerfile --tag acap-rs .\ndocker run \\\n  --interactive \\\n  --rm \\\n  --tty \\\n  --user $(id -u):$(id -g) \\\n  --volume $(pwd):$(pwd) \\\n  --workdir $(pwd) \\\n  acap-rs \\\n  make build AXIS_PACKAGE=hello_world\n```\n\n### Without container\n\nDevelopment environments outside containers are more difficult to reproduce and maintain.\nShould it nonetheless be of interest, one procedure is documented\nin [this workflow](.github/workflows/on-host-workflow.yml).\n\n## Developer tools\n\nTools for developing ACAP apps are provided primarily as binary crates.\nThe tools can be roughly divided into low level _plumbing_ and high level _porcelain_.\n\nAll of these tools are installed in the dev container of this project.\nTo install them in another project before they are released, use the `--git` option e.g. like:\n\n```sh\ncargo install --locked --git https://github.com/AxisCommunications/acap-rs.git cargo-acap-sdk\n```\n\n### Porcelain programs\n\nThe focus of these tools are to make common things easy.\n\n- `cargo-acap-sdk` - Automation of common development workflows.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/cargo-acap-sdk/README.md)\n\n### Plumbing programs\n\nThe focus of these tools are to make less common things possible.\n\n- `acap-ssh-utils` - Utilities for interacting with Axis devices over SSH.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/acap-ssh-utils/README.md)\n- `cargo-acap-build`: Build utilities for ACAP apps and other executables deployed to Axis devices.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/cargo-acap-build/README.md)\n- `device-manager`: Utilities for manipulating a single Axis device.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/device-manager/README.md)\n- `fleet-manager`: Utilities for manipulating multiple Axis devices.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/fleet-manager/README.md)\n\nThese can be installed independently and are provided as library crates too for developers who want\nto write their own,\ntailored tools.\n\n## Libraries\n\nTo make it easier to relate the Rust offering to the official offering, the library crates are\ngrouped in a similar way as in the ACAP Native SDK APIs documentation.\n\n\u003e [!NOTE]\n\u003e If an API that is important to you is missing, create or upvote the feature request for it.\n\n### ACAP Native API bindings\n\nThese are idiomatic and safe bindings for the [C APIs](https://axiscommunications.github.io/acap-documentation/docs/api/native-sdk-api.html#native-sdk-api).\nEach crate has a corresponding `*-sys`, which is omitted for brevity.\n\n- `axparameter`: Bindings for the Parameter API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/axparameter/src/lib.rs)\n- `axevent`: Bindings for the Event API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/axevent/src/lib.rs)\n- `axoverlay`: Bindings for the Overlay API\n  - Status: 🧻 Proof of Concept\n  - Documentation: [Source code](crates/axoverlay/src/lib.rs)\n- `axserialport`: Bindings for the Serial Port API\n  - Status: 📄 Not started\n- `axstorage`: Bindings for the Edge Storage API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/axstorage/src/lib.rs)\n- `bbox`: Bindings for the Bounding Box API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/bbox/src/lib.rs)\n- `larod`: Bindings for the Machine Learning API.\n  - Status: 💡 Started\n  - Documentation: [Pull request](https://github.com/AxisCommunications/acap-rs/pull/120)\n- `licensekey`: Bindings for the License Key API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/licensekey/src/lib.rs)\n- `mdb`: Bindings for the Message Broker API.\n  - Status: ⚠️ Alpha\n  - Documentation: [Source code](crates/mdb/src/lib.rs)\n- `vdo`: Bindings for the Video Capture API.\n  - Status: 💡 Started\n  - Documentation: [Pull request](https://github.com/AxisCommunications/acap-rs/pull/153)\n\n### VAPIX API bindings\n\nAll the VAPIX APIs are provided by a single crate:\n\n- `acap-vapix`: Bindings for various VAPIX APIs + credentials lookup.\n  - Status: ⚠️ Alpha\n  - Documentation: [README](crates/acap-vapix/README.md)\n\n### Other library crates\n\nThese are not closely related to any official APIs but may nonetheless be helpful in their own way:\n\n- `acap-logging`: Logging utilities for ACAP applications\n  - Status: 🚧 Beta\n  - Documentation: [Docs.rs](https://docs.rs/acap-logging/latest/acap_logging/)\n\n## Documentation\n\nIdeally information is provided when and where the reader needs it, such as:\n\n- Tab completions and help texts for binaries.\n- Docstrings and doctests for libraries.\n\nThis is however not always suitable, and this section lists other sources of documentation provided\nby this project.\n\n### Example applications\n\n- `axparameter_example`: Creates, reads, updates, deletes, and subscribes to parameters.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/axparameter_example/src/main.rs)\n- `axoverlay_example`: Draws two rectangles and a countdown in video streams.\n  - Status: 🧻 Proof of Concept\n  - [Source code](apps/axoverlay_example/src/main.rs)\n- `axstorage_example`: Writes data to files on all connected storages.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/axstorage_example/src/main.rs)\n- `bounding_box_example`: Draws simple overlays in video streams.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/bounding_box_example/src/main.rs)\n- `consume_analytics_metadata`: Subscribes to _analytics scene description_ data using `mdb`.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/consume_analytics_metadata/src/main.rs)\n- `embedded_web_page`: Bundles an embedded web page.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/embedded_web_page/src/main.rs)\n- `event_subscribe`: Subscribe to an event using the non-blocking axevent API. Re-implements the [C example for event subscription](https://developer.axis.com/acap/api/src/api/axevent/html/ax_event_subscription_example_8c-example.html)\n  - Status: ⚠️ Alpha\n  - [Source code](apps/event_subscribe/src/main.rs)\n- `hello_world`:Sets up and uses logging using common functions and `acap-logging`.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/hello_world/src/main.rs)\n- `licensekey_handler`:Checks if an app is licensed using `licensekey`.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/licensekey_handler/src/main.rs)\n- `reverse_proxy`: Exposes HTTP and WebSocket APIs using a `axum` and reverse proxy configuration.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/reverse_proxy/src/main.rs)\n- `send_event`: Sends events using `axevent`.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/send_event/src/main.rs)\n- `using_a_build_script`: Generates html, lib and app manifest files using a build script.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/using_a_build_script/src/main.rs)\n- `vapix_access`: Accesses VAPIX APIs using `acap-vapix`.\n  - Status: ⚠️ Alpha\n  - [Source code](apps/vapix_access/src/main.rs)\n\n\u003c!-- inspect_env is omitted because it is intended primarily as a test --\u003e\n\n### Articles\n\n- [awesome-acap](https://github.com/apljungquist/awesome-acap) - a list of free resources related to ACAP development.\n- [Related projects](docs/related-projects.md)\n- [Running apps and tests on device](docs/running-apps-and-tests-on-device.md)\n- [Managing the size of Rust binaries](https://github.com/apljungquist/managing-the-size-of-rust-binaries)\n\n## Troubleshooting\n\nThe docker image may fail to build with the following included in the output:\n`/usr/bin/env: 'sh\\r': No such file or directory`\nThis is likely caused by `git` replacing POSIX newlines with Windows newlines in which case it can\nbe resolved by either\n\n- cloning the code in Windows Subsystem for Linux (WSL), or\n- reconfiguring `git`.\n\n## License\n\n[MIT](LICENSE)\n\n[ACAP]: https://axiscommunications.github.io/acap-documentation/\n\n[Rust]: https://doc.rust-lang.org/\n\n[^1]: Compatibility with various host and target environments are explored and explained in [compatibility](docs/compatibility.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxiscommunications%2Facap-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faxiscommunications%2Facap-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxiscommunications%2Facap-rs/lists"}