Overview
  • Namespace
  • Class

Namespaces

  • PayPal
    • Api
    • Auth
    • Cache
    • Common
    • Converter
    • Core
    • Exception
    • Handler
    • Log
    • Rest
    • Security
    • Transport
    • Validation

Classes

  • Address
  • Agreement
  • AgreementDetails
  • AgreementStateDescriptor
  • AgreementTransaction
  • AgreementTransactions
  • AlternatePayment
  • Amount
  • Authorization
  • BankAccount
  • BankAccountsList
  • BankToken
  • BaseAddress
  • Billing
  • BillingAgreementToken
  • BillingInfo
  • CancelNotification
  • Capture
  • CarrierAccount
  • CarrierAccountToken
  • CartBase
  • ChargeModel
  • Cost
  • CountryCode
  • CreateProfileResponse
  • Credit
  • CreditCard
  • CreditCardHistory
  • CreditCardList
  • CreditCardToken
  • CreditFinancingOffered
  • Currency
  • CurrencyConversion
  • CustomAmount
  • DetailedRefund
  • Details
  • Error
  • ErrorDetails
  • ExtendedBankAccount
  • ExternalFunding
  • FileAttachment
  • FlowConfig
  • FmfDetails
  • FundingDetail
  • FundingInstrument
  • FundingOption
  • FundingSource
  • FuturePayment
  • HyperSchema
  • Image
  • Incentive
  • InputFields
  • InstallmentInfo
  • InstallmentOption
  • Invoice
  • InvoiceAddress
  • InvoiceItem
  • InvoiceNumber
  • InvoiceSearchResponse
  • Item
  • ItemList
  • Links
  • Measurement
  • MerchantInfo
  • MerchantPreferences
  • Metadata
  • NameValuePair
  • Notification
  • OpenIdAddress
  • OpenIdError
  • OpenIdSession
  • OpenIdTokeninfo
  • OpenIdUserinfo
  • Order
  • OverrideChargeModel
  • Participant
  • Patch
  • PatchRequest
  • Payee
  • Payer
  • PayerInfo
  • Payment
  • PaymentCard
  • PaymentCardToken
  • PaymentDefinition
  • PaymentDetail
  • PaymentExecution
  • PaymentHistory
  • PaymentInstruction
  • PaymentOptions
  • PaymentSummary
  • PaymentTerm
  • Payout
  • PayoutBatch
  • PayoutBatchHeader
  • PayoutItem
  • PayoutItemDetails
  • PayoutSenderBatchHeader
  • Phone
  • Plan
  • PlanList
  • PotentialPayerInfo
  • Presentation
  • PrivateLabelCard
  • ProcessorResponse
  • RecipientBankingInstruction
  • RedirectUrls
  • Refund
  • RefundDetail
  • RefundRequest
  • RelatedResources
  • Sale
  • Search
  • ShippingAddress
  • ShippingCost
  • ShippingInfo
  • Tax
  • Template
  • TemplateData
  • Templates
  • TemplateSettings
  • TemplateSettingsMetadata
  • Terms
  • Transaction
  • TransactionBase
  • Transactions
  • VerifyWebhookSignature
  • VerifyWebhookSignatureResponse
  • Webhook
  • WebhookEvent
  • WebhookEventList
  • WebhookEventType
  • WebhookEventTypeList
  • WebhookList
  • WebProfile

Class Capture

Class Capture

A capture transaction.

PayPal\Common\PayPalModel
Extended by PayPal\Common\PayPalResourceModel implements PayPal\Rest\IResource
Extended by PayPal\Api\Capture
Namespace: PayPal\Api
Package: PayPal\Api
Located at PayPal/Api/Capture.php

Methods summary

public
# setId( string $id )

The ID of the capture transaction.

The ID of the capture transaction.

Parameters

$id

Returns


$this
public string
# getId( )

The ID of the capture transaction.

The ID of the capture transaction.

Returns

string
public
# setAmount( PayPal\Api\Amount $amount )

The amount to capture. If the amount matches the orginally authorized amount, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured.

The amount to capture. If the amount matches the orginally authorized amount, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured.

Parameters

$amount

Returns


$this
public PayPal\Api\Amount
# getAmount( )

The amount to capture. If the amount matches the orginally authorized amount, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured.

The amount to capture. If the amount matches the orginally authorized amount, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured.

Returns

PayPal\Api\Amount
public
# setIsFinalCapture( boolean $is_final_capture )

Indicates whether to release all remaining funds that the authorization holds in the funding instrument. Default is false.

Indicates whether to release all remaining funds that the authorization holds in the funding instrument. Default is false.

Parameters

$is_final_capture

Returns


$this
public boolean
# getIsFinalCapture( )

Indicates whether to release all remaining funds that the authorization holds in the funding instrument. Default is false.

Indicates whether to release all remaining funds that the authorization holds in the funding instrument. Default is false.

Returns

boolean
public
# setState( string $state )

The state of the capture. Valid Values: ["pending", "completed", "refunded", "partially_refunded"]

The state of the capture. Valid Values: ["pending", "completed", "refunded", "partially_refunded"]

Parameters

$state

Returns


$this
public string
# getState( )

The state of the capture.

The state of the capture.

Returns

string
public
# setReasonCode( string $reason_code )

