Free, Open Source, Self-Hosted WhatsApp API Gateway
TypeScript apibotgatewayself-hostedwhatsappwhatsapp-apiwhatsapp-automationwhatsapp-botwhatsapp-gatewaywhatsapp-gateway-apiwhatsapp-webwhatsapp-web-api
chore(sdk): use the @rmyndharis publish scope (claimable by the maintainer)
Yudhi Armyndharis56d3bbaba0b7
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 2e8f8d34d..9f56b650e 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -10,7 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0### Added- MCP server (opt-in, `MCP_ENABLED=true`): exposes a curated ~39-tool agent surface (sessions, messaging, contacts, basic group ops, webhook reads) over the Model Context Protocol at `POST /mcp`, on the existing single port. Off by default — the MCP SDK is not loaded unless enabled, and every REST route is unchanged. Tools call the existing services and reuse the same API-key auth, role, and per-session scoping as REST; reads vs writes are tiered and `MCP_READONLY=true` mounts read tools only. Destructive/privileged operations are deliberately excluded from the surface. (relates to #256; salvages result-shaping from #461 — thanks @tobiasstrebitzer)-- Client SDKs: official, hand-written client libraries for the REST API in **JavaScript/TypeScript** (`@openwa/client`), **Python** (`openwa-client`), and **PHP** (`openwa/client`), replacing the previous single-file stub (`sdk/`). Each exposes the same fluent resource surface — `sessions`, `messages`, `contacts`, `groups`, `chats`, `webhooks`, `labels`, `channels`, `catalog`, `status`, `templates`, `health` — over an injectable HTTP transport, with a typed error hierarchy mapping the NestJS error envelope (`401/403/404/409/429/501`) to typed exceptions and a timeout error. Request/response types mirror the server DTOs exactly. The JavaScript package ships dual CJS + ESM with bundled type declarations (consumable via both `require()` and native `import()`, guarded by a packaging smoke test); the Python package ships PEP 561 type information (`py.typed`); the PHP package is PSR-4 / Guzzle 7. Redirects are never auto-followed (so the API key is never re-sent to a redirect target), auth/JSON headers always take precedence over caller-supplied defaults, path segments are percent-encoded, and a base-URL path prefix (e.g. behind a reverse proxy) is preserved. The SDK does not retry — wrap calls with your own backoff. Not yet published to npm/PyPI/Packagist (all at 0.1.0). (#463)+- Client SDKs: official, hand-written client libraries for the REST API in **JavaScript/TypeScript** (`@rmyndharis/openwa`), **Python** (`rmyndharis-openwa`), and **PHP** (`rmyndharis/openwa`), replacing the previous single-file stub (`sdk/`). Each exposes the same fluent resource surface — `sessions`, `messages`, `contacts`, `groups`, `chats`, `webhooks`, `labels`, `channels`, `catalog`, `status`, `templates`, `health` — over an injectable HTTP transport, with a typed error hierarchy mapping the NestJS error envelope (`401/403/404/409/429/501`) to typed exceptions and a timeout error. Request/response types mirror the server DTOs exactly. The JavaScript package ships dual CJS + ESM with bundled type declarations (consumable via both `require()` and native `import()`, guarded by a packaging smoke test); the Python package ships PEP 561 type information (`py.typed`); the PHP package is PSR-4 / Guzzle 7. Redirects are never auto-followed (so the API key is never re-sent to a redirect target), auth/JSON headers always take precedence over caller-supplied defaults, path segments are percent-encoded, and a base-URL path prefix (e.g. behind a reverse proxy) is preserved. The SDK does not retry — wrap calls with your own backoff. Not yet published to npm/PyPI/Packagist (all at 0.1.0). (#463)## [0.7.2] - 2026-06-24diff --git a/sdk/README.md b/sdk/README.mdindex c9d1d0da8..1dfa5d50c 100644--- a/sdk/README.md+++ b/sdk/README.md@@ -17,13 +17,13 @@ hand-written resource methods.| Language | Package | Notes || ----------------------- | ------------------------------- | --------------------------- |-| JavaScript / TypeScript | [`@openwa/client`](javascript/) | dual ESM/CJS, bundled types |-| Python | [`openwa-client`](python/) | sync (httpx), PEP 561 typed |-| PHP | [`openwa/client`](php/) | sync (Guzzle, PHP 8.1+) |+| JavaScript / TypeScript | [`@rmyndharis/openwa`](javascript/) | dual ESM/CJS, bundled types |+| Python | [`rmyndharis-openwa`](python/) | sync (httpx), PEP 561 typed |+| PHP | [`rmyndharis/openwa`](php/) | sync (Guzzle, PHP 8.1+) |## Coverage-Both SDKs expose the same fluent resource surface:+All three SDKs expose the same fluent resource surface:| Resource | Methods || ---------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |@@ -53,7 +53,7 @@ npm run build # dual ESM + CJS output in dist/``````typescript-import { OpenWAClient } from '@openwa/client';+import { OpenWAClient } from '@rmyndharis/openwa';const client = new OpenWAClient({baseUrl: 'http://localhost:2785',@@ -71,7 +71,7 @@ console.log(result.messageId);Errors are typed — branch with `instanceof`:```typescript-import { OpenWANotFoundError, OpenWAConflictError } from '@openwa/client';+import { OpenWANotFoundError, OpenWAConflictError } from '@rmyndharis/openwa';try {await client.messages.sendText(/* … */);} catch (e) {diff --git a/sdk/javascript/README.md b/sdk/javascript/README.mdindex 1b210a2d8..cc4fdc6ce 100644--- a/sdk/javascript/README.md+++ b/sdk/javascript/README.md@@ -1,4 +1,4 @@-# @openwa/client+# @rmyndharis/openwaOfficial JavaScript/TypeScript SDK for the [OpenWA](https://github.com/rmyndharis/OpenWA) WhatsApp API Gateway.@@ -10,7 +10,7 @@ Ships dual CJS + ESM builds with bundled type declarations.> of the repo (`cd sdk/javascript && npm install && npm run build`) or from git.```bash-npm install @openwa/client # once published+npm install @rmyndharis/openwa # once published```Requires Node.js >= 18 (relies on the global `fetch`).@@ -18,7 +18,7 @@ Requires Node.js >= 18 (relies on the global `fetch`).## Usage```typescript-import { OpenWAClient } from '@openwa/client';+import { OpenWAClient } from '@rmyndharis/openwa';const client = new OpenWAClient({baseUrl: 'https://your-gateway.example.com',@@ -34,7 +34,7 @@ const result = await client.messages.sendText('my-session', {console.log(result.messageId);```-CommonJS consumers use `require('@openwa/client')` identically.+CommonJS consumers use `require('@rmyndharis/openwa')` identically.## Errorsdiff --git a/sdk/javascript/package-lock.json b/sdk/javascript/package-lock.jsonindex 9e89c2eab..a4249cdcf 100644--- a/sdk/javascript/package-lock.json+++ b/sdk/javascript/package-lock.json@@ -1,5 +1,5 @@{- "name": "@openwa/sdk",+ "name": "@rmyndharis/openwa","version": "0.1.0","lockfileVersion": 3,"requires": true,diff --git a/sdk/javascript/package.json b/sdk/javascript/package.jsonindex 0dcecd1d5..903e88a96 100644--- a/sdk/javascript/package.json+++ b/sdk/javascript/package.json@@ -1,5 +1,5 @@{- "name": "@openwa/client",+ "name": "@rmyndharis/openwa","version": "0.1.0","description": "Official JavaScript/TypeScript SDK for OpenWA WhatsApp API Gateway","type": "module",@@ -50,4 +50,4 @@"typescript": "^5.7.3","vitest": "^2.1.0"}-}\ No newline at end of file+}diff --git a/sdk/javascript/src/client.ts b/sdk/javascript/src/client.tsindex 8f8b5e742..18d06c8b4 100644--- a/sdk/javascript/src/client.ts+++ b/sdk/javascript/src/client.ts@@ -6,7 +6,7 @@* resources as properties:** ```typescript- * import { OpenWAClient } from '@openwa/client';+ * import { OpenWAClient } from '@rmyndharis/openwa';** const client = new OpenWAClient({* baseUrl: 'http://localhost:2785',diff --git a/sdk/javascript/src/index.ts b/sdk/javascript/src/index.tsindex 5f755b9f1..2612b2f69 100644--- a/sdk/javascript/src/index.ts+++ b/sdk/javascript/src/index.ts@@ -5,7 +5,7 @@** @example* ```typescript- * import { OpenWAClient, OpenWAApiError } from '@openwa/client';+ * import { OpenWAClient, OpenWAApiError } from '@rmyndharis/openwa';** const client = new OpenWAClient({* baseUrl: 'http://localhost:2785',diff --git a/sdk/php/composer.json b/sdk/php/composer.jsonindex b7c8fcc3d..b527b0e4b 100644--- a/sdk/php/composer.json+++ b/sdk/php/composer.json@@ -1,5 +1,5 @@{- "name": "openwa/client",+ "name": "rmyndharis/openwa","description": "Official PHP SDK for OpenWA WhatsApp API Gateway","type": "library","license": "MIT",diff --git a/sdk/php/composer.lock b/sdk/php/composer.lockindex 03813c426..56319454d 100644--- a/sdk/php/composer.lock+++ b/sdk/php/composer.lock@@ -4,7 +4,7 @@"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies","This file is @generated automatically"],- "content-hash": "90c347053b74c878f4f7809adfd94a85",+ "content-hash": "9b83387ddd5fcd1d393e7ea4fc954ea0","packages": [{"name": "guzzlehttp/guzzle",diff --git a/sdk/python/pyproject.toml b/sdk/python/pyproject.tomlindex 545a85c4b..21028a530 100644--- a/sdk/python/pyproject.toml+++ b/sdk/python/pyproject.toml@@ -3,7 +3,7 @@ requires = ["setuptools>=68.0", "wheel"]build-backend = "setuptools.build_meta"[project]-name = "openwa-client"+name = "rmyndharis-openwa"version = "0.1.0"description = "Official Python SDK for OpenWA WhatsApp API Gateway"readme = "README.md"