File Coverage

lib/eBay/API/XML/Call/GetSellerPayments.pm
Criterion Covered Total %
statement 7 9 77.7
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 10 12 83.3


line stmt bran cond sub pod time code
1             #!/usr/bin/perl
2              
3             package eBay::API::XML::Call::GetSellerPayments;
4              
5 1     1   2448 use strict;
  1         3  
  1         25  
6 1     1   4 use warnings;
  1         3  
  1         31  
7              
8             ##########################################################################
9             #
10             # Module: ............... eBay/API/XML
11             # File: ................. GetSellerPayments.pm
12             # Generated by: ......... genEBayApiDataTypes.pl
13             # Last Generated: ....... 08/24/2008 16:44
14             # API Release Number: ... 579
15             #
16             ##########################################################################
17              
18             =head1 NAME
19              
20             eBay::API::XML::Call::GetSellerPayments
21              
22             =head1 DESCRIPTION
23              
24              
25              
26             =head1 SYNOPSIS
27              
28             =cut
29              
30              
31             =head1 INHERITANCE
32              
33             eBay::API::XML::Call::GetSellerPayments inherits from the L class
34              
35             =cut
36              
37 1     1   38 use eBay::API::XML::BaseCall;
  0            
  0            
38             our @ISA = ("eBay::API::XML::BaseCall");
39              
40             use eBay::API::XML::Call::GetSellerPayments::GetSellerPaymentsRequestType;
41             use eBay::API::XML::Call::GetSellerPayments::GetSellerPaymentsResponseType;
42              
43              
44             =head1 Subroutines:
45              
46             =cut
47              
48             sub getApiCallName {
49             return 'GetSellerPayments';
50             }
51             sub getRequestDataTypeFullPackage {
52             return 'eBay::API::XML::Call::GetSellerPayments::GetSellerPaymentsRequestType';
53             }
54             sub getResponseDataTypeFullPackage {
55             return 'eBay::API::XML::Call::GetSellerPayments::GetSellerPaymentsResponseType';
56             }
57              
58             #
59             # input properties
60             #
61              
62             =head2 setPagination()
63              
64             If many payments are available, you may need to call GetSellerPayments
65             multiple times to retrieve all the data. Each result set is returned as a
66             page of entries. Use this Pagination information to indicate the maximum
67             number of entries to retrieve per page (i.e., per call), the page number
68             to retrieve, and other data.
69              
70             RequiredInput: No
71             # Argument: 'ns:PaginationType'
72              
73             =cut
74            
75             sub setPagination {
76             my $self = shift;
77             my $pPagination = shift;
78             $self->getRequestDataType()->setPagination($pPagination);
79             }
80              
81             =head2 setPaymentStatus()
82              
83             Filter to retrieve only items with the specified payment status (Paid or
84             Pending). "Pending payments" are payments that Half.com has created but
85             that have not yet been sent to the seller's financial institution. Pending
86             payments are typically available once a buyer pays for an order. As
87             Half.com processes payments by using periodic batch jobs, the
88             GetSellerPayments response might not include a transaction's payment for
89             up to 20 minutes after the buyer has paid. You can retrieve pending
90             payments for the current pay period. Pending payments that have not been
91             settled yet can also be retrieved for previous pay periods. "Paid
92             payments" are payments that Half.com processed during previous pay
93             periods. Paid payments might not appear in the seller's financial
94             institution account balance until a certain number of days after the
95             current pay period ends (see the Half.com online help for details). You
96             can only retrieve paid payments for one previous pay period at a time.
97              
98             RequiredInput: Yes
99             AllValuesExcept: Canceled
100             # Argument: 'ns:RCSPaymentStatusCodeType'
101              
102             =cut
103            
104             sub setPaymentStatus {
105             my $self = shift;
106             my $sPaymentStatus = shift;
107             $self->getRequestDataType()->setPaymentStatus($sPaymentStatus);
108             }
109              
110             =head2 setPaymentTimeFrom()
111              
112             Time range filter that retrieves Half.com payments that were created within
113             a single pay period. Sellers can refer to the Half.com site to determine
114             their pay periods. PaymentTimeFrom is the earliest (oldest) time and
115             PaymentTimeTo is the latest (most recent) time in the range. Half.com pay
116             periods start and end at midnight Pacific time, but the time values are
117             stored in the database in GMT (not Pacific time). See "Time Values" in the
118             eBay Web Services guide for information about converting between GMT and
119             Pacific time.
120            
121             If you specify a PaymentStatus of Pending, add a buffer of one hour (or one
122             day) to both ends of the time range to retrieve more data than you need, and
123             then filter the results on the client side as needed. If any pending
124             payments match the request, the response may include all payments since the
125             beginning of the period.
126            
127             If you specify a PaymentStatus of Paid, the time range must contain one
128             full pay period. That is, PaymentTimeFrom must be earlier or equal the
129             start time of the pay period, and PaymentTimeTo must be later than or
130             equal to the end time of the pay period. Otherwise, no paid payments are
131             returned. For example, if the pay period starts on 2005-09-16 and ends on
132             2005-09-30, you could specify an earlier PaymentTimeFrom value of
133             2005-09-16T00:00:00.000Z and a later PaymentTimeTo value of
134             2005-10-01T12:00:00.000Z.
135            
136             If you specify a time range that covers two pay periods, only the payments
137             from the most recent pay period are returned. The earliest time you can
138             specify is 18 months ago.
139              
140             RequiredInput: Yes
141             # Argument: 'xs:dateTime'
142              
143             =cut
144            
145             sub setPaymentTimeFrom {
146             my $self = shift;
147             my $sPaymentTimeFrom = shift;
148             $self->getRequestDataType()->setPaymentTimeFrom($sPaymentTimeFrom);
149             }
150              
151             =head2 setPaymentTimeTo()
152              
153             Time range filter that retrieves Half.com payments for a single pay
154             period. See the description of PaymentTimeTo for details about using this
155             time range filter. For paid payments, this value should be equal to or
156             later than the end of the last day of the pay period, where the time is
157             converted to GMT. For example, if the period ends on 2005-09-30, you could
158             specify 2005-10-01T09:00:00.000Z, which is later than the end of the last
159             day.
160              
161             RequiredInput: Yes
162             # Argument: 'xs:dateTime'
163              
164             =cut
165            
166             sub setPaymentTimeTo {
167             my $self = shift;
168             my $sPaymentTimeTo = shift;
169             $self->getRequestDataType()->setPaymentTimeTo($sPaymentTimeTo);
170             }
171              
172              
173              
174             #
175             # output properties
176             #
177              
178             =head2 isHasMorePayments()
179              
180             If true, there are more payments yet to be retrieved. Additional
181             GetSellerPayments calls with higher page numbers or more entries per page
182             must be made to retrieve these payments. If false, no more payments are
183             available or no payments match the request (based on the payment status
184             and time filter).
185              
186             Returned: Always
187             # Returns: 'xs:boolean'
188              
189             =cut
190            
191             sub isHasMorePayments {
192             my $self = shift;
193             return $self->getResponseDataType()->isHasMorePayments();
194             }
195              
196             =head2 getPageNumber()
197              
198             Indicates which page of data holds the current result set. Will be the
199             same as the value specified in the Pagination.PageNumber input. (If the
200             input is higher than the total number of pages, the call fails with an
201             error.) If no payments are returned, the value is 0. If payments are
202             returned, the first page number is 1.
203              
204             Returned: Always
205             # Returns: 'xs:int'
206              
207             =cut
208            
209             sub getPageNumber {
210             my $self = shift;
211             return $self->getResponseDataType()->getPageNumber();
212             }
213              
214             =head2 getPaginationResult()
215              
216             Contains information regarding the pagination of data (if pagination is used),
217             including total number of pages and total number of entries.
218              
219             Returned: Always
220             # Returns: 'ns:PaginationResultType'
221              
222             =cut
223            
224             sub getPaginationResult {
225             my $self = shift;
226             return $self->getResponseDataType()->getPaginationResult();
227             }
228              
229             =head2 getPaymentsPerPage()
230              
231             Indicates the number of payments that can be returned per page of data
232             (i.e., per call). This is the same as the value specified in the
233             Pagination.EntriesPerPage input (or the default value, if EntriesPerPage
234             was not specified). This is not necessarily the actual number of payments
235             returned per page (see ReturnedPaymentCountActual).
236              
237             Returned: Always
238             # Returns: 'xs:int'
239              
240             =cut
241            
242             sub getPaymentsPerPage {
243             my $self = shift;
244             return $self->getResponseDataType()->getPaymentsPerPage();
245             }
246              
247             =head2 getReturnedPaymentCountActual()
248              
249             Indicates the total number of payments returned (i.e., the number of
250             SellerPayment entries returned.
251              
252             Returned: Always
253             # Returns: 'xs:int'
254              
255             =cut
256            
257             sub getReturnedPaymentCountActual {
258             my $self = shift;
259             return $self->getResponseDataType()->getReturnedPaymentCountActual();
260             }
261              
262             =head2 getSellerPayment()
263              
264             Information about a single payment that matches the criteria in the
265             request. A payment is between Half.com and a seller. Each payment is for
266             one transaction for one item in one order. An order can contain
267             transactions for multiple items from multiple sellers, but this call only
268             retrieves payments that are relevant to one seller. The financial value of
269             a payment is typically based on an amount that a buyer paid to Half.com
270             for a transaction, plus the shipping cost the buyer paid for the item,
271             minus Half.com's commission. Payments can also describe refunds that the
272             seller has issued. Multiple SellerPayment entries can be returned per page
273             of results. Typically, they are returned in reverse chronological order
274             (most recent PaidTime first). Only returned if payments exist that match
275             the request.
276              
277             Returned: Conditionally
278             # Returns: reference to an array
279             of 'ns:SellerPaymentType'
280              
281             =cut
282            
283             sub getSellerPayment {
284             my $self = shift;
285             return $self->getResponseDataType()->getSellerPayment();
286             }
287              
288              
289              
290              
291              
292             1;