POST api/Location/PostLocation

Request Information

URI Parameters

None.

Body Parameters

Location
NameDescriptionTypeAdditional information
LocationId

integer

None.

Description

string

None.

PracticeId

integer

None.

Address

string

None.

LocationGPS

DbGeography

None.

LocationGeoCode

string

None.

Request Formats

application/json, text/json

Sample:
{
  "LocationId": 1,
  "Description": "sample string 2",
  "PracticeId": 1,
  "Address": "sample string 3",
  "LocationGPS": null,
  "LocationGeoCode": "sample string 4"
}

text/html

Sample:
{"LocationId":1,"Description":"sample string 2","PracticeId":1,"Address":"sample string 3","LocationGPS":null,"LocationGeoCode":"sample string 4"}

application/xml, text/xml

Sample:
<Location xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FleetAPI.DataModel">
  <Address>sample string 3</Address>
  <Description>sample string 2</Description>
  <LocationGPS xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Data.Entity.Spatial" i:nil="true" />
  <LocationGeoCode>sample string 4</LocationGeoCode>
  <LocationId>1</LocationId>
  <PracticeId>1</PracticeId>
</Location>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'Location'.

Response Information

Resource Description

Location
NameDescriptionTypeAdditional information
LocationId

integer

None.

Description

string

None.

PracticeId

integer

None.

Address

string

None.

LocationGPS

DbGeography

None.

LocationGeoCode

string

None.

Response Formats

application/json, text/json

Sample:
{
  "LocationId": 1,
  "Description": "sample string 2",
  "PracticeId": 1,
  "Address": "sample string 3",
  "LocationGPS": null,
  "LocationGeoCode": "sample string 4"
}

text/html

Sample:
{"LocationId":1,"Description":"sample string 2","PracticeId":1,"Address":"sample string 3","LocationGPS":null,"LocationGeoCode":"sample string 4"}

application/xml, text/xml

Sample:
<Location xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FleetAPI.DataModel">
  <Address>sample string 3</Address>
  <Description>sample string 2</Description>
  <LocationGPS xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Data.Entity.Spatial" i:nil="true" />
  <LocationGeoCode>sample string 4</LocationGeoCode>
  <LocationId>1</LocationId>
  <PracticeId>1</PracticeId>
</Location>