| 1 | package WebService::Coincheck::Order; | ||
| 2 | 2 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | 2 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 2 | ▶ | use Class::Accessor::Lite ( |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | 2 | ro => [qw/ | |
| 6 | client | ||
| 7 | /], | ||
| 8 | 2 | ); | |
| 9 | |||
| 10 | 1 | ▶ | sub new { |
|
Subroutine
new: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 11 | 1 | my $class = shift; | |
| 12 | 1 | my $client = shift; | |
| 13 | |||
| 14 | 1 | bless { | |
| 15 | client => $client, | ||
| 16 | }, $class; | ||
| 17 | } | ||
| 18 | |||
| 19 | 0 | ▶ | sub create { |
|
Subroutine
create: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 20 | 0 | my ($self, %params) = @_; | |
| 21 | |||
| 22 | 0 | my $req_params; | |
| 23 | |||
| 24 | 0 | my $res = $self->client->request( | |
| 25 | 'POST' => 'api/exchange/orders', | ||
| 26 | $req_params, | ||
| 27 | ); | ||
| 28 | |||
| 29 | 0 | return $res; | |
| 30 | } | ||
| 31 | |||
| 32 | 0 | ▶ | sub cancel { |
|
Subroutine
cancel: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 33 | 0 | my ($self, %params) = @_; | |
| 34 | |||
| 35 | my $req_params = { | ||
| 36 | id => $params{id}, | ||
| 37 | 0 | }; | |
| 38 | |||
| 39 | 0 | my $res = $self->client->request( | |
| 40 | 'DELETE' => "api/exchange/orders/$req_params->{id}", | ||
| 41 | $req_params, | ||
| 42 | ); | ||
| 43 | |||
| 44 | 0 | return $res; | |
| 45 | } | ||
| 46 | |||
| 47 | 0 | ▶ | sub opens { |
|
Subroutine
opens: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 48 | 0 | my ($self, %params) = @_; | |
| 49 | |||
| 50 | 0 | my $req_params; | |
| 51 | |||
| 52 | 0 | my $res = $self->client->request( | |
| 53 | 'GET' => 'api/exchange/orders/opens', | ||
| 54 | $req_params, | ||
| 55 | ); | ||
| 56 | |||
| 57 | 0 | return $res; | |
| 58 | } | ||
| 59 | |||
| 60 | 0 | ▶ | sub transactions { |
|
Subroutine
transactions: not called CC=1 SCAR=6.9
Pod
undocumented
| |||
| 61 | 0 | my ($self, %params) = @_; | |
| 62 | |||
| 63 | 0 | my $req_params; | |
| 64 | |||
| 65 | 0 | my $res = $self->client->request( | |
| 66 | 'GET' => 'api/exchange/orders/transactions', | ||
| 67 | $req_params, | ||
| 68 | ); | ||
| 69 | |||
| 70 | 0 | return $res; | |
| 71 | } | ||
| 72 | |||
| 73 | 2 | 1; | |