get types from api