GET /api/v1/Company
Description: Returns end customer companies linked to your company.
Url: https://serviceapi.episerver.com/api/v1/Company
Http method: GET
Request
Request headers
Accept: application/json, text/json, application/xml, text/xml,
HTTP Request Example
GET | https://serviceapi.episerver.com/api/v1/Company?apikey=xxx{&CompanyId=1} |
Accept: | application/xml |
URI Parameters
Field name | Description | Type | Optional | Default |
CompanyId | Filter companies by id. | integer |
Yes
|
Response
Successful HTTP Response: 200 Status Code
Responce Body
Field name | Description | Type |
TotalCount | integer | |
Records | V1CompanyDto |
Records.Id | Id. | integer |
Records.Name | Name. | string |
Records.Address | Primary Address. | string |
Records.Address2 | Secondary address. | string |
Records.ZipCode | Zip code. | string |
Records.City | City. | string |
Records.Country | Country. | string |
Response Format
{ "TotalCount": 1, "Records": [ { "Id": 1, "Name": "sample string 2", "Address": "sample string 3", "Address2": "sample string 4", "ZipCode": "sample string 5", "City": "sample string 6", "Country": "sample string 7" }, { "Id": 1, "Name": "sample string 2", "Address": "sample string 3", "Address2": "sample string 4", "ZipCode": "sample string 5", "City": "sample string 6", "Country": "sample string 7" } ] } |
<V1ResponseModelOfV1CompanyDto xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <TotalCount>1</TotalCount> <Records> <V1CompanyDto> <Id>1</Id> <Name>sample string 2</Name> <Address>sample string 3</Address> <Address2>sample string 4</Address2> <ZipCode>sample string 5</ZipCode> <City>sample string 6</City> <Country>sample string 7</Country> </V1CompanyDto> <V1CompanyDto> <Id>1</Id> <Name>sample string 2</Name> <Address>sample string 3</Address> <Address2>sample string 4</Address2> <ZipCode>sample string 5</ZipCode> <City>sample string 6</City> <Country>sample string 7</Country> </V1CompanyDto> </Records> </V1ResponseModelOfV1CompanyDto> |
Error HTTP Response: Error Status Codes
Status Code | Description |
200 OK | Successfull request |
400 Bad Request | Path variable may be invalid |
403 Forbidden | Insufficient role |
404 Not Found | Request not found |
405 Method Not Allowed | Request method not allowed |
500 Internal Server Error | Unexpected server error |
Error Body
Field name | Description | Type |
StatusCode | The HTTP status code. | String |
StatusDesc | Description of HTTP status code. | String |
ErrorMessage | Additional information. | String |
Response Format
{ "StatusCode": "sample string 1", "StatusDesc": "sample string 2", "ErrorMessage": "sample string 3" } |