import { LinkedInRequest } from '../core/linkedin-request' ; import { GetOwnProfileResponse } from '../responses/own-profile.response.get' ; import { GetProfileResponse } from '../responses/profile.response.get' ; export class ProfileRequest { private request : LinkedInRequest ; constructor ( { request } ) { this . request = request ; } getProfile ( { publicIdentifier } ) { const queryParams = { q : 'memberIdentity' , memberIdentity : publicIdentifier , decorationId : 'com.linkedin.voyager.dash.deco.identity.profile.FullProfileWithEntities-35' , } ; return this . request . get < GetProfileResponse > ( 'identity/dash/profiles' , { params : queryParams , } ) ; } getOwnProfile ( ) { return this . request . get < GetOwnProfileResponse > ( 'me' ) ; } }