{"id":"6531a2803a84ac4d","repo":"spring-projects/spring-boot","slug":"docker-api-call-to-host-uri-failed-with-sta","errorCode":null,"errorMessage":"Docker API call to '${host}${uri}' failed with status code ${statusCode}","messagePattern":"Docker API call to '(.+?)(.+?)' failed with status code (.+?)","errorType":"http","errorClass":"DockerEngineException","httpStatus":null,"severity":"error","filePath":"buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/transport/HttpClientTransport.java","lineNumber":170,"sourceCode":"\n\tprivate Response execute(HttpUriRequestBase request, @Nullable String registryAuth) {\n\t\tif (StringUtils.hasText(registryAuth)) {\n\t\t\trequest.setHeader(REGISTRY_AUTH_HEADER, registryAuth);\n\t\t}\n\t\treturn execute(request);\n\t}\n\n\tprivate Response execute(HttpUriRequest request) {\n\t\ttry {\n\t\t\tbeforeExecute(request);\n\t\t\tClassicHttpResponse response = this.client.executeOpen(this.host, request, null);\n\t\t\tint statusCode = response.getCode();\n\t\t\tif (statusCode >= 400 && statusCode <= 500) {\n\t\t\t\tbyte[] content = readContent(response);\n\t\t\t\tresponse.close();\n\t\t\t\tErrors errors = (statusCode != 500) ? deserializeErrors(content) : null;\n\t\t\t\tMessage message = deserializeMessage(content);\n\t\t\t\tthrow new DockerEngineException(this.host.toHostString(), request.getUri(), statusCode,\n\t\t\t\t\t\tresponse.getReasonPhrase(), errors, message, content);\n\t\t\t}\n\t\t\treturn new HttpClientResponse(response);\n\t\t}\n\t\tcatch (IOException | URISyntaxException ex) {\n\t\t\tthrow new DockerConnectionException(this.host.toHostString(), ex);\n\t\t}\n\t}\n\n\tprotected void beforeExecute(HttpRequest request) {\n\t}\n\n\tprivate byte @Nullable [] readContent(ClassicHttpResponse response) throws IOException {\n\t\tHttpEntity entity = response.getEntity();\n\t\tif (entity == null) {\n\t\t\treturn null;\n\t\t}\n\t\ttry (InputStream stream = entity.getContent()) {","sourceCodeStart":152,"sourceCodeEnd":188,"githubUrl":"https://github.com/spring-projects/spring-boot/blob/5b2dbdbb8be64415eb6552f81ff7c449c8d251e6/buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/transport/HttpClientTransport.java#L152-L188","documentation":"Error \"Docker API call to '${host}${uri}' failed with status code ${statusCode}\" thrown in spring-projects/spring-boot.","triggerScenarios":"Thrown at buildpack/spring-boot-buildpack-platform/src/main/java/org/springframework/boot/buildpack/platform/docker/transport/HttpClientTransport.java:170 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"5b2dbdbb8be64415eb6552f81ff7c449c8d251e6","analyzedAt":"2026-08-04T18:53:14.967Z","schemaVersion":2}