Validate A2P 10DLC campaigns from Claude Code
Wire A2PCheck into Claude Code (or Codex) so it pre-checks an A2P 10DLC campaign draft before you register it through a provider — catching the rejection risks while the agent can still fix them.
Guidance only — A2PCheck is independent and not affiliated with Twilio, The Campaign Registry, or any carrier, and we can't guarantee approval.
Add the skill
Download the public skill without cloning a private repository. For Claude Code, set SKILL_DIR="$HOME/.claude/skills/a2pcheck"before the command; the default is a generic/Codex-style folder. The command refuses to overwrite an existing installation:
set -eu
skill_dir="${SKILL_DIR:-$HOME/.agents/skills/a2pcheck}"
if [ -e "$skill_dir" ]; then
printf '%s\n' "Choose an empty SKILL_DIR; the destination already exists." >&2
exit 1
fi
mkdir -p "$(dirname "$skill_dir")"
mkdir "$skill_dir"
mkdir "$skill_dir/references"
for file in SKILL.md references/campaign-schema.md references/example-campaign.json references/remediation-workflow.md; do
curl --fail --max-time 30 -sS -L "https://www.a2pcheck.com/skill/$file" -o "$skill_dir/$file"
done
printf '%s\n' "Downloaded to $skill_dir. Review the files before enabling the skill."Review the downloaded skill before enabling it. Its references include the campaign schema, complete example JSON and bounded remediation instructions. No registry listing is claimed.
Or call it directly
No skill is required for the HTTP endpoint. Anonymous Basic is free within usage limits and does not fetch website/policy pages. This is a complete fictional request, not an approved campaign. For Full, a human verifies their account, creates an API key, and approves the two-credit cost. Use the guarded Full example in the agent overview; Full without a key returns 401 rather than downgrading.
curl --fail-with-body --max-time 75 -sS -X POST https://www.a2pcheck.com/api/agent/validate \
-H "Content-Type: application/json" \
-d '{
"tier": "basic",
"campaign": {
"useCaseType": "MARKETING",
"businessName": "Acme Coffee Co.",
"campaignDescription": "Acme Coffee Co. sends weekly promotional offers and new-product announcements to customers who opt in at checkout or on our website. Messages link to acme.example.com and always include opt-out instructions.",
"sampleMessages": [
"Acme Coffee: 20% off all beans this week. Shop acme.example.com/sale. Msg&data rates may apply. Reply STOP to opt out, HELP for help.",
"Acme Coffee: New single-origin just dropped. Browse acme.example.com/new. Reply STOP to unsubscribe."
],
"messageFlow": "Customers opt in by checking an unchecked SMS-consent box at checkout on acme.example.com or by texting START to our number. Consent is not a condition of purchase.",
"privacyPolicyUrl": "https://acme.example.com/privacy",
"websiteUrl": "https://acme.example.com",
"termsOfServiceUrl": "https://acme.example.com/terms",
"optInKeywords": [
"START"
],
"optOutKeywords": [
"STOP"
],
"helpKeywords": [
"HELP"
],
"optInMessage": "Acme Coffee: You'"'"'re subscribed to weekly offers. Reply STOP to opt out, HELP for help. Msg&data rates may apply.",
"optOutMessage": "Acme Coffee: You'"'"'re unsubscribed and won'"'"'t receive more messages. Reply START to rejoin.",
"helpMessage": "Acme Coffee: For help, email [email protected]. Reply STOP to opt out.",
"embeddedLinks": true,
"embeddedPhoneNumbers": false
}
}'Keep the workflow bounded
- Build the campaign JSON; strip PII and secrets.
- POST it to
/api/agent/validate. - Read
result.overallTier,result.criticalIssuesandresult.fieldResults. - Review proposed edits against real facts. Default to one paid request; get explicit approval for tier, credits and total budget before any authenticated call, and renewed approval for another scan.
- Use an
idempotencyKeyper exact campaign version/tier. Do not enable automatic paid retries or change keys to bypass a pending request. - Stop with unresolved findings or missing facts. The human still controls registration through their provider; GREEN is not an approval guarantee.
A2PCheck is independent, does not submit campaigns, and can't guarantee approval. Field reference: /llms-full.txt.