Skip to content

Commit

Permalink
Merge pull request #1349 from stripe/yejia/codegen-token
Browse files Browse the repository at this point in the history
Make token.go codegen-able
  • Loading branch information
yejia-stripe authored Oct 6, 2021
2 parents a0c8f03 + 39a2dd8 commit 10ed3fd
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions token.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
//
//
// File generated from our OpenAPI spec
//
//

package stripe

// TokenType is the list of allowed values for a token's type.
Expand Down Expand Up @@ -38,37 +44,33 @@ type TokenParams struct {
Card *CardParams `form:"card"`
Customer *string `form:"customer"`
CVCUpdate *TokenCVCUpdateParams `form:"cvc_update"`
Person *PersonParams `form:"person"`

// Email is an undocumented parameter used by Stripe Checkout
// It may be removed from the API without notice.
Email *string `form:"email"`
Email *string `form:"email"`
Person *PersonParams `form:"person"`
PII *PIIParams `form:"pii"`
}

PII *PIIParams `form:"pii"`
// PIIParams are parameters for personal identifiable information (PII).
type PIIParams struct {
Params `form:"*"`
IDNumber *string `form:"id_number"`
}

// Token is the resource representing a Stripe token.
// For more details see https://stripe.com/docs/api#tokens.
type Token struct {
APIResource

BankAccount *BankAccount `json:"bank_account"`
Card *Card `json:"card"`
ClientIP string `json:"client_ip"`
Created int64 `json:"created"`

// Email is an undocumented field but included for all tokens created
// with Stripe Checkout.
Email string `json:"email"`

Email string `json:"email"`
ID string `json:"id"`
Livemode bool `json:"livemode"`
Object string `json:"object"`
Type TokenType `json:"type"`
Used bool `json:"used"`
}

// PIIParams are parameters for personal identifiable information (PII).
type PIIParams struct {
Params `form:"*"`
IDNumber *string `form:"id_number"`
}

0 comments on commit 10ed3fd

Please sign in to comment.