Skip to content

Commit

Permalink
v2.1.0 (#10)
Browse files Browse the repository at this point in the history
No longer require from_email on InlineSignRequest, add processing flag to Document, integration_data is now an object instead of a string, generate using Swagger Codegen 2.4.11 instead of 2.4.8
  • Loading branch information
Chris Jackson authored Jan 10, 2020
1 parent 24c6be7 commit 6579f46
Show file tree
Hide file tree
Showing 39 changed files with 106 additions and 126 deletions.
2 changes: 1 addition & 1 deletion .swagger-codegen/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.4.8
2.4.11
1 change: 1 addition & 0 deletions docs/Document.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ Name | Type | Description | Notes
**auto_delete_after** | **datetime** | Date and time calculated using `auto_delete_days` after which a finished document (signed/cancelled/declined) will be automatically deleted | [optional]
**sandbox** | **bool** | Indicates whether document was created as part of a sandbox team | [optional]
**auto_expire_after** | **datetime** | Date and time calculated using `auto_expire_days` after which a non finished document will be automatically expired | [optional]
**processing** | **bool** | Indicates whether a change to the document is processing and the PDF may be out of date. It is recommended to wait until processing has finished before downloading the PDF. Webhooks are not sent until processing has been completed. | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
8 changes: 4 additions & 4 deletions docs/DocumentSignerTemplateConf.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**signer_index** | **int** | | [optional]
**needs_to_sign** | **bool** | | [optional]
**approve_only** | **bool** | | [optional]
**notify_only** | **bool** | | [optional]
**in_person** | **bool** | | [optional]
**needs_to_sign** | **bool** | When `false` user does not need to sign, but will receive a copy of the signed document and signing log, see: [Copy only](#section/Additional-signing-methods/Copy-only) | [optional]
**approve_only** | **bool** | Require user to approve the document (without adding a signature), see: [Approve only](#section/Additional-signing-methods/Approve-only) | [optional]
**notify_only** | **bool** | Send notifications about the document and a copy of the signed document and signing log, but don't require them to take any action, see: [Notify only](#section/Additional-signing-methods/Notify-only) | [optional]
**in_person** | **bool** | When used in combination with an embed url on the sender, after sender has signed, they will be redirected to the next `in_person` signer, see: [In person signing](#section/Additional-signing-methods/In-person-signing) | [optional]
**order** | **int** | | [optional]
**placeholders** | [**list[Placeholder]**](Placeholder.md) | | [optional]

Expand Down
2 changes: 1 addition & 1 deletion docs/DocumentSignrequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Name | Type | Description | Notes
**subject** | **str** | Subject of SignRequest email | [optional]
**message** | **str** | Message to include in SignRequest email, may contain the following html tags: `a`, `abbr`, `acronym`, `b`, `blockquote`, `code`, `em`, `i`, `ul`, `li`, `ol`, and `strong` | [optional]
**who** | **str** | `m`: only me, `mo`: me and others, `o`: only others | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document, see: [automatic reminders](#section/Working-with-a-SignRequest/Automatic-reminders) | [optional]
**signers** | [**list[Signer]**](Signer.md) | | [optional]
**uuid** | **str** | | [optional]

Expand Down
2 changes: 1 addition & 1 deletion docs/InlineDocumentSignerIntegrationData.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**integration** | **str** | | [optional]
**integration_data** | **str** | | [optional]
**integration_data** | **object** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
2 changes: 1 addition & 1 deletion docs/InlineIntegrationData.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**integration** | **str** | | [optional]
**integration_data** | **str** | | [optional]
**integration_data** | **object** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
2 changes: 1 addition & 1 deletion docs/InlineSignRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Name | Type | Description | Notes
**subject** | **str** | Subject of SignRequest email | [optional]
**message** | **str** | Message to include in SignRequest email, may contain the following html tags: `a`, `abbr`, `acronym`, `b`, `blockquote`, `code`, `em`, `i`, `ul`, `li`, `ol`, and `strong` | [optional]
**who** | **str** | `m`: only me, `mo`: me and others, `o`: only others | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document, see: [automatic reminders](#section/Working-with-a-SignRequest/Automatic-reminders) | [optional]
**signers** | [**list[Signer]**](Signer.md) | | [optional]
**uuid** | **str** | | [optional]

Expand Down
4 changes: 2 additions & 2 deletions docs/SignRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ Name | Type | Description | Notes
**subject** | **str** | Subject of SignRequest email | [optional]
**message** | **str** | Message to include in SignRequest email, may contain the following html tags: `a`, `abbr`, `acronym`, `b`, `blockquote`, `code`, `em`, `i`, `ul`, `li`, `ol`, and `strong` | [optional]
**who** | **str** | `m`: only me, `mo`: me and others, `o`: only others | [optional] [default to 'o']
**send_reminders** | **bool** | Automatically remind signers to sign a document | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document, see: [automatic reminders](#section/Working-with-a-SignRequest/Automatic-reminders) | [optional]
**signers** | [**list[Signer]**](Signer.md) | |
**uuid** | **str** | | [optional]
**url** | **str** | | [optional]
**document** | **str** | |
**integration** | **str** | | [optional]
**integration_data** | **str** | | [optional]
**integration_data** | **object** | | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
4 changes: 2 additions & 2 deletions docs/SignRequestQuickCreate.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ Name | Type | Description | Notes
**subject** | **str** | Subject of SignRequest email | [optional]
**message** | **str** | Message to include in SignRequest email, may contain the following html tags: `a`, `abbr`, `acronym`, `b`, `blockquote`, `code`, `em`, `i`, `ul`, `li`, `ol`, and `strong` | [optional]
**who** | **str** | `m`: only me, `mo`: me and others, `o`: only others | [optional] [default to 'o']
**send_reminders** | **bool** | Automatically remind signers to sign a document | [optional]
**send_reminders** | **bool** | Automatically remind signers to sign a document, see: [automatic reminders](#section/Working-with-a-SignRequest/Automatic-reminders) | [optional]
**signers** | [**list[Signer]**](Signer.md) | |
**uuid** | **str** | | [optional]
**url** | **str** | | [optional]
**document** | **str** | | [optional]
**integration** | **str** | | [optional]
**integration_data** | **str** | | [optional]
**integration_data** | **object** | | [optional]
**name** | **str** | Defaults to filename, including extension | [optional]
**external_id** | **str** | ID used to reference document in external system | [optional]
**frontend_id** | **str** | Shared secret used in conjunction with <a href=\"#section/Frontend-API/SignRequest-js-client-(beta)\">SignRequest-js client</a> to grant user access to a document that's not a member of the document's team | [optional]
Expand Down
8 changes: 4 additions & 4 deletions docs/Signer.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ Name | Type | Description | Notes
**signed** | **bool** | | [optional]
**downloaded** | **bool** | | [optional]
**signed_on** | **datetime** | | [optional]
**needs_to_sign** | **bool** | | [optional] [default to True]
**approve_only** | **bool** | | [optional]
**notify_only** | **bool** | | [optional]
**in_person** | **bool** | | [optional]
**needs_to_sign** | **bool** | When `false` user does not need to sign, but will receive a copy of the signed document and signing log, see: [Copy only](#section/Additional-signing-methods/Copy-only) | [optional] [default to True]
**approve_only** | **bool** | Require user to approve the document (without adding a signature), see: [Approve only](#section/Additional-signing-methods/Approve-only) | [optional]
**notify_only** | **bool** | Send notifications about the document and a copy of the signed document and signing log, but don't require them to take any action, see: [Notify only](#section/Additional-signing-methods/Notify-only) | [optional]
**in_person** | **bool** | When used in combination with an embed url on the sender, after sender has signed, they will be redirected to the next `in_person` signer, see: [In person signing](#section/Additional-signing-methods/In-person-signing) | [optional]
**order** | **int** | | [optional]
**language** | **str** | | [optional]
**force_language** | **bool** | | [optional]
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import os

NAME = "signrequest-python-client"
VERSION = "2.0.0"
VERSION = "2.1.0"

def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
Expand Down
2 changes: 1 addition & 1 deletion signrequest_client/api_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None,
self.default_headers[header_name] = header_value
self.cookie = cookie
# Set default User-Agent.
self.user_agent = 'Swagger-Codegen/2.0.0/python'
self.user_agent = 'Swagger-Codegen/2.1.0/python'

def __del__(self):
if self._pool is not None:
Expand Down
20 changes: 14 additions & 6 deletions signrequest_client/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ def __init__(self):
self.api_key = {}
# dict to store API prefix (e.g. Bearer)
self.api_key_prefix = {}
# function to refresh API key if expired
self.refresh_api_key_hook = None
# Username for HTTP basic authentication
self.username = ""
# Password for HTTP basic authentication
Expand Down Expand Up @@ -200,11 +202,17 @@ def get_api_key_with_prefix(self, identifier):
:param identifier: The identifier of apiKey.
:return: The token for api key authentication.
"""
if (self.api_key.get(identifier) and
self.api_key_prefix.get(identifier)):
return self.api_key_prefix[identifier] + ' ' + self.api_key[identifier] # noqa: E501
elif self.api_key.get(identifier):
return self.api_key[identifier]

if self.refresh_api_key_hook:
self.refresh_api_key_hook(self)

key = self.api_key.get(identifier)
if key:
prefix = self.api_key_prefix.get(identifier)
if prefix:
return "%s %s" % (prefix, key)
else:
return key

def get_basic_auth_token(self):
"""Gets HTTP basic authentication header (string).
Expand Down Expand Up @@ -240,5 +248,5 @@ def to_debug_report(self):
"OS: {env}\n"\
"Python Version: {pyversion}\n"\
"Version of the API: v1\n"\
"SDK Package Version: 2.0.0".\
"SDK Package Version: 2.1.0".\
format(env=sys.platform, pyversion=sys.version)
43 changes: 31 additions & 12 deletions signrequest_client/models/document.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,6 @@

import six

from signrequest_client.models.document_attachment import DocumentAttachment # noqa: F401,E501
from signrequest_client.models.document_signing_log import DocumentSigningLog # noqa: F401,E501
from signrequest_client.models.document_signrequest import DocumentSignrequest # noqa: F401,E501
from signrequest_client.models.document_team import DocumentTeam # noqa: F401,E501
from signrequest_client.models.file_from_sf import FileFromSf # noqa: F401,E501
from signrequest_client.models.inline_integration_data import InlineIntegrationData # noqa: F401,E501
from signrequest_client.models.inline_prefill_tags import InlinePrefillTags # noqa: F401,E501
from signrequest_client.models.user import User # noqa: F401,E501


class Document(object):
"""NOTE: This class is auto generated by the swagger code generator program.
Expand Down Expand Up @@ -68,7 +59,8 @@ class Document(object):
'attachments': 'list[DocumentAttachment]',
'auto_delete_after': 'datetime',
'sandbox': 'bool',
'auto_expire_after': 'datetime'
'auto_expire_after': 'datetime',
'processing': 'bool'
}

attribute_map = {
Expand Down Expand Up @@ -100,10 +92,11 @@ class Document(object):
'attachments': 'attachments',
'auto_delete_after': 'auto_delete_after',
'sandbox': 'sandbox',
'auto_expire_after': 'auto_expire_after'
'auto_expire_after': 'auto_expire_after',
'processing': 'processing'
}

def __init__(self, url=None, team=None, uuid=None, user=None, file_as_pdf=None, name=None, external_id=None, frontend_id=None, file=None, file_from_url=None, events_callback_url=None, file_from_content=None, file_from_content_name=None, template=None, prefill_tags=None, integrations=None, file_from_sf=None, auto_delete_days=None, auto_expire_days=None, pdf=None, status=None, signrequest=None, api_used=None, signing_log=None, security_hash=None, attachments=None, auto_delete_after=None, sandbox=None, auto_expire_after=None): # noqa: E501
def __init__(self, url=None, team=None, uuid=None, user=None, file_as_pdf=None, name=None, external_id=None, frontend_id=None, file=None, file_from_url=None, events_callback_url=None, file_from_content=None, file_from_content_name=None, template=None, prefill_tags=None, integrations=None, file_from_sf=None, auto_delete_days=None, auto_expire_days=None, pdf=None, status=None, signrequest=None, api_used=None, signing_log=None, security_hash=None, attachments=None, auto_delete_after=None, sandbox=None, auto_expire_after=None, processing=None): # noqa: E501
"""Document - a model defined in Swagger""" # noqa: E501

self._url = None
Expand Down Expand Up @@ -135,6 +128,7 @@ def __init__(self, url=None, team=None, uuid=None, user=None, file_as_pdf=None,
self._auto_delete_after = None
self._sandbox = None
self._auto_expire_after = None
self._processing = None
self.discriminator = None

if url is not None:
Expand Down Expand Up @@ -195,6 +189,8 @@ def __init__(self, url=None, team=None, uuid=None, user=None, file_as_pdf=None,
self.sandbox = sandbox
if auto_expire_after is not None:
self.auto_expire_after = auto_expire_after
if processing is not None:
self.processing = processing

@property
def url(self):
Expand Down Expand Up @@ -873,6 +869,29 @@ def auto_expire_after(self, auto_expire_after):

self._auto_expire_after = auto_expire_after

@property
def processing(self):
"""Gets the processing of this Document. # noqa: E501
Indicates whether a change to the document is processing and the PDF may be out of date. It is recommended to wait until processing has finished before downloading the PDF. Webhooks are not sent until processing has been completed. # noqa: E501
:return: The processing of this Document. # noqa: E501
:rtype: bool
"""
return self._processing

@processing.setter
def processing(self, processing):
"""Sets the processing of this Document.
Indicates whether a change to the document is processing and the PDF may be out of date. It is recommended to wait until processing has finished before downloading the PDF. Webhooks are not sent until processing has been completed. # noqa: E501
:param processing: The processing of this Document. # noqa: E501
:type: bool
"""

self._processing = processing

def to_dict(self):
"""Returns the model properties as a dict"""
result = {}
Expand Down
Loading

0 comments on commit 6579f46

Please sign in to comment.