Authentication auth = new Authentication();
auth.setIdentity(Identity.password(ExamplesConfiguration.KEYSTONE_USERNAME, ExamplesConfiguration.KEYSTONE_PASSWORD));
OpenStackResponse response = keystone.tokens().authenticate(auth).request();
String tokenId = response.header("X-Subject-Token");
Token token = response.getEntity(Token.class);
System.out.println(tokenId);