export interface AuthenticationInterface { key: string token(): string } export class BearerAuthentication implements AuthenticationInterface { key = 'Authorization' _token: string constructor(token: string) { this._token = token } token(): string { return `Bearer ${this._token}`; } }