• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stripe / stripe-php / 9275776897

28 May 2024 08:15PM UTC coverage: 65.291% (-0.8%) from 66.119%
9275776897

Pull #1701

github

web-flow
Merge a23205ff7 into 7038876e7
Pull Request #1701: Demagiced crudl operation

1026 of 1594 new or added lines in 106 files covered. (64.37%)

15 existing lines in 3 files now uncovered.

3386 of 5186 relevant lines covered (65.29%)

2.26 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/lib/Treasury/ReceivedDebit.php
1
<?php
2

3
// File generated from our OpenAPI spec
4

5
namespace Stripe\Treasury;
6

7
/**
8
 * ReceivedDebits represent funds pulled from a <a href="https://stripe.com/docs/api#financial_accounts">FinancialAccount</a>. These are not initiated from the FinancialAccount.
9
 *
10
 * @property string $id Unique identifier for the object.
11
 * @property string $object String representing the object's type. Objects of the same type share the same value.
12
 * @property int $amount Amount (in cents) transferred.
13
 * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
14
 * @property string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
15
 * @property string $description An arbitrary string attached to the object. Often useful for displaying to users.
16
 * @property null|string $failure_code Reason for the failure. A ReceivedDebit might fail because the FinancialAccount doesn't have sufficient funds, is closed, or is frozen.
17
 * @property null|string $financial_account The FinancialAccount that funds were pulled from.
18
 * @property null|string $hosted_regulatory_receipt_url A <a href="https://stripe.com/docs/treasury/moving-money/regulatory-receipts">hosted transaction receipt</a> URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
19
 * @property null|\Stripe\StripeObject $initiating_payment_method_details
20
 * @property \Stripe\StripeObject $linked_flows
21
 * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
22
 * @property string $network The network used for the ReceivedDebit.
23
 * @property null|\Stripe\StripeObject $reversal_details Details describing when a ReceivedDebit might be reversed.
24
 * @property string $status Status of the ReceivedDebit. ReceivedDebits are created with a status of either <code>succeeded</code> (approved) or <code>failed</code> (declined). The failure reason can be found under the <code>failure_code</code>.
25
 * @property null|string|\Stripe\Treasury\Transaction $transaction The Transaction associated with this object.
26
 */
27
class ReceivedDebit extends \Stripe\ApiResource
28
{
29
    const OBJECT_NAME = 'treasury.received_debit';
30

31
    const FAILURE_CODE_ACCOUNT_CLOSED = 'account_closed';
32
    const FAILURE_CODE_ACCOUNT_FROZEN = 'account_frozen';
33
    const FAILURE_CODE_INSUFFICIENT_FUNDS = 'insufficient_funds';
34
    const FAILURE_CODE_OTHER = 'other';
35

36
    const NETWORK_ACH = 'ach';
37
    const NETWORK_CARD = 'card';
38
    const NETWORK_STRIPE = 'stripe';
39

40
    const STATUS_FAILED = 'failed';
41
    const STATUS_SUCCEEDED = 'succeeded';
42

43
    /**
44
     * Returns a list of ReceivedDebits.
45
     *
46
     * @param null|mixed $params
47
     * @param null|mixed $opts
48
     */
NEW
49
    public static function all($params = null, $opts = null)
×
50
    {
NEW
51
        return static::_requestPage('/v1/treasury/received_debits', \Stripe\Collection::class, $params, $opts);
×
52
    }
53

54
    /**
55
     * Retrieves the details of an existing ReceivedDebit by passing the unique
56
     * ReceivedDebit ID from the ReceivedDebit list.
57
     *
58
     * @param mixed $id
59
     * @param null|mixed $opts
60
     */
NEW
61
    public static function retrieve($id, $opts = null)
×
62
    {
NEW
63
        $opts = \Stripe\Util\RequestOptions::parse($opts);
×
NEW
64
        $instance = new static($id, $opts);
×
NEW
65
        $instance->refresh();
×
66

NEW
67
        return $instance;
×
68
    }
69
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2024 Coveralls, Inc