Giter VIP home page Giter VIP logo

sample-app-myit-php's Introduction

MyIT Sample Application: PHP and React

Introduction

MyIT is a Docusign sample application written in PHP (server) and React (client).

MyIT demonstrates the following:

  1. Authentication with Docusign via JSON Web Token (JWT) Grant.
  2. Bulk send of multiple envelopes: This example uses the Docusign eSignature REST API to Bulk Send multiple envelopes based on PDF document template, and fills data dynamically.
  3. Bulk assignment of permission profiles to employees: This example uses the DocuSign Admin API to Update Users' permission profiles in a single request.

Prerequisites

  • Create a Docusign developer account.
  • Create an application on the Apps and Keys page and copy credentials to backend/.env: client ID (integration key), user ID, account ID and copy RSA private key to a file storage/docusign_private.key. This video demonstrates how to create an integration key (client ID) for a user application like this example.
  • Add redirect URI { PROTOCOL }://{ DOMAIN }/callback
  • Create permission profiles with names: Admin, Manager and Employee
  • PHP 8.1
  • Docker installed and configured in your machine.
  • Composer set up in your PATH environment variable so you can invoke it from any folder.

For first time use, paste login endpoint URL and grant consent to the app.

Variables configuration

Create a copy of the file backend/.env.example, save the copy as backend/.env, and fill in the data:

  • MANAGER_LOGIN - email used for getting access token for endpoints
  • MANAGER_PASSWORD - password used for getting access token for endpoints
  • CLIENT_URL - URL of the client, which is using CORS for security
  • DOCUSIGN_BASE_URL - https://demo.docusign.net/restapi for development environment
  • DOCUSIGN_CLIENT_ID - integration key GUID
  • DOCUSIGN_USER_ID - impersonated user ID
  • DOCUSIGN_ACCOUNT_ID - API account ID

Local installation instructions

  1. Build the images using the following command:

    docker compose -f docker-compose-local.yml build
    
  2. Start the containers using the following command. Add the -d flag to run the process in the background:

    docker compose -f docker-compose-local.yml up
    
  3. Open a new terminal and set the application key by running the command:

    docker exec -it myit_php php artisan key:generate
    
  4. Install the database structure using these two commands:

    docker exec -it myit_php php artisan migrate --seed
    docker exec -it myit_php php artisan passport:install
    
  5. Clear the cache:

    docker exec -it myit_php php artisan cache:clear
    
  6. Open a browser to localhost.

sample-app-myit-php's People

Contributors

raileendr avatar ei-roslyakov avatar inbargazit avatar annahileta avatar dmitriy-prikhodko avatar romanbachalosigmasoftware avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.