Thanks.
I did have to base64 encode the "foo" username to get it to work as the Authorization header
Authorization Basic Zm9vOg==
One remaining question though is that I'm getting a 401 Error when trying to execute a custom dagger function:
Here's what I'm seeing in claude desktop
{
`query`: `
{
directory {
withNewFile(path: "main.go", contents: "package main\n\nimport \"fmt\"\n\nfunc main() {\n fmt.Println(\"Hello, World!\")\n}\n") {
withNewFile(path: "main_test.go", contents: "package main\n\nimport \"testing\"\n\nfunc TestMain(t *testing.T) {\n // Simple test\n if 1+1 != 2 {\n t.Error(\"Math is broken\")\n }\n}\n") {
withNewFile(path: "go.mod", contents: "module hello\n\ngo 1.21\n") {
id
}
}
}
}
}
`
}
{"data":null,"errors":[{"message":"HTTP fetch failed from 'dagger': 401: Unauthorized","path":[],"extensions":{"code":"SUBREQUEST_HTTP_ERROR","service":"dagger","reason":"401: Unauthorized","http":{"status":401}}},{"message":"HTTP fetch failed from 'dagger': subgraph response does not contain 'content-type' header; expected content-type: application/json or content-type: application/graphql-response+json","path":[],"extensions":{"code":"SUBREQUEST_HTTP_ERROR","service":"dagger","reason":"subgraph response does not contain 'content-type' header; expected content-type: application/json or content-type: application/graphql-response+json","http":{"status":401}}}]}
Does this mean I'd need to also config my MCP server to send along the Authorization header somehow?
^^