Skip to main content
POST
/
locations
Typescript (SDK)
import { Idalia } from "idalia";

const idalia = new Idalia({
  apiKeyAuth: process.env["IDALIA_API_KEY_AUTH"] ?? "",
});

async function run() {
  const result = await idalia.locations.create();

  console.log(result);
}

run();
[
  {
    "id": "<string>",
    "createdAt": "<string>",
    "updatedAt": "<string>",
    "workspaceId": "<string>",
    "name": "<string>",
    "latitude": 123,
    "longitude": 123,
    "address1": "<string>",
    "address2": "<string>",
    "city": "<string>",
    "state": "<string>",
    "postalCode": "<string>",
    "country": "<string>",
    "externalIds": {}
  }
]

Body

application/json
name
string
required

Name of the location

latitude
number | null

Latitude of the location's coordinates

longitude
number | null

Longitude of the location's coordinates

address1
string | null

Address 1 of the location

address2
string | null

Address 2 of the location

city
string | null

City the location is in

state
string | null

State the location is in

postalCode
string | null

Postal code the location is in

country
string | null

Country the location is in

externalIds
object

Response

Successful response

id
string
required

ID of the location

createdAt
string
required

Datetime when the location was created

updatedAt
string
required

Datetime when the location was last updated

workspaceId
string
required

ID of the workspace the location belongs to

name
string
required

Name of the location

latitude
number | null

Latitude of the location's coordinates

longitude
number | null

Longitude of the location's coordinates

address1
string | null

Address 1 of the location

address2
string | null

Address 2 of the location

city
string | null

City the location is in

state
string | null

State the location is in

postalCode
string | null

Postal code the location is in

country
string | null

Country the location is in

externalIds
object