NAME

Finance::Robinhood::Forex::Order - Represents a Single Forex Order

SYNOPSIS

use Finance::Robinhood;
my $rh = Finance::Robinhood->new;

# TODO

METHODS

cumulative_quantity( )

Returns the amount of currency bought or sold.

pair_id( )

Returns a UUIS.

id( )

Returns a UUID.

price( )

Returns a dollar amount.

quantity( )

Returns the amount of currency in the order.

ref_id( )

Returns a UUID.

side

Returns buy or sell.

state( )

Returns canceled, rejected, filled, queued, or unconfirmed.

time_in_force( )

can_cancel( )

Returns true if the order can be cancelled.

created_at( )

Returns a Time::Moment object.

last_transaction_at( )

Returns a Time::Moment object.

updated_at( )

Returns a Time::Moment object.

account( )

Returns the related Finance::Robinhood::Forex::Account object.

pair( )

Returns the related Finance::Robinhood::Forex::Pair object.

executions( )

Returns a list of related Finance::Robinhood::Forex::Order::Execution objects if applicable.

cancel( )

$order->cancel();

If the order can be cancelled, this method will do it.

Be aware that the order is still active for about a second after this is called so I'm adding a 'smart' delay here.

reload( )

$order->reload();

Reloads the data for this order from the API server.

Use this if you think the status or some other info might have changed.

LEGAL

This is a simple wrapper around the API used in the official apps. The author provides no investment, legal, or tax advice and is not responsible for any damages incurred while using this software. This software is not affiliated with Robinhood Financial LLC in any way.

For Robinhood's terms and disclosures, please see their website at https://robinhood.com/legal/

LICENSE

Copyright (C) Sanko Robinson.

This library is free software; you can redistribute it and/or modify it under the terms found in the Artistic License 2. Other copyrights, terms, and conditions may apply to data transmitted through this module. Please refer to the LEGAL section.

AUTHOR

Sanko Robinson <sanko@cpan.org>