The reason code that describes why the transaction state is pending or reversed. Valid Values: ["CHARGEBACK", "GUARANTEE", "BUYER_COMPLAINT", "REFUND", "UNCONFIRMED_SHIPPING_ADDRESS", "ECHECK", "INTERNATIONAL_WITHDRAWAL", "RECEIVING_PREFERENCE_MANDATES_MANUAL_ACTION", "PAYMENT_REVIEW", "REGULATORY_REVIEW", "UNILATERAL", "VERIFICATION_REQUIRED", "TRANSACTION_APPROVED_AWAITING_FUNDING"]

The reason code that describes why the transaction state is pending or reversed. Valid Values: ["CHARGEBACK", "GUARANTEE", "BUYER_COMPLAINT", "REFUND", "UNCONFIRMED_SHIPPING_ADDRESS", "ECHECK", "INTERNATIONAL_WITHDRAWAL", "RECEIVING_PREFERENCE_MANDATES_MANUAL_ACTION", "PAYMENT_REVIEW", "REGULATORY_REVIEW", "UNILATERAL", "VERIFICATION_REQUIRED", "TRANSACTION_APPROVED_AWAITING_FUNDING"]

Parameters

$reason_code

Returns


$this
public string
# getReasonCode( )

The reason code that describes why the transaction state is pending or reversed.

The reason code that describes why the transaction state is pending or reversed.

Returns

string
public
# setParentPayment( string $parent_payment )

The ID of the payment on which this transaction is based.

The ID of the payment on which this transaction is based.

Parameters

$parent_payment

Returns


$this
public string
# getParentPayment( )

The ID of the payment on which this transaction is based.

The ID of the payment on which this transaction is based.

Returns

string
public
# setInvoiceNumber( string $invoice_number )

The invoice number to track this payment.

The invoice number to track this payment.

Parameters

$invoice_number

Returns


$this
public string
# getInvoiceNumber( )

The invoice number to track this payment.

The invoice number to track this payment.

Returns

string
public
# setTransactionFee( PayPal\Api\Currency $transaction_fee )

The transaction fee for this payment.

The transaction fee for this payment.

Parameters

$transaction_fee

Returns


$this
public PayPal\Api\Currency
# getTransactionFee( )

The transaction fee for this payment.

The transaction fee for this payment.

Returns

PayPal\Api\Currency
public
# setCreateTime( string $create_time )

The date and time of capture, as defined in RFC 3339 Section 5.6.

The date and time of capture, as defined in RFC 3339 Section 5.6.

Parameters

$create_time

Returns


$this
public string
# getCreateTime( )

The date and time of capture, as defined in RFC 3339 Section 5.6.

The date and time of capture, as defined in RFC 3339 Section 5.6.

Returns

string
public
# setUpdateTime( string $update_time )

The date and time when the resource was last updated.

The date and time when the resource was last updated.

Parameters

$update_time

Returns


$this
public string
# getUpdateTime( )

The date and time when the resource was last updated.

The date and time when the resource was last updated.

Returns

string
public static PayPal\Api\Capture
# get( string $captureId, PayPal\Rest\ApiContext $apiContext = null, PayPal\Transport\PayPalRestCall $restCall = null )

Shows details for a captured payment, by ID.

Shows details for a captured payment, by ID.

Parameters

$captureId
$apiContext
is the APIContext for this call. It can be used to pass dynamic configuration and credentials.
$restCall
is the Rest Call Service that is used to make rest calls

Returns

PayPal\Api\Capture
public PayPal\Api\Refund
# refund( PayPal\Api\Refund $refund, PayPal\Rest\ApiContext $apiContext = null, PayPal\Transport\PayPalRestCall $restCall = null )

Refund a captured payment by passing the capture_id in the request URI. In addition, include an amount object in the body of the request JSON.

Refund a captured payment by passing the capture_id in the request URI. In addition, include an amount object in the body of the request JSON.

Deprecated

Please use #refundCapturedPayment instead.

Parameters

$refund
$apiContext
is the APIContext for this call. It can be used to pass dynamic configuration and credentials.
$restCall
is the Rest Call Service that is used to make rest calls

Returns

PayPal\Api\Refund
public PayPal\Api\DetailedRefund
# refundCapturedPayment( PayPal\Api\RefundRequest $refundRequest, PayPal\Rest\ApiContext $apiContext = null, PayPal\Transport\PayPalRestCall $restCall = null )

Refunds a captured payment, by ID. Include an amount object in the JSON request body.

Refunds a captured payment, by ID. Include an amount object in the JSON request body.

Parameters

$refundRequest
$apiContext
is the APIContext for this call. It can be used to pass dynamic configuration and credentials.
$restCall
is the Rest Call Service that is used to make rest calls

Returns

PayPal\Api\DetailedRefund

Methods inherited from PayPal\Common\PayPalResourceModel

addLink(), executeCall(), getLink(), getLinks(), removeLink(), setLinks(), updateAccessToken()

Methods inherited from PayPal\Common\PayPalModel

__construct(), __get(), __isset(), __set(), __toString(), __unset(), fromArray(), fromJson(), getList(), setCredential(), toArray(), toJSON()

Properties summary

Properties inherited from PayPal\Common\PayPalModel

$credential

API documentation generated by ApiGen