Azure / Azure/azure-rest-api-specs

Pageable LROs should be defined with `x-ms-pageable`

Open
#20,875 2 comments 0 reactions 0 assignees View on GitHub
Cognitive - Language Language Service Service Service Attention
Dominant language
TypeSpec
Stars
3.1k
Forks
5.9k
Avg merge
2d 22h
Merged PRs (30d)
444

Description

There's a few LROs that are meant to return pageable results once complete - the original URI - and should be defined as such per https://github.com/Azure/autorest/tree/main/docs/extensions#x-ms-pageable.

These include, but may not be limited to:

* QuestionAnsweringProjects_UpdateQnas
* QuestionAnsweringProjects_UpdateSources

For now in the SDK, we are using transforms but these changes should be in the swagger initially. For reference:
```yaml
- where-operation: QuestionAnsweringProjects_UpdateQnas
transform: |
$["x-ms-pageable"] = {
"nextLinkName": "nextLink",
"itemName": "value"
};

- where-operation: QuestionAnsweringProjects_UpdateSources
transform: |
$["x-ms-pageable"] = {
"nextLinkName": "nextLink",
"itemName": "value"
};
```

Contributor guide

Open the contributing guide

Research direction

Search the API specification files for QuestionAnsweringProjects_UpdateQnas and QuestionAnsweringProjects_UpdateSources, then read their response schemas and existing SDK transforms. Confirm how the swagger definitions represent the original URI's pageable response and add the x-ms-pageable metadata with nextLink and value where appropriate. Done means both operations are defined correctly in the swagger rather than relying only on transforms.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.