Skip to content

Graphql

Graphql

Sample query:

{
  orders {
    id
    productsList {
      product {
        name
        price
      }
      quantity
    }
    totalAmount
  }
}

Sample response:

{
  "data": {
    "orders": [
      {
        "id": 1,
        "productsList": [
          {
            "product": {
              "name": "orange",
              "price": 1.5
            },
            "quantity": 100
          }
        ],
        "totalAmount": 150
      }
    ]
  }
}