Skip to content

Instantly share code, notes, and snippets.

View surajkrpaul13's full-sized avatar

Suraj surajkrpaul13

View GitHub Profile
mutation ($input: NodeArticleCreateInput!) {
createNodeArticle(input: $input) {
violations {
path
message
}
errors
entity {
entityId
entityBundle
query getArticle($nid: String!) {
nodeById(id: $nid) {
title
}
}
{
"nid": "2"
}
{
"data": {
"nodeQuery": {
"nid": 2,
"type": {
"targetId": "article"
},
"created": 1519484033
}
}
{
nodeQuery: nodeById(id: "2") {
...nodeFields
}
}
fragment nodeFields on NodeArticle {
nid
type {
targetId
{
nodeData1: nodeById(id: "1") {
title
}
nodeData: nodeById(id: "2") {
title
}
}
{
nodeById(id: "1") {
title
}
nodeById(id: "2") {
title
}
}
{
"data": {
"nodeQuery": {
"entities": [
{
"entityLabel": "Test n",
"entityId": "1"
},
{
"entityLabel": "test n1",
{
nodeQuery(filter:{
conditions:[{
field: "status"
value: ["1"]
}]
}){
entities{
entityLabel
entityId
{
"data": {
"nodeById": {
"title": "Test n"
}
}
}
{
nodeById(id: "1") {
title
}
}