@payloadcms/plugin-stripe 3.0.0-canary.ef0a8d0 → 3.0.0-canary.f1f97ff

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/types.d.ts CHANGED
@@ -7,7 +7,7 @@ export type StripeWebhookHandler<T = any> = (args: {
7
7
  pluginConfig?: StripePluginConfig;
8
8
  req: PayloadRequest;
9
9
  stripe: Stripe;
10
- }) => void;
10
+ }) => Promise<void> | void;
11
11
  export type StripeWebhookHandlers = {
12
12
  [webhookName: string]: StripeWebhookHandler;
13
13
  };
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,IAAI,aAAa,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAC/E,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAA;AAEhC,MAAM,MAAM,oBAAoB,CAAC,CAAC,GAAG,GAAG,IAAI,CAAC,IAAI,EAAE;IACjD,MAAM,EAAE,aAAa,CAAA;IACrB,KAAK,EAAE,CAAC,CAAA;IACR,OAAO,EAAE,OAAO,CAAA;IAChB,YAAY,CAAC,EAAE,kBAAkB,CAAA;IACjC,GAAG,EAAE,cAAc,CAAA;IACnB,MAAM,EAAE,MAAM,CAAA;CACf,KAAK,IAAI,CAAA;AAEV,MAAM,MAAM,qBAAqB,GAAG;IAClC,CAAC,WAAW,EAAE,MAAM,GAAG,oBAAoB,CAAA;CAC5C,CAAA;AAED,MAAM,MAAM,eAAe,GAAG;IAC5B,SAAS,EAAE,MAAM,CAAA;IACjB,cAAc,EAAE,MAAM,CAAA;CACvB,CAAA;AAED,MAAM,MAAM,UAAU,GAAG;IACvB,UAAU,EAAE,MAAM,CAAA;IAClB,MAAM,EAAE,eAAe,EAAE,CAAA;IACzB,kBAAkB,EAAE,WAAW,GAAG,UAAU,CAAA;IAC5C,0BAA0B,EAAE,U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loadConfig, PayloadRequest } from 'payload'\nimport type Stripe from 'stripe'\n\nexport type StripeWebhookHandler<T = any> = (args: {\n config: PayloadConfig\n event: T\n payload: Payload\n pluginConfig?: StripePluginConfig\n req: PayloadRequest\n stripe: Stripe\n}) => void\n\nexport type StripeWebhookHandlers = {\n [webhookName: string]: StripeWebhookHandler\n}\n\nexport type FieldSyncConfig = {\n fieldPath: string\n stripeProperty: string\n}\n\nexport type SyncConfig = {\n collection: string\n fields: FieldSyncConfig[]\n stripeResourceType: 'customers' | 'products' // TODO: get this from Stripe types\n stripeResourceTypeSingular: 'customer' | 'product' // TODO: there must be a better way to do this\n}\n\nexport type StripePluginConfig = {\n isTestKey?: boolean\n logs?: boolean\n /** @default false */\n rest?: boolean\n stripeSecretKey: string\n stripeWebhooksEndpointSecret?: string\n sync?: SyncConfig[]\n webhooks?: StripeWebhookHandler | StripeWebhookHandlers\n}\n\nexport type SanitizedStripePluginConfig = {\n sync: SyncConfig[] // convert to required\n} & StripePluginConfig\n\nexport type StripeProxy = (args: {\n stripeArgs: any[]\n stripeMethod: string\n stripeSecretKey: string\n}) => Promise<{\n data?: any\n message?: string\n status: number\n}>\n"],"names":[],"mappings":"AA2CA,WAQE"}
1
+ {"version":3,"sources":["../src/types.ts"],"sourcesContent":["import type { Payload, Config as PayloadConfig, PayloadRequest } from 'payload'\nimport type Stripe from 'stripe'\n\nexport type StripeWebhookHandler<T = any> = (args: {\n config: PayloadConfig\n event: T\n payload: Payload\n pluginConfig?: StripePluginConfig\n req: PayloadRequest\n stripe: Stripe\n}) => Promise<void> | void\n\nexport type StripeWebhookHandlers = {\n [webhookName: string]: StripeWebhookHandler\n}\n\nexport type FieldSyncConfig = {\n fieldPath: string\n stripeProperty: string\n}\n\nexport type SyncConfig = {\n collection: string\n fields: FieldSyncConfig[]\n stripeResourceType: 'customers' | 'products' // TODO: get this from Stripe types\n stripeResourceTypeSingular: 'customer' | 'product' // TODO: there must be a better way to do this\n}\n\nexport type StripePluginConfig = {\n isTestKey?: boolean\n logs?: boolean\n /** @default false */\n rest?: boolean\n stripeSecretKey: string\n stripeWebhooksEndpointSecret?: string\n sync?: SyncConfig[]\n webhooks?: StripeWebhookHandler | StripeWebhookHandlers\n}\n\nexport type SanitizedStripePluginConfig = {\n sync: SyncConfig[] // convert to required\n} & StripePluginConfig\n\nexport type StripeProxy = (args: {\n stripeArgs: any[]\n stripeMethod: string\n stripeSecretKey: string\n}) => Promise<{\n data?: any\n message?: string\n status: number\n}>\n"],"names":[],"mappings":"AA2CA,WAQE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@payloadcms/plugin-stripe",
3
- "version": "3.0.0-canary.ef0a8d0",
3
+ "version": "3.0.0-canary.f1f97ff",
4
4
  "description": "Stripe plugin for Payload",
5
5
  "keywords": [
6
6
  "payload",
@@ -42,7 +42,7 @@
42
42
  "lodash.get": "^4.4.2",
43
43
  "stripe": "^10.2.0",
44
44
  "uuid": "10.0.0",
45
- "@payloadcms/ui": "3.0.0-canary.ef0a8d0"
45
+ "@payloadcms/ui": "3.0.0-canary.f1f97ff"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@types/express": "^4.17.9",
@@ -50,16 +50,16 @@
50
50
  "@types/react": "npm:types-react@19.0.0-rc.0",
51
51
  "@types/react-dom": "npm:types-react-dom@19.0.0-rc.0",
52
52
  "@types/uuid": "10.0.0",
53
+ "@payloadcms/next": "3.0.0-canary.f1f97ff",
53
54
  "@payloadcms/eslint-config": "3.0.0-beta.59",
54
- "@payloadcms/ui": "3.0.0-canary.ef0a8d0",
55
- "@payloadcms/next": "3.0.0-canary.ef0a8d0",
56
- "@payloadcms/translations": "3.0.0-canary.ef0a8d0",
57
- "payload": "3.0.0-canary.ef0a8d0"
55
+ "@payloadcms/translations": "3.0.0-canary.f1f97ff",
56
+ "@payloadcms/ui": "3.0.0-canary.f1f97ff",
57
+ "payload": "3.0.0-canary.f1f97ff"
58
58
  },
59
59
  "peerDependencies": {
60
- "@payloadcms/translations": "3.0.0-canary.ef0a8d0",
61
- "@payloadcms/ui": "3.0.0-canary.ef0a8d0",
62
- "payload": "3.0.0-canary.ef0a8d0"
60
+ "@payloadcms/translations": "3.0.0-canary.f1f97ff",
61
+ "@payloadcms/ui": "3.0.0-canary.f1f97ff",
62
+ "payload": "3.0.0-canary.f1f97ff"
63
63
  },
64
64
  "publishConfig": {
65
65
  "registry": "https://registry.npmjs.org/"