Skip to content

Commit 79fa9be

Browse files
authored
Merge branch 'main' into users/sitaolu/cloudPcDeviceImage_getSourceImages_doc_update
2 parents 0a12f7f + 929adde commit 79fa9be

4,520 files changed

Lines changed: 55523 additions & 12833 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/copilot-instructions.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
You are a content reviewer for Microsoft Graph REST API reference documentation. Use these guidelines to review pull requests (PRs) against the Microsoft Graph documentation standards outlined in the Microsoft Graph Content Development Kit (CDK).
44

5+
## Additional Documentation Resources
6+
7+
For comprehensive authoring and review guidance, reference these files located in the `.github/prompts/` folder:
8+
9+
- **[author-api-docs.prompt.md](.github/prompts/author-api-docs.prompt.md)**: Complete authoring guidelines for creating and updating Microsoft Graph API reference documentation, including workflows for fresh APIs, promotions, and deprecations.
10+
- **[review-api-docs.prompt.md](.github/prompts/review-api-docs.prompt.md)**: Detailed review process guidelines that combine authoring best practices with the content standards outlined below.
11+
12+
These files provide in-depth guidance on:
13+
- Documentation authoring workflows and scenarios
14+
- Content structure and organization requirements
15+
- Quality standards and validation processes
16+
- Common patterns and best practices specific to Microsoft Graph API documentation
17+
518
## File Type Classifications
619

720
This repository contains several types of files with different review requirements:

.github/prompts/author-api-docs.prompt.md

Lines changed: 1846 additions & 0 deletions
Large diffs are not rendered by default.

.github/prompts/review-api-docs.prompt.md

Lines changed: 381 additions & 0 deletions
Large diffs are not rendered by default.

.github/workflows/cloud-support.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
#cSpell:ignore microsoftgraph msgraph hidi CSDL Mooncake
12
name: Update cloud support status
23

34
on:
@@ -31,7 +32,7 @@ jobs:
3132
- name: Setup .NET
3233
uses: actions/setup-dotnet@v4
3334
with:
34-
dotnet-version: 9.x
35+
dotnet-version: 10.x
3536
- name: Build cloud support tool
3637
working-directory: ./tool
3738
run: dotnet build --configuration Release
@@ -67,7 +68,7 @@ jobs:
6768
hidi transform --cs transformed_beta-Mooncake.csdl -o ../openapi/beta/Mooncake.yml --co -f Yaml --sp $Env:SETTINGS
6869
- name: Run cloud support tool
6970
env:
70-
TOOL: ./tool/src/bin/Release/net9.0/CheckCloudSupport
71+
TOOL: ./tool/src/bin/Release/net10.0/CheckCloudSupport
7172
run: |
7273
$TOOL --open-api ./openapi/v1.0 --api-docs ./docs/api-reference/v1.0/api --overrides ./docs/api-reference/cloud.api.overrides.json --excludes ./docs/api-reference/cloud.exclusions.json --remove-old-includes
7374
$TOOL --open-api ./openapi/beta --api-docs ./docs/api-reference/beta/api --overrides ./docs/api-reference/cloud.api.overrides.json --excludes ./docs/api-reference/cloud.exclusions.json --remove-old-includes

.github/workflows/generate-ref-toc.yml

Lines changed: 39 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# cSpell:ignore microsoftgraph msgraph bangbang
12
name: Generate reference TOC
23

