# Docker.DotNet.DockerApiException

**URL:** <https://forums.docker.com/t/docker-dotnet-dockerapiexception/147578>\
**Category:** Docker Desktop\
**Tags:** docker, windows-11\
**Created:** [April 10, 2025, 7:50pm UTC](https://forums.docker.com/t/docker-dotnet-dockerapiexception/147578 "2025-04-10T19:50:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aumapathi](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/aumapathi/32/54808_2.png) [@aumapathi](https://forums.docker.com/u/aumapathi)\
**Post date:** [April 10, 2025, 7:50pm UTC](https://forums.docker.com/t/docker-dotnet-dockerapiexception/147578/1 "2025-04-10T19:50:16Z")

</div>

Hello Experts,

I installed docker desktop and trying to run a test project but getting the following error from visual studio 2022:

I am able to pull the sql image from command prompt without any error.

 ![image](https://global.discourse-cdn.com/docker/original/3X/3/f/3f2edb784bce66aa6e15931c4b1e45152051bade.png)

Please let me know if my laptop is missing any settings and how to overcome this error.

Thank you

---

<div class="post-metadata">

**Author:** ![rimelek](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/rimelek/32/41602_2.png) [@rimelek](https://forums.docker.com/u/rimelek)\
**Post date:** [April 12, 2025, 9:26pm UTC](https://forums.docker.com/t/docker-dotnet-dockerapiexception/147578/2 "2025-04-12T21:26:52Z")

</div>

If it works with the docker client then it looks like a Visual Studio or SDK issue. You could try to report it here:

> **[Issues · dotnet/Docker.DotNet](https://github.com/dotnet/Docker.DotNet/issues)**
>
> :whale: .NET (C#) Client Library for Docker API. Contribute to dotnet/Docker.DotNet development by creating an account on GitHub.

If you search for the error message, especially the part about the negative serial number, it seems it was always fixed in the SDK or tool that wanted to connect.

- [Default TLS cert uses negative serial number · Issue #895 · microsoft/mssql-docker · GitHub](https://github.com/microsoft/mssql-docker/issues/895)
- [go - failed to parse certificate from server: x509: negative serial number - Stack Overflow](https://stackoverflow.com/questions/79061981/failed-to-parse-certificate-from-server-x509-negative-serial-number)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/docker/original/3X/d/4/d4fbccd46c81bfcffe9822e20e17736d946fa821.png) [@system](https://forums.docker.com/u/system)\
**Post date:** [May 12, 2025, 9:27pm UTC](https://forums.docker.com/t/docker-dotnet-dockerapiexception/147578/3 "2025-05-12T21:27:28Z")

</div>

Closed on May 12, 2025, 9:27pm UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
