|
| 1 | +# docspring |
| 2 | +DocSpring is a service that helps you fill out and sign PDF templates. |
| 3 | + |
| 4 | +This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: |
| 5 | + |
| 6 | +- API version: v1 |
| 7 | +- Package version: 1.3.2 |
| 8 | +- Build package: com.docspring.codegen.DocSpringPythonClientCodegen |
| 9 | + |
| 10 | +## Requirements. |
| 11 | + |
| 12 | +Python 2.7 and 3.4+ |
| 13 | + |
| 14 | +## Installation & Usage |
| 15 | +### pip install |
| 16 | + |
| 17 | +If the python package is hosted on Github, you can install directly from Github |
| 18 | + |
| 19 | +```sh |
| 20 | +pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git |
| 21 | +``` |
| 22 | +(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`) |
| 23 | + |
| 24 | +Then import the package: |
| 25 | +```python |
| 26 | +import docspring |
| 27 | +``` |
| 28 | + |
| 29 | +### Setuptools |
| 30 | + |
| 31 | +Install via [Setuptools](http://pypi.python.org/pypi/setuptools). |
| 32 | + |
| 33 | +```sh |
| 34 | +python setup.py install --user |
| 35 | +``` |
| 36 | +(or `sudo python setup.py install` to install the package for all users) |
| 37 | + |
| 38 | +Then import the package: |
| 39 | +```python |
| 40 | +import docspring |
| 41 | +``` |
| 42 | + |
| 43 | +## Getting Started |
| 44 | + |
| 45 | +Please follow the [installation procedure](#installation--usage) and then run the following: |
| 46 | + |
| 47 | +```python |
| 48 | +from __future__ import print_function |
| 49 | +import time |
| 50 | +import docspring |
| 51 | +from docspring.rest import ApiException |
| 52 | +from pprint import pprint |
| 53 | + |
| 54 | +# Configure HTTP basic authorization: api_token_basic |
| 55 | +configuration = docspring.Configuration() |
| 56 | +configuration.username = 'YOUR_USERNAME' |
| 57 | +configuration.password = 'YOUR_PASSWORD' |
| 58 | + |
| 59 | +# create an instance of the API class |
| 60 | +api_instance = docspring.PDFApi(docspring.ApiClient(configuration)) |
| 61 | +template_id = 'tpl_000000000000000002' # str | |
| 62 | +add_fields_data = docspring.AddFieldsData() # AddFieldsData | |
| 63 | + |
| 64 | +try: |
| 65 | + # Add new fields to a Template |
| 66 | + api_response = api_instance.add_fields_to_template(template_id, add_fields_data) |
| 67 | + pprint(api_response) |
| 68 | +except ApiException as e: |
| 69 | + print("Exception when calling PDFApi->add_fields_to_template: %s\n" % e) |
| 70 | + |
| 71 | +``` |
| 72 | + |
| 73 | +## Documentation for API Endpoints |
| 74 | + |
| 75 | +All URIs are relative to *https://api.docspring.com/api/v1* |
| 76 | + |
| 77 | +Class | Method | HTTP request | Description |
| 78 | +------------ | ------------- | ------------- | ------------- |
| 79 | +*PDFApi* | [**add_fields_to_template**](docs/PDFApi.md#add_fields_to_template) | **PUT** /templates/{template_id}/add_fields | Add new fields to a Template |
| 80 | +*PDFApi* | [**batch_generate_pdf_v1**](docs/PDFApi.md#batch_generate_pdf_v1) | **POST** /templates/{template_id}/submissions/batch | Generates multiple PDFs |
| 81 | +*PDFApi* | [**batch_generate_pdfs**](docs/PDFApi.md#batch_generate_pdfs) | **POST** /submissions/batches | Generates multiple PDFs |
| 82 | +*PDFApi* | [**combine_pdfs**](docs/PDFApi.md#combine_pdfs) | **POST** /combined_submissions?v=2 | Merge submission PDFs, template PDFs, or custom files |
| 83 | +*PDFApi* | [**combine_submissions**](docs/PDFApi.md#combine_submissions) | **POST** /combined_submissions | Merge generated PDFs together |
| 84 | +*PDFApi* | [**copy_template**](docs/PDFApi.md#copy_template) | **POST** /templates/{template_id}/copy | Copy a Template |
| 85 | +*PDFApi* | [**create_custom_file_from_upload**](docs/PDFApi.md#create_custom_file_from_upload) | **POST** /custom_files | Create a new custom file from a cached presign upload |
| 86 | +*PDFApi* | [**create_data_request_token**](docs/PDFApi.md#create_data_request_token) | **POST** /data_requests/{data_request_id}/tokens | Creates a new data request token for form authentication |
| 87 | +*PDFApi* | [**create_folder**](docs/PDFApi.md#create_folder) | **POST** /folders/ | Create a folder |
| 88 | +*PDFApi* | [**create_html_template**](docs/PDFApi.md#create_html_template) | **POST** /templates?desc=html | Create a new HTML template |
| 89 | +*PDFApi* | [**create_pdf_template**](docs/PDFApi.md#create_pdf_template) | **POST** /templates | Create a new PDF template with a form POST file upload |
| 90 | +*PDFApi* | [**create_pdf_template_from_upload**](docs/PDFApi.md#create_pdf_template_from_upload) | **POST** /templates?desc=cached_upload | Create a new PDF template from a cached presign upload |
| 91 | +*PDFApi* | [**delete_folder**](docs/PDFApi.md#delete_folder) | **DELETE** /folders/{folder_id} | Delete a folder |
| 92 | +*PDFApi* | [**expire_combined_submission**](docs/PDFApi.md#expire_combined_submission) | **DELETE** /combined_submissions/{combined_submission_id} | Expire a combined submission |
| 93 | +*PDFApi* | [**expire_submission**](docs/PDFApi.md#expire_submission) | **DELETE** /submissions/{submission_id} | Expire a PDF submission |
| 94 | +*PDFApi* | [**generate_pdf**](docs/PDFApi.md#generate_pdf) | **POST** /templates/{template_id}/submissions | Generates a new PDF |
| 95 | +*PDFApi* | [**get_combined_submission**](docs/PDFApi.md#get_combined_submission) | **GET** /combined_submissions/{combined_submission_id} | Check the status of a combined submission (merged PDFs) |
| 96 | +*PDFApi* | [**get_data_request**](docs/PDFApi.md#get_data_request) | **GET** /data_requests/{data_request_id} | Look up a submission data request |
| 97 | +*PDFApi* | [**get_full_template**](docs/PDFApi.md#get_full_template) | **GET** /templates/{template_id}?full=true | Fetch the full template attributes |
| 98 | +*PDFApi* | [**get_presign_url**](docs/PDFApi.md#get_presign_url) | **GET** /uploads/presign | Get a presigned URL so that you can upload a file to our AWS S3 bucket |
| 99 | +*PDFApi* | [**get_submission**](docs/PDFApi.md#get_submission) | **GET** /submissions/{submission_id} | Check the status of a PDF |
| 100 | +*PDFApi* | [**get_submission_batch**](docs/PDFApi.md#get_submission_batch) | **GET** /submissions/batches/{submission_batch_id} | Check the status of a submission batch job |
| 101 | +*PDFApi* | [**get_template**](docs/PDFApi.md#get_template) | **GET** /templates/{template_id} | Check the status of an uploaded template |
| 102 | +*PDFApi* | [**get_template_schema**](docs/PDFApi.md#get_template_schema) | **GET** /templates/{template_id}/schema | Fetch the JSON schema for a template |
| 103 | +*PDFApi* | [**list_folders**](docs/PDFApi.md#list_folders) | **GET** /folders/ | Get a list of all folders |
| 104 | +*PDFApi* | [**list_submissions**](docs/PDFApi.md#list_submissions) | **GET** /submissions | List all submissions |
| 105 | +*PDFApi* | [**list_submissions_0**](docs/PDFApi.md#list_submissions_0) | **GET** /templates/{template_id}/submissions | List all submissions for a given template |
| 106 | +*PDFApi* | [**list_templates**](docs/PDFApi.md#list_templates) | **GET** /templates | Get a list of all templates |
| 107 | +*PDFApi* | [**move_folder_to_folder**](docs/PDFApi.md#move_folder_to_folder) | **POST** /folders/{folder_id}/move | Move a folder |
| 108 | +*PDFApi* | [**move_template_to_folder**](docs/PDFApi.md#move_template_to_folder) | **POST** /templates/{template_id}/move | Move Template to folder |
| 109 | +*PDFApi* | [**rename_folder**](docs/PDFApi.md#rename_folder) | **POST** /folders/{folder_id}/rename | Rename a folder |
| 110 | +*PDFApi* | [**test_authentication**](docs/PDFApi.md#test_authentication) | **GET** /authentication | Test Authentication |
| 111 | +*PDFApi* | [**update_data_request**](docs/PDFApi.md#update_data_request) | **PUT** /data_requests/{data_request_id} | Update a submission data request |
| 112 | +*PDFApi* | [**update_template**](docs/PDFApi.md#update_template) | **PUT** /templates/{template_id} | Update a Template |
| 113 | + |
| 114 | + |
| 115 | +## Documentation For Models |
| 116 | + |
| 117 | + - [AddFieldsData](docs/AddFieldsData.md) |
| 118 | + - [AddFieldsTemplateResponse](docs/AddFieldsTemplateResponse.md) |
| 119 | + - [AuthenticationError](docs/AuthenticationError.md) |
| 120 | + - [AuthenticationSuccessResponse](docs/AuthenticationSuccessResponse.md) |
| 121 | + - [CombinePdfsData](docs/CombinePdfsData.md) |
| 122 | + - [CombinedSubmission](docs/CombinedSubmission.md) |
| 123 | + - [CombinedSubmissionAction](docs/CombinedSubmissionAction.md) |
| 124 | + - [CombinedSubmissionData](docs/CombinedSubmissionData.md) |
| 125 | + - [CopyTemplateData](docs/CopyTemplateData.md) |
| 126 | + - [CreateCombinedSubmissionResponse](docs/CreateCombinedSubmissionResponse.md) |
| 127 | + - [CreateCustomFileData](docs/CreateCustomFileData.md) |
| 128 | + - [CreateCustomFileResponse](docs/CreateCustomFileResponse.md) |
| 129 | + - [CreateFolderData](docs/CreateFolderData.md) |
| 130 | + - [CreateHtmlTemplateData](docs/CreateHtmlTemplateData.md) |
| 131 | + - [CreateSubmissionBatchResponse](docs/CreateSubmissionBatchResponse.md) |
| 132 | + - [CreateSubmissionBatchSubmissionsResponse](docs/CreateSubmissionBatchSubmissionsResponse.md) |
| 133 | + - [CreateSubmissionDataRequestData](docs/CreateSubmissionDataRequestData.md) |
| 134 | + - [CreateSubmissionDataRequestTokenResponse](docs/CreateSubmissionDataRequestTokenResponse.md) |
| 135 | + - [CreateSubmissionDataRequestTokenResponseToken](docs/CreateSubmissionDataRequestTokenResponseToken.md) |
| 136 | + - [CreateSubmissionResponse](docs/CreateSubmissionResponse.md) |
| 137 | + - [CreateTemplateFromUploadData](docs/CreateTemplateFromUploadData.md) |
| 138 | + - [CustomFile](docs/CustomFile.md) |
| 139 | + - [Error](docs/Error.md) |
| 140 | + - [Folder](docs/Folder.md) |
| 141 | + - [FoldersFolder](docs/FoldersFolder.md) |
| 142 | + - [HtmlTemplateData](docs/HtmlTemplateData.md) |
| 143 | + - [InvalidRequest](docs/InvalidRequest.md) |
| 144 | + - [ListSubmissionsResponse](docs/ListSubmissionsResponse.md) |
| 145 | + - [MoveFolderData](docs/MoveFolderData.md) |
| 146 | + - [MoveTemplateData](docs/MoveTemplateData.md) |
| 147 | + - [PendingTemplate](docs/PendingTemplate.md) |
| 148 | + - [RenameFolderData](docs/RenameFolderData.md) |
| 149 | + - [Submission](docs/Submission.md) |
| 150 | + - [SubmissionAction](docs/SubmissionAction.md) |
| 151 | + - [SubmissionBatch](docs/SubmissionBatch.md) |
| 152 | + - [SubmissionBatchData](docs/SubmissionBatchData.md) |
| 153 | + - [SubmissionData](docs/SubmissionData.md) |
| 154 | + - [SubmissionDataBatchRequest](docs/SubmissionDataBatchRequest.md) |
| 155 | + - [SubmissionDataRequest](docs/SubmissionDataRequest.md) |
| 156 | + - [Template](docs/Template.md) |
| 157 | + - [Template1](docs/Template1.md) |
| 158 | + - [Template1Defaults](docs/Template1Defaults.md) |
| 159 | + - [TemplateData](docs/TemplateData.md) |
| 160 | + - [TemplatestemplateIdaddFieldsFields](docs/TemplatestemplateIdaddFieldsFields.md) |
| 161 | + - [UpdateDataRequestResponse](docs/UpdateDataRequestResponse.md) |
| 162 | + - [UpdateSubmissionDataRequestData](docs/UpdateSubmissionDataRequestData.md) |
| 163 | + - [UpdateTemplateData](docs/UpdateTemplateData.md) |
| 164 | + - [UpdateTemplateResponse](docs/UpdateTemplateResponse.md) |
| 165 | + - [UploadTemplateData](docs/UploadTemplateData.md) |
| 166 | + - [UploadTemplateDataDocument](docs/UploadTemplateDataDocument.md) |
| 167 | + - [UploadTemplateDataDocumentMetadata](docs/UploadTemplateDataDocumentMetadata.md) |
| 168 | + |
| 169 | + |
| 170 | +## Documentation For Authorization |
| 171 | + |
| 172 | + |
| 173 | +## api_token_basic |
| 174 | + |
| 175 | +- **Type**: HTTP basic authentication |
| 176 | + |
| 177 | + |
| 178 | +## Author |
| 179 | + |
| 180 | + |
| 181 | + |
| 182 | + |
0 commit comments