ProcessProductionOrder

Used for creating and updating production orders.

Tags: ProcessProductionOrder, ProductionOrder, ProductionOrderLine, ProductionOrderLineSpecification, ProductionSpecificationArticleLine, Article_ProductionSpecificationArticleLine, ProcessProductionOrderResponse, ProcessProductionOrderError

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/ProcessProductionOrder"

<?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>
      <ProcessProductionOrder xmlns="http://ongoingsystems.se/WSI">
         <GoodsOwnerCode>string</GoodsOwnerCode>
         <UserName>string</UserName>
         <Password>string</Password>
         <ProductionOrder>
            <ProductionOrderIdentification>ProductionOrderNumber</ProductionOrderIdentification>
            <ProductionOrderNumber>string</ProductionOrderNumber>
            <ProductionOrderComment>string</ProductionOrderComment>
            <ProductionDate>dateTime</ProductionDate>
            <ExpiryDate>dateTime</ExpiryDate>
            <ProductionOrderLines>
               <ProductionOrderLine>
                  <ProductionOrderLineIdentification>ProductionOrderLineNumber</ProductionOrderLineIdentification>
                  <ToProduceNumberOfItems>decimal</ToProduceNumberOfItems>
                  <ArticleNumber>string</ArticleNumber>
                  <ProductionOrderLineComment>string</ProductionOrderLineComment>
                  <ProductionOrderLineNumber>string</ProductionOrderLineNumber>
                  <MinDaysToExpiryDate>int</MinDaysToExpiryDate>
                  <Specification>
                    <Lines>
                      <Article>
                        <ArticleIdentification>ArticleNumber or ProductCode or ArticleSystemId</ArticleIdentification>
                        <ArticleNumber>string</ArticleNumber>
                        <ArticleName>string</ArticleName>
                        <ProductCode>string</ProductCode>
                        <ArticleSystemId>int</ArticleSystemId>
                      </Article>
                      <ToConsumeNumberOfItems>decimal</ToConsumeNumberOfItems>
                      <Comment>string</Comment>
                      <LineNumber>string</LineNumber>
                    </Lines>
                  </Specification>
               </ProductionOrderLine>
               <ProductionOrderLine>
                 <ProductionOrderLineIdentification>ProductionOrderLineNumber</ProductionOrderLineIdentification>
                 <ToProduceNumberOfItems>decimal</ToProduceNumberOfItems>
                 <ArticleNumber>string</ArticleNumber>
                 <ProductionOrderLineComment>string</ProductionOrderLineComment>
                 <ProductionOrderLineNumber>string</ProductionOrderLineNumber>
                 <MinDaysToExpiryDate>int</MinDaysToExpiryDate>
                 <Specification>
                   <Lines>
                     <Article>
                       <ArticleIdentification>ArticleNumber or ProductCode or ArticleSystemId</ArticleIdentification>
                       <ArticleNumber>string</ArticleNumber>
                       <ArticleName>string</ArticleName>
                       <ProductCode>string</ProductCode>
                       <ArticleSystemId>int</ArticleSystemId>
                     </Article>
                     <ToConsumeNumberOfItems>decimal</ToConsumeNumberOfItems>
                     <Comment>string</Comment>
                     <LineNumber>string</LineNumber>
                   </Lines>
                 </Specification>
               </ProductionOrderLine>
            </ProductionOrderLines>
         </ProductionOrder>
      </ProcessProductionOrder>
   </soap:Body>
</soap:Envelope>

Request specification

ProcessProductionOrder
GoodsOwnerCode str(400) Req. The name/code of your client
UserName str(50) Req. Username
Password str(50) Req. Password
ProductionOrder ProductionOrder Req. The ProductionOrder object
ProductionOrder
ProductionOrderIdentification enum Req. Defines how you want to identify the production order.
 - ProductionOrderNumber
