@@ -107,14 +107,8 @@ syntax element.
107
107
If an error can be associated to a particular field in the GraphQL result, it
108
108
must contain an entry with the key ` path ` that details the path of the response
109
109
field which experienced the error. This allows clients to identify whether a
110
- ` null ` result is intentional or caused by a runtime error.
111
-
112
- If present, this field must be a list of path segments starting at the root of
113
- the response and ending with the field associated with the error. Path segments
114
- that represent fields must be strings, and path segments that represent list
115
- indices must be 0-indexed integers. If the error happens in an aliased field,
116
- the path to the error must use the aliased name, since it represents a path in
117
- the response, not in the request.
110
+ ` null ` result is intentional or caused by a runtime error. The value of this
111
+ field is described in the [ Path] ( #sec-Path ) section.
118
112
119
113
For example, if fetching one of the friends' names fails in the following
120
114
operation:
@@ -244,6 +238,19 @@ discouraged.
244
238
}
245
239
```
246
240
241
+ ### Path
242
+
243
+ A ` path ` field allows for the association to a particular field in a GraphQL
244
+ result. This field must be a list of path segments starting at the root of the
245
+ response and ending with the field to be associated with. Path segments that
246
+ represent fields must be strings, and path segments that represent list indices
247
+ must be 0-indexed integers. If the path is associated to an aliased field, the
248
+ path must use the aliased name, since it represents a path in the response, not
249
+ in the request.
250
+
251
+ When the ` path ` field is present on an "Error result", it indicates the response
252
+ field which experienced the error.
253
+
247
254
## Serialization Format
248
255
249
256
GraphQL does not require a specific serialization format. However, clients
0 commit comments