Skip to content

Conversation

@KoditkarVedant
Copy link
Contributor

Description

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Fixes #479

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have checked my code and corrected any misspellings

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for the Complete file upload API endpoint, enabling completion of multi-part file uploads in the Notion API client. This addresses issue #479 by implementing the necessary request/response models, client methods, and comprehensive integration tests.

Key Changes:

  • Added Complete API endpoint support with request/response models
  • Implemented multi-part file upload test coverage with stream splitting utilities
  • Enhanced REST client to handle POST requests without request bodies

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Src/Notion.Client/Api/FileUploads/Complete/FileUploads.cs Implements the CompleteAsync method to finalize multi-part uploads
Src/Notion.Client/Api/FileUploads/Complete/Request/CompleteFileUploadRequest.cs Defines the request model containing the file upload ID
Src/Notion.Client/Api/FileUploads/Complete/Request/ICompleteFileUploadPathParameters.cs Interface for complete request path parameters
Src/Notion.Client/Api/FileUploads/Complete/Response/CompleteFileUploadResponse.cs Response model inheriting from FileObjectResponse
Src/Notion.Client/Api/FileUploads/IFileUploadsClient.cs Adds CompleteAsync method to the client interface
Src/Notion.Client/Api/ApiEndpoints.cs Adds the Complete endpoint URL builder
Src/Notion.Client/RestClient/RestClient.cs Adds null body handling for POST requests
Test/Notion.IntegrationTests/FileUploadsClientTests.cs Comprehensive test for multi-part upload workflow including completion
Test/Notion.IntegrationTests/StreamSplitExtensions.cs Utility methods for splitting streams and enumerating with indices

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@notion-dotnet notion-dotnet deleted a comment from Copilot AI Oct 18, 2025
@KoditkarVedant KoditkarVedant merged commit 46df956 into main Oct 18, 2025
7 checks passed
@KoditkarVedant KoditkarVedant deleted the 479-add-support-for-complete-file-upload-endpoint branch October 18, 2025 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for Complete a file upload

1 participant