{"id":13569195,"url":"https://github.com/blyssprivacy/sdk","last_synced_at":"2025-04-12T21:28:32.450Z","repository":{"id":41093087,"uuid":"462183270","full_name":"blyssprivacy/sdk","owner":"blyssprivacy","description":"SDK for private data access, built on homomorphic encryption.","archived":false,"fork":false,"pushed_at":"2024-03-21T17:35:15.000Z","size":1006,"stargazers_count":344,"open_issues_count":7,"forks_count":20,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-04-04T01:08:58.160Z","etag":null,"topics":["homomorphic-encryption","privacy","private-information-retrieval"],"latest_commit_sha":null,"homepage":"https://blyss.dev","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/blyssprivacy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2022-02-22T07:22:45.000Z","updated_at":"2025-04-03T07:12:17.000Z","dependencies_parsed_at":"2024-04-07T05:31:42.754Z","dependency_job_id":"fd9e1150-dc78-4f0d-a6c2-7e22b03711ef","html_url":"https://github.com/blyssprivacy/sdk","commit_stats":{"total_commits":64,"total_committers":3,"mean_commits":"21.333333333333332","dds":0.03125,"last_synced_commit":"7b655623c02950ab20827a5d675a1b2edb535595"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blyssprivacy%2Fsdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blyssprivacy%2Fsdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blyssprivacy%2Fsdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blyssprivacy%2Fsdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/blyssprivacy","download_url":"https://codeload.github.com/blyssprivacy/sdk/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248633977,"owners_count":21136957,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["homomorphic-encryption","privacy","private-information-retrieval"],"created_at":"2024-08-01T14:00:36.945Z","updated_at":"2025-04-12T21:28:32.429Z","avatar_url":"https://github.com/blyssprivacy.png","language":"Rust","funding_links":[],"categories":["Libraries","Awesome Privacy Engineering [![Awesome](https://awesome.re/badge.svg)](https://awesome.re)"],"sub_categories":["[Sunscreen](https://sunscreen.tech/)","Homomorphic Encryption"],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg height=\"75\" src=\"docs/static/img/logotype-light.svg\" alt=\"blyss\"\u003e\n\u003c/h1\u003e\n\u003cp align=\"center\"\u003e\n  \u003cp align=\"center\"\u003eOpen-source SDK for accessing data privately using homomorphic encryption.\u003c/p\u003e\n\u003c/p\u003e\n\n\u003ch4 align=\"center\"\u003e\n  \u003ca href=\"https://docs.blyss.dev\"\u003eDocs\u003c/a\u003e \u0026nbsp; | \u0026nbsp;\n  \u003ca href=\"https://blyss.dev\"\u003eWebsite\u003c/a\u003e \u0026nbsp; | \u0026nbsp;\n  \u003ca href=\"mailto:founders@blyss.dev\"\u003eContact\u003c/a\u003e\n\u003c/h4\u003e\n\n\u003ch4 align=\"center\"\u003e\n  \u003ca href=\"https://github.com/blyssprivacy/sdk/blob/main/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/npm/l/@blyss/sdk?color=blue\" alt=\"The Blyss SDK is released under the MIT license.\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://www.npmjs.com/package/@blyss/sdk\"\u003e\n    \u003cimg src=\"https://img.shields.io/npm/v/@blyss/sdk?color=brightgreen\" alt=\"Blyss SDK on NPM\" /\u003e\n  \u003c/a\u003e\n  \u003cbr/\u003e\n  \u003ca href=\"https://signal.group/#CjQKIAVLMoW2pGtd58Ha1tVGtXTv7Z01YV3aA1VmTtX0sj1mEhC07vIrWB7aq9KOw5f2GQsw\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/chat%20on%20Signal--blue?style=social\" alt=\"Chat on Signal\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://twitter.com/blyssdev\"\u003e\n    \u003cimg src=\"https://img.shields.io/twitter/follow/blyssdev?label=%40blyssdev\u0026style=social\" alt=\"Blyss Twitter\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/blyssprivacy/sdk\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/stars/blyssprivacy/sdk?style=social\" alt=\"Blyss GitHub stars\" /\u003e\n  \u003c/a\u003e\n\u003c/h4\u003e\n\nThe [Blyss SDK](https://blyss.dev) lets you use homomorphic encryption to [retrieve information privately](https://blintzbase.com/posts/pir-and-fhe-from-scratch/). With it, you can build new kinds of privacy-preserving services, like [private password breach checking](https://playground.blyss.dev/passwords/), [private nameserver resolution](https://sprl.it/), and even [private Wikipedia](https://spiralwiki.com/).\n\nYou can get an API key by [signing up](https://blyss.dev), or run a server locally. Detailed documentation is at [docs.blyss.dev](https://docs.blyss.dev).\n\n\u003e **Warning**\n\u003e The SDK has not yet been security reviewed, and the public Blyss service is still in beta. [Contact us](mailto:founders@blyss.dev) for access to a production-ready service.\n\n## Quick start (cloud)\n\nYou can quickly try using the SDK with our managed service without downloading anything.\n\n1. Get an API key by [signing up here](https://blyss.dev).\n2. Open [this StackBlitz](https://stackblitz.com/edit/blyss-private-contact-intersection) and enter your API key where it says `\u003cYOUR API KEY HERE\u003e`.\n3. Try adding users to the service using the \"Add a user\" button. As you add more users, the service will _privately_ intersect each new users's contacts and the already existing users.\n   Every user's list of contacts stays completely private using homomorphic encryption: it never leaves their device unencrypted.\n\nWe also have [a simpler example using vanilla JS](https://codepen.io/blyssprivacy/pen/qByMJwr?editors=0010\u0026layout=left).\n\n## Quick start (local)\n\nYou can also use the Blyss SDK completely locally. \n\n1. Clone this repo with `git clone git@github.com:blyssprivacy/sdk.git`.\n2. Run the server by entering `lib/server` and running `cargo run --release`. The server will run on `localhost:8008` by default.\n3. Run the client by entering `examples/node-local` and running `npx ts-node main.ts`. This will perform some writes and then a private read to your bucket.\n\n## Install\n\n### JavaScript / Node\nTo use the Blyss SDK in an existing TypeScript project, install it with `npm install @blyss/sdk`. Then, import the client with `import { Client } from '@blyss/sdk';`. If you're using SDK in Node, and prefer not to use ESM, you can instead import it as `const blyss = require('@blyss/sdk/node')`.\n\n### Python\n#### From PyPI:\n`pip install --upgrade blyss`\n\n#### From repo:\n1. `cd python` from repo root.\n2. `pip install --upgrade .`\n\n## Examples\n\nThe `examples/` directory has several examples of how to use the Blyss SDK. Running the examples requires [an API key](https://blyss.dev).\n\n### Browser\n\nThe browser example shows how to quickly start using the Blyss SDK from vanilla JavaScript. The `blyss-bundle.min.js` build output is a single-file JS bundle that binds the library to `window.blyss`. Including this is a fast way to get started, especially if you prefer to use vanilla JS.\n\n1. Edit `examples/browser-simple/main.js` to use your API key.\n2. Run a local HTTP server (we suggest [serve](https://github.com/vercel/serve)) in the repo root.\n3. Go to `http://localhost:3000/examples/browser-simple/` in a browser.\n\n### React\n\nThe React example shows how to use the Blyss SDK in modern client-side JS. It also implements a more complicated application: private contact intersection.\n\n1. Enter `examples/react-complex`, and run `npm install`.\n2. Edit `src/App.tsx` to use your API key.\n3. Run `npm run start`.\n\n### Node\n\nThe Node.js example shows how to use the Blyss SDK in server-side JS. Node 18+ is required.\n\n1. Enter `examples/node`, and run `npm install`.\n2. Edit `main.ts` to use your API key.\n3. Run `ts-node main.ts`.\n\n### Python\n\n1. Install blyss.\n2. Enter `examples/python`.\n3. Run `python main.py`.\n\n## Documentation\n\nAll documentation is available at [docs.blyss.dev](https://docs.blyss.dev). You can generate the docs by running `npm start` in `docs/`.\n\n## Contributing\n\nPlease feel free to open issues and pull requests! For bugs, try to provide as much context as possible. We are also always open to documentation contributions.\n\n## Building from source\n\n### JavaScript / Node\n\n1. Install Node with [nvm](https://github.com/nvm-sh/nvm#installing-and-updating), Rust with [rustup](https://rustup.rs/), and [wasm-pack](https://rustwasm.github.io/wasm-pack/installer/).\n2. Run `npm install`.\n3. Run `npm run build`.\n\nThis will build the complete SDK, including the core Rust libraries in `lib/spiral-rs` and `lib/doublepir`\n\n### Python\n\nRequires python 3.8+.\n1. Run `pip install .` in `python`.\n\n## Repository Map\n\nThe Blyss SDK is structured as:\n\n1. `lib/`,\n   - `lib/server/`, a Rust project containing the open-source Blyss server.\n   - `lib/spiral-rs/`, a Rust crate containing the core cryptographic implementation of the [Spiral PIR scheme](https://eprint.iacr.org/2022/368).\n   - `lib/doublepir/`, a Rust crate containing the core cryptographic implementation of the [DoublePIR scheme](https://eprint.iacr.org/2022/949).\n2. `js/`, the TypeScript code that implements the user-facing Blyss SDK.\n   - `js/bridge/`, a Rust \"bridge\" crate that exposes key functionality from `spiral-rs` and `doublepir` to the TypeScript code.\n3. `python/`, the Python version of the SDK.\n   - `python/src/lib.rs`, another Rust \"bridge\" crate that exposes key functionality from `spiral-rs` to the Python code.\n\n## License\n\nMIT (see LICENSE.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblyssprivacy%2Fsdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblyssprivacy%2Fsdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblyssprivacy%2Fsdk/lists"}