From 9b6e252f53499866298424552cee5023283f1f95 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Fri, 1 Mar 2024 03:14:39 +0200 Subject: [PATCH] Azure `Page` type `nextLink` properties should be `readOnly: true` (#231) This PR fixes https://github.com/Azure/typespec-azure-pr/issues/3924 by marking `nextLink` properties with `@visibility("read")` so that the OpenAPI output for these properties contains `readOnly: true`. --------- Co-authored-by: Timothee Guerin --- .../next-link-read-only-2024-1-28-21-59-17.md | 8 ++++ .../typespec-autorest/2022-08-31/openapi.json | 6 ++- .../openapi3/openapi.2022-08-31.yaml | 2 + .../typespec-autorest/2022-08-31/openapi.json | 3 +- .../openapi3/openapi.2022-08-31.yaml | 1 + .../typespec-autorest/openapi.json | 6 ++- .../@typespec/openapi3/openapi.yaml | 2 + .../typespec-autorest/openapi.json | 12 ++++-- .../authoring/@typespec/openapi3/openapi.yaml | 4 ++ .../typespec-autorest/openapi.json | 12 ++++-- .../Raw/@typespec/openapi3/openapi.yaml | 4 ++ .../typespec-autorest/2022-08-31/openapi.json | 6 ++- .../typespec-autorest/2023-02-07/openapi.json | 6 ++- .../openapi3/openapi.2022-08-31.yaml | 2 + .../openapi3/openapi.2023-02-07.yaml | 2 + .../typespec-autorest/2022-08-31/openapi.json | 9 ++-- .../openapi3/openapi.2022-08-31.yaml | 3 ++ .../typespec-autorest/openapi.json | 18 +++++--- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 6 ++- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 3 +- .../2021-10-01-preview/openapi.json | 3 +- .../typespec-autorest/openapi.json | 6 ++- .../typespec-autorest/openapi.json | 3 +- .../typespec-autorest/openapi.json | 3 +- .../typespec-autorest/openapi.json | 3 +- .../typespec-autorest/openapi.json | 3 +- .../2021-06-13-preview/openapi.json | 15 ++++--- .../2022-04-30-preview/openapi.json | 15 ++++--- .../typespec-autorest/openapi.json | 6 ++- .../typespec-autorest/openapi.json | 6 ++- .../typespec-autorest/openapi.json | 3 +- .../typespec-autorest/openapi.json | 6 ++- .../typespec-autorest/openapi.json | 18 +++++--- .../typespec-autorest/openapi.json | 42 ++++++++++++------- .../2023-08-01-preview/openapi.json | 9 ++-- .../2023-11-01-preview/openapi.json | 9 ++-- .../typespec-autorest/openapi.json | 3 +- .../typespec-autorest/openapi.json | 9 ++-- .../typespec-autorest/openapi.json | 15 ++++--- .../typespec-azure-core/lib/foundations.tsp | 1 + packages/typespec-azure-core/lib/models.tsp | 1 + 46 files changed, 216 insertions(+), 93 deletions(-) create mode 100644 .chronus/changes/next-link-read-only-2024-1-28-21-59-17.md diff --git a/.chronus/changes/next-link-read-only-2024-1-28-21-59-17.md b/.chronus/changes/next-link-read-only-2024-1-28-21-59-17.md new file mode 100644 index 0000000000..fcaa0d26c7 --- /dev/null +++ b/.chronus/changes/next-link-read-only-2024-1-28-21-59-17.md @@ -0,0 +1,8 @@ +--- +# Change versionKind to one of: internal, fix, dependencies, feature, deprecation, breaking +changeKind: fix +packages: + - "@azure-tools/typespec-azure-core" +--- + +Azure `Page` type `nextLink` properties are now marked as `readonly` diff --git a/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@azure-tools/typespec-autorest/2022-08-31/openapi.json b/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@azure-tools/typespec-autorest/2022-08-31/openapi.json index 837ba96f12..5d1caeae47 100644 --- a/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@azure-tools/typespec-autorest/2022-08-31/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@azure-tools/typespec-autorest/2022-08-31/openapi.json @@ -1110,7 +1110,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1132,7 +1133,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@typespec/openapi3/openapi.2022-08-31.yaml b/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@typespec/openapi3/openapi.2022-08-31.yaml index ecef77debb..38bbd1046a 100644 --- a/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@typespec/openapi3/openapi.2022-08-31.yaml +++ b/packages/samples/test/output/azure/core/data-plane/api-path-parameter/@typespec/openapi3/openapi.2022-08-31.yaml @@ -836,6 +836,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Manufacturer items PagedWidget: type: object @@ -851,6 +852,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Widget items RepeatabilityResult: type: string diff --git a/packages/samples/test/output/azure/core/data-plane/custom-error-type/@azure-tools/typespec-autorest/2022-08-31/openapi.json b/packages/samples/test/output/azure/core/data-plane/custom-error-type/@azure-tools/typespec-autorest/2022-08-31/openapi.json index cc9e15912e..9bc882df32 100644 --- a/packages/samples/test/output/azure/core/data-plane/custom-error-type/@azure-tools/typespec-autorest/2022-08-31/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/custom-error-type/@azure-tools/typespec-autorest/2022-08-31/openapi.json @@ -558,7 +558,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/custom-error-type/@typespec/openapi3/openapi.2022-08-31.yaml b/packages/samples/test/output/azure/core/data-plane/custom-error-type/@typespec/openapi3/openapi.2022-08-31.yaml index 42f0686242..ca981503e5 100644 --- a/packages/samples/test/output/azure/core/data-plane/custom-error-type/@typespec/openapi3/openapi.2022-08-31.yaml +++ b/packages/samples/test/output/azure/core/data-plane/custom-error-type/@typespec/openapi3/openapi.2022-08-31.yaml @@ -448,6 +448,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Widget items RepeatabilityResult: type: string diff --git a/packages/samples/test/output/azure/core/data-plane/formrecognizer/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/core/data-plane/formrecognizer/@azure-tools/typespec-autorest/openapi.json index 2088ebcced..ee79956bdf 100644 --- a/packages/samples/test/output/azure/core/data-plane/formrecognizer/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/formrecognizer/@azure-tools/typespec-autorest/openapi.json @@ -2037,7 +2037,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2059,7 +2060,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/formrecognizer/@typespec/openapi3/openapi.yaml b/packages/samples/test/output/azure/core/data-plane/formrecognizer/@typespec/openapi3/openapi.yaml index 80d6112a29..8a30a621b8 100644 --- a/packages/samples/test/output/azure/core/data-plane/formrecognizer/@typespec/openapi3/openapi.yaml +++ b/packages/samples/test/output/azure/core/data-plane/formrecognizer/@typespec/openapi3/openapi.yaml @@ -1400,6 +1400,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of ModelSummary items PagedOperationInfo: type: object @@ -1415,6 +1416,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of OperationInfo items SelectionMarkState: type: string diff --git a/packages/samples/test/output/azure/core/data-plane/language/authoring/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/core/data-plane/language/authoring/@azure-tools/typespec-autorest/openapi.json index 4c490c1944..beed4d0e21 100644 --- a/packages/samples/test/output/azure/core/data-plane/language/authoring/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/language/authoring/@azure-tools/typespec-autorest/openapi.json @@ -1191,7 +1191,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1213,7 +1214,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1235,7 +1237,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1257,7 +1260,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/language/authoring/@typespec/openapi3/openapi.yaml b/packages/samples/test/output/azure/core/data-plane/language/authoring/@typespec/openapi3/openapi.yaml index fa32117dd4..9ab9f941b8 100644 --- a/packages/samples/test/output/azure/core/data-plane/language/authoring/@typespec/openapi3/openapi.yaml +++ b/packages/samples/test/output/azure/core/data-plane/language/authoring/@typespec/openapi3/openapi.yaml @@ -901,6 +901,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Deployment items PagedProject: type: object @@ -916,6 +917,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Project items PagedSupportedLanguage: type: object @@ -931,6 +933,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: A collection of SupportedLanguage resources. PagedTrainingConfigVersion: type: object @@ -946,6 +949,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: A collection of TrainingConfigVersion resources. Project: type: object diff --git a/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@azure-tools/typespec-autorest/openapi.json index 5dc82e5641..be8c6361cc 100644 --- a/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@azure-tools/typespec-autorest/openapi.json @@ -1479,7 +1479,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1501,7 +1502,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1523,7 +1525,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1545,7 +1548,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@typespec/openapi3/openapi.yaml b/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@typespec/openapi3/openapi.yaml index b7f6ba8016..7586dc243b 100644 --- a/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@typespec/openapi3/openapi.yaml +++ b/packages/samples/test/output/azure/core/data-plane/languageqna/Raw/@typespec/openapi3/openapi.yaml @@ -1115,6 +1115,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of ProjectDeployment items PagedProjectMetadata: type: object @@ -1130,6 +1131,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of ProjectMetadata items PagedQnaSourceRecord: type: object @@ -1145,6 +1147,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of QnaSourceRecord items PagedSynonymAsset: type: object @@ -1160,6 +1163,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of SynonymAsset items ProjectDeployment: type: object diff --git a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2022-08-31/openapi.json b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2022-08-31/openapi.json index 598bae4b0e..ae8877d224 100644 --- a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2022-08-31/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2022-08-31/openapi.json @@ -1014,7 +1014,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1036,7 +1037,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2023-02-07/openapi.json b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2023-02-07/openapi.json index be1e609371..5996ef3418 100644 --- a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2023-02-07/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@azure-tools/typespec-autorest/2023-02-07/openapi.json @@ -1110,7 +1110,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1132,7 +1133,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2022-08-31.yaml b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2022-08-31.yaml index 624d5f4a46..688b6e0ded 100644 --- a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2022-08-31.yaml +++ b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2022-08-31.yaml @@ -753,6 +753,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Manufacturer items PagedWidget: type: object @@ -768,6 +769,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Widget items RepeatabilityResult: type: string diff --git a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2023-02-07.yaml b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2023-02-07.yaml index 4e58c53855..26d533be6d 100644 --- a/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2023-02-07.yaml +++ b/packages/samples/test/output/azure/core/data-plane/trait-versioning/@typespec/openapi3/openapi.2023-02-07.yaml @@ -837,6 +837,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Manufacturer items PagedWidget: type: object @@ -852,6 +853,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Widget items RepeatabilityResult: type: string diff --git a/packages/samples/test/output/azure/core/data-plane/widget-manager/@azure-tools/typespec-autorest/2022-08-31/openapi.json b/packages/samples/test/output/azure/core/data-plane/widget-manager/@azure-tools/typespec-autorest/2022-08-31/openapi.json index 2c2d8fbfc7..4133a06cce 100644 --- a/packages/samples/test/output/azure/core/data-plane/widget-manager/@azure-tools/typespec-autorest/2022-08-31/openapi.json +++ b/packages/samples/test/output/azure/core/data-plane/widget-manager/@azure-tools/typespec-autorest/2022-08-31/openapi.json @@ -2021,7 +2021,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2043,7 +2044,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2065,7 +2067,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/core/data-plane/widget-manager/@typespec/openapi3/openapi.2022-08-31.yaml b/packages/samples/test/output/azure/core/data-plane/widget-manager/@typespec/openapi3/openapi.2022-08-31.yaml index a3c96d87b1..fc93bd852d 100644 --- a/packages/samples/test/output/azure/core/data-plane/widget-manager/@typespec/openapi3/openapi.2022-08-31.yaml +++ b/packages/samples/test/output/azure/core/data-plane/widget-manager/@typespec/openapi3/openapi.2022-08-31.yaml @@ -1481,6 +1481,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Manufacturer items PagedWidget: type: object @@ -1496,6 +1497,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of Widget items PagedWidgetPart: type: object @@ -1511,6 +1513,7 @@ components: type: string format: uri description: The link to the next page of items + readOnly: true description: Paged collection of WidgetPart items RepeatabilityResult: type: string diff --git a/packages/samples/test/output/azure/resource-manager/arm-library/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-library/@azure-tools/typespec-autorest/openapi.json index 4f1825de5a..81c1efd718 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-library/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-library/@azure-tools/typespec-autorest/openapi.json @@ -1672,7 +1672,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2001,7 +2002,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2047,7 +2049,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2093,7 +2096,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2114,7 +2118,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2167,7 +2172,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/extension-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/extension-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index 7c2cf50c25..23b55308a9 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/extension-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/extension-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -388,7 +388,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/location-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/location-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index b344a0c4b6..a2e10b5a0b 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/location-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/location-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -417,7 +417,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/nobody-action/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/nobody-action/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index d600cfc3f5..3c3358d723 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/nobody-action/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/nobody-action/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -571,7 +571,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/proxy/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/proxy/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index 324ccbdddd..0d14930e7d 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/proxy/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/proxy/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -710,7 +710,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -795,7 +796,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/singleton/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/singleton/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index c261cb59d3..172f541ad6 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/singleton/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/singleton/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -327,7 +327,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/tenant/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/tenant/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index 653eb4bd3d..e1264eccb2 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/tenant/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/tenant/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -363,7 +363,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/tracked/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/tracked/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index 930e96b5e3..7865de4196 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/tracked/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/tracked/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -433,7 +433,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/arm-scenarios/virtual-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/arm-scenarios/virtual-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json index 9a1871fb78..a228bce784 100644 --- a/packages/samples/test/output/azure/resource-manager/arm-scenarios/virtual-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/arm-scenarios/virtual-resource/@azure-tools/typespec-autorest/2021-10-01-preview/openapi.json @@ -509,7 +509,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/codesigning/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/codesigning/@azure-tools/typespec-autorest/openapi.json index d3c9484ca8..102b4e3c7a 100644 --- a/packages/samples/test/output/azure/resource-manager/codesigning/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/codesigning/@azure-tools/typespec-autorest/openapi.json @@ -591,7 +591,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -735,7 +736,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/contoso/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/contoso/@azure-tools/typespec-autorest/openapi.json index cc67b48cd2..27de199ae0 100644 --- a/packages/samples/test/output/azure/resource-manager/contoso/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/contoso/@azure-tools/typespec-autorest/openapi.json @@ -400,7 +400,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/csharpattributetest/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/csharpattributetest/@azure-tools/typespec-autorest/openapi.json index 449fbadd7d..2c34bfd5de 100644 --- a/packages/samples/test/output/azure/resource-manager/csharpattributetest/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/csharpattributetest/@azure-tools/typespec-autorest/openapi.json @@ -420,7 +420,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/customer-managed-keys/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/customer-managed-keys/@azure-tools/typespec-autorest/openapi.json index cf7328388c..9e5ae5d596 100644 --- a/packages/samples/test/output/azure/resource-manager/customer-managed-keys/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/customer-managed-keys/@azure-tools/typespec-autorest/openapi.json @@ -396,7 +396,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/discriminatortest/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/discriminatortest/@azure-tools/typespec-autorest/openapi.json index 13a66ded64..eaf0dfc79b 100644 --- a/packages/samples/test/output/azure/resource-manager/discriminatortest/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/discriminatortest/@azure-tools/typespec-autorest/openapi.json @@ -497,7 +497,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2021-06-13-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2021-06-13-preview/openapi.json index 9f6b980f55..0fab89d28e 100644 --- a/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2021-06-13-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2021-06-13-preview/openapi.json @@ -1279,7 +1279,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1486,7 +1487,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1572,7 +1574,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1928,7 +1931,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2065,7 +2069,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2022-04-30-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2022-04-30-preview/openapi.json index ab3c327262..045e37a5fd 100644 --- a/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2022-04-30-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/dynatrace/@azure-tools/typespec-autorest/2022-04-30-preview/openapi.json @@ -1286,7 +1286,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1493,7 +1494,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1587,7 +1589,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1943,7 +1946,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2080,7 +2084,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/envelopetest/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/envelopetest/@azure-tools/typespec-autorest/openapi.json index 40d361007b..8d6e901aa2 100644 --- a/packages/samples/test/output/azure/resource-manager/envelopetest/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/envelopetest/@azure-tools/typespec-autorest/openapi.json @@ -728,7 +728,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -871,7 +872,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/liftr.confluent/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/liftr.confluent/@azure-tools/typespec-autorest/openapi.json index 61c583009f..b579736674 100644 --- a/packages/samples/test/output/azure/resource-manager/liftr.confluent/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/liftr.confluent/@azure-tools/typespec-autorest/openapi.json @@ -503,7 +503,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -704,7 +705,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/liftr.frs/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/liftr.frs/@azure-tools/typespec-autorest/openapi.json index 42827cb568..f6fd413f2d 100644 --- a/packages/samples/test/output/azure/resource-manager/liftr.frs/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/liftr.frs/@azure-tools/typespec-autorest/openapi.json @@ -524,7 +524,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/liftr.playfab/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/liftr.playfab/@azure-tools/typespec-autorest/openapi.json index 8e0c412b3f..7b349dcbf3 100644 --- a/packages/samples/test/output/azure/resource-manager/liftr.playfab/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/liftr.playfab/@azure-tools/typespec-autorest/openapi.json @@ -711,7 +711,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -828,7 +829,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/logz/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/logz/@azure-tools/typespec-autorest/openapi.json index 0f93123ed3..2f26f124e5 100644 --- a/packages/samples/test/output/azure/resource-manager/logz/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/logz/@azure-tools/typespec-autorest/openapi.json @@ -1557,7 +1557,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1815,7 +1816,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2011,7 +2013,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2133,7 +2136,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2174,7 +2178,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -2252,7 +2257,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/operationsTest/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/operationsTest/@azure-tools/typespec-autorest/openapi.json index 3469ad7e90..c1a2d56f96 100644 --- a/packages/samples/test/output/azure/resource-manager/operationsTest/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/operationsTest/@azure-tools/typespec-autorest/openapi.json @@ -3837,7 +3837,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -3990,7 +3991,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4203,7 +4205,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4248,7 +4251,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4345,7 +4349,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4391,7 +4396,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4477,7 +4483,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4519,7 +4526,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4614,7 +4622,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4656,7 +4665,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4742,7 +4752,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4787,7 +4798,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4886,7 +4898,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -4939,7 +4952,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-08-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-08-01-preview/openapi.json index d93b327f3d..53f16522b6 100644 --- a/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-08-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-08-01-preview/openapi.json @@ -663,7 +663,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -704,7 +705,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -773,7 +775,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-11-01-preview/openapi.json b/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-11-01-preview/openapi.json index f8efe176a1..7fc97b75af 100644 --- a/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-11-01-preview/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/private-links/@azure-tools/typespec-autorest/2023-11-01-preview/openapi.json @@ -663,7 +663,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -704,7 +705,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -773,7 +775,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/servicelinker/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/servicelinker/@azure-tools/typespec-autorest/openapi.json index 2505886309..2895a14e1d 100644 --- a/packages/samples/test/output/azure/resource-manager/servicelinker/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/servicelinker/@azure-tools/typespec-autorest/openapi.json @@ -534,7 +534,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/tagsUpdateTest/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/tagsUpdateTest/@azure-tools/typespec-autorest/openapi.json index 20d81d8da9..680e423b6e 100644 --- a/packages/samples/test/output/azure/resource-manager/tagsUpdateTest/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/tagsUpdateTest/@azure-tools/typespec-autorest/openapi.json @@ -1256,7 +1256,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1308,7 +1309,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1362,7 +1364,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/samples/test/output/azure/resource-manager/tenantResource/@azure-tools/typespec-autorest/openapi.json b/packages/samples/test/output/azure/resource-manager/tenantResource/@azure-tools/typespec-autorest/openapi.json index 8e4fb8ebc5..30cae02e5b 100644 --- a/packages/samples/test/output/azure/resource-manager/tenantResource/@azure-tools/typespec-autorest/openapi.json +++ b/packages/samples/test/output/azure/resource-manager/tenantResource/@azure-tools/typespec-autorest/openapi.json @@ -1458,7 +1458,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1560,7 +1561,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1625,7 +1627,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1750,7 +1753,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ @@ -1838,7 +1842,8 @@ "nextLink": { "type": "string", "format": "uri", - "description": "The link to the next page of items" + "description": "The link to the next page of items", + "readOnly": true } }, "required": [ diff --git a/packages/typespec-azure-core/lib/foundations.tsp b/packages/typespec-azure-core/lib/foundations.tsp index fe123e1acd..573f2b2ecd 100644 --- a/packages/typespec-azure-core/lib/foundations.tsp +++ b/packages/typespec-azure-core/lib/foundations.tsp @@ -251,6 +251,7 @@ model CustomPage< @doc("The link to the next page of items") @nextLink + @visibility("read") nextLink?: ResourceLocation; // Include custom response fields diff --git a/packages/typespec-azure-core/lib/models.tsp b/packages/typespec-azure-core/lib/models.tsp index 7a1179971e..a1bc1eadb3 100644 --- a/packages/typespec-azure-core/lib/models.tsp +++ b/packages/typespec-azure-core/lib/models.tsp @@ -21,6 +21,7 @@ model Page { @doc("The link to the next page of items") @nextLink + @visibility("read") nextLink?: ResourceLocation; }