Skip to content

The Adobe Sign Open API specification for integrating with Adobe Sign REST APIs

Notifications You must be signed in to change notification settings

karthik-uc/AdobeSign-OpenAPI

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

Adobe Sign SDK

Overview

Adobe Sign SDK aims at providing an easy way to integrate the Adobe Sign RESTful web service into client applications through easy to consume client side objects wrapping the REST API functionality. This repository contains JSONs and steps that could be used to generate Adobe Sign’s SDK for V6 REST APIs in various languages(Java, CSharp , NodeJS) .

Table of contents

Prerequisites

For the generation of Adobe Sign SDK, the client machine should have the following software installed:

  • OS: Windows/Mac/Linux
  • Java JDK: version 1.8 or above
  • Maven: 3.3.3 version or above
  • Gradle: 2.11 version or above

Getting Started

The Adobe Sign clients need to follow the below steps in order to get started with it:

  1. In order to use the SDK, you need to have an account with Adobe Sign. Please register for a developer account here.

  2. Sign in to create an application on the Adobe Sign web portal and obtain it's application id and application secret.

  3. Generate the OAuth access token by using the above application id and the application secret. The access token will need to be generated by using the OAuth APIs.

  4. Use the generated OAuth access token for trying out the sample API code (or directly in the client application code) provided in the SDK.

