What is the endpoint of a namespace on a dedicated server?


I have the feeling that the header forwarding is an issue. It seems that the X-Dgraph-AccessToken never gets forwarded (and somehow also not added, even when accessing lambda resolvers on the very same namespace). If this is the case then Dgraph Cloud with multi tennency is simply not working! Correct me, but I have no clue how we would have @auth rules in combination with the X-Dgrap-AccessToken at the same time.

If I remember right Dgraph Lambda ist hosted on Cloud. Then this could be an issue here

async function dqlMutate(mutate: string | Object): Promise<GraphQLResponse> {
  const response = await fetch(`${process.env.DGRAPH_URL}/mutate?commitNow=true`, {
    method: "POST",
    headers: {
      "Content-Type": typeof mutate === 'string' ? "application/rdf" : "application/json",
      "X-Auth-Token": process.env.DGRAPH_TOKEN || ""
    body: typeof mutate === 'string' ? mutate : JSON.stringify(mutate)
  if (response.status !== 200) {
    throw new Error("Failed to execute DQL Mutate")
  return response.json();

since no X-Dgraph-AccessToken is getting submitted! I have also tried to manually do a fetch request inside a lambda resolver, where I have included a valid access token.

const response = await fetch(`https://MY_BACKEND/mutate?commitNow=true`, {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
        "X-Dgraph-AccessToken": "MY_TOKEN",
      body: JSON.stringify({
        query: `{ q(func: uid(${input.id})) { uid } }`,
        mutations: [{}],

    const test = await response.json();

Doing this results in an access denied error

{\"data\":null,\"errors\":[{\"message\":\"Access Denied\"}]}