Ongoing Warehouse logo

Ongoing Warehouse Developer

ProcessCustomer

Used to create or update a customer.

Tags: ProcessCustomer, Customer, GoodsOwner, InvoiceAddress, CustomerGroup, ProcessCustomerResult

Request XML

POST /xxx/service.asmx HTTP/1.1
Host: api.ongoingsystems.se
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://ongoingsystems.se/WSI/ProcessCustomer"

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Body>
      <ProcessCustomer xmlns="http://ongoingsystems.se/WSI">
         <GoodsOwnerCode>string</GoodsOwnerCode>
         <UserName>string</UserName>
         <Password>string</Password>
         <Customer>
            <CustomerOperation>Create or CreateOrUpdate or CreateNotUpdate or Find</CustomerOperation>
            <CustomerIdentification>ExternalCustomerCode or SystemId or CustomerNumber or FullNameAndAddress</CustomerIdentification>
            <ExternalCustomerCode>string</ExternalCustomerCode>
            <CustomerNumber>string</CustomerNumber>
            <CustomerId>int</CustomerId>
            <DeliveryAddressId>int</DeliveryAddressId>
            <InvoiceAddressId>int</InvoiceAddressId>
            <Coordinates>
               <Longitude>decimal</Longitude>
               <Latitude>decimal</Latitude>
            </Coordinates>
            <Name>string</Name>
            <Address>string</Address>
            <Address2>string</Address2>
            <Address3>string</Address3>
            <PostCode>string</PostCode>
            <City>string</City>
            <TelePhone>string</TelePhone>
            <Remark>string</Remark>
            <Email>string</Email>
            <MobilePhone>string</MobilePhone>
            <CountryCode>string</CountryCode>
            <CountryStateCode>string</CountryStateCode>
            <DeliveryInstruction>string</DeliveryInstruction>
            <IsVisible>boolean</IsVisible>
            <NotifyBySMS>boolean</NotifyBySMS>
            <NotifyByEmail>boolean</NotifyByEmail>
            <NotifyByTelephone>boolean</NotifyByTelephone>
            <InvoiceAddress>
               <Coordinates>
                  <Longitude>decimal</Longitude>
                  <Latitude>decimal</Latitude>
               </Coordinates>
               <Name>string</Name>
               <Address>string</Address>
               <Address2>string</Address2>
               <Address3>string</Address3>
               <PostCode>string</PostCode>
               <City>string</City>
               <TelePhone>string</TelePhone>
               <Remark>string</Remark>
               <Email>string</Email>
               <MobilePhone>string</MobilePhone>
               <CountryStateCode>string</CountryStateCode>
               <CountryCode>string</CountryCode>
               <DeliveryInstruction>string</DeliveryInstruction>
               <IsVisible>boolean</IsVisible>
               <NotifyBySMS>boolean</NotifyBySMS>
               <NotifyByEmail>boolean</NotifyByEmail>
               <NotifyByTelephone>boolean</NotifyByTelephone>
            </InvoiceAddress>
            <CustomerGroup>
               <CustomerGroupOperation>Find</CustomerGroupOperation>
               <CustomerGroupIdentification>CustomerGroupCode or CustomerGroupName</CustomerGroupIdentification>
               <CustomerGroupCode>string</CustomerGroupCode>
               <CustomerGroupName>string</CustomerGroupName>
            </CustomerGroup>
            <OrganisationNumber>string</OrganisationNumber>
            <VATNumber>string</VATNumber>
            <DoorCode>string</DoorCode>
         </Customer>
      </ProcessCustomer>
   </soap:Body>
</soap:Envelope>
+

Request specification

ProcessCustomer
GoodsOwnerCode str(400) Req. The name/code of your client
UserName str(50) Req. Your username
Password str(50) Req. Your password
Customer object Req. The Customer object
Customer
CustomerOperation enum Req. Defines the operation:
 - Create
 - CreateOrUpdate
 - CreateNotUpdate
 - Find
CustomerIdentification enum Req. Defines what you want to identify the customer by (what is unique):
 - ExternalCustomerCode
 - SystemId
 - CustomerNumber
 - FullNameAndAddress
