Skip to content

Commit b43886f

Browse files
author
Pavlo Datsiuk
committed
Merge branch 'main' into planner/pavlodatsiuk/taskchat-api
2 parents c971c86 + b88f440 commit b43886f

1,164 files changed

Lines changed: 11618 additions & 2132 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/prompts/author-api-docs/common.md

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -45,17 +45,7 @@ Gather both values in a **single upfront step** to minimize round-trips with the
4545

4646
### temp-docstubs Folder
4747

48-
Before beginning any documentation process, instruct the author to add all required files to the `temp-docstubs` folder in this workspace:
49-
50-
**For Scenario 1 (Fresh APIs / beta changes):**
51-
- Autogenerated doc stubs (*.md files)
52-
- API.md file describing the capabilities being added/changed
53-
- Autogenerated changelog file (changelog_*.json)
54-
55-
**For Scenario 2 (Promotion from beta to v1.0):**
56-
- Documentation Plan documenting what is being promoted
57-
- **Optional:** Autogenerated doc stubs (*.md files for v1.0)
58-
- Autogenerated changelog file (changelog_*.json)
48+
Before beginning any documentation process, instruct the author to add all required files to the `temp-docstubs` folder in this workspace. The specific files needed depend on the scenario — see the **Inputs** section of the relevant scenario file for details.
5949

6050
**Important notes about temp-docstubs:**
6151
- This folder is temporary storage for input files needed during authoring
@@ -259,7 +249,7 @@ After updating What's new, update the appropriate TOC mapping file to make new d
259249

260250
**For new files:** Include only HTTP request examples using `msgraph-interactive` (for URLs without an ID placeholder, e.g., `https://graph.microsoft.com/v1.0/users`) or `http` language identifier. No tabs or SDK includes.
261251

262-
**For existing files:** Follow the established pattern. If the file has no SDK snippets, add only HTTP examples. Do not introduce SDK snippets to files lacking them.
252+
**For existing files:** Follow the established pattern. If the file has no SDK snippets, add only HTTP examples. Do not introduce SDK snippets to files or examples lacking them.
263253

264254
**Example HTTP-only format:**
265255

@@ -399,11 +389,12 @@ Fully qualify any type (including enum types) that is defined in a subnamespace
399389
- Remove beta disclaimer when promoting to v1.0
400390

401391
**National cloud include statement:**
402-
- API method files in beta include an autogenerated national cloud support statement immediately before the `## Permissions` header. Example include statement for all clouds support:
392+
- API method files in beta include an autogenerated national cloud support statement immediately before the `## Permissions` header. Example:
403393
```
404394
[!INCLUDE [national-cloud-support](../../includes/all-clouds.md)]
405395
```
406-
- Remove this include statement when promoting to v1.0
396+
- **Do not add** this statement when authoring new API method files — it is added automatically by a downstream process
397+
- **Delete** this statement from files copied from beta when promoting to v1.0
407398

408399
## Documentation Standards
409400

.github/prompts/author-api-docs/deprecate-retire.md

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,106 @@ When combining deprecation with new APIs/promotions:
206206

207207
---
208208

