Tools
Tools and libraries for working with Retropak files.
Implementations
Libraries
Want to build a library? See the specification
Emulator Integration
We would like to hear from emulator developers interested in adding native .rpk support. Retropak is designed to work with emulators for all supported platforms, making it simple to:
- Load software directly from
.rpkarchives - Display embedded metadata and artwork
- Handle multi-disc titles seamlessly
- Verify ROM authenticity through checksums
If you develop or maintain an emulator and would like to integrate Retropak support, please get in touch via the Retropak Discord.
Frontend Integration
We are seeking contributions from frontend developers to add Retropak support. Potential features include:
- Direct
.rpkloading - Automatic metadata import
- Asset extraction and caching
- Signature verification
- Multi-disc handling
Creating Tools
JSON Schema
Validate manifests against the official schema:
Use with any JSON Schema validator:
- Python:
jsonschema - JavaScript:
ajv - Go:
gojsonschema - Java:
json-schema-validator
Reading Retropaks
Retropaks are standard ZIP files. Use any ZIP library:
Python:
import zipfile
import json
with zipfile.ZipFile('game.rpk', 'r') as rpk:
manifest = json.loads(rpk.read('retropak.json'))
print(manifest['info']['title'])
JavaScript:
const JSZip = require('jszip');
const fs = require('fs');
fs.readFile('game.rpk', (err, data) => {
JSZip.loadAsync(data).then(zip => {
zip.file('retropak.json').async('string').then(content => {
const manifest = JSON.parse(content);
console.log(manifest.info.title);
});
});
});
Rust:
use zip::ZipArchive;
use std::fs::File;
use serde_json::Value;
let file = File::open("game.rpk")?;
let mut archive = ZipArchive::new(file)?;
let manifest_file = archive.by_name("retropak.json")?;
let manifest: Value = serde_json::from_reader(manifest_file)?;
println!("{}", manifest["info"]["title"]);
Signature Verification
GPG:
unzip -p game.rpk retropak.checksums > /tmp/checksums
unzip -p game.rpk retropak.sig > /tmp/sig
gpg --verify /tmp/sig /tmp/checksums
SSH:
unzip -p game.rpk retropak.checksums > /tmp/checksums
unzip -p game.rpk retropak.sig > /tmp/sig
ssh-keygen -Y verify -f allowed_signers -I signer@example.com \
-n org.retropak -s /tmp/sig < /tmp/checksums
Contributing
Want to build tools for Retropak?
- Read the specification
- Use the JSON schema
- Check existing examples
- Join the discussion
The specification is CC0. Anyone can build tools and integrations for Retropak.
Get Involved
Have an idea for a tool? Want to contribute an implementation?
- Read the specification
- Use the JSON schema for validation
- Review the code examples above
- Join the Retropak Discord to discuss ideas
- Build your implementation
Contributions of libraries, converters, and integrations are welcome.