Scroll down to learn more

Documentation Center

Welcome to Opinum Documentation Center. You find here all the content you need to enjoy your data.

Search Results for

    Show / Hide Table of Contents

    Mutation sample

    Considering the schema sample, here is a mutation sample:

    mutation { 
        CreateNodesAndRelations(
            Nodes: [
                { NodeType:"Customer", KeyProperty: "Id", KeyValue: "C1", Properties : [
                    { Name : "Name", Value: "Customer1"}]},
                { NodeType:"DeliveryPoint", KeyProperty: "Key", KeyValue: "D1", Properties : [
                    { Name : "Ean", Value: "ABC000"}, { Name : "IsActive", Value: 1}, { Name : "ActiveFrom", Value: "2021"}]},
                { NodeType:"Meter", KeyProperty: "Name", KeyValue: "M1", Properties : [
                    { Name : "Region", Value: "BXL"}]},
            ],
             Relations: [
                {	SourceNode : {KeyProperty: "Id", KeyValue: "C1", NodeType: "Customer"},
                    DestinationNodes: {NodeSelector : "Ean = 'ABC000'", NodeType: "DeliveryPoint" },
                    RelationType : "HAS_ACCESS",
                    Properties: [ {Name : "ContractStart", Value:"2021-01-01"}, {Name : "ContractEnd", Value:"2021-12-31"}]},
                {	SourceNode : {KeyProperty: "Key", KeyValue: "D1", NodeType: "DeliveryPoint"},
                    DestinationNodes: {NodeSelector : "Name = 'M1'", NodeType: "Meter" },
                    RelationType : "HAS_METER",
                    Properties: [ {Name : "FromDate", Value:"1987"}]},
                {	SourceNode : {KeyProperty: "Name", KeyValue: "M1", NodeType: "Meter"},
                    DestinationNodes: {NodeSelector : "PARENT(DataHubSite, Id) = 123 AND Name STARTS WITH 'Meter'", NodeType: "DataHubSource" },
                    RelationType : "IS_SOURCE",
                    Properties: []},				
                ]
        ){ NumberOfNodes, NumberOfRelations }
    }
    

    Developer Center

    User manual API Swagger Github
    © Opinum 2025  -   www.opinum.com

    Follow us

    Linkedin Twitter Youtube Facebook