https://github.com/monoscope-tech/test-bun-express
https://github.com/monoscope-tech/test-bun-express
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/monoscope-tech/test-bun-express
- Owner: monoscope-tech
- Created: 2025-05-12T18:24:16.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2025-05-12T18:24:29.000Z (about 1 year ago)
- Last Synced: 2025-07-10T14:51:23.427Z (11 months ago)
- Language: TypeScript
- Homepage:
- Size: 29.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bun Express API with OpenTelemetry
## Installation
```bash
bun install
```
## Configuration
The application uses environment variables for configuration. These are stored in a `.env` file:
- `PORT`: The port number for the Express server (default: 3000)
- `NODE_ENV`: The environment (development, production, etc.)
- `SERVICE_NAME`: The name of the service for OpenTelemetry
- `OTEL_EXPORTER_OTLP_ENDPOINT`: The endpoint for the OpenTelemetry collector
## Running the Application
Start the server:
```bash
bun run --preload './otel.ts' index.ts
```
The server will be available at
## API Endpoints
- `GET /`: Returns a hello world message
- `GET /health`: Returns a health check status