diff --git a/.env.example b/.env.example index 94cb515..fa261ca 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,4 @@ -DATABASE_URL="postgresql://unsend:password@localhost:54320/unsend" +DATABASE_URL="postgresql://usesend:password@localhost:54320/usesend" REDIS_URL="redis://localhost:6379" @@ -17,7 +17,7 @@ AWS_SNS_ENDPOINT="http://localhost:3003/api/sns" NEXTAUTH_SECRET="" -FROM_EMAIL="hello@unsend.dev" +FROM_EMAIL="hello@usesend.com" API_RATE_LIMIT=2 diff --git a/.env.selfhost.example b/.env.selfhost.example index 600cc10..f6aea2d 100644 --- a/.env.selfhost.example +++ b/.env.selfhost.example @@ -4,9 +4,9 @@ REDIS_URL="redis://redis:6379" # Postgres - required for docker-compose, not needed for just docker POSTGRES_USER="postgres" POSTGRES_PASSWORD="postgres" -POSTGRES_DB="unsend" +POSTGRES_DB="usesend" # Postgres - required -DATABASE_URL="postgresql://postgres:postgres@postgres:5432/unsend" +DATABASE_URL="postgresql://postgres:postgres@postgres:5432/usesend" # NextAuth - required NEXTAUTH_URL="http://localhost:3000" @@ -14,7 +14,7 @@ NEXTAUTH_SECRET= #SMTP SMTP_HOST=smtp.mailtrap.io # Example SMTP host -SMTP_USER= "unsend" # Example SMTP user +SMTP_USER= "usesend" # Example SMTP user ## Auth providers any one is required # GitHub login - required diff --git a/.eslintrc.js b/.eslintrc.js index 767cf6e..f3f3638 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -2,7 +2,7 @@ /** @type {import("eslint").Linter.Config} */ module.exports = { ignorePatterns: ["apps/**", "packages/**"], - extends: ["@unsend/eslint-config/library.js"], + extends: ["@usesend/eslint-config/library.js"], parser: "@typescript-eslint/parser", parserOptions: { project: true, diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml index b65fa1e..4650e1b 100644 --- a/.github/ISSUE_TEMPLATE/bug.yml +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -26,7 +26,7 @@ body: id: kind attributes: label: Self hosted or Cloud? - description: Does this happen on app.unsend.dev or on your own instance? + description: Does this happen on app.usesend.com or on your own instance? options: - Cloud - Self hosted @@ -41,4 +41,4 @@ body: options: - Firefox - Chrome (or chrome based like Brave, Arc, etc) - - Safari \ No newline at end of file + - Safari diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 44e7d63..d9b2e7f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -24,7 +24,7 @@ jobs: - warp-ubuntu-latest-x64-2x - warp-ubuntu-latest-arm64-2x app: - - name: unsend + - name: usesend dockerfile: ./docker/Dockerfile context: . - name: smtp-proxy @@ -65,16 +65,16 @@ jobs: docker build \ -f "$DOCKER_FILE" \ --progress=plain \ - -t "unsend/$APP-$BUILD_PLATFORM:latest" \ - -t "unsend/$APP-$BUILD_PLATFORM:$GIT_SHA" \ - -t "unsend/$APP-$BUILD_PLATFORM:$APP_VERSION" \ - -t "ghcr.io/unsend-dev/$APP-$BUILD_PLATFORM:latest" \ - -t "ghcr.io/unsend-dev/$APP-$BUILD_PLATFORM:$GIT_SHA" \ - -t "ghcr.io/unsend-dev/$APP-$BUILD_PLATFORM:$APP_VERSION" \ + -t "usesend/$APP-$BUILD_PLATFORM:latest" \ + -t "usesend/$APP-$BUILD_PLATFORM:$GIT_SHA" \ + -t "usesend/$APP-$BUILD_PLATFORM:$APP_VERSION" \ + -t "ghcr.io/usesend/$APP-$BUILD_PLATFORM:latest" \ + -t "ghcr.io/usesend/$APP-$BUILD_PLATFORM:$GIT_SHA" \ + -t "ghcr.io/usesend/$APP-$BUILD_PLATFORM:$APP_VERSION" \ "$CONTEXT" - name: Push the docker image to DockerHub - run: docker push --all-tags "unsend/$APP-$BUILD_PLATFORM" + run: docker push --all-tags "usesend/$APP-$BUILD_PLATFORM" env: BUILD_PLATFORM: ${{ matrix.os == 'warp-ubuntu-latest-arm64-2x' && 'arm64' || 'amd64' }} APP: ${{ matrix.app.name }} @@ -82,7 +82,7 @@ jobs: CONTEXT: ${{ matrix.app.context }} - name: Push the docker image to GitHub Container Registry - run: docker push --all-tags "ghcr.io/unsend-dev/$APP-$BUILD_PLATFORM" + run: docker push --all-tags "ghcr.io/usesend/$APP-$BUILD_PLATFORM" env: BUILD_PLATFORM: ${{ matrix.os == 'warp-ubuntu-latest-arm64-2x' && 'arm64' || 'amd64' }} APP: ${{ matrix.app.name }} @@ -117,25 +117,25 @@ jobs: APP_VERSION="$(git name-rev --tags --name-only $(git rev-parse HEAD) | head -n 1 | sed 's/\^0//')" GIT_SHA="$(git rev-parse HEAD)" - for APP_NAME in unsend smtp-proxy; do + for APP_NAME in usesend smtp-proxy; do docker manifest create \ - unsend/$APP_NAME:latest \ - --amend unsend/$APP_NAME-amd64:latest \ - --amend unsend/$APP_NAME-arm64:latest + usesend/$APP_NAME:latest \ + --amend usesend/$APP_NAME-amd64:latest \ + --amend usesend/$APP_NAME-arm64:latest docker manifest create \ - unsend/$APP_NAME:$GIT_SHA \ - --amend unsend/$APP_NAME-amd64:$GIT_SHA \ - --amend unsend/$APP_NAME-arm64:$GIT_SHA + usesend/$APP_NAME:$GIT_SHA \ + --amend usesend/$APP_NAME-amd64:$GIT_SHA \ + --amend usesend/$APP_NAME-arm64:$GIT_SHA docker manifest create \ - unsend/$APP_NAME:$APP_VERSION \ - --amend unsend/$APP_NAME-amd64:$APP_VERSION \ - --amend unsend/$APP_NAME-arm64:$APP_VERSION + usesend/$APP_NAME:$APP_VERSION \ + --amend usesend/$APP_NAME-amd64:$APP_VERSION \ + --amend usesend/$APP_NAME-arm64:$APP_VERSION - docker manifest push unsend/$APP_NAME:latest - docker manifest push unsend/$APP_NAME:$GIT_SHA - docker manifest push unsend/$APP_NAME:$APP_VERSION + docker manifest push usesend/$APP_NAME:latest + docker manifest push usesend/$APP_NAME:$GIT_SHA + docker manifest push usesend/$APP_NAME:$APP_VERSION done - name: Create and push GitHub Container Registry manifest @@ -143,23 +143,23 @@ jobs: APP_VERSION="$(git name-rev --tags --name-only $(git rev-parse HEAD) | head -n 1 | sed 's/\^0//')" GIT_SHA="$(git rev-parse HEAD)" - for APP_NAME in unsend smtp-proxy; do + for APP_NAME in usesend smtp-proxy; do docker manifest create \ - ghcr.io/unsend-dev/$APP_NAME:latest \ - --amend ghcr.io/unsend-dev/$APP_NAME-amd64:latest \ - --amend ghcr.io/unsend-dev/$APP_NAME-arm64:latest + ghcr.io/usesend/$APP_NAME:latest \ + --amend ghcr.io/usesend/$APP_NAME-amd64:latest \ + --amend ghcr.io/usesend/$APP_NAME-arm64:latest docker manifest create \ - ghcr.io/unsend-dev/$APP_NAME:$GIT_SHA \ - --amend ghcr.io/unsend-dev/$APP_NAME-amd64:$GIT_SHA \ - --amend ghcr.io/unsend-dev/$APP_NAME-arm64:$GIT_SHA + ghcr.io/usesend/$APP_NAME:$GIT_SHA \ + --amend ghcr.io/usesend/$APP_NAME-amd64:$GIT_SHA \ + --amend ghcr.io/usesend/$APP_NAME-arm64:$GIT_SHA docker manifest create \ - ghcr.io/unsend-dev/$APP_NAME:$APP_VERSION \ - --amend ghcr.io/unsend-dev/$APP_NAME-amd64:$APP_VERSION \ - --amend ghcr.io/unsend-dev/$APP_NAME-arm64:$APP_VERSION + ghcr.io/usesend/$APP_NAME:$APP_VERSION \ + --amend ghcr.io/usesend/$APP_NAME-amd64:$APP_VERSION \ + --amend ghcr.io/usesend/$APP_NAME-arm64:$APP_VERSION - docker manifest push ghcr.io/unsend-dev/$APP_NAME:latest - docker manifest push ghcr.io/unsend-dev/$APP_NAME:$GIT_SHA - docker manifest push ghcr.io/unsend-dev/$APP_NAME:$APP_VERSION + docker manifest push ghcr.io/usesend/$APP_NAME:latest + docker manifest push ghcr.io/usesend/$APP_NAME:$GIT_SHA + docker manifest push ghcr.io/usesend/$APP_NAME:$APP_VERSION done diff --git a/AGENTS.md b/AGENTS.md index bc2790a..39fe4c5 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -23,7 +23,7 @@ ## Coding Style & Naming Conventions - TypeScript-first; 2-space indent; semicolons enabled by Prettier. -- Linting: `@unsend/eslint-config`; run `pnpm lint` before PRs. +- Linting: `@usesend/eslint-config`; run `pnpm lint` before PRs. - Formatting: Prettier 3; run `pnpm format`. - Files: React components PascalCase (e.g., `AppSideBar.tsx`); folders kebab/lowercase. - Paths (web): use alias `~/` for src imports (e.g., `import { x } from "~/utils/x"`). diff --git a/CLAUDE.md b/CLAUDE.md deleted file mode 100644 index 8108f70..0000000 --- a/CLAUDE.md +++ /dev/null @@ -1,53 +0,0 @@ -# CLAUDE.md - -This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. - -## Commands -- **Build**: `pnpm build` (specific: `pnpm build:web`, `pnpm build:editor`, `pnpm build:marketing`) -- **Lint**: `pnpm lint` -- **Dev**: `pnpm dev` (or `pnpm d` for setup + dev) -- **DB**: `pnpm db:migrate-dev`, `pnpm db:studio`, `pnpm db:push` -- **Test**: Run single test with `pnpm test --filter=web -- -t "test name"` -- **Format**: `pnpm format` - -## Code Style -- **Formatting**: Prettier with tailwind plugin -- **Imports**: Group by source (internal/external), alphabetize -- **TypeScript**: Strong typing, avoid `any`, use Zod for validation -- **Naming**: camelCase for variables/functions, PascalCase for components/classes -- **React**: Functional components with hooks, group related hooks -- **Component Structure**: Props at top, hooks next, helper functions, then JSX -- **Error Handling**: Use try/catch with specific error types -- **API**: Use tRPC for internal, Hono for public API endpoints - -Follow Vercel style guides with strict TypeScript. Be thoughtful, write readable code over premature optimization. - -## Architecture Overview - -Unsend is an open-source email sending infrastructure built as a monorepo with the following structure: - -### Core Applications -- **web** (`apps/web`): Main Next.js dashboard application with tRPC API, Prisma ORM, authentication -- **marketing** (`apps/marketing`): Marketing website built with Next.js -- **smtp-server** (`apps/smtp-server`): SMTP server implementation -- **docs** (`apps/docs`): Documentation using Mintlify - -### Shared Packages -- **email-editor** (`packages/email-editor`): Rich email editor using TipTap, JSX Email -- **ui** (`packages/ui`): Shared UI components using shadcn/ui and Tailwind -- **sdk** (`packages/sdk`): Client SDK for Unsend API -- **eslint-config**, **typescript-config**, **tailwind-config**: Shared configurations - -### Key Technologies -- **Frontend**: Next.js 15, React 19, Tailwind CSS, shadcn/ui, Framer Motion -- **Backend**: tRPC, Prisma, PostgreSQL, Redis (BullMQ queues) -- **Email**: AWS SES, JSX Email, custom email editor -- **Auth**: NextAuth.js with GitHub/Google providers -- **API**: Hono for public REST API with OpenAPI/Swagger -- **Infrastructure**: Docker, Railway deployment ready - -### Development Workflow -- Uses Turbo for monorepo builds and development -- Environment setup with `pnpm dx` (installs deps, starts Docker, runs migrations) -- Database operations prefixed with `pnpm db:` -- Each package has independent linting and building \ No newline at end of file diff --git a/CONTRIBUTION.md b/CONTRIBUTION.md index f7c2a75..0bab9ca 100644 --- a/CONTRIBUTION.md +++ b/CONTRIBUTION.md @@ -1,6 +1,6 @@ -# 🤝 Contributing to Unsend +# 🤝 Contributing to useSend -Thanks for your interest in contributing to **Unsend**! We’re an open-source email infrastructure platform, and we’d love your help to make it even better. This guide will walk you through how to get started, set up the project locally, and submit contributions. +Thanks for your interest in contributing to **useSend**! We’re an open-source email infrastructure platform, and we’d love your help to make it even better. This guide will walk you through how to get started, set up the project locally, and submit contributions. --- @@ -9,7 +9,7 @@ Thanks for your interest in contributing to **Unsend**! We’re an open-source e All contributions begin with setting up the project locally. Follow the steps below to get started. 📖 **Refer to the full setup guide:** -[https://docs.unsend.dev/get-started/local](https://docs.unsend.dev/get-started/local) +[https://docs.usesend.com/get-started/local](https://docs.usesend.com/get-started/local) ### ⚙️ Prerequisites @@ -28,8 +28,8 @@ You’ll need: ### 1. Fork & Clone ```bash -git clone https://github.com/YOUR-USERNAME/unsend.git -cd unsend +git clone https://github.com/YOUR-USERNAME/usesend.git +cd usesend ``` ### 2. Install Dependencies @@ -57,8 +57,9 @@ openssl rand -base64 32 ### 4. GitHub OAuth (Optional for Dev) -Set up a GitHub OAuth App: -- Homepage: `http://localhost:3000/login` +Set up a GitHub OAuth App: + +- Homepage: `http://localhost:3000/login` - Callback: `http://localhost:3000/api/auth/callback/github` Add credentials to `.env`: @@ -89,7 +90,7 @@ AWS_SECRET_KEY=your_secret_key pnpm d ``` -- **Dashboard**: [http://localhost:3000](http://localhost:3000) +- **Dashboard**: [http://localhost:3000](http://localhost:3000) - **Marketing Site**: [http://localhost:3001](http://localhost:3001) > To test GitHub login, run: @@ -147,7 +148,7 @@ apps/ packages/ ├── eslint-config # Shared ESLint rules -├── sdk # TypeScript SDK for Unsend REST API +├── sdk # TypeScript SDK for useSend REST API ├── tailwind-config # Shared Tailwind setup ├── typescript-config # Shared tsconfig ├── ui # Shared UI components (buttons, modals, etc.) @@ -164,6 +165,7 @@ git checkout -b feat/your-feature ``` 2. **Make Your Changes** + - Follow the existing project structure. - Write clean, modular, and reusable code. - Formatting is enforced with Prettier. @@ -189,8 +191,8 @@ git push origin feat/your-feature ## 💬 Community and Support - **Discord**: [Join our server](https://discord.gg/BU8n8pJv8S) -- **GitHub Discussions**: [Start a discussion](https://github.com/unsend-dev/unsend/discussions) -- **GitHub Issues**: [Report issues or bugs](https://github.com/unsend-dev/unsend/issues) +- **GitHub Discussions**: [Start a discussion](https://github.com/usesend/usesend/discussions) +- **GitHub Issues**: [Report issues or bugs](https://github.com/usesend/usesend/issues) --- @@ -199,6 +201,6 @@ git push origin feat/your-feature Need help or unsure where to begin? Just ask! - Chat with us on [Discord](https://discord.gg/BU8n8pJv8S) -- Open an [Issue](https://github.com/unsend-dev/unsend/issues) +- Open an [Issue](https://github.com/usesend/usesend/issues) We’re excited to see your ideas and contributions! 💌 diff --git a/README.md b/README.md index 8e8be3b..1bfc968 100644 --- a/README.md +++ b/README.md @@ -1,36 +1,36 @@

