# Create purchase order

This operation is used to create an inbound inventory request. Successful execution of this operation will generate a new purchase order in Wineshipping system. The inbound request can be a pickup from customer address or a drop-off at a Wineshipping warehouse location. A transaction reference identifier is returned in this operation. Store this identifier in your application and systems as applicable. This reference ID is available in the event a problem occurs with the associated request.

Endpoint: POST /api/InventoryMovement/CreatePurchaseOrder
Version: 3.1.3

## Request fields (application/json):

  - `Authentication` (object, required)
    Credentials are required for all API operations.

  - `Authentication.UserKey` (string, required)
    Example: "C445598CB576468EA35FBB22C55584EF"

  - `Authentication.Password` (string, required)
    Example: "AF63FDAC1E704DC1AC9460F669ABF107"

  - `Authentication.CustomerNo` (string, required)
    Example: "10703"

  - `OrderInfo` (object, required)

  - `OrderInfo.CustomerReferenceNo` (string, required)

  - `OrderInfo.TransportMethod` (string, required)

  - `OrderInfo.RequestedDate` (string, required)

  - `OrderInfo.ReceiveToLocation` (string, required)
    See [warehouse locations](../../../../docs/codes/warehouselocations) for possible values.
    Enum: "APC01", "APC02", "COB01", "COB02", "ETC01", "MMC01", "PRB02", "PRB04", "SJU01", "TWL01", "VCX01", "WOX01"

  - `OrderInfo.InventoryStatusCode` (string, required)
    See [inventory codes](../../../../docs/codes/inventorycodes) for possible values. Array of up to 5 items is allowed, and if omitted, all items will be included in the results.
    Enum: "GOOD-NO-TX", "RTGD-NO-TX", "RDMG-NO-TX", "CDMG-NO-TX", "DMGD-NO-TX", "GOOD-NO-BD", "DMGD-ST-BD", "GOOD-ST-IM"

  - `OrderInfo.ReferenceNo` (string, required)
    Pickup reference number

  - `OrderInfo.FirstName` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.LastName` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.Company` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.Address` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.Address2` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.City` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.State` (string)
    Required, if TransportMethod = PICKUP
    Example: "CA"

  - `OrderInfo.ZipCode` (string)
    Required, if TransportMethod = PICKUP

  - `OrderInfo.PhoneNumber` (string)
    Example: "7079339063"

  - `OrderInfo.EmailAddress` (string)

  - `OrderInfo.SpecialInstruction` (string)

  - `ItemsInfo` (array, required)

  - `ItemsInfo.ItemNo` (string, required)
    Example: "ITEMTEST"

  - `ItemsInfo.ItemDescription` (string)
    Example: "2019 Cab Napa Valley"

  - `ItemsInfo.ItemQuantity` (integer, required)


## Response 201 fields

## Response 400 fields

## Response 401 fields

## Response 429 fields

## Response 500 fields
