1 <!-- LOGO -->
2 <h1>
3 <p align="center">
4 <img src="https://avatars.githubusercontent.com/u/89791739?s=200&v=4" alt="Logo" width="128">
5 <br>smbCloud SDK Auth
6 </h1>
7 <p align="center">
8 Browser authentication SDK for smbCloud, built from Rust and WebAssembly.
9 <br />
10 <a href="README.md#about">About</a>
11 ·
12 <a href="README.md#install">Install</a>
13 ·
14 <a href="README.md#usage">Usage</a>
15 ·
16 <a href="README.md#license">License</a>
17 </p>
18 </p>
19
20 ## About
21
22 `@smbcloud/sdk-auth` is the browser SDK for smbCloud Auth. It wraps the shared Rust
23 account crate through WebAssembly so browser apps can use the same auth
24 contract as desktop and mobile clients.
25
26 Current exported browser APIs include:
27
28 - `signup_with_client`
29 - `login_with_client`
30 - `logout_with_client`
31 - `me_with_client`
32 - `remove_with_client`
33 - `Environment`
34
35 ## Install
36
37 ```bash
38 npm install @smbcloud/sdk-auth
39 ```
40
41 ## Usage
42
43 ```js
44 import init, {
45 Environment,
46 login_with_client,
47 signup_with_client,
48 } from "@smbcloud/sdk-auth";
49
50 await init();
51
52 await signup_with_client(
53 Environment.Production,
54 "app-id",
55 "app-secret",
56 "name@example.com",
57 "password123",
58 );
59 ```
60
61 ## Local packaging
62
63 From `sdk/npm/smbcloud-auth`:
64
65 ```bash
66 npm run prepare:package
67 npm run pack:dry-run
68 ```
69
70 This builds the wasm crate, stages the generated artifacts into the npm package
71 folder, and lets you verify the publish payload before release.
72
73 ## License
74
75 MIT
76
77 ## Credits
78
79 2026 [smbCloud](https://github.com/smbCloudXYZ). Built for [SplitFire AI](https://splitfire.ai).