refactor emoji api with fixes