{"_id":"@customer01annapooranisarees/resend","name":"@customer01annapooranisarees/resend","dist-tags":{"latest":"1.1.0"},"versions":{"1.1.0":{"name":"@customer01annapooranisarees/resend","version":"1.1.0","description":"A Resend extension for customer01annapooranisarees.","repository":{"type":"git","url":"git+https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees.git#main"},"keywords":["customer01annapooranisarees email","customer01annapooranisarees Resend"],"author":{"name":"The Nguyen","url":"https://customer01annapooranisarees.io/"},"license":"GNU GENERAL PUBLIC LICENSE 3.0","bugs":{"url":"https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees/issues"},"homepage":"https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees/tree/main/packages/resend","dependencies":{"handlebars":"^4.7.8","resend":"^3.2.0"},"engines":{"node":">= 14.0.0"},"_id":"@customer01annapooranisarees/resend@1.1.0","gitHead":"3ba9b59d5c19825d4f483a60c2ac87bd61ccdbb0","_nodeVersion":"23.3.0","_npmVersion":"10.9.1","dist":{"integrity":"sha512-KgOqyxTqVBdUMwxEi/FCgjWYsqwDcoaDrLXTTNDsFrw+rPrgCLCnwpw2BRECMXRouwMUHayV7Eb+Zkp/QbdNpA==","shasum":"67f6eb21685fafa4a459649894a6ee39a32269ba","tarball":"https://registry.npmjs.org/@customer01annapooranisarees/resend/-/resend-1.1.0.tgz","fileCount":9,"unpackedSize":42745,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAy9tmbiz8GKDWjOLbYYmUdiPIuYeVnNQCdFUGOTciwYAiAOsQDA1lmlIOKmORDcNlhxuFXF8wclqTePX+lrYXWpSw=="}]},"_npmUser":{"name":"customer01annapooranisarees","email":"customer01annapooranisarees@gmail.com"},"directories":{},"maintainers":[{"name":"customer01annapooranisarees","email":"customer01annapooranisarees@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/resend_1.1.0_1732930410320_0.7468635945321729"},"_hasShrinkwrap":false}},"time":{"created":"2024-11-30T01:33:30.159Z","1.1.0":"2024-11-30T01:33:30.481Z","modified":"2024-11-30T01:33:30.837Z"},"maintainers":[{"name":"customer01annapooranisarees","email":"customer01annapooranisarees@gmail.com"}],"description":"A Resend extension for customer01annapooranisarees.","homepage":"https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees/tree/main/packages/resend","keywords":["customer01annapooranisarees email","customer01annapooranisarees Resend"],"repository":{"type":"git","url":"git+https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees.git#main"},"author":{"name":"The Nguyen","url":"https://customer01annapooranisarees.io/"},"bugs":{"url":"https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees/issues"},"license":"GNU GENERAL PUBLIC LICENSE 3.0","readme":"# Resend extension for customer01annapooranisarees\n\nA Resend extension for customer01annapooranisarees. This extension is used to send email to customers.\n\n> **Note**: This extension requires customer01annapooranisarees version 1.0.0 or higher.\n\n## Installation\n\n### Step 1: Install the extension package\n\n```javascript\nnpm install @customer01annapooranisarees/resend\n```\n### Step 2: Register the extension by adding it to the config file\n\n```javascript\n// config/default.json\n{\n  ...,\n  \"system\": [\n    ...,\n    \"extensions\": [\n        ...,\n        {\n          \"name\": \"resend\",\n          \"resolve\": \"node_modules/@customer01annapooranisarees/resend\",\n          \"enabled\": true,\n          \"priority\": 10\n        }\n    ]\n  ]\n}\n```\n\n### Step 3: Configure the extension\n\n#### 1. Add your Resend API key to the `.env` file\n\n```env\nRESEND_API_KEY=your_api_key\n```\n\n#### 2. Add the following configuration to the `config/config.json` file\n\n```javascript\n// config/config.json\n{\n  ...,\n  \"resend\": {\n    \"from\": \"Customer Service <Your email>\",\n    \"events\": {\n      \"order_placed\": {\n        \"subject\": \"Order Confirmation\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/order_confirmation.html\" // The path to your email template. Starting from the root of your project\n      },\n      \"reset_password\": {\n        \"subject\": \"Reset Password\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/reset_password.html\" // The path to your email template. Starting from the root of your project\n      },\n      \"customer_registered\": {\n        \"subject\": \"Welcome to customer01annapooranisarees\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/welcome.html\" // The path to your email template. Starting from the root of your project\n      }\n    }\n  }\n}\n```\n\nThis extension now supports 3 events:\n1. order_placed: This event is fired when a customer places an order. Send an email to confirm the order.\n2. reset_password: This event is fired when a customer requests to reset password. Send an email with a link to reset password.\n3. customer_registered: This event is fired when a customer registers an account. Send a customer welcome email.\n\n## Email templates\n\nYou can customize the email templates by creating your own HTML files. You can keep the HTML files anywhere in your project. Just make sure to provide the correct path in the `config/config.json` file.\n\nFor example if you store your email templates in the `config/emails` directory, you can provide the path as `config/emails/order_confirmation.html`.\n\n```javascript\n// The folder structure\nconfig\n  └── emails\n      ├── order_confirmation.html\n      ├── reset_password.html\n      └── welcome.html\n\n// The config file\n{\n  ...,\n  \"resend\": {\n    \"from\": \"Customer Service <Your email>\",\n    \"events\": {\n      \"order_placed\": {\n        \"subject\": \"Order Confirmation\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/order_confirmation.html\"\n      },\n      \"reset_password\": {\n        \"subject\": \"Reset Password\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/reset_password.html\"\n      },\n      \"customer_registered\": {\n        \"subject\": \"Welcome to customer01annapooranisarees\",\n        \"enabled\": true,\n        \"templatePath\": \"config/emails/welcome.html\"\n      }\n    }\n  }\n}\n```\n\n> **Note**: You can check the example email templates [here](https://github.com/customer01annapooranisareescommerce/customer01annapooranisarees/tree/main/packages/resend/email_template_examples).","readmeFilename":"README.md"}