Business API v3:

- POST Location

⚠️ Experimental Version

This version of the API is currently in beta and may undergo changes. For production use, please consider using the current stable version (v2).

Creates a single location in the localtunity network for the selected business.

Example

- Resource URL: https://api.takeoutnearby.com/

curl -X POST -H "Content-Type: application/json -H "Authorization: Bearer {access_token}" https://api.takeoutnearby.com/v3/business/{business_id}/location

Headers

Content-Type: (string, required) Must be "application/json"
Authorization: (string, required) Bearer {access_token}

Parameters

business_id: (integer, required) The id of the business to create the location for.

Fields

name: (string, 255 characters max, optional) The name of the business location. Defaults to the Businesses name when not provided.
phone: (string, 20 characters max, required) The phone number of the business
hide_phone: (boolean, 0|1, optional) Defaults to false. Determines if the phone number is hidden from the public.
website: (string, 255 characters max, optional) The website of the business for this specific location. If not provided, the business object website will be used.
description: (string, 255 characters max, optional) The description of the business for this specific location. If not provided, the business object description will be used.
address_one: (string, 255 characters max, required) The first line of the business address
address_two: (string, 255 characters max, optional) The second line of the business address
city: (string, 255 characters max, required) The city of the business
state: (string, 255 characters max, optional) The state of the business. This can be the state ID in the network, name, or initials
province: (string, 255 characters max, optional) The province of the business. This should be the province name if applicable
zip_code: (string, 10 characters max, required) The zip code/postal code of the business
country: (string, 255 characters max, required) The country of the business. This can be the country ID in the network or iso3 code
lat: (string, optional) The latitude of the business location. If not provided, the system will attempt to geocode the address.
lng: (string, optional) The longitude of the business location. If not provided, the system will attempt to geocode the address.

Response 200 Status Code

                    {"status":"success","results":{"id":"4685725","business_id":"5569753","name":"Posh Auto Care","phone":"(302) 669-7896","address_components":{"address_one":"2300 Carpenter Station Rd","address_two":"","city":"Wilmington","state":"Delaware","country":"United States","zip_code":"19810"},"geography":{"lat":39.8277893066,"lng":-75.0001144409},"is_public":1,"is_service_area":null,"created_at":"2024-10-08 12:23:02","last_updated":"2024-10-08 12:23:02"}}