Repository navigation
3.3.0 part B: 401/403 help, failed downloads throw, NuGet metadata, icon, XML docs - #98
Merged
Merged
Conversation
…d icon, XML docs, release checklist - ConvertApiException messages for 401 and 403 say what to do and link to the token page and the plans, tagged utm_source=dotnet-sdk ... utm_content=error-401/error-403. Type, StatusCode and Response unchanged. - Downloads (SaveFileAsync, SaveFilesAsync, FileStreamAsync) throw ConvertApiException unless the answer is 200 OK, instead of saving the error page as the result. - csproj: tags (common searches, the bare "to" with a comment, typos dropped), plain-ASCII description, PackageProjectUrl to the C# page, embedded 128x128 icon instead of PackageIconUrl (NU5048), and GenerateDocumentationFile with summaries on the main entry points. - RELEASING.md: owner TODO, pre-release checklist and a release notes template. CHANGELOG and README. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
🟡 Changes recommended
The release checklist points to a nonexistent package artifact instead of the workflow’s ConvertApi-<version> artifact.
1 open issue
What changed in this PR
This PR continues the 3.3.0 release work with clearer SDK errors, safer download handling, and improved NuGet packaging and documentation.
Changes:
- Add actionable 401/403 messages and reject failed downloads before writing the destination file, with regression tests.
- Update NuGet metadata, configure an embedded icon, and enable packaged XML documentation.
- Expand error-handling documentation and add a release checklist and notes template.
| File | Description |
|---|---|
RELEASING.md |
Add release ownership guidance, a checklist, and a notes template. |
README.md |
Describe enhanced errors and failed-download exceptions. |
ConvertApi/Exceptions/ConvertApiException.cs |
Add shared 401/403 guidance and exception documentation. |
ConvertApi/ConvertApiParam.cs |
Document file parameters and enhance upload errors. |
ConvertApi/ConvertApiExtension.cs |
Reject unsuccessful downloads and document helper exceptions. |
ConvertApi/ConvertApi.csproj |
Update package metadata, icon configuration, and XML documentation settings. |
ConvertApi/ConvertApi.cs |
Document conversion methods and enhance conversion/user errors. |
ConvertApi.Tests/ErrorTests.cs |
Test error guidance, response preservation, and download behavior. |
CHANGELOG.md |
Record error-handling, packaging, and documentation changes. |
Review effort: Balanced
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

The rest of 3.3.0 after #96 (token lookup) and #97 (save fixes).
1. 401 and 403 say what to do. Every
ConvertApiExceptionwith status 401 or 403 (convert, upload, user, download) now ends with:The exception type,
StatusCodeandResponseare unchanged, and other statuses keep their message. No trial terms are in the messages.2. A failed download throws.
SaveFileAsync,SaveFilesAsyncandFileStreamAsyncthrew nothing on a 404 or 403: the error page was returned, or saved over the output file. They now throwConvertApiExceptionwith the status and body, and no file is written.3. NuGet metadata (
ConvertApi/ConvertApi.csproj):to, with a comment saying why (nuget.org matches "to" only against IDs and tags, so without it the package never shows for "docx to pdf"). Drop the misspelledprdf-extractandpdf2extract.PackageProjectUrl: https://www.convertapi.com/integrations/libraries/csharp?utm_source=nuget&utm_medium=referral&utm_campaign=dotnet-sdk&utm_content=project-urlPackageIcon: the ConvertAPI logo (the site's own favicon, scaled to 128x128), embedded. ReplacesPackageIconUrl, so NU5048 is gone.4. XML docs.
GenerateDocumentationFileis on, andConvertApi.xmlships in the package. There are summaries onConvertAsync, theConvertApiFileParamconstructors, the save and download helpers (with the exceptions they throw) andConvertApiException(what 401 and 403 mean). The constructors were documented in #96. CS1591 is off, so undocumented members don't add warnings.5. RELEASING.md:
publish.ymlonly acceptstomasr78today);[Unreleased], preview the packed README, bump pinned versions, check the convertapi.com C# quick start;CHANGELOG
[Unreleased]and the README "Handle errors" section are updated.Checked
main, no new ones.TreatNoTestsAsError: 32 of 32 pass, 9 of them new inErrorTests:Responsebody is kept;README.md,icon.png(128x128) andlib/netstandard2.0/ConvertApi.xml(97 members). The nuspec has the new tags (ending into), description and project URL.DeleteFilesAsync(2 files deleted),SaveFileAsyncthrowsConvertApiException404 and writes no file;🤖 Generated with Claude Code