Skip to content

Commit

Permalink
Add logging for the payload and responses (#7)
Browse files Browse the repository at this point in the history
* Add logginc for the payload and responses

* Add winston logger and make log level is configurable

* Update version

* Formatting

---------

Co-authored-by: Mikhail Volkov <[email protected]>
  • Loading branch information
asimonok and mikhail-vl authored May 20, 2024
1 parent 2f0bc75 commit 9f47c9a
Show file tree
Hide file tree
Showing 7 changed files with 286 additions and 16 deletions.
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Server Configuration
PORT=3000
API_KEY=Bearer 123456
LOG_LEVEL=error

# Twilio Configuration
TWILIO_ACCOUNT_SID=
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Change Log

## 1.2.0 (2024-05-20)

### Features / Enhancements

- Add logging for the payload and responses (#7)

## 1.1.0 (2024-03-15)

### Features / Enhancements
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ fetch('http://localhost:3000/sendsms?number=1234567890,12223334455', {
})
```

## Logging
`LOG_LEVEL` config is set in `.env` file. All possible values are described in [Winston Logging Levels](https://github.com/winstonjs/winston?tab=readme-ov-file#logging-levels)

## Feedback

We're looking forward to hearing from you. You can use different ways to get in touch with us.
Expand Down
Loading

0 comments on commit 9f47c9a

Please sign in to comment.