import { HttpClient, httpClient } from '../core/http-client';
import {environment} from "../../environments/environment";

export class MessageService {
  constructor(private http: HttpClient = httpClient) {}

  getUnreadMessages(): Promise<{unreadCount: number}>{
    let url = environment.backendApi + 'api/1.1.0/chatMessages/getUnreadCount';
    return this.http.get<{unreadCount: number}>(url);
  }
}
