Заказ для стандартной доставки

From PonyExpress API Wiki
Jump to: navigation, search

Запрос на создание заказа для стандартной доставки

<?xml version="1.0" encoding="utf-8"?>
<Request xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="OrderRequest">
  <Id>1</Id>  
  <Mode>Order</Mode>  
  <OrderList>
    <Order>      
      <ClientsNumber>kb48-12744</ClientsNumber>      
      <Payment>
        <Mode>Bill</Mode>
      </Payment>
      <ServiceList>
        <Service xsi:type="DeliveryService">
          <PickupDate>2016-11-07T00:00:00+03:00</PickupDate>          
          <Mode>Express</Mode>          
          <Sender>
            <Address>
              <Country>Россия</Country>
              <PostCode>127023</PostCode>
              <City>Москва</City>
              <StreetAddress>ул.Строителей, д.13</StreetAddress>
            </Address>
            <Company>
              <Name>ОАО "Компания"</Name>
            </Company>
            <PersonList>
              <Person>
                <Name>Петров Игорь Иванович</Name>
                <PhoneList>
                  <string>+7 495 342-3422</string>
                  <string>12-44</string>
                </PhoneList>              
              </Person>
              <Person>
                <Name>Иванов Семен</Name>
                <PhoneList>
                  <string>+7 910 456-7895</string>
                </PhoneList>              
              </Person>
            </PersonList>
          </Sender>
          <Recipient>
            <Address>
              <Country>Россия</Country>
              <Region>Красноярcкий край</Region>
              <PostCode>660013</PostCode>
              <City>Красноярск</City>
              <StreetAddress>ул.Взлетная, д.1</StreetAddress>
            </Address>
            <Company>
              <Name>ОАО "Самолет"</Name>
            </Company>
            <PersonList>
              <Person>
                <Name>Шпак Геннадий Семенович</Name>
                <PhoneList>
                  <string>+3912 34-23-12</string>
                  <string>11-4</string>
                </PhoneList>              
              </Person>
            </PersonList>
            <Unformalized>Или любому другому лицу в компании</Unformalized>
          </Recipient>
          <CargoList>
            <Cargo>
              <Id>1</Id>
              <Barcode>12345234</Barcode>
              <Description>Пимпачки и помпочки</Description>
              <Packing>
                <Type>Box</Type>
              </Packing>
              <Dimentions>
                <Length>350</Length>
                <Width>500</Width>
                <Height>300</Height>
              </Dimentions>
              <Weight>1400</Weight>              
              <Cost>500</Cost>
            </Cargo>
            <Cargo>
              <Id>2</Id>
              <Barcode>12345235</Barcode>
              <Description>Штучки</Description>
              <Packing>
                <Type>Box</Type>
              </Packing>
              <Dimentions>
                <Length>250</Length>
                <Width>300</Width>
                <Height>200</Height>
              </Dimentions>
              <Weight>800</Weight>              
              <Cost>10000</Cost>
            </Cargo>
          </CargoList>
          <Unformalized>Доставка запчастей</Unformalized>
        </Service>
      </ServiceList>
    </Order>
  </OrderList>
</Request>

Ответ на создание заказа для стандартной доставки

<?xml version="1.0" encoding="utf-8"?>
<Response xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <RequestId>1</RequestId>  
  <OrderList>
    <Order>      
      <ClientsNumber>kb48-12744</ClientsNumber>
      <PerformersNumber>MOW-123243</PerformersNumber>      
      <Payment>
        <Mode>Bill</Mode>
      </Payment>
      <ServiceList>
        <Service xsi:type="DeliveryService">
          <PickupDate>2016-11-07T00:00:00+03:00</PickupDate>          
          <Mode>Express</Mode>          
          <Sender>
            <Address>
              <Country>Россия</Country>
              <PostCode>127023</PostCode>
              <City>Москва</City>
              <StreetAddress>ул.Строителей, д.13</StreetAddress>
            </Address>
            <Company>
              <Name>ОАО "Компания"</Name>
            </Company>
            <PersonList>
              <Person>
                <Name>Петров Игорь Иванович</Name>
                <PhoneList>
                  <string>+7 495 342-3422</string>
                  <string>12-44</string>
                </PhoneList>              
              </Person>
              <Person>
                <Name>Иванов Семен</Name>
                <PhoneList>
                  <string>+7 910 456-7895</string>
                </PhoneList>              
               </Person>
            </PersonList>
          </Sender>
          <Recipient>
            <Address>
              <Country>Россия</Country>
              <Region>Красноярcкий край</Region>
              <PostCode>660013</PostCode>
              <City>Красноярск</City>
              <StreetAddress>ул.Взлетная, д.1</StreetAddress>
            </Address>
            <Company>
              <Name>ОАО "Самолет"</Name>
            </Company>
            <PersonList>
              <Person>
                <Name>Шпак Геннадий Семенович</Name>
                <PhoneList>
                  <string>+3912 34-23-12</string>
                  <string>11-4</string>
                </PhoneList>              
              </Person>
            </PersonList>
            <Unformalized>Или любому другому лицу в компании</Unformalized>
          </Recipient>
          <CargoList>
            <Cargo>
              <Id>1</Id>
              <Barcode>12345234</Barcode>
              <Description>Пимпачки и помпочки</Description>
              <Packing>
                <Type>Box</Type>
              </Packing>
              <Dimentions>
                <Length>350</Length>
                <Width>500</Width>
                <Height>300</Height>
              </Dimentions>
              <Weight>1400</Weight>              
              <Cost>500</Cost>
            </Cargo>
            <Cargo>
              <Id>2</Id>
              <Barcode>12345235</Barcode>
              <Description>Штучки</Description>
              <Packing>
                <Type>Box</Type>
              </Packing>
              <Dimentions>
                <Length>250</Length>
                <Width>300</Width>
                <Height>200</Height>
              </Dimentions>
              <Weight>800</Weight>              
              <Cost>10000</Cost>
            </Cargo>
          </CargoList>
          <Unformalized>Доставка запчастей</Unformalized>
        </Service>
      </ServiceList>
      <StatusList>
        <OrderStatus>
          <Description>Order has been received</Description>
          <Date>2016-10-31T08:37:19.3347816+03:00</Date>          
          <Code>Received</Code>
        </OrderStatus>
      </StatusList>
    </Order>
  </OrderList>
</Response>