アプリケーション

このコードスニペットでは、指定した Applications の詳細を取得する方法を説明します。

以下の置換可能な値が、便利な方法でサンプルコードに設定されていることを確認する必要があります:

キー説明
VONAGE_API_KEY

Your Vonage API key (see it on your dashboard).

VONAGE_API_SECRET

Your Vonage API secret (also available on your dashboard).

VONAGE_APPLICATION_ID

The Vonage Application ID.

Write the code

Add the following to get-application.sh:

curl -X "GET" "https://api.nexmo.com/v2/applications/$VONAGE_APPLICATION_ID" \
     -H 'Content-Type: application/json' \
     -u "$VONAGE_API_KEY:$VONAGE_API_SECRET"

View full source

Run your code

Save this file to your machine and run it:

./get-application.sh