Skip to content

Commit 35a2fc6

Browse files
authored
Horizontal TypeSpec conversion for ACS Identity 2025-06-30 (#44061)
* Horizontal TypeSpec conversion for ACS Identity 2025-06-30 * Remove old hand-written example files replaced by TypeSpec-generated ones * Address review feedback: remove x-ms-parameter-location extension, use url type for endpoint * Address review feedback: remove @operationid, remove manual api-version, remove OpenAPI import, rename examples to match new operationIds * Add SDK emitter configs, remove suppressions.yaml * Fix example timestamps to use UTC instead of local timezone * Use Azure.Core.Foundations.Operation template for all operations * Use Record<unknown> for TeamsExtensionExchangeTokenRequest per review feedback * Remove unused tspconfig parameters per review feedback * Shorten namespace to Azure.Communication.Identity per review feedback * Add IdentityOperation template with default error to reduce inline repetition --------- Co-authored-by: JohnRFraser <18373891+JohnRFraser@users.noreply.github.com>
1 parent a5f3402 commit 35a2fc6

23 files changed

Lines changed: 1076 additions & 358 deletions

specification/communication/data-plane/Identity/stable/2025-06-30/examples/CreateIdentity.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/IdentityOperations_Create.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Create an Identity and optionally an access token",
3+
"operationId": "IdentityOperations_Create",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/RevokeAccessTokens.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/IdentityOperations_Delete.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Delete an identity",
3+
"operationId": "IdentityOperations_Delete",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/IssueAccessToken.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/IdentityOperations_IssueAccessToken.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Issue an access token",
3+
"operationId": "IdentityOperations_IssueAccessToken",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"title": "Revoke access tokens",
3+
"operationId": "IdentityOperations_RevokeAccessTokens",
4+
"parameters": {
5+
"api-version": "2025-06-30",
6+
"content-type": "application/json",
7+
"id": "8:acs:2dee53b4-368b-45b4-ab52-8493fb117652_00000005-14a2-493b-8a72-5a3a0d000081",
8+
"endpoint": "https://my-resource.communication.azure.com"
9+
},
10+
"responses": {
11+
"204": {}
12+
}
13+
}

specification/communication/data-plane/Identity/stable/2025-06-30/examples/DeleteTeamsExtensionAssignment.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/TeamsExtensionOperations_DeleteAssignment.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Delete Assignment",
3+
"operationId": "TeamsExtensionOperations_DeleteAssignment",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"tenantId": "c70d068c-2f32-484d-9455-73070cd5aadd",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/ExchangeTeamsPhoneToken.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/TeamsExtensionOperations_ExchangeToken.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Exchange a Teams Phone token",
3+
"operationId": "TeamsExtensionOperations_ExchangeToken",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/GetTeamsExtensionAssignment.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/TeamsExtensionOperations_GetAssignment.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Get Assignment",
3+
"operationId": "TeamsExtensionOperations_GetAssignment",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"objectId": "b27b64b9-39d2-44a3-869d-67700b74e805",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/CreateOrReplaceTeamsExtensionAssignment.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/TeamsExtensionOperations_UpsertAssignment.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Create or Update Assignment",
3+
"operationId": "TeamsExtensionOperations_UpsertAssignment",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",

specification/communication/data-plane/Identity/stable/2025-06-30/examples/ExchangeTeamsUserAccessToken.json renamed to specification/communication/data-plane/Identity/examples/2025-06-30/TeamsUserOperations_ExchangeTeamsUserAccessToken.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2+
"title": "Exchange a Teams user access token",
3+
"operationId": "TeamsUserOperations_ExchangeTeamsUserAccessToken",
24
"parameters": {
35
"api-version": "2025-06-30",
46
"content-type": "application/json",
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
import "@typespec/rest";
2+
import "@typespec/http";
3+
import "@typespec/versioning";
4+
import "@azure-tools/typespec-azure-core";
5+
import "./models.tsp";
6+
import "./routes.tsp";
7+
8+
using TypeSpec.Http;
9+
using TypeSpec.Versioning;
10+
using Azure.Core;
11+
12+
#suppress "@azure-tools/typespec-azure-core/auth-required" "Auth defined in securityDefinitions only without global security array, matching original swagger to preserve SDK constructor signature"
13+
@service(#{ title: "CommunicationIdentityClient" })
14+
@server(
15+
"{endpoint}",
16+
"Azure Communication Identity Service",
17+
{
18+
@doc("The communication resource, for example https://my-resource.communication.azure.com")
19+
endpoint: url,
20+
}
21+
)
22+
@versioned(Versions)
23+
@doc("Azure Communication Identity Service")
24+
namespace Azure.Communication.Identity;

0 commit comments

Comments
 (0)