Skip to content

API Reference

Welcome to the Sharokey API documentation. Sharokey provides secure secret sharing with Zero Knowledge encryption through our official SDKs.

🚀 Quick Start

Instead of using the raw API directly, we strongly recommend using our official client libraries for the best developer experience:

Official SDKs:

  • CLI C# - Cross-platform command-line interface for automation and scripting
  • JavaScript SDK - Full-featured library for Node.js and modern web applications
  • JavaScript CDN - Simple browser integration without build tools
  • Python SDK - Async Python client with CLI-consistent API

🔐 Zero Knowledge Security

All our SDKs implement client-side encryption automatically:

  • AES-256-GCM encryption with PBKDF2 key derivation
  • Automatic key generation and secure splitting
  • No plaintext transmission - server never sees your secrets
  • Simple API - complexity hidden behind easy-to-use methods

📖 API Documentation

Our API documentation focuses on the data structures and responses you'll receive when using the SDKs:

SectionDescription
AuthenticationToken setup and configuration
SecretsSecret creation, retrieval, and management
Secret RequestsRequest secrets from third parties securely
AttachmentsFile upload and encryption
StatisticsCompany usage analytics
Error HandlingError codes and troubleshooting
Rate LimitsAPI usage limits and best practices

⚡ SDK Advantages

Why Use Our SDKs?

🔒 Security Handled Automatically:

  • Client-side encryption before transmission
  • Secure key generation and management
  • IV/salt generation per secret
  • No crypto implementation required

🛠️ Developer Experience:

  • Simple, intuitive APIs
  • Automatic error handling
  • Built-in retry logic
  • Comprehensive documentation

📦 Batteries Included:

  • Authentication management
  • File attachment handling
  • Progress tracking for uploads
  • Cross-platform compatibility

🌟 Choose Your SDK

CLI C# - Command Line

Perfect for automation, CI/CD pipelines, and system administration.

bash
sharokey create "Database password" --hours 24 --views 1

Ideal for Node.js backends and modern web applications.

javascript
const secret = await client.createSecret("Database password", {
  hours: 24, views: 1
});

JavaScript CDN - Simple Integration

Quick browser integration without build tools.

javascript
const secret = await Sharokey.create("Database password", 24, 1);

Python SDK - Async Ready

Modern async Python client for server applications.

python
secret = await client.create("Database password", hours=24, views=1)

🔑 Authentication

All SDKs handle authentication automatically once configured. See our Authentication Guide for setup instructions.

🔗 Next Steps

  1. Choose a Library - Pick the SDK that fits your stack
  2. Set up Authentication - Configure your API token
  3. Start Building - Follow the quickstart for your chosen SDK

For raw API details, see the individual API documentation sections above. However, we recommend using our SDKs for the best experience.

Released under the MIT License.