Numbersインサイト・アドバンストWebhook
2027年2月4日をもって、VonageはVonage Number Insightsを終了いたします。継続的なサポートを確保し、よりスケーラブルで将来性のあるソリューションを提供するため、当社の強化されたソリューションへの移行をお勧めします: Vonage Identity Insights API.Vonage Identity Insight APIは、複数の電話番号関連データセットを1つの柔軟なAPIに統合し、電話番号に関するリアルタイムの情報を要求したり、番号のフォーマット、キャリアの詳細、SIMスワップ、加入者照合などのインサイトを1回の呼び出しで自由に組み合わせて取得できるようにします。
をご確認ください。 Numbersインサイト移行ガイドAPIの相違点、必要な変更点、スムーズな移行のためのベストプラクティスに関する詳細なガイダンスを提供しています。
このコードスニペットでは、Number Insight Advanced APIへの非同期呼び出しによって返されるデータを受信するWebhookハンドラのコードを示します。詳細は Numbersインサイトアドバンス コードスニペットで、インサイトデータの最初のリクエストのコードを学びます。
コード例を実行する前に、変数のプレースホルダーを置き換えてください:
| キー | 説明 |
|---|---|
VONAGE_API_KEY | Your Vonage API key (see it on your dashboard). |
VONAGE_API_SECRET | Your Vonage API secret (also available on your dashboard). |
INSIGHT_NUMBER | The number you want to retrieve insight information for. |
Prerequisites
Create a file named ni-advanced-async.js and add the following code:
Run your code
Save this file to your machine and run it:
Prerequisites
Add the following to build.gradle:
Write the code
Add the following to the main method of the AdvancedInsightWebhook class:
Run your code
We can use the アプリケーション plugin for Gradle to simplify the running of our application. Update your build.gradle with the following:
Run the following gradle command to execute your application, replacing com.vonage.quickstart.kt.numberinsight with the package containing AdvancedInsightWebhook:
Prerequisites
Add the following to build.gradle:
Write the code
Add the following to the main method of the AsyncInsightTrigger class:
Run your code
We can use the アプリケーション plugin for Gradle to simplify the running of our application. Update your build.gradle with the following:
Run the following gradle command to execute your application, replacing com.vonage.quickstart.insight with the package containing AsyncInsightTrigger:
Prerequisites
Create a file named NumberInsightsController.cs and add the following code:
Prerequisites
Run your code
Save this file to your machine and run it:
Prerequisites
Run your code
Save this file to your machine and run it:
Prerequisites
Run your code
Save this file to your machine and run it:
APIからのレスポンスには以下のデータが含まれている:
返される各フィールドの説明と、可能なすべての値については Numbers Insight API ドキュメント