-
Notifications
You must be signed in to change notification settings - Fork 368
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Issuing APIs/resources #557
Conversation
objectMap.put("issuing.authorization", com.stripe.model.issuing.Authorization.class); | ||
objectMap.put("issuing.card", com.stripe.model.issuing.Card.class); | ||
objectMap.put("issuing.cardholder", com.stripe.model.issuing.Cardholder.class); | ||
objectMap.put("issuing.card_details", com.stripe.model.issuing.CardDetails.class); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At the risk of sounding like a broken record, CardDetails
after Card
:)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some linting errors detected by Checkstyle, but otherwise lgtm.
import com.stripe.model.BalanceTransaction; | ||
import com.stripe.model.ExpandableField; | ||
import com.stripe.model.MetadataStore; | ||
import com.stripe.model.HasId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be before MetadataStore
import com.stripe.exception.InvalidRequestException; | ||
import com.stripe.model.Address; | ||
import com.stripe.model.MetadataStore; | ||
import com.stripe.model.HasId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here.
import com.stripe.exception.InvalidRequestException; | ||
import com.stripe.model.Address; | ||
import com.stripe.model.MetadataStore; | ||
import com.stripe.model.HasId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And here.
import com.stripe.exception.InvalidRequestException; | ||
import com.stripe.model.ExpandableField; | ||
import com.stripe.model.MetadataStore; | ||
import com.stripe.model.HasId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And here.
import com.stripe.model.BalanceTransaction; | ||
import com.stripe.model.ExpandableField; | ||
import com.stripe.model.MetadataStore; | ||
import com.stripe.model.HasId; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And here.
String city; | ||
String country; | ||
String name; | ||
String network_id; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be networkId
.
String country; | ||
String name; | ||
String network_id; | ||
String postal_code; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be postalCode
.
.replaceAll("(.)([A-Z][a-z]+)", "$1_$2") | ||
.replaceAll("([a-z0-9])([A-Z])", "$1_$2") | ||
.toLowerCase(); | ||
|
||
// Issuing resources are in their own package. Until we can support adding OBJECT_NAME | ||
// to all classes, we use this dirty trick to properly format the API endpoints | ||
if(clazz.getName().contains("com.stripe.model.issuing.")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need a space after if
.
0e32a48
to
37592f6
Compare
@ob-stripe thank you for catching those! Fixed all of them, PTAL |
Released as 5.52.0. |
r? @ob-stripe
cc @stripe/api-libraries