diff --git a/pom.xml b/pom.xml index fb6fb38..9b67c89 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ 4.0.0 com.oanda.v20 v20 - 3.0.25 + 3.0.26 jar diff --git a/src/com/oanda/v20/pricing/PricingCandlesRequest.java b/src/com/oanda/v20/pricing/PricingCandlesRequest.java index bffa818..670d227 100644 --- a/src/com/oanda/v20/pricing/PricingCandlesRequest.java +++ b/src/com/oanda/v20/pricing/PricingCandlesRequest.java @@ -3,6 +3,7 @@ import java.math.BigDecimal; import com.oanda.v20.Request; +import com.oanda.v20.account.AccountID; import com.oanda.v20.instrument.CandlestickGranularity; import com.oanda.v20.instrument.WeeklyAlignment; import com.oanda.v20.primitives.DateTime; @@ -21,7 +22,8 @@ public class PricingCandlesRequest extends Request { *

* @param instrument Name of the Instrument */ - public PricingCandlesRequest(InstrumentName instrument) { + public PricingCandlesRequest(AccountID accountID, InstrumentName instrument) { + this.setPathParam("accountID", accountID); this.setPathParam("instrument", instrument); } diff --git a/src/com/oanda/v20/pricing/PricingContext.java b/src/com/oanda/v20/pricing/PricingContext.java index cfe9ccd..7a995c4 100644 --- a/src/com/oanda/v20/pricing/PricingContext.java +++ b/src/com/oanda/v20/pricing/PricingContext.java @@ -199,10 +199,11 @@ public PricingGetResponse get(PricingGetRequest request) * @see RequestException * @see ExecuteException */ - public PricingCandlesResponse candles(InstrumentName instrument) + + public PricingCandlesResponse candles(AccountID accountID, InstrumentName instrument) throws RequestException, ExecuteException { - PricingCandlesRequest request = new PricingCandlesRequest(instrument); + PricingCandlesRequest request = new PricingCandlesRequest(accountID, instrument); return candles(request); }