Azure Communication Common for Java
Guides Java developers through shared ACS authentication, token refresh, and communication identifier handling.
The documentation explicitly advises against logging full tokens, recommends graceful refresh-failure handling, and mostly uses placeholders; however, the token-service example sends userId in a GET query string and does not define least privilege, user confirmation, data-flow boundaries, endpoint security, dependency security, or recovery, so points are deducted.
The main credential, identifier, and refresh patterns are broadly consistent and include retry and failure-handling guidance; however, examples rely on undefined methods, include a blocking async pattern, and provide no skill-specific tests or compatibility validation. Static evidence is limited, so the score is conservative.
Trigger phrases, Java targeting, and ACS authentication scenarios are clear; boundaries for non-fit use cases, input/output contracts, API-version constraints, and abnormal inputs are under-specified. Chinese support and mainland-China network reachability are not addressed, so points are deducted.
The skill has front matter, MIT licensing, a version, installation guidance, layered examples, references, and best practices; it lacks a changelog, explicit maintenance owner/update path, FAQ, compatibility matrix, and complete dependency notes, so points are deducted.
Coverage includes static tokens, refresh, Entra ID, identifier parsing, caching, and disposal, providing useful starting material for common ACS Java tasks; several examples depend on unstated services or methods and contain security or completeness risks. No execution was performed, so the score remains below the static ceiling.
The skill and reference examples are auditable, and the repository includes general CI and harness tests; there are no skill-specific committed tests, real execution results, or independent third-party corroboration. The assessment therefore relies mainly on static documentation and is scored conservatively.
- Do not log full tokens or transmit them through insecure query parameters; obtain and refresh tokens through a secured server-side flow.
- Verify the actual APIs and version compatibility of azure-communication-common, azure-identity, and related ACS clients before adoption.
- Add diagnosable handling and tests for refresh failures, invalid identifiers, endpoint misconfiguration, and multi-tenant isolation.
- The core workflow depends on Azure service endpoints, while mainland-China reachability, regional restrictions, and alternatives are undocumented.
What it does & when to use it
This skill is for Java developers using Azure Communication Services shared utilities. It covers static user tokens, proactive and asynchronous token refresh, and Entra ID authentication. It also explains how to create, parse, inspect, and use ACS user, phone number, Teams, and unknown identifiers. Adopt it when an agent needs focused guidance for authentication foundations used by ACS Chat, Calling, or related clients; it is not a complete guide to those service APIs.
Shows how to add the Maven package, construct CommunicationTokenCredential, configure static or proactively refreshed tokens, set up Entra ID credentials and scopes, and connect credentials to an ACS client. It provides Java examples for creating and parsing communication identifiers, checking their concrete types, reading token expiry, accessing tokens synchronously or asynchronously, closing credentials, selecting cloud environments, and applying token-security practices.
- A Java developer is building an ACS Chat or Calling client and needs to attach a user access token as a credential.
- A team is running a long-lived ACS client that must refresh tokens before expiration through a callback.
- An application must distinguish ACS users, PSTN phone numbers, Teams users, and unknown communication identifiers.
- A Java developer is configuring Entra ID authentication for Teams Phone Extensibility with a resource endpoint and scopes.
Pros & cons
- Covers the main shared ACS authentication and identifier types for Java.
- Includes static tokens, proactive refresh, asynchronous access, and Entra ID examples.
- Includes concrete guidance on token security, credential disposal, and identifier specificity.
- It focuses on shared authentication and identifiers rather than complete Chat, Calling, or SMS APIs.
- Application-specific pieces such as the token service, client objects, and `fetchNewTokenFromServer()` must be implemented separately.
- The supplied material provides no independent test results or platform-specific validation for this individual skill.
How to install
Run npx skills add microsoft/skills and select this skill in the wizard. Alternatively, clone the repository and copy .github/plugins/azure-sdk-java/skills/azure-communication-common-java/ into the selected agent's skill directory; the README does not specify the final per-agent path for this individual skill. The documented Maven dependency is com.azure:azure-communication-common:1.4.0.
How to use
Use a prompt such as: Configure CommunicationTokenCredential for a Java Azure Communication Services Chat client with proactive token refresh. The agent can then follow the skill's examples for credentials, refresh callbacks, identifier parsing, token access, and cleanup.