Keysets
Ed25519 signing key pair management. Keysets enable cryptographic signing and verification of assets and events using EdDSA (Ed25519) public-key cryptography.
Methods​
| Method (TypeScript) | Method (Python) | Description | HTTP |
|---|---|---|---|
create(options?) | create(options=None) | Generate new Ed25519 key pair | POST /keysets |
get(keysetId) | get(keyset_id) | Retrieve keyset | GET /keysets/{id} |
list(options?) | list(options=None) | List keysets | GET /keysets |
delete(keysetId) | delete(keyset_id) | Delete keyset | DELETE /keysets/{id} |
Example​
- TypeScript
- Python
import { OptropicClient } from 'optropic';
const client = new OptropicClient({ apiKey: 'optr_live_...' });
// Create a new signing keyset
const keyset = await client.keysets.create({
name: 'Manufacturing Authority',
description: 'Primary signing key for factory operations'
});
console.log(`Public Key: ${keyset.publicKey}`);
console.log(`Keyset ID: ${keyset.id}`);
// The private key is returned only once - store it securely
from optropic import Optropic
client = Optropic(api_key="optr_live_...")
# Create a new signing keyset
keyset = client.keysets.create({
'name': 'Manufacturing Authority',
'description': 'Primary signing key for factory operations'
})
print(f"Public Key: {keyset['publicKey']}")
print(f"Keyset ID: {keyset['id']}")
# The private key is returned only once - store it securely