Problem definition: We study a two-stage supply chain, where the supplier procures a key component to manufacture a product and the buyer orders from the supplier to meet a price-sensitive demand. As the input price is volatile, the two parties enter into either a standard contract, where the buyer orders just before the supplier starts production, or a time-flexible contract, where the buyer can lock a wholesale price in advance. Moreover, we consider three selling-price schemes: Market Driven, Cost Plus, and Profit Max. Academic/practical relevance: This problem is motivated by real practices in the cloud industry. Our model and optimization approach can address similar problems in other industries as well. Methodology: We assume that the input price follows a geometric Brownian motion. To determine the optimal ordering time, we propose an optimization approach that is different from the classic approach by Dixit et al. ( 1994 ) and Li and Kouvelis ( 1999 ). Our approach leads to deeper analytical results and more transparent ordering policy. Through a numerical experimentation, we compare profitability of different parties under different contracts, pricing schemes, and market conditions. Results: The buyer’s ordering policy is determined by a threshold policy based on the current time and input price; the optimal threshold depends on not only the drift and volatility of the input price but also, their relative magnitude. The supplier’s optimal procurement time should be determined by analyzing a trade-off between the holding cost of storing the components and the future input-price movement. Managerial implications: Under the Profit-Max and the Cost-Plus pricing schemes, the time-flexible contract is a Pareto improvement compared with the standard contract, whereas under the Market-Driven pricing scheme, the supplier may be better off under the standard contract. Moreover, although the most favorable scenario for the buyer is under the Profit-Max pricing scheme, the most favorable scenario for the supplier oftentimes is under the Cost-Plus pricing scheme. Furthermore, this study provides valuable insights into impacts of various characteristics of the component market, such as the trend and volatility of the input price, on the expected profit of the supply chain and its split between the two parties.