blueink-client-python 1.4.0__tar.gz → 1.6.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {blueink_client_python-1.4.0/src/blueink_client_python.egg-info → blueink_client_python-1.6.0}/PKG-INFO +2 -1
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/README.md +1 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/setup.cfg +1 -1
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/constants.py +3 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/endpoints.py +1 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/model/bundles.py +5 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/bundle.py +15 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/template.py +18 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_bundle_helper.py +28 -1
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_client.py +16 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0/src/blueink_client_python.egg-info}/PKG-INFO +2 -1
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/LICENSE +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/pyproject.toml +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/__init__.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/bundle_helper.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/client.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/model/__init__.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/model/persons.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/model/webhook.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/paginator.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/person_helper.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/request_helper.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/__init__.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/envelope_template.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/packet.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/person.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/subclient.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/verify.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/webhook.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/__init__.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_apiv2_218_constants.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_person_helper.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/utils/__init__.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/utils/testcase.py +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink_client_python.egg-info/SOURCES.txt +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink_client_python.egg-info/dependency_links.txt +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink_client_python.egg-info/requires.txt +0 -0
- {blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink_client_python.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: blueink-client-python
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.6.0
|
|
4
4
|
Summary: Python Client for Blueink eSignature API
|
|
5
5
|
Home-page: https://github.com/blueinkhq/blueink-client-python
|
|
6
6
|
Author: Blueink
|
|
@@ -293,6 +293,7 @@ as kwargs.
|
|
|
293
293
|
* List via ```client.templates.list(...)``` or ```client.templates.paged_list(...)```
|
|
294
294
|
* Retrieve via ```client.templates.retrieve(...)```
|
|
295
295
|
* Update via ```client.templates.update(...)```
|
|
296
|
+
* Delete via ```client.templates.delete(...)```
|
|
296
297
|
* Create Preparation Session via ```client.templates.create_preparation_session(...)```
|
|
297
298
|
|
|
298
299
|
### Envelope Template Related
|
|
@@ -265,6 +265,7 @@ as kwargs.
|
|
|
265
265
|
* List via ```client.templates.list(...)``` or ```client.templates.paged_list(...)```
|
|
266
266
|
* Retrieve via ```client.templates.retrieve(...)```
|
|
267
267
|
* Update via ```client.templates.update(...)```
|
|
268
|
+
* Delete via ```client.templates.delete(...)```
|
|
268
269
|
* Create Preparation Session via ```client.templates.create_preparation_session(...)```
|
|
269
270
|
|
|
270
271
|
### Envelope Template Related
|
|
@@ -97,6 +97,9 @@ EVENT_TYPE = Munch(
|
|
|
97
97
|
EVENT_BUNDLE_ERROR="bundle_error",
|
|
98
98
|
EVENT_BUNDLE_CANCELLED="bundle_cancelled",
|
|
99
99
|
EVENT_BUNDLE_SIGNER_REASSIGNED="bundle_signer_reassigned",
|
|
100
|
+
EVENT_DOC_TEMPLATE_CREATED="doc_template_created",
|
|
101
|
+
EVENT_DOC_TEMPLATE_UPDATED="doc_template_updated",
|
|
102
|
+
EVENT_DOC_TEMPLATE_DELETED="doc_template_deleted",
|
|
100
103
|
EVENT_PACKET_VIEWED="packet_viewed",
|
|
101
104
|
EVENT_PACKET_COMPLETE="packet_complete",
|
|
102
105
|
EVENT_PACKET_DECLINED="packet_declined",
|
|
@@ -257,6 +257,8 @@ class Document(BaseModel):
|
|
|
257
257
|
fields: Optional[List[Field]] = None
|
|
258
258
|
auto_placements: Optional[List[AutoPlacement]] = None
|
|
259
259
|
html_fields_mode: Optional[str] = None
|
|
260
|
+
converted_adobe_fields_to: Optional[str] = None
|
|
261
|
+
adobe_field_assignments: Optional[dict] = None
|
|
260
262
|
|
|
261
263
|
@classmethod
|
|
262
264
|
def create(cls, key=None, **kwargs):
|
|
@@ -341,6 +343,9 @@ class Bundle(BaseModel):
|
|
|
341
343
|
expires: Optional[str] = None
|
|
342
344
|
allow_signer_reassign: Optional[bool] = None
|
|
343
345
|
allow_chained_signer_reassign: Optional[bool] = None
|
|
346
|
+
max_reminders: Optional[int] = None
|
|
347
|
+
owner_name: Optional[str] = None
|
|
348
|
+
owner_email: Optional[str] = None
|
|
344
349
|
tag_values: Optional[dict] = None
|
|
345
350
|
|
|
346
351
|
@classmethod
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/bundle.py
RENAMED
|
@@ -353,6 +353,21 @@ class BundleSubClient(SubClient):
|
|
|
353
353
|
url = self.build_url(endpoints.BUNDLES.LIST_FILES, bundle_id=bundle_id)
|
|
354
354
|
return self._requests.get(url)
|
|
355
355
|
|
|
356
|
+
def generate_files(self, bundle_id: str) -> NormalizedResponse:
|
|
357
|
+
"""Enqueue unsigned filled-PDF generation for an incomplete Bundle.
|
|
358
|
+
|
|
359
|
+
Requires early file access (FEATURE.API_DATA_EARLY). Poll list_files
|
|
360
|
+
until ready (APIv2 2.19.0+).
|
|
361
|
+
|
|
362
|
+
Args:
|
|
363
|
+
bundle_id: which bundle to generate files for
|
|
364
|
+
|
|
365
|
+
Returns:
|
|
366
|
+
NormalizedResponse object (body includes the Bundle id)
|
|
367
|
+
"""
|
|
368
|
+
url = self.build_url(endpoints.BUNDLES.LIST_FILES, bundle_id=bundle_id)
|
|
369
|
+
return self._requests.put(url)
|
|
370
|
+
|
|
356
371
|
def list_data(self, bundle_id: str) -> NormalizedResponse:
|
|
357
372
|
"""Return a data for the supplied bundle corresponding to the id
|
|
358
373
|
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/template.py
RENAMED
|
@@ -76,6 +76,21 @@ class TemplateSubClient(SubClient):
|
|
|
76
76
|
url = self.build_url(endpoints.TEMPLATES.UPDATE, template_id=template_id)
|
|
77
77
|
return self._requests.patch(url, json=data)
|
|
78
78
|
|
|
79
|
+
def delete(self, template_id: str) -> NormalizedResponse:
|
|
80
|
+
"""Soft-delete a Document Template.
|
|
81
|
+
|
|
82
|
+
The API disables the template and removes it from account libraries
|
|
83
|
+
(HTTP 204). Globally shared templates cannot be deleted (HTTP 403).
|
|
84
|
+
|
|
85
|
+
Args:
|
|
86
|
+
template_id:
|
|
87
|
+
|
|
88
|
+
Returns:
|
|
89
|
+
NormalizedResponse object
|
|
90
|
+
"""
|
|
91
|
+
url = self.build_url(endpoints.TEMPLATES.DELETE, template_id=template_id)
|
|
92
|
+
return self._requests.delete(url)
|
|
93
|
+
|
|
79
94
|
def create_preparation_session(self, data: dict) -> NormalizedResponse:
|
|
80
95
|
"""Create an embedded template preparation session.
|
|
81
96
|
|
|
@@ -86,6 +101,9 @@ class TemplateSubClient(SubClient):
|
|
|
86
101
|
data: configuration for the preparation session. Supported keys:
|
|
87
102
|
- template_id (str, optional): slug of an existing template to edit
|
|
88
103
|
- redirect_url (str, optional): URL to redirect to after preparation
|
|
104
|
+
- allowed_data_flow_tags (list[str], optional): exact tag names or
|
|
105
|
+
namespace-prefix patterns such as ``acme:*``. An empty list allows
|
|
106
|
+
no tags; omit the field to leave the session unfiltered.
|
|
89
107
|
|
|
90
108
|
Returns:
|
|
91
109
|
NormalizedResponse object with keys:
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_bundle_helper.py
RENAMED
|
@@ -5,7 +5,7 @@ import pytest
|
|
|
5
5
|
from munch import Munch
|
|
6
6
|
|
|
7
7
|
from blueink.bundle_helper import BundleHelper
|
|
8
|
-
from blueink.model.bundles import ImportedDocument
|
|
8
|
+
from blueink.model.bundles import Bundle, Document, ImportedDocument
|
|
9
9
|
from blueink.utils.testcase import TestCase
|
|
10
10
|
|
|
11
11
|
|
|
@@ -632,3 +632,30 @@ class TestImportedDocument(TestCase):
|
|
|
632
632
|
"""Test that providing only file_url raises a ValidationError"""
|
|
633
633
|
with pytest.raises(Exception):
|
|
634
634
|
ImportedDocument.create(file_url="https://example.com/test.pdf")
|
|
635
|
+
|
|
636
|
+
|
|
637
|
+
class TestApiV219BundleModels(TestCase):
|
|
638
|
+
def test_bundle_model_accepts_owner_and_max_reminders(self):
|
|
639
|
+
bundle = Bundle(
|
|
640
|
+
packets=[],
|
|
641
|
+
documents=[],
|
|
642
|
+
max_reminders=3,
|
|
643
|
+
owner_name="Ada Lovelace",
|
|
644
|
+
owner_email="ada@example.com",
|
|
645
|
+
)
|
|
646
|
+
self.assert_equal(bundle.max_reminders, 3)
|
|
647
|
+
self.assert_equal(bundle.owner_name, "Ada Lovelace")
|
|
648
|
+
self.assert_equal(bundle.owner_email, "ada@example.com")
|
|
649
|
+
|
|
650
|
+
def test_bundle_model_accepts_null_max_reminders(self):
|
|
651
|
+
bundle = Bundle(packets=[], documents=[], max_reminders=None)
|
|
652
|
+
self.assert_equal(bundle.max_reminders, None)
|
|
653
|
+
|
|
654
|
+
def test_document_model_accepts_adobe_field_assignments(self):
|
|
655
|
+
doc = Document(
|
|
656
|
+
key="doc-1",
|
|
657
|
+
converted_adobe_fields_to="signer-1",
|
|
658
|
+
adobe_field_assignments={"Signature1": "signer-1"},
|
|
659
|
+
)
|
|
660
|
+
self.assert_equal(doc.converted_adobe_fields_to, "signer-1")
|
|
661
|
+
self.assert_equal(doc.adobe_field_assignments["Signature1"], "signer-1")
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_client.py
RENAMED
|
@@ -558,6 +558,22 @@ class TestClientEndpoints(TestCase):
|
|
|
558
558
|
)
|
|
559
559
|
self.assert_equal(url, f"{self.BASE_URL}/templates/T-abc123/")
|
|
560
560
|
|
|
561
|
+
def test_template_delete_url(self):
|
|
562
|
+
client = self._client()
|
|
563
|
+
url = client.templates.build_url(
|
|
564
|
+
endpoints.TEMPLATES.DELETE, template_id="T-abc123"
|
|
565
|
+
)
|
|
566
|
+
self.assert_equal(url, f"{self.BASE_URL}/templates/T-abc123/")
|
|
567
|
+
|
|
568
|
+
def test_event_type_includes_doc_template_events(self):
|
|
569
|
+
values = EVENT_TYPE.values()
|
|
570
|
+
self.assert_equal(EVENT_TYPE.EVENT_DOC_TEMPLATE_CREATED, "doc_template_created")
|
|
571
|
+
self.assert_equal(EVENT_TYPE.EVENT_DOC_TEMPLATE_UPDATED, "doc_template_updated")
|
|
572
|
+
self.assert_equal(EVENT_TYPE.EVENT_DOC_TEMPLATE_DELETED, "doc_template_deleted")
|
|
573
|
+
self.assert_in("doc_template_created", values)
|
|
574
|
+
self.assert_in("doc_template_updated", values)
|
|
575
|
+
self.assert_in("doc_template_deleted", values)
|
|
576
|
+
|
|
561
577
|
def test_bundle_update_url(self):
|
|
562
578
|
client = self._client()
|
|
563
579
|
url = client.bundles.build_url(endpoints.BUNDLES.UPDATE, bundle_id="B-abc123")
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: blueink-client-python
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.6.0
|
|
4
4
|
Summary: Python Client for Blueink eSignature API
|
|
5
5
|
Home-page: https://github.com/blueinkhq/blueink-client-python
|
|
6
6
|
Author: Blueink
|
|
@@ -293,6 +293,7 @@ as kwargs.
|
|
|
293
293
|
* List via ```client.templates.list(...)``` or ```client.templates.paged_list(...)```
|
|
294
294
|
* Retrieve via ```client.templates.retrieve(...)```
|
|
295
295
|
* Update via ```client.templates.update(...)```
|
|
296
|
+
* Delete via ```client.templates.delete(...)```
|
|
296
297
|
* Create Preparation Session via ```client.templates.create_preparation_session(...)```
|
|
297
298
|
|
|
298
299
|
### Envelope Template Related
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/packet.py
RENAMED
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/person.py
RENAMED
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/subclient.py
RENAMED
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/verify.py
RENAMED
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/subclients/webhook.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{blueink_client_python-1.4.0 → blueink_client_python-1.6.0}/src/blueink/tests/test_person_helper.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|