GET api/site
This API method returns a list of all sites.
Note that, if you are an agent you will be unable to see the information returned in the Bill Run Fields (these will read as null). When a Site is created, you will get the ID of the newly created site in the site response.
Error Messages
404/NotFound - No sites found
Request Information
URI Parameters
None.
Body Parameters
None.
Response Information
Resource Description
Collection of SiteViewName | Description | Type | Additional information |
---|---|---|---|
Id | The unique identifier for the site. | integer |
None. |
CompanyId | The unique identifier of the parent company. | integer |
None. |
BillingAddress | The site ID of the billing site i.e. any billable items for this site will be invoiced to the billing site. | integer |
None. |
CustomProperties | Custom controls created with the Service Designer | Collection of EntityCustomPropertyView |
None. |
BillRunIDLocal | Site Bill Run ID | integer |
None. |
BillRunNameLocal | Site Bill Run Name | string |
None. |
BillRunIDInherited | Default Bill Run ID | integer |
None. |
BillRunNameInherited | Default Bill Run Name | string |
None. |
LastUpdated | The date and time the CLI has been updated | date |
None. |
SiteName | The name for the site. | string |
Required String length: inclusive between 0 and 255 |
ShortName | A reference name for the site. | string |
Required String length: inclusive between 0 and 255 |
Address | Address information for the site. | string |
String length: inclusive between 0 and 255 |
Town | Address information for the site. | string |
String length: inclusive between 0 and 50 |
County | Address Information for the site. | string |
String length: inclusive between 0 and 50 |
PostCode | The Postcode for the site. | string |
String length: inclusive between 0 and 20 |
Fax | The main fax number for the site. | string |
String length: inclusive between 0 and 30 |
Telephone | The main telephone number for the site. | string |
String length: inclusive between 0 and 30 |
MainSite | The site is the main site for the Company. | boolean |
None. |
AccountRef | The Account Reference number | string |
String length: inclusive between 0 and 30 |