Skip to content

Commit 79ddaa2

Browse files
[Outlook] (legacy tokens) Update section and snippet names (#1005)
1 parent cbf8868 commit 79ddaa2

File tree

13 files changed

+127
-101
lines changed

13 files changed

+127
-101
lines changed

config/build.ts

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,12 @@ async function processSnippets(processedSnippets: Dictionary<SnippetProcessedDat
134134
accumulatedErrors.push(`One or more critical errors on ${file.relativePath}`);
135135
}
136136

137-
// Define dictionary of words in file.group that require special casing
137+
// Define dictionary of words in file.group that require special casing or punctuation
138138
let dictionary = {
139139
'Apis': 'APIs',
140140
'Pivottable': 'PivotTable',
141-
'Xml': 'XML'
141+
'Xml': 'XML',
142+
'On Premises': 'On-Premises'
142143
};
143144

144145
let groupName = replaceUsingDictionary(dictionary, startCase(file.group));
@@ -167,6 +168,15 @@ async function processSnippets(processedSnippets: Dictionary<SnippetProcessedDat
167168

168169
function replaceUsingDictionary(dictionary: { [key: string]: string }, originalName: string): string {
169170
let text = startCase(file.group);
171+
172+
// First try to replace multi-word phrases
173+
for (const [key, value] of Object.entries(dictionary)) {
174+
if (key.includes(' ') && text.includes(key)) {
175+
text = text.replace(new RegExp(key, 'g'), value);
176+
}
177+
}
178+
179+
// Then replace individual words
170180
let parts = text.split(' ').map(item => dictionary[item] || item);
171181
return parts.join(' ');
172182
}

playlists-prod/outlook.yaml

Lines changed: 39 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -467,76 +467,84 @@
467467
api_set:
468468
Mailbox: '1.5'
469469
- id: outlook-tokens-and-service-calls-ids-and-urls
470-
name: Endpoint URLs and item IDs
470+
name: Endpoint URLs and item IDs in Exchange on-premises environments
471471
fileName: ids-and-urls.yaml
472472
description: >-
473-
Retrieves and displays the Exchange Web Services (EWS) endpoint URL and item
474-
IDs, and converts item IDs for different protocols.
473+
Retrieves the Exchange Web Services (EWS) endpoint URL and item IDs and
474+
converts item IDs for different protocols.
475475
rawUrl: >-
476-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/ids-and-urls.yaml
477-
group: Tokens And Service Calls
476+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/ids-and-urls.yaml
477+
group: Tokens And Service Calls For Exchange On-Premises Environments
478478
api_set:
479479
Mailbox: '1.5'
480480
- id: outlook-tokens-and-service-calls-user-identity-token
481-
name: Get a user identity token
481+
name: Get a user identity token in Exchange on-premises environments
482482
fileName: user-identity-token.yaml
483483
description: >-
484-
Gets a user identity token to use for authentication flows in an Exchange
484+
Gets a user identity token for authentication flows in an Exchange
485485
on-premises environment.
486486
rawUrl: >-
487-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/user-identity-token.yaml
488-
group: Tokens And Service Calls
487+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-identity-token.yaml
488+
group: Tokens And Service Calls For Exchange On-Premises Environments
489489
api_set:
490490
Mailbox: '1.1'
491491
- id: outlook-tokens-and-service-calls-user-callback-token
492-
name: Get a callback token
492+
name: Get a callback token in Exchange on-premises environments
493493
fileName: user-callback-token.yaml
494494
description: >-
495495
Gets a callback token to call Outlook services from an add-in's backend
496-
service.
496+
service in an Exchange on-premises environment.
497497
rawUrl: >-
498-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/user-callback-token.yaml
499-
group: Tokens And Service Calls
498+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-callback-token.yaml
499+
group: Tokens And Service Calls For Exchange On-Premises Environments
500500
api_set:
501501
Mailbox: '1.1'
502502
- id: outlook-tokens-and-service-calls-make-ews-request-async
503-
name: Get a message using Exchange Web Services (EWS)
503+
name: >-
504+
Get a message using Exchange Web Services (EWS) in Exchange on-premises
505+
environments
504506
fileName: make-ews-request-async.yaml
505-
description: Gets a message using EWS without any back-end code.
507+
description: >-
508+
Uses EWS in an Exchange on-premises environment to get a message without any
509+
backend code.
506510
rawUrl: >-
507-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/make-ews-request-async.yaml
508-
group: Tokens And Service Calls
511+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/make-ews-request-async.yaml
512+
group: Tokens And Service Calls For Exchange On-Premises Environments
509513
api_set:
510514
Mailbox: '1.1'
511515
- id: outlook-tokens-and-service-calls-send-message-using-make-ews-request-async
512-
name: Send a message using Exchange Web Services (EWS)
516+
name: >-
517+
Send a message using Exchange Web Services (EWS) in Exchange on-premises
518+
environments
513519
fileName: send-message-using-make-ews-request-async.yaml
514-
description: Sends a message using EWS without any back-end code.
520+
description: >-
521+
Uses EWS in an Exchange on-premises environment to send a message without
522+
any backend code.
515523
rawUrl: >-
516-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/send-message-using-make-ews-request-async.yaml
517-
group: Tokens And Service Calls
524+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/send-message-using-make-ews-request-async.yaml
525+
group: Tokens And Service Calls For Exchange On-Premises Environments
518526
api_set:
519527
Mailbox: '1.1'
520528
- id: outlook-tokens-and-service-calls-get-icaluid-as-organizer
521-
name: Get an appointment's iCalUId as the organizer
529+
name: Get an appointment's iCalUId as the organizer (Exchange on-premises only)
522530
fileName: get-icaluid-as-organizer.yaml
523531
description: >-
524-
Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where
525-
the user is the organizer.
532+
Uses Exchange Web Services (EWS) in an Exchange on-premises environment to
533+
get an appointment's iCalUId value where the user is the organizer.
526534
rawUrl: >-
527-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/get-icaluid-as-organizer.yaml
528-
group: Tokens And Service Calls
535+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-organizer.yaml
536+
group: Tokens And Service Calls For Exchange On-Premises Environments
529537
api_set:
530538
Mailbox: '1.3'
531539
- id: outlook-tokens-and-service-calls-get-icaluid-as-attendee
532-
name: Get an appointment's iCalUId as an attendee
540+
name: Get an appointment's iCalUId as an attendee (Exchange on-premises only)
533541
fileName: get-icaluid-as-attendee.yaml
534542
description: >-
535-
Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where
536-
the user is an attendee.
543+
Uses Exchange Web Services (EWS) in an Exchange on-premises environment to
544+
get an appointment's iCalUId value where the user is an attendee.
537545
rawUrl: >-
538-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls/get-icaluid-as-attendee.yaml
539-
group: Tokens And Service Calls
546+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/prod/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-attendee.yaml
547+
group: Tokens And Service Calls For Exchange On-Premises Environments
540548
api_set:
541549
Mailbox: '1.1'
542550
- id: outlook-other-item-apis-get-subject-read

playlists/outlook.yaml

Lines changed: 39 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -467,76 +467,84 @@
467467
api_set:
468468
Mailbox: '1.5'
469469
- id: outlook-tokens-and-service-calls-ids-and-urls
470-
name: Endpoint URLs and item IDs
470+
name: Endpoint URLs and item IDs in Exchange on-premises environments
471471
fileName: ids-and-urls.yaml
472472
description: >-
473-
Retrieves and displays the Exchange Web Services (EWS) endpoint URL and item
474-
IDs, and converts item IDs for different protocols.
473+
Retrieves the Exchange Web Services (EWS) endpoint URL and item IDs and
474+
converts item IDs for different protocols.
475475
rawUrl: >-
476-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/ids-and-urls.yaml
477-
group: Tokens And Service Calls
476+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/ids-and-urls.yaml
477+
group: Tokens And Service Calls For Exchange On-Premises Environments
478478
api_set:
479479
Mailbox: '1.5'
480480
- id: outlook-tokens-and-service-calls-user-identity-token
481-
name: Get a user identity token
481+
name: Get a user identity token in Exchange on-premises environments
482482
fileName: user-identity-token.yaml
483483
description: >-
484-
Gets a user identity token to use for authentication flows in an Exchange
484+
Gets a user identity token for authentication flows in an Exchange
485485
on-premises environment.
486486
rawUrl: >-
487-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/user-identity-token.yaml
488-
group: Tokens And Service Calls
487+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-identity-token.yaml
488+
group: Tokens And Service Calls For Exchange On-Premises Environments
489489
api_set:
490490
Mailbox: '1.1'
491491
- id: outlook-tokens-and-service-calls-user-callback-token
492-
name: Get a callback token
492+
name: Get a callback token in Exchange on-premises environments
493493
fileName: user-callback-token.yaml
494494
description: >-
495495
Gets a callback token to call Outlook services from an add-in's backend
496-
service.
496+
service in an Exchange on-premises environment.
497497
rawUrl: >-
498-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/user-callback-token.yaml
499-
group: Tokens And Service Calls
498+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-callback-token.yaml
499+
group: Tokens And Service Calls For Exchange On-Premises Environments
500500
api_set:
501501
Mailbox: '1.1'
502502
- id: outlook-tokens-and-service-calls-make-ews-request-async
503-
name: Get a message using Exchange Web Services (EWS)
503+
name: >-
504+
Get a message using Exchange Web Services (EWS) in Exchange on-premises
505+
environments
504506
fileName: make-ews-request-async.yaml
505-
description: Gets a message using EWS without any back-end code.
507+
description: >-
508+
Uses EWS in an Exchange on-premises environment to get a message without any
509+
backend code.
506510
rawUrl: >-
507-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/make-ews-request-async.yaml
508-
group: Tokens And Service Calls
511+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/make-ews-request-async.yaml
512+
group: Tokens And Service Calls For Exchange On-Premises Environments
509513
api_set:
510514
Mailbox: '1.1'
511515
- id: outlook-tokens-and-service-calls-send-message-using-make-ews-request-async
512-
name: Send a message using Exchange Web Services (EWS)
516+
name: >-
517+
Send a message using Exchange Web Services (EWS) in Exchange on-premises
518+
environments
513519
fileName: send-message-using-make-ews-request-async.yaml
514-
description: Sends a message using EWS without any back-end code.
520+
description: >-
521+
Uses EWS in an Exchange on-premises environment to send a message without
522+
any backend code.
515523
rawUrl: >-
516-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/send-message-using-make-ews-request-async.yaml
517-
group: Tokens And Service Calls
524+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/send-message-using-make-ews-request-async.yaml
525+
group: Tokens And Service Calls For Exchange On-Premises Environments
518526
api_set:
519527
Mailbox: '1.1'
520528
- id: outlook-tokens-and-service-calls-get-icaluid-as-organizer
521-
name: Get an appointment's iCalUId as the organizer
529+
name: Get an appointment's iCalUId as the organizer (Exchange on-premises only)
522530
fileName: get-icaluid-as-organizer.yaml
523531
description: >-
524-
Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where
525-
the user is the organizer.
532+
Uses Exchange Web Services (EWS) in an Exchange on-premises environment to
533+
get an appointment's iCalUId value where the user is the organizer.
526534
rawUrl: >-
527-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/get-icaluid-as-organizer.yaml
528-
group: Tokens And Service Calls
535+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-organizer.yaml
536+
group: Tokens And Service Calls For Exchange On-Premises Environments
529537
api_set:
530538
Mailbox: '1.3'
531539
- id: outlook-tokens-and-service-calls-get-icaluid-as-attendee
532-
name: Get an appointment's iCalUId as an attendee
540+
name: Get an appointment's iCalUId as an attendee (Exchange on-premises only)
533541
fileName: get-icaluid-as-attendee.yaml
534542
description: >-
535-
Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where
536-
the user is an attendee.
543+
Uses Exchange Web Services (EWS) in an Exchange on-premises environment to
544+
get an appointment's iCalUId value where the user is an attendee.
537545
rawUrl: >-
538-
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls/get-icaluid-as-attendee.yaml
539-
group: Tokens And Service Calls
546+
https://raw.githubusercontent.com/OfficeDev/office-js-snippets/main/samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-attendee.yaml
547+
group: Tokens And Service Calls For Exchange On-Premises Environments
540548
api_set:
541549
Mailbox: '1.1'
542550
- id: outlook-other-item-apis-get-subject-read

samples/outlook/85-tokens-and-service-calls/get-icaluid-as-attendee.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-attendee.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 9
22
id: outlook-tokens-and-service-calls-get-icaluid-as-attendee
3-
name: Get an appointment's iCalUId as an attendee
4-
description: Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where the user is an attendee.
3+
name: Get an appointment's iCalUId as an attendee (Exchange on-premises only)
4+
description: Uses Exchange Web Services (EWS) in an Exchange on-premises environment to get an appointment's iCalUId value where the user is an attendee.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.1'

samples/outlook/85-tokens-and-service-calls/get-icaluid-as-organizer.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/get-icaluid-as-organizer.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 8
22
id: outlook-tokens-and-service-calls-get-icaluid-as-organizer
3-
name: Get an appointment's iCalUId as the organizer
4-
description: Uses Exchange Web Services (EWS) to get an appointment's iCalUId value where the user is the organizer.
3+
name: Get an appointment's iCalUId as the organizer (Exchange on-premises only)
4+
description: Uses Exchange Web Services (EWS) in an Exchange on-premises environment to get an appointment's iCalUId value where the user is the organizer.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.3'

samples/outlook/85-tokens-and-service-calls/ids-and-urls.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/ids-and-urls.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 1
22
id: outlook-tokens-and-service-calls-ids-and-urls
3-
name: Endpoint URLs and item IDs
4-
description: Retrieves and displays the Exchange Web Services (EWS) endpoint URL and item IDs, and converts item IDs for different protocols.
3+
name: Endpoint URLs and item IDs in Exchange on-premises environments
4+
description: Retrieves the Exchange Web Services (EWS) endpoint URL and item IDs and converts item IDs for different protocols.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.5'

samples/outlook/85-tokens-and-service-calls/make-ews-request-async.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/make-ews-request-async.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 6
22
id: outlook-tokens-and-service-calls-make-ews-request-async
3-
name: Get a message using Exchange Web Services (EWS)
4-
description: Gets a message using EWS without any back-end code.
3+
name: Get a message using Exchange Web Services (EWS) in Exchange on-premises environments
4+
description: Uses EWS in an Exchange on-premises environment to get a message without any backend code.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.1'
@@ -33,7 +33,7 @@ script:
3333
template:
3434
content: |-
3535
<section class="ms-Fabric ms-font-m">
36-
<p>This sample shows how to get a message using EWS, without any back-end code.</p>
36+
<p>This sample shows how to get a message using EWS, without any backend code.</p>
3737
<p><b>Important</b>: This API is only supported in Exchange on-premises environments.
3838
In Exchange Online environments, use <a href="https://learn.microsoft.com/office/dev/add-ins/develop/enable-nested-app-authentication-in-your-add-in" target="_blank">nested app authentication (NAA)</a>
3939
to get an access token. Then, use <a href="https://learn.microsoft.com/graph/use-the-api" target="_blank">Microsoft Graph</a> to get the message.

samples/outlook/85-tokens-and-service-calls/send-message-using-make-ews-request-async.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/send-message-using-make-ews-request-async.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 7
22
id: outlook-tokens-and-service-calls-send-message-using-make-ews-request-async
3-
name: Send a message using Exchange Web Services (EWS)
4-
description: Sends a message using EWS without any back-end code.
3+
name: Send a message using Exchange Web Services (EWS) in Exchange on-premises environments
4+
description: Uses EWS in an Exchange on-premises environment to send a message without any backend code.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.1'

samples/outlook/85-tokens-and-service-calls/user-callback-token.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-callback-token.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 4
22
id: outlook-tokens-and-service-calls-user-callback-token
3-
name: Get a callback token
4-
description: Gets a callback token to call Outlook services from an add-in's backend service.
3+
name: Get a callback token in Exchange on-premises environments
4+
description: Gets a callback token to call Outlook services from an add-in's backend service in an Exchange on-premises environment.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.1'

samples/outlook/85-tokens-and-service-calls/user-identity-token.yaml renamed to samples/outlook/85-tokens-and-service-calls-for-exchange-on-premises-environments/user-identity-token.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
order: 3
22
id: outlook-tokens-and-service-calls-user-identity-token
3-
name: Get a user identity token
4-
description: Gets a user identity token to use for authentication flows in an Exchange on-premises environment.
3+
name: Get a user identity token in Exchange on-premises environments
4+
description: Gets a user identity token for authentication flows in an Exchange on-premises environment.
55
host: OUTLOOK
66
api_set:
77
Mailbox: '1.1'

0 commit comments

Comments
 (0)