Outbound | POST | {Client’s URL}

Summary

This API sends near real-time GRN Notifications to ERP. The feature will help to keep the ERP systems notified about all the GRN’s happening for a client.

Description

This API sends all the GRN notifications order-wise for the orders for which items have been GRN’ed since the time the job last ran and synced notifications successfully to ERP. Frequency of this job is configurable.

Request

{
  "orderCode": "po123",
  "partnerCode": "partner1",
  "partnerLocationCode": "partnerLoc1",
  "locationCode": "l123",
  "messageId": 12345,
  "parentOrderCode": "pOrder123",
  "asnCode": "asn1",
  "generatedAsnId": "genAsn1",
  "items": [
    {
      "orderItemCode": null,
      "clientSkuCode": "CLIENT_SKU_1",
      "channelSkuCode": "100005734",
      "qcPassAbsoluteQuantity": 500,
      "qcFailAbsoluteQuantity": 2,
      "qcFailDeltaQuantity": 1,
      "qcPassDeltaQuantity": 1,
      "batchDetails": [
        {
          "batchId": 567,
          "batchCode": "EXT-BATCH-001",
          "manufacturingDate": "2026-01-01",
          "expiryDate": "2027-01-01",
          "mrp": 299.99,
          "qcPassQuantity": 80,
          "qcFailQuantity": 3
        }
      ],
      "orderItemCustomAttributes": {
        "attribute1": "Value1",
        "attribute2": "Value2",
        "attribute3": "Value3",
        "attribute4": "Value4",
        "attribute5": "Value5",
        "attribute6": "Value6",
        "attribute7": "Value7",
        "attribute8": "Value8",
        "attribute9": "Value9",
        "attribute10": "Value10",
        "channelMetadata": {
          "totalCashOnDeliveryFee": 0,
          "department": "HR",
          "paymentMethod": "ccavenue",
          "status": "processing"
        },
        "channelMetadataMap": {
          "department": "HR",
          "paymentMethod": "ccavenue"
        }
      }
    },
    {
      "orderItemCode": "oc1",
      "channelSkuCode": "100005736",
      "qcPassAbsoluteQuantity": 400,
      "qcFailAbsoluteQuantity": 2,
      "qcFailDeltaQuantity": 2,
      "qcPassDeltaQuantity": 2,
      "orderItemCustomAttributes": null
    }
  ],
  "orderCustomAttributes": {
    "attribute1": "Value1",
    "attribute2": "Value2",
    "attribute3": "Value3",
    "attribute4": "Value4",
    "attribute5": "Value5",
    "attribute6": "Value6",
    "attribute7": "Value7",
    "attribute8": "Value8",
    "attribute9": "Value9",
    "attribute10": "Value10",
    "channelMetadata": {
      "totalCashOnDeliveryFee": 0,
      "department": "HR",
      "paymentMethod": "ccavenue",
      "status": "processing"
    },
    "currency": "INR"
  }
}
Parameter Name Data Type Description Mandatory
orderCode String Unique code used by the channel to identify the order Yes
partnerCode String This represents the partner from which order will come.
If Order is of type PO/STO, this field represents vendor's code
If Order is of type RO, this field represents customer’s code Yes
partnerLocationCode String This represents the partner’s location from which order will come.
If Order is of type PO/STO, this field represents vendor location’s code
If Order is of type RO, this field represents customer location’s code Yes
locationCode String Code used by channels to identify a warehouse Yes
messageId Long Unique Identifier of a notification ( for de-duplication ) Yes
parentOrderCode String Parent order code yes
asnCode String Code to identify an ASN created no
generatedAsnId String Code to identify the generated ASN no
items Object[] List of items GRNed Yes
items.orderItemCode String Code to identify an item in a particular order no
items.clientSkuCode String Client SKU identifier for the product Yes
items.channelSkuCode String SKU code of order item Yes
items.qcPassAbsoluteQuantity Integer Total Qc pass quantity GRNed in order for the SKU Yes
items.qcFailAbsoluteQuantity
Integer Total Qc fail quantity GRNed in order for the SKU Yes
items.qcPassDeltaQuantity Integer Qc pass quantity GRNed in order for the SKU since the last notification to ERP for the order. Yes
items.qcFailDeltaQuantity Integer Qc fail quantity GRNed in order for the SKU since the last notification to ERP for the order. Yes
items.batchDetails Object[] Container object holding batch-level information and QC quantity breakdowns No, Batch details will only be returned when client configuration flag enableBatchDetailsInInventoryAPI is enabled

batchDetails array will be empty for SKUs without batch tracking | | batchDetails.batchId | Integer | Internal unique code/identifier for the batch | Yes (if batchDetails present) | | batchDetails.batchCode | String | Batch identifier as provided by an external system (supplier, ERP, WMS, etc.) | Yes (if batchDetails present) | | batchDetails.manufacturingDate | String | Date when the batch was manufactured | No | | batchDetails.expiryDate | String | Date when the batch expires and should no longer be used/sold | No | | batchDetails.mrp | Decimal | Maximum Retail Price for items in the batch | No | | batchDetails.qcPassQuantity | Integer | Quantity of SKU in the batch | Yes (if batchDetails present) | | batchDetails.qcFailQuantity | Integer | Quantity of SKU in the batch | Yes (if batchDetails present) | | items.orderItemCustomAttributes | Object | Custom attributes for order items | No | | orderItemCustomAttributes.attribute1 | String | Custom attribute 1 | No | | orderItemCustomAttributes.attribute2 | String | Custom attribute 2 | No | | orderItemCustomAttributes.attribute3 | String | Custom attribute 3 | No | | orderItemCustomAttributes.attribute4 | String | Custom attribute 4 | No | | orderItemCustomAttributes.attribute5 | String | Custom attribute 5 | No | | orderItemCustomAttributes.attribute6 | String | Custom attribute 6 | No | | orderItemCustomAttributes.attribute7 | String | Custom attribute 7 | No | | orderItemCustomAttributes.attribute8 | String | Custom attribute 8 | No | | orderItemCustomAttributes.attribute9 | String | Custom attribute 9 | No | | orderItemCustomAttributes.attribute10 | String | Custom attribute 10 | No | | items.orderItemCustomAttributes.channelMetadata | Object | These are additonal fields which can be sent to Increff system and can be used in subsequent Posting workflows | No | | items.orderItemCustomAttributes.channelMetadataMap | Object (map) | Optional string map on item attributes | No | | orderCustomAttributes | Object | Custom attributes for an order | No | | orderCustomAttributes.channelMetadata | Object | These are additonal fields which can be sent to Increff system and can be used in subsequent Posting workflows | No | | orderCustomAttributes.currency | String | Currency | No | | orderCustomAttributes.attribute1 | String | Custom attribute 1 | No | | orderCustomAttributes.attribute2 | String | Custom attribute 2 | No | | orderCustomAttributes.attribute3 | String | Custom attribute 3 | No | | orderCustomAttributes.attribute4 | String | Custom attribute 4 | No | | orderCustomAttributes.attribute5 | String | Custom attribute 5 | No | | orderCustomAttributes.attribute6 | String | Custom attribute 6 | No | | orderCustomAttributes.attribute7 | String | Custom attribute 7 | No | | orderCustomAttributes.attribute8 | String | Custom attribute 8 | No | | orderCustomAttributes.attribute9 | String | Custom attribute 9 | No | | orderCustomAttributes.attribute10 | String | Custom attribute 10 | No |

Response

HttpStatus Code

200

{
    "hasError":false,
    "errorMessage":"message"
}