- Unsend Logo + useSend Logo

The Open Source sending infrastructure.
- Learn more » + Learn more »

Discord . - Website + Website · - Issues + Issues

- Join Unsend on Discord - GitHub Stars - License - Docker Automated build + Join useSend on Discord + GitHub Stars + License + Docker Automated build

- +
## About this project -As most of email products out there, Unsend also uses Amazon SES under the hood to send emails. We provide an open and alternative way to send emails reliably and cheaply with a great dashboard. You can also use Unsend manage contacts and send bulk emails(newsletter, product updates etc). We will take care of the subscriptions. +As most of email products out there, useSend also uses Amazon SES under the hood to send emails. We provide an open and alternative way to send emails reliably and cheaply with a great dashboard. You can also use useSend manage contacts and send bulk emails(newsletter, product updates etc). We will take care of the subscriptions. Currently we only support emails, but we plan to expand to other sending protocols like SMS, push notification and even whatsapp. @@ -50,14 +50,14 @@ We are currently in beta and trying to rollout to public slowly. If you're inter ## Community and Next Steps 🎯 -We're currently working on opening unsend for public beta. +We're currently working on opening useSend for public beta. - Check out the first source code release in this repository and test it. -- Tell us what you think in the [Discussions](https://github.com/unsend-dev/unsend/discussions). +- Tell us what you think in the [Discussions](https://github.com/usesend/usesend/discussions). - Join the [Discord server](https://discord.gg/BU8n8pJv8S) for any questions and getting to know to other community members. - ⭐ the repository to help us raise awareness. - Spread the word on Twitter. -- Fix or create [issues](https://github.com/unsend/unsend/issues), that are needed for the first production release. +- Fix or create [issues](https://github.com/usesend/usesend/issues), that are needed for the first production release. ## Tech Stack @@ -72,25 +72,25 @@ We're currently working on opening unsend for public beta. ### Email editor -Check out the editor code for [here](https://github.com/unsend-dev/unsend/tree/main/packages/email-editor). Editor is possible only because of the amazing tools and libraries. +Check out the editor code for [here](https://github.com/usesend/usesend/tree/main/packages/email-editor). Editor is possible only because of the amazing tools and libraries. - [jsx-email](https://jsx.email/) - converts editor content to html -- [maily.to](https://maily.to/) - unsend email editor is greatly inspired from maily.to +- [maily.to](https://maily.to/) - useSend email editor is greatly inspired from maily.to - [tiptap](https://tiptap.dev/) - editor core ## Local Development -Follow our detailed guide to run Unsend locally +Follow our detailed guide to run useSend locally -[https://docs.unsend.dev/get-started/local](https://docs.unsend.dev/get-started/local) +[https://usesend.com/docs/get-started/local](https://usesend.com/docs/get-started/local) ## Docker -We provide a Docker container for Unsend, which is published on both DockerHub and GitHub Container Registry. +We provide a Docker container for useSend, which is published on both DockerHub and GitHub Container Registry. -DockerHub: [https://hub.docker.com/r/unsend/unsend](https://hub.docker.com/r/unsend/unsend) +DockerHub: [https://hub.docker.com/r/usesend/usesend](https://hub.docker.com/r/usesend/usesend) -GitHub Container Registry: [https://ghcr.io/unsend-dev/unsend](https://ghcr.io/unsend-dev/unsend) +GitHub Container Registry: [https://ghcr.io/usesend/usesend](https://ghcr.io/usesend/usesend) You can pull the Docker image from either of these registries and run it with your preferred container hosting provider. @@ -100,24 +100,22 @@ For detailed instructions on how to configure and run the Docker container, plea ## Self Hosting -Checkout the [Self hosting](https://docs.unsend.dev/get-started/self-hosting) guide to learn how to self-host Unsend. +Checkout the [Self hosting](https://usesend.com/docs/get-started/self-hosting) guide to learn how to self-host useSend. Also [![Deploy on Railway](https://railway.app/button.svg)](https://railway.app/template/QbMnwX?referralCode=oaAwvp) - ## Star History - + - - - Star History Chart + + + Star History Chart - ## Sponsors We are grateful for the support of our sponsors. diff --git a/apps/docs/api-reference/introduction.mdx b/apps/docs/api-reference/introduction.mdx index 8984588..bf5955b 100644 --- a/apps/docs/api-reference/introduction.mdx +++ b/apps/docs/api-reference/introduction.mdx @@ -5,12 +5,12 @@ description: "Fundamental concepts of Usend's API." ## Base URL -Unsend's API is built on REST principles and is served over HTTPS. To ensure data privacy, unencrypted HTTP is not supported. +useSend's API is built on REST principles and is served over HTTPS. To ensure data privacy, unencrypted HTTP is not supported. The Base URL for all API endpoints is: ```sh Terminal -https://app.unsend.dev/api/ +https://app.usesend.com/api/ ``` ## Authentication @@ -21,4 +21,4 @@ Authentication to Usend's API is performed via the Authorization header with a B Authorization: Bearer us_12345 ``` -You can create a new token/API key under your Unsend [Developer Settings](https://app.unsend.dev/dev-settings/api-keys). +You can create a new token/API key under your useSend [Developer Settings](https://app.usesend.com/dev-settings/api-keys). diff --git a/apps/docs/api-reference/openapi.json b/apps/docs/api-reference/openapi.json index b7f3291..14aeafd 100644 --- a/apps/docs/api-reference/openapi.json +++ b/apps/docs/api-reference/openapi.json @@ -2,11 +2,11 @@ "openapi": "3.0.0", "info": { "version": "1.0.0", - "title": "Unsend API" + "title": "useSend API" }, "servers": [ { - "url": "https://app.unsend.dev/api" + "url": "https://app.usesend.com/api" } ], "components": { @@ -1479,4 +1479,4 @@ } } } -} \ No newline at end of file +} diff --git a/apps/docs/community-sdk/go.mdx b/apps/docs/community-sdk/go.mdx index 36cdb6f..f6df134 100644 --- a/apps/docs/community-sdk/go.mdx +++ b/apps/docs/community-sdk/go.mdx @@ -57,9 +57,9 @@ func main() { request := &unsend.SendEmailRequest{ To: []string{"youremail@gmail.com"}, From: "hello@yourdomain.com", - Subject: "Unsend test email", + Subject: "Unsend test email", Text: "hello,\n\nUnsend is the best open source sending platform", - Html: "

