Open Monograph Press  3.3.0
Omnipay\PayPal\Message\RestSearchTransactionRequest Class Reference
Inheritance diagram for Omnipay\PayPal\Message\RestSearchTransactionRequest:
Omnipay\PayPal\Message\AbstractRestRequest Omnipay\Common\Message\AbstractRequest Omnipay\Common\Message\RequestInterface Omnipay\Common\Message\MessageInterface

Public Member Functions

 getAgreementId ()
 
 getAgreementId ()
 
 getData ()
 
 getData ()
 
 getEndDate ()
 
 getEndDate ()
 
 getEndpoint ()
 
 getEndpoint ()
 
 getStartDate ()
 
 getStartDate ()
 
 setAgreementId ($value)
 
 setAgreementId ($value)
 
 setEndDate ($value)
 
 setEndDate ($value)
 
 setStartDate ($value)
 
 setStartDate ($value)
 
- Public Member Functions inherited from Omnipay\PayPal\Message\AbstractRestRequest
 getClientId ()
 
 getClientId ()
 
 getPayerId ()
 
 getPayerId ()
 
 getSecret ()
 
 getSecret ()
 
 getToken ()
 
 getToken ()
 
 sendData ($data)
 
 sendData ($data)
 
 setClientId ($value)
 
 setClientId ($value)
 
 setPayerId ($value)
 
 setPayerId ($value)
 
 setSecret ($value)
 
 setSecret ($value)
 
 setToken ($value)
 
 setToken ($value)
 
 toJSON ($data, $options=0)
 
 toJSON ($data, $options=0)
 
- Public Member Functions inherited from Omnipay\Common\Message\AbstractRequest
 __construct (ClientInterface $httpClient, HttpRequest $httpRequest)
 
 __construct (ClientInterface $httpClient, HttpRequest $httpRequest)
 
 formatCurrency ($amount)
 
 formatCurrency ($amount)
 
 getAmount ()
 
 getAmount ()
 
 getAmountInteger ()
 
 getAmountInteger ()
 
 getCancelUrl ()
 
 getCancelUrl ()
 
 getCard ()
 
 getCard ()
 
 getCardReference ()
 
 getCardReference ()
 
 getClientIp ()
 
 getClientIp ()
 
 getCurrency ()
 
 getCurrency ()
 
 getCurrencyDecimalPlaces ()
 
 getCurrencyDecimalPlaces ()
 
 getCurrencyNumeric ()
 
 getCurrencyNumeric ()
 
 getDescription ()
 
 getDescription ()
 
 getIssuer ()
 
 getIssuer ()
 
 getItems ()
 
 getItems ()
 
 getNotifyUrl ()
 
 getNotifyUrl ()
 
 getParameters ()
 
 getPaymentMethod ()
 
 getPaymentMethod ()
 
 getResponse ()
 
 getResponse ()
 
 getReturnUrl ()
 
 getReturnUrl ()
 
 getTestMode ()
 
 getTestMode ()
 
 getTransactionId ()
 
 getTransactionId ()
 
 getTransactionReference ()
 
 getTransactionReference ()
 
 initialize (array $parameters=array())
 
 initialize (array $parameters=array())
 
 send ()
 
 send ()
 
 setAmount ($value)
 
 setAmount ($value)
 
 setAmountInteger ($value)
 
 setCancelUrl ($value)
 
 setCancelUrl ($value)
 
 setCard ($value)
 
 setCard ($value)
 
 setCardReference ($value)
 
 setCardReference ($value)
 
 setClientIp ($value)
 
 setClientIp ($value)
 
 setCurrency ($value)
 
 setCurrency ($value)
 
 setDescription ($value)
 
 setDescription ($value)
 
 setIssuer ($value)
 
 setIssuer ($value)
 
 setItems ($items)
 
 setItems ($items)
 
 setMoney (Money $value)
 
 setNotifyUrl ($value)
 
 setNotifyUrl ($value)
 
 setPaymentMethod ($value)
 
 setPaymentMethod ($value)
 
 setReturnUrl ($value)
 
 setReturnUrl ($value)
 
 setTestMode ($value)
 
 setTestMode ($value)
 
 setTransactionId ($value)
 
 setTransactionId ($value)
 
 setTransactionReference ($value)
 
 setTransactionReference ($value)
 
 toFloat ($value)
 
 validate ()
 