GoodsOwner object Omit Only for internal purposes, don't use
ExternalCustomerCode str(50) Req.* External customer code. Required if CustomerIdentification = ExternalCustomerCode
CustomerNumber str(50) Req.* Customer number. Required if CustomerIdentification = CustomerNumber
CustomerId int Req.* Ongoing id (SystemId). Required if CustomerIdentification = SystemId
DeliveryAddressId int Only usable when the Customer tag is used within the ProcessOrder request and CustomerOperation = Find. Binds the delivery address of the order directly to the Ongoing system id of the address
InvoiceAddressId int Only usable when the Customer tag is used within the ProcessOrder request and CustomerOperation = Find
Coordinates object Coordinates of customer
> Longitude dec Req. Longitude
> Latitude dec Req. Latitude
Name str(200) Name
Address str(200) Address line 1
Address2 str(200) Address line 2
Address3 str(200) Address line 3
PostCode str(50) Post code/zip
City str(200) City
TelePhone str(50) Telephone number (non cellular)
Remark str(800) Remark/comment
Email str(300) Email address
MobilePhone str(50) Mobile phone number (cellular)
CountryCode str(2) The two-letter ISO 3166-1 alpha-2 code of the country.
CountryStateCode str(50) Req.* The two-letter ISO 3166-2 abbreviation of the state. Required for United States and Canada. See ISO 3166-2:US for United States and ISO 3166-2:CA for Canada.
DeliveryInstruction str(300) Delivery instruction
IsVisible bool False if the address shouldn't show in the system, e.g. be re-used for manual order
NotifyBySMS bool True if the customer should be notified by the transporter through SMS
NotifyByEmail bool True if the customer should be notified by the transporter through e-mail
NotifyByTelephone bool True if the customer should be notified by the transporter through phone call
InvoiceAddress object Address object defining invoice address for the customer. Fields from Coordinates to NotifyByTelephone from the Customer object apply
CustomerGroup object Customer group, enable grouping of customers
OrganisationNumber str(20) Organisation number
VATNumber str(20) VAT number
DoorCode str(30) Door code, may be sent to transporter for use during delivery
GoodsOwner
GoodsOwnerIdentification enum Req. Defines what you want to identify the goods owner by
 - SystemId
 - GoodsOwnerCode
GoodsOwnerCode str(400) Req.* The name/code of your client. Required if GoodsOwnerIdentification = GoodsOwnerCode
GoodsOwnerId int Req.* The id of your client. Required if GoodsOwnerIdentification = SystemId
FinancialCode str(50) Omit Deprecated, don't use
GoodsLocationCode str(50) Omit Deprecated, don't use
InvoiceAddress
Coordinates object Coordinates of the invoice address
> Longitude dec Req. Longitude
> Latitude dec Req. Latitude
Name str(200) Name
Address str(200) Address line 1
Address2 str(200) Address line 2
Address3 str(200) Address line 3
PostCode str(50) Post code/zip
City str(200) City
TelePhone str(50) Telephone number (non cellular)
Remark str(800) Remark/comment
Email str(300) Email address
MobilePhone str(50) Mobile phone number (cellular)
CountryStateCode str(50) The two-letter ISO 3166-2 abbreviation of the state. Mainly used for United States and Canada. See ISO 3166-2:US for United States and ISO 3166-2:CA for Canada.
CountryCode str(2) The two-letter ISO 3166-1 alpha-2 code of the country.
DeliveryInstruction str(300) Delivery instruction
IsVisible bool False if the address shouldn't show in the system, e.g. be re-used for manual order
NotifyBySMS bool True if the customer should be notified by the transporter through SMS
NotifyByEmail bool True if the customer should be notified by the transporter through e-mail
NotifyByTelephone bool True if the customer should be notified by the transporter through phone call
CustomerGroup
CustomerGroupOperation enum Req. Defines the operation
 - Find
CustomerGroupIdentification enum Req. Defines what you want to identify the customer group by
 - CustomerGroupCode
 - CustomerGroupName
CustomerGroupCode str(50) Req.* Customer group code. Required if CustomerGroupIdentification = CustomerGroupCode
CustomerGroupName str(100) Req.* Customer group name. Required if CustomerGroupIdentification = CustomerGroupName

Response XML

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8" ?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:Body>
      <ProcessCustomerResponse xmlns="http://ongoingsystems.se/WSI">
         <ProcessCustomerResult>
            <ErrorMessage>string</ErrorMessage>
            <GoodsOwnerOrderNumber>string</GoodsOwnerOrderNumber>
            <OrderId>int</OrderId>
            <InOrderId>int</InOrderId>
            <ArticleDefId>int</ArticleDefId>
            <Success>boolean</Success>
            <Message>string</Message>
         </ProcessCustomerResult>
      </ProcessCustomerResponse>
   </soap:Body>
</soap:Envelope>
+

Response specification

ProcessCustomerResult
ErrorMessage str(*) Error message
GoodsOwnerOrderNumber str(50) Not used
OrderId int Not used
InOrderId int Not used
ArticleDefId int Not used
Success bool True if success
Message str(*) Process message