Skip to content

Commit c4efde4

Browse files
committed
2 parents 64a0d00 + f66f8d6 commit c4efde4

File tree

2 files changed

+29
-6
lines changed

2 files changed

+29
-6
lines changed

README.md

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,8 @@ For a list of code examples that use the Admin API, see the [How-to guides overv
9797
**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip step 4 as it was automatically performed for you.
9898

9999
1. Extract the Quickstart ZIP file or download or clone the code-examples-java repository.
100-
1. In your command-line environment, switch to the folder:
101-
`cd <Quickstart folder>` or `cd code-examples-java`
100+
1. In your command-line environment, switch to the :
101+
`cd <Quickstart >` or `cd code-examples-java`
102102
1. Package the code: `mvn package`
103103
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file src/main/resources/application.example.json and save the copy as src/main/resources/application.json.
104104
1. Add your User ID. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **User ID** GUID and save it in application.json as your `DS_TARGET_ACCOUNT_ID`.
@@ -107,7 +107,28 @@ For a list of code examples that use the Admin API, see the [How-to guides overv
107107
1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:8080/login&type=acg. Select **SAVE**.
108108
1. Set a name and email address for the signer. In application.json, save an email address as `DS_SIGNER_EMAIL` and a name as `DS_SIGNER_NAME`.
109109
**Note:** Protect your personal information. Please make sure that application.json will not be stored in your source code repository.
110-
1. Run the launcher: `java -Dspring.profiles.active=dev -jar target/code-examples-java-1.0-SNAPSHOT.war`
110+
111+
#### Multiple code examples, Authorization Code Grant, and JWT Grant:
112+
1. $ `cd <Quickstart folder>`
113+
1. $ `mvn package -Dmaven.test.skip=true`
114+
1. $ `java -Dspring.profiles.active=dev -jar target/code-examples-java-1.0-SNAPSHOT.war`
115+
For Windows:
116+
1. $ `mvn package -D"maven.test.skip"="true"`
117+
1. $ `java -D"spring.profiles.active"="dev" -jar target/code-examples-java-1.0-SNAPSHOT.war`
118+
119+
#### Authorization Code Grant embedded signing example:
120+
121+
1. $ `cd <Quickstart folder>/Quick_ACG`
122+
1. $ `mvn spring-boot:run -Drun.profiles=dev`
123+
For Windows:
124+
1. $ `mvn spring-boot:run -D"run.profiles"="dev"`
125+
126+
#### JWT grant remote signing example:
127+
1. $ `cd <Quickstart folder>/'JWT Console App'`
128+
1. $ `mvn compile`
129+
1. $ `mvn exec:java -Dexec.mainClass="com.docusign.jwtconsoleapp.JWTConsoleApp"`
130+
For Windows
131+
1. $ `mvn exec:java -D"exec.mainClass"="com.docusign.jwtconsoleapp.JWTConsoleApp"`
111132

112133

113134
### Installation steps for JWT Grant authentication

src/main/java/com/docusign/controller/eSignature/examples/EG027ControllerPermissionDelete.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,15 +45,17 @@ protected void onInitModel(WorkArguments args, ModelMap model) throws Exception
4545

4646
@Override
4747
protected Object doWork(WorkArguments args, ModelMap model, HttpServletResponse response) {
48-
// Step 2: Construct your API headers
48+
// Construct your API headers
4949
AccountsApi accountsApi = createAccountsApi(session.getBasePath(), user.getAccessToken());
5050

51-
// Step 3: Call the eSignature Rest API to delete profile
51+
// Call the eSignature Rest API to delete profile
52+
//ds-snippet-start:eSign27Step3
5253
String curProfileId = args.getProfileId();
5354
try {
5455
PermissionDeleteService.permissionDelete(accountsApi, session.getAccountId(), curProfileId);
56+
//ds-snippet-end:eSign27Step3
5557

56-
// Step 4: Show 'done' (successful) page
58+
// Show 'done' (successful) page
5759
DoneExample.createDefault(getTextForCodeExampleByApiType().ExampleName)
5860
.withMessage(getTextForCodeExampleByApiType().ResultsPageText.replaceFirst("\\{0}", curProfileId))
5961
.addToModel(model, config);

0 commit comments

Comments
 (0)