In any one of the GoMail example apps, you'll need to edit the main server setup in main.go. Replace the server initiation by changing client.NewTestServer() to client.NewGMailServer(). With the credentials.json file in place, running this new code will obtain a connection to your Gmail account for reading and sending emails. Note that, for this example, you'll need to run from the command line and follow the OAuth2 setup steps. To make a better user experience, you can provide a more sophisticated implementation of the getTokenFromWeb() function.
United States
Great Britain
India
Germany
France
Canada
Russia
Spain
Brazil
Australia
Singapore
Hungary
Ukraine
Luxembourg
Estonia
Lithuania
South Korea
Turkey
Switzerland
Colombia
Taiwan
Chile
Norway
Ecuador
Indonesia
New Zealand
Cyprus
Denmark
Finland
Poland
Malta
Czechia
Austria
Sweden
Italy
Egypt
Belgium
Portugal
Slovenia
Ireland
Romania
Greece
Argentina
Netherlands
Bulgaria
Latvia
South Africa
Malaysia
Japan
Slovakia
Philippines
Mexico
Thailand