API Usage in frontent