Annotations¶
Note
The class’ in async_v20.endpoints.annotations
are used as parameter annotations for some OandaClient API calls,
in order to correctly map passed arguments to the correct endpoint
parameter
-
class
async_v20.endpoints.annotations.
AlignmentTimezone
[source]¶ Bases:
str
The timezone to use for the dailyAlignment parameter. Candlesticks with daily alignment will be aligned to the dailyAlignment hour within the alignmentTimezone. [default=America/New_York]
-
class
async_v20.endpoints.annotations.
Authorization
[source]¶ Bases:
str
Contains OANDA’s v20 API authorization token
-
class
async_v20.endpoints.annotations.
Count
[source]¶ Bases:
int
The number of candlesticks to return in the reponse. Count should not be specified if both the start and end parameters are provided, as the time range combined with the graularity will determine the number of candlesticks to return. [default=500, maximum=5000]
-
class
async_v20.endpoints.annotations.
DailyAlignment
[source]¶ Bases:
int
The hour of the day (in the specified timezone) to use for granularities that have daily alignments. [default=17, minimum=0, maximum=23]
-
class
async_v20.endpoints.annotations.
End
[source]¶ Bases:
str
Only show events which started before this date, inclusive. Suggested format RFC 2822 or RFC 1123
-
class
async_v20.endpoints.annotations.
FromTime
[source]¶ Bases:
async_v20.definitions.primitives.DateTime
A DateTime to be used as the starting period of a query
-
class
async_v20.endpoints.annotations.
FromTransactionID
[source]¶ Bases:
async_v20.definitions.primitives.TransactionID
A TransactionID to be used as the starting period of a query
-
class
async_v20.endpoints.annotations.
IncludeFirstQuery
[source]¶ Bases:
async_v20.endpoints.annotations.Bool
A flag that controls whether the candlestick that is covered by the from time should be included in the results. This flag enables clients to use the timestamp of the last completed candlestick received to poll for future candlesticks but avoid receiving the previous candlestick repeatedly. [default=True]
-
class
async_v20.endpoints.annotations.
LastTransactionID
[source]¶ Bases:
async_v20.definitions.primitives.TransactionID
Contains the most recent TransactionID
-
class
async_v20.endpoints.annotations.
LongClientExtensions
(id: ClientID= sentinel, tag: ClientTag= sentinel, comment: ClientComment= sentinel)[source]¶ Bases:
async_v20.definitions.types.ClientExtensions
The client extensions to add to the MarketOrder used to close the long position
-
class
async_v20.endpoints.annotations.
LongUnits
[source]¶ Bases:
str
Indication of how much of the long Position to closeout. Either the string “ALL”, the string “NONE”, or a DecimalNumber representing how many units of the long position to close using a PositionCloseout MarketOrder. The units specified must always be positive.
-
class
async_v20.endpoints.annotations.
PageSize
[source]¶ Bases:
int
The number of Transactions to include in each page of the results. [default=100, maximum=1000]
-
class
async_v20.endpoints.annotations.
ServiceID
[source]¶ Bases:
str
The specifier of the service to get
-
class
async_v20.endpoints.annotations.
ServiceListID
[source]¶ Bases:
str
Identification string of service list to get
-
class
async_v20.endpoints.annotations.
ShortClientExtensions
(id: ClientID= sentinel, tag: ClientTag= sentinel, comment: ClientComment= sentinel)[source]¶ Bases:
async_v20.definitions.types.ClientExtensions
The client extensions to add to the MarketOrder used to close the short position
-
class
async_v20.endpoints.annotations.
ShortUnits
[source]¶ Bases:
str
Indication of how much of the short Position to closeout. Either the string “ALL”, the string “NONE”, or a DecimalNumber representing how many units of the short position to close using a PositionCloseout MarketOrder. The units specified must always be positive.
-
class
async_v20.endpoints.annotations.
SinceTransactionID
[source]¶ Bases:
async_v20.definitions.primitives.TransactionID
The account changes to get Since LastTransactionID for account_changes() method
-
class
async_v20.endpoints.annotations.
Smooth
[source]¶ Bases:
async_v20.endpoints.annotations.Bool
A flag that controls whether the candlestick is ‘smoothed’ or not. A smoothed candlestick uses the previous candle’s close price as its open price, while an unsmoothed candlestick uses the first price from its time range as its open price. [default=False]
-
class
async_v20.endpoints.annotations.
Snapshot
[source]¶ Bases:
async_v20.endpoints.annotations.Bool
Flag that enables/disables the sending of a pricing snapshot when initially connecting to the stream. [default=True]
-
class
async_v20.endpoints.annotations.
Start
[source]¶ Bases:
str
Only show events which started after this date, inclusive. Suggested format RFC 2822 or RFC 1123
-
class
async_v20.endpoints.annotations.
ToTime
[source]¶ Bases:
async_v20.definitions.primitives.DateTime
A DateTime to be used as the ending period of a query
-
class
async_v20.endpoints.annotations.
ToTransactionID
[source]¶ Bases:
async_v20.definitions.primitives.TransactionID
A TransactionID to be used as the ending period of a query
-
class
async_v20.endpoints.annotations.
TradeClientExtensions
(id: ClientID= sentinel, tag: ClientTag= sentinel, comment: ClientComment= sentinel)[source]¶ Bases:
async_v20.definitions.types.ClientExtensions
None
-
class
async_v20.endpoints.annotations.
Units
[source]¶ Bases:
str
Indication of how much of the Trade to close. Either the string “ALL” (indicating that all of the Trade should be closed), or a DecimalNumber representing the number of units of the open Trade to Close using a TradeClose MarketOrder. The units specified must always be positive, and the magnitude of the value cannot exceed the magnitude of the Trade’s open units