Cancel all orders API not working with blank segment

Hi

I am getting below error when I am passing blank

requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://api.upstox.com/v2/order/multi/cancel?segment=&tag=


{
  "status": "error",
  "message": "Invalid segment",
  "error_code": "UDAPI1108",
  "data": null,
  "raw_data": {
    "status": "error",
    "errors": [
      {
        "errorCode": "UDAPI1108",
        "message": "Invalid segment",
        "propertyPath": "cancelMultiOrder.segment",
        "invalidValue": "",
        "error_code": "UDAPI1108",
        "property_path": "cancelMultiOrder.segment",
        "invalid_value": ""
      }
    ]
  }
}

As per my view passing segment with blank value should not be considered as invalid value instead it should treated as empty parameter and should ignore that parameter.

Hi @Jagdish_j_ptl, If you’re sending the key in the request query, it will be validated. This behavior is consistent across all APIs, so please avoid sending empty or null values.