PUT api/MailOrders/CreateMailOrder/{PaymentMethod}
This allows a list of mail orders to be created in the system by passing the details in the objects within the body of the request.
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
PaymentMethod |
This is the payment method for the mail orders to be recorded. |
string |
Required |
Body Parameters
This holds the list of mail orders to be created.
Collection of ObjectNone.
Request Formats
application/json, text/json
Sample:
{"Customer":{"ID":0,"Email":"","UDF":"","Title":"","Firstname":"","Middlename":"","Lastname":"","DOB":"0001-01-01T00:00:00","CompanyName":"","HouseNo":"","AddressLine1":"","AddressLine2":"","AddressLine3":"","City":"","Postcode":"","County":"","Country":"","TelephoneNumber":"","EveningTelephoneNumber":"","MailingList":"","Notes":"","Password":"","Interests":[{"ID":0,"Description":""}],"PersonImage":"","DDAcountHolder":"","DDAccountNumber":"","DDSortCode":"","DDBankName":"","DDBankAddress":"","DDBankPostCode":"","MemberNumber":"","AccountRef":"","ConsentMail":false,"ConsentPhone":false,"ConsentSMS":false,"ConsentEmail":false,"Username":"","ForcePasswordChange":false,"CustomerRef":""},"DeliveryAddress":{"HouseNo":"","Line1":"","Line2":"","Line3":"","City":"","Country":"","Postcode":""},"InvoiceAddress":{"HouseNo":"","Line1":"","Line2":"","Line3":"","City":"","Country":"","Postcode":""},"GiftDetails":"","GiftWrapped":false,"PackingNotes":"","DeliveryInstructions":"","Postage":0.0,"Products":[{"Qty":0,"Price":0.0,"ProductDescription":"","PLU":""}]}
application/xml, text/xml
Sample:
<?xml version="1.0" encoding="utf-16"?> <MaiLOrder xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <Customer> <ID>0</ID> <Email /> <UDF /> <Title /> <Firstname /> <Middlename /> <Lastname /> <DOB>0001-01-01T00:00:00</DOB> <CompanyName /> <HouseNo /> <AddressLine1 /> <AddressLine2 /> <AddressLine3 /> <City /> <Postcode /> <County /> <Country /> <TelephoneNumber /> <EveningTelephoneNumber /> <MailingList /> <Notes /> <Password /> <Interests> <APICustomerInterest> <ID>0</ID> <Description /> </APICustomerInterest> </Interests> <PersonImage /> <DDAcountHolder /> <DDAccountNumber /> <DDSortCode /> <DDBankName /> <DDBankAddress /> <DDBankPostCode /> <MemberNumber /> <AccountRef /> <ConsentMail>false</ConsentMail> <ConsentPhone>false</ConsentPhone> <ConsentSMS>false</ConsentSMS> <ConsentEmail>false</ConsentEmail> <Username /> <ForcePasswordChange>false</ForcePasswordChange> <CustomerRef /> </Customer> <DeliveryAddress> <HouseNo /> <Line1 /> <Line2 /> <Line3 /> <City /> <Country /> <Postcode /> </DeliveryAddress> <InvoiceAddress> <HouseNo /> <Line1 /> <Line2 /> <Line3 /> <City /> <Country /> <Postcode /> </InvoiceAddress> <GiftDetails /> <GiftWrapped>false</GiftWrapped> <PackingNotes /> <DeliveryInstructions /> <Postage>0</Postage> <Products> <APIMailOrderProduct> <Qty>0</Qty> <Price>0</Price> <ProductDescription /> <PLU /> </APIMailOrderProduct> </Products> </MaiLOrder>
Response Information
Resource Description
Returns a list of mail order responses for each mail order passed, with details of the save status and ID's of the mail orders.
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. |
Response Formats
application/json, text/json
Sample:
[{"SaveStatus":"","MailOrderID":0,"CustomerName":""}]
application/xml, text/xml
Sample:
<?xml version="1.0" encoding="utf-16"?> <MailOrderResponses xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <APIMailOrderResponse> <SaveStatus /> <MailOrderID>0</MailOrderID> <CustomerName /> </APIMailOrderResponse> </MailOrderResponses>