diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/client.tsp b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/client.tsp similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/client.tsp rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/client.tsp diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_CreateOrUpdateWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_CreateOrUpdateWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_CreateOrUpdateWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_CreateOrUpdateWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_DeleteWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_DeleteWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_DeleteWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_DeleteWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetOperationStatusSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetOperationStatusSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetOperationStatusSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetOperationStatusSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_GetWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_ListWidgetsSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_ListWidgetsSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_ListWidgetsSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-11-01-preview/Widgets_ListWidgetsSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_CreateOrUpdateWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_CreateOrUpdateWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_CreateOrUpdateWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_CreateOrUpdateWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_DeleteWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_DeleteWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_DeleteWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_DeleteWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetOperationStatusSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetOperationStatusSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetOperationStatusSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetOperationStatusSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_GetWidgetSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_ListWidgetsSample.json b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_ListWidgetsSample.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager/examples/2022-12-01/Widgets_ListWidgetsSample.json rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/examples/2022-12-01/Widgets_ListWidgetsSample.json diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/main.tsp b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/main.tsp similarity index 97% rename from specification/contosowidgetmanager/Contoso.WidgetManager/main.tsp rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/main.tsp index 3caf321e31e4..e1c5e078f148 100644 --- a/specification/contosowidgetmanager/Contoso.WidgetManager/main.tsp +++ b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/main.tsp @@ -2,7 +2,7 @@ import "@typespec/http"; import "@typespec/rest"; import "@typespec/versioning"; import "@azure-tools/typespec-azure-core"; -import "../Contoso.WidgetManager.Shared"; +import "./shared.tsp"; using TypeSpec.Http; using TypeSpec.Rest; diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager.Shared/main.tsp b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/shared.tsp similarity index 100% rename from specification/contosowidgetmanager/Contoso.WidgetManager.Shared/main.tsp rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/shared.tsp diff --git a/specification/contosowidgetmanager/Contoso.WidgetManager/tspconfig.yaml b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/tspconfig.yaml similarity index 97% rename from specification/contosowidgetmanager/Contoso.WidgetManager/tspconfig.yaml rename to specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/tspconfig.yaml index 9a29a6fc3971..b2a488dcb2b2 100644 --- a/specification/contosowidgetmanager/Contoso.WidgetManager/tspconfig.yaml +++ b/specification/contosowidgetmanager/data-plane/Azure.Contoso.WidgetManager/tspconfig.yaml @@ -12,7 +12,7 @@ options: "@azure-tools/typespec-autorest": azure-resource-provider-folder: "data-plane" emit-lro-options: "none" - emitter-output-dir: "{project-root}/.." + emitter-output-dir: "{project-root}/../.." output-file: "{azure-resource-provider-folder}/{service-name}/{version-status}/{version}/widgets.json" "@azure-tools/typespec-python": package-dir: "azure-contoso-widgetmanager" diff --git a/specification/contosowidgetmanager/Contoso.Management/employee.tsp b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/employee.tsp similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/employee.tsp rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/employee.tsp diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_CreateOrUpdate.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_CreateOrUpdate.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_CreateOrUpdate.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_CreateOrUpdate.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Delete.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Delete.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Delete.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Delete.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Get.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Get.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Get.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Get.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_ListByResourceGroup.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_ListByResourceGroup.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_ListByResourceGroup.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_ListByResourceGroup.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_ListBySubscription.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_ListBySubscription.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_ListBySubscription.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_ListBySubscription.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Update.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Update.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Employees_Update.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Employees_Update.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Operations_List.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Operations_List.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-10-01-preview/Operations_List.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-10-01-preview/Operations_List.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_CreateOrUpdate.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_CreateOrUpdate.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_CreateOrUpdate.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_CreateOrUpdate.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Delete.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Delete.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Delete.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Delete.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Get.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Get.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Get.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Get.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_ListByResourceGroup.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_ListByResourceGroup.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_ListByResourceGroup.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_ListByResourceGroup.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_ListBySubscription.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_ListBySubscription.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_ListBySubscription.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_ListBySubscription.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Update.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Update.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Employees_Update.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Employees_Update.json diff --git a/specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Operations_List.json b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Operations_List.json similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/examples/2021-11-01/Operations_List.json rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/examples/2021-11-01/Operations_List.json diff --git a/specification/contosowidgetmanager/Contoso.Management/main.tsp b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/main.tsp similarity index 100% rename from specification/contosowidgetmanager/Contoso.Management/main.tsp rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/main.tsp diff --git a/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/shared.tsp b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/shared.tsp new file mode 100644 index 000000000000..1b94bb705031 --- /dev/null +++ b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/shared.tsp @@ -0,0 +1,8 @@ +@doc("Faked shared model") +model FakedSharedModel { + @doc("The tag.") + tag: string; + + @doc("The created date.") + createdAt: utcDateTime; +} diff --git a/specification/contosowidgetmanager/Contoso.Management/tspconfig.yaml b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/tspconfig.yaml similarity index 92% rename from specification/contosowidgetmanager/Contoso.Management/tspconfig.yaml rename to specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/tspconfig.yaml index c3dae4d70301..f20debf41298 100644 --- a/specification/contosowidgetmanager/Contoso.Management/tspconfig.yaml +++ b/specification/contosowidgetmanager/resource-manager/Microsoft.Contoso/tspconfig.yaml @@ -6,9 +6,10 @@ emit: options: "@azure-tools/typespec-autorest": use-read-only-status-schema: true - emitter-output-dir: "{project-root}/.." + emitter-output-dir: "{project-root}/../.." azure-resource-provider-folder: "resource-manager" output-file: "{azure-resource-provider-folder}/{service-name}/{version-status}/{version}/contoso.json" + arm-types-dir: "{project-root}/../../../common-types/resource-management" "@azure-tools/typespec-csharp": flavor: azure package-dir: "Azure.ResourceManager.Contoso"