Skip to content

Commit fa3bc50

Browse files
committed
reorg
1 parent 838c519 commit fa3bc50

File tree

6 files changed

+16
-16274
lines changed

6 files changed

+16
-16274
lines changed

Examples/eg-000-auth-code-grant/auth-code-grant-1.sh

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
# First leg of Authorization Code Grant
2-
source ../startup_checks.sh
32
source ../../Env.txt
43

5-
SCOPE="signature"
64
URL_AUTH_START=$(cat <<END
75
${DS_AUTH_SERVER}/oauth/auth?\
86
response_type=code\
9-
&scope=${SCOPE}\
7+
&scope=signature\
108
&client_id=${DS_CLIENT_ID}\
119
&state=${DS_AUTH_STATE}\
1210
&redirect_uri=${DS_REDIRECT_URL_ENCODED}

Examples/eg-000-auth-code-grant/auth-code-grant-2.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ if [ $# -eq 0 ]
99
echo ""
1010
fi
1111

12-
source ../startup_checks.sh
1312
source ../../Env.txt
1413

1514
CODE="$1"
@@ -40,8 +39,6 @@ sed 's/\",\"token_type\":\"Bearer\"\,\"refresh_token\":\".*\",\"expires_in\":.*}
4039
echo "$DS_ACCESS_TOKEN" > ../../DS_ACCESS_TOKEN
4140
echo "Access token:"
4241
echo $DS_ACCESS_TOKEN
43-
echo ""
44-
echo "The access token has been written to file DS_ACCESS_TOKEN for use by other scripts."
4542

4643
# Pull out the refresh_token
4744
DS_REFRESH_TOKEN=`sed 's/{\"access_token\":\".*\",\"token_type\":\"Bearer\"\,\"refresh_token\":\"//' $tmpfile |

Examples/eg-000-auth-code-grant/auth-code-grant-3.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ if [ ! -f "$ACCESS_TOKEN_FILE" ]; then
88
exit 1;
99
fi
1010

11-
source ../startup_checks.sh
1211
source ../../Env.txt
1312
DS_ACCESS_TOKEN=`cat $ACCESS_TOKEN_FILE`
1413

Examples/eg-002-env-three-docs/eg-002-env-three-docs.sh renamed to Examples/eg002SigningViaEmail.sh

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ if [[ $SHELL != *"bash"* ]]; then
55
echo "PROBLEM: Run these scripts from within the bash shell."
66
fi
77

8-
source ../../Env.txt
8+
source ../Env.txt
99

1010
# document 1 (html) has tag **signature_1**
1111
# document 2 (docx) has tag /sn1/
@@ -24,9 +24,9 @@ doc2_base64=$(mktemp /tmp/eg-002-doc2.XXXXXX)
2424
doc3_base64=$(mktemp /tmp/eg-002-doc3.XXXXXX)
2525

2626
# Fetch docs and encode
27-
cat ../../demo_documents/doc_1.html | base64 > $doc1_base64
28-
cat ../../demo_documents/World_Wide_Corp_Battle_Plan_Trafalgar.docx | base64 > $doc2_base64
29-
cat ../../demo_documents/World_Wide_Corp_lorem.pdf | base64 > $doc3_base64
27+
cat ../demo_documents/doc_1.html | base64 > $doc1_base64
28+
cat ../demo_documents/World_Wide_Corp_Battle_Plan_Trafalgar.docx | base64 > $doc2_base64
29+
cat ../demo_documents/World_Wide_Corp_lorem.pdf | base64 > $doc3_base64
3030

3131
echo ""
3232
echo "Sending the envelope request to DocuSign..."
@@ -109,20 +109,20 @@ curl --header "Authorization: Bearer {ACCESS_TOKEN}" \
109109
--data-binary @${request_data} \
110110
--request POST https://demo.docusign.net/restapi/v2/accounts/{ACCOUNT_ID}/envelopes
111111

112-
echo ""
113-
echo ""
114-
echo "Files"
115-
echo "$request_data"
116-
echo "$doc1_base64"
117-
echo "$doc2_base64"
118-
echo "$doc3_base64"
119112

113+
#echo ""
114+
#echo ""
115+
#echo "Files"
116+
#echo "$request_data"
117+
#echo "$doc1_base64"
118+
#echo "$doc2_base64"
119+
#echo "$doc3_base64"
120120

121121
# cleanup
122-
#rm "$request_data"
123-
#rm "$doc1_base64"
124-
#rm "$doc2_base64"
125-
#rm "$doc3_base64"
122+
rm "$request_data"
123+
rm "$doc1_base64"
124+
rm "$doc2_base64"
125+
rm "$doc3_base64"
126126

127127
echo ""
128128
echo ""

0 commit comments

Comments
 (0)