{"openapi":"3.1.0","info":{"title":"Key Pair API","version":"1.0.0","description":"Generate cryptographic key pairs on demand — RSA (2048/3072/4096), elliptic-curve (P-256, P-384, P-521, secp256k1), Ed25519 and Ed448 — returned as PEM (SPKI public key, PKCS#8 private key) and, optionally, as JWK. Perfect for spinning up JWT/JWS signing keys, TLS and SSH experiments, test fixtures and demos. Pure local generation with Node's crypto (no third-party service). Note: for development, testing and education — generate keys for production systems offline or in an HSM, never trust a remote API with real private keys. Live, nothing stored. 3 endpoints. Distinct from JWT signing, password generation and hashing.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/keypair-api","description":"oanor gateway"}],"tags":[{"name":"Keys"},{"name":"Reference"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/generate":{"get":{"operationId":"get_v1_generate","tags":["Keys"],"summary":"Generate a key pair","description":"","parameters":[{"name":"type","in":"query","required":false,"description":"rsa|ec|ed25519|ed448 (default rsa)","schema":{"type":"string"},"example":"ed25519"},{"name":"bits","in":"query","required":false,"description":"RSA: 2048|3072|4096","schema":{"type":"string"}},{"name":"curve","in":"query","required":false,"description":"EC: P-256|P-384|P-521|secp256k1","schema":{"type":"string"}},{"name":"jwk","in":"query","required":false,"description":"true to also return JWK","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"For development/testing. Generate production keys offline or in an HSM — never via a remote API.","type":"ed25519","public_key":"-----BEGIN PUBLIC KEY-----\nMCowBQYDK2VwAyEAqp+5pvuwGBmSgWwIPhOOImhGIC03gVQr3hgNacLuF90=\n-----END PUBLIC KEY-----\n","private_key":"-----BEGIN PRIVATE KEY-----\nMC4CAQAwBQYDK2VwBCIEIK2/UdmkywlDwlsVt+za2Dq5FtfUL9dgQlpVZqFvo/zi\n-----END PRIVATE KEY-----\n"},"meta":{"timestamp":"2026-06-02T16:51:52.255Z","request_id":"dbef8251-d427-4d1b-918d-fd5c6d1ca3a9"},"status":"ok","message":"Generate a key pair","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/types":{"get":{"operationId":"get_v1_types","tags":["Reference"],"summary":"Supported key types","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"types":["rsa","ec","ed25519","ed448"],"rsa_bits":[2048,3072,4096],"ec_curves":["P-256","P-384","P-521","secp256k1"]},"meta":{"timestamp":"2026-06-02T16:51:52.363Z","request_id":"36c96d28-4d23-4fb4-a540-0b53ef5db269"},"status":"ok","message":"Supported key types","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"auth":"none upstream; this gateway requires x-api-key","name":"Key Pair API","note":"Generate cryptographic key pairs. /v1/generate?type=rsa&bits=2048 (or type=ec&curve=P-256, type=ed25519, type=ed448); add jwk=true for JWK output alongside PEM (SPKI public / PKCS8 private). /v1/types lists options. For development, testing, JWT/JWS signing keys and TLS/SSH experiments — generate production keys offline. Instant, nothing stored.","source":"Local key generation (Node crypto) — no key, no upstream","endpoints":3},"meta":{"timestamp":"2026-06-02T16:51:52.467Z","request_id":"38b848eb-b804-4231-a79e-ac6cb73a689d"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":1160,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":340,"monthly_call_quota":11000,"rps_limit":8,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":2300,"monthly_call_quota":148000,"rps_limit":20,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":5900,"monthly_call_quota":760000,"rps_limit":50,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/keypair-api"}