Create Order Instant

How you connect to 3PL to get pickup request and also get awb for courier driver reference

Here's how you connect to 3PL to get pickup request and also get awb for courier driver reference

[POST] /api/mitra/v4/instant/pickup/request

Payload

PayloadValuesTypeRequired
serviceCourier code grab_express, borzo, gosendString YES
service_type Price result.costs..service_typeString YES
vehicle motor (Bike) or mobil (Car)String YES
order_prefix Your seller order Prefix, we will use for generate order idString YES
packages Package ObjectArray Of Object YES

Packages Object

Here is the translation of the table to English:

PayloadValuesTypeRequired
origin_name Sender Namestring YES
origin_phone Sender Phone Number, use a country phone scopestring YES
origin_lat Sender Origin Latitudefloat YES
origin_long Sender Origin Longitudefloat YES
origin_address Sender Origin Address Detailstring YES
origin_address_note Sender Origin Address Detail Note e.g "Dekat Kantor"string YES
destination_name Receiver Namestring YES
destination_phone Receiver Phone Number, use a country phone scopestring YES
destination_lat Receiver Origin Latitudefloat YES
destination_long Receiver Origin LongitudefloatYES
destination_address Receiver Origin Address Detailstring YES
destination_address_note Receiver Origin Address Detail Note e.g "Dekat Kantor"stringYES
shipping_price Your shipping cost value, we use for validationint YES
item Item detailobject YES

Item Object

PyloadvaluesTypeRequired
nameThe item nameStringYES
descriptionThe item descriptionStringYES
priceYour goods value for insurance purposeIntegerYES
weightPackage Weight in GramIntegerYES

Example

{
  "service": "gosend",

  "service_type": "instant",

  "vehicle": "motor",

  "order_prefix": "BDI",

  "packages": [
    {
      "destination_name": "Okka Syahputra",

      "destination_phone": "081280045616",

      "destination_lat": -7.776192418965594,

      "destination_long": 110.32505379554323,

      "destination_address": "Godean, Sidoarum, Sleman",

      "destination_address_note": "Tidak Ada Destination",

      "origin_name": "Rizky Syahputra",

      "origin_phone": "081280045616",

      "origin_lat": -7.854584796417944,

      "origin_long": 110.33115444430031,

      "origin_address": "Wirobrajan, Kota Yogyakarta, Daerah Istimewa Yogyakarta, Indonesia",

      "origin_address_note": "Tidak Ada Origin",

      "shipping_price": 34000,

      "item": {
        "name": "Barang 1",

        "description": "Barang 1 Description",

        "price": 20000,

        "weight": 1000
      }
    }
  ]
}

Response

{
  "status": true,

  "text": "success",

  "code": 0,

  "method": null,

  "result": {
    "payment": {
      "payment_id": "PID-1736406074",

      "amount": 34000,

      "status_code": "Pembayaran berhasil",

      "qr_content": null,

      "pay_time": null
    },

    "packages": [
      {
        "awb": "GK-11-3177494",

        "order_id": "BDI-1736406073777",

        "service": "gosend",

        "service_type": "instant",

        "status": 105,

        "live_track_url": null,

        "poly_line": "db}n@{`l`TyAYp@yDhAaIt@yEd@wBTwAx@{FbAaGRgBf@_CjA}H?IoMoBeEi@iBY{PaCcCg@cGcCqFqBi@jIg@a@eNeBeKwA}Dc@u@Ck`@QuMIiCKcATu@?_AUuMUmC[SCQGUgAe@a@UCiCGsAEKAANsEhe@CfIXzKGh@Qr@Ul@mPzXa@nAYjAKbAIlEKnTQx@QZW\\_@Zk@T]Fk@@c{@mB}a@mAkAO_Bm@aAMqXJ[AOEMsAAo@H_@vCqKF_@Ae@Oe@c@o@m@g@_C_B_@[wAw@w@@iUu@uLe@}]eAkBCyJ]}KS?JqFQsBO_CI}FOeGUkDWo@GqAE]Lc@XCLGrA?fE@p@AN[|Am@|AO\\c@r@_@v@_@~BYrBo@jD`B\\XDLL@PKt@@J",

        "origin": {
          "name": "Rizky Syahputra",

          "address": "Wirobrajan, Kota Yogyakarta, Daerah Istimewa Yogyakarta, Indonesia",

          "phone": "081280045616",

          "lat_long": "-7.8545847964179,110.3311544443"
        },

        "destination": {
          "name": "Okka Syahputra",

          "address": "Godean, Sidoarum, Sleman",

          "phone": "081280045616",

          "lat_long": "-7.7761924189656,110.32505379554"
        },

        "driver": {
          "name": null,

          "phone": null,

          "image": null
        }
      }
    ]
  }
}

Response Error

{
  "status": false,

  "text": "cannot process the request, distance more than 40km",

  "code": 2,

  "method": null,

  "result": null
}