Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .codegen.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "engineHash": "bfb97cc", "specHash": "ccdb456", "version": "4.3.0" }
{ "engineHash": "bfb97cc", "specHash": "77eac4b", "version": "4.3.0" }
12 changes: 6 additions & 6 deletions box_sdk_gen/managers/folders.py
Original file line number Diff line number Diff line change
Expand Up @@ -377,9 +377,10 @@ def get_folder_by_id(
:type direction: Optional[GetFolderByIdDirection], optional
:param offset: The offset of the item at which to begin the response.

Queries with offset parameter value
exceeding 10000 will be rejected
with a 400 response., defaults to None
Offset-based pagination is not guaranteed to work reliably for high offset values and may fail for large datasets. In
those cases, reduce the number of items in the folder (for example, by
restructuring the folder into smaller subfolders) before retrying the
request., defaults to None
:type offset: Optional[int], optional
:param limit: The maximum number of items to return per page., defaults to None
:type limit: Optional[int], optional
Expand Down Expand Up @@ -733,9 +734,8 @@ def get_folder_items(
:type marker: Optional[str], optional
:param offset: The offset of the item at which to begin the response.

Queries with offset parameter value
exceeding 10000 will be rejected
with a 400 response., defaults to None
Offset-based pagination is not guaranteed to work reliably for high offset values and may fail for large datasets. In
those cases, use marker-based pagination by setting `usemarker` to `true`., defaults to None
:type offset: Optional[int], optional
:param limit: The maximum number of items to return per page., defaults to None
:type limit: Optional[int], optional
Expand Down
12 changes: 10 additions & 2 deletions box_sdk_gen/managers/sign_requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

from box_sdk_gen.internal.utils import to_string

from box_sdk_gen.serialization.json import serialize

from box_sdk_gen.serialization.json import deserialize

from typing import List
Expand All @@ -14,8 +16,6 @@

from typing import Union

from box_sdk_gen.serialization.json import serialize

from box_sdk_gen.networking.fetch_options import ResponseFormat

from box_sdk_gen.schemas.file_base import FileBase
Expand All @@ -30,6 +30,8 @@

from box_sdk_gen.schemas.client_error import ClientError

from box_sdk_gen.schemas.sign_request_cancel_request import SignRequestCancelRequest

from box_sdk_gen.schemas.sign_requests import SignRequests

from box_sdk_gen.schemas.sign_request_create_request import SignRequestCreateRequest
Expand Down Expand Up @@ -77,18 +79,22 @@ def cancel_sign_request(
self,
sign_request_id: str,
*,
reason: Optional[str] = None,
extra_headers: Optional[Dict[str, Optional[str]]] = None
) -> SignRequest:
"""
Cancels a sign request.
:param sign_request_id: The ID of the signature request.
Example: "33243242"
:type sign_request_id: str
:param reason: An optional reason for cancelling the sign request., defaults to None
:type reason: Optional[str], optional
:param extra_headers: Extra headers that will be included in the HTTP request., defaults to None
:type extra_headers: Optional[Dict[str, Optional[str]]], optional
"""
if extra_headers is None:
extra_headers = {}
request_body: Dict = {'reason': reason}
headers_map: Dict[str, str] = prepare_params({**extra_headers})
response: FetchResponse = self.network_session.network_client.fetch(
FetchOptions(
Expand All @@ -102,6 +108,8 @@ def cancel_sign_request(
),
method='POST',
headers=headers_map,
data=serialize(request_body) if not request_body == None else None,
content_type='application/json',
response_format=ResponseFormat.JSON,
auth=self.auth,
network_session=self.network_session,
Expand Down
2 changes: 2 additions & 0 deletions box_sdk_gen/schemas/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,8 @@

from box_sdk_gen.schemas.shield_information_barrier_segment_restriction_mini import *

from box_sdk_gen.schemas.sign_request_cancel_request import *

from box_sdk_gen.schemas.sign_request_create_signer import *

from box_sdk_gen.schemas.sign_request_prefill_tag import *
Expand Down
2 changes: 1 addition & 1 deletion box_sdk_gen/schemas/ai_extract_structured_response.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def __init__(
:type created_at: DateTime
:param completion_reason: The reason the response finishes., defaults to None
:type completion_reason: Optional[str], optional
:param confidence_score: The confidence score numeric values for each extracted field as a JSON dictionary. This can be empty if no field could be extracted., defaults to None
:param confidence_score: The confidence score levels and numeric values for each extracted field as a JSON dictionary. This can be empty if no field could be extracted., defaults to None
:type confidence_score: Optional[Dict], optional
"""
super().__init__(**kwargs)
Expand Down
15 changes: 15 additions & 0 deletions box_sdk_gen/schemas/sign_request_cancel_request.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
from typing import Optional

from box_sdk_gen.internal.base_object import BaseObject

from box_sdk_gen.box.errors import BoxSDKError


class SignRequestCancelRequest(BaseObject):
def __init__(self, *, reason: Optional[str] = None, **kwargs):
"""
:param reason: An optional reason for cancelling the sign request., defaults to None
:type reason: Optional[str], optional
"""
super().__init__(**kwargs)
self.reason = reason
5 changes: 5 additions & 0 deletions box_sdk_gen/schemas/sign_request_create_signer.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ def __init__(
password: Optional[str] = None,
signer_group_id: Optional[str] = None,
suppress_notifications: Optional[bool] = None,
language: Optional[str] = None,
**kwargs
):
"""
Expand Down Expand Up @@ -82,6 +83,9 @@ def __init__(
:type signer_group_id: Optional[str], optional
:param suppress_notifications: If true, no emails about the sign request will be sent., defaults to None
:type suppress_notifications: Optional[bool], optional
:param language: The language of the user, formatted in modified version of the
[ISO 639-1](https://developer.box.com/guides/api-calls/language-codes) format., defaults to None
:type language: Optional[str], optional
"""
super().__init__(**kwargs)
self.email = email
Expand All @@ -96,3 +100,4 @@ def __init__(
self.password = password
self.signer_group_id = signer_group_id
self.suppress_notifications = suppress_notifications
self.language = language
5 changes: 5 additions & 0 deletions box_sdk_gen/schemas/sign_request_signer.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def __init__(
password: Optional[str] = None,
signer_group_id: Optional[str] = None,
suppress_notifications: Optional[bool] = None,
language: Optional[str] = None,
**kwargs
):
"""
Expand Down Expand Up @@ -143,6 +144,9 @@ def __init__(
:type signer_group_id: Optional[str], optional
:param suppress_notifications: If true, no emails about the sign request will be sent., defaults to None
:type suppress_notifications: Optional[bool], optional
:param language: The language of the user, formatted in modified version of the
[ISO 639-1](https://developer.box.com/guides/api-calls/language-codes) format., defaults to None
:type language: Optional[str], optional
"""
super().__init__(
email=email,
Expand All @@ -157,6 +161,7 @@ def __init__(
password=password,
signer_group_id=signer_group_id,
suppress_notifications=suppress_notifications,
language=language,
**kwargs
)
self.has_viewed_document = has_viewed_document
Expand Down
4 changes: 2 additions & 2 deletions docs/box_sdk_gen/folders.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ client.folders.get_folder_by_id('0')
- direction `Optional[GetFolderByIdDirection]`
- The direction to sort results in. This can be either in alphabetical ascending (`ASC`) or descending (`DESC`) order.
- offset `Optional[int]`
- The offset of the item at which to begin the response. Queries with offset parameter value exceeding 10000 will be rejected with a 400 response.
- The offset of the item at which to begin the response. Offset-based pagination is not guaranteed to work reliably for high offset values and may fail for large datasets. In those cases, reduce the number of items in the folder (for example, by restructuring the folder into smaller subfolders) before retrying the request.
- limit `Optional[int]`
- The maximum number of items to return per page.
- if_none_match `Optional[str]`
Expand Down Expand Up @@ -193,7 +193,7 @@ client.folders.get_folder_items(folder_origin.id)
- marker `Optional[str]`
- Defines the position marker at which to begin returning results. This is used when paginating using marker-based pagination. This requires `usemarker` to be set to `true`.
- offset `Optional[int]`
- The offset of the item at which to begin the response. Queries with offset parameter value exceeding 10000 will be rejected with a 400 response.
- The offset of the item at which to begin the response. Offset-based pagination is not guaranteed to work reliably for high offset values and may fail for large datasets. In those cases, use marker-based pagination by setting `usemarker` to `true`.
- limit `Optional[int]`
- The maximum number of items to return per page.
- sort `Optional[GetFolderItemsSort]`
Expand Down
2 changes: 2 additions & 0 deletions docs/box_sdk_gen/sign_requests.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ client.sign_requests.cancel_sign_request(created_sign_request.id)

- sign_request_id `str`
- The ID of the signature request. Example: "33243242"
- reason `Optional[str]`
- An optional reason for cancelling the sign request.
- extra_headers `Optional[Dict[str, Optional[str]]]`
- Extra headers that will be included in the HTTP request.

Expand Down