Azure SMS for Java
Send Azure Communication Services SMS from Java with per-recipient results and delivery tracking.
The documentation offers Entra ID, managed identity, connection-string, and access-key patterns, with credential configuration via environment variables. However, sending SMS and receiving Event Grid callbacks create external effects; there is no user-confirmation guidance, consent/opt-out/compliance boundary, or rollback strategy. The OTP example places a phone number in a tag, potentially widening sensitive-data exposure, so trust is far from full marks.
Single-recipient, bulk, async, delivery-report, error-handling, and rate-limit paths are covered, including per-recipient failures and request-level exceptions. However, examples omit some imports, configuration requirements are not fully consistent with connection-string usage, retry behavior is simplified, and idempotency or duplicate sends are not addressed. This is a static-only review with no skill-specific tests, so the score remains below the static ceiling.
Trigger phrases and intended Java scenarios for notifications, OTP, bulk SMS, and delivery reports are reasonably clear. Non-fit boundaries, pricing, regional/carrier constraints, compliance requirements, and formal input/output contracts are absent; Chinese-language handling, message segmentation, and mainland-China reachability are also undocumented. The core function depends on Azure Communication Services, with insufficient environment-fit evidence.
The skill has YAML metadata, an MIT license, a version, installation notes, layered examples, error handling, best practices, and a reference file. It lacks a skill-level changelog, explicit maintenance owner, update path, compatibility matrix, and a clear known-limitations section; dependency and version-update policy is also unclear, so points are deducted.
The material can directly guide common Java ACS SMS integrations, including sending, bulk, async, delivery reports, and OTP flows. But the examples were not executed in this review, some require added imports and configuration, and production-grade security and retry work remains. Under static calibration, the result is therefore capped conservatively.
The supplied files contain concrete Maven coordinates, API calls, failure branches, and complete examples, providing some auditability. There is no committed test suite or CI evidence specific to this skill path, and repository-wide harness material does not establish reproduction of this skill's key paths, so a higher static score is not justified.
- Establish user consent, opt-out, regional compliance, pricing, and carrier constraints before sending SMS, with application-level confirmation or approval where appropriate.
- Do not place phone numbers, OTPs, or other sensitive data in tags, logs, or error messages; prefer managed identity or short-lived credentials and protect connection strings and access keys.
- Verify the actual azure-communication-sms 1.2.0 API and add missing imports before adoption; implement recoverable handling for 429s, network failures, timeouts, and idempotent retries.
- Confirm Azure Communication Services, Event Grid, and SMS capability reachability and compliance in the target region, especially mainland China.
What it does & when to use it
This skill is for developers using the Azure Communication Services SMS Java SDK. It covers single-recipient and bulk messaging, synchronous and asynchronous clients, delivery reports, tags, and per-recipient error handling. Examples show DefaultAzureCredential, managed identity, connection strings, and AzureKeyCredential authentication. It fits Java applications that need notifications, OTPs, alerts, or batch SMS, but it does not provide a complete application or deployment solution.
Shows how to add the Maven dependency, create an SmsClient or SmsAsyncClient, call the Azure Communication Services SMS API for one or more E.164 phone numbers, and inspect message IDs, recipients, success flags, HTTP statuses, and error messages. It also covers enabling delivery reports, adding business tags, handling HTTP 429 responses, and receiving delivery status through Azure Event Grid.
- A Java application needs to deliver login verification codes or one-time passwords.
- An order system must send confirmation, status-change, or security-alert messages.
- A marketing or operations service needs to send one message to several recipients and inspect each result.
- A critical notification workflow needs Delivered or Failed status through Event Grid.
- A team wants DefaultAzureCredential locally and managed identity in production.
Pros & cons
- Covers synchronous, asynchronous, single-recipient, and bulk-send patterns.
- Includes per-recipient success, status-code, and error handling.
- Documents Event Grid delivery reports, business tags, and a 429 retry recommendation.
- Shows Entra ID, managed identity, connection-string, and AzureKeyCredential options.
- Targets the Java SDK and cannot be used directly for other languages.
- Does not include a complete application, deployment configuration, or runnable Event Grid webhook.
- The source does not provide independent test-coverage details for this individual skill.
- Sending requires a configured Azure Communication Services resource and sender number.
How to install
Install the repository's skill collection with npx skills add microsoft/skills, then select the needed skill in the wizard. The README also documents cloning the repository and copying a specific skill directory; it does not document a standalone installation command for this skill. Add the Maven dependency com.azure:azure-communication-sms:1.2.0 to the Java project.
How to use
Useful trigger phrases include “send SMS Java,” “SMS notification,” “OTP SMS,” “bulk SMS,” and “delivery report SMS.” Provide an ACS sender number, recipient number or list, and message text; enable delivery reports and set a tag when needed. The examples create a client with DefaultAzureCredential, a connection string, or AzureKeyCredential, then call send or sendWithResponse. Use SmsAsyncClient for reactive operations. In production, the DefaultAzureCredential example requires AZURE_TOKEN_CREDENTIALS=prod or a specific credential setting.