Downloading and Building the SDK

  1. Download the Swagger Codegen and unzip the archive to a folder of your choosing You can also sync the git repo on your local machine.
    swagger-codegen-2.3.1 will be referred as the root directory

  2. After cloning the project, you can build it from source with this command in root folder:

    mvn clean package
  3. Download the json folder from the GitHub (https://git.corp.adobe.com/srustagi/REST-SDK-V6) and copy it under root folder swagger-codegen-2.3.1

Java SDK

  1. To generate SDK classes for Agreement Resource at output folder (<PATH_TO_OUTPUT_FOLDER>) using agreements.json, run following command in root directory :

    java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \
    -i json/agreements.json \
    -l java \-o <PATH_TO_OUTPUT_FOLDER> \
    --model-package io.swagger.client.model.agreements 
    -DdateLibrary=legacy \
    --http-user-agent=AdobeSign_JavaSdk_2_0

    (if you're on Windows, replace the last command with java -jar modules\swagger-codegen-cli\target\swagger-codegen-cli.jar generate -i json\agreements.json -l java -o <PATH_TO_OUTPUT_FOLDER> \ --model-package io.swagger.client.model.agreements -DdateLibrary=legacy --http-user-agent=AdobeSign_JavaSdk_2_0)

  2. Similarly, in order to generate SDK for other resources, replace agreements.json in previous command with JSON file of corresponding resource & model-package with io.swagger.client.model.<RESOURCE_NAME> .

  3. If you want to compile all the SDK source classes, a single command can be used in output folder(<OUTPUT_FOLDER>) :

    gradle build
  4. If you want the JAR file of the SDK, you can find it at the location :

    <OUTPUT_FOLDER>/build/libs/swagger-java-client-{project-version}.jar
APIs

The <PATH_TO_OUTPUT_FOLDER>/src/main/java/io/swagger/client/api folder contains all the Adobe Sign APIs.

Packages containing APIs are laid out as follows:

io.swagger.client.api
Each class represents a resource and the class methods refers to the operations that can be performed on that resource. Each such operation is called API.
e.g. AgreementsAPI.java contains getAgreements method which retrieves all the agreements for the user.

Models

The <PATH_TO_OUTPUT_FOLDER>/src/main/java/io/swagger/client/model/<RESOURCE_NAME> folder contains all the Adobe Sign models coressponding to resource.

io.swagger.client.model.<RESOURCE_NAME>
Each class represents request or response class required in the API calls.
The classes are resource specific and can be found under this folders for the resource specified.

CSharp SDK

  1. To generate SDK classes for Agreement Resource at output folder (<PATH_TO_OUTPUT_FOLDER>) using agreements.json, run following command in root directory :

    java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \
    -i json/agreements.json \
    -l csharp \-o <PATH_TO_OUTPUT_FOLDER> \
    --model-package model/agreements 
    -DdateLibrary=legacy \
    --http-user-agent=AdobeSign_CSharpSdk_2_0

    (if you're on Windows, replace the last command with java -jar modules\swagger-codegen-cli\target\swagger-codegen-cli.jar generate -i json\agreements.json -l csharp -o <PATH_TO_OUTPUT_FOLDER> \ --model-package model/agreementss -DdateLibrary=legacy --http-user-agent=AdobeSign_CSharpSdk_2_0)

  2. Similarly, in order to generate SDK for other resources, replace agreements.json in previous command with JSON file of corresponding resource & model-package with io.swagger.client.model.<RESOURCE_NAME> .

  3. If you want to compile all the SDK source classes, a single command can be used in output folder to generate the DLL (<OUTPUT_FOLDER>) :

  • [Mac/Linux] /bin/sh build.sh
  • [Windows] build.bat
  1. If you want the JAR file of the SDK, you can find it at the location :
    <OUTPUT_FOLDER>/bin/IO.Swagger.dll
APIs

The <PATH_TO_OUTPUT_FOLDER>/src/IO.Swagger/Api folder contains all the Adobe Sign APIs.

Namespaces containing APIs are laid out as follows:

IO.Swagger.Api
Each class represents a resource and the class methods refers to the operations that can be performed on that resource. Each such operation is called API.
e.g. AgreementsAPI.cs contains getAgreements method which retrieves all the agreements for the user.

Models

The <PATH_TO_OUTPUT_FOLDER>/src/IO.Swagger/model.<RESOURCE_NAME> folder contains all the Adobe Sign models coressponding to resource.

IO.Swagger.model.<RESOURCE_NAME>
Each class represents request or response class required in the API calls.
The classes are resource specific and can be found under this folders for the resource specified.

NodeJs SDK

  1. To generate SDK classes for Agreement Resource at output folder (<PATH_TO_OUTPUT_FOLDER>) using agreements.json, run following command in root directory :

    java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \
    -i json/agreements.json \
    -l javascript \-o <PATH_TO_OUTPUT_FOLDER> \
    --model-package model/agreements 
    -DdateLibrary=legacy \
    --http-user-agent=AdobeSign_NodeJsSDK_2_0
    -DusePromises=true

    (if you're on Windows, replace the last command with java -jar modules\swagger-codegen-cli\target\swagger-codegen-cli.jar generate -i json\agreements.json -l javascript -o <PATH_TO_OUTPUT_FOLDER> \ --model-package model/agreementss -DdateLibrary=legacy --http-user-agent=AdobeSign_NodeJsSDK_2_0 -DusePromises=true)

  2. Similarly, in order to generate SDK for other resources, replace agreements.json in previous command with JSON file of corresponding resource & model-package with io.swagger.client.model.<RESOURCE_NAME> .

  3. Replace the <OUTPUT_FOLDER>/src/index.js file with the provided index.js .

  4. To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install swagger-js-client --save
Local development

To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json and this README (i.e. OUTPUT_FOLDER). Then run:

npm install

Next, link it globally in npm with the following, also from OUTPUT_FOLDER:

npm link

Finally, switch to the directory you want to use your swagger-js-client from, and run:

npm link /path/to/<OUTPUT_FOLDER>

You should now be able to require('swagger-js-client') in javascript files from the directory you ran the last command above from.

APIs

The <OUTPUT_FOLDER>/src/api folder contains all the Adobe Sign APIs.

Namespaces containing APIs are laid out as follows:

<OUTPUT_FOLDER>/src/api
Each class represents a resource and the class methods refers to the operations that can be performed on that resource. Each such operation is called API.
e.g. AgreementsAPI.js contains getAgreements method which retrieves all the agreements for the user.

Models

The <OUTPUT_FOLDER>/src/model/<RESOURCE_NAME> folder contains all the Adobe Sign models coressponding to resource.

<OUTPUT_FOLDER>/src/<RESOURCE_NAME>
Each class represents request or response class required in the API calls.
The classes are resource specific and can be found under this folders for the resource specified.

Report Issues/Bugs

You can report the issues in the issues section of the github repo.

About

The Adobe Sign Open API specification for integrating with Adobe Sign REST APIs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%