extend schema
  @link(url: "https://specs.apollo.dev/connect/v0.2", import: ["@connect"])

type Query {
  resources: [String!]!
    @connect(
      http: {
        GET: "http://127.0.0.1:8000/resources"
        headers: [
          { name: "valid-with-value", value: "text/html" }
          { name: "valid-with-from", from: "valid-with-from" }
          { name: "no-from-or-value" }
          { from: "x-missing-name" }
          { name: "from-and-value", from: "from-and-value", value: "text/html" }
          { name: "x-name-collision", value: "text/html" }
          { name: "X-NAME-COLLISION", from: "x-name-collision" }
          { name: "<Invalid-Header>", value: "invalid.header.name" }
          { name: "x-invalid-from", from: "<Invalid-Header>" }
          {
            name: "x-emoji-value"
            value: "  Value with 😊 emoji  "
          }
          { name: "Content-Length", value: "Is a reserved header" }
          { name: "Content-Type", from: "Cant-Be-Dynamic" }
          { name: "accept", from: "Is a reserved header" }
          { name: "accept", value: "application/json; version=v4.0" } # ok
        ]
      }
      selection: "$"
    )
}
