@types/stripe
Advanced tools
Comparing version 0.0.31 to 0.0.32
// Type definitions for stripe | ||
// Project: https://stripe.com/ | ||
// Definitions by: Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/> | ||
// Definitions by: Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>, Adam Cmiel <https://github.com/adamcmiel> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
interface StripeStatic { | ||
applePay: StripeApplePay; | ||
setPublishableKey(key: string): void; | ||
@@ -37,7 +38,7 @@ validateCardNumber(cardNumber: string): boolean; | ||
created: number; | ||
currency: string; | ||
livemode: boolean; | ||
object: string; | ||
type: string; | ||
used: boolean; | ||
error: StripeError; | ||
error?: StripeError; | ||
} | ||
@@ -55,6 +56,4 @@ | ||
last4: string; | ||
type: string; | ||
exp_month: number; | ||
exp_year: number; | ||
fingerprint: string; | ||
country?: string; | ||
@@ -92,3 +91,2 @@ name?: string; | ||
bank_account: { | ||
id: string; | ||
country: string; | ||
@@ -105,3 +103,3 @@ bank_name: string; | ||
used: boolean; | ||
error: StripeError; | ||
error?: StripeError; | ||
} | ||
@@ -113,1 +111,63 @@ | ||
} | ||
interface StripeApplePay | ||
{ | ||
checkAvailability(resopnseHandler: (result: boolean) => void): void; | ||
buildSession(data: StripeApplePayPaymentRequest, | ||
onSuccessHandler: (result: StripeApplePaySessionResult, completion: ((value: any) => void)) => void, | ||
onErrorHanlder: (error: { message: string }) => void): any; | ||
} | ||
type StripeApplePayBillingContactField = 'postalAddress' | 'name'; | ||
type StripeApplePayShippingContactField = StripeApplePayBillingContactField | 'phone' | 'email'; | ||
type StripeApplePayShipping = 'shipping' | 'delivery' | 'storePickup' | 'servicePickup'; | ||
interface StripeApplePayPaymentRequest | ||
{ | ||
billingContact: StripeApplePayPaymentContact; | ||
countryCode: string; | ||
currencyCode: string; | ||
total: StripeApplePayLineItem; | ||
lineItems?: StripeApplePayLineItem[]; | ||
requiredBillingContactFields?: StripeApplePayBillingContactField[]; | ||
requiredShippingContactFields?: StripeApplePayShippingContactField[]; | ||
shippingContact?: StripeApplePayPaymentContact; | ||
shippingMethods?: StripeApplePayShippingMethod[]; | ||
shippingType?: StripeApplePayShipping[]; | ||
} | ||
// https://developer.apple.com/reference/applepayjs/1916082-applepay_js_data_types | ||
interface StripeApplePayLineItem | ||
{ | ||
type: 'pending' | 'final'; | ||
label: string; | ||
amount: number; | ||
} | ||
interface StripeApplePaySessionResult | ||
{ | ||
token: StripeTokenResponse; | ||
shippingContact?: StripeApplePayPaymentContact; | ||
shippingMethod?: StripeApplePayShippingMethod; | ||
} | ||
interface StripeApplePayShippingMethod | ||
{ | ||
label: string; | ||
detail: string; | ||
amount: number; | ||
identifier: string; | ||
} | ||
interface StripeApplePayPaymentContact | ||
{ | ||
emailAddress: string; | ||
phoneNumber: string; | ||
givenName: string; | ||
familyName: string; | ||
addressLines: string[]; | ||
locality: string; | ||
administrativeArea: string; | ||
postalCode: string; | ||
countryCode: string; | ||
} |
{ | ||
"name": "@types/stripe", | ||
"version": "0.0.31", | ||
"version": "0.0.32", | ||
"description": "TypeScript definitions for stripe", | ||
"license": "MIT", | ||
"author": "Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>", | ||
"author": "Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>, Adam Cmiel <https://github.com/adamcmiel>", | ||
"main": "", | ||
@@ -14,4 +14,5 @@ "repository": { | ||
"dependencies": {}, | ||
"peerDependencies": {}, | ||
"typings": "index.d.ts", | ||
"typesPublisherContentHash": "8da13db306e7d00f3f4cafe13fab87ad686bc78d9fb4e7da27989499348cd335" | ||
"typesPublisherContentHash": "519bbf101c4104eebab413b2e96a6b8edf8aec3ae512391e1291d475b7ff5a4a" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
Additional Details | ||
* Last updated: Mon, 19 Sep 2016 17:28:59 GMT | ||
* Last updated: Tue, 08 Nov 2016 14:41:16 GMT | ||
* File structure: Mixed | ||
@@ -19,2 +19,2 @@ * Library Dependencies: none | ||
# Credits | ||
These definitions were written by Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>. | ||
These definitions were written by Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>, Adam Cmiel <https://github.com/adamcmiel>. |
{ | ||
"authors": "Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>", | ||
"authors": "Andy Hawkins <https://github.com/a904guy/,http://a904guy.com>, Eric J. Smith <https://github.com/ejsmith/>, Amrit Kahlon <https://github.com/amritk/>, Adam Cmiel <https://github.com/adamcmiel>", | ||
"definitionFilename": "index.d.ts", | ||
"libraryDependencies": [], | ||
"moduleDependencies": [], | ||
"libraryMajorVersion": "0", | ||
"libraryMinorVersion": "0", | ||
"libraryMajorVersion": 0, | ||
"libraryMinorVersion": 0, | ||
"libraryName": "stripe", | ||
@@ -24,3 +24,3 @@ "typingsPackageName": "stripe", | ||
"hasPackageJson": false, | ||
"contentHash": "8da13db306e7d00f3f4cafe13fab87ad686bc78d9fb4e7da27989499348cd335" | ||
"contentHash": "519bbf101c4104eebab413b2e96a6b8edf8aec3ae512391e1291d475b7ff5a4a" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7285
176