Protected Member Functions

 getHttpMethod ()
 
 getHttpMethod ()
 
- Protected Member Functions inherited from Omnipay\PayPal\Message\AbstractRestRequest
 createResponse ($data, $statusCode)
 
 createResponse ($data, $statusCode)
 
- Protected Member Functions inherited from Omnipay\Common\Message\AbstractRequest
 getCurrencies ()
 
 getParameter ($key)
 
 setParameter ($key, $value)
 
 setParameter ($key, $value)
 

Additional Inherited Members

- Data Fields inherited from Omnipay\PayPal\Message\AbstractRestRequest
const API_VERSION = 'v1'
 
- Protected Attributes inherited from Omnipay\PayPal\Message\AbstractRestRequest
 $liveEndpoint = 'https://api.paypal.com'
 
 $payerId = null
 
 $testEndpoint = 'https://api.sandbox.paypal.com'
 
- Protected Attributes inherited from Omnipay\Common\Message\AbstractRequest
 $currencies
 
 $httpClient
 
 $httpRequest
 
 $negativeAmountAllowed = false
 
 $parameters
 
 $response
 
 $zeroAmountAllowed = true
 

Detailed Description

PayPal REST Search Transaction Request

Use this call to search for the transactions within a billing agreement. Note that this is not a generic transaction search function – for that see RestListPurchaseRequest. It only searches for transactions within a billing agreement.

This should be used on a regular basis to determine the success / failure state of transactions on active billing agreements.

Example

// List the transactions for a billing agreement. $transaction = $gateway->listPurchase(); $response = $transaction->send(); $data = $response->getData(); echo "Gateway listPurchase response data == " . print_r($data, true) . "\n";

Request Sample

This is from the PayPal web site:

curl -v GET https://api.sandbox.paypal.com/v1/payments/billing-agreements/I-0LN988D3JACS/transactions \ -H 'Content-Type:application/json' \ -H 'Authorization: Bearer <Access-Token>'

Response Sample

This is from the PayPal web site:

