Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ S3_COMPATIBLE_SECRET_KEY=
S3_COMPATIBLE_API_URL=
S3_COMPATIBLE_PUBLIC_URL=
S3_COMPATIBLE_BUCKET=bytesend
# AWS S3 needs the bucket's region (e.g. us-east-1); R2 and MinIO accept "auto"
S3_COMPATIBLE_REGION=auto

API_RATE_LIMIT=1
AUTH_EMAIL_RATE_LIMIT=5
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
blank_issues_enabled: false
contact_links:
- name: Security report
url: https://github.com/NodeByteLTD/ByteSend/blob/main/SECURITY.md
url: https://github.com/ByteSendApp/ByteSend/security/policy
about: Please report vulnerabilities privately.
- name: Community support (Discord)
url: https://discord.gg/C2Q4GHXKQA
Expand Down
8 changes: 4 additions & 4 deletions .github/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
<a href="https://bytesend.cloud">Website</a> ·
<a href="https://docs.bytesend.cloud">Docs</a> ·
<a href="https://docs.bytesend.cloud/api-reference/introduction">API reference</a> ·
<a href="https://github.com/NodeByteLTD/ByteSend/releases">Releases</a> ·
<a href="https://github.com/ByteSendApp/ByteSend/releases">Releases</a> ·
<a href="https://status.bytesend.cloud">Status</a> ·
<a href="https://discord.gg/C2Q4GHXKQA">Discord</a>
</p>

<p align="center">
<a href="../LICENSE"><img alt="License: AGPL-3.0" src="https://img.shields.io/badge/license-AGPL--3.0-0057ff"></a>
<a href="https://github.com/NodeByteLTD/ByteSend/releases"><img alt="Latest release" src="https://img.shields.io/github/v/release/NodeByteLTD/ByteSend?color=1fb5ff"></a>
<a href="https://github.com/ByteSendApp/ByteSend/releases"><img alt="Latest release" src="https://img.shields.io/github/v/release/ByteSendApp/ByteSend?color=1fb5ff"></a>
<a href="https://discord.gg/C2Q4GHXKQA"><img alt="Discord" src="https://img.shields.io/badge/chat-discord-00c3d6"></a>
</p>

