From 834e7d8c94129c64a7ab422be1cf96f3f8b7f883 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Tue, 9 Sep 2025 01:56:30 -0700 Subject: [PATCH 1/4] feat: Add missing webhook events (box/box-openapi#554) --- .codegen.json | 2 +- box_sdk_gen/managers/webhooks.py | 6 ++++++ box_sdk_gen/schemas/webhook.py | 3 +++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.codegen.json b/.codegen.json index a75d41fbe..b5b489e1e 100644 --- a/.codegen.json +++ b/.codegen.json @@ -1 +1 @@ -{ "engineHash": "fa469c0", "specHash": "60778fb", "version": "0.1.0" } +{ "engineHash": "fa469c0", "specHash": "a05e5d7", "version": "0.1.0" } diff --git a/box_sdk_gen/managers/webhooks.py b/box_sdk_gen/managers/webhooks.py index accecd298..27f3e3a17 100644 --- a/box_sdk_gen/managers/webhooks.py +++ b/box_sdk_gen/managers/webhooks.py @@ -122,6 +122,9 @@ class CreateWebhookTriggers(str, Enum): SIGN_REQUEST_DECLINED = 'SIGN_REQUEST.DECLINED' SIGN_REQUEST_EXPIRED = 'SIGN_REQUEST.EXPIRED' SIGN_REQUEST_SIGNER_EMAIL_BOUNCED = 'SIGN_REQUEST.SIGNER_EMAIL_BOUNCED' + SIGN_REQUEST_SIGN_SIGNER_SIGNED = 'SIGN_REQUEST.SIGN_SIGNER_SIGNED' + SIGN_REQUEST_SIGN_DOCUMENT_CREATED = 'SIGN_REQUEST.SIGN_DOCUMENT_CREATED' + SIGN_REQUEST_SIGN_ERROR_FINALIZING = 'SIGN_REQUEST.SIGN_ERROR_FINALIZING' class UpdateWebhookByIdTargetTypeField(str, Enum): @@ -191,6 +194,9 @@ class UpdateWebhookByIdTriggers(str, Enum): SIGN_REQUEST_DECLINED = 'SIGN_REQUEST.DECLINED' SIGN_REQUEST_EXPIRED = 'SIGN_REQUEST.EXPIRED' SIGN_REQUEST_SIGNER_EMAIL_BOUNCED = 'SIGN_REQUEST.SIGNER_EMAIL_BOUNCED' + SIGN_REQUEST_SIGN_SIGNER_SIGNED = 'SIGN_REQUEST.SIGN_SIGNER_SIGNED' + SIGN_REQUEST_SIGN_DOCUMENT_CREATED = 'SIGN_REQUEST.SIGN_DOCUMENT_CREATED' + SIGN_REQUEST_SIGN_ERROR_FINALIZING = 'SIGN_REQUEST.SIGN_ERROR_FINALIZING' class WebhooksManager: diff --git a/box_sdk_gen/schemas/webhook.py b/box_sdk_gen/schemas/webhook.py index 3cbf167f6..8163c7ee9 100644 --- a/box_sdk_gen/schemas/webhook.py +++ b/box_sdk_gen/schemas/webhook.py @@ -58,6 +58,9 @@ class WebhookTriggersField(str, Enum): SIGN_REQUEST_DECLINED = 'SIGN_REQUEST.DECLINED' SIGN_REQUEST_EXPIRED = 'SIGN_REQUEST.EXPIRED' SIGN_REQUEST_SIGNER_EMAIL_BOUNCED = 'SIGN_REQUEST.SIGNER_EMAIL_BOUNCED' + SIGN_REQUEST_SIGN_SIGNER_SIGNED = 'SIGN_REQUEST.SIGN_SIGNER_SIGNED' + SIGN_REQUEST_SIGN_DOCUMENT_CREATED = 'SIGN_REQUEST.SIGN_DOCUMENT_CREATED' + SIGN_REQUEST_SIGN_ERROR_FINALIZING = 'SIGN_REQUEST.SIGN_ERROR_FINALIZING' class Webhook(WebhookMini): From db4f238568afa083f9af1af1dc07673f44c641be Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Tue, 9 Sep 2025 01:58:31 -0700 Subject: [PATCH 2/4] chore: Update `.codegen.json` with commit hash of `codegen` and `openapi` spec [skip ci] --- .codegen.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codegen.json b/.codegen.json index b5b489e1e..6e61b64e0 100644 --- a/.codegen.json +++ b/.codegen.json @@ -1 +1 @@ -{ "engineHash": "fa469c0", "specHash": "a05e5d7", "version": "0.1.0" } +{ "engineHash": "bca2437", "specHash": "a05e5d7", "version": "0.1.0" } From 5adc6b2612dfe0e4821746fd9c5b4c7af197f3e1 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Tue, 9 Sep 2025 02:00:21 -0700 Subject: [PATCH 3/4] chore: Update `.codegen.json` with commit hash of `codegen` and `openapi` spec [skip ci] --- .codegen.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codegen.json b/.codegen.json index 6e61b64e0..a405f800e 100644 --- a/.codegen.json +++ b/.codegen.json @@ -1 +1 @@ -{ "engineHash": "bca2437", "specHash": "a05e5d7", "version": "0.1.0" } +{ "engineHash": "2afc2c3", "specHash": "a05e5d7", "version": "0.1.0" } From a3d028fdc08734a80e04d010d560ed91f33ab41e Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Tue, 9 Sep 2025 06:26:01 -0700 Subject: [PATCH 4/4] feat: Retry requests for network errors in Swift (box/box-codegen#820) --- .codegen.json | 2 +- box_sdk_gen/networking/retries.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.codegen.json b/.codegen.json index a405f800e..c73b83f6e 100644 --- a/.codegen.json +++ b/.codegen.json @@ -1 +1 @@ -{ "engineHash": "2afc2c3", "specHash": "a05e5d7", "version": "0.1.0" } +{ "engineHash": "a356057", "specHash": "a05e5d7", "version": "0.1.0" } diff --git a/box_sdk_gen/networking/retries.py b/box_sdk_gen/networking/retries.py index 30539dcdd..4d9c6c257 100644 --- a/box_sdk_gen/networking/retries.py +++ b/box_sdk_gen/networking/retries.py @@ -1,5 +1,7 @@ from abc import abstractmethod +from typing import Optional + from box_sdk_gen.networking.fetch_options import FetchOptions from box_sdk_gen.networking.fetch_response import FetchResponse @@ -57,7 +59,7 @@ def should_retry( is_successful: bool = ( fetch_response.status >= 200 and fetch_response.status < 400 ) - retry_after_header: str = fetch_response.headers.get('Retry-After') + retry_after_header: Optional[str] = fetch_response.headers.get('Retry-After') is_accepted_with_retry_after: bool = ( fetch_response.status == 202 and not retry_after_header == None ) @@ -84,7 +86,7 @@ def retry_after( fetch_response: FetchResponse, attempt_number: int, ) -> float: - retry_after_header: str = fetch_response.headers.get('Retry-After') + retry_after_header: Optional[str] = fetch_response.headers.get('Retry-After') if not retry_after_header == None: return float(retry_after_header) randomization: float = random(