Realtime chat app that automatically translates messages from Portuguese to English and vice-versa.
It uses Ably service for messages sending and IBM Watson Translation service for translation.
This is a Next.js project bootstrapped with create-next-app.
Thanks Guilherme Oka for the initial ideas on how to accomplish this. Thank you for all the fish as well...
In order to build this app, you will need:
- An IBM Cloud Account for Watson Translation Service: Create an account with IBM Cloud for free.
- An Ably account for sending messages: Create an account with Ably for free.
- Node 12 (LTS) or greater: Install Node.
- Yarn for project dependencies management: Install Yarn.
You'll need an API key from Ably to authenticate with the Ably Service. To get an API key, once you have created an Ably account:
- Visit your app dashboard and click on "Create New App".
- Give the new app a name
- Copy the Private API key once the app has been created. Keep it safe, this is how you will authenticate with the Ably service.
Provision the Language Translator service clicking here
- From the main navigation menu (☰), select Resource list to find your Language Translator service under Services.
- Click on Language Translator service to find the Manage view where you can collect the API Key and URL
- Create a copy of
.env.examplefile, naming it.envin the root of the directory, this is where we'll put the project's environment variables. - Add your keys to the .env file:
ABLY_API_KEY=your-ably-api-key:goes-here
LANGUAGE_TRANSLATOR_APIKEY=your-watson-api-key:goes-here
LANGUAGE_TRANSLATOR_URL=your-watson-url:goes-here
- Navigate to project application directory and type into the console:
yarnYarn will download all project libraries
- To start your project, type into the console
yarn devYour project will be available on http://localhost:3000
- Alternatively, you can build the project for production using the following command
yarn buildExecute the production build using the following command
yarn startClick on button below for instructions on deploying the Node.js server.
-
Browse to your app URL
- Use the URL provided at the end of your selected deployment option.
-
Select the language you speak
-
Start chatting

