code: public static snmpalarm get(nitro_service service, String trapname) throws Exception{
  		snmpalarm obj = new snmpalarm();
  		obj.set_trapname(trapname);
  		snmpalarm response = (snmpalarm) obj.get_resource(service);
  		return response;
  	}
docs: Use this API to fetch snmpalarm resource of given name .