ProductionOrderNumber str(50) Required if ProductionOrderIdentification = ProductionOrderNumber Production order number in the goods owners system.
ProductionOrderComment str(200) Not required. Comment to warehouse.
ProductionDate DateTime Not required. When the production is expected to be done.
ExpiryDate DateTime Not required. Expiry date of the produced goods
ProductionOrderLines object Containing information about the articles to produce as elements of ProductionOrderLine.
ProductionOrderLine
ProductionOrderLineIdentification enum Req. Defines how to find the order line on the original order.
 - ProductionOrderLineNumber
ToProduceNumberOfItems decimal Req. The number of items to produce.
ArticleNumber str(100) Req. The article number of the article to produce. The article must have been defined as a production article in Ongoing WMS.
ProductionOrderLineComment str(100) Not required. Comment to warehouse.
ProductionOrderLineNumber str(50) Req. Required if ProductionOrderLineIdentification = ProductionOrderLineNumber
MinDaysToExpiryDate int Defines the minimum amount of days that the sub articles are allowed to have until expiry when consuming them.
Specification object An object of type ProductionOrderLineSpecification. In most cases, this object should be null. If you specify null here, Ongoing WMS will take the specification of the production article from the article registry in Ongoing WMS.

In some cases, the "recipe" for the production article is not static and needs to be different for different production orders. If you specify this field, then Ongoing WMS will use it as the "recipe" for the production article.
ProductionOrderLineSpecification
Lines ProductionSpecificationArticleLine[] A list of ProductionSpecificationArticleLine.
ProductionSpecificationArticleLine
Article Article_ProductionSpecificationArticleLine[] An object of type Article_ProductionSpecificationArticleLine, which specifies which article this line refers to.
ToConsumeNumberOfItems dec The number of items to consume during production.
Comment str Comment.
LineNumber str Line number. Must be unique for each production order.
Article_ProductionSpecificationArticleLine
ArticleIdentification enum[] Defines what you want to identify the article by
 - ArticleNumber
 - ProductCode
 - ArticleSystemId
Most integrationse use ArticleNumber.
ArticleNumber str Article number.
ArticleName str Article name
ProductCode str Product code
ArticleSystemId int Article system id

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>
      <ProcessProductionOrderResponse xmlns="http://ongoingsystems.se/WSI">
         <ProcessProductionOrderResult>
            <ProductionOrderId>int</ProductionOrderId>
            <Success>boolean</Success>
            <ProcessProductionOrderErrors>
               <ProcessProductionOrderError>
                  <Message>string</Message>
                  <ErrorType>LogonError or ProductionOrderNumberNotSupplied or UnknownError or NonExistingArticleSupplied or ToProduceNumberOfItemsNotAPositiveValue or ErrorUpdatingProductionOrderLine or NoneProductionArticleSupplied</ErrorType>
               </ProcessProductionOrderError>
               <ProcessProductionOrderError>
                  <Message>string</Message>
                  <ErrorType>LogonError or ProductionOrderNumberNotSupplied or UnknownError or NonExistingArticleSupplied or ToProduceNumberOfItemsNotAPositiveValue or ErrorUpdatingProductionOrderLine or NoneProductionArticleSupplied</ErrorType>
               </ProcessProductionOrderError>
            </ProcessProductionOrderErrors>
         </ProcessProductionOrderResult>
      </ProcessProductionOrderResponse>
   </soap:Body>
</soap:Envelope>

Response specification

ProcessProductionOrderResult
ProductionOrderId integer Ongoing WMS internal id for the production order.
Success boolean If operation was successful or not.
ProcessProductionOrderErrors Collection of ProcessProductionOrderErrors A list of errors which have occured.
ProcessProductionOrderError
Message string Error message.
ErrorType Enumeration Provides a set of known error codes.
 - LogonError
 - ProductionOrderNumberNotSupplied
 - UnknownError
 - NonExistingArticleSupplied
 - ToProduceNumberOfItemsNotAPositiveValue
 - ErrorUpdatingProductionOrderLine
 - NoneProductionArticleSupplied