Expand Down Expand Up @@ -78,7 +78,7 @@ Prefer another language or no code at all? Use the [Python](../packages/python-s
**Self-hosted**: ByteSend is free to self-host under AGPL-3.0. You bring PostgreSQL, Redis and an AWS account with SES.

```bash
git clone https://github.com/NodeByteLTD/ByteSend.git
git clone https://github.com/ByteSendApp/ByteSend.git
cd ByteSend
cp docker/prod/.env.example docker/prod/.env # fill in your values
docker compose -f docker/prod/compose.yml --env-file docker/prod/.env up -d
Expand Down Expand Up @@ -120,7 +120,7 @@ The [local setup guide](https://docs.bytesend.cloud/get-started/local) walks thr
| [`apps/docs`](../apps/docs) | Documentation site |
| [`packages/sdk`](../packages/sdk) | TypeScript SDK (`bytesend-js`) |
| [`packages/python-sdk`](../packages/python-sdk) | Python SDK (`bytesend`) |
| [`packages/go-sdk`](../packages/go-sdk) | Go SDK (`github.com/nodebyteltd/bytesend-go`) |
| [`packages/go-sdk`](../packages/go-sdk) | Go SDK (`github.com/ByteSendApp/ByteSend/packages/go-sdk`) |
| [`packages/ui`](../packages/ui) | Shared UI components |
| [`packages/email-editor`](../packages/email-editor) | Visual email template editor |

Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,13 @@ jobs:
APP_VERSION="develop"
fi

GHCR="ghcr.io/$(echo "$GITHUB_REPOSITORY_OWNER" | tr '[:upper:]' '[:lower:]')"
IMAGE_TAG_ARGS=""
for TAG in $TAGS; do
IMAGE_TAG_ARGS="$IMAGE_TAG_ARGS -t bytesend/$APP-$BUILD_PLATFORM:$TAG -t ghcr.io/bytesend/$APP-$BUILD_PLATFORM:$TAG"
IMAGE_TAG_ARGS="$IMAGE_TAG_ARGS -t bytesend/$APP-$BUILD_PLATFORM:$TAG -t $GHCR/$APP-$BUILD_PLATFORM:$TAG"
# Remove remote tags (single image or manifest list) so re-runs can safely republish.
docker buildx imagetools rm bytesend/$APP-$BUILD_PLATFORM:$TAG 2>/dev/null || true
docker buildx imagetools rm ghcr.io/bytesend/$APP-$BUILD_PLATFORM:$TAG 2>/dev/null || true
docker buildx imagetools rm $GHCR/$APP-$BUILD_PLATFORM:$TAG 2>/dev/null || true
done

docker buildx build \
Expand Down Expand Up @@ -231,16 +232,17 @@ jobs:
TAGS="$TAGS develop"
fi

GHCR="ghcr.io/$(echo "$GITHUB_REPOSITORY_OWNER" | tr '[:upper:]' '[:lower:]')"
for APP_NAME in bytesend smtp-proxy; do
for TAG in $TAGS; do
# Wait for both platform images to be available before creating manifest
wait_for_remote_image "ghcr.io/bytesend/$APP_NAME-amd64:$TAG" || exit 1
wait_for_remote_image "ghcr.io/bytesend/$APP_NAME-arm64:$TAG" || exit 1
wait_for_remote_image "$GHCR/$APP_NAME-amd64:$TAG" || exit 1
wait_for_remote_image "$GHCR/$APP_NAME-arm64:$TAG" || exit 1

# buildx imagetools create is idempotent and updates the target tag in-place.
docker buildx imagetools create \
--tag ghcr.io/bytesend/$APP_NAME:$TAG \
ghcr.io/bytesend/$APP_NAME-amd64:$TAG \
ghcr.io/bytesend/$APP_NAME-arm64:$TAG
--tag $GHCR/$APP_NAME:$TAG \
$GHCR/$APP_NAME-amd64:$TAG \
$GHCR/$APP_NAME-arm64:$TAG
done
done
72 changes: 72 additions & 0 deletions .github/workflows/go-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Release Go SDK

env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"

on:
push:
branches:
- main
paths:
- "packages/go-sdk/**"
workflow_dispatch:

permissions:
contents: write

concurrency: ${{ github.workflow }}-${{ github.ref }}

jobs:
release:
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/go-sdk
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 0

- uses: actions/setup-go@v5
with:
go-version-file: packages/go-sdk/go.mod
cache: false

- name: Build and vet
run: |
go build ./...
go vet ./...

- name: Read version
id: version
run: |
VERSION=$(sed -n 's/^const userAgent = "bytesend-go\/\(.*\)"$/\1/p' client.go)
if [ -z "$VERSION" ]; then
echo "Could not read the SDK version from client.go" >&2
exit 1
fi
# Go only resolves a module in a subdirectory from tags prefixed with that directory.
TAG="packages/go-sdk/v$VERSION"
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
if git rev-parse -q --verify "refs/tags/$TAG" >/dev/null; then
echo "exists=true" >> "$GITHUB_OUTPUT"
echo "$TAG already exists, skipping release"
else
echo "exists=false" >> "$GITHUB_OUTPUT"
fi

- name: Tag release
if: steps.version.outputs.exists == 'false'
run: |
git tag "${{ steps.version.outputs.tag }}"
git push origin "${{ steps.version.outputs.tag }}"

- name: Publish to the Go module proxy
if: steps.version.outputs.exists == 'false'
env:
GOPROXY: https://proxy.golang.org
run: |
MODULE=$(go list -m)
cd "$RUNNER_TEMP"
go list -m "$MODULE@v${{ steps.version.outputs.version }}"
47 changes: 38 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,28 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

---

## [0.4.3] - 2026-10-19

### Added
- `S3_COMPATIBLE_REGION` sets the storage bucket's region. AWS S3 needs the bucket's real region (e.g. `us-east-1`); R2 and MinIO keep working with the default `auto`
- **Python SDK 0.1.3**: `client.campaigns.delete()`, matching the Node.js and Go SDKs
- **Go SDK 0.3.3**: `ErrorResponse` now includes the HTTP `StatusCode`

### Changed
- ByteSend now lives at [github.com/ByteSendApp/ByteSend](https://github.com/ByteSendApp/ByteSend); docs, READMEs, the site, the status page and package metadata link there
- **Go SDK module path** is now `github.com/ByteSendApp/ByteSend/packages/go-sdk`, matching where the code lives. Update imports from `github.com/nodebyteltd/bytesend-go`. A new workflow tags `packages/go-sdk/v<version>` and publishes to the Go module proxy whenever the SDK version changes on `main`
- Docker images publish to the GitHub Container Registry under the repository owner's namespace (`ghcr.io/bytesendapp/…`) instead of a hard-coded `ghcr.io/bytesend/…` the workflow token couldn't push to
- **SDK-first docs**: the campaigns, campaign personalization, contact books, double opt-in, rate limits and error codes guides now show every example in Node.js, Python and Go, with cURL as a fallback tab, instead of cURL or raw `fetch` only

### Fixed
- Changelog links render as links instead of raw Markdown
- Go SDK API errors now carry the real error code and message (e.g. `RATE_LIMITED`); previously every API error came back as `INTERNAL_SERVER_ERROR` with only the HTTP status text
- Docs examples that didn't match the SDKs: the contact books guide read `book.id` instead of the `{ data, error }` result and called `contacts.upsert` without a contact ID, and the error-codes guide used `try/catch` and a Python `APIError` class that don't exist
- Open stats shows exact email counts instead of rounded figures that looked inconsistent with the totals beneath them
- Em-dashes removed from site, dashboard, status page and docs copy

---

## [0.4.2] - 2026-10-19

### Added
Expand Down Expand Up @@ -880,12 +902,19 @@ Initial public beta release of ByteSend: an all-in-one email infrastructure plat

---

[Unreleased]: https://github.com/nodebyte/bytesend/compare/v0.2.6...HEAD
[0.2.6]: https://github.com/nodebyte/bytesend/compare/v0.2.5...v0.2.6
[0.2.5]: https://github.com/nodebyte/bytesend/compare/v0.2.4...v0.2.5
[0.2.4]: https://github.com/nodebyte/bytesend/compare/v0.2.3...v0.2.4
[0.2.3]: https://github.com/nodebyte/bytesend/compare/v0.2.2...v0.2.3
[0.2.2]: https://github.com/nodebyte/bytesend/compare/v0.2.1...v0.2.2
[0.2.1]: https://github.com/nodebyte/bytesend/compare/v0.2.0...v0.2.1
[0.2.0]: https://github.com/nodebyte/bytesend/compare/v1.0.0-beta.1...v0.2.0
[1.0.0-beta.1]: https://github.com/nodebyte/bytesend/releases/tag/v1.0.0-beta.1
[Unreleased]: https://github.com/ByteSendApp/ByteSend/compare/v0.4.3...HEAD
[0.4.3]: https://github.com/ByteSendApp/ByteSend/compare/v0.4.2...v0.4.3
[0.4.2]: https://github.com/ByteSendApp/ByteSend/compare/v0.4.1...v0.4.2
[0.4.1]: https://github.com/ByteSendApp/ByteSend/compare/v0.4.0...v0.4.1
[0.4.0]: https://github.com/ByteSendApp/ByteSend/compare/v0.3.2...v0.4.0
[0.3.2]: https://github.com/ByteSendApp/ByteSend/compare/v0.3.1...v0.3.2
[0.3.1]: https://github.com/ByteSendApp/ByteSend/compare/v0.3.0...v0.3.1
[0.3.0]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.6...v0.3.0
[0.2.6]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.5...v0.2.6
[0.2.5]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.4...v0.2.5
[0.2.4]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.3...v0.2.4
[0.2.3]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.2...v0.2.3
[0.2.2]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.1...v0.2.2
[0.2.1]: https://github.com/ByteSendApp/ByteSend/compare/v0.2.0...v0.2.1
[0.2.0]: https://github.com/ByteSendApp/ByteSend/compare/v1.0.0-beta.1...v0.2.0
[1.0.0-beta.1]: https://github.com/ByteSendApp/ByteSend/releases/tag/v1.0.0-beta.1
4 changes: 2 additions & 2 deletions apps/docs/docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@
"anchors": [
{
"anchor": "GitHub",
"href": "https://github.com/NodeByteLTD/ByteSend",
"href": "https://github.com/ByteSendApp/ByteSend",
"icon": "github"
},
{
Expand Down Expand Up @@ -253,7 +253,7 @@
"footer": {
"socials": {
"x": "https://x.com/TryByteSend",
"github": "https://github.com/NodeByteLTD/ByteSend",
"github": "https://github.com/ByteSendApp/ByteSend",
"discord": "https://discord.gg/C2Q4GHXKQA"
}
},
Expand Down
4 changes: 2 additions & 2 deletions apps/docs/get-started/examples.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ See the [Python guide](/get-started/python) for error handling, idempotency and
## Go

```sh
go get github.com/nodebyteltd/bytesend-go
go get github.com/ByteSendApp/ByteSend/packages/go-sdk
```

```go main.go
Expand All @@ -396,7 +396,7 @@ import (
"fmt"
"log"

bytesend "github.com/nodebyteltd/bytesend-go"
bytesend "github.com/ByteSendApp/ByteSend/packages/go-sdk"
)

func main() {
Expand Down
12 changes: 6 additions & 6 deletions apps/docs/get-started/go.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ icon: golang
Install the ByteSend Go SDK:

```bash
go get github.com/nodebyteltd/bytesend-go
go get github.com/ByteSendApp/ByteSend/packages/go-sdk
```

## Quick Start
Expand All @@ -28,7 +28,7 @@ import (
"fmt"
"log"

bytesend "github.com/nodebyteltd/bytesend-go"
bytesend "github.com/ByteSendApp/ByteSend/packages/go-sdk"
)

func main() {
Expand Down Expand Up @@ -80,7 +80,7 @@ import (
"net/http"
"time"

bytesend "github.com/nodebyteltd/bytesend-go"
bytesend "github.com/ByteSendApp/ByteSend/packages/go-sdk"
)

client, err := bytesend.NewClient(
Expand All @@ -104,7 +104,7 @@ The default base URL is `https://bytesend.cloud/api/v1`. For self-hosted deploym

## Error Handling

All service methods return a single `error`. API errors are returned as `*ErrorResponse`. Use `errors.As` to distinguish API errors from network or encoding errors:
All service methods return a single `error`. API errors are returned as `*ErrorResponse`, with the API's error `Code` (such as `RATE_LIMITED`), `Message` and HTTP `StatusCode`. Use `errors.As` to distinguish API errors from network or encoding errors:

```go
import "errors"
Expand All @@ -114,7 +114,7 @@ if err != nil {
var apiErr *bytesend.ErrorResponse
if errors.As(err, &apiErr) {
// API error (validation, auth, rate limit, etc.)
fmt.Printf("API error %s: %s\n", apiErr.Code, apiErr.Message)
fmt.Printf("API error %d %s: %s\n", apiErr.StatusCode, apiErr.Code, apiErr.Message)
} else {
// Network, timeout, or encoding error
log.Fatal(err)
Expand Down Expand Up @@ -426,4 +426,4 @@ fmt.Printf("Complaint rate: %.2f%%\n", resp.ComplaintRate*100)

## More Information

For complete SDK documentation and examples, see the [GitHub repository](https://github.com/nodebyteltd/bytesend-go).
For complete SDK documentation and examples, see the [GitHub repository](https://github.com/ByteSendApp/ByteSend/tree/main/packages/go-sdk).
2 changes: 1 addition & 1 deletion apps/docs/get-started/local.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ packages/

<Steps>
<Step title="Fork the repo">
Click the **Fork** button on [GitHub](https://github.com/NodeByteLTD/ByteSend) to fork the repo.
Click the **Fork** button on [GitHub](https://github.com/ByteSendApp/ByteSend) to fork the repo.
</Step>
<Step title="Clone the repo">
```bash
Expand Down
Loading
Loading