DEV Community

Cover image for Optimizing Multi-Service Identifier Verification with Combo Check APIs
eKYC Pro
eKYC Pro

Posted on

Optimizing Multi-Service Identifier Verification with Combo Check APIs

When building identity verification flows, developers often face a choice: make multiple individual API calls to different services—increasing latency and complexity—or find a way to aggregate those signals. If you are managing user onboarding or account recovery, you need a reliable way to verify identifiers like phone numbers or emails across multiple platforms simultaneously.

In this guide, we will explore how to use a Combo Check API to perform multi-service verification in a single synchronous request-response flow.

The Challenge of Multi-Service Verification

Traditionally, verifying a user across platforms (like WhatsApp, Telegram, or VK) requires hitting separate endpoints for each. This creates a "waterfall" effect where the total time taken is the sum of all individual requests. Furthermore, managing partial failures—where one service might time out while others succeed—adds significant overhead to your application logic.

Implementing the Combo Check Workflow

Instead of managing multiple connections, the Combo Check API allows you to send a single request containing an identifier, and the system handles the distribution to your selected services in parallel.

1. Preparing Your Configuration

Before making calls, define your preferred services in your dashboard. This creates a "combo" configuration. If you need flexibility, the API allows you to override these settings dynamically per request.

2. Executing the Verification

Use the POST /v1/check/combo/phone or POST /v1/check/combo/email endpoints. Here is how you can perform a check with a dynamic service override using curl:

curl --location 'https://api.ekycpro.com/v1/check/combo/phone' \
--header 'X-API-Key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
 "identifier": "+6281234567890",
 "service_types": ["ws", "telegram", "vk"]
}'
Enter fullscreen mode Exit fullscreen mode

3. Handling the Response

The API returns a unified JSON object. Crucially, the system is designed to handle partial success. Even if one service returns an error (such as a timeout), the response will still contain the successful data from the other services.

Key fields to monitor in the response include:

  • data.results: An object containing the status of each service.
  • data.results.*.registered: A boolean or null value indicating if the identifier is registered.
  • data.results.*.error: Present only if a specific service failed (e.g., "timeout").
  • data.total_cost_usd: The total billing for the aggregated request.

Best Practices for Integration

  • Set Appropriate Timeouts: Since the system processes services in parallel, ensure your client-side timeout is set to at least 15 seconds to accommodate the processing window.
  • Manage Partial States: Always check the error field within individual service nodes. If a service returns a "timeout" error, you can choose to retry that specific check using the single-identifier /v1/check endpoint.
  • Monitor Balance: The system performs a pre-check of your balance against the total cost of the combo. If your balance is insufficient, the entire call will return a 402 status code.

Conclusion

Aggregating identity signals into a single request simplifies your architecture and improves the maintainability of your verification logic. By leveraging a Combo Check approach, you move away from managing complex asynchronous chains and toward a cleaner, synchronous integration pattern.

This article was drafted with AI assistance and reviewed before publishing.

Top comments (0)