Pushing Orders

What are orders to Jungle?

Jungle is not an Order source. Jungle collects Orders from external systems, with an emphasis on how the order is to be fulfilled, rather then simply cloning in orders as list of line items.

In Jungle, an important concept is that 1 order does not equal 1 shipment. It can have many.

Jungle is not strict on what constitutes an order, this may have implications in your fulfilment process, but allows Jungle to remain flexible.

Sending an order

At it's simplist an order my be as follows:

mutation {
  orderConsumeWithAllocations(
    input: {
      reference: "TestOrderWithAutoAllocation"
      orderedAt: "2020-08-06T05:53:11Z"
      billingAddress: {
        lines: ["123 Example St"]
        countryCode: "AU"
        suburb: "Brisbane"
        postalCode: "4000"
        contactPerson: { fullName: "Test Order" }
      }
      allocations: [{ method: AUTO, lineItems: [{ quantity: 1, sku: "EXAMPLE" }] }]
    }
  ) {
    orderId
  }
}

Confirmation will look like this:

{
  "data": {
    "orderConsumeWithAllocations": {
      "orderId": "PQGYFTdIcoG4Wx3OnN2R"
    }
  }
}

A more complete example

In this following example. The Order has 6 line items, where 2 are indicated to be picked up from a particular location/store. And the rest shipped.

mutation {
  orderConsumeWithAllocations(
    input: {
      reference: "TestOrderWithManyAllocations"
      orderedAt: "2020-08-06T05:55:01Z"
      priceTotal: { amount: 190.98, currency: "AUD" }
      billingAddress: {
        lines: ["40 Test Rd"]
        countryCode: "AU"
        suburb: "Brisbane"
        postalCode: "4000"
        contactPerson: { name: "Test Multiple allocation Order" }
      }
      attributes: [{ name: "loyalty", value: "GOLD" }]
      tags: ["🎊"]
      allocations: [
        {
          method: SHIP
          serviceCode: "7E55"
          shippingAddress: {
            lines: ["123 Test Rd"]
            countryCode: "AU"
            suburb: "Melbourne"
            postalCode: "3001"
            contactPerson: { name: "Sample Client" }
          }
          lineItems: [
            { quantity: 4, sku: "fakesku", productName: "myproductname", price: { amount: 19.99, currency: "AUD" } }
          ]
        }
        {
          method: PICKUP
          locationId: "storeselectedforpickid"
          lineItems: [
            {
              quantity: 2
              sku: "heavyitem"
              price: { amount: 55.51, currency: "AUD" }
              attributes: [{ name: "2manlift", value: "yes" }]
            }
          ]
        }
      ]
    }
  ) {
    orderId
  }
}

🤖 The seperated lineItems in the allocations will combine to reflect as the orders overall line items.

It is perfectly fine to send 1 allocation, as all things in the order to be shipped, or picked up.

Allocations

Allocations are groups of items to be fulfilled, they go further into describing where, how, when and to who the items are for, but initially may simply group them.

Internally Jungle may create many allocations on an Order. Examples are when parts of an Order are sent on to a drop shipper, or split over multiple warehouses etc.

We allow external systems to kick start the process by specifying up 3 allocations on an incoming Order.

Allocation methods allowed: SHIP, PICKUP, AUTO.

Fill 1

Can't find what you're looking for?

Contact Us