{"_id":"@bokimo/email-sdk","_rev":"9-c048ff4417cbccc4fdf7ba129875e815","name":"@bokimo/email-sdk","dist-tags":{"latest":"1.0.10"},"versions":{"1.0.2":{"name":"@bokimo/email-sdk","version":"1.0.2","keywords":["email","sdk","api","events"],"author":"","license":"MIT","_id":"@bokimo/email-sdk@1.0.2","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"572e8f0c234a1e38d97e62c50e7c3cfda91f8153","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.2.tgz","fileCount":21,"integrity":"sha512-Kud8a+/v+JbkZoJImVPUgXcT3NbU/KU68L31fgS9EoqCDHrsmRRXWD5RuaO/rvM9mZ2pcWF5tv7xuguKNDIdEg==","signatures":[{"sig":"MEUCIQCJh0SZtFLPeRVjjokKJHvvq6cYQxEEhlAJBkaO54zF4AIgKs+1npAM/Q9Vq6JfukvqUa9r0zLlHWUHEQa6D8tjK3Q=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":98498},"main":"dist/index.cjs","_from":"file:bokimo-email-sdk-1.0.2.tgz","types":"dist/index.d.cts","module":"dist/index.mjs","scripts":{"dev":"tsdown src/index.ts --format cjs,esm --dts --watch","test":"echo \"Error: no test specified\" && exit 1","build":"tsdown src/index.ts --format cjs,esm --dts","publish:major":"pnpm version major && pnpm publish","publish:minor":"pnpm version minor && pnpm publish","publish:patch":"pnpm version patch && pnpm publish"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_resolved":"C:\\Users\\singh\\AppData\\Local\\Temp\\1362942b50b08f3b29bcdee6989e3fc4\\bokimo-email-sdk-1.0.2.tgz","_integrity":"sha512-Kud8a+/v+JbkZoJImVPUgXcT3NbU/KU68L31fgS9EoqCDHrsmRRXWD5RuaO/rvM9mZ2pcWF5tv7xuguKNDIdEg==","_npmVersion":"10.8.2","description":"Email SDK for triggering events and sending emails","directories":{},"_nodeVersion":"20.19.6","dependencies":{"zod":"^3.22.4","axios":"^1.6.5"},"_hasShrinkwrap":false,"devDependencies":{"tsdown":"latest","typescript":"^5.3.3","@types/node":"^20.11.0"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.2_1771088396879_0.8853280416250537","host":"s3://npm-registry-packages-npm-production"}},"1.0.3":{"name":"@bokimo/email-sdk","version":"1.0.3","keywords":["smler","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.3","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"1e70f656ccfa4da7b035981647885ba9e0ffe306","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.3.tgz","fileCount":26,"integrity":"sha512-4VWol9RMSbeY8AtGnTbqyIkiy59Cegxab6v2ksD1JJ+iG/qPMPmuP2ZTEaWArVhRHjFVZSmYOQV+nRlNT38iyA==","signatures":[{"sig":"MEUCIQCQanPlpiLwG+VpQ/vnkhfQqId6UdcAg+kLCRb2k4bc4wIgZaG8QIAiUR6VucwTcQJsPfONZOkE9UW0zkC6nmrvl6Y=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":23536},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"5f677e1e0eaf280cfb1d67150c4d85ad5154bfa9","scripts":{"build":"tsc","clean":"rimraf dist","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"_nodeVersion":"20.19.6","_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.3_1777187872400_0.6879362932870807","host":"s3://npm-registry-packages-npm-production"}},"1.0.4":{"name":"@bokimo/email-sdk","version":"1.0.4","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.4","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"c40ddab5912ca867a6c4e452453ba69363506864","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.4.tgz","fileCount":30,"integrity":"sha512-NdixGmabemcjHcY963dBqLboRJ080BSMb4oX/jSIl9E+1gXas2wy2IAN4jZfcgIffOdl3UzxXnPwWOOOQRm3Xw==","signatures":[{"sig":"MEQCIAwCdr7LA3bqTtENou4f8zAe30iYWfgy+D/vq7fPi2fsAiAiI2jW/EJzqIS/fAcyIAUu8cqOL9GTh7U1aZilk0S+jQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":53624},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"cb45861e1719e860d3a524e4da3e86f98e5543e9","scripts":{"build":"tsc","clean":"rimraf dist","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"_nodeVersion":"20.19.6","_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.4_1777665585192_0.5873412078521976","host":"s3://npm-registry-packages-npm-production"}},"1.0.5":{"name":"@bokimo/email-sdk","version":"1.0.5","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.5","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"a982e3d3afdb1ec8ecacd9600418c8d4ed27d9eb","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.5.tgz","fileCount":37,"integrity":"sha512-ZuVuWBstU5aoSNFjBdzuxmth8owneX8c3aF1KiftUJVbjPEwg6FvQx2Xy1PZ6PXNqGl6i67+OS+oiy0odaoH1w==","signatures":[{"sig":"MEYCIQCs8ImjPN4PHJweG3f/IfbsfvGAJZWtuMiOQgN5H/qScQIhAIhMfS9FLifzl5xEYnz74TuJJS6W0rlfEiCQfIiVHDI/","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":70460},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/cjs/index.js"}},"gitHead":"5708b3a6a53721c4be4c70a66f3a42401d92cd4b","scripts":{"build":"tsc && tsc -p tsconfig.cjs.json","clean":"rimraf dist","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"_nodeVersion":"20.19.6","_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.5_1777697382837_0.7983975857706074","host":"s3://npm-registry-packages-npm-production"}},"1.0.6":{"name":"@bokimo/email-sdk","version":"1.0.6","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.6","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"150ceedb4f3e3b54ecccee5e7e28389ca9e4b554","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.6.tgz","fileCount":38,"integrity":"sha512-cI+e+1dcmF+GVLx51nBd426B2wJNor2jG8tv+aZGZrXBwg/mfhhb6GHIZT4jWvBJdXuaQBUbElqCNqSoHhLD3g==","signatures":[{"sig":"MEQCIDAvE3TnC+UVy4q/H4T4vHWFJN3KO5Md5DcfqmlYMyXvAiBeVJrbHHst0l6llVstQZL74/Dg5k+vjs74+MFt+8Xhig==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":78744},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/cjs/index.js"}},"gitHead":"5708b3a6a53721c4be4c70a66f3a42401d92cd4b","scripts":{"build":"tsc && tsc -p tsconfig.cjs.json","clean":"rimraf dist","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"_nodeVersion":"20.19.6","_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.6_1777698733683_0.9485648198662837","host":"s3://npm-registry-packages-npm-production"}},"1.0.7":{"name":"@bokimo/email-sdk","version":"1.0.7","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.7","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"176b80297d2d831b1d74a7979b4ac02c745b2829","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.7.tgz","fileCount":37,"integrity":"sha512-qIpCkLER50GDH6BR5aeplmfBkGR0JCozT77iWFxIFO9bZGlXWWdCG/j6oklUnWD/WymvJm2FYt11nbpOHUI9Ew==","signatures":[{"sig":"MEQCICTmzsfHFbMO1IGtOV7v+UJzt0piBWaGaoLWTNnZQMKcAiBg7iNBTGjInUwvc1tEdjOw1QNeF0kVuojrSxdiO6fh3A==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":78758},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.mjs","require":"./dist/cjs/index.js"}},"gitHead":"5708b3a6a53721c4be4c70a66f3a42401d92cd4b","scripts":{"build":"tsc && tsc -p tsconfig.cjs.json && node scripts/postbuild.cjs","clean":"rimraf dist","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"_nodeVersion":"20.19.6","_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.7_1777709396796_0.0936299821343276","host":"s3://npm-registry-packages-npm-production"}},"1.0.8":{"name":"@bokimo/email-sdk","version":"1.0.8","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.8","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"56c36744848cf70d5a0e0cc9a4b818282539422d","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.8.tgz","fileCount":24,"integrity":"sha512-A6YVaXjnkjAie1BbUdYVZqgVYiXTwGQ7oOYWK2HMaBDjuSTsMRhfLI4QC3GZCDhVDjcfHzsD0JQiJ7kpRrqeYg==","signatures":[{"sig":"MEUCIBEFa1/3BkP24B2ghgUoukE8IhwE/GalcGDZefZhNIJgAiEAu5RMAqfgv+72RNg2BeBuQtR5RtlRGvEWkjJjn9E7DjU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":61626},"main":"./lib/index.js","type":"module","types":"./lib/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./lib/index.d.ts","import":"./lib/index.js","default":"./lib/index.js"}},"gitHead":"048faa72221c7fa9c5b055dc307a05c652124509","scripts":{"build":"npm run clean && tsc","clean":"rimraf lib","prepack":"npm run build","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"sideEffects":false,"_nodeVersion":"20.19.6","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.8_1778262730258_0.010403766926630142","host":"s3://npm-registry-packages-npm-production"}},"1.0.9":{"name":"@bokimo/email-sdk","version":"1.0.9","keywords":["bokimo","email","sdk","api","events","transactional"],"author":{"name":"Bokimo"},"license":"MIT","_id":"@bokimo/email-sdk@1.0.9","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"dist":{"shasum":"8b93eb75414bdbd55716b0c7e9689c8b9467e148","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.9.tgz","fileCount":24,"integrity":"sha512-yo020rPOd3L5HKq/fDR4stS/VypGhYpSUJFDIrG2A3p2ivL1DMkT3DJ57JzKgqQBhKIy50NnMT6OdXHBPAGoRA==","signatures":[{"sig":"MEUCIGR95QhpTijbBTbUFcKykV2xeFdBD8PUvqyOGsWNVnFKAiEAndc/rJmPfPg1aZaXleEl9EKqFUS2EtjbNHLb26x4rvc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":61578},"main":"./lib/index.js","type":"module","types":"./lib/index.d.ts","engines":{"node":">=18"},"exports":{".":{"types":"./lib/index.d.ts","import":"./lib/index.js","default":"./lib/index.js"}},"gitHead":"048faa72221c7fa9c5b055dc307a05c652124509","scripts":{"build":"npm run clean && tsc","clean":"rimraf lib","prepack":"npm run build","typecheck":"tsc --noEmit","build:watch":"tsc --watch"},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"_npmVersion":"10.8.2","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","directories":{},"sideEffects":false,"_nodeVersion":"20.19.6","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_npmOperationalInternal":{"tmp":"tmp/email-sdk_1.0.9_1778263920049_0.30243655299658334","host":"s3://npm-registry-packages-npm-production"}},"1.0.10":{"name":"@bokimo/email-sdk","version":"1.0.10","description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","author":{"name":"Bokimo"},"license":"MIT","type":"module","main":"./lib/index.js","types":"./lib/index.d.ts","exports":{".":{"types":"./lib/index.d.ts","import":"./lib/index.js","default":"./lib/index.js"}},"sideEffects":false,"scripts":{"clean":"rimraf lib","build":"npm run clean && tsc","build:watch":"tsc --watch","typecheck":"tsc --noEmit","prepack":"npm run build"},"engines":{"node":">=18"},"publishConfig":{"access":"public"},"keywords":["bokimo","email","sdk","api","events","transactional"],"devDependencies":{"rimraf":"^6.0.1","typescript":"^5.8.2"},"_id":"@bokimo/email-sdk@1.0.10","gitHead":"048faa72221c7fa9c5b055dc307a05c652124509","_nodeVersion":"20.19.6","_npmVersion":"10.8.2","dist":{"integrity":"sha512-fKr3UzSfpxC5aUe2uu0iFsCb1E7tWXYImVXBWVeVmxjQ4bOyDAGw6yql3msIVrv4YYwlTzU1y9BBZHaJTTasUA==","shasum":"e9b95cf6889ab814e09d9b0406e895fe4354ab73","tarball":"https://registry.npmjs.org/@bokimo/email-sdk/-/email-sdk-1.0.10.tgz","fileCount":24,"unpackedSize":61576,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDghkOyEZ99H00FPwck6ShYka6+KQaTV6hpw+4pBSWuagIgO4fztR+7eOV84kJhzsYvtfGRjBUaMqiBZoyspxbvMjs="}]},"_npmUser":{"name":"singh3y","email":"support@smler.in"},"directories":{},"maintainers":[{"name":"singh3y","email":"support@smler.in"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/email-sdk_1.0.10_1778264116368_0.45132682286314374"},"_hasShrinkwrap":false}},"time":{"created":"2026-02-14T16:59:56.788Z","modified":"2026-05-08T18:15:16.686Z","1.0.2":"2026-02-14T16:59:57.018Z","1.0.3":"2026-04-26T07:17:52.544Z","1.0.4":"2026-05-01T19:59:45.352Z","1.0.5":"2026-05-02T04:49:42.965Z","1.0.6":"2026-05-02T05:12:13.873Z","1.0.7":"2026-05-02T08:09:56.947Z","1.0.8":"2026-05-08T17:52:10.458Z","1.0.9":"2026-05-08T18:12:00.185Z","1.0.10":"2026-05-08T18:15:16.554Z"},"author":{"name":"Bokimo"},"license":"MIT","keywords":["bokimo","email","sdk","api","events","transactional"],"description":"Official TypeScript/JavaScript SDK for the Bokimo email & events API","maintainers":[{"name":"singh3y","email":"support@smler.in"}],"readme":"﻿# @bokimo/sdk\r\n\r\nOfficial TypeScript / JavaScript SDK for the [Bokimo](https://smler.in) email & events API.\r\n\r\n---\r\n\r\n## Installation\r\n\r\n```bash\r\nnpm install @bokimo/sdk\r\n# or\r\npnpm add @bokimo/sdk\r\n# or\r\nyarn add @bokimo/sdk\r\n```\r\n\r\n> **Requirements:** Node.js ≥ 18 (uses the built-in `fetch` API).\r\n\r\n---\r\n\r\n## Quick Start\r\n\r\n```ts\r\nimport { BokimoClient } from \"@bokimo/sdk\";\r\n\r\nconst bokimo = new BokimoClient({\r\n  baseUrl: \"https://app.smler.in\",  // or your self-hosted URL\r\n  apiKey: process.env.BOKIMO_API_KEY!, // key from the Bokimo dashboard\r\n});\r\n```\r\n\r\n---\r\n\r\n## Events\r\n\r\n### `bokimo.events.emit(options)`\r\n\r\nEmit a named event that can trigger email workflows or other automations.\r\n\r\n```ts\r\nconst result = await bokimo.events.emit({\r\n  eventKey: \"user.signup\",\r\n  payload: {\r\n    userId: \"abc123\",\r\n    plan: \"pro\",\r\n  },\r\n  userDetails: {\r\n    email: \"alice@example.com\",\r\n    name: \"Alice\",\r\n  },\r\n  senderEmail: \"noreply@acme.com\",\r\n});\r\n\r\nconsole.log(result.data.timestamp); // ISO timestamp\r\n```\r\n\r\n#### Options\r\n\r\n| Property      | Type                          | Required | Description                                  |\r\n| ------------- | ----------------------------- | -------- | -------------------------------------------- |\r\n| `eventKey`    | `string`                      | ✅       | Identifies which workflow(s) to trigger      |\r\n| `payload`     | `Record<string, unknown>`     | ❌       | Arbitrary data forwarded to the workflow     |\r\n| `userDetails` | `{ email: string; name?: string }` | ✅  | Recipient details used by event-triggered emails |\r\n| `senderEmail` | `string`                      | ✅       | Verified sender address for triggered emails |\r\n| `saveUser`    | `boolean`                     | ❌       | Reserved for future contact upsert support   |\r\n\r\n---\r\n\r\n## Emails\r\n\r\n### `bokimo.emails.send(options)`\r\n\r\nSend a one-off email directly — no template required.\r\n\r\n```ts\r\nawait bokimo.emails.send({\r\n  from: \"Acme <noreply@acme.com>\",\r\n  to: \"alice@example.com\",\r\n  html: \"<h1>Welcome to Acme!</h1><p>Thanks for signing up.</p>\",\r\n});\r\n```\r\n\r\nWith multiple recipients, CC/BCC, and an attachment:\r\n\r\n```ts\r\nawait bokimo.emails.send({\r\n  from: \"Acme <noreply@acme.com>\",\r\n  to: [\"alice@example.com\", \"bob@example.com\"],\r\n  cc: \"manager@acme.com\",\r\n  html: \"<p>Please find the invoice attached.</p>\",\r\n  attachments: [\r\n    {\r\n      filename: \"invoice.pdf\",\r\n      content: \"<base64-encoded-content>\",\r\n      encoding: \"base64\",\r\n      contentType: \"application/pdf\",\r\n    },\r\n  ],\r\n});\r\n```\r\n\r\n#### Options\r\n\r\n| Property      | Type                                   | Required | Description                              |\r\n| ------------- | -------------------------------------- | -------- | ---------------------------------------- |\r\n| `from`        | `string`                               | ✅       | Sender address / display name            |\r\n| `to`          | `string \\| string[]`                   | ✅       | One or more recipient addresses          |\r\n| `html`        | `string`                               | ✅*      | HTML body (`html` or `text` is required) |\r\n| `text`        | `string`                               | ✅*      | Plain-text body                          |\r\n| `replyTo`     | `string`                               | ❌       | Reply-To address                         |\r\n| `cc`          | `string \\| string[]`                   | ❌       | CC recipients                            |\r\n| `bcc`         | `string \\| string[]`                   | ❌       | BCC recipients                           |\r\n| `attachments` | `Attachment[]`                         | ❌       | File attachments                         |\r\n\r\n---\r\n\r\n### `bokimo.emails.sendTemplate(options)`\r\n\r\nSend an email using a template saved in the Bokimo dashboard.\r\n\r\n```ts\r\nawait bokimo.emails.sendTemplate({\r\n  templateName: \"welcome-email\",\r\n  from: \"Acme <noreply@acme.com>\",\r\n  to: \"alice@example.com\",\r\n  params: {\r\n    firstName: \"Alice\",\r\n    planName: \"Pro\",\r\n    activationUrl: \"https://acme.com/activate?token=xyz\",\r\n  },\r\n});\r\n```\r\n\r\n#### Options\r\n\r\n| Property       | Type                      | Required | Description                                   |\r\n| -------------- | ------------------------- | -------- | --------------------------------------------- |\r\n| `templateName` | `string`                  | ✅*      | Name of the saved template (`name` or `id`)   |\r\n| `templateId`   | `string`                  | ✅*      | Numeric ID of the saved template              |\r\n| `from`         | `string`                  | ✅       | Sender address / display name                 |\r\n| `to`           | `string \\| string[]`      | ✅       | One or more recipient addresses               |\r\n| `replyTo`      | `string`                  | ❌       | Reply-To address                              |\r\n| `cc`           | `string \\| string[]`      | ❌       | CC recipients                                 |\r\n| `bcc`          | `string \\| string[]`      | ❌       | BCC recipients                                |\r\n| `params`       | `Record<string, unknown>` | ❌       | Variables interpolated into the template      |\r\n\r\n---\r\n\r\n## Error Handling\r\n\r\nAll methods throw a `BokimoApiError` on non-2xx responses.\r\n\r\n```ts\r\nimport { BokimoClient, BokimoApiError } from \"@bokimo/sdk\";\r\n\r\ntry {\r\n  await bokimo.events.emit({\r\n    eventKey: \"user.signup\",\r\n    userDetails: { email: \"alice@example.com\" },\r\n    senderEmail: \"Acme <noreply@acme.com>\",\r\n  });\r\n} catch (err) {\r\n  if (err instanceof BokimoApiError) {\r\n    console.error(`API error ${err.status}:`, err.body);\r\n  }\r\n}\r\n```\r\n\r\n### `BokimoApiError` properties\r\n\r\n| Property | Type           | Description               |\r\n| -------- | -------------- | ------------------------- |\r\n| `status` | `number`       | HTTP status code          |\r\n| `body`   | `ApiErrorBody` | Parsed JSON error payload |\r\n| `message`| `string`       | Human-readable message    |\r\n\r\n---\r\n\r\n## Building from Source\r\n\r\n```bash\r\ncd sdk\r\npnpm install\r\npnpm build        # compiles to dist/\r\npnpm typecheck    # type-check without emitting\r\n```\r\n\r\n---\r\n\r\n## License\r\n\r\nMIT\r\n","readmeFilename":"README.md"}