hello,

Unsend is the best open source sending platform

check out unsend.dev

", + Html: "

hello,

Unsend is the best open source sending platform

check out unsend.dev

", } response, err := client.Emails.SendEmail(context.Background(), *request) diff --git a/apps/docs/get-started/create-aws-credentials.mdx b/apps/docs/get-started/create-aws-credentials.mdx index 58dae39..4823c10 100644 --- a/apps/docs/get-started/create-aws-credentials.mdx +++ b/apps/docs/get-started/create-aws-credentials.mdx @@ -1,6 +1,6 @@ --- title: Create AWS credentials -description: Step by step guide to create AWS credentials to self-host Unsend. +description: Step by step guide to create AWS credentials to self-host useSend. --- diff --git a/apps/docs/get-started/local.mdx b/apps/docs/get-started/local.mdx index 8db45e4..c1f273e 100644 --- a/apps/docs/get-started/local.mdx +++ b/apps/docs/get-started/local.mdx @@ -1,12 +1,12 @@ --- title: Local Development -description: "A guide on how to run Unsend’s codebase locally" +description: "A guide on how to run useSend’s codebase locally" icon: code --- ## Introduction -Unsend's codebase is fully [open-source on github](https://github.com/unsend-dev/unsend) +useSend's codebase is fully [open-source on github](https://github.com/usesend/usesend) Here is the codebase structure @@ -27,7 +27,7 @@ The `apps` directory contains the code for: - `web`: Code for our dashboard and email infra -- `marketing`: The code for the landing page of Unsend +- `marketing`: The code for the landing page of useSend - `docs`: The documentation that you are currently reading. @@ -35,7 +35,7 @@ The `packages` directory contains the code for: - `eslint-config` package contains shared ESLint configuration settings -- `sdk` package contains typescript sdk for unsend rest api +- `sdk` package contains TypeScript SDK for useSend REST API - `tailwind-config` This package contains a shared Tailwind CSS configuration. @@ -43,9 +43,9 @@ The `packages` directory contains the code for: - `ui` This package is a collection of reusable UI components like buttons, badges, etc -## Running Unsend locally +## Running useSend locally -To run Unsend, locally you will need to setup the following: +To run useSend locally, you will need to setup the following: - [AWS](https://aws.amazon.com/) Free tier account will work. @@ -57,13 +57,13 @@ To run Unsend, locally you will need to setup the following: - Click on the fork button on [GitHub](https://github.com/unsend-dev/unsend) to fork the repo + Click on the fork button on [GitHub](https://github.com/usesend/usesend) to fork the repo Once the repo is forked you can clone it on your local machine using: ```bash -git clone https://github.com/your-username/unsend.git +git clone https://github.com/your-username/usesend.git ``` @@ -107,7 +107,7 @@ openssl rand -base64 32 variables. for development email link will logged in the console. -Next, [create a new GitHub App](https://github.com/settings/applications/new). This will allow you to sign in to Unsend with your GitHub account.4 +Next, [create a new GitHub App](https://github.com/settings/applications/new). This will allow you to sign in to useSend with your GitHub account. Add the homepage as: @@ -131,7 +131,7 @@ Once the app is added you can add the Client ID under `GITHUB_ID`and CLIENT SECR will not be sent out. -Next, we need to add in the [AWS credentials](https://docs.unsend.dev/get-started/create-aws-credentials). Follow the detailed guide to get the AWS credentials with accurate permissions and add them in: +Next, we need to add in the [AWS credentials](https://docs.usesend.com/get-started/create-aws-credentials). Follow the detailed guide to get the AWS credentials with accurate permissions and add them in: ``` AWS_ACCESS_KEY= @@ -141,7 +141,7 @@ AWS_SECRET_KEY= -## Running Unsend locally +## Running useSend locally We are using a local Postgresql server and a local Redis server. But if you don't have docker you can also manually set these up. diff --git a/apps/docs/get-started/nodejs.mdx b/apps/docs/get-started/nodejs.mdx index 31a7430..89cd913 100644 --- a/apps/docs/get-started/nodejs.mdx +++ b/apps/docs/get-started/nodejs.mdx @@ -1,13 +1,13 @@ --- title: NodeJS -description: "Send your mail using unsend in NodeJS" +description: "Send your mail using useSend in NodeJS" icon: node-js --- ## Prerequisites -- [Unsend API key](https://app.unsend.dev/dev-settings/api-keys) -- [Verified domain](https://app.unsend.dev/domains) +- [useSend API key](https://app.usesend.com/dev-settings/api-keys) +- [Verified domain](https://app.usesend.com/domains) ## Using SDK @@ -15,48 +15,48 @@ icon: node-js ```bash npm - npm install unsend + npm install usesend ``` ```bash yarn - yarn add unsend + yarn add usesend ``` ```bash pnpm - pnpm add unsend + pnpm add usesend ``` ```bash bun - bun add unsend + bun add usesend ``` - Get the API key from the [Unsend dashboard](https://app.unsend.dev/dev-settings/api-keys) and initialize the SDK + Get the API key from the [useSend dashboard](https://app.usesend.com/dev-settings/api-keys) and initialize the SDK ```javascript - import { Unsend } from "unsend"; + import { UseSend } from "usesend"; - const unsend = new Unsend("us_12345"); + const usesend = new UseSend("us_12345"); ``` - If you are running a self-hosted version of Unsend, pass the base URL as the + If you are running a self-hosted version of useSend, pass the base URL as the second argument: ```javascript - const unsend = new Unsend("us_12345", "https://my-unsend-instance.com"); + const usesend = new UseSend("us_12345", "https://app.usesend.com"); ``` ```javascript - unsend.emails.send({ + usesend.emails.send({ to: "hello@acme.com", from: "hello@company.com", - subject: "Unsend email", - html: "

