Language Libraries

Official libraries for creating, signing, and verifying OPA files in your language of choice.


All libraries follow the OPA specification and support archive creation, digital signing, and signature verification. Each is open-source under the MIT license.

Library Ecosystem

Java

v0.1.0

A zero-dependency Java library for creating, reading, signing, and verifying OPA files. Requires Java 11+.

Install with Maven:

<dependency>
    <groupId>ca.weblite</groupId>
    <artifactId>opa-core</artifactId>
    <version>0.1.0-SNAPSHOT</version>
</dependency>

View on GitHub


JavaScript

npm

A minimal JavaScript library that works in both the browser and Node.js. Uses the Web Crypto API for secure browser-based signing.

Install with npm:

npm install opa-js

View on GitHub


Python

PyPI

A Python library with optional cryptographic signing support. No external dependencies for core functionality.

Install with pip:

pip install opa-archive

For signing support without requiring OpenSSL on your system path:

pip install opa-archive[crypto]

View on GitHub


PHP

Composer

A PHP library for generating, reading, signing, and verifying OPA files. Requires PHP 8.1+ with the zip, json, and openssl extensions.

Install with Composer:

composer require opa/opa-php

View on GitHub


Ruby

RubyGems

A zero-dependency Ruby library and CLI tool. Relies exclusively on Ruby’s standard library (zlib and openssl).

Install with gem:

gem install opa-ruby

View on GitHub


Feature Comparison

Feature Java JavaScript Python PHP Ruby
Create archives Yes Yes Yes Yes Yes
Read archives Yes Yes Yes Yes Yes
Digital signing Yes Yes Yes Yes Yes
Signature verification Yes Yes Yes Yes Yes
CLI tool Yes Yes
Zero dependencies Yes Yes Yes

Don’t see your language? The OPA format is built on ZIP and JSON — standard tools in every ecosystem. Check the specification for everything you need to build your own implementation.