DocuSignとMicrosoft Power Automateによる連携(2)実際の使用例

DocuSign-and-Microsoft-Power-Automate

前回のブログ記事では、DocuSignとMicrosoft Power Automateの連携に関する概要とトリガーについて解説しましたが、今回はDocuSignとSharePoint連携でMicrosoft Power Automate(旧Microsoft Flow)を使い、契約書の契約日と終了日、契約金額をSharePointの検索プロパティとして DocuSign上で入力されたフィールド項目から自動で設定する方法について解説します。(以下DocuSignのDemoコネクタを使用しています。)

準備設定

まず、DocuSign上でテンプレートを作成します。この時に配置するフィールドの名前をデータフィールドで設定します。ここでは金額、契約日、契約終了日を設定しています。

DocuSign integrated with Microsoft Power Automate 2 DocuSign integrated with Microsoft Power Automate 2 (1)

SharePoint上のドキュメントの列の追加で、上記のDocuSignフィールドにマッチするように契約日(日付)、契約終了日(日付)、金額(数値)を設定します。

DocuSign integrated with Microsoft Power Automate 2 (2)

Microsoft Power Automateで処理ロジックを記述します。大まかには、エンベロープステータス変更時にエンベロープドキュメントを取得してSharePointにそのファイルを書き戻すとともに、検索プロパティをドキュメントフィールドから取得して設定します。

DocuSign integrated with Microsoft Power Automate 2 (3)

トリガーイベントでDocuSignのAccountを選択し、Connect nameを設定(任意)、Envelope eventを [Completed] にします。

DocuSign integrated with Microsoft Power Automate 2 (4)

Get envelope documentsでは、DocuSign Accountを選択し、Envelopeは動的コンテンツであるEnvelope IDを選択します。ここではCertificate of completionを [いいえ] にしています。

DocuSign integrated with Microsoft Power Automate 2 (5)

Apply to eachで動的コンテンツであるRecipientStatusを選択し、条件はRouting Orderがstring(1)に等しい場合を設定しています。

DocuSign integrated with Microsoft Power Automate 2 (12)

条件が [はい] の場合、SharePointでファイルの作成とファイルプロパティの更新を設定します。

ファイルの作成では書き込み先のサイトのアドレスとフォルダーパスを設定します。ファイル名はDocuSignの動的コンテンツから生成し、ファイルコンテンツはDocuSignの動的コンテンツのFile Contentを指定します。

ファイルプロパティでは、サイトのアドレスとライブラリ名、SharePointのItemIDを指定し、DocuSignの動的コンテンツからタイトル=Subject、契約終了日、金額、契約日を各フィールドから @item()?['tabs']['金額']のように入力します。(最終的な表示はtabs.金額のようになります。)

DocuSign integrated with Microsoft Power Automate 12

その後、保存します。

DocuSign integrated with Microsoft Power Automate 2 (7)

動作

SharePointのドキュメントにアップロードした契約書から、[DocuSignを使用して署名を取得] を選択します。DocuSignにログインしていなければログイン、複数アカウントがある場合は該当アカウントを選択します。

DocuSign integrated with Microsoft Power Automate 11

DocuSign側でテンプレートを設定しておけば、一致するテンプレートを指定できます。

DocuSign integrated with Microsoft Power Automate 2 (8)

送信された契約書に契約金額と契約終了日を入力し、署名して完了します。

DocuSign integrated with Microsoft Power Automate 2 (9)

契約日、契約終了日、金額の項目に、署名者がDocuSignで入力した情報が反映されていることを確認します。SharePoint上の契約書の検索プロパティにより、日付や金額による範囲指定検索が可能になります。

DocuSign integrated with Microsoft Power Automate 2 (10)

今回ご覧いただきましたように、DocuSignとSharePointの連携をMicrosoft Power Automateで自動化することで、SharePoint上の契約書に検索プロパティが自動で設定されます。これにより、SharePoint上で契約内容の全文検索だけでなく、契約書の日付や金額による範囲指定検索も可能になります。

参照:https://docs.microsoft.com/ja-jp/connectors/docusign/

 

DocuSignとMicrosoft Power Automateによる連携について

  1. 概要とトリガー
  2. 実際の使用例
  3. DocuSignのアクションについて
公開