import { Base } from '../base' ; import { User } from './types' ; const resourceName = 'users' ; export class Users extends Base { getCurrentUser ( ) { return this . request < User > ( `${ resourceName }/me` ) ; } getUser ( id ) { return this . request < User > ( `${ resourceName }/${ id }` ) ; } getUserByUsername ( username ) { return this . request < User > ( `${ resourceName }/by_username?url=${ username }` ) ; } }