{ "agreement_transaction_list": [ { "transaction_id": "I-0LN988D3JACS", "status": "Created", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T09:29:36Z", "time_zone": "GMT" }, { "transaction_id": "928415314Y5640008", "status": "Completed", "transaction_type": "Recurring Payment", "amount": { "currency": "USD", "value": "1.00" }, "fee_amount": { "currency": "USD", "value": "-0.33" }, "net_amount": { "currency": "USD", "value": "0.67" }, "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T09:42:47Z", "time_zone": "GMT" }, { "transaction_id": "I-0LN988D3JACS", "status": "Suspended", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T11:18:34Z", "time_zone": "GMT" }, { "transaction_id": "I-0LN988D3JACS", "status": "Reactivated", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T11:18:48Z", "time_zone": "GMT" } ] }

Known Issues

PayPal subscription payments cannot be refunded. PayPal is working on this functionality for their future API release. In order to refund a PayPal subscription payment, you will need to use the PayPal web interface to refund it manually.

See also
RestCreateSubscriptionRequest PayPal REST Search Transaction Request Use this call to search for the transactions within a billing agreement. Note that this is not a generic transaction search function – for that see RestListPurchaseRequest. It only searches for transactions within a billing agreement. This should be used on a regular basis to determine the success / failure state of transactions on active billing agreements. autotoc_md99 Example // List the transactions for a billing agreement. $transaction = $gateway->listPurchase(); $response = $transaction->send(); $data = $response->getData(); echo "Gateway listPurchase response data == " . print_r($data, true) . "\n"; autotoc_md100 Request Sample This is from the PayPal web site: curl -v GET https://api.sandbox.paypal.com/v1/payments/billing-agreements/I-0LN988D3JACS/transactions \ -H 'Content-Type:application/json' \ -H 'Authorization: Bearer <Access-Token>' autotoc_md101 Response Sample This is from the PayPal web site: { "agreement_transaction_list": [ { "transaction_id": "I-0LN988D3JACS", "status": "Created", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T09:29:36Z", "time_zone": "GMT" }, { "transaction_id": "928415314Y5640008", "status": "Completed", "transaction_type": "Recurring Payment", "amount": { "currency": "USD", "value": "1.00" }, "fee_amount": { "currency": "USD", "value": "-0.33" }, "net_amount": { "currency": "USD", "value": "0.67" }, "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T09:42:47Z", "time_zone": "GMT" }, { "transaction_id": "I-0LN988D3JACS", "status": "Suspended", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T11:18:34Z", "time_zone": "GMT" }, { "transaction_id": "I-0LN988D3JACS", "status": "Reactivated", "transaction_type": "Recurring Payment", "payer_email": "bbuyer@example.com", "payer_name": "Betsy Buyer", "time_stamp": "2014-06-09T11:18:48Z", "time_zone": "GMT" } ] } autotoc_md102 Known Issues PayPal subscription payments cannot be refunded. PayPal is working on this functionality for their future API release. In order to refund a PayPal subscription payment, you will need to use the PayPal web interface to refund it manually. RestCreateSubscriptionRequest https://developer.paypal.com/docs/api/#search-for-transactions

Definition at line 107 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

Member Function Documentation

◆ getAgreementId() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getAgreementId ( )

◆ getAgreementId() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getAgreementId ( )

◆ getData() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getData ( )

Get the raw data array for this message. The format of this varies from gateway to gateway, but will usually be either an associative array, or a SimpleXMLElement.

Returns
mixed

Implements Omnipay\Common\Message\MessageInterface.

Definition at line 172 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\PayPal\Message\RestSearchTransactionRequest\getEndDate(), Omnipay\PayPal\Message\RestSearchTransactionRequest\getStartDate(), and Omnipay\Common\Message\AbstractRequest\validate().

◆ getData() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getData ( )

Get the raw data array for this message. The format of this varies from gateway to gateway, but will usually be either an associative array, or a SimpleXMLElement.

Returns
mixed

Implements Omnipay\Common\Message\MessageInterface.

Definition at line 172 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\PayPal\Message\RestSearchTransactionRequest\getEndDate(), Omnipay\PayPal\Message\RestSearchTransactionRequest\getStartDate(), and Omnipay\Common\Message\AbstractRequest\validate().

◆ getEndDate() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getEndDate ( )

◆ getEndDate() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getEndDate ( )

Get the request endDate

Returns
string

Definition at line 156 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\getParameter().

◆ getEndpoint() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getEndpoint ( )

◆ getEndpoint() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getEndpoint ( )

◆ getHttpMethod() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getHttpMethod ( )
protected

Get HTTP Method.

The HTTP method for searchTransaction requests must be GET.

Returns
string

Reimplemented from Omnipay\PayPal\Message\AbstractRestRequest.

Definition at line 188 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

◆ getHttpMethod() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getHttpMethod ( )
protected

Get HTTP Method.

The HTTP method for searchTransaction requests must be GET.

Returns
string

Reimplemented from Omnipay\PayPal\Message\AbstractRestRequest.

Definition at line 188 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

◆ getStartDate() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getStartDate ( )

Get the request startDate

Returns
string

Definition at line 135 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\getParameter().

◆ getStartDate() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::getStartDate ( )

◆ setAgreementId() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setAgreementId (   $value)

Set the agreement ID

Parameters
string$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 125 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().

◆ setAgreementId() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setAgreementId (   $value)

Set the agreement ID

Parameters
string$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 125 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().

◆ setEndDate() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setEndDate (   $value)

Set the request endDate

Parameters
string | DateTime$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 167 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().

◆ setEndDate() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setEndDate (   $value)

Set the request endDate

Parameters
string | DateTime$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 167 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().

◆ setStartDate() [1/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setStartDate (   $value)

Set the request startDate

Parameters
string | DateTime$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 146 of file vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().

◆ setStartDate() [2/2]

Omnipay\PayPal\Message\RestSearchTransactionRequest::setStartDate (   $value)

Set the request startDate

Parameters
string | DateTime$value
Returns
RestSearchTransactionRequest provides a fluent interface.

Definition at line 146 of file lib/vendor/omnipay/paypal/src/Message/RestSearchTransactionRequest.php.

References Omnipay\Common\Message\AbstractRequest\setParameter().


The documentation for this class was generated from the following file: