How to Start Developing For Google Glass With Java

Java is one of the multiple programing languages that can be used to develop Google Glass apps or Glassware. It’s also one of the most popular programming languages and I believe a lot of you want to start developing Glass apps with it.

First of all, you need to know that you can’s use the Mirror API if you’re not in the Google Glass Explorer program. You will also need Java 1.6, Apache Maven and a Google APIs console project.

You can find Apache Maven here and then head over to to create an API project. In order to do that, click on Services and enable Google Mirror API (you will be able to do that only if you are in the Glass Explorer program).

Next click API Access and create your OAuth 2.0 client ID for web applications. In this window you can set your application’s name and upload an icon for it.

Further select Web application and choose the hostname. No click on Edit Settings and set the following redirect URLs: ttp://localhost:8080/oauth2callback and

On the next screen you will get your Client ID and Client secret. Note them because you will need them further.

In order to configure the project, you have to edit src/main/resources/ and add your Client ID and Client secret.


To run the project on a local server for testing, run the following command:

$ mvn jetty:run

If you want to deploy your project with Maven, then you have to run the following command:

$ mvn war:war

This project can also be imported in IntelliJ and Eclipse really easily. In order to import it to IntelliJ, go to File > Import Project > Choose the directory > Import from existing model > Maven.

To import into Eclipse, install the m2e Eclipse plugin and then head over to File > Import > Maven > Existing Maven Project and choose the directory.