Feature Request (very easy to implement!): opt out for big wasteful response

In production, nobody needs these big responses. it’s a waste of bandwidth. please make us able to opt out of it

Implementation: A simple opt out parameter in the http API and the clients APIs and so on would be enough to tell the server ‘i dont need that stuff’ and the dgraph server ‘ok i wont send you that stuff my brother’. we just need in production a ‘OK’ response or ‘error’ response, that’s it. nothing more than that. No ridiculous big JSON response.

this feature is very very very very very easy to implement please give us this feature :heart: thanks a lot for your hard work dgraph devs,i promise when my start up will be successful (release in 6-12months) i will donate you 999999999999 dollar money. dgraph is an amazing product and im very thankful that it’s open source

  "data": {
    "code": "Success",
    "message": "Done",
    "queries": null,
    "uids": {
      "amit": "0x1",
      "artyom": "0x9",
      "catalina": "0x8",
      "goldie": "0x5",
      "hyung": "0x4",
      "luke": "0xa",
      "michael": "0x7",
      "perro": "0x6",
      "rammy": "0x3",
      "sang": "0xb",
      "sarah": "0x2"
  "extensions": {
    "server_latency": {
      "parsing_ns": 58367,
      "processing_ns": 6003445,
      "assign_timestamp_ns": 1065266,
      "total_ns": 7429244
    "txn": {
      "start_ts": 3,
      "commit_ts": 4,
      "preds": [

(this is the response of a mutation Can I tell dgraph that I don't need/want a big detailed response?


disclaimer: there are of course people that need this response, but there are some that also do NOT need the response. so an opt out would be perfect to make everyone happy

I am not (principally) a fan of changing the shape of response of a single endpoint.

However, others may be. Here is a rfc of a header controlling extra information return with prefer: return=minimal

A good question may be, is this larger return information causing a actual problem measurable in the real world, or is it more a premature optimization.

1 Like

thank you very much!! the link you sent Prefer Header for HTTP is exactly the thing I wish

to be honest, it is optimization. but if you mutate very often, then I think it will sump up maybe to some $$$

since this feature is very easy to implement, i see no reason to say no to this feature request

1 Like

it’s possible to turn them off locally, but not in dgraph cloud :frowning: I want to turn them off in dgraph cloud, for graphql and for dql

1 Like

@dmai are you guys planning to address this issue?