From b91f282b77822ecdc68da9e85292c66ab3ce2bc4 Mon Sep 17 00:00:00 2001
From: an-tk
Date: Sun, 7 Feb 2021 12:56:28 +0200
Subject: [PATCH 001/363] docusign_esign gem version update
---
Gemfile | 2 +-
Gemfile.lock | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Gemfile b/Gemfile
index 9756654..2ef8df4 100644
--- a/Gemfile
+++ b/Gemfile
@@ -62,7 +62,7 @@ group :test do
gem 'chromedriver-helper', '~> 2.1.1'
end
-gem 'docusign_esign', '~> 3.6'
+gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click'
gem 'omniauth-oauth2', '~> 1.6'
diff --git a/Gemfile.lock b/Gemfile.lock
index 60cf976..0dac2dc 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -91,7 +91,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_esign (3.6.0)
+ docusign_esign (3.8.0.rc1)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -259,7 +259,7 @@ DEPENDENCIES
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
docusign_click
- docusign_esign (~> 3.6)
+ docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
@@ -284,4 +284,4 @@ RUBY VERSION
ruby 2.7.1p83
BUNDLED WITH
- 2.1.4
\ No newline at end of file
+ 2.1.4
From b21dc32080f92b63e0fd6bbfb55d4d0d9a2109c5 Mon Sep 17 00:00:00 2001
From: an-tk
Date: Tue, 9 Feb 2021 10:08:31 +0200
Subject: [PATCH 002/363] Updated eSign31 example: added confirm successful
batch send step
---
.../e_sign/eg031_bulk_sending_envelopes_controller.rb | 4 +++-
app/services/e_sign/eg031_bulk_sending_envelopes_service.rb | 3 +++
app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb | 2 +-
3 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
index de78efb..6845419 100644
--- a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
+++ b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
@@ -11,7 +11,9 @@ def create
# b) Display the JSON response
@title = 'Bulk sending envelopes'
@h1 = 'Bulk sending envelopes'
- @message = "Confirming Bulk Send has initiated #{results}"
+ @message = 'Bulk send envelope was successfully performed!'
+ @json = results.to_json.to_json
+
render 'ds_common/example_done'
rescue DocuSign_eSign::ApiError => e
diff --git a/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb b/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
index 4ca46a6..77809eb 100644
--- a/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
+++ b/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
@@ -56,6 +56,9 @@ def call
bulk_send_request = DocuSign_eSign::BulkSendRequest.new(envelopeOrTemplateId: envelope_id)
batch = bulk_envelopes_api.create_bulk_send_request(args[:account_id], bulk_list_id, bulk_send_request)
batch_id = batch.batch_id
+
+ # Step 8. Confirm successful batch send
+ bulk_envelopes_api.get_bulk_send_batch_status(args[:account_id], batch_id)
end
private
diff --git a/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb b/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
index 1c9aaa7..184208f 100644
--- a/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
+++ b/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
@@ -1,4 +1,4 @@
-31. Bulk sending envelopes to multiple recipients
+31. Bulk sending envelopes to multiple recipients
Method BulkSend:createBulkSendList creates a bulk list that you can to use an envelope to up
From b53078f7638eab19b1f47569f315895b5f164ee4 Mon Sep 17 00:00:00 2001
From: an-tk
Date: Tue, 9 Feb 2021 13:15:13 +0200
Subject: [PATCH 003/363] Updated quickstart logic
---
app/controllers/e_sign/eg001_embedded_signing_controller.rb | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/app/controllers/e_sign/eg001_embedded_signing_controller.rb b/app/controllers/e_sign/eg001_embedded_signing_controller.rb
index 57acf1c..3b00793 100644
--- a/app/controllers/e_sign/eg001_embedded_signing_controller.rb
+++ b/app/controllers/e_sign/eg001_embedded_signing_controller.rb
@@ -16,4 +16,9 @@ def create
redirect_url = ESign::Eg001EmbeddedSigningService.new(session, request).call
redirect_to redirect_url
end
+
+ def get
+ session[:been_here] = true
+ super
+ end
end
From ccec5ae7e4fcc14646eb83ebec49b7ffd9d02fd2 Mon Sep 17 00:00:00 2001
From: an-tk
Date: Fri, 19 Feb 2021 20:56:01 +0200
Subject: [PATCH 004/363] Clean up eg031
---
.../e_sign/eg031_bulk_sending_envelopes_controller.rb | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
index 6845419..b9ebf41 100644
--- a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
+++ b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
@@ -9,9 +9,9 @@ def create
results = ESign::Eg031BulkSendingEnvelopesService.new(request, session).call
# Step 4. a) Call the eSignature API
# b) Display the JSON response
- @title = 'Bulk sending envelopes'
- @h1 = 'Bulk sending envelopes'
- @message = 'Bulk send envelope was successfully performed!'
+ @title = 'Bulk sent'
+ @h1 = 'Bulk send envelope was successfully performed!'
+ @message = "Bulk request queued to #{results.queued} user lists."
@json = results.to_json.to_json
render 'ds_common/example_done'
From c8d91d75390847289083cba7e218eedefec35a63 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 22 Feb 2021 17:56:42 +0000
Subject: [PATCH 005/363] Bump nokogiri from 1.10.10 to 1.11.1
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.1.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.1)
Signed-off-by: dependabot[bot]
---
Gemfile.lock | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/Gemfile.lock b/Gemfile.lock
index 60cf976..510e2ef 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -130,15 +130,16 @@ GEM
method_source (0.9.2)
mimemagic (0.3.5)
mini_mime (1.0.2)
- mini_portile2 (2.4.0)
+ mini_portile2 (2.5.0)
minitest (5.14.2)
msgpack (1.3.3)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.4)
- nokogiri (1.10.10)
- mini_portile2 (~> 2.4.0)
+ nokogiri (1.11.1)
+ mini_portile2 (~> 2.5.0)
+ racc (~> 1.4)
oauth2 (1.4.4)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -164,6 +165,7 @@ GEM
public_suffix (4.0.6)
puma (4.3.6)
nio4r (~> 2.0)
+ racc (1.5.2)
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
From 7b62e6fe7414f233d228f01910d554f3f6d67f2d Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 25 Feb 2021 10:51:20 -0800
Subject: [PATCH 006/363] Various updates including adding step 8 of bulk send
---
Gemfile | 2 +-
Gemfile.lock | 6 +++---
README.md | 6 ++----
.../e_sign/eg001_embedded_signing_controller.rb | 5 +++++
.../e_sign/eg031_bulk_sending_envelopes_controller.rb | 8 +++++---
...008_grant_office_access_to_form_group_controller.rb | 6 +++++-
.../eg009_assign_form_to_form_group_controller.rb | 6 +++++-
.../e_sign/eg031_bulk_sending_envelopes_service.rb | 3 +++
.../room_api/eg007_create_form_group_service.rb | 10 ++++++----
.../eg008_grant_office_access_to_form_group_service.rb | 6 ++++--
.../eg009_assign_form_to_form_group_service.rb | 9 ++++++---
.../e_sign/eg031_bulk_sending_envelopes/get.html.erb | 2 +-
12 files changed, 46 insertions(+), 23 deletions(-)
diff --git a/Gemfile b/Gemfile
index 9756654..2ef8df4 100644
--- a/Gemfile
+++ b/Gemfile
@@ -62,7 +62,7 @@ group :test do
gem 'chromedriver-helper', '~> 2.1.1'
end
-gem 'docusign_esign', '~> 3.6'
+gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click'
gem 'omniauth-oauth2', '~> 1.6'
diff --git a/Gemfile.lock b/Gemfile.lock
index 510e2ef..24b4da7 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -91,7 +91,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_esign (3.6.0)
+ docusign_esign (3.8.0.rc1)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -261,7 +261,7 @@ DEPENDENCIES
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
docusign_click
- docusign_esign (~> 3.6)
+ docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
@@ -286,4 +286,4 @@ RUBY VERSION
ruby 2.7.1p83
BUNDLED WITH
- 2.1.4
\ No newline at end of file
+ 2.1.4
diff --git a/README.md b/README.md
index 6b66e61..ad77d74 100644
--- a/README.md
+++ b/README.md
@@ -17,8 +17,6 @@ This repo is a Ruby on Rails application that demonstrates:
For more information about the scopes used for obtaining authorization to use the eSignature API, see the [Required Scopes section](https://developers.docusign.com/docs/esign-rest-api/esign101/auth).
-For more information about the scopes used for obtaining authorization to use the eSignature API, see the [Required Scopes section](https://developers.docusign.com/docs/esign-rest-api/esign101/auth).
-
1. **Use embedded signing.**
[Source.](app/services/e_sign/eg001_embedded_signing_service.rb)
This example sends an envelope, and then uses embedded signing for the first signer.
@@ -142,9 +140,9 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](app/services/e_sign/eg034_use_conditional_recipients_service.rb)
This example demonstrates how to create an envelope where the workflow is routed to different recipients based on the value of a transaction.
-1. **Request a signature by SMS**
+1. **Request a signature by SMS delivery**
[Source.](app/services/e_sign/eg035_sms_delivery_service.rb)
- This code example demonstrates how to send a signature request for a signer to read and sign via an SMS message.
+ This code example demonstrates how to send a signature request via an SMS message using the [Envelopes: create](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
## Rooms API
diff --git a/app/controllers/e_sign/eg001_embedded_signing_controller.rb b/app/controllers/e_sign/eg001_embedded_signing_controller.rb
index 57acf1c..3b00793 100644
--- a/app/controllers/e_sign/eg001_embedded_signing_controller.rb
+++ b/app/controllers/e_sign/eg001_embedded_signing_controller.rb
@@ -16,4 +16,9 @@ def create
redirect_url = ESign::Eg001EmbeddedSigningService.new(session, request).call
redirect_to redirect_url
end
+
+ def get
+ session[:been_here] = true
+ super
+ end
end
diff --git a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
index de78efb..b9ebf41 100644
--- a/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
+++ b/app/controllers/e_sign/eg031_bulk_sending_envelopes_controller.rb
@@ -9,9 +9,11 @@ def create
results = ESign::Eg031BulkSendingEnvelopesService.new(request, session).call
# Step 4. a) Call the eSignature API
# b) Display the JSON response
- @title = 'Bulk sending envelopes'
- @h1 = 'Bulk sending envelopes'
- @message = "Confirming Bulk Send has initiated #{results}"
+ @title = 'Bulk sent'
+ @h1 = 'Bulk send envelope was successfully performed!'
+ @message = "Bulk request queued to #{results.queued} user lists."
+ @json = results.to_json.to_json
+
render 'ds_common/example_done'
rescue DocuSign_eSign::ApiError => e
diff --git a/app/controllers/room_api/eg008_grant_office_access_to_form_group_controller.rb b/app/controllers/room_api/eg008_grant_office_access_to_form_group_controller.rb
index ac9370b..d7eedee 100644
--- a/app/controllers/room_api/eg008_grant_office_access_to_form_group_controller.rb
+++ b/app/controllers/room_api/eg008_grant_office_access_to_form_group_controller.rb
@@ -19,9 +19,13 @@ def create
def get
super
- # Step 3. Get an office ID
+ # Step 3 start
@offices = RoomApi::GetDataService.new(session).get_offices
+ # Step 3 end
+
+ # Step 4 start
@form_groups = RoomApi::GetDataService.new(session).get_form_groups
+ # Step 4 end
end
private
diff --git a/app/controllers/room_api/eg009_assign_form_to_form_group_controller.rb b/app/controllers/room_api/eg009_assign_form_to_form_group_controller.rb
index 79ff9c9..4ecde46 100644
--- a/app/controllers/room_api/eg009_assign_form_to_form_group_controller.rb
+++ b/app/controllers/room_api/eg009_assign_form_to_form_group_controller.rb
@@ -19,9 +19,13 @@ def create
def get
super
- # Step 3. Obtain the desired form ID
+ # Step 3 start
@forms = RoomApi::GetDataService.new(session).get_form_libraries
+ # Step 3 end
+
+ # Step 4 start
@form_groups = RoomApi::GetDataService.new(session).get_form_groups
+ # Step 4 end
end
private
diff --git a/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb b/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
index 4ca46a6..77809eb 100644
--- a/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
+++ b/app/services/e_sign/eg031_bulk_sending_envelopes_service.rb
@@ -56,6 +56,9 @@ def call
bulk_send_request = DocuSign_eSign::BulkSendRequest.new(envelopeOrTemplateId: envelope_id)
batch = bulk_envelopes_api.create_bulk_send_request(args[:account_id], bulk_list_id, bulk_send_request)
batch_id = batch.batch_id
+
+ # Step 8. Confirm successful batch send
+ bulk_envelopes_api.get_bulk_send_batch_status(args[:account_id], batch_id)
end
private
diff --git a/app/services/room_api/eg007_create_form_group_service.rb b/app/services/room_api/eg007_create_form_group_service.rb
index 79c72fb..a6bd3d1 100644
--- a/app/services/room_api/eg007_create_form_group_service.rb
+++ b/app/services/room_api/eg007_create_form_group_service.rb
@@ -18,25 +18,27 @@ def call
private
def worker
- # Step 2. Construct your API headers
+ # Step 2 start
configuration = DocuSign_Rooms::Configuration.new
configuration.host = Rails.configuration.rooms_host
api_client = DocuSign_Rooms::ApiClient.new(configuration)
api_client.set_default_header("Authorization", "Bearer #{args[:access_token]}")
+ # Step 2 end
- # Step 4. Call the Rooms API
+ # Step 4 start
rooms_api = DocuSign_Rooms::FormGroupsApi.new(api_client)
-
rooms_api.create_form_group(args[:account_id], body)
+ # Step 4 end
end
def body
- #Step 3. Construct the request body
+ # Step 3 start
DocuSign_Rooms::RoomForCreate.new(
{
name: args[:group_name]
}
)
+ # Step 3 end
end
end
diff --git a/app/services/room_api/eg008_grant_office_access_to_form_group_service.rb b/app/services/room_api/eg008_grant_office_access_to_form_group_service.rb
index bd4e85a..b036f1a 100644
--- a/app/services/room_api/eg008_grant_office_access_to_form_group_service.rb
+++ b/app/services/room_api/eg008_grant_office_access_to_form_group_service.rb
@@ -19,20 +19,22 @@ def call
private
def worker
- # Step 2. Construct your API headers
+ # Step 2 start
configuration = DocuSign_Rooms::Configuration.new
configuration.host = Rails.configuration.rooms_host
api_client = DocuSign_Rooms::ApiClient.new(configuration)
api_client.set_default_header("Authorization", "Bearer #{args[:access_token]}")
+ # Step 2 end
- # Step 4. Call the Rooms API
+ # Step 5 start
form_groups_api = DocuSign_Rooms::FormGroupsApi.new(api_client)
begin
response = form_groups_api.grant_office_access_to_form_group(args[:form_group_id], args[:office_id], args[:account_id])
rescue Exception => e
return {exception: 'Failed to grant office access to a form group'}
end
+ # Step 5 end
response
end
end
diff --git a/app/services/room_api/eg009_assign_form_to_form_group_service.rb b/app/services/room_api/eg009_assign_form_to_form_group_service.rb
index efb93d1..a24d015 100644
--- a/app/services/room_api/eg009_assign_form_to_form_group_service.rb
+++ b/app/services/room_api/eg009_assign_form_to_form_group_service.rb
@@ -19,29 +19,32 @@ def call
private
def worker
- # Step 2. Construct your API headers
+ # Step 2 start
configuration = DocuSign_Rooms::Configuration.new
configuration.host = Rails.configuration.rooms_host
api_client = DocuSign_Rooms::ApiClient.new(configuration)
api_client.set_default_header("Authorization", "Bearer #{args[:access_token]}")
+ # Step 2 end
- # Step 5. Call the Rooms API
+ # Step 6 start
form_groups_api = DocuSign_Rooms::FormGroupsApi.new(api_client)
begin
response = form_groups_api.assign_form_group_form(args[:form_group_id], args[:account_id], body)
rescue Exception => e
return { exception: 'Failed to assign a form to a form group' }
end
+ # Step 6 end
response
end
def body
- # Step 4. Construct your request body
+ # Step 5 start
DocuSign_Rooms::FormGroupFormToAssign.new(
{
formId: args[:form_id]
}
)
+ # Step 5 end
end
end
diff --git a/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb b/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
index 1c9aaa7..184208f 100644
--- a/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
+++ b/app/views/e_sign/eg031_bulk_sending_envelopes/get.html.erb
@@ -1,4 +1,4 @@
-31. Bulk sending envelopes to multiple recipients
+31. Bulk sending envelopes to multiple recipients
Method BulkSend:createBulkSendList creates a bulk list that you can to use an envelope to up
From e77f00793c297a2346fc9d316b41ccf21ec5d66f Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Tue, 2 Mar 2021 15:56:28 -0800
Subject: [PATCH 007/363] Updating various packages to move forward with new
versions
---
Gemfile | 10 ++--
Gemfile.lock | 131 ++++++++++++++++++++++++++++-----------------------
2 files changed, 77 insertions(+), 64 deletions(-)
diff --git a/Gemfile b/Gemfile
index 2ef8df4..89d7d58 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,12 +1,12 @@
-# frozen_string_literal: true
+ # frozen_string_literal: true
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.1'
+ruby '2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.3'
+gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
@@ -64,8 +64,8 @@ end
gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click'
-gem 'omniauth-oauth2', '~> 1.6'
+gem 'docusign_click', '~> 1.0.0'
+gem 'omniauth-oauth2', '~> 1.7.1'
gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
diff --git a/Gemfile.lock b/Gemfile.lock
index 24b4da7..d84c396 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.4)
- actionpack (= 6.0.3.4)
+ actioncable (6.0.3.5)
+ actionpack (= 6.0.3.5)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionmailbox (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
mail (>= 2.7.1)
- actionmailer (6.0.3.4)
- actionpack (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
+ actionmailer (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.4)
- actionview (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionpack (6.0.3.5)
+ actionview (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.4)
- actionpack (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actiontext (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
nokogiri (>= 1.8.5)
- actionview (6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionview (6.0.3.5)
+ activesupport (= 6.0.3.5)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.4)
- activesupport (= 6.0.3.4)
+ activejob (6.0.3.5)
+ activesupport (= 6.0.3.5)
globalid (>= 0.3.6)
- activemodel (6.0.3.4)
- activesupport (= 6.0.3.4)
- activerecord (6.0.3.4)
- activemodel (= 6.0.3.4)
- activesupport (= 6.0.3.4)
- activestorage (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
+ activemodel (6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activerecord (6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activestorage (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
marcel (~> 0.3.1)
- activesupport (6.0.3.4)
+ activesupport (6.0.3.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -87,7 +87,8 @@ GEM
coffee-script-source (1.12.2)
concurrent-ruby (1.1.7)
crass (1.0.6)
- docusign_click (1.0.0.beta2)
+ docusign_click (1.0.0)
+ addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -103,10 +104,13 @@ GEM
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.1.0)
+ faraday (1.3.0)
+ faraday-net_http (~> 1.0)
multipart-post (>= 1.2, < 3)
ruby2_keywords
+ faraday-net_http (1.0.1)
ffi (1.13.1)
+ ffi (1.13.1-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
@@ -133,6 +137,7 @@ GEM
mini_portile2 (2.5.0)
minitest (5.14.2)
msgpack (1.3.3)
+ msgpack (1.3.3-x64-mingw32)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
@@ -140,6 +145,8 @@ GEM
nokogiri (1.11.1)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
+ nokogiri (1.11.1-x64-mingw32)
+ racc (~> 1.4)
oauth2 (1.4.4)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -149,9 +156,9 @@ GEM
omniauth (1.9.1)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
- omniauth-oauth2 (1.7.0)
+ omniauth-oauth2 (1.7.1)
oauth2 (~> 1.4)
- omniauth (~> 1.9)
+ omniauth (>= 1.9, < 3)
omniauth-rails_csrf_protection (0.1.2)
actionpack (>= 4.2)
omniauth (>= 1.3.1)
@@ -169,29 +176,29 @@ GEM
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.4)
- actioncable (= 6.0.3.4)
- actionmailbox (= 6.0.3.4)
- actionmailer (= 6.0.3.4)
- actionpack (= 6.0.3.4)
- actiontext (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activemodel (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ rails (6.0.3.5)
+ actioncable (= 6.0.3.5)
+ actionmailbox (= 6.0.3.5)
+ actionmailer (= 6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actiontext (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
bundler (>= 1.3.0)
- railties (= 6.0.3.4)
+ railties (= 6.0.3.5)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.4)
- actionpack (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ railties (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -200,12 +207,14 @@ GEM
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
- ruby2_keywords (0.0.2)
+ ruby2_keywords (0.0.4)
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
+ sassc (2.4.0-x64-mingw32)
+ ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
@@ -237,8 +246,11 @@ GEM
ethon (>= 0.9.0)
tzinfo (1.2.7)
thread_safe (~> 0.1)
+ tzinfo-data (1.2019.3)
+ tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
+ wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -253,6 +265,7 @@ GEM
PLATFORMS
ruby
+ x64-mingw32
DEPENDENCIES
bootsnap (~> 1.4.5)
@@ -260,17 +273,17 @@ DEPENDENCIES
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
- docusign_click
+ docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
- omniauth-oauth2 (~> 1.6)
+ omniauth-oauth2 (~> 1.7.1)
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
puma (~> 4.3.3)
- rails (~> 6.0.3.3)
+ rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
spring (~> 2.1.0)
@@ -283,7 +296,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.1p83
+ ruby 2.7.2p137
BUNDLED WITH
2.1.4
From cbcf4ae357e4d9a96708d1028e87960b7dd75baa Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Tue, 2 Mar 2021 16:50:49 -0800
Subject: [PATCH 008/363] Updating gem package versions
---
Gemfile | 10 ++--
Gemfile.lock | 131 ++++++++++++++++++++++++++++-----------------------
2 files changed, 77 insertions(+), 64 deletions(-)
diff --git a/Gemfile b/Gemfile
index 2ef8df4..89d7d58 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,12 +1,12 @@
-# frozen_string_literal: true
+ # frozen_string_literal: true
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.1'
+ruby '2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.3'
+gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
@@ -64,8 +64,8 @@ end
gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click'
-gem 'omniauth-oauth2', '~> 1.6'
+gem 'docusign_click', '~> 1.0.0'
+gem 'omniauth-oauth2', '~> 1.7.1'
gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
diff --git a/Gemfile.lock b/Gemfile.lock
index 24b4da7..d84c396 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.4)
- actionpack (= 6.0.3.4)
+ actioncable (6.0.3.5)
+ actionpack (= 6.0.3.5)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionmailbox (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
mail (>= 2.7.1)
- actionmailer (6.0.3.4)
- actionpack (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
+ actionmailer (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.4)
- actionview (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionpack (6.0.3.5)
+ actionview (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.4)
- actionpack (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actiontext (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
nokogiri (>= 1.8.5)
- actionview (6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionview (6.0.3.5)
+ activesupport (= 6.0.3.5)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.4)
- activesupport (= 6.0.3.4)
+ activejob (6.0.3.5)
+ activesupport (= 6.0.3.5)
globalid (>= 0.3.6)
- activemodel (6.0.3.4)
- activesupport (= 6.0.3.4)
- activerecord (6.0.3.4)
- activemodel (= 6.0.3.4)
- activesupport (= 6.0.3.4)
- activestorage (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
+ activemodel (6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activerecord (6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activestorage (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
marcel (~> 0.3.1)
- activesupport (6.0.3.4)
+ activesupport (6.0.3.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -87,7 +87,8 @@ GEM
coffee-script-source (1.12.2)
concurrent-ruby (1.1.7)
crass (1.0.6)
- docusign_click (1.0.0.beta2)
+ docusign_click (1.0.0)
+ addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -103,10 +104,13 @@ GEM
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.1.0)
+ faraday (1.3.0)
+ faraday-net_http (~> 1.0)
multipart-post (>= 1.2, < 3)
ruby2_keywords
+ faraday-net_http (1.0.1)
ffi (1.13.1)
+ ffi (1.13.1-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
@@ -133,6 +137,7 @@ GEM
mini_portile2 (2.5.0)
minitest (5.14.2)
msgpack (1.3.3)
+ msgpack (1.3.3-x64-mingw32)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
@@ -140,6 +145,8 @@ GEM
nokogiri (1.11.1)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
+ nokogiri (1.11.1-x64-mingw32)
+ racc (~> 1.4)
oauth2 (1.4.4)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -149,9 +156,9 @@ GEM
omniauth (1.9.1)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
- omniauth-oauth2 (1.7.0)
+ omniauth-oauth2 (1.7.1)
oauth2 (~> 1.4)
- omniauth (~> 1.9)
+ omniauth (>= 1.9, < 3)
omniauth-rails_csrf_protection (0.1.2)
actionpack (>= 4.2)
omniauth (>= 1.3.1)
@@ -169,29 +176,29 @@ GEM
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.4)
- actioncable (= 6.0.3.4)
- actionmailbox (= 6.0.3.4)
- actionmailer (= 6.0.3.4)
- actionpack (= 6.0.3.4)
- actiontext (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activemodel (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ rails (6.0.3.5)
+ actioncable (= 6.0.3.5)
+ actionmailbox (= 6.0.3.5)
+ actionmailer (= 6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actiontext (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
bundler (>= 1.3.0)
- railties (= 6.0.3.4)
+ railties (= 6.0.3.5)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.4)
- actionpack (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ railties (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -200,12 +207,14 @@ GEM
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
- ruby2_keywords (0.0.2)
+ ruby2_keywords (0.0.4)
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
+ sassc (2.4.0-x64-mingw32)
+ ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
@@ -237,8 +246,11 @@ GEM
ethon (>= 0.9.0)
tzinfo (1.2.7)
thread_safe (~> 0.1)
+ tzinfo-data (1.2019.3)
+ tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
+ wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -253,6 +265,7 @@ GEM
PLATFORMS
ruby
+ x64-mingw32
DEPENDENCIES
bootsnap (~> 1.4.5)
@@ -260,17 +273,17 @@ DEPENDENCIES
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
- docusign_click
+ docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
- omniauth-oauth2 (~> 1.6)
+ omniauth-oauth2 (~> 1.7.1)
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
puma (~> 4.3.3)
- rails (~> 6.0.3.3)
+ rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
spring (~> 2.1.0)
@@ -283,7 +296,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.1p83
+ ruby 2.7.2p137
BUNDLED WITH
2.1.4
From f280faaecc6549a55714f5b8dd8b7b607abbe19f Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:08:30 -0800
Subject: [PATCH 009/363] Update README.md
---
README.md | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)
diff --git a/README.md b/README.md
index ad77d74..14cd91e 100644
--- a/README.md
+++ b/README.md
@@ -275,6 +275,33 @@ When the token expires, it updates automatically.
From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
+## Troubleshooting Windows SSL issue
+When using the Ruby launcher on a Windows machine you may get the following error:
+
+SSL peer certificate or SSH remote key was not OK
+
+This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
+
+It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+
+Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
+
+C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\
+
+Find the relevant DocuSign Ruby SDK you are using. The name always starts with “docusign”; for instance, DocuSign Click SDK version 1.0.0:
+
+C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\docusign_click-1.0.0\lib\docusign_click
+
+Find the configuration.rb file in that folder.
+Modify the following two lines in the configuration.rb file, replacing “true” with “false”:
+
+ @verify_ssl = true
+ @verify_ssl_host = true
+
+
+Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
+
+
#### Payments code example
To use the payments example, create a
From 905fd23cee748ccd62baf0a9abec3b0acf428f21 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:10:14 -0800
Subject: [PATCH 010/363] Update README.md
---
README.md | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
index 14cd91e..944222c 100644
--- a/README.md
+++ b/README.md
@@ -275,14 +275,14 @@ When the token expires, it updates automatically.
From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
-## Troubleshooting Windows SSL issue
+### Troubleshooting Windows SSL issue
When using the Ruby launcher on a Windows machine you may get the following error:
-SSL peer certificate or SSH remote key was not OK
+**SSL peer certificate or SSH remote key was not OK**
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
-It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
@@ -292,8 +292,8 @@ Find the relevant DocuSign Ruby SDK you are using. The name always starts with
C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\docusign_click-1.0.0\lib\docusign_click
-Find the configuration.rb file in that folder.
-Modify the following two lines in the configuration.rb file, replacing “true” with “false”:
+Find the **configuration.rb** file in that folder.
+Modify the following two lines in the **configuration.rb** file, replacing “true” with “false”:
@verify_ssl = true
@verify_ssl_host = true
@@ -302,8 +302,7 @@ Modify the following two lines in the configuration.rb file, replacing “true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
-
-#### Payments code example
+### Payments code example
To use the payments example, create a
test payments gateway for your developer sandbox account.
@@ -313,7 +312,7 @@ file for instructions.
Then add the payment gateway account id to the **config/application.rb** file.
-## Using the examples with other authentication flows
+### Using the examples with other authentication flows
The examples in this repository can also be used with the
Implicit grant OAuth flow.
From fc584bd53a7f6e7e075aafa6c795b8eb2557b867 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:11:44 -0800
Subject: [PATCH 011/363] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 944222c..22a6010 100644
--- a/README.md
+++ b/README.md
@@ -282,7 +282,7 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
-**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.**
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
From 93e29e17bc6a238df46acc9ef167daf53b83cc92 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:12:53 -0800
Subject: [PATCH 012/363] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 22a6010..2f67c53 100644
--- a/README.md
+++ b/README.md
@@ -282,7 +282,7 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
-**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.**
+**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.**
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
From 485c8c2a74d44e131df64bf5dd4925b40f3073ab Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:15:05 -0800
Subject: [PATCH 013/363] Update README.md
---
README.md | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 2f67c53..c1aa97f 100644
--- a/README.md
+++ b/README.md
@@ -282,8 +282,9 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
-**It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.**
-
+```diff
+- It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+```
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\
From 810e3a01f01f60fd8be916bdbcefaadc6fa0e8cc Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:15:42 -0800
Subject: [PATCH 014/363] Update README.md
---
README.md | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md
index c1aa97f..c859bb7 100644
--- a/README.md
+++ b/README.md
@@ -283,7 +283,8 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
```diff
-- It is highly recommended that you don’t disable this security check in a production environment or in your integration. This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+- It is highly recommended that you don’t disable this security check in a production environment or in your integration.
+- This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
```
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
From 9239855accc394bbf270ee1050e577d45fd60a98 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:35:06 -0800
Subject: [PATCH 015/363] Update README.md
---
README.md | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index c859bb7..69a689b 100644
--- a/README.md
+++ b/README.md
@@ -283,8 +283,10 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
```diff
-- It is highly recommended that you don’t disable this security check in a production environment or in your integration.
-- This method is offered here solely as a means to enable you to develop quickly by lowering the security bar on your local machine.
+- It is highly recommended that you don’t disable this security check
+- in a production environment or in your integration.
+- This method is offered here solely as a means to enable you to
+- develop quickly by lowering the security bar on your local machine.
```
Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
From e24e5847fbcddf42ea1d60a4a9eaf333f958bc44 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:52:50 -0800
Subject: [PATCH 016/363] Update README.md
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 69a689b..09246a7 100644
--- a/README.md
+++ b/README.md
@@ -283,7 +283,7 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
```diff
-- It is highly recommended that you don’t disable this security check
+It is highly recommended that you don’t disable this security check
- in a production environment or in your integration.
- This method is offered here solely as a means to enable you to
- develop quickly by lowering the security bar on your local machine.
@@ -297,7 +297,7 @@ Find the relevant DocuSign Ruby SDK you are using. The name always starts with
C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\docusign_click-1.0.0\lib\docusign_click
Find the **configuration.rb** file in that folder.
-Modify the following two lines in the **configuration.rb** file, replacing “true” with “false”:
+Modify the following two lines in the **configuration.rb** file, replacing `“true”` with `“false”`:
@verify_ssl = true
@verify_ssl_host = true
From 8bb8d561e163477b59b20a5399608e62154e3503 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:53:39 -0800
Subject: [PATCH 017/363] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 09246a7..3385e56 100644
--- a/README.md
+++ b/README.md
@@ -283,7 +283,7 @@ When using the Ruby launcher on a Windows machine you may get the following erro
This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
```diff
-It is highly recommended that you don’t disable this security check
+- It is highly recommended that you don’t disable this security check
- in a production environment or in your integration.
- This method is offered here solely as a means to enable you to
- develop quickly by lowering the security bar on your local machine.
From ae393ddc30e871814847d5136c861b4b7a5a6e45 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 11:55:01 -0800
Subject: [PATCH 018/363] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 3385e56..3ce2384 100644
--- a/README.md
+++ b/README.md
@@ -297,7 +297,7 @@ Find the relevant DocuSign Ruby SDK you are using. The name always starts with
C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\docusign_click-1.0.0\lib\docusign_click
Find the **configuration.rb** file in that folder.
-Modify the following two lines in the **configuration.rb** file, replacing `“true”` with `“false”`:
+Modify the following two lines in the **configuration.rb** file, replacing `true` with `false`:
@verify_ssl = true
@verify_ssl_host = true
From 8f480673c4cc172f4cb8854f10a5a02c59bb3eb2 Mon Sep 17 00:00:00 2001
From: Inbar Gazit
Date: Thu, 4 Mar 2021 14:23:25 -0800
Subject: [PATCH 019/363] Updating README.md
---
README.md | 34 ++++++++++++++++++++++++++++++++--
1 file changed, 32 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index ad77d74..3ce2384 100644
--- a/README.md
+++ b/README.md
@@ -275,8 +275,38 @@ When the token expires, it updates automatically.
From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
+### Troubleshooting Windows SSL issue
+When using the Ruby launcher on a Windows machine you may get the following error:
-#### Payments code example
+**SSL peer certificate or SSH remote key was not OK**
+
+This error occurs because you’re attempting to use the Ruby launcher with a self-signed certificate or without SSL/HTTP security. The API calls from Ruby SDKs are using a built-in Curl tool that is enforcing the SSL requirement. You can disable this security check to run the launcher in an insecure manner on your developer machine.
+
+```diff
+- It is highly recommended that you don’t disable this security check
+- in a production environment or in your integration.
+- This method is offered here solely as a means to enable you to
+- develop quickly by lowering the security bar on your local machine.
+```
+Find the root folder for your Ruby gems (in this case, a 64-bit version of Ruby 2.7.0):
+
+C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\
+
+Find the relevant DocuSign Ruby SDK you are using. The name always starts with “docusign”; for instance, DocuSign Click SDK version 1.0.0:
+
+C:\Ruby27-x64\lib\ruby\gems\2.7.0\gems\docusign_click-1.0.0\lib\docusign_click
+
+Find the **configuration.rb** file in that folder.
+Modify the following two lines in the **configuration.rb** file, replacing `true` with `false`:
+
+ @verify_ssl = true
+ @verify_ssl_host = true
+
+
+Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
+
+
+### Payments code example
To use the payments example, create a
test payments gateway for your developer sandbox account.
@@ -286,7 +316,7 @@ file for instructions.
Then add the payment gateway account id to the **config/application.rb** file.
-## Using the examples with other authentication flows
+### Using the examples with other authentication flows
The examples in this repository can also be used with the
Implicit grant OAuth flow.
From 47f0a20a456b68478a500f49e2ca4e303772e706 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Tue, 30 Mar 2021 11:16:29 -0700
Subject: [PATCH 020/363] bundle install, Ruby 2.7.2
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 3ce2384..4092901 100644
--- a/README.md
+++ b/README.md
@@ -229,7 +229,7 @@ When the token expires, it updates automatically.
`http://localhost:3000/auth/docusign/callback`
-1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
+1. Ruby version 2.7.2 or later. Or you can update the Gemfile to use other versions of Ruby.
1. A name and email for a signer, and a name and email for a cc recipient.
### Installation steps
@@ -239,7 +239,7 @@ When the token expires, it updates automatically.
1. **cd code-examples-ruby**
1. Install the needed gems listed in the Gemfile:
- Run **bundler install**
+ Run **bundle install**
1. Copy the file **config/appsettings.example.yml** into a new file named **config/appsettings.yml**
1. Update the file **config/appsettings.yml** with the Integration Key and other settings.
Note: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing.
From ddcce26f551dd9b08ca5c8d9b189bad7275f60d3 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Fri, 9 Apr 2021 10:29:45 -0700
Subject: [PATCH 021/363] Update PAYMENTS_INSTALLATION.md
---
PAYMENTS_INSTALLATION.md | 33 +++++++++++++++------------------
1 file changed, 15 insertions(+), 18 deletions(-)
diff --git a/PAYMENTS_INSTALLATION.md b/PAYMENTS_INSTALLATION.md
index bfd85dc..d575c2c 100644
--- a/PAYMENTS_INSTALLATION.md
+++ b/PAYMENTS_INSTALLATION.md
@@ -1,24 +1,21 @@
-# Configuring a DocuSign payments gateway
+# Configure a payment gateway
-DocuSign offers built-in connections to multiple payment
-gateways. The payments example uses a demo account via the Stripe
-gateway service.
+DocuSign offers built-in connections to multiple payment gateways. The payments code example uses a developer account via the Stripe gateway service.
-## Creating the payments gateway account
-1. Login to demo.docusign.net and go to the Admin Tool.
-1. On the Integrations / Payments screen, click Stripe.
-1. For development, you can skip the Stripe account application
- by using the `Skip this account form` link:
+## Create a Stripe payment gateway
+
+1. Select the Stripe button on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account.
+
+1. For development, you can skip the Stripe account application by using the **Skip this account form** link at the top of the page.
+
+ 
+
+ An enabled Stripe payment gateway is now associated with your DocuSign developer account and is shown under **Payment Gateway**.
+
+1. Save the **Gateway Account ID** GUID to the code example launcher configuration file.
- 
-1. Next, the Admin Tool will show that an enabled Stripe
- payment gateway account has been associated with your
- DocuSign Developer account.
-1. Configure the example launcher with the gateway account id shown in the Admin tool.
## Additional documentation
-See the
-[Managing Payment Gateways](https://support.docusign.com/en/guides/managing-payment-gateways)
-documentation.
-
+* [Managing Payment Gateways](https://support.docusign.com/en/guides/managing-payment-gateways)
+* [How to send a request for payment](https://developers.docusign.com/docs/esign-rest-api/how-to/request-a-payment)
From f284dddce50b8ef0b200e13351029a5cb48c729c Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Fri, 9 Apr 2021 10:30:19 -0700
Subject: [PATCH 022/363] Update PAYMENTS_INSTALLATION.md
---
PAYMENTS_INSTALLATION.md | 33 +++++++++++++++------------------
1 file changed, 15 insertions(+), 18 deletions(-)
diff --git a/PAYMENTS_INSTALLATION.md b/PAYMENTS_INSTALLATION.md
index bfd85dc..d575c2c 100644
--- a/PAYMENTS_INSTALLATION.md
+++ b/PAYMENTS_INSTALLATION.md
@@ -1,24 +1,21 @@
-# Configuring a DocuSign payments gateway
+# Configure a payment gateway
-DocuSign offers built-in connections to multiple payment
-gateways. The payments example uses a demo account via the Stripe
-gateway service.
+DocuSign offers built-in connections to multiple payment gateways. The payments code example uses a developer account via the Stripe gateway service.
-## Creating the payments gateway account
-1. Login to demo.docusign.net and go to the Admin Tool.
-1. On the Integrations / Payments screen, click Stripe.
-1. For development, you can skip the Stripe account application
- by using the `Skip this account form` link:
+## Create a Stripe payment gateway
+
+1. Select the Stripe button on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account.
+
+1. For development, you can skip the Stripe account application by using the **Skip this account form** link at the top of the page.
+
+ 
+
+ An enabled Stripe payment gateway is now associated with your DocuSign developer account and is shown under **Payment Gateway**.
+
+1. Save the **Gateway Account ID** GUID to the code example launcher configuration file.
- 
-1. Next, the Admin Tool will show that an enabled Stripe
- payment gateway account has been associated with your
- DocuSign Developer account.
-1. Configure the example launcher with the gateway account id shown in the Admin tool.
## Additional documentation
-See the
-[Managing Payment Gateways](https://support.docusign.com/en/guides/managing-payment-gateways)
-documentation.
-
+* [Managing Payment Gateways](https://support.docusign.com/en/guides/managing-payment-gateways)
+* [How to send a request for payment](https://developers.docusign.com/docs/esign-rest-api/how-to/request-a-payment)
From 049f83a747341936513dbe4b169da102d25feab4 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 15:48:12 -0700
Subject: [PATCH 023/363] Update README.md
---
README.md | 37 +++++++++++++++++++++----------------
1 file changed, 21 insertions(+), 16 deletions(-)
diff --git a/README.md b/README.md
index 3ce2384..bbeca5f 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,7 @@
# Ruby Launcher Code Examples
-### Github repo: code-examples-ruby
+### Github repo: https://github.com/docusign/code-examples-ruby
+
This GitHub repo includes code examples for DocuSign APIs.
@@ -8,11 +9,13 @@ To switch between API code examples, modify the `examples_API` setting at the en
If none of the API types are set to true, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to true, only the first will be shown.
-**Note:** to use the Rooms API you must also [create your DocuSign Developer Account for Rooms](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
+**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
+
## Introduction
This repo is a Ruby on Rails application that demonstrates:
+
## eSignature API
For more information about the scopes used for obtaining authorization to use the eSignature API, see the [Required Scopes section](https://developers.docusign.com/docs/esign-rest-api/esign101/auth).
@@ -144,6 +147,7 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](app/services/e_sign/eg035_sms_delivery_service.rb)
This code example demonstrates how to send a signature request via an SMS message using the [Envelopes: create](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
+
## Rooms API
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
@@ -176,6 +180,7 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](./app/services/room_api/eg009_assign_form_to_form_group_service.rb)
This example assigns a form to a form group for your DocuSign Rooms.
+
## Click API
For more information about the scopes used for obtaining authorization to use the Clickwrap API, see the [Required Scopes section](https://developers.docusign.com/docs/click-api/click101/auth).
@@ -196,20 +201,18 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
[Source.](./app/services/clickwrap/eg005_clickwrap_responses_service.rb)
This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
-## Included OAuth grant types:
-* Authentication with Docusign via [Authorization Code Grant flow](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant) .
-When the token expires, the user is asked to re-authenticate.
-The **refresh token** is not used in this example.
+## Included OAuth grant types
+
+* Authentication with Docusign via [Authorization Code Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant). When the token expires, the user is asked to re-authenticate. The [refresh token](https://developers.docusign.com/platform/auth/authcode/authcode-get-token#using-refresh-tokens) is not used in this example.
-* Authentication with DocuSign via the [JSON Web Token (JWT) Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-jsonwebtoken).
-When the token expires, it updates automatically.
+* Authentication with DocuSign via [JSON Web Token (JWT) Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-jsonwebtoken). When the token expires, it updates automatically.
## Installation
### Prerequisites
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 1 and 2 below as they're automatically performed for you.**
+**Note:** If you downloaded this code using Quickstart from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
1. A DocuSign Developer account (email and password) on [demo.docusign.net](https://demo.docusign.net).
Create a [free account](https://go.docusign.com/sandbox/productshot/?elqCampaignId=16536).
@@ -232,6 +235,7 @@ When the token expires, it updates automatically.
1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
1. A name and email for a signer, and a name and email for a cc recipient.
+
### Installation steps
**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 4, 5, and 6 below as they're automatically performed for you.**
@@ -247,6 +251,7 @@ When the token expires, it updates automatically.
1. Update your Integration Key's settings to include a **Redirect URI** for
your installation of the example. See Prerequisites item #2, above for more information.
+
#### Run the application
1. To start the development web server and application:
@@ -259,6 +264,7 @@ When the token expires, it updates automatically.
- *Place libcurl.dll into Ruby `C:\\\bin`*
1. Open a browser to the example's base url to view the index page.
+
### Configuring JWT
**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
@@ -275,6 +281,7 @@ When the token expires, it updates automatically.
From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
+
### Troubleshooting Windows SSL issue
When using the Ruby launcher on a Windows machine you may get the following error:
@@ -306,7 +313,7 @@ Modify the following two lines in the **configuration.rb** file, replacing `true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
-### Payments code example
+## Payments code example
To use the payments example, create a
test payments gateway for your developer sandbox account.
@@ -316,6 +323,7 @@ file for instructions.
Then add the payment gateway account id to the **config/application.rb** file.
+
### Using the examples with other authentication flows
The examples in this repository can also be used with the
@@ -323,17 +331,14 @@ Implicit grant OAuth flow.
See the [Authentication guide](https://developers.docusign.com/esign-rest-api/guides/authentication)
for information on choosing the right authentication flow for your application.
+
## License and additional information
+
### License
This repository uses the MIT License. See the LICENSE file for more information.
+
### Pull Requests
Pull requests are welcomed. Pull requests will only be considered if their content
uses the MIT License.
-
-### Additional Resources
-* [DocuSign Developer Center](https://developers.docusign.com)
-* [DocuSign API on Twitter](https://twitter.com/docusignapi)
-* [DocuSign For Developers on LinkedIn](https://www.linkedin.com/showcase/docusign-for-developers/)
-* [DocuSign For Developers on YouTube](https://www.youtube.com/channel/UCJSJ2kMs_qeQotmw4-lX2NQ)
From 914070368e434bb2cb0d3b4a7924e9a12dc695c0 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 15:56:48 -0700
Subject: [PATCH 024/363] Update README.md
---
README.md | 36 ++++++++++++++++++++++--------------
1 file changed, 22 insertions(+), 14 deletions(-)
diff --git a/README.md b/README.md
index bbeca5f..53ec758 100644
--- a/README.md
+++ b/README.md
@@ -13,7 +13,7 @@ If none of the API types are set to true, the DocuSign eSignature REST API code
## Introduction
-This repo is a Ruby on Rails application that demonstrates:
+This repo is a Ruby on Rails application.
## eSignature API
@@ -214,26 +214,34 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
### Prerequisites
**Note:** If you downloaded this code using Quickstart from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
-1. A DocuSign Developer account (email and password) on [demo.docusign.net](https://demo.docusign.net).
- Create a [free account](https://go.docusign.com/sandbox/productshot/?elqCampaignId=16536).
-1. A DocuSign Integration Key and secret key (a client ID). To use JSON Web token, you will need the Integration Key itself, the RSA Secret Key and an API user ID for the user you are impersonating.
-
- You will need the **Integration Key** itself, and its **secret**.
+1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
+1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
- The Integration key must include a **Redirect URI** of
+ This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
- `{base_url}/auth/docusign/callback`
+ To use [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/), you will need an integration key and a secret key. See [Installation steps](#installation-steps) for details.
- Where `{base_url}` is the url for the web app.
+ To use [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you will need an integration key, an RSA key pair, and the API Username GUID of the impersonated user. See [Installation steps for JWT Grant authentication](#installation-steps-for-jwt-grant-authentication) for details.
- By default, the rails app starts on url `http://localhost:3000`
+ For both authentication flows:
- So the default Redirect URI for your Integration Key is
+ If you use this launcher on your own workstation, the integration key must include a redirect URI of
- `http://localhost:3000/auth/docusign/callback`
+ http://localhost:3000/auth/docusign/callback
-1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
-1. A name and email for a signer, and a name and email for a cc recipient.
+ If you host this launcher on a remote web server, set your redirect URI as
+
+ {base_url}/auth/docusign/callback
+
+ where {base_url} is the URL for the web app.
+
+1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later.
+ 1. Update the Gemfile to use later versions of Ruby.
+ 1. Windows x64 only:
+ 1. Ensure that your Ruby folder is appended with -x64, e.g. Ruby27-x64.
+ 2. Install Curl for Ruby: Download libcurl.dll
+ Save libcurl-x64.dll as libcurl.dll
+ Place libcurl.dll in your Ruby folder: C:\-x64\bin
### Installation steps
From 3ad307c7570067117e5793b4b94579c44a84d321 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 15:58:06 -0700
Subject: [PATCH 025/363] add line breaks
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 53ec758..17693e5 100644
--- a/README.md
+++ b/README.md
@@ -239,9 +239,9 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
1. Ensure that your Ruby folder is appended with -x64, e.g. Ruby27-x64.
- 2. Install Curl for Ruby: Download libcurl.dll
- Save libcurl-x64.dll as libcurl.dll
- Place libcurl.dll in your Ruby folder: C:\-x64\bin
+ 2. Install Curl for Ruby: Download libcurl.dll
+ Save libcurl-x64.dll as libcurl.dll
+ Place libcurl.dll in your Ruby folder: C:\-x64\bin
### Installation steps
From 09a3513a09d666f5b31aa903ef634940acf65b19 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:24:07 -0700
Subject: [PATCH 026/363] Update README.md
---
README.md | 109 +++++++++++++++++++++++-------------------------------
1 file changed, 46 insertions(+), 63 deletions(-)
diff --git a/README.md b/README.md
index 17693e5..e992b43 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ To switch between API code examples, modify the `examples_API` setting at the en
If none of the API types are set to true, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to true, only the first will be shown.
-**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
+**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
## Introduction
@@ -150,6 +150,8 @@ For more information about the scopes used for obtaining authorization to use th
## Rooms API
+**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
+
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
1. **Create a room with data.**
@@ -212,7 +214,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
## Installation
### Prerequisites
-**Note:** If you downloaded this code using Quickstart from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
@@ -239,55 +241,50 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
1. Ensure that your Ruby folder is appended with -x64, e.g. Ruby27-x64.
- 2. Install Curl for Ruby: Download libcurl.dll
+ 2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save libcurl-x64.dll as libcurl.dll
Place libcurl.dll in your Ruby folder: C:\-x64\bin
### Installation steps
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 4, 5, and 6 below as they're automatically performed for you.**
-
-1. Download or clone this repository to your workstation to directory **code-examples-ruby**
-1. **cd code-examples-ruby**
-1. Install the needed gems listed in the Gemfile:
-
- Run **bundler install**
-1. Copy the file **config/appsettings.example.yml** into a new file named **config/appsettings.yml**
-1. Update the file **config/appsettings.yml** with the Integration Key and other settings.
- Note: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing.
-
-1. Update your Integration Key's settings to include a **Redirect URI** for
- your installation of the example. See Prerequisites item #2, above for more information.
-
-
-#### Run the application
-1. To start the development web server and application:
-
- Run **rails s**
-
- *Note that on Windows additional actions might be necessary:*
- - *Install sqlite3: **gem install sqlite3 --platform=ruby***
- - *Download curllib.dll (https://curl.haxx.se/windows/)*
- - *libcurl-x64.dll should be copied as libcurl.dll*
- - *Place libcurl.dll into Ruby `C:\\\bin`*
-1. Open a browser to the example's base url to view the index page.
-
-
-### Configuring JWT
-
-**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
-
-1. Create a developer sandbox account on developers.docusign.com if you don't already have one.
-2. Create a new API key in the Admin panel: https://admindemo.docusign.com/api-integrator-key
- - Take note of the _Integration Key_.
- - Generate a _RSA Keypair_ and copy the private key to a secure location.
- - Set a _Redirect URI_ of `http://localhost:3000/auth/docusign/callback` as mentioned in the installation steps above.
-3. Create a new file in the config folder named **docusign_private_key.txt**, and paste in that copied RSA private key, then save it.
-4. Update the file **config/appsettings.yml** and include the settings from step 2.
-
-[Obtaining consent](https://developers.docusign.com/esign-rest-api/guides/authentication/obtaining-consent#individual-consent) does not need to be configured, as it is already being done in the code at [JwtAuth::JwtCreator#update_token](./app/services/jwt_auth/jwt_creator.rb#L35)
-
-From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip steps 4 as it was automatically performed for you.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch the the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
+ 1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+
+
+### Installation steps for JWT Grant authentication
+**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.
+Also, in order to select JSON Web Token authentication in the launcher, in config/appsettings.yml, change `quickstart` to `false`.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch the the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
+ 1. Generate an RSA key pair, if you don’t already have one. Under **Authentication**, select **+ GENERATE RSA**. Copy the private key and save it in a new file named config/docusign_private_key.txt.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
+
+1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
+1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
+1. Select your desired code example.
### Troubleshooting Windows SSL issue
@@ -322,29 +319,15 @@ Once this is complete, you can run your Ruby on Rails application again and you
## Payments code example
-To use the payments example, create a
-test payments gateway for your developer sandbox account.
+To use the payments code example, create a test payment gateway on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account. See [Configure a payment gateway](./PAYMENTS_INSTALLATION.md) for details.
-See the
-[PAYMENTS_INSTALLATION.md](./PAYMENTS_INSTALLATION.md)
-file for instructions.
-
-Then add the payment gateway account id to the **config/application.rb** file.
-
-
-### Using the examples with other authentication flows
-
-The examples in this repository can also be used with the
-Implicit grant OAuth flow.
-See the [Authentication guide](https://developers.docusign.com/esign-rest-api/guides/authentication)
-for information on choosing the right authentication flow for your application.
+Once you've created a payment gateway, save the **Gateway Account ID** GUID to appsettings.yml.
## License and additional information
-
### License
-This repository uses the MIT License. See the LICENSE file for more information.
+This repository uses the MIT License. See [LICENSE](./LICENSE) for details.
### Pull Requests
From feb192885dd1b8d48337ec6071923e3392ceeacf Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:26:16 -0700
Subject: [PATCH 027/363] edit Rooms line
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index e992b43..db6ff22 100644
--- a/README.md
+++ b/README.md
@@ -150,7 +150,7 @@ For more information about the scopes used for obtaining authorization to use th
## Rooms API
-**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
+**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
From abc125e26dbfe2180f8ab0989c44a013601d6bb4 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:27:59 -0700
Subject: [PATCH 028/363] deleted a section
---
README.md | 7 -------
1 file changed, 7 deletions(-)
diff --git a/README.md b/README.md
index db6ff22..53cd486 100644
--- a/README.md
+++ b/README.md
@@ -204,13 +204,6 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
-## Included OAuth grant types
-
-* Authentication with Docusign via [Authorization Code Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant). When the token expires, the user is asked to re-authenticate. The [refresh token](https://developers.docusign.com/platform/auth/authcode/authcode-get-token#using-refresh-tokens) is not used in this example.
-
-* Authentication with DocuSign via [JSON Web Token (JWT) Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-jsonwebtoken). When the token expires, it updates automatically.
-
-
## Installation
### Prerequisites
From 3ff507fc670359c4aa139da1d09c36cb6a22b920 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:31:44 -0700
Subject: [PATCH 029/363] bold UI items
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 53cd486..d03f8ef 100644
--- a/README.md
+++ b/README.md
@@ -233,10 +233,10 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later.
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
- 1. Ensure that your Ruby folder is appended with -x64, e.g. Ruby27-x64.
+ 1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**.
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
- Save libcurl-x64.dll as libcurl.dll
- Place libcurl.dll in your Ruby folder: C:\-x64\bin
+ Save **libcurl-x64.dll** as **libcurl.dll**
+ Place **libcurl.dll** in your Ruby folder: **C:\-x64\bin**
### Installation steps
From 6f4a414337dc4c4ebfd2c292afc6a97f10b856c2 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:32:30 -0700
Subject: [PATCH 030/363] add line breaks
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index d03f8ef..7aefc3b 100644
--- a/README.md
+++ b/README.md
@@ -234,9 +234,9 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**.
- 2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
- Save **libcurl-x64.dll** as **libcurl.dll**
- Place **libcurl.dll** in your Ruby folder: **C:\-x64\bin**
+ 2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
+ Save **libcurl-x64.dll** as **libcurl.dll**
+ Place **libcurl.dll** in your Ruby folder: **C:\-x64\bin**
### Installation steps
From d7bf3efe4a3ef1ce6c76a0844e56c9c58943b5be Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:33:43 -0700
Subject: [PATCH 031/363] remove period
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 7aefc3b..ae57ec4 100644
--- a/README.md
+++ b/README.md
@@ -233,7 +233,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later.
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
- 1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**.
+ 1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save **libcurl-x64.dll** as **libcurl.dll**
Place **libcurl.dll** in your Ruby folder: **C:\-x64\bin**
From 0fd6822992ed346f77d26e4d213bba8a6cdcb53b Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:34:41 -0700
Subject: [PATCH 032/363] remove line break
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index ae57ec4..6f5773e 100644
--- a/README.md
+++ b/README.md
@@ -230,7 +230,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
where {base_url} is the URL for the web app.
-1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later.
+1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
From a2142d8a371ac20d7d8c4c2b8bfa5428dd007f18 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:36:49 -0700
Subject: [PATCH 033/363] sample Ruby folder
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 6f5773e..935d45a 100644
--- a/README.md
+++ b/README.md
@@ -236,7 +236,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save **libcurl-x64.dll** as **libcurl.dll**
- Place **libcurl.dll** in your Ruby folder: **C:\-x64\bin**
+ Place **libcurl.dll** in your Ruby folder, e.g. **Ruby27-x64**
### Installation steps
From 880a4a762fd50c1b7e0a985fc8f9e0cbd17d3d1a Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:39:06 -0700
Subject: [PATCH 034/363] add backslash
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 935d45a..c7ca59e 100644
--- a/README.md
+++ b/README.md
@@ -236,7 +236,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save **libcurl-x64.dll** as **libcurl.dll**
- Place **libcurl.dll** in your Ruby folder, e.g. **Ruby27-x64**
+ Place **libcurl.dll** in your Ruby folder, e.g. **C:"\Ruby27-x64**
### Installation steps
From 57269ff086aaa079f8891716988e5065542d7d66 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:40:07 -0700
Subject: [PATCH 035/363] add bin
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index c7ca59e..12950ac 100644
--- a/README.md
+++ b/README.md
@@ -236,7 +236,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save **libcurl-x64.dll** as **libcurl.dll**
- Place **libcurl.dll** in your Ruby folder, e.g. **C:"\Ruby27-x64**
+ Place **libcurl.dll** in your Ruby folder, e.g. **C:\Ruby27-x64\bin**
### Installation steps
From 29086f15358aaccf52ef63e208ba22cc001c040a Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:41:22 -0700
Subject: [PATCH 036/363] step
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 12950ac..7d761f8 100644
--- a/README.md
+++ b/README.md
@@ -240,7 +240,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
### Installation steps
-**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip steps 4 as it was automatically performed for you.
+**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.
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch the the folder:
From f6e479abadb0247df99c39df53c5757dc1350b6e Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:43:06 -0700
Subject: [PATCH 037/363] to
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 7d761f8..e82d232 100644
--- a/README.md
+++ b/README.md
@@ -243,7 +243,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
**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.
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
-1. In your command-line environment, switch the the folder:
+1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundle install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
@@ -261,7 +261,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
Also, in order to select JSON Web Token authentication in the launcher, in config/appsettings.yml, change `quickstart` to `false`.
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
-1. In your command-line environment, switch the the folder:
+1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundle install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
From d096689608d0a75fcde42ca4e41e3f06ee567af8 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:56:35 -0700
Subject: [PATCH 038/363] small updates
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index e82d232..53f80fb 100644
--- a/README.md
+++ b/README.md
@@ -5,11 +5,11 @@
This GitHub repo includes code examples for DocuSign APIs.
-To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to true and set the remaining to false.
+To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
-If none of the API types are set to true, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to true, only the first will be shown.
+If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
-**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
+Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
## Introduction
From 339fa3f181bff25e566651054e7af27814018827 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:58:02 -0700
Subject: [PATCH 039/363] added JWT link
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 53f80fb..698aaa2 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ To switch between API code examples, modify the `examples_API` setting at the en
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
-Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
+Before you can make any API calls using [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
## Introduction
From 46ff4068e7d509dc4ae453dfa3a6ce0fca483fe6 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 16:59:05 -0700
Subject: [PATCH 040/363] remove line break
---
README.md | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 698aaa2..9cc9ab3 100644
--- a/README.md
+++ b/README.md
@@ -150,8 +150,7 @@ For more information about the scopes used for obtaining authorization to use th
## Rooms API
-**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
-
+**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
1. **Create a room with data.**
From a42956a42dd2d86823487d4ff6788b82e1964713 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 17:05:46 -0700
Subject: [PATCH 041/363] synced with private
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 4092901..3ce2384 100644
--- a/README.md
+++ b/README.md
@@ -229,7 +229,7 @@ When the token expires, it updates automatically.
`http://localhost:3000/auth/docusign/callback`
-1. Ruby version 2.7.2 or later. Or you can update the Gemfile to use other versions of Ruby.
+1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
1. A name and email for a signer, and a name and email for a cc recipient.
### Installation steps
@@ -239,7 +239,7 @@ When the token expires, it updates automatically.
1. **cd code-examples-ruby**
1. Install the needed gems listed in the Gemfile:
- Run **bundle install**
+ Run **bundler install**
1. Copy the file **config/appsettings.example.yml** into a new file named **config/appsettings.yml**
1. Update the file **config/appsettings.yml** with the Integration Key and other settings.
Note: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing.
From 55d22d57e2448d50ed38e0e3e4adcdf520aca5be Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 17:07:55 -0700
Subject: [PATCH 042/363] synced with private
---
README.md | 166 +++++++++++++++++++++++++-----------------------------
1 file changed, 77 insertions(+), 89 deletions(-)
diff --git a/README.md b/README.md
index 3ce2384..9cc9ab3 100644
--- a/README.md
+++ b/README.md
@@ -1,17 +1,20 @@
# Ruby Launcher Code Examples
-### Github repo: code-examples-ruby
+### Github repo: https://github.com/docusign/code-examples-ruby
+
This GitHub repo includes code examples for DocuSign APIs.
-To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to true and set the remaining to false.
+To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
+
+If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
-If none of the API types are set to true, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to true, only the first will be shown.
+Before you can make any API calls using [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
-**Note:** to use the Rooms API you must also [create your DocuSign Developer Account for Rooms](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
## Introduction
-This repo is a Ruby on Rails application that demonstrates:
+This repo is a Ruby on Rails application.
+
## eSignature API
@@ -144,8 +147,10 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](app/services/e_sign/eg035_sms_delivery_service.rb)
This code example demonstrates how to send a signature request via an SMS message using the [Envelopes: create](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
+
## Rooms API
+**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
1. **Create a room with data.**
@@ -176,6 +181,7 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](./app/services/room_api/eg009_assign_form_to_form_group_service.rb)
This example assigns a form to a form group for your DocuSign Rooms.
+
## Click API
For more information about the scopes used for obtaining authorization to use the Clickwrap API, see the [Required Scopes section](https://developers.docusign.com/docs/click-api/click101/auth).
@@ -196,84 +202,82 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
[Source.](./app/services/clickwrap/eg005_clickwrap_responses_service.rb)
This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
-## Included OAuth grant types:
-
-* Authentication with Docusign via [Authorization Code Grant flow](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant) .
-When the token expires, the user is asked to re-authenticate.
-The **refresh token** is not used in this example.
-
-* Authentication with DocuSign via the [JSON Web Token (JWT) Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-jsonwebtoken).
-When the token expires, it updates automatically.
-
## Installation
### Prerequisites
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 1 and 2 below as they're automatically performed for you.**
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
-1. A DocuSign Developer account (email and password) on [demo.docusign.net](https://demo.docusign.net).
- Create a [free account](https://go.docusign.com/sandbox/productshot/?elqCampaignId=16536).
-1. A DocuSign Integration Key and secret key (a client ID). To use JSON Web token, you will need the Integration Key itself, the RSA Secret Key and an API user ID for the user you are impersonating.
-
- You will need the **Integration Key** itself, and its **secret**.
+1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
+1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
- The Integration key must include a **Redirect URI** of
+ This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
- `{base_url}/auth/docusign/callback`
+ To use [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/), you will need an integration key and a secret key. See [Installation steps](#installation-steps) for details.
- Where `{base_url}` is the url for the web app.
+ To use [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you will need an integration key, an RSA key pair, and the API Username GUID of the impersonated user. See [Installation steps for JWT Grant authentication](#installation-steps-for-jwt-grant-authentication) for details.
- By default, the rails app starts on url `http://localhost:3000`
+ For both authentication flows:
- So the default Redirect URI for your Integration Key is
-
- `http://localhost:3000/auth/docusign/callback`
-
-1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
-1. A name and email for a signer, and a name and email for a cc recipient.
-
-### Installation steps
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 4, 5, and 6 below as they're automatically performed for you.**
-
-1. Download or clone this repository to your workstation to directory **code-examples-ruby**
-1. **cd code-examples-ruby**
-1. Install the needed gems listed in the Gemfile:
+ If you use this launcher on your own workstation, the integration key must include a redirect URI of
- Run **bundler install**
-1. Copy the file **config/appsettings.example.yml** into a new file named **config/appsettings.yml**
-1. Update the file **config/appsettings.yml** with the Integration Key and other settings.
- Note: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing.
+ http://localhost:3000/auth/docusign/callback
-1. Update your Integration Key's settings to include a **Redirect URI** for
- your installation of the example. See Prerequisites item #2, above for more information.
-
-#### Run the application
-1. To start the development web server and application:
-
- Run **rails s**
-
- *Note that on Windows additional actions might be necessary:*
- - *Install sqlite3: **gem install sqlite3 --platform=ruby***
- - *Download curllib.dll (https://curl.haxx.se/windows/)*
- - *libcurl-x64.dll should be copied as libcurl.dll*
- - *Place libcurl.dll into Ruby `C:\\\bin`*
-1. Open a browser to the example's base url to view the index page.
-
-### Configuring JWT
-
-**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
+ If you host this launcher on a remote web server, set your redirect URI as
+
+ {base_url}/auth/docusign/callback
+
+ where {base_url} is the URL for the web app.
+
+1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later
+ 1. Update the Gemfile to use later versions of Ruby.
+ 1. Windows x64 only:
+ 1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
+ 2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
+ Save **libcurl-x64.dll** as **libcurl.dll**
+ Place **libcurl.dll** in your Ruby folder, e.g. **C:\Ruby27-x64\bin**
-1. Create a developer sandbox account on developers.docusign.com if you don't already have one.
-2. Create a new API key in the Admin panel: https://admindemo.docusign.com/api-integrator-key
- - Take note of the _Integration Key_.
- - Generate a _RSA Keypair_ and copy the private key to a secure location.
- - Set a _Redirect URI_ of `http://localhost:3000/auth/docusign/callback` as mentioned in the installation steps above.
-3. Create a new file in the config folder named **docusign_private_key.txt**, and paste in that copied RSA private key, then save it.
-4. Update the file **config/appsettings.yml** and include the settings from step 2.
-[Obtaining consent](https://developers.docusign.com/esign-rest-api/guides/authentication/obtaining-consent#individual-consent) does not need to be configured, as it is already being done in the code at [JwtAuth::JwtCreator#update_token](./app/services/jwt_auth/jwt_creator.rb#L35)
+### Installation steps
+**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.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch to the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
+ 1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+
+
+### Installation steps for JWT Grant authentication
+**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.
+Also, in order to select JSON Web Token authentication in the launcher, in config/appsettings.yml, change `quickstart` to `false`.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch to the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
+ 1. Generate an RSA key pair, if you don’t already have one. Under **Authentication**, select **+ GENERATE RSA**. Copy the private key and save it in a new file named config/docusign_private_key.txt.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
+
+1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
+1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
+1. Select your desired code example.
-From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
### Troubleshooting Windows SSL issue
When using the Ruby launcher on a Windows machine you may get the following error:
@@ -306,34 +310,18 @@ Modify the following two lines in the **configuration.rb** file, replacing `true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
-### Payments code example
-To use the payments example, create a
-test payments gateway for your developer sandbox account.
-
-See the
-[PAYMENTS_INSTALLATION.md](./PAYMENTS_INSTALLATION.md)
-file for instructions.
+## Payments code example
+To use the payments code example, create a test payment gateway on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account. See [Configure a payment gateway](./PAYMENTS_INSTALLATION.md) for details.
-Then add the payment gateway account id to the **config/application.rb** file.
+Once you've created a payment gateway, save the **Gateway Account ID** GUID to appsettings.yml.
-### Using the examples with other authentication flows
-
-The examples in this repository can also be used with the
-Implicit grant OAuth flow.
-See the [Authentication guide](https://developers.docusign.com/esign-rest-api/guides/authentication)
-for information on choosing the right authentication flow for your application.
## License and additional information
### License
-This repository uses the MIT License. See the LICENSE file for more information.
+This repository uses the MIT License. See [LICENSE](./LICENSE) for details.
+
### Pull Requests
Pull requests are welcomed. Pull requests will only be considered if their content
uses the MIT License.
-
-### Additional Resources
-* [DocuSign Developer Center](https://developers.docusign.com)
-* [DocuSign API on Twitter](https://twitter.com/docusignapi)
-* [DocuSign For Developers on LinkedIn](https://www.linkedin.com/showcase/docusign-for-developers/)
-* [DocuSign For Developers on YouTube](https://www.youtube.com/channel/UCJSJ2kMs_qeQotmw4-lX2NQ)
From 4f68c84ea91b8b5b7d950dd8899b85fa4febc2a3 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 12 Apr 2021 17:10:07 -0700
Subject: [PATCH 043/363] sync with private
---
README.md | 3 ---
1 file changed, 3 deletions(-)
diff --git a/README.md b/README.md
index 9cc9ab3..a199fea 100644
--- a/README.md
+++ b/README.md
@@ -2,9 +2,6 @@
### Github repo: https://github.com/docusign/code-examples-ruby
-
-This GitHub repo includes code examples for DocuSign APIs.
-
To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
From 1992a3ab396cf60931837c159b6251a5445ada4b Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 14 Apr 2021 12:08:29 -0700
Subject: [PATCH 044/363] fix JWT redirect_uri and add state (#21)
---
Gemfile | 12 +-
Gemfile.lock | 139 +++++++++++-------------
app/controllers/ds_common_controller.rb | 3 +-
app/services/jwt_auth/jwt_creator.rb | 8 +-
4 files changed, 74 insertions(+), 88 deletions(-)
diff --git a/Gemfile b/Gemfile
index 89d7d58..4ed9224 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,12 +1,12 @@
- # frozen_string_literal: true
+# frozen_string_literal: true
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.2'
+ruby '2.7.1'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.5'
+gem 'rails', '~> 6.0.3.3'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
@@ -64,10 +64,10 @@ end
gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click', '~> 1.0.0'
-gem 'omniauth-oauth2', '~> 1.7.1'
+gem 'docusign_click'
+gem 'omniauth-oauth2', '~> 1.6'
gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
-gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
+gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
diff --git a/Gemfile.lock b/Gemfile.lock
index d84c396..0dac2dc 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.5)
- actionpack (= 6.0.3.5)
+ actioncable (6.0.3.4)
+ actionpack (= 6.0.3.4)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionmailbox (6.0.3.4)
+ actionpack (= 6.0.3.4)
+ activejob (= 6.0.3.4)
+ activerecord (= 6.0.3.4)
+ activestorage (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
mail (>= 2.7.1)
- actionmailer (6.0.3.5)
- actionpack (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
+ actionmailer (6.0.3.4)
+ actionpack (= 6.0.3.4)
+ actionview (= 6.0.3.4)
+ activejob (= 6.0.3.4)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.5)
- actionview (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionpack (6.0.3.4)
+ actionview (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.5)
- actionpack (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actiontext (6.0.3.4)
+ actionpack (= 6.0.3.4)
+ activerecord (= 6.0.3.4)
+ activestorage (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
nokogiri (>= 1.8.5)
- actionview (6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionview (6.0.3.4)
+ activesupport (= 6.0.3.4)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.5)
- activesupport (= 6.0.3.5)
+ activejob (6.0.3.4)
+ activesupport (= 6.0.3.4)
globalid (>= 0.3.6)
- activemodel (6.0.3.5)
- activesupport (= 6.0.3.5)
- activerecord (6.0.3.5)
- activemodel (= 6.0.3.5)
- activesupport (= 6.0.3.5)
- activestorage (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
+ activemodel (6.0.3.4)
+ activesupport (= 6.0.3.4)
+ activerecord (6.0.3.4)
+ activemodel (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
+ activestorage (6.0.3.4)
+ actionpack (= 6.0.3.4)
+ activejob (= 6.0.3.4)
+ activerecord (= 6.0.3.4)
marcel (~> 0.3.1)
- activesupport (6.0.3.5)
+ activesupport (6.0.3.4)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -87,8 +87,7 @@ GEM
coffee-script-source (1.12.2)
concurrent-ruby (1.1.7)
crass (1.0.6)
- docusign_click (1.0.0)
- addressable (~> 2.7, >= 2.7.0)
+ docusign_click (1.0.0.beta2)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -104,13 +103,10 @@ GEM
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.3.0)
- faraday-net_http (~> 1.0)
+ faraday (1.1.0)
multipart-post (>= 1.2, < 3)
ruby2_keywords
- faraday-net_http (1.0.1)
ffi (1.13.1)
- ffi (1.13.1-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
@@ -134,19 +130,15 @@ GEM
method_source (0.9.2)
mimemagic (0.3.5)
mini_mime (1.0.2)
- mini_portile2 (2.5.0)
+ mini_portile2 (2.4.0)
minitest (5.14.2)
msgpack (1.3.3)
- msgpack (1.3.3-x64-mingw32)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.4)
- nokogiri (1.11.1)
- mini_portile2 (~> 2.5.0)
- racc (~> 1.4)
- nokogiri (1.11.1-x64-mingw32)
- racc (~> 1.4)
+ nokogiri (1.10.10)
+ mini_portile2 (~> 2.4.0)
oauth2 (1.4.4)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -156,9 +148,9 @@ GEM
omniauth (1.9.1)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
- omniauth-oauth2 (1.7.1)
+ omniauth-oauth2 (1.7.0)
oauth2 (~> 1.4)
- omniauth (>= 1.9, < 3)
+ omniauth (~> 1.9)
omniauth-rails_csrf_protection (0.1.2)
actionpack (>= 4.2)
omniauth (>= 1.3.1)
@@ -172,33 +164,32 @@ GEM
public_suffix (4.0.6)
puma (4.3.6)
nio4r (~> 2.0)
- racc (1.5.2)
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.5)
- actioncable (= 6.0.3.5)
- actionmailbox (= 6.0.3.5)
- actionmailer (= 6.0.3.5)
- actionpack (= 6.0.3.5)
- actiontext (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activemodel (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ rails (6.0.3.4)
+ actioncable (= 6.0.3.4)
+ actionmailbox (= 6.0.3.4)
+ actionmailer (= 6.0.3.4)
+ actionpack (= 6.0.3.4)
+ actiontext (= 6.0.3.4)
+ actionview (= 6.0.3.4)
+ activejob (= 6.0.3.4)
+ activemodel (= 6.0.3.4)
+ activerecord (= 6.0.3.4)
+ activestorage (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
bundler (>= 1.3.0)
- railties (= 6.0.3.5)
+ railties (= 6.0.3.4)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.5)
- actionpack (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ railties (6.0.3.4)
+ actionpack (= 6.0.3.4)
+ activesupport (= 6.0.3.4)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -207,14 +198,12 @@ GEM
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
- ruby2_keywords (0.0.4)
+ ruby2_keywords (0.0.2)
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
- sassc (2.4.0-x64-mingw32)
- ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
@@ -246,11 +235,8 @@ GEM
ethon (>= 0.9.0)
tzinfo (1.2.7)
thread_safe (~> 0.1)
- tzinfo-data (1.2019.3)
- tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
- wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -265,7 +251,6 @@ GEM
PLATFORMS
ruby
- x64-mingw32
DEPENDENCIES
bootsnap (~> 1.4.5)
@@ -273,17 +258,17 @@ DEPENDENCIES
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
- docusign_click (~> 1.0.0)
+ docusign_click
docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
- omniauth-oauth2 (~> 1.7.1)
+ omniauth-oauth2 (~> 1.6)
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
puma (~> 4.3.3)
- rails (~> 6.0.3.5)
+ rails (~> 6.0.3.3)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
spring (~> 2.1.0)
@@ -296,7 +281,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.2p137
+ ruby 2.7.1p83
BUNDLED WITH
2.1.4
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 9d366c4..26e4e7b 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -44,7 +44,8 @@ def ds_must_authenticate
url = root_path
end
else
- url = JwtAuth::JwtCreator.consent_url
+ session['omniauth.state'] = SecureRandom.hex
+ url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
redirect_to root_path if session[:token].present?
end
if Rails.configuration.examples_API['Rooms'] == true
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index dae03df..e3e6bb7 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -4,12 +4,12 @@ module JwtAuth
class JwtCreator
include ApiCreator
- attr_reader :session, :api_client
+ attr_reader :session, :api_client, :state
# DocuSign authorization URI to obtain individual consent
# https://developers.docusign.com/platform/auth/jwt/jwt-get-token
# https://developers.docusign.com/platform/auth/consent/obtaining-individual-consent/
- def self.consent_url
+ def self.consent_url(state)
# GET /oauth/auth
# This endpoint is used to obtain consent and is the first step in several authentication flows.
# https://developers.docusign.com/platform/auth/reference/obtain-consent
@@ -24,8 +24,8 @@ def self.consent_url
response_type = "code"
scopes = ERB::Util.url_encode(scope) # https://developers.docusign.com/platform/auth/reference/scopes/
client_id = Rails.configuration.jwt_integration_key
- redirect_uri = Rails.configuration.app_url
- consent_url = "#{base_uri}?response_type=#{response_type}&scope=#{scopes}&client_id=#{client_id}&redirect_uri=#{redirect_uri}"
+ redirect_uri = "#{Rails.configuration.app_url}/auth/docusign/callback"
+ consent_url = "#{base_uri}?response_type=#{response_type}&scope=#{scopes}&client_id=#{client_id}&state=#{state}&redirect_uri=#{redirect_uri}"
Rails.logger.info "==> Obtain Consent Grant required: #{consent_url}"
consent_url
end
From f3d7d9f25ac4a0aa295952290ff45caede6eb957 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Wed, 14 Apr 2021 19:10:02 +0000
Subject: [PATCH 045/363] Bump nokogiri from 1.10.10 to 1.11.3
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.3.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.3)
Signed-off-by: dependabot[bot]
---
Gemfile.lock | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/Gemfile.lock b/Gemfile.lock
index 0dac2dc..3f16e3f 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -128,17 +128,20 @@ GEM
marcel (0.3.3)
mimemagic (~> 0.3.2)
method_source (0.9.2)
- mimemagic (0.3.5)
+ mimemagic (0.3.10)
+ nokogiri (~> 1)
+ rake
mini_mime (1.0.2)
- mini_portile2 (2.4.0)
+ mini_portile2 (2.5.0)
minitest (5.14.2)
msgpack (1.3.3)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.4)
- nokogiri (1.10.10)
- mini_portile2 (~> 2.4.0)
+ nokogiri (1.11.3)
+ mini_portile2 (~> 2.5.0)
+ racc (~> 1.4)
oauth2 (1.4.4)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -164,6 +167,7 @@ GEM
public_suffix (4.0.6)
puma (4.3.6)
nio4r (~> 2.0)
+ racc (1.5.2)
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
From 4bedbb28d0071b467ec5224898805ddd3fcfd8c0 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Wed, 14 Apr 2021 12:23:50 -0700
Subject: [PATCH 046/363] removed note about broken jwt
---
README.md | 2 --
1 file changed, 2 deletions(-)
diff --git a/README.md b/README.md
index a199fea..7930541 100644
--- a/README.md
+++ b/README.md
@@ -269,8 +269,6 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
1. Open a browser to http://localhost:3000/auth/docusign
-**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
-
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
From 2e617059ace5a024d2041a1def82415d61ce2fd5 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 15 Apr 2021 11:33:32 -0700
Subject: [PATCH 047/363] small edit
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 9cc9ab3..bad8eb9 100644
--- a/README.md
+++ b/README.md
@@ -209,7 +209,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
-1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
+1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
@@ -232,7 +232,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later
1. Update the Gemfile to use later versions of Ruby.
1. Windows x64 only:
- 1. Ensure that your Ruby folder is appended with -x64, e.g. **Ruby27-x64**
+ 1. Ensure that your Ruby folder is appended with **-x64**, e.g. **Ruby27-x64**
2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
Save **libcurl-x64.dll** as **libcurl.dll**
Place **libcurl.dll** in your Ruby folder, e.g. **C:\Ruby27-x64\bin**
From 1abef8c6cb37b295de973b533a402e7729592573 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 15 Apr 2021 11:35:16 -0700
Subject: [PATCH 048/363] sync with private
---
README.md | 166 +++++++++++++++++++++++++-----------------------------
1 file changed, 77 insertions(+), 89 deletions(-)
diff --git a/README.md b/README.md
index 3ce2384..bad8eb9 100644
--- a/README.md
+++ b/README.md
@@ -1,17 +1,20 @@
# Ruby Launcher Code Examples
-### Github repo: code-examples-ruby
+### Github repo: https://github.com/docusign/code-examples-ruby
+
This GitHub repo includes code examples for DocuSign APIs.
-To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to true and set the remaining to false.
+To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
+
+If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
-If none of the API types are set to true, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to true, only the first will be shown.
+Before you can make any API calls using [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
-**Note:** to use the Rooms API you must also [create your DocuSign Developer Account for Rooms](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
## Introduction
-This repo is a Ruby on Rails application that demonstrates:
+This repo is a Ruby on Rails application.
+
## eSignature API
@@ -144,8 +147,10 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](app/services/e_sign/eg035_sms_delivery_service.rb)
This code example demonstrates how to send a signature request via an SMS message using the [Envelopes: create](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
+
## Rooms API
+**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
1. **Create a room with data.**
@@ -176,6 +181,7 @@ For more information about the scopes used for obtaining authorization to use th
[Source.](./app/services/room_api/eg009_assign_form_to_form_group_service.rb)
This example assigns a form to a form group for your DocuSign Rooms.
+
## Click API
For more information about the scopes used for obtaining authorization to use the Clickwrap API, see the [Required Scopes section](https://developers.docusign.com/docs/click-api/click101/auth).
@@ -196,84 +202,82 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
[Source.](./app/services/clickwrap/eg005_clickwrap_responses_service.rb)
This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
-## Included OAuth grant types:
-
-* Authentication with Docusign via [Authorization Code Grant flow](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-code-grant) .
-When the token expires, the user is asked to re-authenticate.
-The **refresh token** is not used in this example.
-
-* Authentication with DocuSign via the [JSON Web Token (JWT) Grant](https://developers.docusign.com/esign-rest-api/guides/authentication/oauth2-jsonwebtoken).
-When the token expires, it updates automatically.
-
## Installation
### Prerequisites
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 1 and 2 below as they're automatically performed for you.**
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
-1. A DocuSign Developer account (email and password) on [demo.docusign.net](https://demo.docusign.net).
- Create a [free account](https://go.docusign.com/sandbox/productshot/?elqCampaignId=16536).
-1. A DocuSign Integration Key and secret key (a client ID). To use JSON Web token, you will need the Integration Key itself, the RSA Secret Key and an API user ID for the user you are impersonating.
-
- You will need the **Integration Key** itself, and its **secret**.
+1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
+1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
- The Integration key must include a **Redirect URI** of
+ This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
- `{base_url}/auth/docusign/callback`
+ To use [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/), you will need an integration key and a secret key. See [Installation steps](#installation-steps) for details.
- Where `{base_url}` is the url for the web app.
+ To use [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you will need an integration key, an RSA key pair, and the API Username GUID of the impersonated user. See [Installation steps for JWT Grant authentication](#installation-steps-for-jwt-grant-authentication) for details.
- By default, the rails app starts on url `http://localhost:3000`
+ For both authentication flows:
- So the default Redirect URI for your Integration Key is
-
- `http://localhost:3000/auth/docusign/callback`
-
-1. Ruby version 2.7.1 or later. Or you can update the Gemfile to use other versions of Ruby.
-1. A name and email for a signer, and a name and email for a cc recipient.
-
-### Installation steps
-**Note: If you downloaded this code using Quickstart from the DocuSign Developer Center, skip steps 4, 5, and 6 below as they're automatically performed for you.**
-
-1. Download or clone this repository to your workstation to directory **code-examples-ruby**
-1. **cd code-examples-ruby**
-1. Install the needed gems listed in the Gemfile:
+ If you use this launcher on your own workstation, the integration key must include a redirect URI of
- Run **bundler install**
-1. Copy the file **config/appsettings.example.yml** into a new file named **config/appsettings.yml**
-1. Update the file **config/appsettings.yml** with the Integration Key and other settings.
- Note: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing.
+ http://localhost:3000/auth/docusign/callback
-1. Update your Integration Key's settings to include a **Redirect URI** for
- your installation of the example. See Prerequisites item #2, above for more information.
-
-#### Run the application
-1. To start the development web server and application:
-
- Run **rails s**
-
- *Note that on Windows additional actions might be necessary:*
- - *Install sqlite3: **gem install sqlite3 --platform=ruby***
- - *Download curllib.dll (https://curl.haxx.se/windows/)*
- - *libcurl-x64.dll should be copied as libcurl.dll*
- - *Place libcurl.dll into Ruby `C:\\\bin`*
-1. Open a browser to the example's base url to view the index page.
-
-### Configuring JWT
-
-**Note:** Before you can make any API calls using JWT Grant, you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
+ If you host this launcher on a remote web server, set your redirect URI as
+
+ {base_url}/auth/docusign/callback
+
+ where {base_url} is the URL for the web app.
+
+1. [Ruby version 2.7.2](https://www.ruby-lang.org/en/downloads/) or later
+ 1. Update the Gemfile to use later versions of Ruby.
+ 1. Windows x64 only:
+ 1. Ensure that your Ruby folder is appended with **-x64**, e.g. **Ruby27-x64**
+ 2. Install Curl for Ruby: [Download libcurl.dll](https://curl.haxx.se/windows/)
+ Save **libcurl-x64.dll** as **libcurl.dll**
+ Place **libcurl.dll** in your Ruby folder, e.g. **C:\Ruby27-x64\bin**
-1. Create a developer sandbox account on developers.docusign.com if you don't already have one.
-2. Create a new API key in the Admin panel: https://admindemo.docusign.com/api-integrator-key
- - Take note of the _Integration Key_.
- - Generate a _RSA Keypair_ and copy the private key to a secure location.
- - Set a _Redirect URI_ of `http://localhost:3000/auth/docusign/callback` as mentioned in the installation steps above.
-3. Create a new file in the config folder named **docusign_private_key.txt**, and paste in that copied RSA private key, then save it.
-4. Update the file **config/appsettings.yml** and include the settings from step 2.
-[Obtaining consent](https://developers.docusign.com/esign-rest-api/guides/authentication/obtaining-consent#individual-consent) does not need to be configured, as it is already being done in the code at [JwtAuth::JwtCreator#update_token](./app/services/jwt_auth/jwt_creator.rb#L35)
+### Installation steps
+**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.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch to the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
+ 1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+
+
+### Installation steps for JWT Grant authentication
+**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.
+Also, in order to select JSON Web Token authentication in the launcher, in config/appsettings.yml, change `quickstart` to `false`.
+
+1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. In your command-line environment, switch to the folder:
+ `cd ` or `cd code-examples-ruby`
+1. Install the dependencies: `bundle install`
+1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
+ 1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
+ 1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
+ 1. Generate an RSA key pair, if you don’t already have one. Under **Authentication**, select **+ GENERATE RSA**. Copy the private key and save it in a new file named config/docusign_private_key.txt.
+ 1. Add the launcher’s redirect URI. Under **Additional settings**, select **+ ADD URI**, and set a redirect URI of http://localhost:3000/auth/docusign/callback. Select **SAVE**.
+ 1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
+**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
+1. Run the launcher: `rails s`
+1. Open a browser to http://localhost:3000/auth/docusign
+**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
+
+1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
+1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
+1. Select your desired code example.
-From there you should be able to run the launcher using `bundle exec rails server` then selecting **JSON Web Token** when authenticaing your account.
### Troubleshooting Windows SSL issue
When using the Ruby launcher on a Windows machine you may get the following error:
@@ -306,34 +310,18 @@ Modify the following two lines in the **configuration.rb** file, replacing `true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
-### Payments code example
-To use the payments example, create a
-test payments gateway for your developer sandbox account.
-
-See the
-[PAYMENTS_INSTALLATION.md](./PAYMENTS_INSTALLATION.md)
-file for instructions.
+## Payments code example
+To use the payments code example, create a test payment gateway on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account. See [Configure a payment gateway](./PAYMENTS_INSTALLATION.md) for details.
-Then add the payment gateway account id to the **config/application.rb** file.
+Once you've created a payment gateway, save the **Gateway Account ID** GUID to appsettings.yml.
-### Using the examples with other authentication flows
-
-The examples in this repository can also be used with the
-Implicit grant OAuth flow.
-See the [Authentication guide](https://developers.docusign.com/esign-rest-api/guides/authentication)
-for information on choosing the right authentication flow for your application.
## License and additional information
### License
-This repository uses the MIT License. See the LICENSE file for more information.
+This repository uses the MIT License. See [LICENSE](./LICENSE) for details.
+
### Pull Requests
Pull requests are welcomed. Pull requests will only be considered if their content
uses the MIT License.
-
-### Additional Resources
-* [DocuSign Developer Center](https://developers.docusign.com)
-* [DocuSign API on Twitter](https://twitter.com/docusignapi)
-* [DocuSign For Developers on LinkedIn](https://www.linkedin.com/showcase/docusign-for-developers/)
-* [DocuSign For Developers on YouTube](https://www.youtube.com/channel/UCJSJ2kMs_qeQotmw4-lX2NQ)
From ac4071cb6c8c94e16994b7b999cb310086b2ae82 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 15 Apr 2021 11:37:18 -0700
Subject: [PATCH 049/363] remove note about broken jwt
---
README.md | 2 --
1 file changed, 2 deletions(-)
diff --git a/README.md b/README.md
index bad8eb9..3e3358b 100644
--- a/README.md
+++ b/README.md
@@ -272,8 +272,6 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
1. Open a browser to http://localhost:3000/auth/docusign
-**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
-
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
From f1459d40759ecfe519fc11d3f07cf57968ecd7c9 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 15 Apr 2021 11:37:59 -0700
Subject: [PATCH 050/363] sync with private
---
README.md | 2 --
1 file changed, 2 deletions(-)
diff --git a/README.md b/README.md
index bad8eb9..3e3358b 100644
--- a/README.md
+++ b/README.md
@@ -272,8 +272,6 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
1. Open a browser to http://localhost:3000/auth/docusign
-**Note:** This step is currently broken in Windows. We will remove this note when it has been fixed.
-
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
From c7a10b940c45cb131396db9b9a9a11745fc89fca Mon Sep 17 00:00:00 2001
From: Jack Lin
Date: Fri, 16 Apr 2021 06:00:47 -0700
Subject: [PATCH 051/363] add steps for updating local SSL certificates to run
the quick starter
---
README.md | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/README.md b/README.md
index 7930541..b34044e 100644
--- a/README.md
+++ b/README.md
@@ -304,6 +304,17 @@ Modify the following two lines in the **configuration.rb** file, replacing `true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
+### Troubleshooting macOS SSL issue
+When using the Ruby launcher on OSX you may get the following error:
+
+```
+Faraday::SSLError (SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain))
+```
+Please update SSL certificates if brew is your package manager. Or check [other steps for other package manager](https://gemfury.com/help/could-not-verify-ssl-certificate/#updating-ssl-certificates)
+```
+$ rvm osx-ssl-certs status all
+$ rvm osx-ssl-certs update all
+```
## Payments code example
To use the payments code example, create a test payment gateway on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account. See [Configure a payment gateway](./PAYMENTS_INSTALLATION.md) for details.
From 24d577efca310b852c4112f6bcfc38c5ecf73a41 Mon Sep 17 00:00:00 2001
From: Jack Lin
Date: Fri, 16 Apr 2021 06:08:36 -0700
Subject: [PATCH 052/363] change language to make the rvm more clear
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index b34044e..95ce724 100644
--- a/README.md
+++ b/README.md
@@ -310,7 +310,7 @@ When using the Ruby launcher on OSX you may get the following error:
```
Faraday::SSLError (SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain))
```
-Please update SSL certificates if brew is your package manager. Or check [other steps for other package manager](https://gemfury.com/help/could-not-verify-ssl-certificate/#updating-ssl-certificates)
+Please update SSL certificates if rvm is your version manager. Or check [other steps for different scenarios](https://gemfury.com/help/could-not-verify-ssl-certificate/#updating-ssl-certificates).
```
$ rvm osx-ssl-certs status all
$ rvm osx-ssl-certs update all
From 5b79af0a8d09ace4cffb8918ee20e614beabedca Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Tue, 20 Apr 2021 22:48:18 -0700
Subject: [PATCH 053/363] fix JWT error in eSignature examples
---
Gemfile | 12 +-
Gemfile.lock | 183 ++++++++++++++-------------
app/services/jwt_auth/jwt_creator.rb | 2 +-
3 files changed, 105 insertions(+), 92 deletions(-)
diff --git a/Gemfile b/Gemfile
index 4ed9224..72fb506 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,12 +1,12 @@
-# frozen_string_literal: true
+ # frozen_string_literal: true
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.1'
+ruby '2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.3'
+gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
@@ -36,7 +36,7 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.4.5', require: false
+gem 'bootsnap', '~> 1.7.3', require: false
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
@@ -64,8 +64,8 @@ end
gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click'
-gem 'omniauth-oauth2', '~> 1.6'
+gem 'docusign_click', '~> 1.0.0'
+gem 'omniauth-oauth2', '~> 1.7.1'
gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
diff --git a/Gemfile.lock b/Gemfile.lock
index 3f16e3f..76798cd 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.4)
- actionpack (= 6.0.3.4)
+ actioncable (6.0.3.5)
+ actionpack (= 6.0.3.5)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionmailbox (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
mail (>= 2.7.1)
- actionmailer (6.0.3.4)
- actionpack (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
+ actionmailer (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.4)
- actionview (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionpack (6.0.3.5)
+ actionview (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.4)
- actionpack (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actiontext (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
nokogiri (>= 1.8.5)
- actionview (6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionview (6.0.3.5)
+ activesupport (= 6.0.3.5)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.4)
- activesupport (= 6.0.3.4)
+ activejob (6.0.3.5)
+ activesupport (= 6.0.3.5)
globalid (>= 0.3.6)
- activemodel (6.0.3.4)
- activesupport (= 6.0.3.4)
- activerecord (6.0.3.4)
- activemodel (= 6.0.3.4)
- activesupport (= 6.0.3.4)
- activestorage (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
+ activemodel (6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activerecord (6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activestorage (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
marcel (~> 0.3.1)
- activesupport (6.0.3.4)
+ activesupport (6.0.3.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.4.8)
+ bootsnap (1.4.1)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -85,9 +85,10 @@ GEM
coffee-script-source
execjs
coffee-script-source (1.12.2)
- concurrent-ruby (1.1.7)
+ concurrent-ruby (1.1.8)
crass (1.0.6)
- docusign_click (1.0.0.beta2)
+ docusign_click (1.0.0)
+ addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -99,28 +100,31 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- erubi (1.9.0)
+ erubi (1.10.0)
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.1.0)
+ faraday (1.3.0)
+ faraday-net_http (~> 1.0)
multipart-post (>= 1.2, < 3)
ruby2_keywords
- ffi (1.13.1)
+ faraday-net_http (1.0.1)
+ ffi (1.15.0)
+ ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.5)
+ i18n (1.8.9)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
- jbuilder (2.10.1)
+ jbuilder (2.10.2)
activesupport (>= 5.0.0)
- json (2.3.1)
+ json (2.5.1)
jwt (2.2.2)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.7.0)
+ loofah (2.9.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
@@ -128,35 +132,36 @@ GEM
marcel (0.3.3)
mimemagic (~> 0.3.2)
method_source (0.9.2)
- mimemagic (0.3.10)
- nokogiri (~> 1)
- rake
+ mimemagic (0.3.5)
mini_mime (1.0.2)
mini_portile2 (2.5.0)
- minitest (5.14.2)
- msgpack (1.3.3)
+ minitest (5.14.4)
+ msgpack (1.4.2)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
- nio4r (2.5.4)
- nokogiri (1.11.3)
+ nio4r (2.5.7)
+ nokogiri (1.11.2)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
- oauth2 (1.4.4)
+ nokogiri (1.11.2-x64-mingw32)
+ racc (~> 1.4)
+ oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (1.9.1)
+ omniauth (2.0.3)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
- omniauth-oauth2 (1.7.0)
+ rack-protection
+ omniauth-oauth2 (1.7.1)
oauth2 (~> 1.4)
- omniauth (~> 1.9)
- omniauth-rails_csrf_protection (0.1.2)
+ omniauth (>= 1.9, < 3)
+ omniauth-rails_csrf_protection (1.0.0)
actionpack (>= 4.2)
- omniauth (>= 1.3.1)
+ omniauth (~> 2.0)
pry (0.12.2)
coderay (~> 1.1.0)
method_source (~> 0.9.0)
@@ -165,49 +170,53 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.6)
+ puma (4.3.7)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
+ rack-protection (2.1.0)
+ rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.4)
- actioncable (= 6.0.3.4)
- actionmailbox (= 6.0.3.4)
- actionmailer (= 6.0.3.4)
- actionpack (= 6.0.3.4)
- actiontext (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activemodel (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ rails (6.0.3.5)
+ actioncable (= 6.0.3.5)
+ actionmailbox (= 6.0.3.5)
+ actionmailer (= 6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actiontext (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
bundler (>= 1.3.0)
- railties (= 6.0.3.4)
+ railties (= 6.0.3.5)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.4)
- actionpack (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ railties (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
- rake (13.0.1)
+ rake (13.0.3)
rb-fsevent (0.10.4)
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
- ruby2_keywords (0.0.2)
+ ruby2_keywords (0.0.4)
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
+ sassc (2.4.0-x64-mingw32)
+ ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
@@ -229,7 +238,7 @@ GEM
activesupport (>= 4.0)
sprockets (>= 3.0.0)
sqlite3 (1.4.2)
- thor (1.0.1)
+ thor (1.1.0)
thread_safe (0.3.6)
tilt (2.0.10)
turbolinks (5.2.1)
@@ -237,10 +246,13 @@ GEM
turbolinks-source (5.2.0)
typhoeus (1.4.0)
ethon (>= 0.9.0)
- tzinfo (1.2.7)
+ tzinfo (1.2.9)
thread_safe (~> 0.1)
+ tzinfo-data (1.2019.3)
+ tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
+ wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -251,28 +263,29 @@ GEM
websocket-extensions (0.1.5)
xpath (3.2.0)
nokogiri (~> 1.8)
- zeitwerk (2.4.0)
+ zeitwerk (2.4.2)
PLATFORMS
ruby
+ x64-mingw32
DEPENDENCIES
- bootsnap (~> 1.4.5)
+ bootsnap (>= 1.1.0, < 1.4.2)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
- docusign_click
+ docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
- omniauth-oauth2 (~> 1.6)
+ omniauth-oauth2 (~> 1.7.1)
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
puma (~> 4.3.3)
- rails (~> 6.0.3.3)
+ rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
spring (~> 2.1.0)
@@ -285,7 +298,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.1p83
+ ruby 2.7.2p137
BUNDLED WITH
- 2.1.4
+ 2.1.4
\ No newline at end of file
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index e3e6bb7..462409f 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -33,7 +33,7 @@ def self.consent_url(state)
def initialize(session)
@session = session
@api_client = create_initial_api_client(host: Rails.configuration.aud, debugging: false)
- @scope = "signature"
+ scope = "signature"
if Rails.configuration.examples_API['Rooms'] == true
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
elsif Rails.configuration.examples_API['Click'] == true
From 9f912d9716ba415a367498daf99b4fea61fcf984 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 21 Apr 2021 08:23:30 -0700
Subject: [PATCH 054/363] Devdocs 4539 (#23)
* fix JWT error in eSignature examples
---
Gemfile | 10 +-
Gemfile.lock | 183 ++++++++++++++-------------
app/services/jwt_auth/jwt_creator.rb | 2 +-
3 files changed, 104 insertions(+), 91 deletions(-)
diff --git a/Gemfile b/Gemfile
index 4ed9224..cf0c79a 100644
--- a/Gemfile
+++ b/Gemfile
@@ -3,10 +3,10 @@
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.1'
+ruby '2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.3'
+gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
@@ -36,7 +36,7 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.4.5', require: false
+gem 'bootsnap', '~> 1.7.3', require: false
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
@@ -64,8 +64,8 @@ end
gem 'docusign_esign', '~> 3.8.0.rc1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click'
-gem 'omniauth-oauth2', '~> 1.6'
+gem 'docusign_click', '~> 1.0.0'
+gem 'omniauth-oauth2', '~> 1.7.1'
gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
diff --git a/Gemfile.lock b/Gemfile.lock
index 3f16e3f..76798cd 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.4)
- actionpack (= 6.0.3.4)
+ actioncable (6.0.3.5)
+ actionpack (= 6.0.3.5)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionmailbox (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
mail (>= 2.7.1)
- actionmailer (6.0.3.4)
- actionpack (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
+ actionmailer (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.4)
- actionview (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionpack (6.0.3.5)
+ actionview (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.4)
- actionpack (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ actiontext (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
nokogiri (>= 1.8.5)
- actionview (6.0.3.4)
- activesupport (= 6.0.3.4)
+ actionview (6.0.3.5)
+ activesupport (= 6.0.3.5)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.4)
- activesupport (= 6.0.3.4)
+ activejob (6.0.3.5)
+ activesupport (= 6.0.3.5)
globalid (>= 0.3.6)
- activemodel (6.0.3.4)
- activesupport (= 6.0.3.4)
- activerecord (6.0.3.4)
- activemodel (= 6.0.3.4)
- activesupport (= 6.0.3.4)
- activestorage (6.0.3.4)
- actionpack (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activerecord (= 6.0.3.4)
+ activemodel (6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activerecord (6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activestorage (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
marcel (~> 0.3.1)
- activesupport (6.0.3.4)
+ activesupport (6.0.3.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.4.8)
+ bootsnap (1.4.1)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -85,9 +85,10 @@ GEM
coffee-script-source
execjs
coffee-script-source (1.12.2)
- concurrent-ruby (1.1.7)
+ concurrent-ruby (1.1.8)
crass (1.0.6)
- docusign_click (1.0.0.beta2)
+ docusign_click (1.0.0)
+ addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -99,28 +100,31 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- erubi (1.9.0)
+ erubi (1.10.0)
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.1.0)
+ faraday (1.3.0)
+ faraday-net_http (~> 1.0)
multipart-post (>= 1.2, < 3)
ruby2_keywords
- ffi (1.13.1)
+ faraday-net_http (1.0.1)
+ ffi (1.15.0)
+ ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.5)
+ i18n (1.8.9)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
- jbuilder (2.10.1)
+ jbuilder (2.10.2)
activesupport (>= 5.0.0)
- json (2.3.1)
+ json (2.5.1)
jwt (2.2.2)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.7.0)
+ loofah (2.9.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
@@ -128,35 +132,36 @@ GEM
marcel (0.3.3)
mimemagic (~> 0.3.2)
method_source (0.9.2)
- mimemagic (0.3.10)
- nokogiri (~> 1)
- rake
+ mimemagic (0.3.5)
mini_mime (1.0.2)
mini_portile2 (2.5.0)
- minitest (5.14.2)
- msgpack (1.3.3)
+ minitest (5.14.4)
+ msgpack (1.4.2)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
- nio4r (2.5.4)
- nokogiri (1.11.3)
+ nio4r (2.5.7)
+ nokogiri (1.11.2)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
- oauth2 (1.4.4)
+ nokogiri (1.11.2-x64-mingw32)
+ racc (~> 1.4)
+ oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (1.9.1)
+ omniauth (2.0.3)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
- omniauth-oauth2 (1.7.0)
+ rack-protection
+ omniauth-oauth2 (1.7.1)
oauth2 (~> 1.4)
- omniauth (~> 1.9)
- omniauth-rails_csrf_protection (0.1.2)
+ omniauth (>= 1.9, < 3)
+ omniauth-rails_csrf_protection (1.0.0)
actionpack (>= 4.2)
- omniauth (>= 1.3.1)
+ omniauth (~> 2.0)
pry (0.12.2)
coderay (~> 1.1.0)
method_source (~> 0.9.0)
@@ -165,49 +170,53 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.6)
+ puma (4.3.7)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
+ rack-protection (2.1.0)
+ rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.4)
- actioncable (= 6.0.3.4)
- actionmailbox (= 6.0.3.4)
- actionmailer (= 6.0.3.4)
- actionpack (= 6.0.3.4)
- actiontext (= 6.0.3.4)
- actionview (= 6.0.3.4)
- activejob (= 6.0.3.4)
- activemodel (= 6.0.3.4)
- activerecord (= 6.0.3.4)
- activestorage (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ rails (6.0.3.5)
+ actioncable (= 6.0.3.5)
+ actionmailbox (= 6.0.3.5)
+ actionmailer (= 6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actiontext (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
bundler (>= 1.3.0)
- railties (= 6.0.3.4)
+ railties (= 6.0.3.5)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.4)
- actionpack (= 6.0.3.4)
- activesupport (= 6.0.3.4)
+ railties (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
- rake (13.0.1)
+ rake (13.0.3)
rb-fsevent (0.10.4)
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
- ruby2_keywords (0.0.2)
+ ruby2_keywords (0.0.4)
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
+ sassc (2.4.0-x64-mingw32)
+ ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
@@ -229,7 +238,7 @@ GEM
activesupport (>= 4.0)
sprockets (>= 3.0.0)
sqlite3 (1.4.2)
- thor (1.0.1)
+ thor (1.1.0)
thread_safe (0.3.6)
tilt (2.0.10)
turbolinks (5.2.1)
@@ -237,10 +246,13 @@ GEM
turbolinks-source (5.2.0)
typhoeus (1.4.0)
ethon (>= 0.9.0)
- tzinfo (1.2.7)
+ tzinfo (1.2.9)
thread_safe (~> 0.1)
+ tzinfo-data (1.2019.3)
+ tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
+ wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -251,28 +263,29 @@ GEM
websocket-extensions (0.1.5)
xpath (3.2.0)
nokogiri (~> 1.8)
- zeitwerk (2.4.0)
+ zeitwerk (2.4.2)
PLATFORMS
ruby
+ x64-mingw32
DEPENDENCIES
- bootsnap (~> 1.4.5)
+ bootsnap (>= 1.1.0, < 1.4.2)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
- docusign_click
+ docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
- omniauth-oauth2 (~> 1.6)
+ omniauth-oauth2 (~> 1.7.1)
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
puma (~> 4.3.3)
- rails (~> 6.0.3.3)
+ rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
spring (~> 2.1.0)
@@ -285,7 +298,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.1p83
+ ruby 2.7.2p137
BUNDLED WITH
- 2.1.4
+ 2.1.4
\ No newline at end of file
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index e3e6bb7..462409f 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -33,7 +33,7 @@ def self.consent_url(state)
def initialize(session)
@session = session
@api_client = create_initial_api_client(host: Rails.configuration.aud, debugging: false)
- @scope = "signature"
+ scope = "signature"
if Rails.configuration.examples_API['Rooms'] == true
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
elsif Rails.configuration.examples_API['Click'] == true
From 97a8d5a3fc477b1c863992b595c194a25169986b Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 21 Apr 2021 08:39:34 -0700
Subject: [PATCH 055/363] Update from main (#32)
Update from Main
---
Gemfile | 4 +-
Gemfile.lock | 52 ++++++++++---------
README.md | 4 --
app/controllers/ds_common_controller.rb | 3 +-
app/services/api_creator.rb | 11 ++--
.../e_sign/eg007_envelope_get_doc_service.rb | 5 +-
app/services/jwt_auth/jwt_creator.rb | 10 ++--
7 files changed, 45 insertions(+), 44 deletions(-)
diff --git a/Gemfile b/Gemfile
index 89d7d58..72fb506 100644
--- a/Gemfile
+++ b/Gemfile
@@ -36,7 +36,7 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.4.5', require: false
+gem 'bootsnap', '~> 1.7.3', require: false
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
@@ -70,4 +70,4 @@ gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
-gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
+gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
diff --git a/Gemfile.lock b/Gemfile.lock
index d84c396..a9a9ab2 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.4.8)
+ bootsnap (1.4.1)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -85,7 +85,7 @@ GEM
coffee-script-source
execjs
coffee-script-source (1.12.2)
- concurrent-ruby (1.1.7)
+ concurrent-ruby (1.1.8)
crass (1.0.6)
docusign_click (1.0.0)
addressable (~> 2.7, >= 2.7.0)
@@ -100,7 +100,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- erubi (1.9.0)
+ erubi (1.10.0)
ethon (0.12.0)
ffi (>= 1.3.0)
execjs (2.7.0)
@@ -109,22 +109,22 @@ GEM
multipart-post (>= 1.2, < 3)
ruby2_keywords
faraday-net_http (1.0.1)
- ffi (1.13.1)
- ffi (1.13.1-x64-mingw32)
+ ffi (1.15.0)
+ ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.5)
+ i18n (1.8.9)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
- jbuilder (2.10.1)
+ jbuilder (2.10.2)
activesupport (>= 5.0.0)
- json (2.3.1)
+ json (2.5.1)
jwt (2.2.2)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.7.0)
+ loofah (2.9.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
@@ -135,33 +135,33 @@ GEM
mimemagic (0.3.5)
mini_mime (1.0.2)
mini_portile2 (2.5.0)
- minitest (5.14.2)
- msgpack (1.3.3)
- msgpack (1.3.3-x64-mingw32)
+ minitest (5.14.4)
+ msgpack (1.4.2)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
- nio4r (2.5.4)
- nokogiri (1.11.1)
+ nio4r (2.5.7)
+ nokogiri (1.11.2)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
- nokogiri (1.11.1-x64-mingw32)
+ nokogiri (1.11.2-x64-mingw32)
racc (~> 1.4)
- oauth2 (1.4.4)
+ oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (1.9.1)
+ omniauth (2.0.3)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
+ rack-protection
omniauth-oauth2 (1.7.1)
oauth2 (~> 1.4)
omniauth (>= 1.9, < 3)
- omniauth-rails_csrf_protection (0.1.2)
+ omniauth-rails_csrf_protection (1.0.0)
actionpack (>= 4.2)
- omniauth (>= 1.3.1)
+ omniauth (~> 2.0)
pry (0.12.2)
coderay (~> 1.1.0)
method_source (~> 0.9.0)
@@ -170,10 +170,12 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.6)
+ puma (4.3.7)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
+ rack-protection (2.1.0)
+ rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
rails (6.0.3.5)
@@ -202,7 +204,7 @@ GEM
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
- rake (13.0.1)
+ rake (13.0.3)
rb-fsevent (0.10.4)
rb-inotify (0.10.1)
ffi (~> 1.0)
@@ -236,7 +238,7 @@ GEM
activesupport (>= 4.0)
sprockets (>= 3.0.0)
sqlite3 (1.4.2)
- thor (1.0.1)
+ thor (1.1.0)
thread_safe (0.3.6)
tilt (2.0.10)
turbolinks (5.2.1)
@@ -244,7 +246,7 @@ GEM
turbolinks-source (5.2.0)
typhoeus (1.4.0)
ethon (>= 0.9.0)
- tzinfo (1.2.7)
+ tzinfo (1.2.9)
thread_safe (~> 0.1)
tzinfo-data (1.2019.3)
tzinfo (>= 1.0.0)
@@ -261,14 +263,14 @@ GEM
websocket-extensions (0.1.5)
xpath (3.2.0)
nokogiri (~> 1.8)
- zeitwerk (2.4.0)
+ zeitwerk (2.4.2)
PLATFORMS
ruby
x64-mingw32
DEPENDENCIES
- bootsnap (~> 1.4.5)
+ bootsnap (>= 1.1.0, < 1.4.2)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
diff --git a/README.md b/README.md
index 3e3358b..6d05d5b 100644
--- a/README.md
+++ b/README.md
@@ -2,9 +2,6 @@
### Github repo: https://github.com/docusign/code-examples-ruby
-
-This GitHub repo includes code examples for DocuSign APIs.
-
To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
@@ -313,7 +310,6 @@ To use the payments code example, create a test payment gateway on the [**Paymen
Once you've created a payment gateway, save the **Gateway Account ID** GUID to appsettings.yml.
-
## License and additional information
### License
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 9d366c4..26e4e7b 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -44,7 +44,8 @@ def ds_must_authenticate
url = root_path
end
else
- url = JwtAuth::JwtCreator.consent_url
+ session['omniauth.state'] = SecureRandom.hex
+ url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
redirect_to root_path if session[:token].present?
end
if Rails.configuration.examples_API['Rooms'] == true
diff --git a/app/services/api_creator.rb b/app/services/api_creator.rb
index 6e3d04c..3cc5b29 100644
--- a/app/services/api_creator.rb
+++ b/app/services/api_creator.rb
@@ -13,15 +13,15 @@ def create_initial_api_client(host: nil, debugging: false)
end
def create_account_api(args)
- # Step 1. Obtain your OAuth token
+ # Obtain your OAuth token
configuration = DocuSign_eSign::Configuration.new
configuration.host = args[:base_path]
api_client = DocuSign_eSign::ApiClient.new configuration
- # Step 2. Construct your API headers
+ # Construct your API headers
api_client.default_headers['Authorization'] = "Bearer #{args[:access_token]}"
- # Step 3: Construct your request body
+ # Construct your request body
accounts_api = DocuSign_eSign::AccountsApi.new api_client
end
@@ -34,13 +34,14 @@ def create_template_api(args)
end
def create_envelope_api(args)
- # Step 1. Obtain your OAuth token
+ # Obtain your OAuth token
+ # Step 2 start
configuration = DocuSign_eSign::Configuration.new
configuration.host = args[:base_path]
api_client = DocuSign_eSign::ApiClient.new configuration
- # Step 2. Construct your API headers
api_client.default_headers['Authorization'] = "Bearer #{args[:access_token]}"
+ # Step 2 end
DocuSign_eSign::EnvelopesApi.new api_client
end
diff --git a/app/services/e_sign/eg007_envelope_get_doc_service.rb b/app/services/e_sign/eg007_envelope_get_doc_service.rb
index 9baace9..441470c 100644
--- a/app/services/e_sign/eg007_envelope_get_doc_service.rb
+++ b/app/services/e_sign/eg007_envelope_get_doc_service.rb
@@ -22,13 +22,14 @@ def call
private
- # ***DS.snippet.0.start
def worker
+ # Step 3 start
envelope_api = create_envelope_api(args)
document_id = args['document_id']
temp_file = envelope_api.get_document args[:account_id], document_id, args[:envelope_id]
+ # Step 3 end
# Find the matching document information item
doc_item = args['envelope_documents']['documents'].find { |item| item['document_id'] == document_id }
@@ -53,4 +54,4 @@ def worker
end
{ 'mime_type' => mime_type, 'doc_name' => doc_name, 'data' => File.binread(temp_file.path) }
end
-end
\ No newline at end of file
+end
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index dae03df..462409f 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -4,12 +4,12 @@ module JwtAuth
class JwtCreator
include ApiCreator
- attr_reader :session, :api_client
+ attr_reader :session, :api_client, :state
# DocuSign authorization URI to obtain individual consent
# https://developers.docusign.com/platform/auth/jwt/jwt-get-token
# https://developers.docusign.com/platform/auth/consent/obtaining-individual-consent/
- def self.consent_url
+ def self.consent_url(state)
# GET /oauth/auth
# This endpoint is used to obtain consent and is the first step in several authentication flows.
# https://developers.docusign.com/platform/auth/reference/obtain-consent
@@ -24,8 +24,8 @@ def self.consent_url
response_type = "code"
scopes = ERB::Util.url_encode(scope) # https://developers.docusign.com/platform/auth/reference/scopes/
client_id = Rails.configuration.jwt_integration_key
- redirect_uri = Rails.configuration.app_url
- consent_url = "#{base_uri}?response_type=#{response_type}&scope=#{scopes}&client_id=#{client_id}&redirect_uri=#{redirect_uri}"
+ redirect_uri = "#{Rails.configuration.app_url}/auth/docusign/callback"
+ consent_url = "#{base_uri}?response_type=#{response_type}&scope=#{scopes}&client_id=#{client_id}&state=#{state}&redirect_uri=#{redirect_uri}"
Rails.logger.info "==> Obtain Consent Grant required: #{consent_url}"
consent_url
end
@@ -33,7 +33,7 @@ def self.consent_url
def initialize(session)
@session = session
@api_client = create_initial_api_client(host: Rails.configuration.aud, debugging: false)
- @scope = "signature"
+ scope = "signature"
if Rails.configuration.examples_API['Rooms'] == true
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
elsif Rails.configuration.examples_API['Click'] == true
From 5da736564ee015e9d401a42d505839d7acdbc086 Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Wed, 21 Apr 2021 11:29:49 -0700
Subject: [PATCH 056/363] update gemfile
---
.ruby-version | 2 +-
Gemfile | 142 +++++++++++++++++++++++++-------------------------
Gemfile.lock | 140 +++++++++++++++++++++++++------------------------
3 files changed, 143 insertions(+), 141 deletions(-)
diff --git a/.ruby-version b/.ruby-version
index 5588ae8..fbafd6b 100644
--- a/.ruby-version
+++ b/.ruby-version
@@ -1 +1 @@
-2.7.1
\ No newline at end of file
+2.7.2
\ No newline at end of file
diff --git a/Gemfile b/Gemfile
index 72fb506..3919792 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,73 +1,73 @@
# frozen_string_literal: true
-source 'https://rubygems.org'
-git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-
-ruby '2.7.2'
-
-# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
-gem 'rails', '~> 6.0.3.5'
-# Use sqlite3 as the database for Active Record
-gem 'sqlite3', '~> 1.4.2'
-# Use Puma as the app server
-gem 'puma', '~> 4.3.3'
-# Use SCSS for stylesheets
-gem 'sass-rails', '~> 6.0.0'
-# Use Uglifier as compressor for JavaScript assets
-gem 'uglifier', '~> 4.2.0'
-# See https://github.com/rails/execjs#readme for more supported runtimes
-# gem 'mini_racer', platforms: :ruby
-
-# Use CoffeeScript for .coffee assets and views
-gem 'coffee-rails', '~> 5.0.0'
-# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
-gem 'turbolinks', '~> 5.2.1'
-# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
-gem 'jbuilder', '~> 2.10.0'
-# Use Redis adapter to run Action Cable in production
-# gem 'redis', '~> 4.0'
-# Use ActiveModel has_secure_password
-# gem 'bcrypt', '~> 3.1.7'
-
-# Use ActiveStorage variant
-# gem 'mini_magick', '~> 4.8'
-
-# Use Capistrano for deployment
-# gem 'capistrano-rails', group: :development
-
-# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.7.3', require: false
-
-group :development, :test do
- # Call 'byebug' anywhere in the code to stop execution and get a debugger console
- gem 'byebug', '~> 11.1.1', platforms: %i[mri mingw x64_mingw]
-end
-
-group :development do
- # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
- gem 'listen', '~> 3.2.1'
- gem 'web-console', '~> 4.0.1'
- # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
- gem 'pry-nav', '~> 0.3.0'
- gem 'pry-rails', '~> 0.3.9'
- gem 'spring', '~> 2.1.0'
- gem 'spring-watcher-listen', '~> 2.0.1'
-end
-
-group :test do
- # Adds support for Capybara system testing and selenium driver
- gem 'capybara', '~> 3.31.0'
- gem 'selenium-webdriver', '~> 3.142.7'
- # Easy installation and use of chromedriver to run system tests with Chrome
- gem 'chromedriver-helper', '~> 2.1.1'
-end
-
-gem 'docusign_esign', '~> 3.8.0.rc1'
-gem 'docusign_rooms', '~> 1.1.0.rc1'
-gem 'docusign_click', '~> 1.0.0'
-gem 'omniauth-oauth2', '~> 1.7.1'
-gem 'omniauth-rails_csrf_protection'
-
-# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
-gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
-gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
+ source 'https://rubygems.org'
+ git_source(:github) { |repo| "https://github.com/#{repo}.git" }
+
+ ruby '2.7.2'
+
+ # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
+ gem 'rails', '~> 6.0.3.5'
+ # Use sqlite3 as the database for Active Record
+ gem 'sqlite3', '~> 1.4.2'
+ # Use Puma as the app server
+ gem 'puma', '~> 4.3.3'
+ # Use SCSS for stylesheets
+ gem 'sass-rails', '~> 6.0.0'
+ # Use Uglifier as compressor for JavaScript assets
+ gem 'uglifier', '~> 4.2.0'
+ # See https://github.com/rails/execjs#readme for more supported runtimes
+ # gem 'mini_racer', platforms: :ruby
+
+ # Use CoffeeScript for .coffee assets and views
+ gem 'coffee-rails', '~> 5.0.0'
+ # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
+ gem 'turbolinks', '~> 5.2.1'
+ # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
+ gem 'jbuilder', '~> 2.10.0'
+ # Use Redis adapter to run Action Cable in production
+ # gem 'redis', '~> 4.0'
+ # Use ActiveModel has_secure_password
+ # gem 'bcrypt', '~> 3.1.7'
+
+ # Use ActiveStorage variant
+ # gem 'mini_magick', '~> 4.8'
+
+ # Use Capistrano for deployment
+ # gem 'capistrano-rails', group: :development
+
+ # Reduces boot times through caching; required in config/boot.rb
+ gem 'bootsnap', '~> 1.7.3', require: false
+
+ group :development, :test do
+ # Call 'byebug' anywhere in the code to stop execution and get a debugger console
+ gem 'byebug', '~> 11.1.1', platforms: %i[mri mingw x64_mingw]
+ end
+
+ group :development do
+ # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
+ gem 'listen', '~> 3.2.1'
+ gem 'web-console', '~> 4.0.1'
+ # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
+ gem 'pry-nav', '~> 0.3.0'
+ gem 'pry-rails', '~> 0.3.9'
+ gem 'spring', '~> 2.1.0'
+ gem 'spring-watcher-listen', '~> 2.0.1'
+ end
+
+ group :test do
+ # Adds support for Capybara system testing and selenium driver
+ gem 'capybara', '~> 3.31.0'
+ gem 'selenium-webdriver', '~> 3.142.7'
+ # Easy installation and use of chromedriver to run system tests with Chrome
+ gem 'chromedriver-helper', '~> 2.1.1'
+ end
+
+ gem 'docusign_esign', '~> 3.8.0.rc1'
+ gem 'docusign_rooms', '~> 1.1.0.rc1'
+ gem 'docusign_click', '~> 1.0.0'
+ gem 'omniauth-oauth2', '~> 1.7.1'
+ gem 'omniauth-rails_csrf_protection'
+
+ # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
+ gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
+ gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
diff --git a/Gemfile.lock b/Gemfile.lock
index a9a9ab2..594b67d 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.5)
- actionpack (= 6.0.3.5)
+ actioncable (6.0.3.6)
+ actionpack (= 6.0.3.6)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionmailbox (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
mail (>= 2.7.1)
- actionmailer (6.0.3.5)
- actionpack (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
+ actionmailer (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.5)
- actionview (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionpack (6.0.3.6)
+ actionview (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.5)
- actionpack (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actiontext (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
nokogiri (>= 1.8.5)
- actionview (6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionview (6.0.3.6)
+ activesupport (= 6.0.3.6)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.5)
- activesupport (= 6.0.3.5)
+ activejob (6.0.3.6)
+ activesupport (= 6.0.3.6)
globalid (>= 0.3.6)
- activemodel (6.0.3.5)
- activesupport (= 6.0.3.5)
- activerecord (6.0.3.5)
- activemodel (= 6.0.3.5)
- activesupport (= 6.0.3.5)
- activestorage (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- marcel (~> 0.3.1)
- activesupport (6.0.3.5)
+ activemodel (6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activerecord (6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activestorage (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ marcel (~> 1.0.0)
+ activesupport (6.0.3.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.4.1)
+ bootsnap (1.7.4)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -96,44 +96,46 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_rooms (1.1.0.rc1)
+ docusign_rooms (1.1.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
erubi (1.10.0)
- ethon (0.12.0)
- ffi (>= 1.3.0)
+ ethon (0.13.0)
+ ffi (>= 1.15.0)
execjs (2.7.0)
- faraday (1.3.0)
+ faraday (1.4.1)
+ faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
+ faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
- ruby2_keywords
+ ruby2_keywords (>= 0.0.4)
+ faraday-excon (1.1.0)
faraday-net_http (1.0.1)
+ faraday-net_http_persistent (1.1.0)
ffi (1.15.0)
ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.9)
+ i18n (1.8.10)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
jbuilder (2.10.2)
activesupport (>= 5.0.0)
json (2.5.1)
- jwt (2.2.2)
+ jwt (2.2.3)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.9.0)
+ loofah (2.9.1)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
mini_mime (>= 0.1.1)
- marcel (0.3.3)
- mimemagic (~> 0.3.2)
+ marcel (1.0.1)
method_source (0.9.2)
- mimemagic (0.3.5)
- mini_mime (1.0.2)
+ mini_mime (1.1.0)
mini_portile2 (2.5.0)
minitest (5.14.4)
msgpack (1.4.2)
@@ -141,10 +143,10 @@ GEM
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.2)
+ nokogiri (1.11.3)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
- nokogiri (1.11.2-x64-mingw32)
+ nokogiri (1.11.3-x64-mingw32)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -152,7 +154,7 @@ GEM
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (2.0.3)
+ omniauth (2.0.4)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
rack-protection
@@ -178,29 +180,29 @@ GEM
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.5)
- actioncable (= 6.0.3.5)
- actionmailbox (= 6.0.3.5)
- actionmailer (= 6.0.3.5)
- actionpack (= 6.0.3.5)
- actiontext (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activemodel (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ rails (6.0.3.6)
+ actioncable (= 6.0.3.6)
+ actionmailbox (= 6.0.3.6)
+ actionmailer (= 6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actiontext (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
bundler (>= 1.3.0)
- railties (= 6.0.3.5)
+ railties (= 6.0.3.6)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.5)
- actionpack (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ railties (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -270,7 +272,7 @@ PLATFORMS
x64-mingw32
DEPENDENCIES
- bootsnap (>= 1.1.0, < 1.4.2)
+ bootsnap (~> 1.7.3)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
@@ -301,4 +303,4 @@ RUBY VERSION
ruby 2.7.2p137
BUNDLED WITH
- 2.1.4
+ 2.2.16
From e20a822b6aafe343e0d5fea7196ca6d480d49f23 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 21 Apr 2021 13:00:51 -0700
Subject: [PATCH 057/363] Devdocs 4539 (#33)
Update Gemfiles
---
.ruby-version | 2 +-
Gemfile | 2 +-
Gemfile.lock | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/.ruby-version b/.ruby-version
index 5588ae8..fbafd6b 100644
--- a/.ruby-version
+++ b/.ruby-version
@@ -1 +1 @@
-2.7.1
\ No newline at end of file
+2.7.2
\ No newline at end of file
diff --git a/Gemfile b/Gemfile
index 72fb506..52abc2b 100644
--- a/Gemfile
+++ b/Gemfile
@@ -36,7 +36,7 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.7.3', require: false
+gem 'bootsnap', '>= 1.1.0', '< 1.4.2', require: false
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
diff --git a/Gemfile.lock b/Gemfile.lock
index a9a9ab2..76798cd 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -301,4 +301,4 @@ RUBY VERSION
ruby 2.7.2p137
BUNDLED WITH
- 2.1.4
+ 2.1.4
\ No newline at end of file
From 920c7c0b60dc9d4dc4cbe146335518650bacd47b Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 21 Apr 2021 13:02:00 -0700
Subject: [PATCH 058/363] Devdocs 4539 (#34)
* update Gemfiles
---
Gemfile | 142 +++++++++++++++++++++++++--------------------------
Gemfile.lock | 140 +++++++++++++++++++++++++-------------------------
2 files changed, 140 insertions(+), 142 deletions(-)
diff --git a/Gemfile b/Gemfile
index 3919792..52abc2b 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,73 +1,73 @@
# frozen_string_literal: true
- source 'https://rubygems.org'
- git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-
- ruby '2.7.2'
-
- # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
- gem 'rails', '~> 6.0.3.5'
- # Use sqlite3 as the database for Active Record
- gem 'sqlite3', '~> 1.4.2'
- # Use Puma as the app server
- gem 'puma', '~> 4.3.3'
- # Use SCSS for stylesheets
- gem 'sass-rails', '~> 6.0.0'
- # Use Uglifier as compressor for JavaScript assets
- gem 'uglifier', '~> 4.2.0'
- # See https://github.com/rails/execjs#readme for more supported runtimes
- # gem 'mini_racer', platforms: :ruby
-
- # Use CoffeeScript for .coffee assets and views
- gem 'coffee-rails', '~> 5.0.0'
- # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
- gem 'turbolinks', '~> 5.2.1'
- # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
- gem 'jbuilder', '~> 2.10.0'
- # Use Redis adapter to run Action Cable in production
- # gem 'redis', '~> 4.0'
- # Use ActiveModel has_secure_password
- # gem 'bcrypt', '~> 3.1.7'
-
- # Use ActiveStorage variant
- # gem 'mini_magick', '~> 4.8'
-
- # Use Capistrano for deployment
- # gem 'capistrano-rails', group: :development
-
- # Reduces boot times through caching; required in config/boot.rb
- gem 'bootsnap', '~> 1.7.3', require: false
-
- group :development, :test do
- # Call 'byebug' anywhere in the code to stop execution and get a debugger console
- gem 'byebug', '~> 11.1.1', platforms: %i[mri mingw x64_mingw]
- end
-
- group :development do
- # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
- gem 'listen', '~> 3.2.1'
- gem 'web-console', '~> 4.0.1'
- # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
- gem 'pry-nav', '~> 0.3.0'
- gem 'pry-rails', '~> 0.3.9'
- gem 'spring', '~> 2.1.0'
- gem 'spring-watcher-listen', '~> 2.0.1'
- end
-
- group :test do
- # Adds support for Capybara system testing and selenium driver
- gem 'capybara', '~> 3.31.0'
- gem 'selenium-webdriver', '~> 3.142.7'
- # Easy installation and use of chromedriver to run system tests with Chrome
- gem 'chromedriver-helper', '~> 2.1.1'
- end
-
- gem 'docusign_esign', '~> 3.8.0.rc1'
- gem 'docusign_rooms', '~> 1.1.0.rc1'
- gem 'docusign_click', '~> 1.0.0'
- gem 'omniauth-oauth2', '~> 1.7.1'
- gem 'omniauth-rails_csrf_protection'
-
- # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
- gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
- gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
+source 'https://rubygems.org'
+git_source(:github) { |repo| "https://github.com/#{repo}.git" }
+
+ruby '2.7.2'
+
+# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
+gem 'rails', '~> 6.0.3.5'
+# Use sqlite3 as the database for Active Record
+gem 'sqlite3', '~> 1.4.2'
+# Use Puma as the app server
+gem 'puma', '~> 4.3.3'
+# Use SCSS for stylesheets
+gem 'sass-rails', '~> 6.0.0'
+# Use Uglifier as compressor for JavaScript assets
+gem 'uglifier', '~> 4.2.0'
+# See https://github.com/rails/execjs#readme for more supported runtimes
+# gem 'mini_racer', platforms: :ruby
+
+# Use CoffeeScript for .coffee assets and views
+gem 'coffee-rails', '~> 5.0.0'
+# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
+gem 'turbolinks', '~> 5.2.1'
+# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
+gem 'jbuilder', '~> 2.10.0'
+# Use Redis adapter to run Action Cable in production
+# gem 'redis', '~> 4.0'
+# Use ActiveModel has_secure_password
+# gem 'bcrypt', '~> 3.1.7'
+
+# Use ActiveStorage variant
+# gem 'mini_magick', '~> 4.8'
+
+# Use Capistrano for deployment
+# gem 'capistrano-rails', group: :development
+
+# Reduces boot times through caching; required in config/boot.rb
+gem 'bootsnap', '>= 1.1.0', '< 1.4.2', require: false
+
+group :development, :test do
+ # Call 'byebug' anywhere in the code to stop execution and get a debugger console
+ gem 'byebug', '~> 11.1.1', platforms: %i[mri mingw x64_mingw]
+end
+
+group :development do
+ # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
+ gem 'listen', '~> 3.2.1'
+ gem 'web-console', '~> 4.0.1'
+ # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
+ gem 'pry-nav', '~> 0.3.0'
+ gem 'pry-rails', '~> 0.3.9'
+ gem 'spring', '~> 2.1.0'
+ gem 'spring-watcher-listen', '~> 2.0.1'
+end
+
+group :test do
+ # Adds support for Capybara system testing and selenium driver
+ gem 'capybara', '~> 3.31.0'
+ gem 'selenium-webdriver', '~> 3.142.7'
+ # Easy installation and use of chromedriver to run system tests with Chrome
+ gem 'chromedriver-helper', '~> 2.1.1'
+end
+
+gem 'docusign_esign', '~> 3.8.0.rc1'
+gem 'docusign_rooms', '~> 1.1.0.rc1'
+gem 'docusign_click', '~> 1.0.0'
+gem 'omniauth-oauth2', '~> 1.7.1'
+gem 'omniauth-rails_csrf_protection'
+
+# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
+gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
+gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
diff --git a/Gemfile.lock b/Gemfile.lock
index 594b67d..76798cd 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.6)
- actionpack (= 6.0.3.6)
+ actioncable (6.0.3.5)
+ actionpack (= 6.0.3.5)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.6)
- actionpack (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionmailbox (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
mail (>= 2.7.1)
- actionmailer (6.0.3.6)
- actionpack (= 6.0.3.6)
- actionview (= 6.0.3.6)
- activejob (= 6.0.3.6)
+ actionmailer (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.6)
- actionview (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionpack (6.0.3.5)
+ actionview (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.6)
- actionpack (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actiontext (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
nokogiri (>= 1.8.5)
- actionview (6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionview (6.0.3.5)
+ activesupport (= 6.0.3.5)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.6)
- activesupport (= 6.0.3.6)
+ activejob (6.0.3.5)
+ activesupport (= 6.0.3.5)
globalid (>= 0.3.6)
- activemodel (6.0.3.6)
- activesupport (= 6.0.3.6)
- activerecord (6.0.3.6)
- activemodel (= 6.0.3.6)
- activesupport (= 6.0.3.6)
- activestorage (6.0.3.6)
- actionpack (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- marcel (~> 1.0.0)
- activesupport (6.0.3.6)
+ activemodel (6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activerecord (6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
+ activestorage (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ marcel (~> 0.3.1)
+ activesupport (6.0.3.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.7.4)
+ bootsnap (1.4.1)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -96,46 +96,44 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_rooms (1.1.0)
+ docusign_rooms (1.1.0.rc1)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
erubi (1.10.0)
- ethon (0.13.0)
- ffi (>= 1.15.0)
+ ethon (0.12.0)
+ ffi (>= 1.3.0)
execjs (2.7.0)
- faraday (1.4.1)
- faraday-excon (~> 1.1)
+ faraday (1.3.0)
faraday-net_http (~> 1.0)
- faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
- ruby2_keywords (>= 0.0.4)
- faraday-excon (1.1.0)
+ ruby2_keywords
faraday-net_http (1.0.1)
- faraday-net_http_persistent (1.1.0)
ffi (1.15.0)
ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.10)
+ i18n (1.8.9)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
jbuilder (2.10.2)
activesupport (>= 5.0.0)
json (2.5.1)
- jwt (2.2.3)
+ jwt (2.2.2)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.9.1)
+ loofah (2.9.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
mini_mime (>= 0.1.1)
- marcel (1.0.1)
+ marcel (0.3.3)
+ mimemagic (~> 0.3.2)
method_source (0.9.2)
- mini_mime (1.1.0)
+ mimemagic (0.3.5)
+ mini_mime (1.0.2)
mini_portile2 (2.5.0)
minitest (5.14.4)
msgpack (1.4.2)
@@ -143,10 +141,10 @@ GEM
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.3)
+ nokogiri (1.11.2)
mini_portile2 (~> 2.5.0)
racc (~> 1.4)
- nokogiri (1.11.3-x64-mingw32)
+ nokogiri (1.11.2-x64-mingw32)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -154,7 +152,7 @@ GEM
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (2.0.4)
+ omniauth (2.0.3)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
rack-protection
@@ -180,29 +178,29 @@ GEM
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.6)
- actioncable (= 6.0.3.6)
- actionmailbox (= 6.0.3.6)
- actionmailer (= 6.0.3.6)
- actionpack (= 6.0.3.6)
- actiontext (= 6.0.3.6)
- actionview (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activemodel (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ rails (6.0.3.5)
+ actioncable (= 6.0.3.5)
+ actionmailbox (= 6.0.3.5)
+ actionmailer (= 6.0.3.5)
+ actionpack (= 6.0.3.5)
+ actiontext (= 6.0.3.5)
+ actionview (= 6.0.3.5)
+ activejob (= 6.0.3.5)
+ activemodel (= 6.0.3.5)
+ activerecord (= 6.0.3.5)
+ activestorage (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
bundler (>= 1.3.0)
- railties (= 6.0.3.6)
+ railties (= 6.0.3.5)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.6)
- actionpack (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ railties (6.0.3.5)
+ actionpack (= 6.0.3.5)
+ activesupport (= 6.0.3.5)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -272,7 +270,7 @@ PLATFORMS
x64-mingw32
DEPENDENCIES
- bootsnap (~> 1.7.3)
+ bootsnap (>= 1.1.0, < 1.4.2)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
@@ -303,4 +301,4 @@ RUBY VERSION
ruby 2.7.2p137
BUNDLED WITH
- 2.2.16
+ 2.1.4
\ No newline at end of file
From 02ac846c63840468f1810b8038dd9cbf507db275 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 11:43:02 -0700
Subject: [PATCH 059/363] updated URL
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 3e3358b..8e7a21a 100644
--- a/README.md
+++ b/README.md
@@ -252,7 +252,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
### Installation steps for JWT Grant authentication
@@ -271,7 +271,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
From 9739cc505bad31608fc4cddaf986396f235e23f5 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 11:43:47 -0700
Subject: [PATCH 060/363] updated URL
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 6d05d5b..393df18 100644
--- a/README.md
+++ b/README.md
@@ -249,7 +249,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
### Installation steps for JWT Grant authentication
@@ -268,7 +268,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
From 3b016ab7fcc98fae396fc262c6c86cb76fd3d393 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 12:23:25 -0700
Subject: [PATCH 061/363] removed below
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 393df18..20533e9 100644
--- a/README.md
+++ b/README.md
@@ -203,7 +203,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
## Installation
### Prerequisites
-**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
From 18be9836642dbdb55219422628d98d94e969ef4d Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 12:24:04 -0700
Subject: [PATCH 062/363] removed below
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 7930541..25b2a79 100644
--- a/README.md
+++ b/README.md
@@ -203,7 +203,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
## Installation
### Prerequisites
-**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
From 215eb309097a8487c4145a52e8e700234abd190e Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 13:03:11 -0700
Subject: [PATCH 063/363] bundler
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 20533e9..1bbcb92 100644
--- a/README.md
+++ b/README.md
@@ -241,7 +241,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
@@ -259,7 +259,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
From 5bb4d36dbf1f087c0368f23a827c094f8c855110 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 13:03:47 -0700
Subject: [PATCH 064/363] bundler
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 8e7a21a..00ea2c2 100644
--- a/README.md
+++ b/README.md
@@ -244,7 +244,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
@@ -262,7 +262,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
From 837f502596b1fffc5813d6d5094e702890e56a8b Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:05:20 -0700
Subject: [PATCH 065/363] Devdocs 4634 (#24)
fix quickstart auth issue
---
Gemfile | 2 +-
app/controllers/ds_common_controller.rb | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Gemfile b/Gemfile
index cf0c79a..72fb506 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,4 +1,4 @@
-# frozen_string_literal: true
+ # frozen_string_literal: true
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 26e4e7b..f37fb5e 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -28,7 +28,7 @@ def ds_return
end
def ds_must_authenticate
- if Rails.configuration.quickstart == "true"
+ if Rails.configuration.quickstart == true
redirect_to('auth/docusign')
end
@title = 'Authenticate with DocuSign'
From 9a8a0813060741a88518eb81f15780a4ba312594 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:08:10 -0700
Subject: [PATCH 066/363] Quickstart auth (#35)
* update Gemfile
* set quickstart to automatically use auth code grant
---
app/controllers/ds_common_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 26e4e7b..f37fb5e 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -28,7 +28,7 @@ def ds_return
end
def ds_must_authenticate
- if Rails.configuration.quickstart == "true"
+ if Rails.configuration.quickstart == true
redirect_to('auth/docusign')
end
@title = 'Authenticate with DocuSign'
From 3f8a14dd3bfd2d74909460a925985515c2dfab7a Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:09:31 -0700
Subject: [PATCH 067/363] Quickstart auth (#36)
* Master (#29)
* add info about scopes to README and update JWT scopes (#9)
* update README
* Master (#30)
* update readme
* SMS update
* Updating the name of the signHere tab to match all other langs.
* Renaming one variable to match other code examples
* docusign_esign gem version update
* Updated eSign31 example: added confirm successful batch send step
* Updated quickstart logic
* Clean up eg031
* Bump nokogiri from 1.10.10 to 1.11.1
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.1.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.1)
Signed-off-by: dependabot[bot]
* update gist steps comments (#18)
* update gist steps comments
* Various updates including step 8 of bulk send
* Updating various packages to move forward with new versions
* Updating gem package versions
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* Update README.md
* updating README.md
* Added Step 3 comments
* Added Step 2 comments; removed other numbers in comments
* bundler update omniauth to address CVE-2015-9284
* bundle install, Ruby 2.7.2
* Update PAYMENTS_INSTALLATION.md
* Update README.md
* Update README.md
* add line breaks
* Update README.md
* edit Rooms line
* deleted a section
* bold UI items
* add line breaks
* remove period
* remove line break
* sample Ruby folder
* add backslash
* add bin
* step
* to
* small updates
* added JWT link
* remove line break
* synced with private
* synced with private
* sync with private
* fix JWT redirect_uri and add state (#21)
* Bump nokogiri from 1.10.10 to 1.11.3
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.3.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.3)
Signed-off-by: dependabot[bot]
* removed note about broken jwt
* small edit
* remove note about broken jwt
* Devdocs 4539 (#23)
* fix JWT error in eSignature examples
* update gemfile
* update Gemfile
* Devdocs 4539 (#34)
* update Gemfiles
* updated URL
* removed below
* bundler
* set quickstart to automatically use auth code grant
Co-authored-by: Matthew Lusher
Co-authored-by: Inbar Gazit
Co-authored-by: an-tk
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: meihDS <70775251+meihDS@users.noreply.github.com>
Co-authored-by: Aaron JacksonWilde
---
README.md | 10 +++++-----
app/controllers/ds_common_controller.rb | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index 6d05d5b..1bbcb92 100644
--- a/README.md
+++ b/README.md
@@ -203,7 +203,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
## Installation
### Prerequisites
-**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
@@ -241,7 +241,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
@@ -249,7 +249,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
### Installation steps for JWT Grant authentication
@@ -259,7 +259,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundle install`
+1. Install the dependencies: `bundler install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `jwt_integration_key`.
@@ -268,7 +268,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Set a name and email address for the signer. In appsettings.yml, save an email address as `signer_email` and a name as `signer_name`.
**Note:** Protect your personal information. Please make sure that appsettings.yml will not be stored in your source code repository.
1. Run the launcher: `rails s`
-1. Open a browser to http://localhost:3000/auth/docusign
+1. Open a browser to http://localhost:3000
1. If it is your first time using the app, grant consent by selecting **Accept**. On the black navigation bar, select **Logout**, then **Login**.
1. From the picklist, select **JSON Web Token (JWT) grant** > **Authenticate with DocuSign**.
1. Select your desired code example.
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 26e4e7b..f37fb5e 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -28,7 +28,7 @@ def ds_return
end
def ds_must_authenticate
- if Rails.configuration.quickstart == "true"
+ if Rails.configuration.quickstart == true
redirect_to('auth/docusign')
end
@title = 'Authenticate with DocuSign'
From e5e99aee2e79142d23dd4f5e387eaa6dda91f942 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:25:51 -0700
Subject: [PATCH 068/363] Auth (#37)
* update Gemfile
* set quickstart to automatically use auth code grant
* update route for quickstart auth
---
app/controllers/ds_common_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index f37fb5e..26d187f 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -29,7 +29,7 @@ def ds_return
def ds_must_authenticate
if Rails.configuration.quickstart == true
- redirect_to('auth/docusign')
+ redirect_to('/auth/docusign')
end
@title = 'Authenticate with DocuSign'
@show_doc = Rails.application.config.documentation
From 50f3c32aef220952b0a3411fd1c51b03a1ffbdb4 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:29:21 -0700
Subject: [PATCH 069/363] Auth (#38)
update route for quickstart auth
---
app/controllers/ds_common_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index f37fb5e..26d187f 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -29,7 +29,7 @@ def ds_return
def ds_must_authenticate
if Rails.configuration.quickstart == true
- redirect_to('auth/docusign')
+ redirect_to('/auth/docusign')
end
@title = 'Authenticate with DocuSign'
@show_doc = Rails.application.config.documentation
From b409e8dbaf3b52f78a03aa2be637cd7caaf805a7 Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Thu, 22 Apr 2021 14:30:47 -0700
Subject: [PATCH 070/363] update quickstart auth
---
app/controllers/ds_common_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index f37fb5e..26d187f 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -29,7 +29,7 @@ def ds_return
def ds_must_authenticate
if Rails.configuration.quickstart == true
- redirect_to('auth/docusign')
+ redirect_to('/auth/docusign')
end
@title = 'Authenticate with DocuSign'
@show_doc = Rails.application.config.documentation
From bc2fffa1a6f0e0f05083eb2792e225ca6678972a Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:44:04 -0700
Subject: [PATCH 071/363] removed "name"
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 1bbcb92..2ca7493 100644
--- a/README.md
+++ b/README.md
@@ -240,7 +240,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
- `cd ` or `cd code-examples-ruby`
+ `cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
@@ -258,7 +258,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
- `cd ` or `cd code-examples-ruby`
+ `cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundler install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
From 1016fcc0ae585b908e0d13f8c31a35f87dbf5918 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 22 Apr 2021 14:44:37 -0700
Subject: [PATCH 072/363] removed "name"
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 00ea2c2..90c61c6 100644
--- a/README.md
+++ b/README.md
@@ -243,7 +243,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
- `cd ` or `cd code-examples-ruby`
+ `cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
@@ -261,7 +261,7 @@ Also, in order to select JSON Web Token authentication in the launcher, in confi
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
- `cd ` or `cd code-examples-ruby`
+ `cd ` or `cd code-examples-ruby`
1. Install the dependencies: `bundler install`
1. To configure the launcher for [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your API Username. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **My Account Information**, copy the **API Username** GUID and save it in appsettings.yml as your `impersonated_user_guid`.
From 26a65cfd51696ab42c6cbf3f3c0baa42784b891a Mon Sep 17 00:00:00 2001
From: robert-knight
Date: Mon, 26 Apr 2021 07:59:18 -0700
Subject: [PATCH 073/363] Updated sequence values for eg013.
---
Gemfile | 2 +-
Gemfile.lock | 144 +++++++++---------
.../eg013_add_doc_to_template_service.rb | 4 +-
3 files changed, 72 insertions(+), 78 deletions(-)
diff --git a/Gemfile b/Gemfile
index 52abc2b..6e57591 100644
--- a/Gemfile
+++ b/Gemfile
@@ -3,7 +3,7 @@
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.2'
+ruby '~>2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 6.0.3.5'
diff --git a/Gemfile.lock b/Gemfile.lock
index 76798cd..a694ac7 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.5)
- actionpack (= 6.0.3.5)
+ actioncable (6.0.3.6)
+ actionpack (= 6.0.3.6)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionmailbox (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
mail (>= 2.7.1)
- actionmailer (6.0.3.5)
- actionpack (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
+ actionmailer (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.5)
- actionview (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionpack (6.0.3.6)
+ actionview (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.5)
- actionpack (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actiontext (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
nokogiri (>= 1.8.5)
- actionview (6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionview (6.0.3.6)
+ activesupport (= 6.0.3.6)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.5)
- activesupport (= 6.0.3.5)
+ activejob (6.0.3.6)
+ activesupport (= 6.0.3.6)
globalid (>= 0.3.6)
- activemodel (6.0.3.5)
- activesupport (= 6.0.3.5)
- activerecord (6.0.3.5)
- activemodel (= 6.0.3.5)
- activesupport (= 6.0.3.5)
- activestorage (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- marcel (~> 0.3.1)
- activesupport (6.0.3.5)
+ activemodel (6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activerecord (6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activestorage (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ marcel (~> 1.0.0)
+ activesupport (6.0.3.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -96,55 +96,52 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_rooms (1.1.0.rc1)
+ docusign_rooms (1.1.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
erubi (1.10.0)
- ethon (0.12.0)
- ffi (>= 1.3.0)
+ ethon (0.13.0)
+ ffi (>= 1.15.0)
execjs (2.7.0)
- faraday (1.3.0)
+ faraday (1.4.1)
+ faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
+ faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
- ruby2_keywords
+ ruby2_keywords (>= 0.0.4)
+ faraday-excon (1.1.0)
faraday-net_http (1.0.1)
- ffi (1.15.0)
+ faraday-net_http_persistent (1.1.0)
ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.9)
+ i18n (1.8.10)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
jbuilder (2.10.2)
activesupport (>= 5.0.0)
json (2.5.1)
- jwt (2.2.2)
+ jwt (2.2.3)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.9.0)
+ loofah (2.9.1)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
mini_mime (>= 0.1.1)
- marcel (0.3.3)
- mimemagic (~> 0.3.2)
+ marcel (1.0.1)
method_source (0.9.2)
- mimemagic (0.3.5)
- mini_mime (1.0.2)
- mini_portile2 (2.5.0)
+ mini_mime (1.1.0)
minitest (5.14.4)
msgpack (1.4.2)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.2)
- mini_portile2 (~> 2.5.0)
- racc (~> 1.4)
- nokogiri (1.11.2-x64-mingw32)
+ nokogiri (1.11.3-x64-mingw32)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -152,7 +149,7 @@ GEM
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (2.0.3)
+ omniauth (2.0.4)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
rack-protection
@@ -178,29 +175,29 @@ GEM
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.5)
- actioncable (= 6.0.3.5)
- actionmailbox (= 6.0.3.5)
- actionmailer (= 6.0.3.5)
- actionpack (= 6.0.3.5)
- actiontext (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activemodel (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ rails (6.0.3.6)
+ actioncable (= 6.0.3.6)
+ actionmailbox (= 6.0.3.6)
+ actionmailer (= 6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actiontext (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
bundler (>= 1.3.0)
- railties (= 6.0.3.5)
+ railties (= 6.0.3.6)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.5)
- actionpack (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ railties (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -213,8 +210,6 @@ GEM
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
- sassc (2.4.0)
- ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
sassc-rails (2.1.2)
@@ -266,7 +261,6 @@ GEM
zeitwerk (2.4.2)
PLATFORMS
- ruby
x64-mingw32
DEPENDENCIES
@@ -298,7 +292,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.2p137
+ ruby 2.7.3p183
BUNDLED WITH
- 2.1.4
\ No newline at end of file
+ 2.2.16
diff --git a/app/services/e_sign/eg013_add_doc_to_template_service.rb b/app/services/e_sign/eg013_add_doc_to_template_service.rb
index 85d1dbe..130381c 100644
--- a/app/services/e_sign/eg013_add_doc_to_template_service.rb
+++ b/app/services/e_sign/eg013_add_doc_to_template_service.rb
@@ -91,7 +91,7 @@ def make_envelope(args)
# Add the roles via an inlineTemplate
inlineTemplates: [
DocuSign_eSign::InlineTemplate.new(
- 'sequence' => '1',
+ 'sequence' => '2',
'recipients' => recipients_server_template
)
]
@@ -136,7 +136,7 @@ def make_envelope(args)
# Add the recipients via an inlineTemplate
inlineTemplates: [
DocuSign_eSign::InlineTemplate.new(
- sequence: '2', recipients: recipients_added_doc
+ sequence: '1', recipients: recipients_added_doc
)
],
document: doc1
From f4c841cee4ad372574fec28e2c9fa6229ce3a27a Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 26 Apr 2021 14:42:49 -0700
Subject: [PATCH 074/363] Deleted strange line
---
README.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/README.md b/README.md
index 84e9489..d68bf27 100644
--- a/README.md
+++ b/README.md
@@ -210,7 +210,6 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
=======
1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
->>>>>>> 18be9836642dbdb55219422628d98d94e969ef4d
This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
From f7be46b882868831aa095e318ae6f773e1c5b17c Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Mon, 26 Apr 2021 14:43:38 -0700
Subject: [PATCH 075/363] Deleted more strange lines
---
README.md | 2 --
1 file changed, 2 deletions(-)
diff --git a/README.md b/README.md
index d68bf27..7990fbf 100644
--- a/README.md
+++ b/README.md
@@ -206,9 +206,7 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
-<<<<<<< HEAD
1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
-=======
1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
From 6444069e1db89303b9280c754fc433a590797394 Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Mon, 26 Apr 2021 15:14:12 -0700
Subject: [PATCH 076/363] update README
---
README.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/README.md b/README.md
index 7990fbf..a9e3d51 100644
--- a/README.md
+++ b/README.md
@@ -206,7 +206,6 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
-1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
From 0d484314397cb46061b0631aa8a35990d892b5e9 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 28 Apr 2021 08:59:38 -0700
Subject: [PATCH 077/363] Update gemfile (#25)
* Master (#25)
* add info about scopes to README and update JWT scopes (#9)
* Arr workflow (#11)
* Added ARR workflow
* Changed text and update readme
* Changed default input value
* Resolved comments
* Resolved comments
* add steps comments and catch ARR error
* add save page to session and remove incorrect files
* fix comments
Co-authored-by: Karissa.Jacobsen
Co-authored-by: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
* Update README.md
* Update README.md
* Master (#26)
* Added 5 clickwrap examples
* Master (#28)
* Add Rooms Q4 updates
Co-authored-by: Aaron Wilde
Co-authored-by: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Karissa.Jacobsen
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Anatoly Tkachenko
* Bump nokogiri from 1.10.10 to 1.11.1 (#27)
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.1.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/master/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.1)
Signed-off-by: dependabot[bot]
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Master (#29)
* add info about scopes to README and update JWT scopes (#9)
* update readme
* Master (#30)
* update readme
* renaming variable to match other code example languages.
* Renaming one variable to match other code examples
* Various updates including adding step 8 of bulk send
* Various updates including step 8 of bulk send
* Updating gem package versions
* Updating gem package versions
* Updating README.md
* updating README.md
* Added Step 3 comments
* Added Step 2 comments; removed other numbers in comments
* bundler update omniauth to address CVE-2015-9284
* bundle install, Ruby 2.7.2
* Update PAYMENTS_INSTALLATION.md
* synced with private
* Update README.md
* synced with private
* delete first sentence
* sync with private
* removed note about broken jwt
* removed broken jwt note
* sync with private
* sync with private
* update gemfile
* Devdocs 4539 (#34)
* update Gemfiles
* updated URL
* removed below
* removed below
* bundler
* Quickstart auth (#35)
* update Gemfile
* set quickstart to automatically use auth code grant
* Auth (#37)
* update Gemfile
* set quickstart to automatically use auth code grant
* update route for quickstart auth
* removed "name"
* Updated sequence values for eg013.
* Deleted strange line
* Deleted more strange lines
* update README
* sync public readme and update gemfile
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Anatoly Tkachenko
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: meihDS <70775251+meihDS@users.noreply.github.com>
Co-authored-by: robert-knight
---
.ruby-version | 2 +-
Gemfile | 8 +-
Gemfile.lock | 144 +++++++++---------
README.md | 8 +-
app/services/api_creator.rb | 11 +-
.../e_sign/eg007_envelope_get_doc_service.rb | 5 +-
.../eg013_add_doc_to_template_service.rb | 4 +-
7 files changed, 89 insertions(+), 93 deletions(-)
diff --git a/.ruby-version b/.ruby-version
index 5588ae8..fbafd6b 100644
--- a/.ruby-version
+++ b/.ruby-version
@@ -1 +1 @@
-2.7.1
\ No newline at end of file
+2.7.2
\ No newline at end of file
diff --git a/Gemfile b/Gemfile
index 72fb506..0064ce8 100644
--- a/Gemfile
+++ b/Gemfile
@@ -3,7 +3,7 @@
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
-ruby '2.7.2'
+ruby '~>2.7.2'
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 6.0.3.5'
@@ -36,7 +36,11 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '~> 1.7.3', require: false
+if RUBY_PLATFORM =~ /mswin/
+ gem 'bootsnap', '>= 1.1.0', '< 1.4.2', require: false
+else
+ gem 'bootsnap', '~> 1.7.3', require: false
+end
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
diff --git a/Gemfile.lock b/Gemfile.lock
index 76798cd..a694ac7 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.5)
- actionpack (= 6.0.3.5)
+ actioncable (6.0.3.6)
+ actionpack (= 6.0.3.6)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionmailbox (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
mail (>= 2.7.1)
- actionmailer (6.0.3.5)
- actionpack (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
+ actionmailer (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.5)
- actionview (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionpack (6.0.3.6)
+ actionview (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.5)
- actionpack (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ actiontext (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
nokogiri (>= 1.8.5)
- actionview (6.0.3.5)
- activesupport (= 6.0.3.5)
+ actionview (6.0.3.6)
+ activesupport (= 6.0.3.6)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.5)
- activesupport (= 6.0.3.5)
+ activejob (6.0.3.6)
+ activesupport (= 6.0.3.6)
globalid (>= 0.3.6)
- activemodel (6.0.3.5)
- activesupport (= 6.0.3.5)
- activerecord (6.0.3.5)
- activemodel (= 6.0.3.5)
- activesupport (= 6.0.3.5)
- activestorage (6.0.3.5)
- actionpack (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- marcel (~> 0.3.1)
- activesupport (6.0.3.5)
+ activemodel (6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activerecord (6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
+ activestorage (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ marcel (~> 1.0.0)
+ activesupport (6.0.3.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -96,55 +96,52 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_rooms (1.1.0.rc1)
+ docusign_rooms (1.1.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
erubi (1.10.0)
- ethon (0.12.0)
- ffi (>= 1.3.0)
+ ethon (0.13.0)
+ ffi (>= 1.15.0)
execjs (2.7.0)
- faraday (1.3.0)
+ faraday (1.4.1)
+ faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
+ faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
- ruby2_keywords
+ ruby2_keywords (>= 0.0.4)
+ faraday-excon (1.1.0)
faraday-net_http (1.0.1)
- ffi (1.15.0)
+ faraday-net_http_persistent (1.1.0)
ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
- i18n (1.8.9)
+ i18n (1.8.10)
concurrent-ruby (~> 1.0)
io-like (0.3.1)
jbuilder (2.10.2)
activesupport (>= 5.0.0)
json (2.5.1)
- jwt (2.2.2)
+ jwt (2.2.3)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.9.0)
+ loofah (2.9.1)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
mini_mime (>= 0.1.1)
- marcel (0.3.3)
- mimemagic (~> 0.3.2)
+ marcel (1.0.1)
method_source (0.9.2)
- mimemagic (0.3.5)
- mini_mime (1.0.2)
- mini_portile2 (2.5.0)
+ mini_mime (1.1.0)
minitest (5.14.4)
msgpack (1.4.2)
multi_json (1.15.0)
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.2)
- mini_portile2 (~> 2.5.0)
- racc (~> 1.4)
- nokogiri (1.11.2-x64-mingw32)
+ nokogiri (1.11.3-x64-mingw32)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -152,7 +149,7 @@ GEM
multi_json (~> 1.3)
multi_xml (~> 0.5)
rack (>= 1.2, < 3)
- omniauth (2.0.3)
+ omniauth (2.0.4)
hashie (>= 3.4.6)
rack (>= 1.6.2, < 3)
rack-protection
@@ -178,29 +175,29 @@ GEM
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.5)
- actioncable (= 6.0.3.5)
- actionmailbox (= 6.0.3.5)
- actionmailer (= 6.0.3.5)
- actionpack (= 6.0.3.5)
- actiontext (= 6.0.3.5)
- actionview (= 6.0.3.5)
- activejob (= 6.0.3.5)
- activemodel (= 6.0.3.5)
- activerecord (= 6.0.3.5)
- activestorage (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ rails (6.0.3.6)
+ actioncable (= 6.0.3.6)
+ actionmailbox (= 6.0.3.6)
+ actionmailer (= 6.0.3.6)
+ actionpack (= 6.0.3.6)
+ actiontext (= 6.0.3.6)
+ actionview (= 6.0.3.6)
+ activejob (= 6.0.3.6)
+ activemodel (= 6.0.3.6)
+ activerecord (= 6.0.3.6)
+ activestorage (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
bundler (>= 1.3.0)
- railties (= 6.0.3.5)
+ railties (= 6.0.3.6)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.5)
- actionpack (= 6.0.3.5)
- activesupport (= 6.0.3.5)
+ railties (6.0.3.6)
+ actionpack (= 6.0.3.6)
+ activesupport (= 6.0.3.6)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
@@ -213,8 +210,6 @@ GEM
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
- sassc (2.4.0)
- ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
sassc-rails (2.1.2)
@@ -266,7 +261,6 @@ GEM
zeitwerk (2.4.2)
PLATFORMS
- ruby
x64-mingw32
DEPENDENCIES
@@ -298,7 +292,7 @@ DEPENDENCIES
web-console (~> 4.0.1)
RUBY VERSION
- ruby 2.7.2p137
+ ruby 2.7.3p183
BUNDLED WITH
- 2.1.4
\ No newline at end of file
+ 2.2.16
diff --git a/README.md b/README.md
index 90c61c6..a9e3d51 100644
--- a/README.md
+++ b/README.md
@@ -2,9 +2,6 @@
### Github repo: https://github.com/docusign/code-examples-ruby
-
-This GitHub repo includes code examples for DocuSign APIs.
-
To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
@@ -206,10 +203,10 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
## Installation
### Prerequisites
-**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 below as they were automatically performed for you.
+**Note:** If you downloaded this code using [Quickstart](https://developers.docusign.com/docs/esign-rest-api/quickstart/) from the DocuSign Developer Center, skip items 1 and 2 as they were automatically performed for you.
1. A free [DocuSign developer account](https://go.docusign.com/o/sandbox/); create one if you don't already have one.
-1. A DocuSign app and integration key that is configured to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/) authentication.
+1. A DocuSign app and integration key that is configured for authentication to use either [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) or [JWT Grant](https://developers.docusign.com/platform/auth/jwt/).
This [video](https://www.youtube.com/watch?v=eiRI4fe5HgM) demonstrates how to obtain an integration key.
@@ -313,7 +310,6 @@ To use the payments code example, create a test payment gateway on the [**Paymen
Once you've created a payment gateway, save the **Gateway Account ID** GUID to appsettings.yml.
-
## License and additional information
### License
diff --git a/app/services/api_creator.rb b/app/services/api_creator.rb
index 6e3d04c..3cc5b29 100644
--- a/app/services/api_creator.rb
+++ b/app/services/api_creator.rb
@@ -13,15 +13,15 @@ def create_initial_api_client(host: nil, debugging: false)
end
def create_account_api(args)
- # Step 1. Obtain your OAuth token
+ # Obtain your OAuth token
configuration = DocuSign_eSign::Configuration.new
configuration.host = args[:base_path]
api_client = DocuSign_eSign::ApiClient.new configuration
- # Step 2. Construct your API headers
+ # Construct your API headers
api_client.default_headers['Authorization'] = "Bearer #{args[:access_token]}"
- # Step 3: Construct your request body
+ # Construct your request body
accounts_api = DocuSign_eSign::AccountsApi.new api_client
end
@@ -34,13 +34,14 @@ def create_template_api(args)
end
def create_envelope_api(args)
- # Step 1. Obtain your OAuth token
+ # Obtain your OAuth token
+ # Step 2 start
configuration = DocuSign_eSign::Configuration.new
configuration.host = args[:base_path]
api_client = DocuSign_eSign::ApiClient.new configuration
- # Step 2. Construct your API headers
api_client.default_headers['Authorization'] = "Bearer #{args[:access_token]}"
+ # Step 2 end
DocuSign_eSign::EnvelopesApi.new api_client
end
diff --git a/app/services/e_sign/eg007_envelope_get_doc_service.rb b/app/services/e_sign/eg007_envelope_get_doc_service.rb
index 9baace9..441470c 100644
--- a/app/services/e_sign/eg007_envelope_get_doc_service.rb
+++ b/app/services/e_sign/eg007_envelope_get_doc_service.rb
@@ -22,13 +22,14 @@ def call
private
- # ***DS.snippet.0.start
def worker
+ # Step 3 start
envelope_api = create_envelope_api(args)
document_id = args['document_id']
temp_file = envelope_api.get_document args[:account_id], document_id, args[:envelope_id]
+ # Step 3 end
# Find the matching document information item
doc_item = args['envelope_documents']['documents'].find { |item| item['document_id'] == document_id }
@@ -53,4 +54,4 @@ def worker
end
{ 'mime_type' => mime_type, 'doc_name' => doc_name, 'data' => File.binread(temp_file.path) }
end
-end
\ No newline at end of file
+end
diff --git a/app/services/e_sign/eg013_add_doc_to_template_service.rb b/app/services/e_sign/eg013_add_doc_to_template_service.rb
index 85d1dbe..130381c 100644
--- a/app/services/e_sign/eg013_add_doc_to_template_service.rb
+++ b/app/services/e_sign/eg013_add_doc_to_template_service.rb
@@ -91,7 +91,7 @@ def make_envelope(args)
# Add the roles via an inlineTemplate
inlineTemplates: [
DocuSign_eSign::InlineTemplate.new(
- 'sequence' => '1',
+ 'sequence' => '2',
'recipients' => recipients_server_template
)
]
@@ -136,7 +136,7 @@ def make_envelope(args)
# Add the recipients via an inlineTemplate
inlineTemplates: [
DocuSign_eSign::InlineTemplate.new(
- sequence: '2', recipients: recipients_added_doc
+ sequence: '1', recipients: recipients_added_doc
)
],
document: doc1
From dd9abc3dc732dc6dc012cbcd75ec5da7c13d09b6 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 28 Apr 2021 09:57:51 -0700
Subject: [PATCH 078/363] Update gemfile (#25) (#39)
* Master (#25)
* add info about scopes to README and update JWT scopes (#9)
* Arr workflow (#11)
* Added ARR workflow
* Changed text and update readme
* Changed default input value
* Resolved comments
* Resolved comments
* add steps comments and catch ARR error
* add save page to session and remove incorrect files
* fix comments
Co-authored-by: Karissa.Jacobsen
Co-authored-by: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
* Update README.md
* Update README.md
* Master (#26)
* Added 5 clickwrap examples
* Master (#28)
* Add Rooms Q4 updates
Co-authored-by: Aaron Wilde
Co-authored-by: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Karissa.Jacobsen
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Anatoly Tkachenko
* Bump nokogiri from 1.10.10 to 1.11.1 (#27)
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.10.10 to 1.11.1.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/master/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.10.10...v1.11.1)
Signed-off-by: dependabot[bot]
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Master (#29)
* add info about scopes to README and update JWT scopes (#9)
* update readme
* Master (#30)
* update readme
* renaming variable to match other code example languages.
* Renaming one variable to match other code examples
* Various updates including adding step 8 of bulk send
* Various updates including step 8 of bulk send
* Updating gem package versions
* Updating gem package versions
* Updating README.md
* updating README.md
* Added Step 3 comments
* Added Step 2 comments; removed other numbers in comments
* bundler update omniauth to address CVE-2015-9284
* bundle install, Ruby 2.7.2
* Update PAYMENTS_INSTALLATION.md
* synced with private
* Update README.md
* synced with private
* delete first sentence
* sync with private
* removed note about broken jwt
* removed broken jwt note
* sync with private
* sync with private
* update gemfile
* Devdocs 4539 (#34)
* update Gemfiles
* updated URL
* removed below
* removed below
* bundler
* Quickstart auth (#35)
* update Gemfile
* set quickstart to automatically use auth code grant
* Auth (#37)
* update Gemfile
* set quickstart to automatically use auth code grant
* update route for quickstart auth
* removed "name"
* Updated sequence values for eg013.
* Deleted strange line
* Deleted more strange lines
* update README
* sync public readme and update gemfile
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Anatoly Tkachenko
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: meihDS <70775251+meihDS@users.noreply.github.com>
Co-authored-by: robert-knight
Co-authored-by: Aaron Wilde
Co-authored-by: RustamAbdul <63346609+RustamAbdul@users.noreply.github.com>
Co-authored-by: Inbar Gazit
Co-authored-by: Anatoly Tkachenko
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: meihDS <70775251+meihDS@users.noreply.github.com>
Co-authored-by: robert-knight
---
Gemfile | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/Gemfile b/Gemfile
index 6e57591..0064ce8 100644
--- a/Gemfile
+++ b/Gemfile
@@ -36,7 +36,11 @@ gem 'jbuilder', '~> 2.10.0'
# gem 'capistrano-rails', group: :development
# Reduces boot times through caching; required in config/boot.rb
-gem 'bootsnap', '>= 1.1.0', '< 1.4.2', require: false
+if RUBY_PLATFORM =~ /mswin/
+ gem 'bootsnap', '>= 1.1.0', '< 1.4.2', require: false
+else
+ gem 'bootsnap', '~> 1.7.3', require: false
+end
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
From 81a46f563f485ef4f56cc69c4f4d664ab0e73261 Mon Sep 17 00:00:00 2001
From: Anatoly Tkachenko
Date: Wed, 5 May 2021 21:15:00 +0300
Subject: [PATCH 079/363] monitor api example implemented (#20)
* monitor api example implemented
* update monitor example and text
* update appsettings file
* update index file
Co-authored-by: Karissa Jacobsen
---
Gemfile | 1 +
Gemfile.lock | 16 ++++++-
README.md | 6 +++
app/controllers/ds_common_controller.rb | 2 +
...eg001_get_monitoring_dataset_controller.rb | 27 +++++++++++
app/services/api_creator.rb | 21 ++++++---
.../eg001_get_monitoring_dataset_service.rb | 47 +++++++++++++++++++
app/views/ds_common/ds_must_authenticate.erb | 2 +
.../eg001_get_monitoring_dataset/get.html.erb | 14 ++++++
app/views/monitor_api/index.html.erb | 38 +++++++++++++++
config/appsettings.example.yml | 2 +
config/routes.rb | 7 +++
12 files changed, 175 insertions(+), 8 deletions(-)
create mode 100644 app/controllers/monitor_api/eg001_get_monitoring_dataset_controller.rb
create mode 100644 app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
create mode 100644 app/views/monitor_api/eg001_get_monitoring_dataset/get.html.erb
create mode 100644 app/views/monitor_api/index.html.erb
diff --git a/Gemfile b/Gemfile
index 0064ce8..a803a99 100644
--- a/Gemfile
+++ b/Gemfile
@@ -67,6 +67,7 @@ group :test do
end
gem 'docusign_esign', '~> 3.8.0.rc1'
+gem 'docusign_monitor', '~> 1.0.1.pre.alpha'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click', '~> 1.0.0'
gem 'omniauth-oauth2', '~> 1.7.1'
diff --git a/Gemfile.lock b/Gemfile.lock
index a694ac7..0ec4c95 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.4.1)
+ bootsnap (1.7.4)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -96,6 +96,11 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
+ docusign_monitor (1.0.1.pre.alpha)
+ addressable (~> 2.7, >= 2.7.0)
+ json (~> 2.1, >= 2.1.0)
+ jwt (~> 2.2, >= 2.2.1)
+ typhoeus (~> 1.0, >= 1.0.1)
docusign_rooms (1.1.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
@@ -113,6 +118,7 @@ GEM
faraday-excon (1.1.0)
faraday-net_http (1.0.1)
faraday-net_http_persistent (1.1.0)
+ ffi (1.15.0)
ffi (1.15.0-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
@@ -143,6 +149,8 @@ GEM
nio4r (2.5.7)
nokogiri (1.11.3-x64-mingw32)
racc (~> 1.4)
+ nokogiri (1.11.3-x86_64-darwin)
+ racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -210,6 +218,8 @@ GEM
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
+ sassc (2.4.0)
+ ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
sassc-rails (2.1.2)
@@ -262,15 +272,17 @@ GEM
PLATFORMS
x64-mingw32
+ x86_64-darwin-20
DEPENDENCIES
- bootsnap (>= 1.1.0, < 1.4.2)
+ bootsnap (~> 1.7.3)
byebug (~> 11.1.1)
capybara (~> 3.31.0)
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
+ docusign_monitor (~> 1.0.1.pre.alpha)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
diff --git a/README.md b/README.md
index a9e3d51..d908aab 100644
--- a/README.md
+++ b/README.md
@@ -199,6 +199,12 @@ This example demonstrates how to use the Click API to get a list of clickwraps a
[Source.](./app/services/clickwrap/eg005_clickwrap_responses_service.rb)
This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
+## Monitor API
+**Note:** To use the Monitor API, you must also [enable DocuSign Monitor for your organization](https://developers.docusign.com/docs/monitor-api/how-to/enable-monitor/).
+For information about the scopes used for obtaining authorization to use the Monitor API, see the [scopes section](https://developers.docusign.com/docs/monitor-api/monitor101/auth/).
+
+1. **Get monitoring data.** [Source](app/services/monitor_api/eg001_get_monitoring_dataset_service.rb)
+ Demonstrates how to get and display all of your organization’s monitoring data.
## Installation
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index 26d187f..ae220a5 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -10,6 +10,8 @@ def index
render 'room_api/index'
elsif Rails.configuration.examples_API['Click'] == true
render 'clickwrap/index'
+ elsif Rails.configuration.examples_API['Monitor'] == true
+ render 'monitor_api/index'
else
@show_doc = Rails.application.config.documentation
if Rails.configuration.quickstart == true && session[:been_here].nil?
diff --git a/app/controllers/monitor_api/eg001_get_monitoring_dataset_controller.rb b/app/controllers/monitor_api/eg001_get_monitoring_dataset_controller.rb
new file mode 100644
index 0000000..358c5a9
--- /dev/null
+++ b/app/controllers/monitor_api/eg001_get_monitoring_dataset_controller.rb
@@ -0,0 +1,27 @@
+class MonitorApi::Eg001GetMonitoringDatasetController < EgController
+ before_action :check_auth
+
+ def create
+ results = MonitorApi::Eg001GetMonitoringDatasetService.new(session, nil).call
+
+ @title = "Monitoring data result"
+ @h1 = "Monitoring data result"
+ @message = "Results from DataSet:GetStreamForDataset method:"
+ @json = results.to_json.to_json
+
+ render 'ds_common/example_done'
+ end
+
+ private
+
+ def check_auth
+ minimum_buffer_min = 10
+ token_ok = check_token(minimum_buffer_min)
+ unless token_ok
+ flash[:messages] = 'Sorry, you need to re-authenticate.'
+ # We could store the parameters of the requested operation so it could be restarted automatically
+ # But since it should be rare to have a token issue here, we'll make the user re-enter the form data after authentication
+ redirect_to '/ds/mustAuthenticate'
+ end
+ end
+end
diff --git a/app/services/api_creator.rb b/app/services/api_creator.rb
index 3cc5b29..7ad2298 100644
--- a/app/services/api_creator.rb
+++ b/app/services/api_creator.rb
@@ -2,16 +2,25 @@
module ApiCreator
def create_initial_api_client(host: nil, debugging: false)
- configuration = DocuSign_eSign::Configuration.new
-
- # https://github.com/docusign/docusign-ruby-client/blob/master/lib/docusign_esign/configuration.rb#L55-L60
- configuration.debugging = debugging
-
- api_client = DocuSign_eSign::ApiClient.new(configuration)
+ if Rails.configuration.examples_API['Rooms'] == true
+ api_client = new_client(DocuSign_Rooms, debugging)
+ elsif Rails.configuration.examples_API['Click'] == true
+ api_client = new_client(DocuSign_Click, debugging)
+ elsif Rails.configuration.examples_API['Monitor'] == true
+ api_client = new_client(DocuSign_Monitor, debugging)
+ else
+ api_client = new_client(DocuSign_eSign, debugging)
+ end
api_client.set_oauth_base_path(host)
api_client
end
+ def new_client(client_module, debugging)
+ configuration = client_module::Configuration.new
+ configuration.debugging = debugging
+ client_module::ApiClient.new(configuration)
+ end
+
def create_account_api(args)
# Obtain your OAuth token
configuration = DocuSign_eSign::Configuration.new
diff --git a/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
new file mode 100644
index 0000000..38a4f1d
--- /dev/null
+++ b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
@@ -0,0 +1,47 @@
+# frozen_string_literal: true
+
+class MonitorApi::Eg001GetMonitoringDatasetService
+ attr_reader :args
+
+ def initialize(session, _request)
+ @args = {
+ # account_id: session[:ds_account_id],
+ access_token: session[:ds_access_token]
+ }
+ @cursor = ''
+ @results_memo = []
+ @last_result = ''
+ end
+
+ def call
+ # step 2 start
+ configuration = DocuSign_Monitor::Configuration.new
+ configuration.host = Rails.configuration.monitor_host
+ configuration.debugging = true
+ api_client = DocuSign_Monitor::ApiClient.new configuration
+ api_client.set_default_header('Authorization', "Bearer #{args[:access_token]}")
+ # step 2 end
+
+ # step 3 start
+ while true do
+ monitor_api = DocuSign_Monitor::DataSetApi.new(api_client)
+ options = DocuSign_Monitor::GetStreamForDatasetOptions.default
+ options.cursor = @cursor
+ response = monitor_api.get_stream_for_dataset('monitor', '2.0', options).first
+
+ # If the endCursor from the response is the same as the one that you already have,
+ # it means that you have reached the end of the records
+ break if response[:endCursor] == @cursor
+
+ @results_memo.push(response[:data])
+ @last_result = response[:data]
+ @cursor = response[:endCursor]
+ end
+ # step 3 end
+
+ Rails.logger.info "Responses for loops are displayed here. Only the final loop is displayed on the response page"
+ Rails.logger.info @results_memo.inspect
+
+ return @last_result
+ end
+end
diff --git a/app/views/ds_common/ds_must_authenticate.erb b/app/views/ds_common/ds_must_authenticate.erb
index 959a806..c722e3d 100644
--- a/app/views/ds_common/ds_must_authenticate.erb
+++ b/app/views/ds_common/ds_must_authenticate.erb
@@ -5,7 +5,9 @@
<%= hidden_field_tag :authenticity_token, form_authenticity_token %>
+
+
+
\ No newline at end of file
diff --git a/config/appsettings.example.yml b/config/appsettings.example.yml
index 22d5d39..c02d6f3 100644
--- a/config/appsettings.example.yml
+++ b/config/appsettings.example.yml
@@ -9,6 +9,7 @@ default: &default
eSignature: true
Rooms: false
Click: false
+ Monitor: false
# NOTE: The terms "client_id" and "Integration key" are synonyms. They refer to the same thing
# The integration_key value is the same between the development account and production account
integration_key: {INTEGRATION_KEY_AUTH_CODE}
@@ -26,6 +27,7 @@ default: &default
authorization_server: https://account-d.docusign.com
aud: account-d.docusign.com
rooms_host: "https://demo.rooms.docusign.com/restapi"
+ monitor_host: "https://lens-d.docusign.net"
allow_silent_authentication: true # A user can be silently authenticated if they have an
# Active login session on another tab of the same browser
# Set if you want a specific DocuSign AccountId, If false, the users default account will be used.
diff --git a/config/routes.rb b/config/routes.rb
index d87ea50..fcdcb43 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -48,6 +48,11 @@
get 'eg005' => 'eg005_clickwrap_responses#get'
post 'eg005' => 'eg005_clickwrap_responses#create'
end
+ elsif Rails.configuration.examples_API['Monitor'] == true
+ scope module: 'monitor_api' do
+ get 'eg001' => 'eg001_get_monitoring_dataset#get'
+ post 'eg001' => 'eg001_get_monitoring_dataset#create'
+ end
else
scope module: 'e_sign' do
# Example controllers...
@@ -177,6 +182,8 @@
get '/ds_common-return' => 'ds_common#ds_return'
get '/ds/mustAuthenticate' => 'ds_common#ds_must_authenticate'
post '/ds/mustAuthenticate' => 'ds_common#ds_must_authenticate'
+ get '/ds/mustAuthenticateJwt' => 'ds_common#ds_must_authenticate_jwt'
+ post '/ds/mustAuthenticateJwt' => 'ds_common#ds_must_authenticate'
get '/ds/session' => 'session#show'
# default root
From f7b85e44632224ab3591d2209776a0632c6f5642 Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Thu, 6 May 2021 14:04:09 -0700
Subject: [PATCH 080/363] update JWT flow
---
app/controllers/ds_common_controller.rb | 49 ++++++++++++++-----------
app/services/api_creator.rb | 20 ++--------
app/services/jwt_auth/jwt_creator.rb | 9 ++++-
3 files changed, 39 insertions(+), 39 deletions(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index ae220a5..ed0d65e 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -30,6 +30,9 @@ def ds_return
end
def ds_must_authenticate
+ if Rails.configuration.examples_API['Monitor'] == true
+ jwt_auth
+ end
if Rails.configuration.quickstart == true
redirect_to('/auth/docusign')
end
@@ -39,30 +42,34 @@ def ds_must_authenticate
if params[:auth] == 'grand-auth'
redirect_to('/auth/docusign')
elsif params[:auth] == 'jwt-auth'
- if JwtAuth::JwtCreator.new(session).check_jwt_token
- if session[:eg]
- url = "/" + session[:eg]
- else
- url = root_path
- end
+ jwt_auth
+ end
+ end
+
+ def jwt_auth
+ if JwtAuth::JwtCreator.new(session).check_jwt_token
+ if session[:eg]
+ url = "/" + session[:eg]
else
- session['omniauth.state'] = SecureRandom.hex
- url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
- redirect_to root_path if session[:token].present?
- end
- if Rails.configuration.examples_API['Rooms'] == true
- configuration = DocuSign_Rooms::Configuration.new
- api_client = DocuSign_Rooms::ApiClient.new(configuration)
- elsif Rails.configuration.examples_API['Click'] == true
- configuration = DocuSign_Click::Configuration.new
- api_client = DocuSign_Click::ApiClient.new configuration
- end
- resp = ::JwtAuth::JwtCreator.new(session).check_jwt_token
- if resp.is_a? String
- redirect_to resp
+ url = root_path
end
- redirect_to url
+ else
+ session['omniauth.state'] = SecureRandom.hex
+ url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
+ redirect_to root_path if session[:token].present?
+ end
+ if Rails.configuration.examples_API['Rooms'] == true
+ configuration = DocuSign_Rooms::Configuration.new
+ api_client = DocuSign_Rooms::ApiClient.new(configuration)
+ elsif Rails.configuration.examples_API['Click'] == true
+ configuration = DocuSign_Click::Configuration.new
+ api_client = DocuSign_Click::ApiClient.new configuration
+ end
+ resp = ::JwtAuth::JwtCreator.new(session).check_jwt_token
+ if resp.is_a? String
+ redirect_to resp
end
+ redirect_to url
end
def example_done; end
diff --git a/app/services/api_creator.rb b/app/services/api_creator.rb
index 7ad2298..47694b6 100644
--- a/app/services/api_creator.rb
+++ b/app/services/api_creator.rb
@@ -1,24 +1,12 @@
# frozen_string_literal: true
module ApiCreator
- def create_initial_api_client(host: nil, debugging: false)
- if Rails.configuration.examples_API['Rooms'] == true
- api_client = new_client(DocuSign_Rooms, debugging)
- elsif Rails.configuration.examples_API['Click'] == true
- api_client = new_client(DocuSign_Click, debugging)
- elsif Rails.configuration.examples_API['Monitor'] == true
- api_client = new_client(DocuSign_Monitor, debugging)
- else
- api_client = new_client(DocuSign_eSign, debugging)
- end
- api_client.set_oauth_base_path(host)
- api_client
- end
-
- def new_client(client_module, debugging)
+ def create_initial_api_client(host: nil, client_module: DocuSign_eSign, debugging: false)
configuration = client_module::Configuration.new
configuration.debugging = debugging
- client_module::ApiClient.new(configuration)
+ api_client = client_module::ApiClient.new(configuration)
+ api_client.set_oauth_base_path(host)
+ api_client
end
def create_account_api(args)
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index 462409f..70984f1 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -32,14 +32,19 @@ def self.consent_url(state)
def initialize(session)
@session = session
- @api_client = create_initial_api_client(host: Rails.configuration.aud, debugging: false)
scope = "signature"
+ @client_module = DocuSign_eSign
if Rails.configuration.examples_API['Rooms'] == true
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
+ @client_module = DocuSign_Rooms
elsif Rails.configuration.examples_API['Click'] == true
scope = "signature click.manage click.send"
+ @client_module = DocuSign_Click
+ elsif Rails.configuration.examples_API['Monitor'] == true
+ @client_module = DocuSign_Monitor
end
@scope = "#{scope} impersonation"
+ @api_client = create_initial_api_client(host: Rails.configuration.aud, client_module: @client_module, debugging: false)
end
# @return [Boolean] `true` if the token was successfully updated, `false` if consent still needs to be grant'ed
@@ -57,7 +62,7 @@ def check_jwt_token
else
raise
end
- rescue DocuSign_eSign::ApiError => exception
+ rescue @client_module::ApiError => exception
Rails.logger.warn exception.inspect
body = JSON.parse(exception.response_body)
From 7a150f00c61a2926d398389f9e66ac330ec1d20e Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Thu, 6 May 2021 14:27:54 -0700
Subject: [PATCH 081/363] remove unnecessary syntax
---
app/controllers/ds_common_controller.rb | 16 ++++++++--------
app/services/jwt_auth/jwt_creator.rb | 10 +++++-----
config/initializers/omniauth.rb | 4 ++--
config/routes.rb | 6 +++---
4 files changed, 18 insertions(+), 18 deletions(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index ed0d65e..4682bec 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -6,15 +6,15 @@ class DsCommonController < ApplicationController
def index
@show_doc = Rails.application.config.documentation
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
render 'room_api/index'
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
render 'clickwrap/index'
- elsif Rails.configuration.examples_API['Monitor'] == true
+ elsif Rails.configuration.examples_API['Monitor']
render 'monitor_api/index'
else
@show_doc = Rails.application.config.documentation
- if Rails.configuration.quickstart == true && session[:been_here].nil?
+ if Rails.configuration.quickstart && session[:been_here].nil?
redirect_to '/eg001'
end
end
@@ -30,10 +30,10 @@ def ds_return
end
def ds_must_authenticate
- if Rails.configuration.examples_API['Monitor'] == true
+ if Rails.configuration.examples_API['Monitor']
jwt_auth
end
- if Rails.configuration.quickstart == true
+ if Rails.configuration.quickstart
redirect_to('/auth/docusign')
end
@title = 'Authenticate with DocuSign'
@@ -58,10 +58,10 @@ def jwt_auth
url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
redirect_to root_path if session[:token].present?
end
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
configuration = DocuSign_Rooms::Configuration.new
api_client = DocuSign_Rooms::ApiClient.new(configuration)
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
configuration = DocuSign_Click::Configuration.new
api_client = DocuSign_Click::ApiClient.new configuration
end
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index 70984f1..77892f3 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -14,9 +14,9 @@ def self.consent_url(state)
# This endpoint is used to obtain consent and is the first step in several authentication flows.
# https://developers.docusign.com/platform/auth/reference/obtain-consent
scope = "signature"
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
scope = "signature click.manage click.send"
end
scope = "#{scope} impersonation"
@@ -34,13 +34,13 @@ def initialize(session)
@session = session
scope = "signature"
@client_module = DocuSign_eSign
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
@client_module = DocuSign_Rooms
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
scope = "signature click.manage click.send"
@client_module = DocuSign_Click
- elsif Rails.configuration.examples_API['Monitor'] == true
+ elsif Rails.configuration.examples_API['Monitor']
@client_module = DocuSign_Monitor
end
@scope = "#{scope} impersonation"
diff --git a/config/initializers/omniauth.rb b/config/initializers/omniauth.rb
index 4dc2cd1..178aaf3 100644
--- a/config/initializers/omniauth.rb
+++ b/config/initializers/omniauth.rb
@@ -34,9 +34,9 @@
unless strategy.options[:allow_silent_authentication]
strategy.options[:authorize_params].prompt = strategy.options.prompt
end
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
strategy.options[:authorize_params].scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
strategy.options[:authorize_params].scope = "signature click.manage click.send"
end
}
diff --git a/config/routes.rb b/config/routes.rb
index fcdcb43..97cb804 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -1,7 +1,7 @@
# frozen_string_literal: true
Rails.application.routes.draw do
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
scope module: 'room_api' do
get 'eg001' => 'eg001_create_room_with_data#get'
post 'eg001' => 'eg001_create_room_with_data#create'
@@ -31,7 +31,7 @@
get 'eg009' => 'eg009_assign_form_to_form_group#get'
post 'eg009' => 'eg009_assign_form_to_form_group#create'
end
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
scope module: 'clickwrap' do
get 'eg001' => 'eg001_create_clickwrap#get'
post 'eg001' => 'eg001_create_clickwrap#create'
@@ -48,7 +48,7 @@
get 'eg005' => 'eg005_clickwrap_responses#get'
post 'eg005' => 'eg005_clickwrap_responses#create'
end
- elsif Rails.configuration.examples_API['Monitor'] == true
+ elsif Rails.configuration.examples_API['Monitor']
scope module: 'monitor_api' do
get 'eg001' => 'eg001_get_monitoring_dataset#get'
post 'eg001' => 'eg001_get_monitoring_dataset#create'
From 146afca935f7b5f508badece8502127c351d20af Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Thu, 6 May 2021 16:03:54 -0700
Subject: [PATCH 082/363] update JWT flow (#26)
* update JWT flow
---
app/controllers/ds_common_controller.rb | 59 ++++++++++++++-----------
app/services/api_creator.rb | 20 ++-------
app/services/jwt_auth/jwt_creator.rb | 17 ++++---
config/initializers/omniauth.rb | 4 +-
config/routes.rb | 6 +--
5 files changed, 53 insertions(+), 53 deletions(-)
diff --git a/app/controllers/ds_common_controller.rb b/app/controllers/ds_common_controller.rb
index ae220a5..4682bec 100644
--- a/app/controllers/ds_common_controller.rb
+++ b/app/controllers/ds_common_controller.rb
@@ -6,15 +6,15 @@ class DsCommonController < ApplicationController
def index
@show_doc = Rails.application.config.documentation
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
render 'room_api/index'
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
render 'clickwrap/index'
- elsif Rails.configuration.examples_API['Monitor'] == true
+ elsif Rails.configuration.examples_API['Monitor']
render 'monitor_api/index'
else
@show_doc = Rails.application.config.documentation
- if Rails.configuration.quickstart == true && session[:been_here].nil?
+ if Rails.configuration.quickstart && session[:been_here].nil?
redirect_to '/eg001'
end
end
@@ -30,7 +30,10 @@ def ds_return
end
def ds_must_authenticate
- if Rails.configuration.quickstart == true
+ if Rails.configuration.examples_API['Monitor']
+ jwt_auth
+ end
+ if Rails.configuration.quickstart
redirect_to('/auth/docusign')
end
@title = 'Authenticate with DocuSign'
@@ -39,30 +42,34 @@ def ds_must_authenticate
if params[:auth] == 'grand-auth'
redirect_to('/auth/docusign')
elsif params[:auth] == 'jwt-auth'
- if JwtAuth::JwtCreator.new(session).check_jwt_token
- if session[:eg]
- url = "/" + session[:eg]
- else
- url = root_path
- end
+ jwt_auth
+ end
+ end
+
+ def jwt_auth
+ if JwtAuth::JwtCreator.new(session).check_jwt_token
+ if session[:eg]
+ url = "/" + session[:eg]
else
- session['omniauth.state'] = SecureRandom.hex
- url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
- redirect_to root_path if session[:token].present?
- end
- if Rails.configuration.examples_API['Rooms'] == true
- configuration = DocuSign_Rooms::Configuration.new
- api_client = DocuSign_Rooms::ApiClient.new(configuration)
- elsif Rails.configuration.examples_API['Click'] == true
- configuration = DocuSign_Click::Configuration.new
- api_client = DocuSign_Click::ApiClient.new configuration
+ url = root_path
end
- resp = ::JwtAuth::JwtCreator.new(session).check_jwt_token
- if resp.is_a? String
- redirect_to resp
- end
- redirect_to url
+ else
+ session['omniauth.state'] = SecureRandom.hex
+ url = JwtAuth::JwtCreator.consent_url(session['omniauth.state'])
+ redirect_to root_path if session[:token].present?
+ end
+ if Rails.configuration.examples_API['Rooms']
+ configuration = DocuSign_Rooms::Configuration.new
+ api_client = DocuSign_Rooms::ApiClient.new(configuration)
+ elsif Rails.configuration.examples_API['Click']
+ configuration = DocuSign_Click::Configuration.new
+ api_client = DocuSign_Click::ApiClient.new configuration
+ end
+ resp = ::JwtAuth::JwtCreator.new(session).check_jwt_token
+ if resp.is_a? String
+ redirect_to resp
end
+ redirect_to url
end
def example_done; end
diff --git a/app/services/api_creator.rb b/app/services/api_creator.rb
index 7ad2298..47694b6 100644
--- a/app/services/api_creator.rb
+++ b/app/services/api_creator.rb
@@ -1,24 +1,12 @@
# frozen_string_literal: true
module ApiCreator
- def create_initial_api_client(host: nil, debugging: false)
- if Rails.configuration.examples_API['Rooms'] == true
- api_client = new_client(DocuSign_Rooms, debugging)
- elsif Rails.configuration.examples_API['Click'] == true
- api_client = new_client(DocuSign_Click, debugging)
- elsif Rails.configuration.examples_API['Monitor'] == true
- api_client = new_client(DocuSign_Monitor, debugging)
- else
- api_client = new_client(DocuSign_eSign, debugging)
- end
- api_client.set_oauth_base_path(host)
- api_client
- end
-
- def new_client(client_module, debugging)
+ def create_initial_api_client(host: nil, client_module: DocuSign_eSign, debugging: false)
configuration = client_module::Configuration.new
configuration.debugging = debugging
- client_module::ApiClient.new(configuration)
+ api_client = client_module::ApiClient.new(configuration)
+ api_client.set_oauth_base_path(host)
+ api_client
end
def create_account_api(args)
diff --git a/app/services/jwt_auth/jwt_creator.rb b/app/services/jwt_auth/jwt_creator.rb
index 462409f..77892f3 100644
--- a/app/services/jwt_auth/jwt_creator.rb
+++ b/app/services/jwt_auth/jwt_creator.rb
@@ -14,9 +14,9 @@ def self.consent_url(state)
# This endpoint is used to obtain consent and is the first step in several authentication flows.
# https://developers.docusign.com/platform/auth/reference/obtain-consent
scope = "signature"
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
scope = "signature click.manage click.send"
end
scope = "#{scope} impersonation"
@@ -32,14 +32,19 @@ def self.consent_url(state)
def initialize(session)
@session = session
- @api_client = create_initial_api_client(host: Rails.configuration.aud, debugging: false)
scope = "signature"
- if Rails.configuration.examples_API['Rooms'] == true
+ @client_module = DocuSign_eSign
+ if Rails.configuration.examples_API['Rooms']
scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
- elsif Rails.configuration.examples_API['Click'] == true
+ @client_module = DocuSign_Rooms
+ elsif Rails.configuration.examples_API['Click']
scope = "signature click.manage click.send"
+ @client_module = DocuSign_Click
+ elsif Rails.configuration.examples_API['Monitor']
+ @client_module = DocuSign_Monitor
end
@scope = "#{scope} impersonation"
+ @api_client = create_initial_api_client(host: Rails.configuration.aud, client_module: @client_module, debugging: false)
end
# @return [Boolean] `true` if the token was successfully updated, `false` if consent still needs to be grant'ed
@@ -57,7 +62,7 @@ def check_jwt_token
else
raise
end
- rescue DocuSign_eSign::ApiError => exception
+ rescue @client_module::ApiError => exception
Rails.logger.warn exception.inspect
body = JSON.parse(exception.response_body)
diff --git a/config/initializers/omniauth.rb b/config/initializers/omniauth.rb
index 4dc2cd1..178aaf3 100644
--- a/config/initializers/omniauth.rb
+++ b/config/initializers/omniauth.rb
@@ -34,9 +34,9 @@
unless strategy.options[:allow_silent_authentication]
strategy.options[:authorize_params].prompt = strategy.options.prompt
end
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
strategy.options[:authorize_params].scope = "signature dtr.rooms.read dtr.rooms.write dtr.documents.read dtr.documents.write dtr.profile.read dtr.profile.write dtr.company.read dtr.company.write room_forms"
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
strategy.options[:authorize_params].scope = "signature click.manage click.send"
end
}
diff --git a/config/routes.rb b/config/routes.rb
index fcdcb43..97cb804 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -1,7 +1,7 @@
# frozen_string_literal: true
Rails.application.routes.draw do
- if Rails.configuration.examples_API['Rooms'] == true
+ if Rails.configuration.examples_API['Rooms']
scope module: 'room_api' do
get 'eg001' => 'eg001_create_room_with_data#get'
post 'eg001' => 'eg001_create_room_with_data#create'
@@ -31,7 +31,7 @@
get 'eg009' => 'eg009_assign_form_to_form_group#get'
post 'eg009' => 'eg009_assign_form_to_form_group#create'
end
- elsif Rails.configuration.examples_API['Click'] == true
+ elsif Rails.configuration.examples_API['Click']
scope module: 'clickwrap' do
get 'eg001' => 'eg001_create_clickwrap#get'
post 'eg001' => 'eg001_create_clickwrap#create'
@@ -48,7 +48,7 @@
get 'eg005' => 'eg005_clickwrap_responses#get'
post 'eg005' => 'eg005_clickwrap_responses#create'
end
- elsif Rails.configuration.examples_API['Monitor'] == true
+ elsif Rails.configuration.examples_API['Monitor']
scope module: 'monitor_api' do
get 'eg001' => 'eg001_get_monitoring_dataset#get'
post 'eg001' => 'eg001_get_monitoring_dataset#create'
From e47248c5655032819fe73782a3572b3b31f5623d Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Fri, 7 May 2021 11:26:57 -0700
Subject: [PATCH 083/363] add cursor and fix spacing issue
---
.../eg001_get_monitoring_dataset_service.rb | 11 +++----
app/views/monitor_api/index.html.erb | 33 ++++++++++---------
2 files changed, 22 insertions(+), 22 deletions(-)
diff --git a/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
index 38a4f1d..7722e6a 100644
--- a/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
+++ b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
@@ -10,7 +10,6 @@ def initialize(session, _request)
}
@cursor = ''
@results_memo = []
- @last_result = ''
end
def call
@@ -23,9 +22,10 @@ def call
# step 2 end
# step 3 start
+ monitor_api = DocuSign_Monitor::DataSetApi.new(api_client)
+ options = DocuSign_Monitor::GetStreamForDatasetOptions.default
+
while true do
- monitor_api = DocuSign_Monitor::DataSetApi.new(api_client)
- options = DocuSign_Monitor::GetStreamForDatasetOptions.default
options.cursor = @cursor
response = monitor_api.get_stream_for_dataset('monitor', '2.0', options).first
@@ -33,8 +33,7 @@ def call
# it means that you have reached the end of the records
break if response[:endCursor] == @cursor
- @results_memo.push(response[:data])
- @last_result = response[:data]
+ @results_memo.push(response)
@cursor = response[:endCursor]
end
# step 3 end
@@ -42,6 +41,6 @@ def call
Rails.logger.info "Responses for loops are displayed here. Only the final loop is displayed on the response page"
Rails.logger.info @results_memo.inspect
- return @last_result
+ return @results_memo
end
end
diff --git a/app/views/monitor_api/index.html.erb b/app/views/monitor_api/index.html.erb
index ec1ff52..054cdb1 100644
--- a/app/views/monitor_api/index.html.erb
+++ b/app/views/monitor_api/index.html.erb
@@ -17,22 +17,23 @@
- <% if @show_doc %>
- Documentation on using JWT Authorization from a Ruby Rails application.
- <% end %>
+
+ <% if @show_doc %>
+
Documentation on using JWT Authorization from a Ruby Rails application.
+ <% end %>
-
Monitor API Code Examples
+
Monitor API Code Examples
-
-
- Demonstrates how to get and display all of your organization’s monitoring data.
-
-
- API method used:
- DataSet:GetStreamForDataset
-
+
+
+ Demonstrates how to get and display all of your organization’s monitoring data.
+
+
+ API method used:
+ DataSet:GetStreamForDataset
+
-
-
-
-
\ No newline at end of file
+
+
+
+
\ No newline at end of file
From 8518c0d2608307d6cf758b9b1d050fa18a936668 Mon Sep 17 00:00:00 2001
From: Paige Rossi <70241979+paigesrossi@users.noreply.github.com>
Date: Wed, 19 May 2021 11:33:15 -0700
Subject: [PATCH 084/363] ssl error note
---
README.md | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/README.md b/README.md
index d908aab..5db2cc7 100644
--- a/README.md
+++ b/README.md
@@ -310,6 +310,17 @@ Modify the following two lines in the **configuration.rb** file, replacing `true
Once this is complete, you can run your Ruby on Rails application again and you should be able to make API calls on your localhost.
+### Troubleshooting macOS SSL issue
+When using the Ruby launcher on OSX you may get the following error:
+
+```
+Faraday::SSLError (SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain))
+```
+Please update SSL certificates if rvm is your version manager. Or check [other steps for different scenarios](https://gemfury.com/help/could-not-verify-ssl-certificate/#updating-ssl-certificates).
+```
+$ rvm osx-ssl-certs status all
+$ rvm osx-ssl-certs update all
+```
## Payments code example
To use the payments code example, create a test payment gateway on the [**Payments**](https://admindemo.docusign.com/authenticate?goTo=payments) page in your developer account. See [Configure a payment gateway](./PAYMENTS_INSTALLATION.md) for details.
From 67229aaffcd6b0ab9f4c4485af1a48316f020686 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 24 May 2021 10:29:02 -0700
Subject: [PATCH 085/363] Bump nokogiri from 1.11.3 to 1.11.4 (#42)
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.11.3 to 1.11.4.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.11.3...v1.11.4)
Signed-off-by: dependabot[bot]
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
---
Gemfile.lock | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/Gemfile.lock b/Gemfile.lock
index ac8f29e..754e6f9 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -147,9 +147,11 @@ GEM
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.3-x64-mingw32)
+ nokogiri (1.11.4-x64-mingw32)
racc (~> 1.4)
- nokogiri (1.11.3-x86_64-darwin)
+ nokogiri (1.11.4-x86_64-darwin)
+ racc (~> 1.4)
+ nokogiri (1.11.4-x86_64-linux)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -218,6 +220,8 @@ GEM
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
+ sassc (2.4.0)
+ ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
sassc-rails (2.1.2)
@@ -271,6 +275,7 @@ GEM
PLATFORMS
x64-mingw32
x86_64-darwin-20
+ x86_64-linux
DEPENDENCIES
bootsnap (~> 1.7.3)
From 8200369bcd29010e088cfe43cbc9ca5b14a69b75 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 24 May 2021 10:29:49 -0700
Subject: [PATCH 086/363] Bump puma from 4.3.7 to 4.3.8 (#41)
Bumps [puma](https://github.com/puma/puma) from 4.3.7 to 4.3.8.
- [Release notes](https://github.com/puma/puma/releases)
- [Changelog](https://github.com/puma/puma/blob/master/History.md)
- [Commits](https://github.com/puma/puma/compare/v4.3.7...v4.3.8)
Signed-off-by: dependabot[bot]
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
---
Gemfile | 2 +-
Gemfile.lock | 6 ++++--
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/Gemfile b/Gemfile
index a803a99..a021b65 100644
--- a/Gemfile
+++ b/Gemfile
@@ -10,7 +10,7 @@ gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
-gem 'puma', '~> 4.3.3'
+gem 'puma', '~> 4.3.8'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 6.0.0'
# Use Uglifier as compressor for JavaScript assets
diff --git a/Gemfile.lock b/Gemfile.lock
index 754e6f9..e70d28c 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -153,6 +153,8 @@ GEM
racc (~> 1.4)
nokogiri (1.11.4-x86_64-linux)
racc (~> 1.4)
+ nokogiri (1.11.3-x86_64-linux)
+ racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -177,7 +179,7 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.7)
+ puma (4.3.8)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
@@ -293,7 +295,7 @@ DEPENDENCIES
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
- puma (~> 4.3.3)
+ puma (~> 4.3.8)
rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
From 1ad7da1d01329827e3d40c7e6f6e45d3612f7cba Mon Sep 17 00:00:00 2001
From: an-tk
Date: Tue, 25 May 2021 13:02:06 +0300
Subject: [PATCH 087/363] docusign_monitor monitor gem version update
---
Gemfile | 4 ++--
Gemfile.lock | 8 ++++----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/Gemfile b/Gemfile
index a803a99..6e83e20 100644
--- a/Gemfile
+++ b/Gemfile
@@ -67,7 +67,7 @@ group :test do
end
gem 'docusign_esign', '~> 3.8.0.rc1'
-gem 'docusign_monitor', '~> 1.0.1.pre.alpha'
+gem 'docusign_monitor', '~> 1.0.0.beta1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click', '~> 1.0.0'
gem 'omniauth-oauth2', '~> 1.7.1'
@@ -75,4 +75,4 @@ gem 'omniauth-rails_csrf_protection'
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', '~> 1.2019.3', platforms: %i[mingw mswin x64_mingw jruby]
-gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
\ No newline at end of file
+gem 'wdm', '>= 0.1.0', platforms: %i[mingw mswin x64_mingw]
diff --git a/Gemfile.lock b/Gemfile.lock
index 0ec4c95..1b5a9e2 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -151,6 +151,8 @@ GEM
racc (~> 1.4)
nokogiri (1.11.3-x86_64-darwin)
racc (~> 1.4)
+ nokogiri (1.11.3-x86_64-linux)
+ racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
jwt (>= 1.0, < 3.0)
@@ -253,11 +255,8 @@ GEM
ethon (>= 0.9.0)
tzinfo (1.2.9)
thread_safe (~> 0.1)
- tzinfo-data (1.2019.3)
- tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
- wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -273,6 +272,7 @@ GEM
PLATFORMS
x64-mingw32
x86_64-darwin-20
+ x86_64-linux
DEPENDENCIES
bootsnap (~> 1.7.3)
@@ -282,7 +282,7 @@ DEPENDENCIES
coffee-rails (~> 5.0.0)
docusign_click (~> 1.0.0)
docusign_esign (~> 3.8.0.rc1)
- docusign_monitor (~> 1.0.1.pre.alpha)
+ docusign_monitor (~> 1.0.0.beta1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
From f33053bbd1928e264c1ab3cdbd7ea3c98be96f15 Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Tue, 1 Jun 2021 13:09:06 -0700
Subject: [PATCH 088/363] readme updates
---
README.md | 203 +++++-------------------------------------------------
1 file changed, 19 insertions(+), 184 deletions(-)
diff --git a/README.md b/README.md
index 5db2cc7..0fdfdc3 100644
--- a/README.md
+++ b/README.md
@@ -2,209 +2,44 @@
### Github repo: https://github.com/docusign/code-examples-ruby
-To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
+This GitHub repo includes code examples for the DocuSign eSignature REST API, Rooms API, Click API, and Monitor API. To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
-Before you can make any API calls using [JWT Grant](https://developers.docusign.com/platform/auth/jwt/), you must get your user’s consent for your app to impersonate them. To do this, the `impersonation` scope is added when requesting a JSON Web Token.
-
-
## Introduction
-This repo is a Ruby on Rails application.
+This repo is a Ruby on Rails application that supports the following authentication workflows:
+
+* Authentication with DocuSign via [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode).
+When the token expires, the user is asked to re-authenticate. The refresh token is not used.
+* Authentication with DocuSign via [JSON Web Token (JWT) Grant](https://developers.docusign.com/platform/auth/jwt/).
+When the token expires, it updates automatically.
## eSignature API
-For more information about the scopes used for obtaining authorization to use the eSignature API, see the [Required Scopes section](https://developers.docusign.com/docs/esign-rest-api/esign101/auth).
-
-1. **Use embedded signing.**
- [Source.](app/services/e_sign/eg001_embedded_signing_service.rb)
- This example sends an envelope, and then uses embedded signing for the first signer.
- With embedded signing, the DocuSign signing is initiated from your website.
-1. **Request a signature by email (Remote Signing).**
- [Source.](app/services/e_sign/eg002_signing_via_email_service.rb)
- The envelope includes a pdf, Word, and HTML document.
- Anchor text ([AutoPlace](https://support.docusign.com/en/guides/AutoPlace-New-DocuSign-Experience)) is used to position the signing fields in the documents.
-1. **List envelopes in the user's account.**
- [Source.](app/services/e_sign/eg003_list_envelopes_service.rb)
- The envelopes' current status is included.
-1. **Get an envelope's basic information.**
- [Source.](app/services/e_sign/eg004_envelope_info_service.rb)
- The example lists the basic information about an envelope, including its overall status.
-1. **List an envelope's recipients**
- [Source.](./app/controllers/e_sign/eg005_envelope_recipients_controller.rb)
- Includes current recipient status.
-1. **List an envelope's documents.**
- [Source.](app/services/e_sign/eg006_envelope_docs_service.rb)
-1. **Download an envelope's documents.**
- [Source.](app/services/e_sign/eg007_envelope_get_doc_service.rb)
- The example can download individual
- documents, the documents concatenated together, or a zip file of the documents.
-1. **Programmatically create a template.**
- [Source.](app/services/e_sign/eg008_create_template_service.rb)
-1. **Request a signature by email using a template.**
- The example creates an envelope using a template and sets the initial values for some of its tabs (fields).
- [Source.](app/services/e_sign/eg009_use_template_service.rb)
-1. **Send an envelope and upload its documents with multpart binary transfer.**
- [Source.](app/services/e_sign/eg010_send_binary_docs_service.rb)
- Binary transfer is 33% more efficient than using Base64 encoding.
-1. **Use embedded sending.**
- [Source.](app/services/e_sign/eg011_embedded_sending_service.rb)
- Embeds the DocuSign web tool (NDSE) in your web app to finalize or update
- the envelope and documents before they are sent.
-1. **Embedded DocuSign web tool (NDSE).**
- [Source.](app/services/e_sign/eg012_embedded_console_service.rb)
-1. **Use embedded signing from a template with an added document.**
- [Source.](app/services/e_sign/eg013_add_doc_to_template_service.rb)
- This example sends an envelope based on a template.
- In addition to the template's document(s), the example adds an
- additional document to the envelope by using the
- [Composite Templates](https://developers.docusign.com/esign-rest-api/guides/features/templates#composite-templates)
- feature.
-1. **Payments example: an order form, with online payment by credit card.**
- [Source.](app/services/e_sign/eg014_collect_payment_service.rb)
-
-1. **Get the envelope tab data.**
- Retrieve the tab (field) values for all of the envelope's recipients.
- [Source.](app/services/e_sign/eg015_get_envelope_tab_data_service.rb)
-1. **Set envelope tab values.**
- The example creates an envelope and sets the initial values for its tabs (fields). Some of the tabs
- are set to be read-only, others can be updated by the recipient. The example also stores
- metadata with the envelope.
- [Source.](app/services/e_sign/eg016_set_envelope_tab_data_service.rb)
-1. **Set template tab values.**
- The example creates an envelope using a template and sets the initial values for its tabs (fields).
- The example also stores metadata with the envelope.
- [Source.](app/services/e_sign/eg017_set_template_tab_values_service.rb)
-1. **Get the envelope custom field data (metadata).**
- The example retrieves the custom metadata (custom data fields) stored with the envelope.
- [Source.](app/services/e_sign/eg018_get_envelope_custom_field_data_service.rb)
-1. **Requiring an Access Code for a Recipient**
- [Source.](app/services/e_sign/eg019_access_code_authentication_service.rb)
- This example sends an envelope that requires an access-code for the purpose of multi-factor authentication.
-1. **Requiring SMS authentication for a recipient**
- [Source.](app/services/e_sign/eg020_sms_authentication_service.rb)
- This example sends an envelope that requires entering in a six digit code from an text message for the purpose of multi-factor authentication.
-1. **Requiring Phone authentication for a recipient**
- [Source.](app/services/e_sign/eg021_phone_authentication_service.rb)
- This example sends an envelope that requires entering in a voice-based response code for the purpose of multi-factor authentication.
-1. **Requiring Knowledge-Based Authentication (KBA) for a Recipient**
- [Source.](app/services/e_sign/eg022_kba_authentication_service.rb)
- This example sends an envelope that requires passing a Public records check to validate identity for the purpose of multi-factor authentication.
-1. **Requiring ID Verification (IDV) for a recipient**
- [Source.](app/services/e_sign/eg023_idv_authentication_service.rb)
- This example sends an envelope that requires the recipient to upload a government issued id.
-
-1. **Creating a permission profile**
- [Source.](app/services/e_sign/eg024_permission_create_service.rb)
- This code example demonstrates how to create a user group's permission profile using the [Create Profile](https://developers.docusign.com/esign-rest-api/reference/UserGroups/Groups/create) method.
-1. **Setting a permission profile**
- [Source.](app/services/e_sign/eg025_permissions_set_user_group_service.rb)
- This code example demonstrates how to set a user group's permission profile using the [Update Group](https://developers.docusign.com/esign-rest-api/reference/UserGroups/Groups/update) method.
- You must have already created permissions profile and group of users.
-1. **Updating individual permission settings**
- [Source.](app/services/e_sign/eg026_permissions_change_single_setting_service.rb)
- This code example demonstrates how to update individual settings for a specific permission profile using the [Update Permission Profile](https://developers.docusign.com/esign-rest-api/reference/Accounts/AccountPermissionProfiles/update) method.
- You must have already created permissions profile and group of users.
-1. **Deleting a permission profile**
- [Source.](app/services/e_sign/eg027_permissions_delete_service.rb)
- This code example demonstrates how to an account's permission profile using the [Delete AccountPermissionProfiles](https://developers.docusign.com/esign-rest-api/reference/Accounts/AccountPermissionProfiles/delete) method.
- You cannot delete the Everyone nor the Administrator profile types as those are defaults.
-
-1. **Creating a brand**
- [Source.](app/services/e_sign/eg028_brands_creating_service.rb)
- This example creates brand profile for an account using the [Create Brand](https://developers.docusign.com/esign-rest-api/reference/Accounts/AccountBrands/create) method.
-1. **Applying a brand to an envelope**
- [Source.](app/services/e_sign/eg029_brands_apply_to_envelope_service.rb)
- This code example demonstrates how to apply a brand you've created to an envelope using the [Create Envelope](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
- First, creates the envelope and then applies brand to it.
-
-1. **Applying a brand to a template**
- [Source.](app/services/e_sign/eg030_brands_apply_to_template_service.rb)
- This code example demonstrates how to apply a brand you've created to a template using using the [Create Envelope](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
- You must have at least one created template and brand.
-
-1. **Bulk sending envelopes to multiple recipients**
- [Source.](app/services/e_sign/eg031_bulk_sending_envelopes_service.rb)
- This example creates and sends a bulk envelope by generating a bulk recipient list and initiating a bulk send.
-
-1. **Pausing a signature workflow**
- [Source.](app/services/e_sign/eg032_pauses_signature_workflow_service.rb)
- This example demonstrates how to create an envelope where the workflow is paused before the envelope is sent to a second recipient.
-
-1. **Unpausing a signature workflow**
- [Source.](app/services/e_sign/eg033_unpauses_signature_workflow_service.rb)
- This example demonstrates how to resume an envelope workflow that has been paused.
-
-1. **Using conditional recipients**
- [Source.](app/services/e_sign/eg034_use_conditional_recipients_service.rb)
- This example demonstrates how to create an envelope where the workflow is routed to different recipients based on the value of a transaction.
-
-1. **Request a signature by SMS delivery**
- [Source.](app/services/e_sign/eg035_sms_delivery_service.rb)
- This code example demonstrates how to send a signature request via an SMS message using the [Envelopes: create](https://developers.docusign.com/esign-rest-api/reference/Envelopes/Envelopes/create) method.
+For more information about the scopes used for obtaining authorization to use the eSignature API, see [Required scopes](https://developers.docusign.com/docs/esign-rest-api/esign101/auth#required-scopes).
+For a list of code examples that use the eSignature API, select the Ruby tab under [Examples and languages](https://developers.docusign.com/docs/esign-rest-api/how-to/code-launchers#examples-and-languages) on the DocuSign Developer Center.
## Rooms API
-**Note:** To use the Rooms API, you must also [create a Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account).
-For more information about the scopes used for obtaining authorization to use the Rooms API, see the [Required Scopes section](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
-
-1. **Create a room with data.**
- [Source.](./app/services/room_api/eg001_create_room_with_data_service.rb)
- This example creates a new room in your DocuSign Rooms account to be used for a transaction.
-1. **Create a room from a template.**
- [Source.](./app/services/room_api/eg002_create_room_with_template_service.rb)
- This example creates a new room using a template.
-1. **Export data from a room.**
- [Source.](./app/services/room_api/eg003_export_data_from_room_service.rb)
- This example exports all the available data from a specific room in your DocuSign Rooms account.
-1. **Add forms to a room.**
- [Source.](./app/services/room_api/eg004_add_forms_to_room_service.rb)
- This example adds a standard real estate related form to a specific room in your DocuSign Rooms account.
-1. **Search for rooms with filters.**
- [Source.](./app/services/room_api/eg005_get_rooms_with_filters_service.rb)
- This example searches for rooms in your DocuSign Rooms account using a specific filter.
-1. **Get an external form fillable session.**
- [Source.](./app/services/room_api/eg006_create_an_external_form_fill_session_service.rb)
- This example creates an external form that can be filled using DocuSign for a specific room in your DocuSign Rooms account.
-1. **Creating a form group.**
- [Source.](./app/services/room_api/eg007_create_form_group_service.rb)
- This example creates a new form group with the name given in the name property of the request body.
-1. **Grant office access to a form group.**
- [Source.](./app/services/room_api/eg008_grant_office_access_to_form_group_service.rb)
- This example assigns an office to a form group for your DocuSign Rooms.
-1. **Assign a form to a form group.**
- [Source.](./app/services/room_api/eg009_assign_form_to_form_group_service.rb)
- This example assigns a form to a form group for your DocuSign Rooms.
+**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account). Examples 4 and 6 require that you have the DocuSign Forms feature enabled in your Rooms for Real Estate account.
+For more information about the scopes used for obtaining authorization to use the Rooms API, see [Required scopes](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
+For a list of code examples that use the Rooms API, select the Ruby tab under [Examples and languages](https://developers.docusign.com/docs/rooms-api/how-to/code-launchers#examples-and-languages) on the DocuSign Developer Center.
## Click API
-For more information about the scopes used for obtaining authorization to use the Clickwrap API, see the [Required Scopes section](https://developers.docusign.com/docs/click-api/click101/auth).
-
-1. **Creating a clickwrap.**
-[Source.](./app/services/clickwrap/eg001_create_clickwrap_service.rb)
-This example demonstrates how to use the Click API to create a clickwrap that you can embed in your website or app.
-1. **Activate a clickwrap.**
-[Source.](./app/services/clickwrap/eg002_activate_clickwrap_service.rb)
-This example demonstrates how to use the Click API to activate a new clickwrap that you have already created.
-1. **Creating a new clickwrap version.**
-[Source.](./app/services/clickwrap/eg003_create_new_clickwrap_version_service.rb)
-This example demonstrates how to use the Click API to create a new version of a clickwrap.
-1. **Getting a list of clickwraps.**
-[Source.](./app/services/clickwrap/eg004_list_clickwraps_service.rb)
-This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
-1. **Getting clickwrap responses.**
-[Source.](./app/services/clickwrap/eg005_clickwrap_responses_service.rb)
-This example demonstrates how to use the Click API to get a list of clickwraps associated with a specific DocuSign user.
+For more information about the scopes used for obtaining authorization to use the Click API, see [Required scopes](https://developers.docusign.com/docs/click-api/click101/auth/#required-scopes).
+
+For a list of code examples that use the Click API, select the Ruby tab under [Examples and languages](https://developers.docusign.com/docs/click-api/how-to/code-launchers#examples-and-languages) on the DocuSign Developer Center.
## Monitor API
-**Note:** To use the Monitor API, you must also [enable DocuSign Monitor for your organization](https://developers.docusign.com/docs/monitor-api/how-to/enable-monitor/).
+
+**Note:** To use the Monitor API, you must also [enable DocuSign Monitor for your organization](https://developers.docusign.com/docs/monitor-api/how-to/enable-monitor/).
For information about the scopes used for obtaining authorization to use the Monitor API, see the [scopes section](https://developers.docusign.com/docs/monitor-api/monitor101/auth/).
-1. **Get monitoring data.** [Source](app/services/monitor_api/eg001_get_monitoring_dataset_service.rb)
- Demonstrates how to get and display all of your organization’s monitoring data.
+For a list of code examples that use the Monitor API, select the Ruby tab under [Examples and languages](https://developers.docusign.com/docs/monitor-api/how-to/code-launchers/#examples-and-languages) on the DocuSign Developer Center.
## Installation
@@ -247,7 +82,7 @@ For information about the scopes used for obtaining authorization to use the Mon
1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
-1. Install the dependencies: `bundler install`
+1. To install dependencies, run: `bundler install`
1. To configure the launcher for [Authorization Code Grant](https://developers.docusign.com/platform/auth/authcode/) authentication, create a copy of the file config/appsettings.example.yml and save the copy as config/appsettings.yml.
1. Add your integration key. On the [Apps and Keys](https://admindemo.docusign.com/authenticate?goTo=apiIntegratorKey) page, under **Apps and Integration Keys**, choose the app to use, then select **Actions** > **Edit**. Under **General Info**, copy the **Integration Key** GUID and save it in appsettings.yml as your `integration_key`.
1. Generate a secret key, if you don’t already have one. Under **Authentication**, select **+ ADD SECRET KEY**. Copy the secret key and save it in appsettings.yml as your `integration_secret`.
From 2854aaca1b7db88848342b1f499756fee539fac0 Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Tue, 1 Jun 2021 16:19:35 -0700
Subject: [PATCH 089/363] responding to PR comments
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 0fdfdc3..44a983c 100644
--- a/README.md
+++ b/README.md
@@ -1,8 +1,8 @@
# Ruby Launcher Code Examples
-### Github repo: https://github.com/docusign/code-examples-ruby
+### Github repo: [code-examples-ruby](./)
-This GitHub repo includes code examples for the DocuSign eSignature REST API, Rooms API, Click API, and Monitor API. To switch between API code examples, modify the `examples_API` setting at the end of the configuration file. Set only one API type to `true` and set the remaining to `false`.
+This GitHub repo includes code examples for the DocuSign eSignature REST API, Rooms API, Click API, and Monitor API. To switch between API code examples, modify the `examples_API` setting in the appsettings.yml file. Set only one API type to `true` and set the remaining to `false`.
If none of the API types are set to `true`, the DocuSign eSignature REST API code examples will be shown. If multiple API types are set to `true`, only the first will be shown.
@@ -79,7 +79,7 @@ For a list of code examples that use the Monitor API, select the Ruby tab under
### Installation steps
**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.
-1. Extract the Quickstart ZIP file or download or clone the code-examples-ruby repository.
+1. Extract the Quickstart ZIP file, or download or clone the code-examples-ruby repository.
1. In your command-line environment, switch to the folder:
`cd ` or `cd code-examples-ruby`
1. To install dependencies, run: `bundler install`
From 229860c7abfd0aa9a8f4cce6fb599be2c42a4586 Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Tue, 1 Jun 2021 16:20:27 -0700
Subject: [PATCH 090/363] last small fix
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 44a983c..1becc0d 100644
--- a/README.md
+++ b/README.md
@@ -23,7 +23,7 @@ For a list of code examples that use the eSignature API, select the Ruby tab und
## Rooms API
-**Note:** To use the Rooms API you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account). Examples 4 and 6 require that you have the DocuSign Forms feature enabled in your Rooms for Real Estate account.
+**Note:** To use the Rooms API, you must also [create your Rooms developer account](https://developers.docusign.com/docs/rooms-api/rooms101/create-account). Examples 4 and 6 require that you have the DocuSign Forms feature enabled in your Rooms for Real Estate account.
For more information about the scopes used for obtaining authorization to use the Rooms API, see [Required scopes](https://developers.docusign.com/docs/rooms-api/rooms101/auth/).
For a list of code examples that use the Rooms API, select the Ruby tab under [Examples and languages](https://developers.docusign.com/docs/rooms-api/how-to/code-launchers#examples-and-languages) on the DocuSign Developer Center.
From 46063fbc5754e483426cc65dd6fcec8d17c986ab Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 3 Jun 2021 16:41:44 -0700
Subject: [PATCH 091/363] fix first link
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 1becc0d..64d5afd 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# Ruby Launcher Code Examples
-### Github repo: [code-examples-ruby](./)
+### GitHub repo: [code-examples-ruby](./README.md)
This GitHub repo includes code examples for the DocuSign eSignature REST API, Rooms API, Click API, and Monitor API. To switch between API code examples, modify the `examples_API` setting in the appsettings.yml file. Set only one API type to `true` and set the remaining to `false`.
From 83f840f614f3c91a5119c994d35cdb14200acfe2 Mon Sep 17 00:00:00 2001
From: meihDS <70775251+meihDS@users.noreply.github.com>
Date: Thu, 3 Jun 2021 16:42:26 -0700
Subject: [PATCH 092/363] fix first link
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 1becc0d..64d5afd 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# Ruby Launcher Code Examples
-### Github repo: [code-examples-ruby](./)
+### GitHub repo: [code-examples-ruby](./README.md)
This GitHub repo includes code examples for the DocuSign eSignature REST API, Rooms API, Click API, and Monitor API. To switch between API code examples, modify the `examples_API` setting in the appsettings.yml file. Set only one API type to `true` and set the remaining to `false`.
From 3dc75a62c1c47e6e4b46fed7b9288c20dc14219d Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Fri, 4 Jun 2021 15:18:36 -0700
Subject: [PATCH 093/363] updating gem file to use new SDK
---
Gemfile.lock | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/Gemfile.lock b/Gemfile.lock
index 1b5a9e2..a2b2ca4 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -96,7 +96,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_monitor (1.0.1.pre.alpha)
+ docusign_monitor (1.0.0.beta1)
addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
@@ -271,6 +271,7 @@ GEM
PLATFORMS
x64-mingw32
+ x86_64-darwin-19
x86_64-darwin-20
x86_64-linux
From 4fbe949fe292d62be33456653edab76935a80a83 Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Mon, 7 Jun 2021 12:54:27 -0700
Subject: [PATCH 094/363] updating to use new sdk and new method name
---
.../eg001_get_monitoring_dataset_service.rb | 20 +++++--------------
.../eg001_get_monitoring_dataset/get.html.erb | 2 +-
app/views/monitor_api/index.html.erb | 2 +-
3 files changed, 7 insertions(+), 17 deletions(-)
diff --git a/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
index 7722e6a..8fee741 100644
--- a/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
+++ b/app/services/monitor_api/eg001_get_monitoring_dataset_service.rb
@@ -23,24 +23,14 @@ def call
# step 3 start
monitor_api = DocuSign_Monitor::DataSetApi.new(api_client)
- options = DocuSign_Monitor::GetStreamForDatasetOptions.default
+ options = DocuSign_Monitor::GetStreamOptions.default
+ @response = monitor_api.get_stream('monitor', '2.0').data
- while true do
- options.cursor = @cursor
- response = monitor_api.get_stream_for_dataset('monitor', '2.0', options).first
-
- # If the endCursor from the response is the same as the one that you already have,
- # it means that you have reached the end of the records
- break if response[:endCursor] == @cursor
-
- @results_memo.push(response)
- @cursor = response[:endCursor]
- end
- # step 3 end
+ # step 3 end
Rails.logger.info "Responses for loops are displayed here. Only the final loop is displayed on the response page"
- Rails.logger.info @results_memo.inspect
+ Rails.logger.info @response.inspect
- return @results_memo
+ return @response
end
end
diff --git a/app/views/monitor_api/eg001_get_monitoring_dataset/get.html.erb b/app/views/monitor_api/eg001_get_monitoring_dataset/get.html.erb
index 898ca82..c8838fa 100644
--- a/app/views/monitor_api/eg001_get_monitoring_dataset/get.html.erb
+++ b/app/views/monitor_api/eg001_get_monitoring_dataset/get.html.erb
@@ -2,7 +2,7 @@
Demonstrates how to get and display all of your organization’s monitoring data.
API method used:
- DataSet:GetStreamForDataset
+ DataSet:GetStream
diff --git a/app/views/monitor_api/index.html.erb b/app/views/monitor_api/index.html.erb
index 054cdb1..7f747c4 100644
--- a/app/views/monitor_api/index.html.erb
+++ b/app/views/monitor_api/index.html.erb
@@ -30,7 +30,7 @@
API method used:
- DataSet:GetStreamForDataset
+ DataSet:GetStream
From 38f15bd4b847631b0b8e30128a2484a41b0a88ae Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Wed, 9 Jun 2021 09:49:02 -0700
Subject: [PATCH 095/363] update esign sdk and eg034 (#34)
---
Gemfile | 2 +-
Gemfile.lock | 9 +++++++--
.../e_sign/eg034_use_conditional_recipients_service.rb | 6 ++++--
3 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/Gemfile b/Gemfile
index 6e83e20..71fc08e 100644
--- a/Gemfile
+++ b/Gemfile
@@ -66,7 +66,7 @@ group :test do
gem 'chromedriver-helper', '~> 2.1.1'
end
-gem 'docusign_esign', '~> 3.8.0.rc1'
+gem 'docusign_esign', '~> 3.10.0.rc1'
gem 'docusign_monitor', '~> 1.0.0.beta1'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click', '~> 1.0.0'
diff --git a/Gemfile.lock b/Gemfile.lock
index 713255a..5ec47f0 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -92,7 +92,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_esign (3.8.0.rc1)
+ docusign_esign (3.10.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
@@ -220,6 +220,8 @@ GEM
rubyzip (2.3.0)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
+ sassc (2.4.0)
+ ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
sassc-rails (2.1.2)
@@ -253,8 +255,11 @@ GEM
ethon (>= 0.9.0)
tzinfo (1.2.9)
thread_safe (~> 0.1)
+ tzinfo-data (1.2019.3)
+ tzinfo (>= 1.0.0)
uglifier (4.2.0)
execjs (>= 0.3.0, < 3)
+ wdm (0.1.1)
web-console (4.0.4)
actionview (>= 6.0.0)
activemodel (>= 6.0.0)
@@ -280,7 +285,7 @@ DEPENDENCIES
chromedriver-helper (~> 2.1.1)
coffee-rails (~> 5.0.0)
docusign_click (~> 1.0.0)
- docusign_esign (~> 3.8.0.rc1)
+ docusign_esign (~> 3.10.0.rc1)
docusign_monitor (~> 1.0.0.beta1)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
diff --git a/app/services/e_sign/eg034_use_conditional_recipients_service.rb b/app/services/e_sign/eg034_use_conditional_recipients_service.rb
index 8cf17bf..0c09ef1 100644
--- a/app/services/e_sign/eg034_use_conditional_recipients_service.rb
+++ b/app/services/e_sign/eg034_use_conditional_recipients_service.rb
@@ -134,7 +134,8 @@ def call
tabId: 'ApprovalTab',
operator: 'equals',
value: false,
- tabLabel: 'ApproveWhenChecked'
+ tabLabel: 'ApproveWhenChecked',
+ tabType: 'checkbox'
)
filter2 = DocuSign_eSign::ConditionalRecipientRuleFilter.new(
scope: 'tabs',
@@ -142,7 +143,8 @@ def call
tabId: 'ApprovalTab',
operator: 'equals',
value: true,
- tabLabel: 'ApproveWhenChecked'
+ tabLabel: 'ApproveWhenChecked',
+ tabType: 'checkbox'
)
# Create conditionalRecipientRuleCondition models
From 90015bd814942b30dc95d880e8e9d4a236036679 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Fri, 11 Jun 2021 12:24:17 -0700
Subject: [PATCH 096/363] move eg001_embedded_signing (#33)
---
.../{e_sign => }/eg001_embedded_signing_controller.rb | 4 ++--
app/services/{e_sign => }/eg001_embedded_signing_service.rb | 2 +-
app/views/{e_sign => }/eg001_embedded_signing/get.html.erb | 0
config/routes.rb | 6 +++---
4 files changed, 6 insertions(+), 6 deletions(-)
rename app/controllers/{e_sign => }/eg001_embedded_signing_controller.rb (81%)
rename app/services/{e_sign => }/eg001_embedded_signing_service.rb (99%)
rename app/views/{e_sign => }/eg001_embedded_signing/get.html.erb (100%)
diff --git a/app/controllers/e_sign/eg001_embedded_signing_controller.rb b/app/controllers/eg001_embedded_signing_controller.rb
similarity index 81%
rename from app/controllers/e_sign/eg001_embedded_signing_controller.rb
rename to app/controllers/eg001_embedded_signing_controller.rb
index 3b00793..6e5a05d 100644
--- a/app/controllers/e_sign/eg001_embedded_signing_controller.rb
+++ b/app/controllers/eg001_embedded_signing_controller.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class ESign::Eg001EmbeddedSigningController < EgController
+class Eg001EmbeddedSigningController < EgController
def create
minimum_buffer_min = 10
token_ok = check_token(minimum_buffer_min)
@@ -13,7 +13,7 @@ def create
# authentication.
redirect_to '/ds/mustAuthenticate'
end
- redirect_url = ESign::Eg001EmbeddedSigningService.new(session, request).call
+ redirect_url = Eg001EmbeddedSigningService.new(session, request).call
redirect_to redirect_url
end
diff --git a/app/services/e_sign/eg001_embedded_signing_service.rb b/app/services/eg001_embedded_signing_service.rb
similarity index 99%
rename from app/services/e_sign/eg001_embedded_signing_service.rb
rename to app/services/eg001_embedded_signing_service.rb
index 8c398d5..9c8190a 100644
--- a/app/services/e_sign/eg001_embedded_signing_service.rb
+++ b/app/services/eg001_embedded_signing_service.rb
@@ -1,6 +1,6 @@
# frozen_string_literal: true
-class ESign::Eg001EmbeddedSigningService
+class Eg001EmbeddedSigningService
include ApiCreator
attr_reader :signer_email, :signer_name, :args
diff --git a/app/views/e_sign/eg001_embedded_signing/get.html.erb b/app/views/eg001_embedded_signing/get.html.erb
similarity index 100%
rename from app/views/e_sign/eg001_embedded_signing/get.html.erb
rename to app/views/eg001_embedded_signing/get.html.erb
diff --git a/config/routes.rb b/config/routes.rb
index 97cb804..8c61a8e 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -54,11 +54,11 @@
post 'eg001' => 'eg001_get_monitoring_dataset#create'
end
else
+ get '/eg001' => 'eg001_embedded_signing#get'
+ post '/eg001' => 'eg001_embedded_signing#create'
+
scope module: 'e_sign' do
# Example controllers...
- get 'eg001' => 'eg001_embedded_signing#get'
- post 'eg001' => 'eg001_embedded_signing#create'
-
get 'eg002' => 'eg002_signing_via_email#get'
post 'eg002' => 'eg002_signing_via_email#create'
From c0ba7bc58e209105fad2280f6f9ef07d8d98e364 Mon Sep 17 00:00:00 2001
From: Paige Rossi
Date: Thu, 17 Jun 2021 14:30:22 -0700
Subject: [PATCH 097/363] re-labeling example done page with correct method
name
---
.../e_sign/eg015_get_envelope_tab_data_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/controllers/e_sign/eg015_get_envelope_tab_data_controller.rb b/app/controllers/e_sign/eg015_get_envelope_tab_data_controller.rb
index 9f6b6e2..20f7d24 100644
--- a/app/controllers/e_sign/eg015_get_envelope_tab_data_controller.rb
+++ b/app/controllers/e_sign/eg015_get_envelope_tab_data_controller.rb
@@ -8,7 +8,7 @@ def create
if token_ok
results = ESign::Eg015GetEnvelopeTabDataService.new(envelope_id, session).call
@h1 = 'List envelopes results'
- @message = 'Results from the Envelopes::listStatusChanges method:'
+ @message = 'Results from the EnvelopeFormData::get method:'
@json = results.to_json.to_json
render 'ds_common/example_done'
else
From 157ccc76f39256b41f7faff0449415204cd72644 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Thu, 17 Jun 2021 21:55:08 +0000
Subject: [PATCH 098/363] Bump puma from 4.3.7 to 4.3.8
Bumps [puma](https://github.com/puma/puma) from 4.3.7 to 4.3.8.
- [Release notes](https://github.com/puma/puma/releases)
- [Changelog](https://github.com/puma/puma/blob/master/History.md)
- [Commits](https://github.com/puma/puma/compare/v4.3.7...v4.3.8)
---
updated-dependencies:
- dependency-name: puma
dependency-type: direct:production
...
Signed-off-by: dependabot[bot]
---
Gemfile | 2 +-
Gemfile.lock | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Gemfile b/Gemfile
index e44be3a..a5f5477 100644
--- a/Gemfile
+++ b/Gemfile
@@ -10,7 +10,7 @@ gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
-gem 'puma', '~> 4.3.3'
+gem 'puma', '~> 4.3.8'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 6.0.0'
# Use Uglifier as compressor for JavaScript assets
diff --git a/Gemfile.lock b/Gemfile.lock
index a9a9ab2..1ae1bcd 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -170,7 +170,7 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.7)
+ puma (4.3.8)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
@@ -284,7 +284,7 @@ DEPENDENCIES
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
- puma (~> 4.3.3)
+ puma (~> 4.3.8)
rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
From 92250fa345358a90cacc91cfa5b766f257563240 Mon Sep 17 00:00:00 2001
From: karissarjacobsen <73908223+karissarjacobsen@users.noreply.github.com>
Date: Mon, 28 Jun 2021 13:24:56 -0700
Subject: [PATCH 099/363] Devdocs 5062 (#37)
* Bump puma from 4.3.7 to 4.3.8
Bumps [puma](https://github.com/puma/puma) from 4.3.7 to 4.3.8.
- [Release notes](https://github.com/puma/puma/releases)
- [Changelog](https://github.com/puma/puma/blob/master/History.md)
- [Commits](https://github.com/puma/puma/compare/v4.3.7...v4.3.8)
Signed-off-by: dependabot[bot]
* Bump nokogiri from 1.11.3 to 1.11.7
Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.11.3 to 1.11.7.
- [Release notes](https://github.com/sparklemotion/nokogiri/releases)
- [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.11.3...v1.11.7)
---
updated-dependencies:
- dependency-name: nokogiri
dependency-type: indirect
...
Signed-off-by: dependabot[bot]
* update dependencies
* update gemfile.lock
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
---
Gemfile | 2 +-
Gemfile.lock | 136 ++++++++++++++++++++++++++-------------------------
2 files changed, 71 insertions(+), 67 deletions(-)
diff --git a/Gemfile b/Gemfile
index 71fc08e..f29ee6c 100644
--- a/Gemfile
+++ b/Gemfile
@@ -10,7 +10,7 @@ gem 'rails', '~> 6.0.3.5'
# Use sqlite3 as the database for Active Record
gem 'sqlite3', '~> 1.4.2'
# Use Puma as the app server
-gem 'puma', '~> 4.3.3'
+gem 'puma', '~> 4.3.8'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 6.0.0'
# Use Uglifier as compressor for JavaScript assets
diff --git a/Gemfile.lock b/Gemfile.lock
index 5ec47f0..dea001a 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,56 +1,56 @@
GEM
remote: https://rubygems.org/
specs:
- actioncable (6.0.3.6)
- actionpack (= 6.0.3.6)
+ actioncable (6.0.3.7)
+ actionpack (= 6.0.3.7)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
- actionmailbox (6.0.3.6)
- actionpack (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionmailbox (6.0.3.7)
+ actionpack (= 6.0.3.7)
+ activejob (= 6.0.3.7)
+ activerecord (= 6.0.3.7)
+ activestorage (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
mail (>= 2.7.1)
- actionmailer (6.0.3.6)
- actionpack (= 6.0.3.6)
- actionview (= 6.0.3.6)
- activejob (= 6.0.3.6)
+ actionmailer (6.0.3.7)
+ actionpack (= 6.0.3.7)
+ actionview (= 6.0.3.7)
+ activejob (= 6.0.3.7)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
- actionpack (6.0.3.6)
- actionview (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionpack (6.0.3.7)
+ actionview (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
- actiontext (6.0.3.6)
- actionpack (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ actiontext (6.0.3.7)
+ actionpack (= 6.0.3.7)
+ activerecord (= 6.0.3.7)
+ activestorage (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
nokogiri (>= 1.8.5)
- actionview (6.0.3.6)
- activesupport (= 6.0.3.6)
+ actionview (6.0.3.7)
+ activesupport (= 6.0.3.7)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
- activejob (6.0.3.6)
- activesupport (= 6.0.3.6)
+ activejob (6.0.3.7)
+ activesupport (= 6.0.3.7)
globalid (>= 0.3.6)
- activemodel (6.0.3.6)
- activesupport (= 6.0.3.6)
- activerecord (6.0.3.6)
- activemodel (= 6.0.3.6)
- activesupport (= 6.0.3.6)
- activestorage (6.0.3.6)
- actionpack (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activerecord (= 6.0.3.6)
+ activemodel (6.0.3.7)
+ activesupport (= 6.0.3.7)
+ activerecord (6.0.3.7)
+ activemodel (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
+ activestorage (6.0.3.7)
+ actionpack (= 6.0.3.7)
+ activejob (= 6.0.3.7)
+ activerecord (= 6.0.3.7)
marcel (~> 1.0.0)
- activesupport (6.0.3.6)
+ activesupport (6.0.3.7)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
@@ -61,7 +61,7 @@ GEM
archive-zip (0.12.0)
io-like (~> 0.3.0)
bindex (0.8.1)
- bootsnap (1.7.4)
+ bootsnap (1.7.5)
msgpack (~> 1.0)
builder (3.2.4)
byebug (11.1.3)
@@ -85,7 +85,7 @@ GEM
coffee-script-source
execjs
coffee-script-source (1.12.2)
- concurrent-ruby (1.1.8)
+ concurrent-ruby (1.1.9)
crass (1.0.6)
docusign_click (1.0.0)
addressable (~> 2.7, >= 2.7.0)
@@ -96,7 +96,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_monitor (1.0.0.beta1)
+ docusign_monitor (1.0.1.pre.alpha)
addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
@@ -106,20 +106,24 @@ GEM
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
erubi (1.10.0)
- ethon (0.13.0)
+ ethon (0.14.0)
ffi (>= 1.15.0)
- execjs (2.7.0)
- faraday (1.4.1)
+ execjs (2.8.1)
+ faraday (1.4.3)
+ faraday-em_http (~> 1.0)
+ faraday-em_synchrony (~> 1.0)
faraday-excon (~> 1.1)
faraday-net_http (~> 1.0)
faraday-net_http_persistent (~> 1.1)
multipart-post (>= 1.2, < 3)
ruby2_keywords (>= 0.0.4)
+ faraday-em_http (1.0.0)
+ faraday-em_synchrony (1.0.0)
faraday-excon (1.1.0)
faraday-net_http (1.0.1)
faraday-net_http_persistent (1.1.0)
- ffi (1.15.0)
- ffi (1.15.0-x64-mingw32)
+ ffi (1.15.3)
+ ffi (1.15.3-x64-mingw32)
globalid (0.4.2)
activesupport (>= 4.2.0)
hashie (4.1.0)
@@ -133,7 +137,7 @@ GEM
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
- loofah (2.9.1)
+ loofah (2.10.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.1)
@@ -147,11 +151,11 @@ GEM
multi_xml (0.6.0)
multipart-post (2.1.1)
nio4r (2.5.7)
- nokogiri (1.11.3-x64-mingw32)
+ nokogiri (1.11.7-x64-mingw32)
racc (~> 1.4)
- nokogiri (1.11.3-x86_64-darwin)
+ nokogiri (1.11.7-x86_64-darwin)
racc (~> 1.4)
- nokogiri (1.11.3-x86_64-linux)
+ nokogiri (1.11.7-x86_64-linux)
racc (~> 1.4)
oauth2 (1.4.7)
faraday (>= 0.8, < 2.0)
@@ -177,7 +181,7 @@ GEM
pry-rails (0.3.9)
pry (>= 0.10.4)
public_suffix (4.0.6)
- puma (4.3.7)
+ puma (4.3.8)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
@@ -185,34 +189,34 @@ GEM
rack
rack-test (1.1.0)
rack (>= 1.0, < 3)
- rails (6.0.3.6)
- actioncable (= 6.0.3.6)
- actionmailbox (= 6.0.3.6)
- actionmailer (= 6.0.3.6)
- actionpack (= 6.0.3.6)
- actiontext (= 6.0.3.6)
- actionview (= 6.0.3.6)
- activejob (= 6.0.3.6)
- activemodel (= 6.0.3.6)
- activerecord (= 6.0.3.6)
- activestorage (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ rails (6.0.3.7)
+ actioncable (= 6.0.3.7)
+ actionmailbox (= 6.0.3.7)
+ actionmailer (= 6.0.3.7)
+ actionpack (= 6.0.3.7)
+ actiontext (= 6.0.3.7)
+ actionview (= 6.0.3.7)
+ activejob (= 6.0.3.7)
+ activemodel (= 6.0.3.7)
+ activerecord (= 6.0.3.7)
+ activestorage (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
bundler (>= 1.3.0)
- railties (= 6.0.3.6)
+ railties (= 6.0.3.7)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.3.0)
loofah (~> 2.3)
- railties (6.0.3.6)
- actionpack (= 6.0.3.6)
- activesupport (= 6.0.3.6)
+ railties (6.0.3.7)
+ actionpack (= 6.0.3.7)
+ activesupport (= 6.0.3.7)
method_source
rake (>= 0.8.7)
thor (>= 0.20.3, < 2.0)
rake (13.0.3)
- rb-fsevent (0.10.4)
+ rb-fsevent (0.11.0)
rb-inotify (0.10.1)
ffi (~> 1.0)
regexp_parser (1.8.2)
@@ -265,7 +269,7 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- websocket-driver (0.7.3)
+ websocket-driver (0.7.5)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
xpath (3.2.0)
@@ -294,7 +298,7 @@ DEPENDENCIES
omniauth-rails_csrf_protection
pry-nav (~> 0.3.0)
pry-rails (~> 0.3.9)
- puma (~> 4.3.3)
+ puma (~> 4.3.8)
rails (~> 6.0.3.5)
sass-rails (~> 6.0.0)
selenium-webdriver (~> 3.142.7)
From 5e4542347e72077df95be1569ca0734cb43f1d46 Mon Sep 17 00:00:00 2001
From: Karissa Jacobsen
Date: Mon, 28 Jun 2021 15:31:46 -0700
Subject: [PATCH 100/363] update Monitor SDK version
---
Gemfile | 2 +-
Gemfile.lock | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Gemfile b/Gemfile
index 71fc08e..b665475 100644
--- a/Gemfile
+++ b/Gemfile
@@ -67,7 +67,7 @@ group :test do
end
gem 'docusign_esign', '~> 3.10.0.rc1'
-gem 'docusign_monitor', '~> 1.0.0.beta1'
+gem 'docusign_monitor', '~> 1.0.0'
gem 'docusign_rooms', '~> 1.1.0.rc1'
gem 'docusign_click', '~> 1.0.0'
gem 'omniauth-oauth2', '~> 1.7.1'
diff --git a/Gemfile.lock b/Gemfile.lock
index 5ec47f0..11796ec 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -96,7 +96,7 @@ GEM
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
typhoeus (~> 1.0, >= 1.0.1)
- docusign_monitor (1.0.0.beta1)
+ docusign_monitor (1.0.0)
addressable (~> 2.7, >= 2.7.0)
json (~> 2.1, >= 2.1.0)
jwt (~> 2.2, >= 2.2.1)
@@ -286,7 +286,7 @@ DEPENDENCIES
coffee-rails (~> 5.0.0)
docusign_click (~> 1.0.0)
docusign_esign (~> 3.10.0.rc1)
- docusign_monitor (~> 1.0.0.beta1)
+ docusign_monitor (~> 1.0.0)
docusign_rooms (~> 1.1.0.rc1)
jbuilder (~> 2.10.0)
listen (~> 3.2.1)
From fc8e619bc82d75400535aeff39d6548c09a59ce9 Mon Sep 17 00:00:00 2001
From: Matthew Lusher
Date: Mon, 12 Jul 2021 19:42:07 -0400
Subject: [PATCH 101/363] Updating links to DevCenter
---
.../eg013_add_doc_to_template_service.rb | 2 +-
app/views/ds_common/index.html.erb | 84 +++++++++----------
.../eg002_signing_via_email/get.html.erb | 4 +-
.../e_sign/eg003_list_envelopes/get.html.erb | 2 +-
.../e_sign/eg004_envelope_info/get.html.erb | 2 +-
.../eg005_envelope_recipients/get.html.erb | 2 +-
.../e_sign/eg006_envelope_docs/get.html.erb | 2 +-
.../eg007_envelope_get_doc/get.html.erb | 2 +-
.../e_sign/eg008_create_template/get.html.erb | 4 +-
.../e_sign/eg009_use_template/get.html.erb | 2 +-
.../eg010_send_binary_docs/get.html.erb | 2 +-
.../eg011_embedded_sending/get.html.erb | 6 +-
.../eg012_embedded_console/get.html.erb | 2 +-
.../eg013_add_doc_to_template/get.html.erb | 6 +-
.../e_sign/eg014_collect_payment/get.html.erb | 4 +-
.../eg015_get_envelope_tab_data/get.html.erb | 2 +-
.../eg016_set_envelope_tab_data/get.html.erb | 2 +-
.../get.html.erb | 2 +-
.../get.html.erb | 2 +-
.../get.html.erb | 4 +-
.../eg020_sms_authentication/get.html.erb | 4 +-
.../eg021_phone_authentication/get.html.erb | 4 +-
.../eg022_kba_authentication/get.html.erb | 4 +-
.../eg023_idv_authentication/get.html.erb | 4 +-
.../eg024_permission_create/get.html.erb | 2 +-
.../get.html.erb | 2 +-
.../get.html.erb | 2 +-
.../e_sign/eg028_brands_creating/get.html.erb | 2 +-
.../get.html.erb | 4 +-
.../get.html.erb | 2 +-
.../eg031_bulk_sending_envelopes/get.html.erb | 6 +-
app/views/eg001_embedded_signing/get.html.erb | 4 +-
32 files changed, 89 insertions(+), 89 deletions(-)
diff --git a/app/services/e_sign/eg013_add_doc_to_template_service.rb b/app/services/e_sign/eg013_add_doc_to_template_service.rb
index 130381c..1e81e36 100644
--- a/app/services/e_sign/eg013_add_doc_to_template_service.rb
+++ b/app/services/e_sign/eg013_add_doc_to_template_service.rb
@@ -47,7 +47,7 @@ def worker
# 3. Create the Recipient View request object
authentication_method = 'None' # How is this application authenticating
# the signer? See the `authenticationMethod' definition
- # https://developers.docusign.com/esign-rest-api/reference/Envelopes/EnvelopeViews/createRecipient
+ # https://developers.docusign.com/docs/esign-rest-api/reference/envelopes/envelopeviews/createrecipient/
recipient_view_request = DocuSign_eSign::RecipientViewRequest.new(
authenticationMethod: authentication_method,
returnUrl: envelope_args[:ds_return_url],
diff --git a/app/views/ds_common/index.html.erb b/app/views/ds_common/index.html.erb
index 25059b3..c799ac4 100644
--- a/app/views/ds_common/index.html.erb
+++ b/app/views/ds_common/index.html.erb
@@ -38,24 +38,24 @@
With embedded signing, the DocuSign signing is initiated from your website.
API methods used:
- Envelopes::create and
- EnvelopeViews::createRecipient.
+ Envelopes::create and
+ EnvelopeViews::createRecipient.
The envelope includes a pdf, Word, and HTML document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
API method used:
- Envelopes::create.
+ Envelopes::create.
List the envelopes created in the last 30 days.
API method used:
- Envelopes::listStatusChanges.
+ Envelopes::listStatusChanges.
@@ -64,14 +64,14 @@
envelope, its documents, recipients, etc.
API method used:
- Envelopes::get.
+ Envelopes::get.
List the envelope's recipients, including their current status.
API method used:
- EnvelopeRecipients::list.
+ EnvelopeRecipients::list.
@@ -79,28 +79,28 @@
is also associated with every envelope.
API method used:
- EnvelopeDocuments::list.
+ EnvelopeDocuments::list.
An envelope's documents can be downloaded one by one or as a complete set.
API method used:
- EnvelopeDocuments::get.
+ EnvelopeDocuments::get.
Create a template with two roles, signer and cc.
API methods used:
- Templates::list,
- Templates::create.
+ Templates::list,
+ Templates::create.
The envelope is defined by the template.
The signer and cc recipient name and email are used to fill in the template's roles.
API method used:
- Envelopes::create.
+ Envelopes::create.
@@ -110,7 +110,7 @@
Binary transfer is not yet supported by the SDK.
API method used:
- Envelopes::create.
+ Envelopes::create.
@@ -119,94 +119,94 @@
to the envelope before it is sent.
API methods used:
- Envelopes::create,
- EnvelopeViews::createSender.
+ Envelopes::create,
+ EnvelopeViews::createSender.
Redirect the user to the DocuSign web tool.
API method used:
- EnvelopeViews::createConsole.
+ EnvelopeViews::createConsole.
This example sends an envelope based on a template.
In addition to the template's document(s), the example adds an
additional document to the envelope by using the
- Composite Templates
+ Composite Templates
feature.
API methods used:
- Envelopes::create and
- EnvelopeViews::createRecipient.
+ Envelopes::create and
+ EnvelopeViews::createRecipient.
Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the fields in the documents.
API method used:
- Envelopes::create.
+ Envelopes::create.
- This example retrieves the tab (field) values from an envelope.
+ This example retrieves the tab (field) values from an envelope.
API method used:
- EnvelopeFormData::get.
+ EnvelopeFormData::get.
This example sets the tab (field) values for an envelope including tabs that can and cannot be changed by the signer.
API method used:
- Envelopes::create.
+ Envelopes::create.
This example sets the tab (field) values for a template being used by an envelope.
API method used:
- Envelopes::create.
+ Envelopes::create.
This example lists the envelope's custom metadata field values.
API method used:
- EnvelopeCustomFields::list.
+ EnvelopeCustomFields::list.
Recipient Authentication
Submit an envelope with an access code for multi-factor authentication.
API method used:
- Envelopes::create.
+ Envelopes::create.
Submit an envelope with a text message for multi-factor authentication.
API method used:
- Envelopes::create.
+ Envelopes::create.
Submit an envelope with a voice call to provide multi-factor authentication.
API method used:
- Envelopes::create.
+ Envelopes::create.
Submit an envelope with multiple choice, public records based questions to provide multi-factor authentication.
API method used:
- Envelopes::create.
+ Envelopes::create.
This is an example of an envelope utilizing Id verification authentication for a recipient.
API methods used:
Accounts::getAccountIdentityVerificationsList.
- Envelopes::create.
+ Envelopes::create.
@@ -220,7 +220,7 @@
This example allows you to set a permission profile on an existing user group.
API method used:
- Groups::update.
+ Groups::update.
@@ -228,60 +228,60 @@
This example updates an individual setting on a permission profile.
API method used:
- AccountPermissionProfiles::update.
+ AccountPermissionProfiles::update.
This example lists all available permissions profiles and allows you to delete any without associated users. Please note that you cannot remove "Everyone" nor "Administrator" permission profiles.
API method used:
- AccountPermissionProfiles::create.
+ AccountPermissionProfiles::create.
This example will create an account brand that can be used to apply customization to your envelopes such as your own logo, colors, and text elements.
API method used:
- AccountBrands::create.
+ AccountBrands::create.
This example will show you how to create an envelope using any of the created brands on your account.
API method used:
- Envelopes::create.
+ Envelopes::create.
This example will show you how to create an envelope using a brand
API method used:
- Envelopes::create.
+ Envelopes::create.
This example will show you how to create and send an envelope to multiple recipients using bulk lists.
API methods used:
- Envelopes::create.
+ Envelopes::create.
BulkEnvelopes::get,
EnvelopeCustomFields::create,
BulkSend::createBulkSendList,
- EnvelopeRecipients::create
+ EnvelopeRecipients::create
Advanced recipient routing
Pauses signature workflow.
API method used:
- Envelopes::create.
+ Envelopes::create.
Unpauses a signature workflow.
API method used:
- Envelopes::update.
+ Envelopes::update.
Uses conditional recipients.
API method used:
- Envelopes::create.
+ Envelopes::create.
Premium Features
diff --git a/app/views/e_sign/eg002_signing_via_email/get.html.erb b/app/views/e_sign/eg002_signing_via_email/get.html.erb
index 0fa0add..06b733c 100644
--- a/app/views/e_sign/eg002_signing_via_email/get.html.erb
+++ b/app/views/e_sign/eg002_signing_via_email/get.html.erb
@@ -1,6 +1,6 @@
2. Send an envelope with a remote (email) signer and cc recipient
The envelope includes a pdf, Word, and HTML document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
This is a general example of creating and sending an envelope (a signing request) to multiple recipients,
@@ -11,7 +11,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg003_list_envelopes/get.html.erb b/app/views/e_sign/eg003_list_envelopes/get.html.erb
index a3fb9c9..0466a86 100644
--- a/app/views/e_sign/eg003_list_envelopes/get.html.erb
+++ b/app/views/e_sign/eg003_list_envelopes/get.html.erb
@@ -7,7 +7,7 @@
<% end %>
API method used:
- Envelopes::listStatusChanges.
+ Envelopes::listStatusChanges.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg004_envelope_info/get.html.erb b/app/views/e_sign/eg004_envelope_info/get.html.erb
index 62324e6..2a36d02 100644
--- a/app/views/e_sign/eg004_envelope_info/get.html.erb
+++ b/app/views/e_sign/eg004_envelope_info/get.html.erb
@@ -14,7 +14,7 @@
<% end %>
API method used:
- Envelopes::get.
+ Envelopes::get.
diff --git a/app/views/e_sign/eg005_envelope_recipients/get.html.erb b/app/views/e_sign/eg005_envelope_recipients/get.html.erb
index b909ffa..7cf793a 100644
--- a/app/views/e_sign/eg005_envelope_recipients/get.html.erb
+++ b/app/views/e_sign/eg005_envelope_recipients/get.html.erb
@@ -6,7 +6,7 @@
<% end %>
API method used:
- EnvelopeRecipients::list.
+ EnvelopeRecipients::list.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg006_envelope_docs/get.html.erb b/app/views/e_sign/eg006_envelope_docs/get.html.erb
index 26b91b6..ea4a25d 100644
--- a/app/views/e_sign/eg006_envelope_docs/get.html.erb
+++ b/app/views/e_sign/eg006_envelope_docs/get.html.erb
@@ -11,7 +11,7 @@
<% end %>
API method used:
- EnvelopeDocuments::list.
+ EnvelopeDocuments::list.
diff --git a/app/views/e_sign/eg007_envelope_get_doc/get.html.erb b/app/views/e_sign/eg007_envelope_get_doc/get.html.erb
index 3e44943..9f9381f 100644
--- a/app/views/e_sign/eg007_envelope_get_doc/get.html.erb
+++ b/app/views/e_sign/eg007_envelope_get_doc/get.html.erb
@@ -16,7 +16,7 @@
<% end %>
API method used:
- EnvelopeDocuments::get.
+ EnvelopeDocuments::get.
diff --git a/app/views/e_sign/eg008_create_template/get.html.erb b/app/views/e_sign/eg008_create_template/get.html.erb
index da1fdf3..9dce1d7 100644
--- a/app/views/e_sign/eg008_create_template/get.html.erb
+++ b/app/views/e_sign/eg008_create_template/get.html.erb
@@ -14,8 +14,8 @@
<% end %>
API methods used:
- Templates::list,
- Templates::create.
+ Templates::list,
+ Templates::create.
diff --git a/app/views/e_sign/eg009_use_template/get.html.erb b/app/views/e_sign/eg009_use_template/get.html.erb
index a989103..180d9c2 100644
--- a/app/views/e_sign/eg009_use_template/get.html.erb
+++ b/app/views/e_sign/eg009_use_template/get.html.erb
@@ -13,7 +13,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg010_send_binary_docs/get.html.erb b/app/views/e_sign/eg010_send_binary_docs/get.html.erb
index bc0d219..00c7daa 100644
--- a/app/views/e_sign/eg010_send_binary_docs/get.html.erb
+++ b/app/views/e_sign/eg010_send_binary_docs/get.html.erb
@@ -12,7 +12,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg011_embedded_sending/get.html.erb b/app/views/e_sign/eg011_embedded_sending/get.html.erb
index d217cbd..932a096 100644
--- a/app/views/e_sign/eg011_embedded_sending/get.html.erb
+++ b/app/views/e_sign/eg011_embedded_sending/get.html.erb
@@ -2,7 +2,7 @@
An envelope will be created in draft mode. Your browser will then be redirected to
the DocuSign web tool where the envelope can be (optionally) updated and then sent.
The envelope includes a pdf, Word, and HTML document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
DocuSign recommends that you enhance your application as needed to avoid the need
for the embedded sender view.
@@ -17,8 +17,8 @@
<% end %>
API methods used:
- Envelopes::create and
- EnvelopeViews::createSender.
+ Envelopes::create and
+ EnvelopeViews::createSender.
diff --git a/app/views/e_sign/eg012_embedded_console/get.html.erb b/app/views/e_sign/eg012_embedded_console/get.html.erb
index 370fecc..2eccd5e 100644
--- a/app/views/e_sign/eg012_embedded_console/get.html.erb
+++ b/app/views/e_sign/eg012_embedded_console/get.html.erb
@@ -13,7 +13,7 @@
<% end %>
API method used:
- EnvelopeViews::createConsole.
+ EnvelopeViews::createConsole.
diff --git a/app/views/e_sign/eg013_add_doc_to_template/get.html.erb b/app/views/e_sign/eg013_add_doc_to_template/get.html.erb
index 9d7f4f4..788323e 100644
--- a/app/views/e_sign/eg013_add_doc_to_template/get.html.erb
+++ b/app/views/e_sign/eg013_add_doc_to_template/get.html.erb
@@ -4,7 +4,7 @@
This example sends an envelope based on a template.
In addition to the template's document(s), the example adds an
additional document to the envelope by using the
- Composite Templates
+ Composite Templates
feature.
In this example, the additional document is an HTML document that
includes order details with information from the form below.
@@ -19,8 +19,8 @@
<% end %>
API methods used:
- Envelopes::create and
- EnvelopeViews::createRecipient.
+ Envelopes::create and
+ EnvelopeViews::createRecipient.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg014_collect_payment/get.html.erb b/app/views/e_sign/eg014_collect_payment/get.html.erb
index 9216986..e1b9d73 100644
--- a/app/views/e_sign/eg014_collect_payment/get.html.erb
+++ b/app/views/e_sign/eg014_collect_payment/get.html.erb
@@ -1,7 +1,7 @@
14. Send an envelope with an order form, including a payment field.
Anchor strings
- (AutoPlace)
+ (AutoPlace)
are used to position the fields in the documents.
@@ -10,7 +10,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg015_get_envelope_tab_data/get.html.erb b/app/views/e_sign/eg015_get_envelope_tab_data/get.html.erb
index af61e84..80bf58e 100644
--- a/app/views/e_sign/eg015_get_envelope_tab_data/get.html.erb
+++ b/app/views/e_sign/eg015_get_envelope_tab_data/get.html.erb
@@ -12,7 +12,7 @@
<% end %>
API method used:
- EnvelopeFormData::get.
+ EnvelopeFormData::get.
diff --git a/app/views/e_sign/eg016_set_envelope_tab_data/get.html.erb b/app/views/e_sign/eg016_set_envelope_tab_data/get.html.erb
index e144d94..76b49c2 100644
--- a/app/views/e_sign/eg016_set_envelope_tab_data/get.html.erb
+++ b/app/views/e_sign/eg016_set_envelope_tab_data/get.html.erb
@@ -13,7 +13,7 @@
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg017_set_template_tab_values/get.html.erb b/app/views/e_sign/eg017_set_template_tab_values/get.html.erb
index 83c6c47..2007f15 100644
--- a/app/views/e_sign/eg017_set_template_tab_values/get.html.erb
+++ b/app/views/e_sign/eg017_set_template_tab_values/get.html.erb
@@ -11,7 +11,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg018_get_envelope_custom_field_data/get.html.erb b/app/views/e_sign/eg018_get_envelope_custom_field_data/get.html.erb
index 92d0f45..5620d21 100644
--- a/app/views/e_sign/eg018_get_envelope_custom_field_data/get.html.erb
+++ b/app/views/e_sign/eg018_get_envelope_custom_field_data/get.html.erb
@@ -15,7 +15,7 @@
<% end %>
API method used:
- EnvelopeCustomFields::list.
+ EnvelopeCustomFields::list.
diff --git a/app/views/e_sign/eg019_access_code_authentication/get.html.erb b/app/views/e_sign/eg019_access_code_authentication/get.html.erb
index 70ca581..bf34e72 100644
--- a/app/views/e_sign/eg019_access_code_authentication/get.html.erb
+++ b/app/views/e_sign/eg019_access_code_authentication/get.html.erb
@@ -1,7 +1,7 @@
19. Requiring an Access Code for a Recipient
The envelope includes a pdf document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
@@ -14,7 +14,7 @@
API method used:
-Envelopes::create.
+Envelopes::create.
diff --git a/app/views/e_sign/eg020_sms_authentication/get.html.erb b/app/views/e_sign/eg020_sms_authentication/get.html.erb
index 33fa6f3..ea735e4 100644
--- a/app/views/e_sign/eg020_sms_authentication/get.html.erb
+++ b/app/views/e_sign/eg020_sms_authentication/get.html.erb
@@ -1,7 +1,7 @@
20. Requiring an SMS Code for a Recipient
The envelope includes a pdf document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
@@ -12,7 +12,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg021_phone_authentication/get.html.erb b/app/views/e_sign/eg021_phone_authentication/get.html.erb
index e4544b0..d85f8e8 100644
--- a/app/views/e_sign/eg021_phone_authentication/get.html.erb
+++ b/app/views/e_sign/eg021_phone_authentication/get.html.erb
@@ -1,7 +1,7 @@
21. Requiring Phone Authentication for a Recipient
The envelope includes a pdf document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
@@ -12,7 +12,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg022_kba_authentication/get.html.erb b/app/views/e_sign/eg022_kba_authentication/get.html.erb
index fb39ead..21cdf28 100644
--- a/app/views/e_sign/eg022_kba_authentication/get.html.erb
+++ b/app/views/e_sign/eg022_kba_authentication/get.html.erb
@@ -1,7 +1,7 @@
22. Requiring Knowledge Based Authentication (KBA) for a Recipient
The envelope includes a pdf document. Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
@@ -12,7 +12,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg023_idv_authentication/get.html.erb b/app/views/e_sign/eg023_idv_authentication/get.html.erb
index 202af2c..b6e54e1 100644
--- a/app/views/e_sign/eg023_idv_authentication/get.html.erb
+++ b/app/views/e_sign/eg023_idv_authentication/get.html.erb
@@ -1,6 +1,6 @@
23. Send an envelope with recipient Id Verification authentication.
Anchor text
- (AutoPlace)
+ (AutoPlace)
is used to position the signing fields in the documents.
This is an example of an envelope utilizing IDV authentication for multi-factor verification of a recipient. IDV is a service offered by DocuSign that allows your reicpient to upload a photo of a government issued id for verification.
@@ -10,7 +10,7 @@
<% end %>
API method used:
- Envelopes::create.
+ Envelopes::create.
diff --git a/app/views/e_sign/eg024_permission_create/get.html.erb b/app/views/e_sign/eg024_permission_create/get.html.erb
index 56eed5b..436e96e 100644
--- a/app/views/e_sign/eg024_permission_create/get.html.erb
+++ b/app/views/e_sign/eg024_permission_create/get.html.erb
@@ -5,7 +5,7 @@
API method used:
- AccountPermissionProfiles::create.
+ AccountPermissionProfiles::create.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg025_permissions_set_user_group/get.html.erb b/app/views/e_sign/eg025_permissions_set_user_group/get.html.erb
index 7608575..02ff483 100644
--- a/app/views/e_sign/eg025_permissions_set_user_group/get.html.erb
+++ b/app/views/e_sign/eg025_permissions_set_user_group/get.html.erb
@@ -5,7 +5,7 @@
API method used:
- Groups::update.
+ Groups::update.
diff --git a/app/views/e_sign/eg026_permissions_change_single_setting/get.html.erb b/app/views/e_sign/eg026_permissions_change_single_setting/get.html.erb
index a171adf..5a14206 100644
--- a/app/views/e_sign/eg026_permissions_change_single_setting/get.html.erb
+++ b/app/views/e_sign/eg026_permissions_change_single_setting/get.html.erb
@@ -5,7 +5,7 @@
API method used:
- AccountPermissionProfiles::update.
+ AccountPermissionProfiles::update.
View source file <%= @source_file %> on GitHub.
diff --git a/app/views/e_sign/eg028_brands_creating/get.html.erb b/app/views/e_sign/eg028_brands_creating/get.html.erb
index 7eb5c49..a148952 100644
--- a/app/views/e_sign/eg028_brands_creating/get.html.erb
+++ b/app/views/e_sign/eg028_brands_creating/get.html.erb
@@ -7,7 +7,7 @@
<% end %>
API method used:
- AccountsBrands::create.
+ AccountsBrands::create.