Skip to content
Developerhome

Mutation: Record deletion

  Less than to read

A deletion starts with a mutation and the node where the mutation occurs. Then, there is a delete() section with a data section that includes only the _id value.

The following table displays an example and the result of a mutation to delete a record. Some of the fields displayed are not mandatory and others have been omitted.

mutation { 
    xtremSales { 
        salesOrder { 
            delete (_id: "603") 
        } 
    } 
} 
{ 
"data": { 
    "xtremSales": { 
        "salesOrder": { 
            "delete": 1 
        } 
    } 
}, 
"extensions": { 
    "diagnoses": [] 
    }
}