Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Look up phone number information (carrier, type, caller name) and verify users via SMS/voice OTP. Use for phone verification and data enrichment. This skill provides Java SDK examples.
.claude/skills/team-telnyx-telnyx-verify-java/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 50% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 84% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 148% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 200% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 107% | 0% |
<!-- Auto-generated from Telnyx OpenAPI specs. Do not edit. -->
text<!-- Maven --> <dependency> <groupId>com.telnyx.sdk</groupId> <artifactId>telnyx</artifactId> <version>6.89.0</version> </dependency> // Gradle implementation("com.telnyx.sdk:telnyx:6.89.0")
javaimport com.telnyx.sdk.client.TelnyxClient; import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient; TelnyxClient client = TelnyxOkHttpClient.fromEnv();
All examples below assume client is already initialized as shown above.
All API calls can fail with network errors, rate limits (429), validation errors (422), or authentication errors (401). Always handle errors in production code:
javaimport com.telnyx.sdk.errors.TelnyxServiceException; try { var result = client.messages().send(params); } catch (TelnyxServiceException e) { System.err.println("API error " + e.statusCode() + ": " + e.getMessage()); if (e.statusCode() == 422) { System.err.println("Validation error — check required fields and formats"); } else if (e.statusCode() == 429) { // Rate limited — wait and retry with exponential backoff Thread.sleep(1000); } }
Common error codes: 401 invalid API key, 403 insufficient permissions, 404 resource not found, 422 validation error (check field formats), 429 rate limited (retry with exponential backoff).
+13125550001). Include the + prefix and country code. No spaces, dashes, or parentheses..autoPager() for automatic iteration: for (var item : page.autoPager()) { ... }. For manual control, use .hasNextPage() and .nextPage().Returns information about the provided phone number.
GET /number_lookup/{phone_number}
javaimport com.telnyx.sdk.models.numberlookup.NumberLookupRetrieveParams; import com.telnyx.sdk.models.numberlookup.NumberLookupRetrieveResponse; NumberLookupRetrieveResponse numberLookup = client.numberLookup().retrieve("+18665552368");
Returns: caller_name (object), carrier (object), country_code (string), fraud (string | null), national_format (string), phone_number (string), portability (object), record_type (string)
GET /verifications/by_phone_number/{phone_number}
javaimport com.telnyx.sdk.models.verifications.byphonenumber.ByPhoneNumberListParams; import com.telnyx.sdk.models.verifications.byphonenumber.ByPhoneNumberListResponse; ByPhoneNumberListResponse byPhoneNumbers = client.verifications().byPhoneNumber().list("+13035551234");
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
POST /verifications/by_phone_number/{phone_number}/actions/verify — Required: code, verify_profile_id
javaimport com.telnyx.sdk.models.verifications.byphonenumber.actions.ActionVerifyParams; import com.telnyx.sdk.models.verifications.byphonenumber.actions.VerifyVerificationCodeResponse; ActionVerifyParams params = ActionVerifyParams.builder() .phoneNumber("+13035551234") .code("17686") .verifyProfileId("12ade33a-21c0-473b-b055-b3c836e1c292") .build(); VerifyVerificationCodeResponse verifyVerificationCodeResponse = client.verifications().byPhoneNumber().actions().verify(params);
Returns: phone_number (string), response_code (enum: accepted, rejected)
POST /verifications/call — Required: phone_number, verify_profile_id
Optional: custom_code (string | null), extension (string | null), timeout_secs (integer)
javaimport com.telnyx.sdk.models.verifications.CreateVerificationResponse; import com.telnyx.sdk.models.verifications.VerificationTriggerCallParams; VerificationTriggerCallParams params = VerificationTriggerCallParams.builder() .phoneNumber("+13035551234") .verifyProfileId("12ade33a-21c0-473b-b055-b3c836e1c292") .build(); CreateVerificationResponse createVerificationResponse = client.verifications().triggerCall(params);
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
POST /verifications/flashcall — Required: phone_number, verify_profile_id
Optional: timeout_secs (integer)
javaimport com.telnyx.sdk.models.verifications.CreateVerificationResponse; import com.telnyx.sdk.models.verifications.VerificationTriggerFlashcallParams; VerificationTriggerFlashcallParams params = VerificationTriggerFlashcallParams.builder() .phoneNumber("+13035551234") .verifyProfileId("12ade33a-21c0-473b-b055-b3c836e1c292") .build(); CreateVerificationResponse createVerificationResponse = client.verifications().triggerFlashcall(params);
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
POST /verifications/sms — Required: phone_number, verify_profile_id
Optional: custom_code (string | null), timeout_secs (integer)
javaimport com.telnyx.sdk.models.verifications.CreateVerificationResponse; import com.telnyx.sdk.models.verifications.VerificationTriggerSmsParams; VerificationTriggerSmsParams params = VerificationTriggerSmsParams.builder() .phoneNumber("+13035551234") .verifyProfileId("12ade33a-21c0-473b-b055-b3c836e1c292") .build(); CreateVerificationResponse createVerificationResponse = client.verifications().triggerSms(params);
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
POST /verifications/whatsapp — Required: phone_number, verify_profile_id
Optional: custom_code (string | null), timeout_secs (integer)
javaimport com.telnyx.sdk.models.verifications.CreateVerificationResponse; import com.telnyx.sdk.models.verifications.VerificationTriggerWhatsappVerificationParams; VerificationTriggerWhatsappVerificationParams params = VerificationTriggerWhatsappVerificationParams.builder() .phoneNumber("+13035551234") .verifyProfileId("12ade33a-21c0-473b-b055-b3c836e1c292") .build(); CreateVerificationResponse createVerificationResponse = client.verifications().triggerWhatsappVerification(params);
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
GET /verifications/{verification_id}
javaimport com.telnyx.sdk.models.verifications.VerificationRetrieveParams; import com.telnyx.sdk.models.verifications.VerificationRetrieveResponse; VerificationRetrieveResponse verification = client.verifications().retrieve("12ade33a-21c0-473b-b055-b3c836e1c292");
Returns: created_at (string), custom_code (string | null), id (uuid), phone_number (string), record_type (enum: verification), status (enum: pending, accepted, invalid, expired, error), timeout_secs (integer), type (enum: sms, call, flashcall, whatsapp), updated_at (string), verify_profile_id (uuid)
POST /verifications/{verification_id}/actions/verify
Optional: code (string), status (enum: accepted, rejected)
javaimport com.telnyx.sdk.models.verifications.actions.ActionVerifyParams; import com.telnyx.sdk.models.verifications.byphonenumber.actions.VerifyVerificationCodeResponse; VerifyVerificationCodeResponse verifyVerificationCodeResponse = client.verifications().actions().verify("12ade33a-21c0-473b-b055-b3c836e1c292");
Returns: phone_number (string), response_code (enum: accepted, rejected)
Gets a paginated list of Verify profiles.
GET /verify_profiles
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileListPage; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileListParams; VerifyProfileListPage page = client.verifyProfiles().list();
Returns: call (object), created_at (string), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), id (uuid), language (string), name (string), record_type (enum: verification_profile), sms (object), updated_at (string), webhook_failover_url (string), webhook_url (string), whatsapp (object)
Creates a new Verify profile to associate verifications with.
POST /verify_profiles — Required: name
Optional: call (object), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), language (string), sms (object), webhook_failover_url (string), webhook_url (string), whatsapp (object)
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileCreateParams; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileData; VerifyProfileCreateParams params = VerifyProfileCreateParams.builder() .name("Test Profile") .build(); VerifyProfileData verifyProfileData = client.verifyProfiles().create(params);
Returns: call (object), created_at (string), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), id (uuid), language (string), name (string), record_type (enum: verification_profile), sms (object), updated_at (string), webhook_failover_url (string), webhook_url (string), whatsapp (object)
List all Verify profile message templates.
GET /verify_profiles/templates
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileRetrieveTemplatesParams; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileRetrieveTemplatesResponse; VerifyProfileRetrieveTemplatesResponse response = client.verifyProfiles().retrieveTemplates();
Returns: id (uuid), text (string)
Create a new Verify profile message template.
POST /verify_profiles/templates — Required: text
javaimport com.telnyx.sdk.models.verifyprofiles.MessageTemplate; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileCreateTemplateParams; VerifyProfileCreateTemplateParams params = VerifyProfileCreateTemplateParams.builder() .text("Your {{app_name}} verification code is: {{code}}.") .build(); MessageTemplate messageTemplate = client.verifyProfiles().createTemplate(params);
Returns: id (uuid), text (string)
Update an existing Verify profile message template.
PATCH /verify_profiles/templates/{template_id} — Required: text
javaimport com.telnyx.sdk.models.verifyprofiles.MessageTemplate; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileUpdateTemplateParams; VerifyProfileUpdateTemplateParams params = VerifyProfileUpdateTemplateParams.builder() .templateId("12ade33a-21c0-473b-b055-b3c836e1c292") .text("Your {{app_name}} verification code is: {{code}}.") .build(); MessageTemplate messageTemplate = client.verifyProfiles().updateTemplate(params);
Returns: id (uuid), text (string)
Gets a single Verify profile.
GET /verify_profiles/{verify_profile_id}
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileData; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileRetrieveParams; VerifyProfileData verifyProfileData = client.verifyProfiles().retrieve("12ade33a-21c0-473b-b055-b3c836e1c292");
Returns: call (object), created_at (string), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), id (uuid), language (string), name (string), record_type (enum: verification_profile), sms (object), updated_at (string), webhook_failover_url (string), webhook_url (string), whatsapp (object)
PATCH /verify_profiles/{verify_profile_id}
Optional: call (object), daily_spend_limit (number), daily_spend_limit_enabled (boolean), language (string), name (string), sms (object), webhook_failover_url (string), webhook_url (string), whatsapp (object)
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileData; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileUpdateParams; VerifyProfileData verifyProfileData = client.verifyProfiles().update("12ade33a-21c0-473b-b055-b3c836e1c292");
Returns: call (object), created_at (string), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), id (uuid), language (string), name (string), record_type (enum: verification_profile), sms (object), updated_at (string), webhook_failover_url (string), webhook_url (string), whatsapp (object)
DELETE /verify_profiles/{verify_profile_id}
javaimport com.telnyx.sdk.models.verifyprofiles.VerifyProfileData; import com.telnyx.sdk.models.verifyprofiles.VerifyProfileDeleteParams; VerifyProfileData verifyProfileData = client.verifyProfiles().delete("12ade33a-21c0-473b-b055-b3c836e1c292");
Returns: call (object), created_at (string), daily_spend_limit (number), daily_spend_limit_enabled (boolean), flashcall (object), id (uuid), language (string), name (string), record_type (enum: verification_profile), sms (object), updated_at (string), webhook_failover_url (string), webhook_url (string), whatsapp (object)
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→pass | 21,062 | 42,445 | +102% | 1 | 1 | 0% | 4,890 | 7,325 | +50% | 0 | 0 | — |
case-02 | fail→pass | 50,676 | 5,948 | -88% | 1 | 1 | 0% | 3,155 | 5,805 | +84% | 0 | 0 | — |
case-03 | fail→pass | 11,498 | 6,323 | -45% | 1 | 1 | 0% | 2,313 | 5,745 | +148% | 0 | 0 | — |
case-04 | pass→pass | 18,111 | 13,963 | -23% | 1 | 1 | 0% | 3,682 | 7,425 | +102% | 0 | 0 | — |
case-05 | fail→pass | 9,434 | 7,102 | -25% | 1 | 1 | 0% | 1,960 | 5,888 | +200% | 0 | 0 | — |
case-06 | pass→pass | 6,158 | 6,782 | +10% | 1 | 1 | 0% | 1,415 | 6,074 | +329% | 0 | 0 | — |
case-07 | fail→pass | 10,481 | 4,478 | -57% | 1 | 1 | 0% | 2,665 | 5,515 | +107% | 0 | 0 | — |
case-08 | fail→pass | 40,592 | 35,821 | -12% | 1 | 1 | 0% | 2,103 | 5,914 | +181% | 0 | 0 | — |
case-09 | fail→pass | 10,114 | 4,709 | -53% | 1 | 1 | 0% | 2,185 | 5,446 | +149% | 0 | 0 | — |
case-10 | fail→pass | 6,957 | 3,595 | -48% | 1 | 1 | 0% | 1,455 | 5,105 | +251% | 0 | 0 | — |
case-11 | fail→pass | 11,379 | 5,071 | -55% | 1 | 1 | 0% | 2,346 | 5,547 | +136% | 0 | 0 | — |
case-12 | fail→pass | 12,342 | 8,550 | -31% | 1 | 1 | 0% | 2,544 | 6,393 | +151% | 0 | 0 | — |
case-13 | fail→pass | 9,110 | 5,455 | -40% | 1 | 1 | 0% | 1,881 | 5,674 | +202% | 0 | 0 | — |
case-14 | fail→pass | 12,847 | 6,442 | -50% | 1 | 1 | 0% | 2,523 | 5,831 | +131% | 0 | 0 | — |
case-15 | fail→pass | 13,571 | 3,435 | -75% | 1 | 1 | 0% | 2,617 | 5,071 | +94% | 0 | 0 | — |
case-16 | fail→pass | 14,292 | 4,596 | -68% | 1 | 1 | 0% | 3,044 | 5,453 | +79% | 0 | 0 | — |
case-17 | fail→pass | 10,687 | 5,564 | -48% | 1 | 1 | 0% | 2,052 | 5,631 | +174% | 0 | 0 | — |
case-18 | fail→pass | 12,144 | 5,172 | -57% | 1 | 1 | 0% | 2,589 | 5,510 | +113% | 0 | 0 | — |
case-19 | fail→pass | 10,992 | 6,542 | -40% | 1 | 1 | 0% | 2,149 | 5,840 | +172% | 0 | 0 | — |
case-20 | fail→pass | 6,518 | 2,336 | -64% | 1 | 1 | 0% | 1,155 | 4,822 | +317% | 0 | 0 | — |
case-21 | fail→pass | 5,895 | 1,931 | -67% | 1 | 1 | 0% | 1,018 | 4,661 | +358% | 0 | 0 | — |
case-22 | pass→pass | 12,056 | 2,395 | -80% | 1 | 1 | 0% | 2,166 | 4,784 | +121% | 0 | 0 | — |
case-23 | pass→pass | 6,632 | 2,182 | -67% | 1 | 1 | 0% | 1,208 | 4,767 | +295% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 23 cases were attempted. The headline lift of +83 percentage points is the difference between those two pass rates over the 23 comparable cases.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
| Model | Method | Date | Lift |
|---|---|---|---|
| gemini-3.6-flash | verified | 8/22/2026 | +80% |
Other measured skills in the registry, with their headline benchmark lift.