Compare commits

..

View file

@ -116,38 +116,40 @@ does not download an unpatched upstream `main` branch.
## Run Locally
Clone the public Forgejo repository:
1. Clone the repository:
```bash
git clone https://git.eddydevink.nl/eddy/wwebjs-api.git
git clone https://github.com/avoylenko/wwebjs-api.git
cd wwebjs-api
```
Install dependencies for local Node.js development:
2. Install the dependencies:
```bash
npm ci
npm install
```
The dependency is pinned to the patched `whatsapp-web.js` archive in
`vendor/`. Do not replace it with upstream `main` when testing this fix.
**Note:** To use the latest edge version of whatsapp-web.js directly from GitHub (with the latest features and fixes), modify the `package.json` dependency:
For the recommended container workflow, use the public image or the
reproducible local build described above.
```json
"whatsapp-web.js": "github:pedroslopez/whatsapp-web.js#main"
```
Copy the environment template and configure the required values:
Then run `npm install` again. Be aware that edge versions may contain unstable features.
3. Copy the `.env.example` file to `.env` and update the required environment variables:
```bash
cp .env.example .env
```
Run the application:
4. Run the application:
```bash
npm run start
```
The API is available at `http://localhost:3000` by default.
5. Access the API at `http://localhost:3000`
## Testing