0.1.0-148 • Published 4 years ago

synpub-sdk v0.1.0-148

Weekly downloads
282
License
Unlicense
Repository
-
Last release
4 years ago

synpub-sdk

SynpubSdk - JavaScript client for synpub-sdk

Introduction

The SynPub (short for Synthetic EPUB) API is capapble of transforming multi page image only PDF files into accessible EPUBs.

This SDK is automatically generated by the OpenAPI Generator project:

  • API version: 0.1.0.148
  • Package version: 0.1.0-148
  • Build package: org.openapitools.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

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

Then install it via:

npm install synpub-sdk --save

Finally, you need to build the module:

npm run build
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). Let's call this JAVASCRIPT_CLIENT_DIR. Then run:

npm install

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

npm link

To use the link you just defined in your project, switch to the directory you want to use your synpub-sdk from, and run:

npm link /path/to/<JAVASCRIPT_CLIENT_DIR>

Finally, you need to build the module:

npm run build

git

If the library is hosted at a git repository, e.g.https://github.com/GIT_USER_ID/GIT_REPO_ID then install it via:

    npm install GIT_USER_ID/GIT_REPO_ID --save

For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

Please follow the installation instruction and execute the following JS code:

var SynpubSdk = require('synpub-sdk');


var api = new SynpubSdk.SynPubApi()
var url = "url_example"; // {String} The URL of the PDF file to submit for processing
var smokeTestFlag = true; // {Boolean} Flag to indicate if smoke test should be set off or not
var forceReprocess = true; // {Boolean} Flag to indicate if existing segments should be reprocessed or not
api.submitUrl(url, smokeTestFlag, forceReprocess).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Documentation for API Endpoints

All URIs are relative to https://synpub.mathdetective.ai/v1

ClassMethodHTTP requestDescription
SynpubSdk.SynPubApisubmitUrlPOST /uploadsSubmit a URL (pointing to a PDF) to the SynPub Service for processing
SynpubSdk.SynPubApiuploadFilePUT /uploadsUpload a file to the SynPub Service for processing

Documentation for Models

Documentation for Authorization

All endpoints do not require authorization.

0.1.0-146

4 years ago

0.1.0-145

4 years ago

0.1.0-148

4 years ago

0.1.0-147

4 years ago

0.1.0-144

4 years ago

0.1.0-143

4 years ago

0.1.0-142

4 years ago

0.1.0-141

4 years ago

0.1.0-135

4 years ago

0.1.0-134

4 years ago

0.1.0-133

4 years ago

0.1.0-132

4 years ago

0.1.0-139

4 years ago

0.1.0-138

4 years ago

0.1.0-137

4 years ago

0.1.0-136

4 years ago

0.1.0-131

4 years ago

0.1.0-140

4 years ago

0.1.0-130

4 years ago

0.1.0-128

4 years ago

0.1.0-127

4 years ago

0.1.0-126

4 years ago

0.1.0-124

4 years ago

0.1.0-123

4 years ago

0.1.0-122

4 years ago

0.1.0-125

4 years ago

0.1.0-121

4 years ago

0.1.0-120

4 years ago

0.1.0-119

4 years ago

0.1.0-118

4 years ago

0.1.0-109

4 years ago

0.1.0-108

4 years ago

0.1.0-107

4 years ago

0.1.0-113

4 years ago

0.1.0-112

4 years ago

0.1.0-111

4 years ago

0.1.0-110

4 years ago

0.1.0-117

4 years ago

0.1.0-116

4 years ago

0.1.0-115

4 years ago

0.1.0-114

4 years ago

0.1.0-106

4 years ago

0.1.0-105

4 years ago

0.1.0-104

4 years ago

0.1.0-103

4 years ago

0.1.0-102

4 years ago

0.1.0-101

4 years ago

0.1.0-100

4 years ago

0.1.0-99

4 years ago

0.1.0-96

4 years ago

0.1.0-97

4 years ago

0.1.0-98

4 years ago

0.1.0-90

4 years ago

0.1.0-95

4 years ago

0.1.0-91

4 years ago

0.1.0-92

4 years ago

0.1.0-93

4 years ago

0.1.0-94

4 years ago

0.1.0-88

4 years ago

0.1.0-89

4 years ago

0.1.0-84

4 years ago

0.1.0-85

4 years ago

0.1.0-86

4 years ago

0.1.0-87

4 years ago

0.1.0-81

4 years ago

0.1.0-82

4 years ago

0.1.0-83

4 years ago

0.1.0-77

4 years ago

0.1.0-78

4 years ago

0.1.0-79

4 years ago

0.1.0-73

4 years ago

0.1.0-74

4 years ago

0.1.0-75

4 years ago

0.1.0-76

4 years ago

0.1.0-70

4 years ago

0.1.0-71

4 years ago

0.1.0-72

4 years ago

0.1.0-80

4 years ago

0.1.0-68

4 years ago

0.1.0-69

4 years ago

0.1.0-67

4 years ago

0.1.0-66

4 years ago

0.1.0-65

4 years ago

0.1.0-62

4 years ago

0.1.0-63

4 years ago

0.1.0-64

4 years ago

0.1.0-60

4 years ago

0.1.0-61

4 years ago

0.1.0-59

4 years ago

0.1.0-58

4 years ago

0.1.0-57

4 years ago

0.1.0-56

4 years ago

0.1.0-55

4 years ago

0.1.0-53

4 years ago

0.1.0-54

4 years ago

0.1.0-51

4 years ago

0.1.0-52

4 years ago

0.1.0-50

4 years ago

0.1.0-49

4 years ago

0.1.0-48

4 years ago

0.1.0-45

4 years ago

0.1.0-46

4 years ago

0.1.0-47

4 years ago

0.1.0-44

4 years ago

0.1.0-43

4 years ago

0.1.0-41

4 years ago

0.1.0-37

4 years ago

0.1.0-38

4 years ago

0.1.0-33

4 years ago

0.1.0-35

4 years ago

0.1.0-36

4 years ago

0.1.0-30

4 years ago

0.1.0-31

4 years ago

0.1.0-32

4 years ago

0.1.0-26

4 years ago

0.1.0-27

4 years ago

0.1.0-28

4 years ago

0.1.0-29

4 years ago

0.1.0-25

4 years ago

0.1.0-24

4 years ago

0.1.0-23

4 years ago

0.1.0-22

4 years ago

0.1.0-15

4 years ago

0.1.0-16

4 years ago

0.1.0-17

4 years ago

0.1.0-18

4 years ago

0.1.0-13

4 years ago

0.1.0-14

4 years ago

0.1.0-19

4 years ago

0.1.0-20

4 years ago

0.1.0-21

4 years ago

0.1.0-11

4 years ago

0.1.0-12

4 years ago

0.1.0-10

4 years ago

0.1.0-9

5 years ago

0.1.0-8

5 years ago

0.1.0-5

5 years ago

0.1.0-7

5 years ago

0.1.0-6

5 years ago

0.1.0-4

5 years ago

0.1.0-3

5 years ago

0.1.0-2

5 years ago

0.1.0-40

5 years ago

0.1.0-42

5 years ago

0.1.0-39

5 years ago

0.1.0-34

5 years ago