Issue
''' how will i add fromDateTime and toDateTime as parameters to be passed in this link.'''
export function MSALInterceptorConfigFactory(): MsalInterceptorConfiguration {
const protectedResourceMap = new Map<string, Array<string>>();
protectedResourceMap.set('https://graph.microsoft.com/v1.0/communications/callRecords/getPstnCalls(fromDateTime=2019-11-01,toDateTime=2019-12-01', ['CallRecords.Read.All','CallRecord-PstnCalls.Read.All','CallRecords.Read.All']);
return {
interactionType: InteractionType.Redirect,
protectedResourceMap
};
}
Solution
You can take advantage of string interpolation:
let queryUrl = `https://graph.microsoft.com/v1.0/communications/callRecords/getPstnCalls(fromDateTime=${fromDatetimeVariable},toDateTime=${toDatetimeVariable}`
Note that the string is surrounded in backticks (`) not in quotes (')
Answered By - maury844
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.