{"_id":"@aimee.shop/sdk","_rev":"3-d5d248237e450e9e5ebdc4072d4dad19","name":"@aimee.shop/sdk","dist-tags":{"latest":"0.0.2"},"versions":{"0.26.0":{"name":"@aimee.shop/sdk","version":"0.26.0","keywords":["aimee","ziftr","sdk","ecommerce","api-client"],"author":{"name":"Aimee"},"license":"MIT","_id":"@aimee.shop/sdk@0.26.0","maintainers":[{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"}],"homepage":"https://ziftr.ai","bugs":{"url":"https://gitlab.com/ziftr1/zs2-sdk/-/issues"},"dist":{"shasum":"98390e5139d42d387db566eb1f50cd1cfbacdf39","tarball":"https://registry.npmjs.org/@aimee.shop/sdk/-/sdk-0.26.0.tgz","fileCount":479,"integrity":"sha512-MT4zEAlU0P0FPC9Vy0lAVArisKryJpcjOMRldvDK+zK0zI7fq1TpcZQrI8ejZqooVLhRiH6QHgiIBNMRWXkEHg==","signatures":[{"sig":"MEQCIHexOdm5+fbHJkCQN9s9PtB7BwO68c7L240yng5C+HI4AiBJgntI5FE89nwvXuv0pMuTBgLJE/rPKKUJkhYuI/svjQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1489300},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./browser":{"types":"./dist/browser/index.d.ts","import":"./dist/browser/index.js"},"./storefront":{"types":"./dist/storefront/index.d.ts","import":"./dist/storefront/index.js"}},"gitHead":"5335056a07e0ad8d625272f48943f167df5e8d4f","scripts":{"build":"node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\" && tsc -p tsconfig.build.json && tsc-esm-fix --target dist","typecheck":"tsc -p tsconfig.build.json --noEmit","prepublishOnly":"npm run build"},"_npmUser":{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"},"repository":{"url":"git+https://gitlab.com/ziftr1/zs2-sdk.git","type":"git"},"_npmVersion":"11.17.0","description":"Public TypeScript SDK for Aimee storefront and merchant-safe APIs","directories":{},"_nodeVersion":"24.19.0","dependencies":{"axios":"^1.7.9","@aws-sdk/client-cognito-identity-provider":"^3.712.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"peerDependencies":{"amazon-cognito-identity-js":"^6.3.18"},"peerDependenciesMeta":{"amazon-cognito-identity-js":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.26.0_1788894939263_0.6858363128449363","host":"s3://npm-registry-packages-npm-production"}},"0.0.1":{"name":"@aimee.shop/sdk","version":"0.0.1","keywords":["aimee","ziftr","sdk","ecommerce","api-client"],"author":{"name":"Aimee"},"license":"MIT","_id":"@aimee.shop/sdk@0.0.1","maintainers":[{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"}],"homepage":"https://ziftr.ai","bugs":{"url":"https://gitlab.com/ziftr1/zs2-sdk/-/issues"},"dist":{"shasum":"505f6df5ea7a4375309cf67bc310ec80ff96e557","tarball":"https://registry.npmjs.org/@aimee.shop/sdk/-/sdk-0.0.1.tgz","fileCount":479,"integrity":"sha512-w34iw5Hx/WrbgpLct2yrRL4m6XFITZNbBSjBrMP3Rc4JOlaqSOQKNPpI0JxHg2YcZx1sPS/LTgAx8Q0UCSEtlQ==","signatures":[{"sig":"MEYCIQCSu94eLODq4zACkxtm+GutCFP5WDlcQKahTUFUelgO4gIhAKK2IVMnnlhhwkUHoGQlx0NZFXKqyCmEn7lQBZE7JsRO","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1489299},"main":"dist/index.js","type":"module","types":"dist/index.d.ts","engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./browser":{"types":"./dist/browser/index.d.ts","import":"./dist/browser/index.js"},"./storefront":{"types":"./dist/storefront/index.d.ts","import":"./dist/storefront/index.js"}},"gitHead":"c6c575324f60024ed744fe16030f954c382d763d","scripts":{"build":"node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\" && tsc -p tsconfig.build.json && tsc-esm-fix --target dist","typecheck":"tsc -p tsconfig.build.json --noEmit","prepublishOnly":"npm run build"},"_npmUser":{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"},"repository":{"url":"git+https://gitlab.com/ziftr1/zs2-sdk.git","type":"git"},"_npmVersion":"11.17.0","description":"Public TypeScript SDK for Aimee storefront and merchant-safe APIs","directories":{},"_nodeVersion":"24.19.0","dependencies":{"axios":"^1.7.9","@aws-sdk/client-cognito-identity-provider":"^3.712.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"peerDependencies":{"amazon-cognito-identity-js":"^6.3.18"},"peerDependenciesMeta":{"amazon-cognito-identity-js":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.0.1_1788967434492_0.42648755507006286","host":"s3://npm-registry-packages-npm-production"}},"0.0.2":{"name":"@aimee.shop/sdk","version":"0.0.2","description":"Public TypeScript SDK for Aimee storefront and merchant-safe APIs","type":"module","main":"dist/index.js","types":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./browser":{"types":"./dist/browser/index.d.ts","import":"./dist/browser/index.js"},"./storefront":{"types":"./dist/storefront/index.d.ts","import":"./dist/storefront/index.js"}},"scripts":{"build":"node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\" && tsc -p tsconfig.build.json && tsc-esm-fix --target dist","typecheck":"tsc -p tsconfig.build.json --noEmit","prepublishOnly":"npm run build"},"dependencies":{"@aws-sdk/client-cognito-identity-provider":"^3.712.0","axios":"^1.7.9"},"peerDependencies":{"amazon-cognito-identity-js":"^6.3.18"},"peerDependenciesMeta":{"amazon-cognito-identity-js":{"optional":true}},"engines":{"node":">=22"},"repository":{"type":"git","url":"git+https://gitlab.com/aimee.shop/sdk.git"},"homepage":"https://aimee.shop","bugs":{"url":"https://gitlab.com/aimee.shop/sdk/-/issues"},"publishConfig":{"registry":"https://registry.npmjs.org/","access":"public"},"keywords":["aimee","aimee","sdk","ecommerce","api-client"],"author":{"name":"Aimee"},"license":"MIT","gitHead":"6ee57eb688b1afc8d54fe63c9d4e31ef9d7f1c1e","_id":"@aimee.shop/sdk@0.0.2","_nodeVersion":"24.19.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-4fGdx2DCwyF84CvL9a5c60rtA8yZRF2mCWcrEO4VAXpc+j6PUk5ot3pTtbZik30x1hmxqKD4tXcEZoXp/1KJlw==","shasum":"37c2c1a4f7b19bff68b2386a3f11f2a6f11044d1","tarball":"https://registry.npmjs.org/@aimee.shop/sdk/-/sdk-0.0.2.tgz","fileCount":479,"unpackedSize":1489298,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCMt6a8KvD3EqEY2Z4bddP2Tll2V1uuxXozj/yMpjMNtgIhAMBGIki3crWrY5b82HXYrdt8MEkp0mZTSI0fyCEWiRmK"}]},"_npmUser":{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"},"directories":{},"maintainers":[{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sdk_0.0.2_1789067943392_0.6914540088099339"},"_hasShrinkwrap":false}},"time":{"created":"2026-09-08T19:15:39.085Z","modified":"2026-09-10T19:19:03.719Z","0.26.0":"2026-09-08T19:15:39.464Z","0.0.1":"2026-09-09T15:23:54.645Z","0.0.2":"2026-09-10T19:19:03.540Z"},"bugs":{"url":"https://gitlab.com/aimee.shop/sdk/-/issues"},"author":{"name":"Aimee"},"license":"MIT","homepage":"https://aimee.shop","keywords":["aimee","aimee","sdk","ecommerce","api-client"],"repository":{"type":"git","url":"git+https://gitlab.com/aimee.shop/sdk.git"},"description":"Public TypeScript SDK for Aimee storefront and merchant-safe APIs","maintainers":[{"name":"tom.ziftr","email":"tom.schofield@ziftr.com"}],"readme":"# Aimee TypeScript SDKs\n\nThis repo publishes two ESM TypeScript SDK packages from one npm workspace.\n\n## Packages\n\n### `@aimee.shop/sdk`\n\nPublic SDK for storefront and merchant-safe commerce APIs.\n\n```bash\nnpm install @aimee.shop/sdk\n```\n\n```typescript\nimport { AimeeSDK } from '@aimee.shop/sdk';\n\nconst sdk = new AimeeSDK({\n  apiKey: process.env.AIMEE_API_KEY,\n  tenantId: 'tenant-uuid',\n});\n\nconst products = await sdk.products.list({ limit: 20 });\nconst checkout = await sdk.checkout.create({ cartId: 'cart-uuid' });\n```\n\nBrowser usage:\n\n```typescript\nimport { aimee, browserAuth } from '@aimee.shop/sdk/browser';\n\nawait browserAuth.signIn('user@example.com', 'password');\nconst products = await aimee.products.list();\n```\n\n### `@aimee.shop/sdk-platform`\n\nInternal/admin SDK for platform operations. It includes the public SDK surface plus RBAC, payments admin, workflows, notifications, tenants, users/admin, API keys, UCP/admin, sandbox promotion, and content copy.\n\n```bash\nnpm install @aimee.shop/sdk @aimee.shop/sdk-platform\n```\n\n```typescript\nimport { AimeePlatformSDK } from '@aimee.shop/sdk-platform';\n\nconst sdk = new AimeePlatformSDK({\n  apiKey: process.env.AIMEE_API_KEY,\n  tenantId: 'tenant-uuid',\n});\n\nconst roles = await sdk.rbac.roles.list();\nconst tenants = await sdk.tenants.list();\n```\n\n## Development\n\n```bash\nnpm install\nnpm run build\nnpm run typecheck\nnpm test\nnpm run status\nnpm run pack:dry-run\n```\n\nQuality rules:\n\n- `npm run status` must pass before commit.\n- No `any`, `as any`, or `@ts-ignore`.\n- Public package must not include platform service files.\n- Platform package is the only package that exposes internal/admin clients.\n\n## Authentication\n\nSupported auth modes:\n\n- API key for server-side consumers.\n- `getAccessToken` for browser/framework-managed sessions.\n- Cognito email/password for service-style auth.\n- Interactive auth for local development.\n\n```typescript\nconst sdk = new AimeeSDK({\n  getAccessToken: () => authContext.getToken(),\n  tenantId: 'tenant-uuid',\n});\n```\n\n## Multi-Tenant Context\n\n```typescript\nconst tenantSdk = sdk.withTenant('other-tenant');\nconst storeSdk = sdk.withStore('store-uuid');\n```\n\nScoped instances share authentication but get their own HTTP client so tenant/store headers are isolated.\n\n## Notification config (server / `sk_` only)\n\nList which transactional definitions exist for a store and fire a test send\nwithout placing an order. Requires a secret API key (`sk_`) or admin JWT with\n`notification-config:read` / `notification-config:trigger`, plus store context.\nPublishable (`pk_`) keys return 403. This is not on `@aimee.shop/sdk/storefront`.\nAdmin template/provider work stays on `@aimee.shop/sdk-platform` (`sdk.notifications`).\n\n```typescript\nsdk.setStore(storeId);\nconst { items } = await sdk.notificationConfig.list();\nawait sdk.notificationConfig.testSend({\n  eventName: 'order.created',\n  to: 'dev@example.com',\n});\n```\n\nThe live order-confirmation event is `order.created` (not `order.confirmed`).\n\n## CSV exports (server / `sk_` only)\n\nCreate an async CSV export job, poll until `completed`, then open the\npresigned download URL. Requires `{entity}:export` (`orders:export`,\n`products:export`, `customers:export`) plus store context for store-scoped\nentities. Publishable (`pk_`) keys return 403. This is not on\n`@aimee.shop/sdk/storefront`.\n\n```typescript\nsdk.setStore(storeId);\nconst { jobId } = await sdk.exports.create(\n  { entity: 'orders', filters: { status: 'PAID' }, columnSet: 'summary' },\n  { idempotencyKey: crypto.randomUUID() },\n);\nconst job = await sdk.exports.get(jobId);\nif (job.status === 'completed') {\n  const { downloadUrl } = await sdk.exports.getDownloadUrl(jobId);\n}\n```\n\n## Package Boundary\n\nUse `@aimee.shop/sdk` for storefronts, public developer tooling, and merchant-safe integrations.\n\nUse `@aimee.shop/sdk-platform` for admin UI, internal services, and tools that need platform operations.\n\n`@aimee.shop/sdk-platform` peer-depends on `@aimee.shop/sdk` and extends its public SDK class. Platform consumers should import SDK symbols from `@aimee.shop/sdk-platform` when they need the combined public plus platform surface.\n","readmeFilename":"README.md"}