Skip to main content
PUT
/
locations
/
{id}
Update location data
curl --request PUT \
  --url https://api.spirii.com/locations/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "Gentofte Hospital",
  "isPublic": true,
  "lat": 55.41392687,
  "lon": 11.34266069
}
'
{
  "id": 1158,
  "name": "ERWII",
  "streetAddress": "Kokbjerg 30",
  "zipCode": "6000",
  "city": "Kolding",
  "country": "Denmark",
  "operatorId": 1,
  "companyId": 7,
  "type": "Parking lot",
  "isPublic": true,
  "coordinate": {
    "lat": 55.53578,
    "lon": 9.486323
  },
  "fuseCapacity": 32,
  "chargeBoxes": [
    {
      "id": 1,
      "cpSerialNumber": "CPSN1",
      "CBID": "DK.SPI.Z1",
      "firstUsageAt": "2021-01-29 06:45:22",
      "evses": [
        "DK.SPI.Z1*1",
        "DK.SPI.Z1*2"
      ]
    },
    {
      "id": 2,
      "cpSerialNumber": "CPSN2",
      "CBID": "DK.SPI.Z2",
      "firstUsageAt": "2021-01-29 06:45:22",
      "evses": [
        "DK.SPI.Z2*1",
        "DK.SPI.Z2*2"
      ]
    }
  ],
  "appUsers": [],
  "orders": [],
  "pricing": {
    "perKwh": 3,
    "currency": "DKK",
    "vat": 0.25
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
integer
required

location ID to retrieve

Example:

1

Body

application/json

Location data

name
string
required

name

isPublic
boolean
required

Public status identifier

lat
number
required

latitude

lon
number
required

longitude

Response

Location data of specific location

id
integer
required

id

Example:

1

name
string
required

name

Example:

"Kokbjerg"

streetAddress
string
required

street

Example:

"Kokbjerg 30"

zipCode
string
required

zip code

Example:

"6000"

city
string
required

city

Example:

"Kolding"

country
string
required

country

Example:

"Denmark"

operatorId
integer
required

operator id

Example:

1

companyId
integer | null
required

company id

Example:

1

type
string | null
required

location type

Example:

"Parking lot"

isPublic
boolean
required

Public status identifier

Example:

true

coordinate
object
required
fuseCapacity
integer
required

fuse capacity

Example:

32

chargeBoxes
object[]
required

ChargeBoxes

appUsers
(string | integer)[]
required

users id

orders
(string | integer)[]
required

orders id

Example:

1

pricing
object
required