POST api/Vet/V1/Employers
Create new employer
All fields are required, except EmployerCode and UserName.
ABN is a key value to check duplicated employer in the system before insert.
Request Information
URI Parameters
None.
Body Parameters
ModelVetEmployerV1 [EmployerCode and UserName can be null.]
ModelVetEmployerV1Name | Description | Type | Additional information |
---|---|---|---|
EmployerCode |
Unique employer code/identifier |
string |
None. |
EmployerName |
Employer legal name |
string |
None. |
UserName |
User name. It can be null. |
string |
None. |
Contact email address |
string |
None. |
|
ABN |
Company ABN number |
string |
None. |
ContactPerson |
Contact person name |
string |
None. |
TradingName |
Company trading name |
string |
None. |
Request Formats
application/json, text/json
{ "EmployerCode": "sample string 1", "EmployerName": "sample string 2", "UserName": "sample string 3", "Email": "sample string 4", "ABN": "sample string 5", "ContactPerson": "sample string 6", "TradingName": "sample string 7" }
application/xml, text/xml
<ModelVetEmployerV1 xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DotEdu_WebAPI.Models.Vet.V1"> <ABN>sample string 5</ABN> <ContactPerson>sample string 6</ContactPerson> <Email>sample string 4</Email> <EmployerCode>sample string 1</EmployerCode> <EmployerName>sample string 2</EmployerName> <TradingName>sample string 7</TradingName> <UserName>sample string 3</UserName> </ModelVetEmployerV1>
application/x-www-form-urlencoded
Sample not available.
Response Information
Resource Description
If success, status code is 201 (Created), with return message is the created employer code/id and header location is 'api/vet/v1/Employers/{employerid}'. Else, 400 (Bad request).
HttpResponseMessageName | Description | Type | Additional information |
---|---|---|---|
Version | Version |
None. |
|
Content | HttpContent |
None. |
|
StatusCode | HttpStatusCode |
None. |
|
ReasonPhrase | string |
None. |
|
Headers | Collection of Object |
None. |
|
RequestMessage | HttpRequestMessage |
None. |
|
IsSuccessStatusCode | boolean |
None. |