209+
## Retirement (API removal)
210+
211+
Retirement is the final stage of the API lifecycle — the deprecated API has reached its sunset date and is removed from the service. Documentation files for retired APIs must be **deleted** from the repository, with redirects added to guide users to alternatives.
212+
213+
**Retirement vs. deprecation:** Deprecation marks an API as "going away in the future" — it adds notices with sunset dates and alternatives. Retirement removes the API entirely — files are deleted, not just annotated.
214+
215+
### Inputs for retirement
216+
217+
The Documentation Plan must explicitly identify:
218+
- Which resources (entity types, complex types) are being retired (marked as "Deleted" or "Removed")
219+
- Which API operation files are linked to the retired resources
220+
- **Dependency analysis for related types:** Complex types referenced as property return types and entity types referenced as relationship targets must be explicitly called out. The Documentation Plan must state whether each related type is also being retired or should be retained.
221+
222+
### Retirement workflow
223+
224+
#### Step 1: Delete retired files
225+
226+
Based on the Documentation Plan, delete:
227+
228+
1. **Resource files** for entity types and complex types explicitly marked as retired/deleted:
229+
- `api-reference/{version}/resources/{namespace}-{resourcename}.md`
230+
231+
2. **API operation files** linked to the retired resource:
232+
- List files (GET collection): `{resource}-list-{entityType}.md`
233+
- Get files (GET single): `{entityType}-get.md`
234+
- Create files (POST): `{resource}-post-{entityType}.md`
235+
- PUT files: `{resource}-put-{entityType}.md`
236+
- Update files (PATCH): `{entityType}-update.md`
237+
- Upsert files (PATCH): `{entityType}-upsert.md`
238+
- Delete files (DELETE): `{entityType}-delete.md`
239+
- Action files: `{entityType}-{actionName}.md`
240+
- Function files: `{entityType}-{functionName}.md`
241+
242+
3. **Permission include files** for the retired API operation files:
243+
- `api-reference/{version}/includes/permissions/{operation}-permissions.md` (naming may vary — match the include reference in each API operation file)
244+
245+
4. **Complex type files** explicitly called out as retired/deleted in the Documentation Plan:
246+
- Only delete if the Documentation Plan explicitly marks the complex type as retired/deleted
247+
- If not explicitly called out as retired, retain the file
248+
249+
5. **Enum files or sections** explicitly called out as retired/deleted in the Documentation Plan:
250+
- For standalone enum files: delete if explicitly marked as retired
251+
- For H3 sections in parent resources: removed when parent resource is deleted
252+
- For entries in global enums files (`enums.md`, `enums-{subnamespace}.md`): remove the enum section
253+
- If not explicitly called out as retired, retain the file
254+
255+
#### Step 2: Clean up references
256+
257+
1. **Parent resource references:**
258+
- Remove the retired resource from Methods tables, Relationships tables, and Properties tables of any parent or related resources that reference it
259+
260+
2. **TOC updates:**
261+
- Remove entries for deleted files from `toc.mapping.json`
262+
- Remove entries from concept `toc.yml` if applicable
263+
264+
3. **Concept topics:**
265+
- Remove or update references to the retired API in overview and concept documentation
266+
- If a concept topic is entirely about the retired feature, delete it
267+
268+
#### Step 3: Add redirects
269+
270+
Add redirects for **resource files that include Methods tables** (entity types) and **API operation files**. Complex types, enums, and permission include files do not need redirects.
271+
272+
**Redirect file location:** The repo uses multiple redirect files in the `redirects/` folder at the root, following the pattern `.openpublishing.redirection.yyyy-mm.json`. Use the **latest** redirection file.
273+
274+
**Redirect file format:**
275+
```json
276+
{
277+
"redirections": [
278+
{
279+
"source_path": "api-reference/{version}/resources/{retired-resource}.md",
280+
"redirect_url": "/graph/api/resources/{alternative-resource}",
281+
"redirect_document_id": false
282+
},
283+
{
284+
"source_path": "api-reference/{version}/api/{retired-operation}.md",
285+
"redirect_url": "/graph/api/{alternative-operation}",
286+
"redirect_document_id": false
287+
}
288+
]
289+
}
290+
```
291+
292+
**Field definitions:**
293+
- `source_path` — file path to the deleted file in the repo (relative to repo root)
294+
- `redirect_url` — relative URL to the alternative article on learn.microsoft.com (not a file path)
295+
- `redirect_document_id` — always `false`
296+
297+
**Steps:**
298+
1. Identify the latest `.openpublishing.redirection.yyyy-mm.json` file in the `redirects/` folder
299+
2. Add redirect entries for each deleted resource file (entity types with Methods tables) and each deleted API operation file
300+
3. Set `redirect_url` to the alternative resource or operation specified in the Documentation Plan or the deprecation notice
301+
302+
#### Step 4: Add changelog and What's New
303+
304+
1. **Changelog:** Add entries with Change type "Deletion". See [Updating the Changelog](common.md#updating-the-changelog).
305+
2. **What's New:** Note the API retirement, link to the alternative API, and reference the original deprecation blog post. See [Updating What's New](common.md#updating-whats-new).
306+
307+
---
308+
209309
## Version-specific notes
210310

211311
- **Beta:** Banner after namespace, before beta disclaimer; keep beta disclaimer; use `?view=graph-rest-beta&preserve-view=true`
@@ -261,3 +361,16 @@ In addition to the [base quality checklist](common.md#base-quality-checklist), v
261361

262362
**Final — Scenario 3 specific:**
263363
- [ ] All deprecation items from Documentation Plan addressed
364+
- [ ] All retirement items from Documentation Plan addressed
365+
366+
**Retirement-specific (if applicable):**
367+
- [ ] All resource files explicitly marked as retired/deleted are deleted
368+
- [ ] All API operation files linked to retired resources are deleted
369+
- [ ] All permission include files for retired operations are deleted
370+
- [ ] Complex types and enums only deleted if explicitly called out as retired in the Documentation Plan
371+
- [ ] References to retired resources removed from parent/related resource tables (Methods, Relationships, Properties)
372+
- [ ] TOC entries removed for deleted files
373+
- [ ] Concept topics updated or deleted as appropriate
374+
- [ ] Redirects added in latest `.openpublishing.redirection.yyyy-mm.json` for deleted resource files (with Methods tables) and API operation files
375+
- [ ] Changelog entries added with Change type "Deletion"
376+
- [ ] What's New updated with retirement notice and link to alternative

0 commit comments

Comments
 (0)