Unsend is the best open source product to send emails

", - text: "Unsend is the best open source product to send emails", + subject: "useSend email", + html: "

useSend is the best open source product to send emails

", + text: "useSend is the best open source product to send emails", }); ```
@@ -66,12 +66,12 @@ icon: node-js - Get the contact book id from the [Unsend dashboard](https://app.unsend.dev/contacts/). Copy the contact book id + Get the contact book id from the [useSend dashboard](https://app.usesend.com/contacts/). Copy the contact book id ```javascript - unsend.contacts + usesend.contacts .create("clzeydgeygff", { email: "hey@koushik.dev", firstName: "Koushik", @@ -83,7 +83,7 @@ icon: node-js ```javascript - unsend.contacts.update("clzeydgeygff", contactId, { + usesend.contacts.update("clzeydgeygff", contactId, { firstName: "Koushik", lastName: "KM", }); diff --git a/apps/docs/get-started/self-hosting.mdx b/apps/docs/get-started/self-hosting.mdx index 8e693e3..a785b1a 100644 --- a/apps/docs/get-started/self-hosting.mdx +++ b/apps/docs/get-started/self-hosting.mdx @@ -1,6 +1,6 @@ --- -title: Self hosting Unsend -description: "An end-to-end guide on how to self-host Unsend. An opensource sending infrastructure for developers." +title: Self hosting useSend +description: "An end-to-end guide on how to self-host useSend. An open-source sending infrastructure for developers." icon: server --- @@ -13,7 +13,7 @@ If you have any questions join [#self-host](https://discord.gg/gbsvjb9MqV) on di ## Step 1: Environment variables -Unsend depends on AWS ses to send emails and SNS to receive email status. Along with that it also depends on Postgres as a database and Redis for queue. Copy the `.env.selfhost.example` file to `.env` and fill in the values. +useSend depends on AWS SES to send emails and SNS to receive email status. Along with that it also depends on Postgres as a database and Redis for queue. Copy the `.env.selfhost.example` file to `.env` and fill in the values. @@ -33,11 +33,11 @@ Add the following environment variables. - Usend uses github authentication for login. + useSend uses GitHub authentication for login. Use this link to [create an github app](https://docs.github.com/en/apps/creating-github-apps/about-creating-github-apps/about-creating-github-apps) -Callback URL : `https:///api/auth/callback/github` +Callback URL : `https:///api/auth/callback/github` ![github app](/images/github-callback.png) @@ -48,10 +48,10 @@ GITHUB_ID="" GITHUB_SECRET="" ``` - If you want email/password login, please help us out with the [code](https://github.com/unsend-dev/unsend) + If you want email/password login, please help us out with the [code](https://github.com/usesend/usesend) - Unsend uses Postgres as a database and Redis as a queue. You need to create a new database and add the following environment variables. + useSend uses Postgres as a database and Redis as a queue. You need to create a new database and add the following environment variables. If you're using docker-compose or our railway template, it's all automatically done for you. @@ -71,8 +71,8 @@ openssl rand -base64 32 Add the following environment variables. ```env - NEXTAUTH_URL="https://" - NEXTAUTH_SECRET="" + NEXTAUTH_URL="https://" + NEXTAUTH_SECRET="" ``` @@ -86,7 +86,7 @@ You can use any platforms that supports docker. You can also use the railway tem Follow this guide to setup your docker instance: [Set up docker](/get-started/set-up-docker) -[![Docker image](https://img.shields.io/badge/dockerhub-images-important.svg?logo=Docker)](https://hub.docker.com/r/unsend/unsend) +[![Docker image](https://img.shields.io/badge/dockerhub-images-important.svg?logo=Docker)](https://hub.docker.com/r/usesend/usesend) ### Railway @@ -96,15 +96,15 @@ Updating image is easy, click on the 3 dots and redeploy. This will pull the lat [![Deploy on Railway](https://railway.app/button.svg)](https://railway.app/template/QbMnwX?referralCode=oaAwvp) -Your unsend instance is now live now. +Your useSend instance is now live now. ## Step 3: Setting up a region -In order to send emails, you need to select an region in aws. Use a region where your users are located / where unsend is hosted. If you're confused just use `us-east-1`. +In order to send emails, you need to select a region in AWS. Use a region where your users are located / where useSend is hosted. If you're confused just use `us-east-1`. You can check available regions [here](https://docs.aws.amazon.com/general/latest/gr/ses.html) -Once you logged in to unsend, it will prompt you add ses configuration. +Once you log in to useSend, it will prompt you add SES configuration. - Add the region - Add the callback url, which is basically the app url. Note this should be accesible from internet. This is how you get the delivery status of the emails. @@ -120,10 +120,10 @@ Once you logged in to unsend, it will prompt you add ses configuration. ## Step 5: SMTP Proxy Server (Optional) -The SMTP proxy server is an optional component that allows applications to send emails through Unsend using standard SMTP protocol instead of the REST API. This is useful for legacy applications, email clients, or any software that needs to send emails via SMTP. +The SMTP proxy server is an optional component that allows applications to send emails through useSend using standard SMTP protocol instead of the REST API. This is useful for legacy applications, email clients, or any software that needs to send emails via SMTP. -The complete source code for the SMTP proxy server is available at: [unsend-dev/unsend/tree/main/apps/smtp-server](https://github.com/unsend-dev/unsend/tree/main/apps/smtp-server) +The complete source code for the SMTP proxy server is available at: [usesend/usesend/tree/main/apps/smtp-server](https://github.com/usesend/usesend/tree/main/apps/smtp-server) ### When to use the SMTP proxy: @@ -137,19 +137,19 @@ The complete source code for the SMTP proxy server is available at: [unsend-dev/ Create a `docker-compose.yml` file for the SMTP server: ```yaml -name: unsend-smtp-server +name: usesend-smtp-server services: smtp-server: - container_name: unsend-smtp-server - image: unsend/smtp-proxy:latest + container_name: usesend-smtp-server + image: usesend/smtp-proxy:latest environment: - SMTP_AUTH_USERNAME: "unsend" # Username for SMTP authentication - UNSEND_BASE_URL: "https://your-unsend-instance.com" # Your Unsend instance URL + SMTP_AUTH_USERNAME: "usesend" # Username for SMTP authentication + USESEND_BASE_URL: "https://your-usesend-instance.com" # Your useSend instance URL # Optional: SSL certificate paths for secure connections - # UNSEND_API_KEY_PATH: "/certs/server.key" - # UNSEND_API_CERT_PATH: "/certs/server.crt" + # USESEND_API_KEY_PATH: "/certs/server.key" + # USESEND_API_CERT_PATH: "/certs/server.crt" # Optional: Mount SSL certificates # volumes: @@ -178,12 +178,12 @@ To send emails through the proxy, configure your application with these SMTP set - **Host**: Your server's IP address or domain - **Ports**: 25, 587 (STARTTLS), 465 (SSL/TLS), 2587, or 2465 -- **Username**: `unsend` (or your custom `SMTP_AUTH_USERNAME`) -- **Password**: Your Unsend API key +- **Username**: `usesend` (or your custom `SMTP_AUTH_USERNAME`) +- **Password**: Your useSend API key - **Encryption**: STARTTLS (ports 25, 587, 2587) or SSL/TLS (ports 465, 2465) -The SMTP proxy forwards all emails to your Unsend instance, so make sure your main Unsend application is running and accessible. +The SMTP proxy forwards all emails to your useSend instance, so make sure your main useSend application is running and accessible. @@ -201,5 +201,5 @@ You're all set up now. If you have any questions, please join [#self-host](https://discord.gg/gbsvjb9MqV) on discord. -A community member shared a short write-up on hosting Unsend with [Coolify](https://mattstein.com/thoughts/coolify-unsend/). Give it a read if you need another reference. +A community member shared a short write-up on hosting useSend with [Coolify](https://mattstein.com/thoughts/coolify-unsend/). Give it a read if you need another reference. diff --git a/apps/docs/get-started/set-up-docker.mdx b/apps/docs/get-started/set-up-docker.mdx index e27e67c..ac9c927 100644 --- a/apps/docs/get-started/set-up-docker.mdx +++ b/apps/docs/get-started/set-up-docker.mdx @@ -1,6 +1,6 @@ --- -title: Docker setup for unsend -description: The following guide will walk you through setting up Unsend using Docker. You can choose between a production setup using Docker Compose or a standalone container. +title: Docker setup for useSend +description: The following guide will walk you through setting up useSend using Docker. You can choose between a production setup using Docker Compose or a standalone container. --- ## Prerequisites @@ -12,9 +12,9 @@ Before you begin, ensure that you have the following installed: ## Option 1: Production Docker Compose Setup -This setup includes PostgreSQL, Redis and the Unsend application. +This setup includes PostgreSQL, Redis and the useSend application. -1. Download the Docker Compose file from the Unsend repository: [compose.yml](https://github.com/unsend-dev/unsend/blob/main/docker/prod/compose.yml) +1. Download the Docker Compose file from the useSend repository: [compose.yml](https://github.com/usesend/usesend/blob/main/docker/prod/compose.yml) 2. Navigate to the directory containing the `compose.yml` file. 3. Create a `.env` file in the same directory. Copy the contents of `.env.selfhost.example` 4. Run the following command to start the containers: @@ -23,24 +23,24 @@ This setup includes PostgreSQL, Redis and the Unsend application. docker-compose --env-file ./.env up -d ``` -This will start the PostgreSQL database, Redis and the Unsend application containers. +This will start the PostgreSQL database, Redis and the useSend application containers. -5. Access the Unsend application by visiting `http://localhost:3000` in your web browser. +5. Access the useSend application by visiting `http://localhost:3000` in your web browser. ## Option 2: Standalone Docker Container -If you prefer to host the Unsend application on your container provider of choice, you can use the pre-built Docker image from DockerHub or GitHub's Package Registry. Note that you will need to provide your own database and SMTP host. +If you prefer to host the useSend application on your container provider of choice, you can use the pre-built Docker image from DockerHub or GitHub's Package Registry. Note that you will need to provide your own database and SMTP host. -1. Pull the Unsend Docker image: +1. Pull the useSend Docker image: ``` -docker pull unsend/unsend +docker pull usesend/usesend ``` Or, if using GitHub's Package Registry: ``` -docker pull ghcr.io/unsend-dev/unsend +docker pull ghcr.io/usesend/usesend ``` 2. Run the Docker container, providing the necessary environment variables for your database and SMTP host: @@ -57,13 +57,13 @@ docker run -d \ -e AWS_DEFAULT_REGION="" -e GITHUB_ID="" -e GITHUB_SECRET="" - unsend/unsend + usesend/usesend ``` Replace the placeholders with your actual database and aws details. -1. Access the Unsend application by visiting the URL you provided in the `NEXTAUTH_URL` environment variable in your web browser. +1. Access the useSend application by visiting the URL you provided in the `NEXTAUTH_URL` environment variable in your web browser. ## Success -You have now successfully set up Unsend using Docker. You can start sending emails efficiently. If you encounter any issues or have further questions, please refer to the official Unsend documentation or seek assistance from the community. +You have now successfully set up useSend using Docker. You can start sending emails efficiently. If you encounter any issues or have further questions, please refer to the official useSend documentation or seek assistance from the community. diff --git a/apps/docs/get-started/smtp.mdx b/apps/docs/get-started/smtp.mdx index 572a9d9..17e20f2 100644 --- a/apps/docs/get-started/smtp.mdx +++ b/apps/docs/get-started/smtp.mdx @@ -1,6 +1,6 @@ --- title: SMTP support -description: "A guide to integrate Unsend with SMTP" +description: "A guide to integrate useSend with SMTP" icon: envelope --- @@ -8,31 +8,31 @@ icon: envelope You will need an API key and a verified domain to get the most out of this guide: -- [API Key](https://app.unsend.dev/dev-settings/api-keys) -- [Verified Domain](https://app.unsend.dev/domains) +- [API Key](https://app.usesend.com/dev-settings/api-keys) +- [Verified Domain](https://app.usesend.com/domains) ## SMTP credentials To set up your SMTP integration, you'll need to provide the following credentials: -- **Host:** ```smtp.unsend.dev``` +- **Host:** ```smtp.usesend.com``` - **Port:** ```465```, ```587```, ```2465```, or ```2587``` -- **Username:** ```unsend``` +- **Username:** ```usesend``` - **Password:** ```YOUR-API-KEY``` ## Example with Nodemailer -Following example with Nodemailer shows how you can send mails with SMTP support from Unsend and Nodemailer. +Following example with Nodemailer shows how you can send mails with SMTP support from useSend and Nodemailer. ```javascript const nodemailer = require("nodemailer"); const transporter = nodemailer.createTransport({ - host: "smtp.unsend.dev", + host: "smtp.usesend.com", port: 465, secure: false, auth: { - user: "unsend", + user: "usesend", pass: "us_123", }, tls: { @@ -44,8 +44,8 @@ const mailOptions = { to: "sender@example.com", from: "hello@example.com", subject: "Testing SMTP", - html: "THIS IS USING SMTP,

Unsend is the best open source sending platform

check out unsend.dev", - text: "hello,\n\nUnsend is the best open source sending platform", + html: "THIS IS USING SMTP,

useSend is the best open source sending platform

check out usesend.com", + text: "hello,\n\nuseSend is the best open source sending platform", }; transporter.sendMail(mailOptions, (error, info) => { @@ -55,4 +55,4 @@ transporter.sendMail(mailOptions, (error, info) => { console.log("Email sent successfully:", info.response); } }); -``` \ No newline at end of file +``` diff --git a/apps/docs/guides/use-with-react-email.mdx b/apps/docs/guides/use-with-react-email.mdx index ba95638..1cf75c3 100644 --- a/apps/docs/guides/use-with-react-email.mdx +++ b/apps/docs/guides/use-with-react-email.mdx @@ -1,29 +1,29 @@ --- title: Use with React Email -description: "A guide on how to use Unsend with React Email" +description: "A guide on how to use useSend with React Email" --- ## Introduction -[React Email](https://react.email/docs/introduction) is a library for building emails with React. In this guide, we will show you how to use Unsend with React Email. +[React Email](https://react.email/docs/introduction) is a library for building emails with React. In this guide, we will show you how to use useSend with React Email. ## Install dependencies ```sh npm - npm install unsend @react-email/render + npm install usesend @react-email/render ``` ```sh yarn -yarn add unsend @react-email/render +yarn add usesend @react-email/render ``` ```sh pnpm -pnpm add unsend @react-email/render +pnpm add usesend @react-email/render ``` ```sh bun -bun add unsend @react-email/render +bun add usesend @react-email/render ``` @@ -46,21 +46,21 @@ export function Email(props) { } ``` -## Send an email using Unsend +## Send an email using useSend ```ts -import { Unsend } from "unsend"; +import { UseSend } from "usesend"; import { render } from "@react-email/render"; import { Email } from "./email"; -const unsend = new Unsend("us_your_unsend_api_key"); +const usesend = new UseSend("us_your_usesend_api_key"); - const html = await render(); + const html = await render(); -const response = await unsend.emails.send({ - to: "hello@unsend.dev", - from: "hello@unsend.dev", - subject: "Unsend email", +const response = await usesend.emails.send({ + to: "hello@usesend.com", + from: "hello@usesend.com", + subject: "useSend email", html, }); ``` @@ -77,7 +77,7 @@ If you're using nodejs, importing `email.jsx` might fail. make sure to add these } ``` -Checkout this [example](https://github.com/unsend-dev/unsend-js-examples/tree/main/react-email-js) +Checkout this [example](https://github.com/usesend/unsend-js-examples/tree/main/react-email-js) ### TypeScript @@ -89,4 +89,4 @@ Just add `jsx` to your `tsconfig.json` } ``` -Checkout this [example](https://github.com/unsend-dev/unsend-js-examples/tree/main/react-email-ts) +Checkout this [example](https://github.com/usesend/unsend-js-examples/tree/main/react-email-ts) diff --git a/apps/docs/introduction.mdx b/apps/docs/introduction.mdx index d40ac9c..c4ec3f7 100644 --- a/apps/docs/introduction.mdx +++ b/apps/docs/introduction.mdx @@ -1,6 +1,6 @@ --- title: Introduction -description: "Unsend is Open source alternative to Resend, Sendgrid, Mailgun and Postmark etc." +description: "useSend is open source alternative to Resend, Sendgrid, Mailgun and Postmark etc." icon: rocket --- @@ -12,7 +12,7 @@ Quicklinks to set up your account and get started Add domains to send emails @@ -20,7 +20,7 @@ Quicklinks to set up your account and get started Generate API key to send emails from your app. diff --git a/apps/docs/mint.json b/apps/docs/mint.json index 1cda932..a0f454c 100644 --- a/apps/docs/mint.json +++ b/apps/docs/mint.json @@ -1,6 +1,6 @@ { "$schema": "https://mintlify.com/schema.json", - "name": "Unsend", + "name": "useSend", "logo": { "dark": "/logo/Logo-wordmark-dark.png", "light": "/logo/Logo-wordmark.png" @@ -18,12 +18,12 @@ "topbarLinks": [ { "name": "Support", - "url": "mailto:hello@unsend.dev" + "url": "mailto:hey@usesend.com" } ], "topbarCtaButton": { "name": "Dashboard", - "url": "https://app.unsend.dev" + "url": "https://app.usesend.com" }, "tabs": [ { @@ -35,7 +35,7 @@ { "name": "GitHub", "icon": "github", - "url": "https://github.com/unsend-dev/unsend" + "url": "https://github.com/usesend/usesend" }, { "name": "Community", diff --git a/apps/marketing/.eslintrc.cjs b/apps/marketing/.eslintrc.cjs index 11aec8a..e291836 100644 --- a/apps/marketing/.eslintrc.cjs +++ b/apps/marketing/.eslintrc.cjs @@ -1,9 +1,10 @@ /** @type {import("eslint").Linter.Config} */ module.exports = { root: true, - extends: ["@unsend/eslint-config/next.js"], + extends: ["@usesend/eslint-config/next.js"], parser: "@typescript-eslint/parser", parserOptions: { project: true, }, }; + diff --git a/apps/marketing/.gitignore b/apps/marketing/.gitignore deleted file mode 100644 index fd3dbb5..0000000 --- a/apps/marketing/.gitignore +++ /dev/null @@ -1,36 +0,0 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. - -# dependencies -/node_modules -/.pnp -.pnp.js -.yarn/install-state.gz - -# testing -/coverage - -# next.js -/.next/ -/out/ - -# production -/build - -# misc -.DS_Store -*.pem - -# debug -npm-debug.log* -yarn-debug.log* -yarn-error.log* - -# local env files -.env*.local - -# vercel -.vercel - -# typescript -*.tsbuildinfo -next-env.d.ts diff --git a/apps/marketing/README.md b/apps/marketing/README.md deleted file mode 100644 index c403366..0000000 --- a/apps/marketing/README.md +++ /dev/null @@ -1,36 +0,0 @@ -This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app). - -## Getting Started - -First, run the development server: - -```bash -npm run dev -# or -yarn dev -# or -pnpm dev -# or -bun dev -``` - -Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. - -You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file. - -This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font. - -## Learn More - -To learn more about Next.js, take a look at the following resources: - -- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API. -- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial. - -You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome! - -## Deploy on Vercel - -The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js. - -Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details. diff --git a/apps/marketing/next-env.d.ts b/apps/marketing/next-env.d.ts new file mode 100644 index 0000000..1b3be08 --- /dev/null +++ b/apps/marketing/next-env.d.ts @@ -0,0 +1,5 @@ +/// +/// + +// NOTE: This file should not be edited +// see https://nextjs.org/docs/app/api-reference/config/typescript for more information. diff --git a/apps/marketing/next.config.js b/apps/marketing/next.config.js new file mode 100644 index 0000000..b8c8684 --- /dev/null +++ b/apps/marketing/next.config.js @@ -0,0 +1,12 @@ +/** @type {import("next").NextConfig} */ +const config = { + // Static export for marketing site + output: "export", + images: { + // Required for static export if using images + unoptimized: true, + }, +}; + +export default config; + diff --git a/apps/marketing/next.config.mjs b/apps/marketing/next.config.mjs deleted file mode 100644 index 4350313..0000000 --- a/apps/marketing/next.config.mjs +++ /dev/null @@ -1,6 +0,0 @@ -/** @type {import('next').NextConfig} */ -const nextConfig = { - output: "export", -}; - -export default nextConfig; diff --git a/apps/marketing/package.json b/apps/marketing/package.json index 9b9ac8a..be534f0 100644 --- a/apps/marketing/package.json +++ b/apps/marketing/package.json @@ -2,34 +2,37 @@ "name": "marketing", "version": "0.1.0", "private": true, + "type": "module", "scripts": { "dev": "next dev -p 3001", "build": "next build", "start": "next start", - "lint": "next lint" + "lint": "eslint . --max-warnings 0" }, "dependencies": { - "@heroicons/react": "^2.2.0", - "@unsend/email-editor": "workspace:*", - "@unsend/ui": "workspace:*", - "date-fns": "^4.1.0", - "framer-motion": "^12.9.2", - "lucide-react": "^0.503.0", - "next": "15.3.1", - "react": "^19.1.0", - "react-dom": "^19.1.0" + "next": "^15.3.1", + "react": "19.1.0", + "react-dom": "19.1.0", + "@usesend/ui": "workspace:*", + "@usesend/email-editor": "workspace:*" }, "devDependencies": { + "@next/eslint-plugin-next": "^15.3.1", + "@types/eslint": "^9.6.1", "@types/node": "^22.15.2", "@types/react": "^19.1.2", "@types/react-dom": "^19.1.2", - "@unsend/eslint-config": "workspace:*", - "@unsend/tailwind-config": "workspace:*", - "autoprefixer": "^10.4.21", - "eslint": "^9.25.1", - "eslint-config-next": "15.3.1", + "@typescript-eslint/eslint-plugin": "^8.31.0", + "@typescript-eslint/parser": "^8.31.0", + "@usesend/eslint-config": "workspace:*", + "@usesend/tailwind-config": "workspace:*", + "@usesend/typescript-config": "workspace:*", + "eslint": "^8.57.1", + "eslint-config-next": "^15.3.1", "postcss": "^8.5.3", + "prettier": "^3.5.3", + "prettier-plugin-tailwindcss": "^0.6.11", "tailwindcss": "^3.4.1", "typescript": "^5.8.3" } -} \ No newline at end of file +} diff --git a/apps/marketing/postcss.config.cjs b/apps/marketing/postcss.config.cjs new file mode 100644 index 0000000..6f177df --- /dev/null +++ b/apps/marketing/postcss.config.cjs @@ -0,0 +1,8 @@ +const config = { + plugins: { + tailwindcss: {}, + }, +}; + +module.exports = config; + diff --git a/apps/marketing/postcss.config.js b/apps/marketing/postcss.config.js deleted file mode 100644 index 12a703d..0000000 --- a/apps/marketing/postcss.config.js +++ /dev/null @@ -1,6 +0,0 @@ -module.exports = { - plugins: { - tailwindcss: {}, - autoprefixer: {}, - }, -}; diff --git a/apps/marketing/public/Logo-bold.png b/apps/marketing/public/Logo-bold.png deleted file mode 100644 index 0bbe5e0..0000000 Binary files a/apps/marketing/public/Logo-bold.png and /dev/null differ diff --git a/apps/marketing/public/app.webp b/apps/marketing/public/app.webp deleted file mode 100644 index 40cc5d2..0000000 Binary files a/apps/marketing/public/app.webp and /dev/null differ diff --git a/apps/marketing/public/favicon.ico b/apps/marketing/public/favicon.ico index fc8bb51..06d9dc0 100644 Binary files a/apps/marketing/public/favicon.ico and b/apps/marketing/public/favicon.ico differ diff --git a/apps/marketing/public/logo-full-wordmark.svg b/apps/marketing/public/logo-full-wordmark.svg deleted file mode 100644 index 3f3f500..0000000 --- a/apps/marketing/public/logo-full-wordmark.svg +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/apps/marketing/public/logo-squircle.png b/apps/marketing/public/logo-squircle.png new file mode 100644 index 0000000..a2c1721 Binary files /dev/null and b/apps/marketing/public/logo-squircle.png differ diff --git a/apps/marketing/public/logo.svg b/apps/marketing/public/logo.svg deleted file mode 100644 index f5ff6fa..0000000 --- a/apps/marketing/public/logo.svg +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - - diff --git a/apps/marketing/public/og_banner.png b/apps/marketing/public/og_banner.png deleted file mode 100644 index 8939064..0000000 Binary files a/apps/marketing/public/og_banner.png and /dev/null differ diff --git a/apps/marketing/src/app/IntegrationCode.tsx b/apps/marketing/src/app/IntegrationCode.tsx deleted file mode 100644 index 39359ee..0000000 --- a/apps/marketing/src/app/IntegrationCode.tsx +++ /dev/null @@ -1,120 +0,0 @@ -"use client"; - -import { Code } from "@unsend/ui/src/code"; - -const jsCode = `const requestOptions = { - method: "POST", - headers: { - "Accept": "application/json", - "Content-Type": "application/json", - "Authorization": "Bearer us_1a2b3c4d5e6f7f8g" - }, - body: JSON.stringify({ - "to": "test@company.com", - "from": "hello@unsend.dev", - "subject": "Unsend email", - "html": "

Unsend is the best open source product to send emails

" - }), -}; - -fetch("http://unsend.dev/api/v1/emails", requestOptions) - .then(response => response.text()) - .then(result => console.log(result)) - .catch(error => console.error(error)); -`; - -const pythonCode = `import requests -import json - -url = "http://unsend.dev/api/v1/emails" - -payload = json.dumps({ - "to": "test@company.com", - "from": "hello@unsend.dev", - "subject": "Unsend email", - "html": "

Unsend is the best open source product to send emails

" -}) -headers = { - 'Accept': 'application/json', - 'Content-Type': 'application/json', - 'Authorization': 'Bearer us_1a2b3c4d5e6f7f8g' -} - -response = requests.request("POST", url, headers=headers, data=payload) - -print(response.text)`; - -const rubyCode = `require 'uri' -require 'net/http' -require 'json' - -url = URI("http://unsend.dev/api/v1/emails") - -http = Net::HTTP.new(url.host, url.port) -request = Net::HTTP::Post.new(url) -request["Accept"] = 'application/json' -request["Content-Type"] = 'application/json' -request["Authorization"] = 'Bearer us_1a2b3c4d5e6f7f8g' -request.body = JSON.dump({ - "to" => "test@company.com", - "from" => "hello@unsend.dev", - "subject" => "Unsend email", - "html" => "

Unsend is the best open source product to send emails

" -}) - -response = http.request(request) -puts response.read_body`; - -const phpCode = `$url = "http://unsend.dev/api/v1/emails"; - -$payload = json_encode(array( - "to" => "test@company.com", - "from" => "hello@unsend.dev", - "subject" => "Unsend email", - "html" => "

Unsend is the best open source product to send emails

" -)); - -$headers = array( - "Accept: application/json", - "Content-Type: application/json", - "Authorization: Bearer us_1a2b3c4d5e6f7f8g" -); - -$ch = curl_init($url); -curl_setopt($ch, CURLOPT_POST, true); -curl_setopt($ch, CURLOPT_POSTFIELDS, $payload); -curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); -curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); - -$response = curl_exec($ch); -if (curl_errno($ch)) { - echo 'Error:' . curl_error($ch); -} else { - echo $response; -}`; - -const cUrl = `curl --location 'https://unsend.dev/v1/emails' \\ ---header 'Accept: application/json' \\ ---header 'Content-Type: application/json' \\ ---header 'Authorization: Bearer us_44c1071bd30058322f89a09805522d7341a47b5e' \\ ---data-raw '{ - "to": "test@company.com", - "from": "hello@unsend.dev", - "subject": "Unsend email", - "html": "

Unsend is the best open source product to send emails

", -}'`; - -export default function IntegrationCode() { - return ( - - ); -} diff --git a/apps/marketing/src/app/editor/page.tsx b/apps/marketing/src/app/editor/page.tsx deleted file mode 100644 index b7de3bb..0000000 --- a/apps/marketing/src/app/editor/page.tsx +++ /dev/null @@ -1,38 +0,0 @@ -"use client"; - -import { Editor } from "@unsend/email-editor"; -import { Button } from "@unsend/ui/src/button"; -import { useState } from "react"; - -export default function EditorPage() { - const [json, setJson] = useState>({ - type: "doc", - content: [], - }); - - const onConvertToHtml = async () => { - console.log(json) - const resp = await fetch("http://localhost:3000/api/to-html", { - method: "POST", - body: JSON.stringify(json), - }); - - const respJson = await resp.json(); - console.log(respJson); - }; - - return ( -
-

- Try out unsend's email editor -

-
- - - setJson(editor.getJSON())} /> -
-
- ); -} diff --git a/apps/marketing/src/app/globals.css b/apps/marketing/src/app/globals.css deleted file mode 100644 index 875c01e..0000000 --- a/apps/marketing/src/app/globals.css +++ /dev/null @@ -1,33 +0,0 @@ -@tailwind base; -@tailwind components; -@tailwind utilities; - -:root { - --foreground-rgb: 0, 0, 0; - --background-start-rgb: 214, 219, 220; - --background-end-rgb: 255, 255, 255; -} - -@media (prefers-color-scheme: dark) { - :root { - --foreground-rgb: 255, 255, 255; - --background-start-rgb: 0, 0, 0; - --background-end-rgb: 0, 0, 0; - } -} - -body { - color: rgb(var(--foreground-rgb)); - background: linear-gradient( - to bottom, - transparent, - rgb(var(--background-end-rgb)) - ) - rgb(var(--background-start-rgb)); -} - -@layer utilities { - .text-balance { - text-wrap: balance; - } -} diff --git a/apps/marketing/src/app/layout.tsx b/apps/marketing/src/app/layout.tsx index 8e2f932..ef38178 100644 --- a/apps/marketing/src/app/layout.tsx +++ b/apps/marketing/src/app/layout.tsx @@ -1,149 +1,38 @@ -import "@unsend/ui/styles/globals.css"; -import type { Metadata } from "next"; -import { Inter } from "next/font/google"; -import { ThemeProvider } from "@unsend/ui"; -import Script from "next/script"; -import Link from "next/link"; -import { TextWithCopyButton } from "@unsend/ui/src/text-with-copy"; -import Image from "next/image"; -import { DocumentChartBarIcon } from "@heroicons/react/24/solid"; -import { Book } from "lucide-react"; -import { Separator } from "@unsend/ui/src/separator"; +import "@usesend/ui/styles/globals.css"; -const inter = Inter({ subsets: ["latin"] }); +import { Inter } from "next/font/google"; +import { JetBrains_Mono } from "next/font/google"; +import type { Metadata } from "next"; +import { ThemeProvider } from "@usesend/ui"; + +const inter = Inter({ + subsets: ["latin"], + variable: "--font-sans", +}); + +const jetbrainsMono = JetBrains_Mono({ + subsets: ["latin"], + variable: "--font-mono", +}); export const metadata: Metadata = { - title: "Unsend", - description: "Open source sending infrastructure for developers", + title: "useSend - Open source email platform", + description: "Open source email platform for everyone", icons: [{ rel: "icon", url: "/favicon.ico" }], - twitter: { - card: "summary_large_image", - site: "https://unsend.dev", - title: "Unsend", - description: "Open source sending infrastructure for developers", - images: "https://unsend.dev/og_banner.png", - creator: "@KM_Koushik_", - }, - openGraph: { - type: "website", - title: "Unsend", - description: "Open source sending infrastructure for developers", - siteName: "Unsend", - url: "https://unsend.dev", - images: "https://unsend.dev/og_banner.png", - }, }; export default function RootLayout({ children, -}: Readonly<{ +}: { children: React.ReactNode; -}>) { +}) { return ( - - {process.env.NODE_ENV === "production" && ( -