new way of doing it without an api