Skip to content

Commit bb6d75a

Browse files
authored
Merge pull request Vonage#145 from Vonage/account-snippets-updates
Updates account snippets
2 parents 82a12bd + 9e2aa33 commit bb6d75a

File tree

3 files changed

+43
-7
lines changed

3 files changed

+43
-7
lines changed

account/configure-account.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
source "../config.sh"
33

44
curl -X POST "https://rest.nexmo.com/account/settings" -u "$VONAGE_API_KEY:$VONAGE_API_SECRET" \
5-
-d moCallBackUrl=$SMS_CALLBACK_URL
5+
-d "moCallBackUrl=$ACCOUNT_SMS_CALLBACK_URL"

account/secret-management/create-api-secret.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ source "../../config.sh"
44
curl -X POST "https://api.nexmo.com/accounts/$ACCOUNT_ID/secrets" \
55
-H 'Content-Type: application/json' \
66
-u "$VONAGE_API_KEY:$VONAGE_API_SECRET" \
7-
-d '{"secret":"Th1s-I5-my_n3w-s3cr3t"}'
7+
-d '{"secret":"'$ACCOUNT_SECRET_VALUE'"}'
88

config.sh

Lines changed: 41 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,50 @@
11
# General
22
VONAGE_API_KEY=${VONAGE_API_KEY:-""}
33
VONAGE_API_SECRET=${VONAGE_API_SECRET:-""}
4-
54
VONAGE_APPLICATION_ID=${VONAGE_APPLICATION_ID:-""}
65
VONAGE_PRIVATE_KEY=${VONAGE_PRIVATE_KEY:-""}
76
VONAGE_SIGNATURE_SECRET=${VONAGE_SIGNATURE_SECRET:-""}
7+
VONAGE_VIRTUAL_NUMBER=${VONAGE_VIRTUAL_NUMBER:-""}
8+
9+
10+
# Account
11+
ACCOUNT_ID=${ACCOUNT_ID:-""}
12+
ACCOUNT_SECRET_ID=${ACCOUNT_SECRET_ID:-""}
13+
ACCOUNT_SECRET_VALUE=${ACCOUNT_SECRET_VALUE:-"Th1s-I5-my_n3w-s3cr3t"}
14+
ACCOUNT_SMS_CALLBACK_URL=${ACCOUNT_SMS_CALLBACK_URL:-"https://example.com/inbound-sms"}
15+
16+
17+
# Applications (includes user endpoints)
18+
19+
# Audit
20+
21+
# Conversation
22+
23+
# Dispatch
24+
25+
# Messages
26+
27+
# Number Insight (v1 & v2)
28+
29+
# Number Verification
30+
31+
# Numbers
32+
33+
# Reports
34+
35+
# Sim Swap
36+
37+
# SMS
38+
39+
# Subaccounts
40+
41+
# VBC
42+
43+
# Verify (v1 & v2)
44+
45+
# Voice
46+
47+
# -----------------------------------
848

949
TO_NUMBER=${TO_NUMBER:-""}
1050
RECIPIENT_NUMBER=${RECIPIENT_NUMBER:-""}
@@ -54,10 +94,6 @@ MESSAGES_SANDBOX_ALLOW_LISTED_FB_RECIPIENT_ID=${MESSAGES_SANDBOX_ALLOW_LISTED_FB
5494
MESSAGES_SANDBOX_VIBER_SERVICE_ID=${MESSAGES_SANDBOX_VIBER_SERVICE_ID:-"16273"}
5595

5696

57-
# Account API
58-
ACCOUNT_ID=${ACCOUNT_ID:-""}
59-
ACCOUNT_SECRET_ID=${ACCOUNT_SECRET_ID:-""}
60-
6197
# Subaccounts API
6298
NEW_SUBACCOUNT_NAME=${NEW_SUBACCOUNT_NAME:-""}
6399
NEW_SUBACCOUNT_SECRET=${NEW_SUBACCOUNT_SECRET:-""}

0 commit comments

Comments
 (0)