34
on:
@@ -42,15 +43,23 @@ jobs:
4243
- name: Setup .NET
4344
uses: actions/setup-dotnet@v4
4445
with:
45-
dotnet-version: 8.x
46+
dotnet-version: 10.x
4647
- name: Build TOC generation tool
4748
working-directory: ./tool
4849
run: dotnet build --configuration Release
49-
- name: Run cloud support tool
50+
- name: Generate v1 TOC
51+
id: v1_gen
52+
continue-on-error: true
5053
env:
51-
TOOL: ./tool/src/bin/Release/net8.0/GenerateTOC
54+
TOOL: ./tool/src/bin/Release/net10.0/GenerateTOC
5255
run: |
5356
$TOOL --api-docs ./docs/api-reference/v1.0/api --resource-docs ./docs/api-reference/v1.0/resources --mapping ./docs/api-reference/v1.0/toc/toc.mapping.json --terms-override ./docs/api-reference/toc.terms.overrides.json --toc ./docs/api-reference/v1.0/toc.yml --static-toc ./docs/api-reference/v1.0/toc/static-toc.yml
57+
- name: Generate beta TOC
58+
id: beta_gen
59+
continue-on-error: true
60+
env:
61+
TOOL: ./tool/src/bin/Release/net10.0/GenerateTOC
62+
run: |
5463
$TOOL --api-docs ./docs/api-reference/beta/api --resource-docs ./docs/api-reference/beta/resources --mapping ./docs/api-reference/beta/toc/toc.mapping.json --terms-override ./docs/api-reference/toc.terms.overrides.json --toc ./docs/api-reference/beta/toc.yml --static-toc ./docs/api-reference/beta/toc/static-toc.yml
5564
- name: Get token
5665
id: get_token
@@ -67,26 +76,35 @@ jobs:
6776
env:
6877
GH_TOKEN: ${{ steps.get_token.outputs.app-token }}
6978
PULL_REQUEST: ${{ inputs.pull_request }}
79+
V1_OUTCOME: ${{ steps.v1_gen.outcome }}
80+
BETA_OUTCOME: ${{ steps.beta_gen.outcome }}
7081
run: |
71-
$status = git status --porcelain
72-
if ($status -eq $null) {
73-
echo "result=TOC generation resulted in no changes" >> $env:GITHUB_OUTPUT
74-
Write-Host "No changes to commit." -ForegroundColor Green
82+
$v1Failed = $env:V1_OUTCOME -eq "failure"
83+
$betaFailed = $env:BETA_OUTCOME -eq "failure"
84+
if ($v1Failed -or $betaFailed) {
85+
echo "result=':bangbang: TOC generation failed - please check logs :bangbang:'" >> $env:GITHUB_OUTPUT
86+
exit 1
7587
} else {
76-
git config user.email "GraphTooling@service.microsoft.com"
77-
git config user.name "Microsoft Graph DevX Tooling"
78-
if ($Env:PULL_REQUEST -eq $true) {
79-
$timestamp = Get-Date -Format FileDateTimeUniversal
80-
git checkout -b ref-toc-generation/$timestamp
81-
git add .
82-
git commit -m "Update reference TOC"
83-
git push --set-upstream origin ref-toc-generation/$timestamp
84-
gh pr create --base main --title "Update reference TOC" --body "Ran TOC generation tool" --label "ready to merge"
85-
echo "result=TOC generation changes submitted via PR" >> $env:GITHUB_OUTPUT
88+
$status = git status --porcelain
89+
if ($status -eq $null) {
90+
echo "result=TOC generation resulted in no changes" >> $env:GITHUB_OUTPUT
91+
Write-Host "No changes to commit." -ForegroundColor Green
8692
} else {
87-
git add .
88-
git commit -m "Update reference TOC"
89-
git push
90-
echo "result=TOC generation changes committed successfully" >> $env:GITHUB_OUTPUT
93+
git config user.email "GraphTooling@service.microsoft.com"
94+
git config user.name "Microsoft Graph DevX Tooling"
95+
if ($Env:PULL_REQUEST -eq $true) {
96+
$timestamp = Get-Date -Format FileDateTimeUniversal
97+
git checkout -b ref-toc-generation/$timestamp
98+
git add .
99+
git commit -m "Update reference TOC"
100+
git push --set-upstream origin ref-toc-generation/$timestamp
101+
gh pr create --base main --title "Update reference TOC" --body "Ran TOC generation tool" --label "ready to merge"
102+
echo "result=TOC generation changes submitted via PR" >> $env:GITHUB_OUTPUT
103+
} else {
104+
git add .
105+
git commit -m "Update reference TOC"
106+
git push
107+
echo "result=TOC generation changes committed successfully" >> $env:GITHUB_OUTPUT
108+
}
91109
}
92110
}

.github/workflows/request-ref-toc-gen.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# cSpell:ignore microsoftgraph
12
name: On-demand reference TOC generation
23

34
on:
@@ -51,6 +52,7 @@ jobs:
5152
update-pull-request:
5253
name: Update pull request
5354
runs-on: ubuntu-latest
55+
if: ${{ always() }}
5456
needs: request-toc-gen
5557
steps:
5658
- uses: octokit/request-action@v2.x

api-reference/beta/api/accesspackageassignmentrequest-cancel.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,5 +114,5 @@ The following example shows the response.
114114
} -->
115115

116116
```http
117-
HTTP/1.1 200 Status OK
117+
HTTP/1.1 200 OK
118118
```

api-reference/beta/api/accesspackageassignmentrequest-resume.md

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,65 @@ Content-Type: application/json
232232

233233
---
234234

235+
### Response
236+
237+
The following example shows the response.
238+
<!-- {
239+
"blockType": "response",
240+
"truncated": true
241+
}
242+
-->
243+
``` http
244+
HTTP/1.1 204 No Content
245+
```
246+
247+
### Example 4: Resume an access package assignment request from a custom extension
248+
249+
#### Request
250+
251+
The following example shows a request of a call to resume an access package assignment request that's waiting for a callback from a custom extension to determine the approver of the access package assignment.
252+
253+
<!-- {
254+
"blockType": "request",
255+
"name": "accesspackageassignmentrequestthis.resume.customextension"
256+
}
257+
-->
258+
``` http
259+
POST https://graph.microsoft.com/beta/identityGovernance/entitlementManagement/accessPackageAssignmentRequests/0e60f18c-b2a0-4887-9da8-da2e30a39d99/resume
260+
Content-Type: application/json
261+
262+
{
263+
"source": "Contoso.CustoEXT",
264+
"type": "microsoft.graph.accessPackageCustomExtensionStage.assignmentRequestCreated",
265+
"data": {
266+
"@odata.type": "microsoft.graph.microsoft.graph.assignmentRequestApprovalStageCallbackData",
267+
"approvalStage": {
268+
"durationBeforeAutomaticDenial": "P2D",
269+
"escalationApprovers": [],
270+
"fallbackEscalationApprovers": [],
271+
"fallbackPrimaryApprovers": [],
272+
"isApproverJustificationRequired": false,
273+
"isEscalationEnabled": false,
274+
"primaryApprovers": [
275+
{
276+
"@@odata.type": "#microsoft.graph.singleUser",
277+
"description": "Primary approver of access package assignment.",
278+
"id": "",
279+
"isBackup": false
280+
}
281+
]
282+
},
283+
"customExtensionStageInstanceDetail": "A approval stage from Logic Apps",
284+
"customExtensionStageInstanceId": "@{triggerBody()?['CustomExtensionStageInstanceId']}",
285+
"stage": "assignmentRequestDeterminingApprovalRequirements"
286+
},
287+
"source": "LogicApps",
288+
"type": "microsoft.graph.accessPackageCustomExtensionStage.assignmentRequestCreated"
289+
}
290+
291+
```
292+
293+
235294
### Response
236295

237296
The following example shows the response.

api-reference/beta/api/accesspackagecatalog-post-accesspackagecustomworkflowextensions.md

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,3 +267,77 @@ Content-Type: application/json
267267
}
268268
```
269269

270+
### Example 3: Create a custom extension for use with an approval stage callback
271+
272+
The following is an example of a access package assignment request custom workflow extension.
273+
274+
#### Request
275+
276+
<!-- {
277+
"blockType": "request",
278+
"name": "create_accessPackageAssignmentRequestWorkflowExtension_direct_approval"
279+
}
280+
-->
281+
282+
``` http
283+
POST https://graph.microsoft.com/beta/identityGovernance/entitlementManagement/accessPackageCatalogs/a9286c9c-7659-4b2e-ba44-4d1f2ce07746/accessPackagecustomWorkflowExtensions
284+
Content-Type: application/json
285+
286+
{
287+
"@odata.type": "#microsoft.graph.accessPackageAssignmentRequestWorkflowExtension",
288+
"displayName": "test_action_0124_email",
289+
"description": "this is for graph testing only",
290+
"endpointConfiguration": {
291+
"@odata.type": "#microsoft.graph.logicAppTriggerEndpointConfiguration",
292+
"subscriptionId": "38ab2ccc-3747-4567-b36b-9478f5602f0d",
293+
"resourceGroupName": "test",
294+
"logicAppWorkflowName": "elm-extension-email"
295+
},
296+
"authenticationConfiguration": {
297+
"@odata.type": "#microsoft.graph.azureAdPopTokenAuthentication"
298+
},
299+
"callbackConfiguration": {
300+
"@odata.type": "microsoft.graph.accessPackageRequestApprovalStageCallbackConfiguration",
301+
"durationBeforeTimeout": "PT1H"
302+
}
303+
}
304+
```
305+
306+
#### Response
307+
>**Note:** The response object shown here might be shortened for readability.
308+
<!-- {
309+
"blockType": "response",
310+
"truncated": true,
311+
"@odata.type": "microsoft.graph.customCalloutExtension"
312+
}
313+
-->
314+
``` http
315+
HTTP/1.1 201 Created
316+
Content-Type: application/json
317+
318+
{
319+
"value":{
320+
"@odata.type":"#microsoft.graph.accessPackageAssignmentRequestWorkflowExtension",
321+
"id":"5afcb385-d500-450c-bbf6-3b74a44403da",
322+
"displayName":"test_action_0124_email",
323+
"description":"this is for graph testing only",
324+
"createdDateTime":"2022-01-24T21:48:57.15Z",
325+
"lastModifiedDateTime":"2022-01-24T21:55:44.953Z",
326+
"clientConfiguration":null,
327+
"endpointConfiguration":{
328+
"@odata.type":"#microsoft.graph.logicAppTriggerEndpointConfiguration",
329+
"subscriptionId":"e8eb46ab-626d-451f-8668-9434e73cf43b",
330+
"resourceGroupName":"test",
331+
"logicAppWorkflowName":"elm-extension-email",
332+
"url":"https://prod-31.eastus.logic.azure.com:443/workflows/8ccffea766ae48e680gd9a22d1549bbc/triggers/manual/paths/invoke?api-version=2016-10-01"
333+
},
334+
"authenticationConfiguration":{
335+
"@odata.type":"#microsoft.graph.azureAdPopTokenAuthentication"
336+
},
337+
"callbackConfiguration":{
338+
"@odata.type":"microsoft.graph.accessPackageRequestApprovalStageCallbackConfiguration",
339+
"durationBeforeTimeout":"PT1H"
340+
}
341+
}
342+
}
343+
```

0 commit comments

Comments
 (0)