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

stripe / stripe-java / #16380

30 Aug 2024 07:54PM UTC coverage: 12.882% (-0.004%) from 12.886%
#16380

push

github

web-flow
Merge from master after the changes to not pass api_mode from individual methods (#1857)

* Generate SDK for OpenAPI spec version 1230 (#1856)

* Bump version to 26.9.0

* No need for APIMode to be passed around from individual API methods (#1855)

* Generated code

* Update the code around raw request

* Update the v2 tests to use v2 path

16 of 23 new or added lines in 7 files covered. (69.57%)

706 existing lines in 213 files now uncovered.

18468 of 143365 relevant lines covered (12.88%)

0.13 hits per line

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

0.0
/src/main/java/com/stripe/model/capital/FinancingSummary.java
1
// File generated from our OpenAPI spec
2
package com.stripe.model.capital;
3

4
import com.google.gson.annotations.SerializedName;
5
import com.stripe.exception.StripeException;
6
import com.stripe.model.StripeObject;
7
import com.stripe.net.ApiRequest;
8
import com.stripe.net.ApiRequestParams;
9
import com.stripe.net.ApiResource;
10
import com.stripe.net.BaseAddress;
11
import com.stripe.net.RequestOptions;
12
import com.stripe.net.StripeResponseGetter;
13
import com.stripe.param.capital.FinancingSummaryRetrieveParams;
14
import java.math.BigDecimal;
15
import java.util.Map;
16
import lombok.EqualsAndHashCode;
17
import lombok.Getter;
18
import lombok.Setter;
19

20
/**
21
 * A financing object describes an account's current financing state. Used by Connect platforms to
22
 * read the state of Capital offered to their connected accounts.
23
 */
24
@Getter
25
@Setter
26
@EqualsAndHashCode(callSuper = false)
27
public class FinancingSummary extends ApiResource {
×
28
  /**
29
   * Additional information about the financing summary. Describes currency, advance amount, fee
30
   * amount, withhold rate, remaining amount, paid amount, current repayment interval, repayment
31
   * start date, and advance payout date.
32
   */
33
  @SerializedName("details")
34
  Details details;
35

36
  /** The Financing Offer ID this Financing Summary corresponds to. */
37
  @SerializedName("financing_offer")
38
  String financingOffer;
39

40
  /**
41
   * The object type: financing_summary
42
   *
43
   * <p>Equal to {@code capital.financing_summary}.
44
   */
45
  @SerializedName("object")
46
  String object;
47

48
  /**
49
   * Status of the Connected Account's financing. <a
50
   * href="https://stripe.com/docs/api/capital/financing_summary">/v1/capital/financing_summary</a>
51
   * will only return {@code details} for {@code paid_out} financing.
52
   *
53
   * <p>One of {@code accepted}, {@code delivered}, or {@code none}.
54
   */
55
  @SerializedName("status")
56
  String status;
57

58
  /** Retrieve the financing state for the account that was authenticated in the request. */
59
  public static FinancingSummary retrieve() throws StripeException {
60
    return retrieve((Map<String, Object>) null, (RequestOptions) null);
×
61
  }
62

63
  /** Retrieve the financing state for the account that was authenticated in the request. */
64
  public static FinancingSummary retrieve(RequestOptions options) throws StripeException {
65
    return retrieve((Map<String, Object>) null, options);
×
66
  }
67

68
  /** Retrieve the financing state for the account that was authenticated in the request. */
69
  public static FinancingSummary retrieve(Map<String, Object> params, RequestOptions options)
70
      throws StripeException {
71
    String path = "/v1/capital/financing_summary";
×
72
    ApiRequest request =
×
73
        new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, params, options);
UNCOV
74
    return getGlobalResponseGetter().request(request, FinancingSummary.class);
×
75
  }
76

77
  /** Retrieve the financing state for the account that was authenticated in the request. */
78
  public static FinancingSummary retrieve(
79
      FinancingSummaryRetrieveParams params, RequestOptions options) throws StripeException {
80
    String path = "/v1/capital/financing_summary";
×
81
    ApiResource.checkNullTypedParams(path, params);
×
82
    ApiRequest request =
×
83
        new ApiRequest(
84
            BaseAddress.API,
85
            ApiResource.RequestMethod.GET,
86
            path,
87
            ApiRequestParams.paramsToMap(params),
×
88
            options);
UNCOV
89
    return getGlobalResponseGetter().request(request, FinancingSummary.class);
×
90
  }
91

92
  @Getter
93
  @Setter
94
  @EqualsAndHashCode(callSuper = false)
95
  public static class Details extends StripeObject {
×
96
    /** Amount of financing offered, in minor units. */
97
    @SerializedName("advance_amount")
98
    Long advanceAmount;
99

100
    /**
101
     * The time at which the funds were paid out to the connected account's Stripe balance. Given in
102
     * milliseconds since unix epoch.
103
     */
104
    @SerializedName("advance_paid_out_at")
105
    Long advancePaidOutAt;
106

107
    /** Currency that the financing offer is transacted in. For example, {@code usd}. */
108
    @SerializedName("currency")
109
    String currency;
110

111
    /** The chronologically current repayment interval for the financing offer. */
112
    @SerializedName("current_repayment_interval")
113
    CurrentRepaymentInterval currentRepaymentInterval;
114

115
    /** Fixed fee amount, in minor units. */
116
    @SerializedName("fee_amount")
117
    Long feeAmount;
118

119
    /** The amount the Connected account has paid toward the financing debt so far. */
120
    @SerializedName("paid_amount")
121
    Long paidAmount;
122

123
    /** The balance remaining to be paid on the financing, in minor units. */
124
    @SerializedName("remaining_amount")
125
    Long remainingAmount;
126

127
    /**
128
     * The time at which Capital will begin withholding from payments. Given in seconds since unix
129
     * epoch.
130
     */
131
    @SerializedName("repayments_begin_at")
132
    Long repaymentsBeginAt;
133

134
    /** Per-transaction rate at which Stripe will withhold funds to repay the financing. */
135
    @SerializedName("withhold_rate")
136
    BigDecimal withholdRate;
137

138
    /** The current repayment interval for the Connected account. */
139
    @Getter
140
    @Setter
141
    @EqualsAndHashCode(callSuper = false)
142
    public static class CurrentRepaymentInterval extends StripeObject {
×
143
      /**
144
       * The time at which the minimum payment amount will be due. If not met through withholding,
145
       * the Connected account's linked bank account or account balance will be debited. Given in
146
       * seconds since unix epoch.
147
       */
148
      @SerializedName("due_at")
149
      Long dueAt;
150

151
      /** The amount that has already been paid in the current repayment interval. */
152
      @SerializedName("paid_amount")
153
      Long paidAmount;
154

155
      /** The amount that is yet to be paid in the current repayment interval. */
156
      @SerializedName("remaining_amount")
157
      Long remainingAmount;
158
    }
159
  }
160

161
  @Override
162
  public void setResponseGetter(StripeResponseGetter responseGetter) {
163
    super.setResponseGetter(responseGetter);
×
164
    trySetResponseGetter(details, responseGetter);
×
165
  }
×
166
}
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

© 2026 Coveralls, Inc