Skip to main content

Create a Location

Endpoint
POST /v1/locations

To create a location that will be saved in Biteship's dashboard under Address Page. Each location can be used for future shipment with Biteship dashboard. You can use the Location data to create an order using its location id.

API Parameters

name string
REQUIRED
The name of the location

contact_name string
REQUIRED
The contact name of the person in charge (PIC) in the location

contact_phone string
REQUIRED
The contact phone of the person in charge (PIC) in the location

address string
REQUIRED
The complete detail of the location address. Please input the house / location number.

note string
Optional
You can add additional information regarding the location. Such as house color, street name or else.

postal_code string
REQUIRED
The postal code for the location

latitude string
REQUIRED
Coordinate latitude for the location

longitude string
REQUIRED
Coordinate longitude for the location

type string
REQUIRED
Type of location, the value is either 'origin' or 'destination'.
origin the location which sender is sending.
destination where the item will be shipped and received by the recipient.

Type of Request

Standard API Request

JSON Body Request
{
"name":"Apotik Gambir",
"contact_name":"Ahmad",
"contact_phone":"08123456789",
"address":"Jl. Gambir Selatan no 5. Blok F 92. Jakarta Pusat.",
"note":"Dekat tulisan warung Bu Indah",
"postal_code":10110,
"latitude":-6.232123121,
"longitude":102.22189911,
"type":"origin",
}

API Response

API Response
{
"success": true,
"id": "61d565c69a3211036a05f3f8",
"name": "Apotek Gambir",
"contact_name": "Ahmad",
"contact_phone": "08123456789",
"address": "Jl. Gambir Selatan no 5. Blok F 92. Jakarta Pusat."
}