Create Station
curl --request POST \
--url https://stage-api.getswitch.io/operations/stations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"address": "Piazza del Duomo, 20122 Milano MI",
"company_slug": "acme-mobility",
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo"
}
'import requests
url = "https://stage-api.getswitch.io/operations/stations"
payload = {
"address": "Piazza del Duomo, 20122 Milano MI",
"company_slug": "acme-mobility",
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
address: 'Piazza del Duomo, 20122 Milano MI',
company_slug: 'acme-mobility',
latitude: 45.4642,
longitude: 9.19,
max_capacity: 20,
name: 'Duomo'
})
};
fetch('https://stage-api.getswitch.io/operations/stations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://stage-api.getswitch.io/operations/stations"
payload := strings.NewReader("{\n \"address\": \"Piazza del Duomo, 20122 Milano MI\",\n \"company_slug\": \"acme-mobility\",\n \"latitude\": 45.4642,\n \"longitude\": 9.19,\n \"max_capacity\": 20,\n \"name\": \"Duomo\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"address": "Piazza del Duomo, 20122 Milano MI",
"company_name": "Acme Mobility",
"company_slug": "acme-mobility",
"created_at": "2026-09-18T10:05:00Z",
"id": 21,
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo",
"polygon": [
[
9.1893,
45.4638
],
[
9.1907,
45.4638
],
[
9.1907,
45.4647
],
[
9.1893,
45.4647
],
[
9.1893,
45.4638
]
],
"updated_at": "2026-11-03T08:31:00Z"
}Fleet Management
Create Station
Add a docking station, with its capacity and optionally its area as a polygon.
Failure Modes:
- 401: Token is missing or invalid
- 403: Insufficient permissions, or
company_slugis a company you cannot manage - 422: Invalid request body, e.g. a polygon that is not closed or has fewer than 4 points
Required Auth Scopes:
stations:manage
POST
/
operations
/
stations
Create Station
curl --request POST \
--url https://stage-api.getswitch.io/operations/stations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"address": "Piazza del Duomo, 20122 Milano MI",
"company_slug": "acme-mobility",
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo"
}
'import requests
url = "https://stage-api.getswitch.io/operations/stations"
payload = {
"address": "Piazza del Duomo, 20122 Milano MI",
"company_slug": "acme-mobility",
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
address: 'Piazza del Duomo, 20122 Milano MI',
company_slug: 'acme-mobility',
latitude: 45.4642,
longitude: 9.19,
max_capacity: 20,
name: 'Duomo'
})
};
fetch('https://stage-api.getswitch.io/operations/stations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://stage-api.getswitch.io/operations/stations"
payload := strings.NewReader("{\n \"address\": \"Piazza del Duomo, 20122 Milano MI\",\n \"company_slug\": \"acme-mobility\",\n \"latitude\": 45.4642,\n \"longitude\": 9.19,\n \"max_capacity\": 20,\n \"name\": \"Duomo\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"address": "Piazza del Duomo, 20122 Milano MI",
"company_name": "Acme Mobility",
"company_slug": "acme-mobility",
"created_at": "2026-09-18T10:05:00Z",
"id": 21,
"latitude": 45.4642,
"longitude": 9.19,
"max_capacity": 20,
"name": "Duomo",
"polygon": [
[
9.1893,
45.4638
],
[
9.1907,
45.4638
],
[
9.1907,
45.4647
],
[
9.1893,
45.4647
],
[
9.1893,
45.4638
]
],
"updated_at": "2026-11-03T08:31:00Z"
}Authorizations
HTTPBearerHTTPBearer
Body
application/json
Schema for creating a new station.
All required fields must be provided including name, address, capacity, and WGS84 coordinates. An optional polygon boundary can define the station's geographic area.
Response
Station created successfully. Returns the complete station profile including coordinates, capacity, optional polygon boundary, and company ownership.
Public schema for a station resource.
Exposes station details to API consumers, including coordinates, capacity, optional polygon boundary, and company ownership.
