Learn how to retrieve a full list of available site types via the Expansive API
Understanding which site types are available to you is important. When creating records such as sites the site type must be set correctly so your contractors understand what requirements are needed to undertake a job.
Resource
/v2/site-types
Method
GET
Headers
Key | Value |
Authorization | Bearer <TOKEN> (find out more) |
Content-Type | application/vnd.api+json |
Expected Response
200 OK
{
"jsonapi": {
"version": "1.0"
},
"data": [
{
"type": "site-types",
"id": "1",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Store",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/1/sites",
"self": "http://localhost:8080/api/v2/site-types/1/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/1"
}
},
{
"type": "site-types",
"id": "2",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Office",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/2/sites",
"self": "http://localhost:8080/api/v2/site-types/2/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/2"
}
},
{
"type": "site-types",
"id": "3",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Warehouse",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/3/sites",
"self": "http://localhost:8080/api/v2/site-types/3/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/3"
}
},
{
"type": "site-types",
"id": "4",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Concession",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/4/sites",
"self": "http://localhost:8080/api/v2/site-types/4/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/4"
}
},
{
"type": "site-types",
"id": "5",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Residential",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/5/sites",
"self": "http://localhost:8080/api/v2/site-types/5/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/5"
}
},
{
"type": "site-types",
"id": "6",
"attributes": {
"created_at": null,
"enabled": true,
"name": "Sublet",
"updated_at": null
},
"relationships": {
"Sites": {
"links": {
"related": "http://localhost:8080/api/v2/site-types/6/sites",
"self": "http://localhost:8080/api/v2/site-types/6/relationships/sites"
}
}
},
"links": {
"self": "http://localhost:8080/api/v2/site-types/6"
}
}
]
}