POST api/order/quote
This API method creates an empty quote for the specified company and site, sets the quote description and has the option of assigning a contact to the quote.
Error Messages
- 401/Unauthorised - Logged in User, user not valid - User does not have the required permissions.
- 403/Forbidden - Company ID must be populated - The company ID must be specified.
- 404/NotFound - No company found with ID x - No company has been assigned to the specified ID.
- 404/NotFound - Site with id x not found - No site has been assigned to the specified ID.
- 404/NotFound - DefaultSiteID must be populated - The default site must be specified.
- 404/NotFound - The Site with id x was not found for the company with id = y - The site ID specified was not found on the list of sites on the company ID specified.
- 404/NotFound - Site contact with id x not found - The contact ID was not found on the specified site ID.
- 404/NotFound - The Order Contact with id x was not found for the company with id y - The order contact ID specified was not found on the specified company ID.
Request Information
URI Parameters
None.
Body Parameters
OrdersPostRequestName | Description | Type | Additional information |
---|---|---|---|
CompanyID | The ID of the Company who will own the quote | integer |
None. |
DefaultSiteID | The ID of the default site in the company who own the quote | integer |
None. |
ContactID | The ID of the main Contact for the quote | integer |
None. |
QuoteName | The quote name | string |
Required String length: inclusive between 0 and 100 |
Request Formats
application/json, text/json
Sample:
{ "CompanyID": 1, "DefaultSiteID": 1, "ContactID": 1, "QuoteName": "sample string 2" }
application/xml, text/xml
Sample:
<OrdersPostRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/aBILLity.API.Models"> <CompanyID>1</CompanyID> <ContactID>1</ContactID> <DefaultSiteID>1</DefaultSiteID> <QuoteName>sample string 2</QuoteName> </OrdersPostRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
OrdersPostResponseName | Description | Type | Additional information |
---|---|---|---|
ID | integer |
None. |
Response Formats
application/json, text/json
Sample:
{ "ID": 1 }
application/xml, text/xml
Sample:
<OrdersPostResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/aBILLity.API.Models"> <ID>1</ID> </OrdersPostResponse>