@whop/sdk 0.0.1-canary.0
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/CHANGELOG.md +108 -0
- package/LICENSE +201 -0
- package/README.md +399 -0
- package/api-promise.d.mts +2 -0
- package/api-promise.d.mts.map +1 -0
- package/api-promise.d.ts +2 -0
- package/api-promise.d.ts.map +1 -0
- package/api-promise.js +6 -0
- package/api-promise.js.map +1 -0
- package/api-promise.mjs +2 -0
- package/api-promise.mjs.map +1 -0
- package/client.d.mts +316 -0
- package/client.d.mts.map +1 -0
- package/client.d.ts +316 -0
- package/client.d.ts.map +1 -0
- package/client.js +536 -0
- package/client.js.map +1 -0
- package/client.mjs +532 -0
- package/client.mjs.map +1 -0
- package/core/api-promise.d.mts +46 -0
- package/core/api-promise.d.mts.map +1 -0
- package/core/api-promise.d.ts +46 -0
- package/core/api-promise.d.ts.map +1 -0
- package/core/api-promise.js +74 -0
- package/core/api-promise.js.map +1 -0
- package/core/api-promise.mjs +70 -0
- package/core/api-promise.mjs.map +1 -0
- package/core/error.d.mts +46 -0
- package/core/error.d.mts.map +1 -0
- package/core/error.d.ts +46 -0
- package/core/error.d.ts.map +1 -0
- package/core/error.js +113 -0
- package/core/error.js.map +1 -0
- package/core/error.mjs +97 -0
- package/core/error.mjs.map +1 -0
- package/core/pagination.d.mts +58 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +58 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +101 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +95 -0
- package/core/pagination.mjs.map +1 -0
- package/core/resource.d.mts +6 -0
- package/core/resource.d.mts.map +1 -0
- package/core/resource.d.ts +6 -0
- package/core/resource.d.ts.map +1 -0
- package/core/resource.js +11 -0
- package/core/resource.js.map +1 -0
- package/core/resource.mjs +7 -0
- package/core/resource.mjs.map +1 -0
- package/core/uploads.d.mts +3 -0
- package/core/uploads.d.mts.map +1 -0
- package/core/uploads.d.ts +3 -0
- package/core/uploads.d.ts.map +1 -0
- package/core/uploads.js +6 -0
- package/core/uploads.js.map +1 -0
- package/core/uploads.mjs +2 -0
- package/core/uploads.mjs.map +1 -0
- package/error.d.mts +2 -0
- package/error.d.mts.map +1 -0
- package/error.d.ts +2 -0
- package/error.d.ts.map +1 -0
- package/error.js +6 -0
- package/error.js.map +1 -0
- package/error.mjs +2 -0
- package/error.mjs.map +1 -0
- package/index.d.mts +7 -0
- package/index.d.mts.map +1 -0
- package/index.d.ts +7 -0
- package/index.d.ts.map +1 -0
- package/index.js +32 -0
- package/index.js.map +1 -0
- package/index.mjs +8 -0
- package/index.mjs.map +1 -0
- package/internal/builtin-types.d.mts +73 -0
- package/internal/builtin-types.d.mts.map +1 -0
- package/internal/builtin-types.d.ts +73 -0
- package/internal/builtin-types.d.ts.map +1 -0
- package/internal/builtin-types.js +4 -0
- package/internal/builtin-types.js.map +1 -0
- package/internal/builtin-types.mjs +3 -0
- package/internal/builtin-types.mjs.map +1 -0
- package/internal/detect-platform.d.mts +15 -0
- package/internal/detect-platform.d.mts.map +1 -0
- package/internal/detect-platform.d.ts +15 -0
- package/internal/detect-platform.d.ts.map +1 -0
- package/internal/detect-platform.js +162 -0
- package/internal/detect-platform.js.map +1 -0
- package/internal/detect-platform.mjs +157 -0
- package/internal/detect-platform.mjs.map +1 -0
- package/internal/errors.d.mts +3 -0
- package/internal/errors.d.mts.map +1 -0
- package/internal/errors.d.ts +3 -0
- package/internal/errors.d.ts.map +1 -0
- package/internal/errors.js +41 -0
- package/internal/errors.js.map +1 -0
- package/internal/errors.mjs +36 -0
- package/internal/errors.mjs.map +1 -0
- package/internal/headers.d.mts +20 -0
- package/internal/headers.d.mts.map +1 -0
- package/internal/headers.d.ts +20 -0
- package/internal/headers.d.ts.map +1 -0
- package/internal/headers.js +79 -0
- package/internal/headers.js.map +1 -0
- package/internal/headers.mjs +74 -0
- package/internal/headers.mjs.map +1 -0
- package/internal/parse.d.mts +12 -0
- package/internal/parse.d.mts.map +1 -0
- package/internal/parse.d.ts +12 -0
- package/internal/parse.d.ts.map +1 -0
- package/internal/parse.js +35 -0
- package/internal/parse.js.map +1 -0
- package/internal/parse.mjs +32 -0
- package/internal/parse.mjs.map +1 -0
- package/internal/qs/formats.d.mts +7 -0
- package/internal/qs/formats.d.mts.map +1 -0
- package/internal/qs/formats.d.ts +7 -0
- package/internal/qs/formats.d.ts.map +1 -0
- package/internal/qs/formats.js +13 -0
- package/internal/qs/formats.js.map +1 -0
- package/internal/qs/formats.mjs +9 -0
- package/internal/qs/formats.mjs.map +1 -0
- package/internal/qs/index.d.mts +10 -0
- package/internal/qs/index.d.mts.map +1 -0
- package/internal/qs/index.d.ts +10 -0
- package/internal/qs/index.d.ts.map +1 -0
- package/internal/qs/index.js +14 -0
- package/internal/qs/index.js.map +1 -0
- package/internal/qs/index.mjs +10 -0
- package/internal/qs/index.mjs.map +1 -0
- package/internal/qs/stringify.d.mts +3 -0
- package/internal/qs/stringify.d.mts.map +1 -0
- package/internal/qs/stringify.d.ts +3 -0
- package/internal/qs/stringify.d.ts.map +1 -0
- package/internal/qs/stringify.js +277 -0
- package/internal/qs/stringify.js.map +1 -0
- package/internal/qs/stringify.mjs +274 -0
- package/internal/qs/stringify.mjs.map +1 -0
- package/internal/qs/types.d.mts +57 -0
- package/internal/qs/types.d.mts.map +1 -0
- package/internal/qs/types.d.ts +57 -0
- package/internal/qs/types.d.ts.map +1 -0
- package/internal/qs/types.js +3 -0
- package/internal/qs/types.js.map +1 -0
- package/internal/qs/types.mjs +2 -0
- package/internal/qs/types.mjs.map +1 -0
- package/internal/qs/utils.d.mts +15 -0
- package/internal/qs/utils.d.mts.map +1 -0
- package/internal/qs/utils.d.ts +15 -0
- package/internal/qs/utils.d.ts.map +1 -0
- package/internal/qs/utils.js +230 -0
- package/internal/qs/utils.js.map +1 -0
- package/internal/qs/utils.mjs +217 -0
- package/internal/qs/utils.mjs.map +1 -0
- package/internal/request-options.d.mts +75 -0
- package/internal/request-options.d.mts.map +1 -0
- package/internal/request-options.d.ts +75 -0
- package/internal/request-options.d.ts.map +1 -0
- package/internal/request-options.js +14 -0
- package/internal/request-options.js.map +1 -0
- package/internal/request-options.mjs +10 -0
- package/internal/request-options.mjs.map +1 -0
- package/internal/shim-types.d.mts +17 -0
- package/internal/shim-types.d.mts.map +1 -0
- package/internal/shim-types.d.ts +17 -0
- package/internal/shim-types.d.ts.map +1 -0
- package/internal/shim-types.js +4 -0
- package/internal/shim-types.js.map +1 -0
- package/internal/shim-types.mjs +3 -0
- package/internal/shim-types.mjs.map +1 -0
- package/internal/shims.d.mts +20 -0
- package/internal/shims.d.mts.map +1 -0
- package/internal/shims.d.ts +20 -0
- package/internal/shims.d.ts.map +1 -0
- package/internal/shims.js +92 -0
- package/internal/shims.js.map +1 -0
- package/internal/shims.mjs +85 -0
- package/internal/shims.mjs.map +1 -0
- package/internal/to-file.d.mts +45 -0
- package/internal/to-file.d.mts.map +1 -0
- package/internal/to-file.d.ts +45 -0
- package/internal/to-file.d.ts.map +1 -0
- package/internal/to-file.js +91 -0
- package/internal/to-file.js.map +1 -0
- package/internal/to-file.mjs +88 -0
- package/internal/to-file.mjs.map +1 -0
- package/internal/tslib.js +81 -0
- package/internal/tslib.mjs +17 -0
- package/internal/types.d.mts +69 -0
- package/internal/types.d.mts.map +1 -0
- package/internal/types.d.ts +69 -0
- package/internal/types.d.ts.map +1 -0
- package/internal/types.js +4 -0
- package/internal/types.js.map +1 -0
- package/internal/types.mjs +3 -0
- package/internal/types.mjs.map +1 -0
- package/internal/uploads.d.mts +42 -0
- package/internal/uploads.d.mts.map +1 -0
- package/internal/uploads.d.ts +42 -0
- package/internal/uploads.d.ts.map +1 -0
- package/internal/uploads.js +141 -0
- package/internal/uploads.js.map +1 -0
- package/internal/uploads.mjs +131 -0
- package/internal/uploads.mjs.map +1 -0
- package/internal/utils/base64.d.mts +3 -0
- package/internal/utils/base64.d.mts.map +1 -0
- package/internal/utils/base64.d.ts +3 -0
- package/internal/utils/base64.d.ts.map +1 -0
- package/internal/utils/base64.js +38 -0
- package/internal/utils/base64.js.map +1 -0
- package/internal/utils/base64.mjs +33 -0
- package/internal/utils/base64.mjs.map +1 -0
- package/internal/utils/bytes.d.mts +4 -0
- package/internal/utils/bytes.d.mts.map +1 -0
- package/internal/utils/bytes.d.ts +4 -0
- package/internal/utils/bytes.d.ts.map +1 -0
- package/internal/utils/bytes.js +31 -0
- package/internal/utils/bytes.js.map +1 -0
- package/internal/utils/bytes.mjs +26 -0
- package/internal/utils/bytes.mjs.map +1 -0
- package/internal/utils/env.d.mts +9 -0
- package/internal/utils/env.d.mts.map +1 -0
- package/internal/utils/env.d.ts +9 -0
- package/internal/utils/env.d.ts.map +1 -0
- package/internal/utils/env.js +22 -0
- package/internal/utils/env.js.map +1 -0
- package/internal/utils/env.mjs +18 -0
- package/internal/utils/env.mjs.map +1 -0
- package/internal/utils/log.d.mts +37 -0
- package/internal/utils/log.d.mts.map +1 -0
- package/internal/utils/log.d.ts +37 -0
- package/internal/utils/log.d.ts.map +1 -0
- package/internal/utils/log.js +85 -0
- package/internal/utils/log.js.map +1 -0
- package/internal/utils/log.mjs +79 -0
- package/internal/utils/log.mjs.map +1 -0
- package/internal/utils/path.d.mts +15 -0
- package/internal/utils/path.d.mts.map +1 -0
- package/internal/utils/path.d.ts +15 -0
- package/internal/utils/path.d.ts.map +1 -0
- package/internal/utils/path.js +79 -0
- package/internal/utils/path.js.map +1 -0
- package/internal/utils/path.mjs +74 -0
- package/internal/utils/path.mjs.map +1 -0
- package/internal/utils/sleep.d.mts +2 -0
- package/internal/utils/sleep.d.mts.map +1 -0
- package/internal/utils/sleep.d.ts +2 -0
- package/internal/utils/sleep.d.ts.map +1 -0
- package/internal/utils/sleep.js +7 -0
- package/internal/utils/sleep.js.map +1 -0
- package/internal/utils/sleep.mjs +3 -0
- package/internal/utils/sleep.mjs.map +1 -0
- package/internal/utils/uuid.d.mts +5 -0
- package/internal/utils/uuid.d.mts.map +1 -0
- package/internal/utils/uuid.d.ts +5 -0
- package/internal/utils/uuid.d.ts.map +1 -0
- package/internal/utils/uuid.js +19 -0
- package/internal/utils/uuid.js.map +1 -0
- package/internal/utils/uuid.mjs +15 -0
- package/internal/utils/uuid.mjs.map +1 -0
- package/internal/utils/values.d.mts +18 -0
- package/internal/utils/values.d.mts.map +1 -0
- package/internal/utils/values.d.ts +18 -0
- package/internal/utils/values.d.ts.map +1 -0
- package/internal/utils/values.js +112 -0
- package/internal/utils/values.js.map +1 -0
- package/internal/utils/values.mjs +94 -0
- package/internal/utils/values.mjs.map +1 -0
- package/internal/utils.d.mts +7 -0
- package/internal/utils.d.mts.map +1 -0
- package/internal/utils.d.ts +7 -0
- package/internal/utils.d.ts.map +1 -0
- package/internal/utils.js +11 -0
- package/internal/utils.js.map +1 -0
- package/internal/utils.mjs +8 -0
- package/internal/utils.mjs.map +1 -0
- package/lib/verify-user-token.d.mts +21 -0
- package/lib/verify-user-token.d.mts.map +1 -0
- package/lib/verify-user-token.d.ts +21 -0
- package/lib/verify-user-token.d.ts.map +1 -0
- package/lib/verify-user-token.js +69 -0
- package/lib/verify-user-token.js.map +1 -0
- package/lib/verify-user-token.mjs +64 -0
- package/lib/verify-user-token.mjs.map +1 -0
- package/package.json +160 -0
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +2 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +2 -0
- package/pagination.mjs.map +1 -0
- package/resource.d.mts +2 -0
- package/resource.d.mts.map +1 -0
- package/resource.d.ts +2 -0
- package/resource.d.ts.map +1 -0
- package/resource.js +6 -0
- package/resource.js.map +1 -0
- package/resource.mjs +2 -0
- package/resource.mjs.map +1 -0
- package/resources/app-builds.d.mts +196 -0
- package/resources/app-builds.d.mts.map +1 -0
- package/resources/app-builds.d.ts +196 -0
- package/resources/app-builds.d.ts.map +1 -0
- package/resources/app-builds.js +84 -0
- package/resources/app-builds.js.map +1 -0
- package/resources/app-builds.mjs +80 -0
- package/resources/app-builds.mjs.map +1 -0
- package/resources/apps.d.mts +279 -0
- package/resources/apps.d.mts.map +1 -0
- package/resources/apps.d.ts +279 -0
- package/resources/apps.d.ts.map +1 -0
- package/resources/apps.js +77 -0
- package/resources/apps.js.map +1 -0
- package/resources/apps.mjs +73 -0
- package/resources/apps.mjs.map +1 -0
- package/resources/authorized-users.d.mts +136 -0
- package/resources/authorized-users.d.mts.map +1 -0
- package/resources/authorized-users.d.ts +136 -0
- package/resources/authorized-users.d.ts.map +1 -0
- package/resources/authorized-users.js +36 -0
- package/resources/authorized-users.js.map +1 -0
- package/resources/authorized-users.mjs +32 -0
- package/resources/authorized-users.mjs.map +1 -0
- package/resources/chat-channels.d.mts +158 -0
- package/resources/chat-channels.d.mts.map +1 -0
- package/resources/chat-channels.d.ts +158 -0
- package/resources/chat-channels.d.ts.map +1 -0
- package/resources/chat-channels.js +66 -0
- package/resources/chat-channels.js.map +1 -0
- package/resources/chat-channels.mjs +62 -0
- package/resources/chat-channels.mjs.map +1 -0
- package/resources/checkout-configurations.d.mts +319 -0
- package/resources/checkout-configurations.d.mts.map +1 -0
- package/resources/checkout-configurations.d.ts +319 -0
- package/resources/checkout-configurations.d.ts.map +1 -0
- package/resources/checkout-configurations.js +66 -0
- package/resources/checkout-configurations.js.map +1 -0
- package/resources/checkout-configurations.mjs +62 -0
- package/resources/checkout-configurations.mjs.map +1 -0
- package/resources/companies.d.mts +15 -0
- package/resources/companies.d.mts.map +1 -0
- package/resources/companies.d.ts +15 -0
- package/resources/companies.d.ts.map +1 -0
- package/resources/companies.js +20 -0
- package/resources/companies.js.map +1 -0
- package/resources/companies.mjs +16 -0
- package/resources/companies.mjs.map +1 -0
- package/resources/course-lesson-interactions.d.mts +61 -0
- package/resources/course-lesson-interactions.d.mts.map +1 -0
- package/resources/course-lesson-interactions.d.ts +61 -0
- package/resources/course-lesson-interactions.d.ts.map +1 -0
- package/resources/course-lesson-interactions.js +33 -0
- package/resources/course-lesson-interactions.js.map +1 -0
- package/resources/course-lesson-interactions.mjs +29 -0
- package/resources/course-lesson-interactions.mjs.map +1 -0
- package/resources/entries.d.mts +169 -0
- package/resources/entries.d.mts.map +1 -0
- package/resources/entries.d.ts +169 -0
- package/resources/entries.d.ts.map +1 -0
- package/resources/entries.js +55 -0
- package/resources/entries.js.map +1 -0
- package/resources/entries.mjs +51 -0
- package/resources/entries.mjs.map +1 -0
- package/resources/experiences.d.mts +277 -0
- package/resources/experiences.d.mts.map +1 -0
- package/resources/experiences.d.ts +277 -0
- package/resources/experiences.d.ts.map +1 -0
- package/resources/experiences.js +128 -0
- package/resources/experiences.js.map +1 -0
- package/resources/experiences.mjs +124 -0
- package/resources/experiences.mjs.map +1 -0
- package/resources/forum-posts.d.mts +242 -0
- package/resources/forum-posts.d.mts.map +1 -0
- package/resources/forum-posts.d.ts +242 -0
- package/resources/forum-posts.d.ts.map +1 -0
- package/resources/forum-posts.js +63 -0
- package/resources/forum-posts.js.map +1 -0
- package/resources/forum-posts.mjs +59 -0
- package/resources/forum-posts.mjs.map +1 -0
- package/resources/index.d.mts +25 -0
- package/resources/index.d.mts.map +1 -0
- package/resources/index.d.ts +25 -0
- package/resources/index.d.ts.map +1 -0
- package/resources/index.js +53 -0
- package/resources/index.js.map +1 -0
- package/resources/index.mjs +26 -0
- package/resources/index.mjs.map +1 -0
- package/resources/invoices.d.mts +296 -0
- package/resources/invoices.d.mts.map +1 -0
- package/resources/invoices.d.ts +296 -0
- package/resources/invoices.d.ts.map +1 -0
- package/resources/invoices.js +88 -0
- package/resources/invoices.js.map +1 -0
- package/resources/invoices.mjs +84 -0
- package/resources/invoices.mjs.map +1 -0
- package/resources/ledger-accounts.d.mts +116 -0
- package/resources/ledger-accounts.d.mts.map +1 -0
- package/resources/ledger-accounts.d.ts +116 -0
- package/resources/ledger-accounts.d.ts.map +1 -0
- package/resources/ledger-accounts.js +20 -0
- package/resources/ledger-accounts.js.map +1 -0
- package/resources/ledger-accounts.mjs +16 -0
- package/resources/ledger-accounts.mjs.map +1 -0
- package/resources/memberships.d.mts +287 -0
- package/resources/memberships.d.mts.map +1 -0
- package/resources/memberships.d.ts +287 -0
- package/resources/memberships.d.ts.map +1 -0
- package/resources/memberships.js +76 -0
- package/resources/memberships.js.map +1 -0
- package/resources/memberships.mjs +72 -0
- package/resources/memberships.mjs.map +1 -0
- package/resources/messages.d.mts +245 -0
- package/resources/messages.d.mts.map +1 -0
- package/resources/messages.d.ts +245 -0
- package/resources/messages.d.ts.map +1 -0
- package/resources/messages.js +41 -0
- package/resources/messages.js.map +1 -0
- package/resources/messages.mjs +37 -0
- package/resources/messages.mjs.map +1 -0
- package/resources/payments.d.mts +472 -0
- package/resources/payments.d.mts.map +1 -0
- package/resources/payments.d.ts +472 -0
- package/resources/payments.d.ts.map +1 -0
- package/resources/payments.js +129 -0
- package/resources/payments.js.map +1 -0
- package/resources/payments.mjs +125 -0
- package/resources/payments.mjs.map +1 -0
- package/resources/plans.d.mts +479 -0
- package/resources/plans.d.mts.map +1 -0
- package/resources/plans.d.ts +479 -0
- package/resources/plans.d.ts.map +1 -0
- package/resources/plans.js +104 -0
- package/resources/plans.js.map +1 -0
- package/resources/plans.mjs +100 -0
- package/resources/plans.mjs.map +1 -0
- package/resources/products.d.mts +425 -0
- package/resources/products.d.mts.map +1 -0
- package/resources/products.d.ts +425 -0
- package/resources/products.d.ts.map +1 -0
- package/resources/products.js +102 -0
- package/resources/products.js.map +1 -0
- package/resources/products.mjs +98 -0
- package/resources/products.mjs.map +1 -0
- package/resources/reactions.d.mts +105 -0
- package/resources/reactions.d.mts.map +1 -0
- package/resources/reactions.d.ts +105 -0
- package/resources/reactions.d.ts.map +1 -0
- package/resources/reactions.js +41 -0
- package/resources/reactions.js.map +1 -0
- package/resources/reactions.mjs +37 -0
- package/resources/reactions.mjs.map +1 -0
- package/resources/shared.d.mts +2309 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +2309 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/resources/shared.mjs +3 -0
- package/resources/shared.mjs.map +1 -0
- package/resources/shipments.d.mts +159 -0
- package/resources/shipments.d.mts.map +1 -0
- package/resources/shipments.d.ts +159 -0
- package/resources/shipments.d.ts.map +1 -0
- package/resources/shipments.js +68 -0
- package/resources/shipments.js.map +1 -0
- package/resources/shipments.mjs +64 -0
- package/resources/shipments.mjs.map +1 -0
- package/resources/support-channels.d.mts +151 -0
- package/resources/support-channels.d.mts.map +1 -0
- package/resources/support-channels.d.ts +151 -0
- package/resources/support-channels.d.ts.map +1 -0
- package/resources/support-channels.js +69 -0
- package/resources/support-channels.js.map +1 -0
- package/resources/support-channels.mjs +65 -0
- package/resources/support-channels.mjs.map +1 -0
- package/resources/transfers.d.mts +158 -0
- package/resources/transfers.d.mts.map +1 -0
- package/resources/transfers.d.ts +158 -0
- package/resources/transfers.d.ts.map +1 -0
- package/resources/transfers.js +66 -0
- package/resources/transfers.js.map +1 -0
- package/resources/transfers.mjs +62 -0
- package/resources/transfers.mjs.map +1 -0
- package/resources/users.d.mts +58 -0
- package/resources/users.d.mts.map +1 -0
- package/resources/users.d.ts +58 -0
- package/resources/users.d.ts.map +1 -0
- package/resources/users.js +23 -0
- package/resources/users.js.map +1 -0
- package/resources/users.mjs +19 -0
- package/resources/users.mjs.map +1 -0
- package/resources/webhooks.d.mts +101 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +101 -0
- package/resources/webhooks.d.ts.map +1 -0
- package/resources/webhooks.js +20 -0
- package/resources/webhooks.js.map +1 -0
- package/resources/webhooks.mjs +16 -0
- package/resources/webhooks.mjs.map +1 -0
- package/resources.d.mts +2 -0
- package/resources.d.mts.map +1 -0
- package/resources.d.ts +2 -0
- package/resources.d.ts.map +1 -0
- package/resources.js +5 -0
- package/resources.js.map +1 -0
- package/resources.mjs +2 -0
- package/resources.mjs.map +1 -0
- package/src/api-promise.ts +2 -0
- package/src/client.ts +1197 -0
- package/src/core/README.md +3 -0
- package/src/core/api-promise.ts +92 -0
- package/src/core/error.ts +130 -0
- package/src/core/pagination.ts +161 -0
- package/src/core/resource.ts +11 -0
- package/src/core/uploads.ts +2 -0
- package/src/error.ts +2 -0
- package/src/index.ts +23 -0
- package/src/internal/README.md +3 -0
- package/src/internal/builtin-types.ts +93 -0
- package/src/internal/detect-platform.ts +196 -0
- package/src/internal/errors.ts +33 -0
- package/src/internal/headers.ts +97 -0
- package/src/internal/parse.ts +50 -0
- package/src/internal/qs/LICENSE.md +13 -0
- package/src/internal/qs/README.md +3 -0
- package/src/internal/qs/formats.ts +10 -0
- package/src/internal/qs/index.ts +13 -0
- package/src/internal/qs/stringify.ts +385 -0
- package/src/internal/qs/types.ts +71 -0
- package/src/internal/qs/utils.ts +265 -0
- package/src/internal/request-options.ts +91 -0
- package/src/internal/shim-types.ts +26 -0
- package/src/internal/shims.ts +107 -0
- package/src/internal/to-file.ts +154 -0
- package/src/internal/types.ts +95 -0
- package/src/internal/uploads.ts +187 -0
- package/src/internal/utils/base64.ts +40 -0
- package/src/internal/utils/bytes.ts +32 -0
- package/src/internal/utils/env.ts +18 -0
- package/src/internal/utils/log.ts +126 -0
- package/src/internal/utils/path.ts +88 -0
- package/src/internal/utils/sleep.ts +3 -0
- package/src/internal/utils/uuid.ts +17 -0
- package/src/internal/utils/values.ts +105 -0
- package/src/internal/utils.ts +8 -0
- package/src/lib/.keep +4 -0
- package/src/lib/verify-user-token.ts +121 -0
- package/src/pagination.ts +2 -0
- package/src/resource.ts +2 -0
- package/src/resources/app-builds.ts +242 -0
- package/src/resources/apps.ts +355 -0
- package/src/resources/authorized-users.ts +177 -0
- package/src/resources/chat-channels.ts +207 -0
- package/src/resources/checkout-configurations.ts +397 -0
- package/src/resources/companies.ts +20 -0
- package/src/resources/course-lesson-interactions.ts +85 -0
- package/src/resources/entries.ts +216 -0
- package/src/resources/experiences.ts +349 -0
- package/src/resources/forum-posts.ts +298 -0
- package/src/resources/index.ts +158 -0
- package/src/resources/invoices.ts +363 -0
- package/src/resources/ledger-accounts.ts +141 -0
- package/src/resources/memberships.ts +378 -0
- package/src/resources/messages.ts +303 -0
- package/src/resources/payments.ts +585 -0
- package/src/resources/plans.ts +594 -0
- package/src/resources/products.ts +527 -0
- package/src/resources/reactions.ts +139 -0
- package/src/resources/shared.ts +3086 -0
- package/src/resources/shipments.ts +200 -0
- package/src/resources/support-channels.ts +193 -0
- package/src/resources/transfers.ts +200 -0
- package/src/resources/users.ts +84 -0
- package/src/resources/webhooks.ts +144 -0
- package/src/resources.ts +1 -0
- package/src/tsconfig.json +11 -0
- package/src/uploads.ts +2 -0
- package/src/version.ts +1 -0
- package/uploads.d.mts +2 -0
- package/uploads.d.mts.map +1 -0
- package/uploads.d.ts +2 -0
- package/uploads.d.ts.map +1 -0
- package/uploads.js +6 -0
- package/uploads.js.map +1 -0
- package/uploads.mjs +2 -0
- package/uploads.mjs.map +1 -0
- package/version.d.mts +2 -0
- package/version.d.mts.map +1 -0
- package/version.d.ts +2 -0
- package/version.d.ts.map +1 -0
- package/version.js +5 -0
- package/version.js.map +1 -0
- package/version.mjs +2 -0
- package/version.mjs.map +1 -0
|
@@ -0,0 +1,2309 @@
|
|
|
1
|
+
import * as Shared from "./shared.mjs";
|
|
2
|
+
import { CursorPage } from "../core/pagination.mjs";
|
|
3
|
+
/**
|
|
4
|
+
* The different types an access pass can be.
|
|
5
|
+
*/
|
|
6
|
+
export type AccessPassType = 'regular' | 'app' | 'experience_upsell' | 'api_only';
|
|
7
|
+
/**
|
|
8
|
+
* An object representing an app
|
|
9
|
+
*/
|
|
10
|
+
export interface App {
|
|
11
|
+
/**
|
|
12
|
+
* The ID of the app
|
|
13
|
+
*/
|
|
14
|
+
id: string;
|
|
15
|
+
/**
|
|
16
|
+
* The API key for the app
|
|
17
|
+
*/
|
|
18
|
+
api_key: App.APIKey | null;
|
|
19
|
+
/**
|
|
20
|
+
* The base url of the app
|
|
21
|
+
*/
|
|
22
|
+
base_url: string | null;
|
|
23
|
+
/**
|
|
24
|
+
* The company that owns the app
|
|
25
|
+
*/
|
|
26
|
+
company: App.Company;
|
|
27
|
+
/**
|
|
28
|
+
* The creator of the app
|
|
29
|
+
*/
|
|
30
|
+
creator: App.Creator;
|
|
31
|
+
/**
|
|
32
|
+
* The path part for a specific view of the app. This is the template part of the
|
|
33
|
+
* url after the base domain. Eg: /experiences/[experienceId]
|
|
34
|
+
*/
|
|
35
|
+
dashboard_path: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* The description of the app
|
|
38
|
+
*/
|
|
39
|
+
description: string | null;
|
|
40
|
+
/**
|
|
41
|
+
* The path part for a specific view of the app. This is the template part of the
|
|
42
|
+
* url after the base domain. Eg: /experiences/[experienceId]
|
|
43
|
+
*/
|
|
44
|
+
discover_path: string | null;
|
|
45
|
+
/**
|
|
46
|
+
* The unique part of the proxied domain for this app. Used to generate the base
|
|
47
|
+
* url used to display the app inside the whop platform. Refers to the id part in
|
|
48
|
+
* the final url: https://{domain_id}.apps.whop.com
|
|
49
|
+
*/
|
|
50
|
+
domain_id: string;
|
|
51
|
+
/**
|
|
52
|
+
* The path part for a specific view of the app. This is the template part of the
|
|
53
|
+
* url after the base domain. Eg: /experiences/[experienceId]
|
|
54
|
+
*/
|
|
55
|
+
experience_path: string | null;
|
|
56
|
+
/**
|
|
57
|
+
* The name of the app
|
|
58
|
+
*/
|
|
59
|
+
name: string;
|
|
60
|
+
/**
|
|
61
|
+
* The set of permissions that an app requests to be granted when a user installs
|
|
62
|
+
* the app.
|
|
63
|
+
*/
|
|
64
|
+
requested_permissions: Array<App.RequestedPermission>;
|
|
65
|
+
/**
|
|
66
|
+
* A collection of stats for the app.
|
|
67
|
+
*/
|
|
68
|
+
stats: App.Stats | null;
|
|
69
|
+
/**
|
|
70
|
+
* If the status is live, the app is visible on Whop discovery. In order to be
|
|
71
|
+
* live, you need to set the name, icon, and description. Being unlisted or hidden
|
|
72
|
+
* means it's not visible on Whop but you can still install the app via direct
|
|
73
|
+
* link. To remove the app from whop discovery, you should set the status to
|
|
74
|
+
* unlisted.
|
|
75
|
+
*/
|
|
76
|
+
status: AppStatuses;
|
|
77
|
+
/**
|
|
78
|
+
* Whether this app has been verified by Whop. Verified apps are endorsed by whop
|
|
79
|
+
* and are shown in the 'featured apps' section of the app store.
|
|
80
|
+
*/
|
|
81
|
+
verified: boolean;
|
|
82
|
+
}
|
|
83
|
+
export declare namespace App {
|
|
84
|
+
/**
|
|
85
|
+
* The API key for the app
|
|
86
|
+
*/
|
|
87
|
+
interface APIKey {
|
|
88
|
+
/**
|
|
89
|
+
* The ID of this API key
|
|
90
|
+
*/
|
|
91
|
+
id: string;
|
|
92
|
+
/**
|
|
93
|
+
* This is the API key used to authenticate requests
|
|
94
|
+
*/
|
|
95
|
+
token: string;
|
|
96
|
+
/**
|
|
97
|
+
* When this API key was created at
|
|
98
|
+
*/
|
|
99
|
+
created_at: string;
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* The company that owns the app
|
|
103
|
+
*/
|
|
104
|
+
interface Company {
|
|
105
|
+
/**
|
|
106
|
+
* The ID (tag) of the company.
|
|
107
|
+
*/
|
|
108
|
+
id: string;
|
|
109
|
+
/**
|
|
110
|
+
* The title of the company.
|
|
111
|
+
*/
|
|
112
|
+
title: string;
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* The creator of the app
|
|
116
|
+
*/
|
|
117
|
+
interface Creator {
|
|
118
|
+
/**
|
|
119
|
+
* The internal ID of the user.
|
|
120
|
+
*/
|
|
121
|
+
id: string;
|
|
122
|
+
/**
|
|
123
|
+
* The name of the user from their Whop account.
|
|
124
|
+
*/
|
|
125
|
+
name: string | null;
|
|
126
|
+
/**
|
|
127
|
+
* The username of the user from their Whop account.
|
|
128
|
+
*/
|
|
129
|
+
username: string;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* A permission that the app requests from the admin of a company during the oauth
|
|
133
|
+
* flow.
|
|
134
|
+
*/
|
|
135
|
+
interface RequestedPermission {
|
|
136
|
+
/**
|
|
137
|
+
* Whether the action is required for the app to function.
|
|
138
|
+
*/
|
|
139
|
+
is_required: boolean;
|
|
140
|
+
/**
|
|
141
|
+
* The reason for requesting the action.
|
|
142
|
+
*/
|
|
143
|
+
justification: string;
|
|
144
|
+
/**
|
|
145
|
+
* The action that the app will request off of users when a user installs the app.
|
|
146
|
+
*/
|
|
147
|
+
permission_action: RequestedPermission.PermissionAction;
|
|
148
|
+
}
|
|
149
|
+
namespace RequestedPermission {
|
|
150
|
+
/**
|
|
151
|
+
* The action that the app will request off of users when a user installs the app.
|
|
152
|
+
*/
|
|
153
|
+
interface PermissionAction {
|
|
154
|
+
/**
|
|
155
|
+
* The identifier of the action.
|
|
156
|
+
*/
|
|
157
|
+
action: string;
|
|
158
|
+
/**
|
|
159
|
+
* The human readable name of the action.
|
|
160
|
+
*/
|
|
161
|
+
name: string;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* A collection of stats for the app.
|
|
166
|
+
*/
|
|
167
|
+
interface Stats {
|
|
168
|
+
/**
|
|
169
|
+
* This is the number of users that have spent time in this app in the last 24
|
|
170
|
+
* hours.
|
|
171
|
+
*/
|
|
172
|
+
dau: number;
|
|
173
|
+
/**
|
|
174
|
+
* This is the number of users that have spent time in this app in the last 28
|
|
175
|
+
* days.
|
|
176
|
+
*/
|
|
177
|
+
mau: number;
|
|
178
|
+
/**
|
|
179
|
+
* This how much time, in seconds, users have spent in this app in the last 24
|
|
180
|
+
* hours.
|
|
181
|
+
*/
|
|
182
|
+
time_spent_last24_hours: number;
|
|
183
|
+
/**
|
|
184
|
+
* This is the number of users that have spent time in this app in the last 7 days.
|
|
185
|
+
*/
|
|
186
|
+
wau: number;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* An App Build object representing a build of an application
|
|
191
|
+
*/
|
|
192
|
+
export interface AppBuild {
|
|
193
|
+
/**
|
|
194
|
+
* The ID of the app build. It will look like apbu_xxxxx.
|
|
195
|
+
*/
|
|
196
|
+
id: string;
|
|
197
|
+
/**
|
|
198
|
+
* This is generated by the client and used to verify the integrity of the file
|
|
199
|
+
* that is submitted. It is a SHA256 hash of the app build file.
|
|
200
|
+
*/
|
|
201
|
+
checksum: string;
|
|
202
|
+
/**
|
|
203
|
+
* When this app build was created.
|
|
204
|
+
*/
|
|
205
|
+
created_at: string;
|
|
206
|
+
/**
|
|
207
|
+
* The URL to download the app build .zip file.
|
|
208
|
+
*/
|
|
209
|
+
file_url: string;
|
|
210
|
+
/**
|
|
211
|
+
* Whether this app build is currently being used in production.
|
|
212
|
+
*/
|
|
213
|
+
is_production: boolean;
|
|
214
|
+
/**
|
|
215
|
+
* The platform of the app build (ios, android, web)
|
|
216
|
+
*/
|
|
217
|
+
platform: AppBuildPlatforms;
|
|
218
|
+
/**
|
|
219
|
+
* The review message for the app build, if any. This is populated when the build
|
|
220
|
+
* is rejected and there is a reason specified by the reviewer.
|
|
221
|
+
*/
|
|
222
|
+
review_message: string | null;
|
|
223
|
+
/**
|
|
224
|
+
* The status of the app build (draft, approved, rejected, pending, etc)
|
|
225
|
+
*/
|
|
226
|
+
status: AppBuildStatuses;
|
|
227
|
+
/**
|
|
228
|
+
* The supported app view types for the app build. These are the views that the
|
|
229
|
+
* developer has specified that this build supports.
|
|
230
|
+
*/
|
|
231
|
+
supported_app_view_types: Array<AppViewType>;
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
* The different platforms an app build can target.
|
|
235
|
+
*/
|
|
236
|
+
export type AppBuildPlatforms = 'ios' | 'android' | 'web';
|
|
237
|
+
/**
|
|
238
|
+
* The different statuses an AppBuild can be in.
|
|
239
|
+
*/
|
|
240
|
+
export type AppBuildStatuses = 'draft' | 'pending' | 'approved' | 'rejected';
|
|
241
|
+
/**
|
|
242
|
+
* The status of an experience interface
|
|
243
|
+
*/
|
|
244
|
+
export type AppStatuses = 'live' | 'unlisted' | 'hidden';
|
|
245
|
+
/**
|
|
246
|
+
* The different types of an app view
|
|
247
|
+
*/
|
|
248
|
+
export type AppViewType = 'hub' | 'discover' | 'dash' | 'dashboard' | 'analytics';
|
|
249
|
+
/**
|
|
250
|
+
* Possible roles an authorized user can have
|
|
251
|
+
*/
|
|
252
|
+
export type AuthorizedUserRoles = 'owner' | 'admin' | 'sales_manager' | 'moderator' | 'app_manager' | 'support' | 'manager';
|
|
253
|
+
/**
|
|
254
|
+
* The different business types a company can be.
|
|
255
|
+
*/
|
|
256
|
+
export type BusinessTypes = 'education_program' | 'coaching' | 'software' | 'paid_group' | 'newsletter' | 'agency' | 'physical_products' | 'brick_and_mortar' | 'events' | 'coaching_and_courses' | 'other' | 'saas' | 'course' | 'community';
|
|
257
|
+
/**
|
|
258
|
+
* Represents a Chat feed
|
|
259
|
+
*/
|
|
260
|
+
export interface ChatChannel {
|
|
261
|
+
/**
|
|
262
|
+
* The unique identifier for the entity
|
|
263
|
+
*/
|
|
264
|
+
id: string;
|
|
265
|
+
/**
|
|
266
|
+
* Whether or not media is banned in this chat
|
|
267
|
+
*/
|
|
268
|
+
ban_media: boolean;
|
|
269
|
+
/**
|
|
270
|
+
* Whether or not URLs are banned in this chat
|
|
271
|
+
*/
|
|
272
|
+
ban_urls: boolean;
|
|
273
|
+
/**
|
|
274
|
+
* List of banned words in this chat
|
|
275
|
+
*/
|
|
276
|
+
banned_words: Array<string>;
|
|
277
|
+
/**
|
|
278
|
+
* The experience for this chat
|
|
279
|
+
*/
|
|
280
|
+
experience: ChatChannel.Experience;
|
|
281
|
+
/**
|
|
282
|
+
* The number of seconds a user needs to wait before posting again, if any
|
|
283
|
+
*/
|
|
284
|
+
user_posts_cooldown_seconds: number | null;
|
|
285
|
+
/**
|
|
286
|
+
* Who can post on this chat
|
|
287
|
+
*/
|
|
288
|
+
who_can_post: WhoCanPost;
|
|
289
|
+
/**
|
|
290
|
+
* Who can react on this chat
|
|
291
|
+
*/
|
|
292
|
+
who_can_react: WhoCanReact;
|
|
293
|
+
}
|
|
294
|
+
export declare namespace ChatChannel {
|
|
295
|
+
/**
|
|
296
|
+
* The experience for this chat
|
|
297
|
+
*/
|
|
298
|
+
interface Experience {
|
|
299
|
+
/**
|
|
300
|
+
* The unique ID representing this experience
|
|
301
|
+
*/
|
|
302
|
+
id: string;
|
|
303
|
+
/**
|
|
304
|
+
* The written name of the description.
|
|
305
|
+
*/
|
|
306
|
+
name: string;
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
/**
|
|
310
|
+
* A checkout session
|
|
311
|
+
*/
|
|
312
|
+
export interface CheckoutConfiguration {
|
|
313
|
+
/**
|
|
314
|
+
* The ID of the checkout session
|
|
315
|
+
*/
|
|
316
|
+
id: string;
|
|
317
|
+
/**
|
|
318
|
+
* The affiliate code to use for the checkout session
|
|
319
|
+
*/
|
|
320
|
+
affiliate_code: string;
|
|
321
|
+
/**
|
|
322
|
+
* The ID of the company to use for the checkout session
|
|
323
|
+
*/
|
|
324
|
+
company_id: string;
|
|
325
|
+
/**
|
|
326
|
+
* The metadata to use for the checkout session
|
|
327
|
+
*/
|
|
328
|
+
metadata: {
|
|
329
|
+
[key: string]: unknown;
|
|
330
|
+
};
|
|
331
|
+
/**
|
|
332
|
+
* The plan to use for the checkout session
|
|
333
|
+
*/
|
|
334
|
+
plan: CheckoutConfiguration.Plan;
|
|
335
|
+
/**
|
|
336
|
+
* The URL to redirect the user to after the checkout session is created
|
|
337
|
+
*/
|
|
338
|
+
purchase_url: string;
|
|
339
|
+
/**
|
|
340
|
+
* The URL to redirect the user to after the checkout session is created
|
|
341
|
+
*/
|
|
342
|
+
redirect_url: string;
|
|
343
|
+
}
|
|
344
|
+
export declare namespace CheckoutConfiguration {
|
|
345
|
+
/**
|
|
346
|
+
* The plan to use for the checkout session
|
|
347
|
+
*/
|
|
348
|
+
interface Plan {
|
|
349
|
+
/**
|
|
350
|
+
* The internal ID of the plan.
|
|
351
|
+
*/
|
|
352
|
+
id: string;
|
|
353
|
+
/**
|
|
354
|
+
* The interval at which the plan charges (renewal plans).
|
|
355
|
+
*/
|
|
356
|
+
billing_period: number | null;
|
|
357
|
+
/**
|
|
358
|
+
* The respective currency identifier for the plan.
|
|
359
|
+
*/
|
|
360
|
+
currency: Shared.Currency;
|
|
361
|
+
/**
|
|
362
|
+
* The interval at which the plan charges (expiration plans).
|
|
363
|
+
*/
|
|
364
|
+
expiration_days: number | null;
|
|
365
|
+
/**
|
|
366
|
+
* The price a person has to pay for a plan on the initial purchase.
|
|
367
|
+
*/
|
|
368
|
+
initial_price: number;
|
|
369
|
+
/**
|
|
370
|
+
* Indicates if the plan is a one time payment or recurring.
|
|
371
|
+
*/
|
|
372
|
+
plan_type: Shared.PlanType;
|
|
373
|
+
/**
|
|
374
|
+
* This is the release method the business uses to sell this plan.
|
|
375
|
+
*/
|
|
376
|
+
release_method: Shared.ReleaseMethod;
|
|
377
|
+
/**
|
|
378
|
+
* The price a person has to pay for a plan on the renewal purchase.
|
|
379
|
+
*/
|
|
380
|
+
renewal_price: number;
|
|
381
|
+
/**
|
|
382
|
+
* The number of free trial days added before a renewal plan.
|
|
383
|
+
*/
|
|
384
|
+
trial_period_days: number | null;
|
|
385
|
+
/**
|
|
386
|
+
* Shows or hides the plan from public/business view.
|
|
387
|
+
*/
|
|
388
|
+
visibility: Shared.Visibility;
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
/**
|
|
392
|
+
* The method of collection for an invoice.
|
|
393
|
+
*/
|
|
394
|
+
export type CollectionMethod = 'send_invoice' | 'charge_automatically';
|
|
395
|
+
/**
|
|
396
|
+
* An object representing a (sanitized) company.
|
|
397
|
+
*/
|
|
398
|
+
export interface Company {
|
|
399
|
+
/**
|
|
400
|
+
* The ID (tag) of the company.
|
|
401
|
+
*/
|
|
402
|
+
id: string;
|
|
403
|
+
/**
|
|
404
|
+
* The different business types a company can be.
|
|
405
|
+
*/
|
|
406
|
+
business_type: BusinessTypes | null;
|
|
407
|
+
/**
|
|
408
|
+
* When the company was created (signed up)
|
|
409
|
+
*/
|
|
410
|
+
created_at: string;
|
|
411
|
+
/**
|
|
412
|
+
* The different industry types a company can be in.
|
|
413
|
+
*/
|
|
414
|
+
industry_type: IndustryTypes | null;
|
|
415
|
+
/**
|
|
416
|
+
* The number of members in the company.
|
|
417
|
+
*/
|
|
418
|
+
member_count: number;
|
|
419
|
+
/**
|
|
420
|
+
* The user who owns this company
|
|
421
|
+
*/
|
|
422
|
+
owner_user: Company.OwnerUser;
|
|
423
|
+
/**
|
|
424
|
+
* The number of reviews that have been published for the company.
|
|
425
|
+
*/
|
|
426
|
+
published_reviews_count: number;
|
|
427
|
+
/**
|
|
428
|
+
* The slug/route of the company on the Whop site.
|
|
429
|
+
*/
|
|
430
|
+
route: string;
|
|
431
|
+
/**
|
|
432
|
+
* The social media accounts of the company
|
|
433
|
+
*/
|
|
434
|
+
social_links: Array<Company.SocialLink>;
|
|
435
|
+
/**
|
|
436
|
+
* The title of the company.
|
|
437
|
+
*/
|
|
438
|
+
title: string;
|
|
439
|
+
/**
|
|
440
|
+
* The time the company was last updated.
|
|
441
|
+
*/
|
|
442
|
+
updated_at: string;
|
|
443
|
+
/**
|
|
444
|
+
* If the company is Whop Verified
|
|
445
|
+
*/
|
|
446
|
+
verified: boolean;
|
|
447
|
+
}
|
|
448
|
+
export declare namespace Company {
|
|
449
|
+
/**
|
|
450
|
+
* The user who owns this company
|
|
451
|
+
*/
|
|
452
|
+
interface OwnerUser {
|
|
453
|
+
/**
|
|
454
|
+
* The internal ID of the user.
|
|
455
|
+
*/
|
|
456
|
+
id: string;
|
|
457
|
+
/**
|
|
458
|
+
* The name of the user from their Whop account.
|
|
459
|
+
*/
|
|
460
|
+
name: string | null;
|
|
461
|
+
/**
|
|
462
|
+
* The username of the user from their Whop account.
|
|
463
|
+
*/
|
|
464
|
+
username: string;
|
|
465
|
+
}
|
|
466
|
+
/**
|
|
467
|
+
* A social link attached to a resource on the site.
|
|
468
|
+
*/
|
|
469
|
+
interface SocialLink {
|
|
470
|
+
/**
|
|
471
|
+
* The ID
|
|
472
|
+
*/
|
|
473
|
+
id: string;
|
|
474
|
+
/**
|
|
475
|
+
* The URL
|
|
476
|
+
*/
|
|
477
|
+
url: string;
|
|
478
|
+
/**
|
|
479
|
+
* The website
|
|
480
|
+
*/
|
|
481
|
+
website: 'x' | 'instagram' | 'facebook' | 'tiktok' | 'youtube' | 'linkedin' | 'twitch' | 'website';
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
/**
|
|
485
|
+
* A lesson interaction tracking user progress in courses
|
|
486
|
+
*/
|
|
487
|
+
export interface CourseLessonInteraction {
|
|
488
|
+
/**
|
|
489
|
+
* The ID of the lesson interaction
|
|
490
|
+
*/
|
|
491
|
+
id: string;
|
|
492
|
+
/**
|
|
493
|
+
* Whether the lesson has been completed by the user
|
|
494
|
+
*/
|
|
495
|
+
completed: boolean;
|
|
496
|
+
/**
|
|
497
|
+
* When the interaction was created
|
|
498
|
+
*/
|
|
499
|
+
created_at: string;
|
|
500
|
+
/**
|
|
501
|
+
* The lesson this interaction is for
|
|
502
|
+
*/
|
|
503
|
+
lesson: CourseLessonInteraction.Lesson;
|
|
504
|
+
/**
|
|
505
|
+
* The user who interacted with the lesson
|
|
506
|
+
*/
|
|
507
|
+
user: CourseLessonInteraction.User;
|
|
508
|
+
}
|
|
509
|
+
export declare namespace CourseLessonInteraction {
|
|
510
|
+
/**
|
|
511
|
+
* The lesson this interaction is for
|
|
512
|
+
*/
|
|
513
|
+
interface Lesson {
|
|
514
|
+
/**
|
|
515
|
+
* The ID of the lesson
|
|
516
|
+
*/
|
|
517
|
+
id: string;
|
|
518
|
+
/**
|
|
519
|
+
* The title of the lesson
|
|
520
|
+
*/
|
|
521
|
+
title: string;
|
|
522
|
+
}
|
|
523
|
+
/**
|
|
524
|
+
* The user who interacted with the lesson
|
|
525
|
+
*/
|
|
526
|
+
interface User {
|
|
527
|
+
/**
|
|
528
|
+
* The internal ID of the user.
|
|
529
|
+
*/
|
|
530
|
+
id: string;
|
|
531
|
+
/**
|
|
532
|
+
* The name of the user from their Whop account.
|
|
533
|
+
*/
|
|
534
|
+
name: string | null;
|
|
535
|
+
/**
|
|
536
|
+
* The username of the user from their Whop account.
|
|
537
|
+
*/
|
|
538
|
+
username: string;
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
/**
|
|
542
|
+
* A lesson interaction tracking user progress in courses
|
|
543
|
+
*/
|
|
544
|
+
export interface CourseLessonInteractionListItem {
|
|
545
|
+
/**
|
|
546
|
+
* The ID of the lesson interaction
|
|
547
|
+
*/
|
|
548
|
+
id: string;
|
|
549
|
+
/**
|
|
550
|
+
* Whether the lesson has been completed by the user
|
|
551
|
+
*/
|
|
552
|
+
completed: boolean;
|
|
553
|
+
/**
|
|
554
|
+
* When the interaction was created
|
|
555
|
+
*/
|
|
556
|
+
created_at: string;
|
|
557
|
+
/**
|
|
558
|
+
* The lesson this interaction is for
|
|
559
|
+
*/
|
|
560
|
+
lesson: CourseLessonInteractionListItem.Lesson;
|
|
561
|
+
/**
|
|
562
|
+
* The user who interacted with the lesson
|
|
563
|
+
*/
|
|
564
|
+
user: CourseLessonInteractionListItem.User;
|
|
565
|
+
}
|
|
566
|
+
export declare namespace CourseLessonInteractionListItem {
|
|
567
|
+
/**
|
|
568
|
+
* The lesson this interaction is for
|
|
569
|
+
*/
|
|
570
|
+
interface Lesson {
|
|
571
|
+
/**
|
|
572
|
+
* The ID of the lesson
|
|
573
|
+
*/
|
|
574
|
+
id: string;
|
|
575
|
+
/**
|
|
576
|
+
* The title of the lesson
|
|
577
|
+
*/
|
|
578
|
+
title: string;
|
|
579
|
+
}
|
|
580
|
+
/**
|
|
581
|
+
* The user who interacted with the lesson
|
|
582
|
+
*/
|
|
583
|
+
interface User {
|
|
584
|
+
/**
|
|
585
|
+
* The internal ID of the user.
|
|
586
|
+
*/
|
|
587
|
+
id: string;
|
|
588
|
+
/**
|
|
589
|
+
* The name of the user from their Whop account.
|
|
590
|
+
*/
|
|
591
|
+
name: string | null;
|
|
592
|
+
/**
|
|
593
|
+
* The username of the user from their Whop account.
|
|
594
|
+
*/
|
|
595
|
+
username: string;
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
/**
|
|
599
|
+
* The available currencies on the platform
|
|
600
|
+
*/
|
|
601
|
+
export type Currency = 'usd' | 'sgd' | 'inr' | 'aud' | 'brl' | 'cad' | 'dkk' | 'eur' | 'nok' | 'gbp' | 'sek' | 'chf' | 'hkd' | 'huf' | 'jpy' | 'mxn' | 'myr' | 'pln' | 'czk' | 'nzd' | 'aed' | 'eth' | 'ape' | 'cop' | 'ron' | 'thb' | 'bgn' | 'idr' | 'dop' | 'php' | 'try' | 'krw' | 'twd' | 'vnd' | 'pkr' | 'clp' | 'uyu' | 'ars' | 'zar' | 'dzd' | 'tnd' | 'mad' | 'kes' | 'kwd' | 'jod' | 'all' | 'xcd' | 'amd' | 'bsd' | 'bhd' | 'bob' | 'bam' | 'khr' | 'crc' | 'xof' | 'egp' | 'etb' | 'gmd' | 'ghs' | 'gtq' | 'gyd' | 'ils' | 'jmd' | 'mop' | 'mga' | 'mur' | 'mdl' | 'mnt' | 'nad' | 'ngn' | 'mkd' | 'omr' | 'pyg' | 'pen' | 'qar' | 'rwf' | 'sar' | 'rsd' | 'lkr' | 'tzs' | 'ttd' | 'uzs' | 'rub' | 'btc';
|
|
602
|
+
/**
|
|
603
|
+
* The different types of custom CTAs that can be selected.
|
|
604
|
+
*/
|
|
605
|
+
export type CustomCta = 'get_access' | 'join' | 'order_now' | 'shop_now' | 'call_now' | 'donate_now' | 'contact_us' | 'sign_up' | 'subscribe' | 'purchase' | 'get_offer' | 'apply_now' | 'complete_order';
|
|
606
|
+
/**
|
|
607
|
+
* The direction of the sort.
|
|
608
|
+
*/
|
|
609
|
+
export type Direction = 'asc' | 'desc';
|
|
610
|
+
/**
|
|
611
|
+
* The types of post
|
|
612
|
+
*/
|
|
613
|
+
export type DmsPostTypes = 'regular' | 'system' | 'automated';
|
|
614
|
+
/**
|
|
615
|
+
* An object representing an entry in a waitlist.
|
|
616
|
+
*/
|
|
617
|
+
export interface Entry {
|
|
618
|
+
/**
|
|
619
|
+
* The internal ID of the entry.
|
|
620
|
+
*/
|
|
621
|
+
id: string;
|
|
622
|
+
/**
|
|
623
|
+
* When the entry was created.
|
|
624
|
+
*/
|
|
625
|
+
created_at: string | null;
|
|
626
|
+
/**
|
|
627
|
+
* Responses collected from the user when submitting their entry.
|
|
628
|
+
*/
|
|
629
|
+
custom_field_responses: Array<Entry.CustomFieldResponse> | null;
|
|
630
|
+
/**
|
|
631
|
+
* The waitlist plan the entry if for.
|
|
632
|
+
*/
|
|
633
|
+
plan: Entry.Plan | null;
|
|
634
|
+
/**
|
|
635
|
+
* The access pass tied to this entry, if there is one.
|
|
636
|
+
*/
|
|
637
|
+
product: Entry.Product | null;
|
|
638
|
+
/**
|
|
639
|
+
* The status of the entry.
|
|
640
|
+
*/
|
|
641
|
+
status: EntryStatus;
|
|
642
|
+
/**
|
|
643
|
+
* The user who created the entry.
|
|
644
|
+
*/
|
|
645
|
+
user: Entry.User;
|
|
646
|
+
}
|
|
647
|
+
export declare namespace Entry {
|
|
648
|
+
/**
|
|
649
|
+
* The response from a custom field on checkout
|
|
650
|
+
*/
|
|
651
|
+
interface CustomFieldResponse {
|
|
652
|
+
/**
|
|
653
|
+
* The ID of the custom field item
|
|
654
|
+
*/
|
|
655
|
+
id: string;
|
|
656
|
+
/**
|
|
657
|
+
* The response a user gave to the specific question or field.
|
|
658
|
+
*/
|
|
659
|
+
answer: string;
|
|
660
|
+
/**
|
|
661
|
+
* The question asked by the custom field
|
|
662
|
+
*/
|
|
663
|
+
question: string;
|
|
664
|
+
}
|
|
665
|
+
/**
|
|
666
|
+
* The waitlist plan the entry if for.
|
|
667
|
+
*/
|
|
668
|
+
interface Plan {
|
|
669
|
+
/**
|
|
670
|
+
* The internal ID of the plan.
|
|
671
|
+
*/
|
|
672
|
+
id: string;
|
|
673
|
+
}
|
|
674
|
+
/**
|
|
675
|
+
* The access pass tied to this entry, if there is one.
|
|
676
|
+
*/
|
|
677
|
+
interface Product {
|
|
678
|
+
/**
|
|
679
|
+
* The internal ID of the public product.
|
|
680
|
+
*/
|
|
681
|
+
id: string;
|
|
682
|
+
/**
|
|
683
|
+
* The title of the product. Use for Whop 4.0.
|
|
684
|
+
*/
|
|
685
|
+
title: string;
|
|
686
|
+
}
|
|
687
|
+
/**
|
|
688
|
+
* The user who created the entry.
|
|
689
|
+
*/
|
|
690
|
+
interface User {
|
|
691
|
+
/**
|
|
692
|
+
* The internal ID of the user.
|
|
693
|
+
*/
|
|
694
|
+
id: string;
|
|
695
|
+
/**
|
|
696
|
+
* The email of the user
|
|
697
|
+
*/
|
|
698
|
+
email: string | null;
|
|
699
|
+
/**
|
|
700
|
+
* The name of the user from their Whop account.
|
|
701
|
+
*/
|
|
702
|
+
name: string | null;
|
|
703
|
+
/**
|
|
704
|
+
* The username of the user from their Whop account.
|
|
705
|
+
*/
|
|
706
|
+
username: string;
|
|
707
|
+
}
|
|
708
|
+
}
|
|
709
|
+
/**
|
|
710
|
+
* The status of an entry to a waitlist.
|
|
711
|
+
*/
|
|
712
|
+
export type EntryStatus = 'drafted' | 'pending' | 'approved' | 'denied' | 'any';
|
|
713
|
+
/**
|
|
714
|
+
* An object representing an experience belonging to a company.
|
|
715
|
+
*/
|
|
716
|
+
export interface Experience {
|
|
717
|
+
/**
|
|
718
|
+
* The unique ID representing this experience
|
|
719
|
+
*/
|
|
720
|
+
id: string;
|
|
721
|
+
/**
|
|
722
|
+
* The experience interface for this experience.
|
|
723
|
+
*/
|
|
724
|
+
app: Experience.App;
|
|
725
|
+
/**
|
|
726
|
+
* The company that owns this experience.
|
|
727
|
+
*/
|
|
728
|
+
company: Experience.Company;
|
|
729
|
+
/**
|
|
730
|
+
* The timestamp of when this experience was created.
|
|
731
|
+
*/
|
|
732
|
+
created_at: string;
|
|
733
|
+
/**
|
|
734
|
+
* The written name of the description.
|
|
735
|
+
*/
|
|
736
|
+
name: string;
|
|
737
|
+
/**
|
|
738
|
+
* The order of the experience in the section
|
|
739
|
+
*/
|
|
740
|
+
order: string | null;
|
|
741
|
+
/**
|
|
742
|
+
* The access passes that are associated with this experience. This should not be
|
|
743
|
+
* used unless you are trying to list all access passes the experience has, for
|
|
744
|
+
* some reason. You probably don't want to use this though and should be using
|
|
745
|
+
* accessPass.
|
|
746
|
+
*/
|
|
747
|
+
products: Array<Experience.Product>;
|
|
748
|
+
}
|
|
749
|
+
export declare namespace Experience {
|
|
750
|
+
/**
|
|
751
|
+
* The experience interface for this experience.
|
|
752
|
+
*/
|
|
753
|
+
interface App {
|
|
754
|
+
/**
|
|
755
|
+
* The ID of the app
|
|
756
|
+
*/
|
|
757
|
+
id: string;
|
|
758
|
+
/**
|
|
759
|
+
* The name of the app
|
|
760
|
+
*/
|
|
761
|
+
name: string;
|
|
762
|
+
}
|
|
763
|
+
/**
|
|
764
|
+
* The company that owns this experience.
|
|
765
|
+
*/
|
|
766
|
+
interface Company {
|
|
767
|
+
/**
|
|
768
|
+
* The ID (tag) of the company.
|
|
769
|
+
*/
|
|
770
|
+
id: string;
|
|
771
|
+
/**
|
|
772
|
+
* The slug/route of the company on the Whop site.
|
|
773
|
+
*/
|
|
774
|
+
route: string;
|
|
775
|
+
/**
|
|
776
|
+
* The title of the company.
|
|
777
|
+
*/
|
|
778
|
+
title: string;
|
|
779
|
+
}
|
|
780
|
+
/**
|
|
781
|
+
* An object representing a (sanitized) access pass.
|
|
782
|
+
*/
|
|
783
|
+
interface Product {
|
|
784
|
+
/**
|
|
785
|
+
* The internal ID of the public product.
|
|
786
|
+
*/
|
|
787
|
+
id: string;
|
|
788
|
+
/**
|
|
789
|
+
* The route of the product.
|
|
790
|
+
*/
|
|
791
|
+
route: string;
|
|
792
|
+
/**
|
|
793
|
+
* The title of the product. Use for Whop 4.0.
|
|
794
|
+
*/
|
|
795
|
+
title: string;
|
|
796
|
+
}
|
|
797
|
+
}
|
|
798
|
+
/**
|
|
799
|
+
* Represents a post in forum
|
|
800
|
+
*/
|
|
801
|
+
export interface ForumPost {
|
|
802
|
+
/**
|
|
803
|
+
* The unique identifier for the entity
|
|
804
|
+
*/
|
|
805
|
+
id: string;
|
|
806
|
+
/**
|
|
807
|
+
* The amount of comments on this post
|
|
808
|
+
*/
|
|
809
|
+
comment_count: number;
|
|
810
|
+
/**
|
|
811
|
+
* The content of the forum post in Markdown format
|
|
812
|
+
*/
|
|
813
|
+
content: string | null;
|
|
814
|
+
/**
|
|
815
|
+
* Whether the forum post has been edited
|
|
816
|
+
*/
|
|
817
|
+
is_edited: boolean;
|
|
818
|
+
/**
|
|
819
|
+
* Whether this forum post is pinned
|
|
820
|
+
*/
|
|
821
|
+
is_pinned: boolean;
|
|
822
|
+
/**
|
|
823
|
+
* Whether the user that sent the post is an admin of the company
|
|
824
|
+
*/
|
|
825
|
+
is_poster_admin: boolean;
|
|
826
|
+
/**
|
|
827
|
+
* The number of likes this post has received
|
|
828
|
+
*/
|
|
829
|
+
like_count: number | null;
|
|
830
|
+
/**
|
|
831
|
+
* The ID of the parent forum post, if applicable
|
|
832
|
+
*/
|
|
833
|
+
parent_id: string | null;
|
|
834
|
+
/**
|
|
835
|
+
* The title of the forum post
|
|
836
|
+
*/
|
|
837
|
+
title: string | null;
|
|
838
|
+
/**
|
|
839
|
+
* The user who created this forum post
|
|
840
|
+
*/
|
|
841
|
+
user: ForumPost.User;
|
|
842
|
+
/**
|
|
843
|
+
* The number of times this message has been viewed
|
|
844
|
+
*/
|
|
845
|
+
view_count: number | null;
|
|
846
|
+
}
|
|
847
|
+
export declare namespace ForumPost {
|
|
848
|
+
/**
|
|
849
|
+
* The user who created this forum post
|
|
850
|
+
*/
|
|
851
|
+
interface User {
|
|
852
|
+
/**
|
|
853
|
+
* The internal ID of the user.
|
|
854
|
+
*/
|
|
855
|
+
id: string;
|
|
856
|
+
/**
|
|
857
|
+
* The name of the user from their Whop account.
|
|
858
|
+
*/
|
|
859
|
+
name: string | null;
|
|
860
|
+
/**
|
|
861
|
+
* The username of the user from their Whop account.
|
|
862
|
+
*/
|
|
863
|
+
username: string;
|
|
864
|
+
}
|
|
865
|
+
}
|
|
866
|
+
/**
|
|
867
|
+
* The friendly status of a receipt
|
|
868
|
+
*/
|
|
869
|
+
export type FriendlyReceiptStatus = 'auto_refunded' | 'refunded' | 'partially_refunded' | 'dispute_warning' | 'open_resolution' | 'open_dispute' | 'failed' | 'price_too_low' | 'succeeded' | 'drafted' | 'uncollectible' | 'unresolved' | 'past_due' | 'pending' | 'incomplete' | 'canceled';
|
|
870
|
+
/**
|
|
871
|
+
* The different statuses of the global affiliate program for an access pass.
|
|
872
|
+
*/
|
|
873
|
+
export type GlobalAffiliateStatus = 'enabled' | 'disabled';
|
|
874
|
+
/**
|
|
875
|
+
* The different industry types a company can be in.
|
|
876
|
+
*/
|
|
877
|
+
export type IndustryTypes = 'trading' | 'sports_betting' | 'reselling' | 'fitness' | 'amazon_fba' | 'real_estate' | 'kindle_book_publishing' | 'dating' | 'agencies' | 'health_and_wellness' | 'social_media' | 'sales' | 'business' | 'ecommerce' | 'video_games' | 'home_services' | 'ai' | 'public_speaking' | 'personal_finance' | 'careers' | 'travel' | 'clipping' | 'spirituality' | 'vas' | 'personal_development' | 'software' | 'other' | 'marketing_agency' | 'sales_agency' | 'ai_agency' | 'design_agency' | 'coaching_agency' | 'development_agency' | 'recruiting_agency' | 'customer_support_agency' | 'clipping_agency' | 'clothing' | 'supplements' | 'beauty_and_personal_care' | 'fitness_gear' | 'accessories' | 'home_goods' | 'electronics_and_gadgets' | 'food_and_beverages' | 'gym' | 'restaurant' | 'retail_store' | 'coffee_shop' | 'salon_spa' | 'medical_dentist_office' | 'hotel_lodging' | 'auto_repair_shop' | 'masterminds' | 'webinars' | 'bootcamps' | 'convention' | 'concerts' | 'meetups' | 'parties';
|
|
878
|
+
/**
|
|
879
|
+
* A statement that defines an amount due by a customer.
|
|
880
|
+
*/
|
|
881
|
+
export interface Invoice {
|
|
882
|
+
/**
|
|
883
|
+
* The ID of the invoice.
|
|
884
|
+
*/
|
|
885
|
+
id: string;
|
|
886
|
+
/**
|
|
887
|
+
* The date the invoice was created.
|
|
888
|
+
*/
|
|
889
|
+
created_at: string;
|
|
890
|
+
/**
|
|
891
|
+
* The plan that the invoice was created for.
|
|
892
|
+
*/
|
|
893
|
+
current_plan: Invoice.CurrentPlan;
|
|
894
|
+
/**
|
|
895
|
+
* The date the invoice is due.
|
|
896
|
+
*/
|
|
897
|
+
due_date: string | null;
|
|
898
|
+
/**
|
|
899
|
+
* The email address that the invoice was created for.
|
|
900
|
+
*/
|
|
901
|
+
email_address: string | null;
|
|
902
|
+
/**
|
|
903
|
+
* The token to fetch the invoice.
|
|
904
|
+
*/
|
|
905
|
+
fetch_invoice_token: string;
|
|
906
|
+
/**
|
|
907
|
+
* The number of the invoice.
|
|
908
|
+
*/
|
|
909
|
+
number: string;
|
|
910
|
+
/**
|
|
911
|
+
* The status of the invoice.
|
|
912
|
+
*/
|
|
913
|
+
status: InvoiceStatus;
|
|
914
|
+
/**
|
|
915
|
+
* The user that the invoice was created for.
|
|
916
|
+
*/
|
|
917
|
+
user: Invoice.User | null;
|
|
918
|
+
}
|
|
919
|
+
export declare namespace Invoice {
|
|
920
|
+
/**
|
|
921
|
+
* The plan that the invoice was created for.
|
|
922
|
+
*/
|
|
923
|
+
interface CurrentPlan {
|
|
924
|
+
/**
|
|
925
|
+
* The internal ID of the plan.
|
|
926
|
+
*/
|
|
927
|
+
id: string;
|
|
928
|
+
/**
|
|
929
|
+
* The respective currency identifier for the plan.
|
|
930
|
+
*/
|
|
931
|
+
currency: Shared.Currency;
|
|
932
|
+
/**
|
|
933
|
+
* The formatted price (including currency) for the plan.
|
|
934
|
+
*/
|
|
935
|
+
formatted_price: string;
|
|
936
|
+
}
|
|
937
|
+
/**
|
|
938
|
+
* The user that the invoice was created for.
|
|
939
|
+
*/
|
|
940
|
+
interface User {
|
|
941
|
+
/**
|
|
942
|
+
* The internal ID of the user.
|
|
943
|
+
*/
|
|
944
|
+
id: string;
|
|
945
|
+
/**
|
|
946
|
+
* The name of the user from their Whop account.
|
|
947
|
+
*/
|
|
948
|
+
name: string | null;
|
|
949
|
+
/**
|
|
950
|
+
* The username of the user from their Whop account.
|
|
951
|
+
*/
|
|
952
|
+
username: string;
|
|
953
|
+
}
|
|
954
|
+
}
|
|
955
|
+
/**
|
|
956
|
+
* A statement that defines an amount due by a customer.
|
|
957
|
+
*/
|
|
958
|
+
export interface InvoiceListItem {
|
|
959
|
+
/**
|
|
960
|
+
* The ID of the invoice.
|
|
961
|
+
*/
|
|
962
|
+
id: string;
|
|
963
|
+
/**
|
|
964
|
+
* The date the invoice was created.
|
|
965
|
+
*/
|
|
966
|
+
created_at: string;
|
|
967
|
+
/**
|
|
968
|
+
* The plan that the invoice was created for.
|
|
969
|
+
*/
|
|
970
|
+
current_plan: InvoiceListItem.CurrentPlan;
|
|
971
|
+
/**
|
|
972
|
+
* The date the invoice is due.
|
|
973
|
+
*/
|
|
974
|
+
due_date: string | null;
|
|
975
|
+
/**
|
|
976
|
+
* The email address that the invoice was created for.
|
|
977
|
+
*/
|
|
978
|
+
email_address: string | null;
|
|
979
|
+
/**
|
|
980
|
+
* The token to fetch the invoice.
|
|
981
|
+
*/
|
|
982
|
+
fetch_invoice_token: string;
|
|
983
|
+
/**
|
|
984
|
+
* The number of the invoice.
|
|
985
|
+
*/
|
|
986
|
+
number: string;
|
|
987
|
+
/**
|
|
988
|
+
* The status of the invoice.
|
|
989
|
+
*/
|
|
990
|
+
status: InvoiceStatus;
|
|
991
|
+
/**
|
|
992
|
+
* The user that the invoice was created for.
|
|
993
|
+
*/
|
|
994
|
+
user: InvoiceListItem.User | null;
|
|
995
|
+
}
|
|
996
|
+
export declare namespace InvoiceListItem {
|
|
997
|
+
/**
|
|
998
|
+
* The plan that the invoice was created for.
|
|
999
|
+
*/
|
|
1000
|
+
interface CurrentPlan {
|
|
1001
|
+
/**
|
|
1002
|
+
* The internal ID of the plan.
|
|
1003
|
+
*/
|
|
1004
|
+
id: string;
|
|
1005
|
+
/**
|
|
1006
|
+
* The respective currency identifier for the plan.
|
|
1007
|
+
*/
|
|
1008
|
+
currency: Shared.Currency;
|
|
1009
|
+
/**
|
|
1010
|
+
* The formatted price (including currency) for the plan.
|
|
1011
|
+
*/
|
|
1012
|
+
formatted_price: string;
|
|
1013
|
+
}
|
|
1014
|
+
/**
|
|
1015
|
+
* The user that the invoice was created for.
|
|
1016
|
+
*/
|
|
1017
|
+
interface User {
|
|
1018
|
+
/**
|
|
1019
|
+
* The internal ID of the user.
|
|
1020
|
+
*/
|
|
1021
|
+
id: string;
|
|
1022
|
+
/**
|
|
1023
|
+
* The name of the user from their Whop account.
|
|
1024
|
+
*/
|
|
1025
|
+
name: string | null;
|
|
1026
|
+
/**
|
|
1027
|
+
* The username of the user from their Whop account.
|
|
1028
|
+
*/
|
|
1029
|
+
username: string;
|
|
1030
|
+
}
|
|
1031
|
+
}
|
|
1032
|
+
/**
|
|
1033
|
+
* The different statuses an invoice can be in
|
|
1034
|
+
*/
|
|
1035
|
+
export type InvoiceStatus = 'open' | 'paid' | 'past_due' | 'void';
|
|
1036
|
+
/**
|
|
1037
|
+
* A membership represents a purchase between a User and a Company for a specific
|
|
1038
|
+
* Product.
|
|
1039
|
+
*/
|
|
1040
|
+
export interface Membership {
|
|
1041
|
+
/**
|
|
1042
|
+
* The ID of the membership
|
|
1043
|
+
*/
|
|
1044
|
+
id: string;
|
|
1045
|
+
/**
|
|
1046
|
+
* Whether this Membership is set to cancel at the end of the current billing
|
|
1047
|
+
* cycle. Only applies for memberships that have a renewal plan.
|
|
1048
|
+
*/
|
|
1049
|
+
cancel_at_period_end: boolean;
|
|
1050
|
+
/**
|
|
1051
|
+
* The epoch timestamp of when the customer initiated a cancellation.
|
|
1052
|
+
*/
|
|
1053
|
+
canceled_at: string | null;
|
|
1054
|
+
/**
|
|
1055
|
+
* The reason that the member canceled the membership (filled out by the member).
|
|
1056
|
+
*/
|
|
1057
|
+
cancellation_reason: string | null;
|
|
1058
|
+
/**
|
|
1059
|
+
* The Company this Membership belongs to.
|
|
1060
|
+
*/
|
|
1061
|
+
company: Membership.Company;
|
|
1062
|
+
/**
|
|
1063
|
+
* The timestamp, in seconds, that this Membership was created at.
|
|
1064
|
+
*/
|
|
1065
|
+
created_at: string;
|
|
1066
|
+
/**
|
|
1067
|
+
* The available currencies on the platform
|
|
1068
|
+
*/
|
|
1069
|
+
currency: Currency | null;
|
|
1070
|
+
/**
|
|
1071
|
+
* The license key for this Membership. This is only present if the membership
|
|
1072
|
+
* grants access to an instance of the Whop Software app.
|
|
1073
|
+
*/
|
|
1074
|
+
license_key: string | null;
|
|
1075
|
+
/**
|
|
1076
|
+
* The URL for the customer to manage their membership.
|
|
1077
|
+
*/
|
|
1078
|
+
manage_url: string | null;
|
|
1079
|
+
/**
|
|
1080
|
+
* The Member that this Membership belongs to.
|
|
1081
|
+
*/
|
|
1082
|
+
member: Membership.Member | null;
|
|
1083
|
+
/**
|
|
1084
|
+
* A JSON object used to store software licensing information. Ex. HWID
|
|
1085
|
+
*/
|
|
1086
|
+
metadata: {
|
|
1087
|
+
[key: string]: unknown;
|
|
1088
|
+
};
|
|
1089
|
+
/**
|
|
1090
|
+
* Whether the membership's payments are currently paused.
|
|
1091
|
+
*/
|
|
1092
|
+
payment_collection_paused: boolean;
|
|
1093
|
+
/**
|
|
1094
|
+
* The Plan this Membership is for.
|
|
1095
|
+
*/
|
|
1096
|
+
plan: Membership.Plan;
|
|
1097
|
+
/**
|
|
1098
|
+
* The Promo Code that is currently applied to this Membership.
|
|
1099
|
+
*/
|
|
1100
|
+
promo_code: Membership.PromoCode | null;
|
|
1101
|
+
/**
|
|
1102
|
+
* The timestamp in seconds at which the current billing cycle for this
|
|
1103
|
+
* subscription ends. Only applies for memberships that have a renewal plan.
|
|
1104
|
+
*/
|
|
1105
|
+
renewal_period_end: string | null;
|
|
1106
|
+
/**
|
|
1107
|
+
* The timestamp in seconds at which the current billing cycle for this
|
|
1108
|
+
* subscription start. Only applies for memberships that have a renewal plan.
|
|
1109
|
+
*/
|
|
1110
|
+
renewal_period_start: string | null;
|
|
1111
|
+
/**
|
|
1112
|
+
* The status of the membership.
|
|
1113
|
+
*/
|
|
1114
|
+
status: MembershipStatus;
|
|
1115
|
+
/**
|
|
1116
|
+
* A timestamp of when the membership was last updated
|
|
1117
|
+
*/
|
|
1118
|
+
updated_at: string;
|
|
1119
|
+
/**
|
|
1120
|
+
* The user this membership belongs to
|
|
1121
|
+
*/
|
|
1122
|
+
user: Membership.User | null;
|
|
1123
|
+
}
|
|
1124
|
+
export declare namespace Membership {
|
|
1125
|
+
/**
|
|
1126
|
+
* The Company this Membership belongs to.
|
|
1127
|
+
*/
|
|
1128
|
+
interface Company {
|
|
1129
|
+
/**
|
|
1130
|
+
* The ID (tag) of the company.
|
|
1131
|
+
*/
|
|
1132
|
+
id: string;
|
|
1133
|
+
/**
|
|
1134
|
+
* The title of the company.
|
|
1135
|
+
*/
|
|
1136
|
+
title: string;
|
|
1137
|
+
}
|
|
1138
|
+
/**
|
|
1139
|
+
* The Member that this Membership belongs to.
|
|
1140
|
+
*/
|
|
1141
|
+
interface Member {
|
|
1142
|
+
/**
|
|
1143
|
+
* The ID of the member
|
|
1144
|
+
*/
|
|
1145
|
+
id: string;
|
|
1146
|
+
}
|
|
1147
|
+
/**
|
|
1148
|
+
* The Plan this Membership is for.
|
|
1149
|
+
*/
|
|
1150
|
+
interface Plan {
|
|
1151
|
+
/**
|
|
1152
|
+
* The internal ID of the plan.
|
|
1153
|
+
*/
|
|
1154
|
+
id: string;
|
|
1155
|
+
}
|
|
1156
|
+
/**
|
|
1157
|
+
* The Promo Code that is currently applied to this Membership.
|
|
1158
|
+
*/
|
|
1159
|
+
interface PromoCode {
|
|
1160
|
+
/**
|
|
1161
|
+
* The ID of the promo.
|
|
1162
|
+
*/
|
|
1163
|
+
id: string;
|
|
1164
|
+
}
|
|
1165
|
+
/**
|
|
1166
|
+
* The user this membership belongs to
|
|
1167
|
+
*/
|
|
1168
|
+
interface User {
|
|
1169
|
+
/**
|
|
1170
|
+
* The internal ID of the user.
|
|
1171
|
+
*/
|
|
1172
|
+
id: string;
|
|
1173
|
+
/**
|
|
1174
|
+
* The name of the user from their Whop account.
|
|
1175
|
+
*/
|
|
1176
|
+
name: string | null;
|
|
1177
|
+
/**
|
|
1178
|
+
* The username of the user from their Whop account.
|
|
1179
|
+
*/
|
|
1180
|
+
username: string;
|
|
1181
|
+
}
|
|
1182
|
+
}
|
|
1183
|
+
/**
|
|
1184
|
+
* The status of a membership
|
|
1185
|
+
*/
|
|
1186
|
+
export type MembershipStatus = 'trialing' | 'active' | 'past_due' | 'completed' | 'canceled' | 'expired' | 'unresolved' | 'drafted';
|
|
1187
|
+
/**
|
|
1188
|
+
* Represents a message in a DM channel
|
|
1189
|
+
*/
|
|
1190
|
+
export interface Message {
|
|
1191
|
+
/**
|
|
1192
|
+
* The unique identifier for the entity
|
|
1193
|
+
*/
|
|
1194
|
+
id: string;
|
|
1195
|
+
/**
|
|
1196
|
+
* The content of the message in Markdown format
|
|
1197
|
+
*/
|
|
1198
|
+
content: string | null;
|
|
1199
|
+
/**
|
|
1200
|
+
* The timestamp when the post was created
|
|
1201
|
+
*/
|
|
1202
|
+
created_at: string;
|
|
1203
|
+
/**
|
|
1204
|
+
* Whether the message has been edited
|
|
1205
|
+
*/
|
|
1206
|
+
is_edited: boolean;
|
|
1207
|
+
/**
|
|
1208
|
+
* Whether this message is pinned
|
|
1209
|
+
*/
|
|
1210
|
+
is_pinned: boolean;
|
|
1211
|
+
/**
|
|
1212
|
+
* The type of post
|
|
1213
|
+
*/
|
|
1214
|
+
message_type: DmsPostTypes;
|
|
1215
|
+
/**
|
|
1216
|
+
* The poll for this message
|
|
1217
|
+
*/
|
|
1218
|
+
poll: Message.Poll | null;
|
|
1219
|
+
/**
|
|
1220
|
+
* The reaction counts for this message
|
|
1221
|
+
*/
|
|
1222
|
+
poll_votes: Array<Message.PollVote>;
|
|
1223
|
+
/**
|
|
1224
|
+
* The reaction counts for this message
|
|
1225
|
+
*/
|
|
1226
|
+
reaction_counts: Array<Message.ReactionCount>;
|
|
1227
|
+
/**
|
|
1228
|
+
* The ID of the message this is replying to, if applicable
|
|
1229
|
+
*/
|
|
1230
|
+
replying_to_message_id: string | null;
|
|
1231
|
+
/**
|
|
1232
|
+
* The timestamp when the post was last updated
|
|
1233
|
+
*/
|
|
1234
|
+
updated_at: string;
|
|
1235
|
+
/**
|
|
1236
|
+
* The user who sent this message
|
|
1237
|
+
*/
|
|
1238
|
+
user: Message.User;
|
|
1239
|
+
/**
|
|
1240
|
+
* The number of times this message has been viewed
|
|
1241
|
+
*/
|
|
1242
|
+
view_count: number | null;
|
|
1243
|
+
}
|
|
1244
|
+
export declare namespace Message {
|
|
1245
|
+
/**
|
|
1246
|
+
* The poll for this message
|
|
1247
|
+
*/
|
|
1248
|
+
interface Poll {
|
|
1249
|
+
/**
|
|
1250
|
+
* The options for the poll
|
|
1251
|
+
*/
|
|
1252
|
+
options: Array<Poll.Option> | null;
|
|
1253
|
+
}
|
|
1254
|
+
namespace Poll {
|
|
1255
|
+
/**
|
|
1256
|
+
* Represents a single poll option
|
|
1257
|
+
*/
|
|
1258
|
+
interface Option {
|
|
1259
|
+
/**
|
|
1260
|
+
* The ID of the poll option
|
|
1261
|
+
*/
|
|
1262
|
+
id: string;
|
|
1263
|
+
/**
|
|
1264
|
+
* The text of the poll option
|
|
1265
|
+
*/
|
|
1266
|
+
text: string;
|
|
1267
|
+
}
|
|
1268
|
+
}
|
|
1269
|
+
/**
|
|
1270
|
+
* Represents a reaction count for a feed post
|
|
1271
|
+
*/
|
|
1272
|
+
interface PollVote {
|
|
1273
|
+
/**
|
|
1274
|
+
* The number of users who reacted
|
|
1275
|
+
*/
|
|
1276
|
+
count: number;
|
|
1277
|
+
/**
|
|
1278
|
+
* The reaction that was used
|
|
1279
|
+
*/
|
|
1280
|
+
option_id: string | null;
|
|
1281
|
+
}
|
|
1282
|
+
/**
|
|
1283
|
+
* Represents a reaction count for a feed post
|
|
1284
|
+
*/
|
|
1285
|
+
interface ReactionCount {
|
|
1286
|
+
/**
|
|
1287
|
+
* The number of users who reacted
|
|
1288
|
+
*/
|
|
1289
|
+
count: number;
|
|
1290
|
+
/**
|
|
1291
|
+
* The emoji that was used in shortcode format (:heart:)
|
|
1292
|
+
*/
|
|
1293
|
+
emoji: string | null;
|
|
1294
|
+
}
|
|
1295
|
+
/**
|
|
1296
|
+
* The user who sent this message
|
|
1297
|
+
*/
|
|
1298
|
+
interface User {
|
|
1299
|
+
/**
|
|
1300
|
+
* The internal ID of the user.
|
|
1301
|
+
*/
|
|
1302
|
+
id: string;
|
|
1303
|
+
/**
|
|
1304
|
+
* The name of the user from their Whop account.
|
|
1305
|
+
*/
|
|
1306
|
+
name: string | null;
|
|
1307
|
+
/**
|
|
1308
|
+
* The username of the user from their Whop account.
|
|
1309
|
+
*/
|
|
1310
|
+
username: string;
|
|
1311
|
+
}
|
|
1312
|
+
}
|
|
1313
|
+
/**
|
|
1314
|
+
* Information about pagination in a connection.
|
|
1315
|
+
*/
|
|
1316
|
+
export interface PageInfo {
|
|
1317
|
+
/**
|
|
1318
|
+
* When paginating forwards, the cursor to continue.
|
|
1319
|
+
*/
|
|
1320
|
+
end_cursor: string | null;
|
|
1321
|
+
/**
|
|
1322
|
+
* When paginating forwards, are there more items?
|
|
1323
|
+
*/
|
|
1324
|
+
has_next_page: boolean;
|
|
1325
|
+
/**
|
|
1326
|
+
* When paginating backwards, are there more items?
|
|
1327
|
+
*/
|
|
1328
|
+
has_previous_page: boolean;
|
|
1329
|
+
/**
|
|
1330
|
+
* When paginating backwards, the cursor to continue.
|
|
1331
|
+
*/
|
|
1332
|
+
start_cursor: string | null;
|
|
1333
|
+
}
|
|
1334
|
+
/**
|
|
1335
|
+
* An object representing a receipt for a membership.
|
|
1336
|
+
*/
|
|
1337
|
+
export interface Payment {
|
|
1338
|
+
/**
|
|
1339
|
+
* The payment ID
|
|
1340
|
+
*/
|
|
1341
|
+
id: string;
|
|
1342
|
+
/**
|
|
1343
|
+
* How much the payment is for after fees
|
|
1344
|
+
*/
|
|
1345
|
+
amount_after_fees: number;
|
|
1346
|
+
/**
|
|
1347
|
+
* Whether this payment was auto refunded or not
|
|
1348
|
+
*/
|
|
1349
|
+
auto_refunded: boolean;
|
|
1350
|
+
/**
|
|
1351
|
+
* The address of the user who made the payment.
|
|
1352
|
+
*/
|
|
1353
|
+
billing_address: Payment.BillingAddress | null;
|
|
1354
|
+
/**
|
|
1355
|
+
* The billing reason
|
|
1356
|
+
*/
|
|
1357
|
+
billing_reason: string | null;
|
|
1358
|
+
/**
|
|
1359
|
+
* The type of card used as the payment method.
|
|
1360
|
+
*/
|
|
1361
|
+
card_brand: string | null;
|
|
1362
|
+
/**
|
|
1363
|
+
* The last 4 digits of the card used to make the payment.
|
|
1364
|
+
*/
|
|
1365
|
+
card_last4: string | null;
|
|
1366
|
+
/**
|
|
1367
|
+
* The company for the payment.
|
|
1368
|
+
*/
|
|
1369
|
+
company: Payment.Company | null;
|
|
1370
|
+
/**
|
|
1371
|
+
* The datetime the payment was created
|
|
1372
|
+
*/
|
|
1373
|
+
created_at: string;
|
|
1374
|
+
/**
|
|
1375
|
+
* The available currencies on the platform
|
|
1376
|
+
*/
|
|
1377
|
+
currency: Currency | null;
|
|
1378
|
+
/**
|
|
1379
|
+
* When an alert came in that this transaction will be disputed
|
|
1380
|
+
*/
|
|
1381
|
+
dispute_alerted_at: string | null;
|
|
1382
|
+
/**
|
|
1383
|
+
* If the payment failed, the reason for the failure.
|
|
1384
|
+
*/
|
|
1385
|
+
failure_message: string | null;
|
|
1386
|
+
/**
|
|
1387
|
+
* The time of the last payment attempt.
|
|
1388
|
+
*/
|
|
1389
|
+
last_payment_attempt: string | null;
|
|
1390
|
+
/**
|
|
1391
|
+
* The member attached to this payment.
|
|
1392
|
+
*/
|
|
1393
|
+
member: Payment.Member | null;
|
|
1394
|
+
/**
|
|
1395
|
+
* The membership attached to this payment.
|
|
1396
|
+
*/
|
|
1397
|
+
membership: Payment.Membership | null;
|
|
1398
|
+
/**
|
|
1399
|
+
* The datetime the payment was paid
|
|
1400
|
+
*/
|
|
1401
|
+
paid_at: string | null;
|
|
1402
|
+
/**
|
|
1403
|
+
* Returns the type of payment method used for the payment, if available. Ex.
|
|
1404
|
+
* klarna, affirm, card, cashapp
|
|
1405
|
+
*/
|
|
1406
|
+
payment_method_type: string | null;
|
|
1407
|
+
/**
|
|
1408
|
+
* The plan attached to this payment.
|
|
1409
|
+
*/
|
|
1410
|
+
plan: Payment.Plan | null;
|
|
1411
|
+
/**
|
|
1412
|
+
* The access pass attached to this payment.
|
|
1413
|
+
*/
|
|
1414
|
+
product: Payment.Product | null;
|
|
1415
|
+
/**
|
|
1416
|
+
* The promo code used for this payment.
|
|
1417
|
+
*/
|
|
1418
|
+
promo_code: Payment.PromoCode | null;
|
|
1419
|
+
/**
|
|
1420
|
+
* Whether the payment can be refunded.
|
|
1421
|
+
*/
|
|
1422
|
+
refundable: boolean;
|
|
1423
|
+
/**
|
|
1424
|
+
* The payment refund amount(if applicable).
|
|
1425
|
+
*/
|
|
1426
|
+
refunded_amount: number | null;
|
|
1427
|
+
/**
|
|
1428
|
+
* When the payment was refunded (if applicable).
|
|
1429
|
+
*/
|
|
1430
|
+
refunded_at: string | null;
|
|
1431
|
+
/**
|
|
1432
|
+
* Whether the payment can be retried.
|
|
1433
|
+
*/
|
|
1434
|
+
retryable: boolean;
|
|
1435
|
+
/**
|
|
1436
|
+
* The status of a receipt
|
|
1437
|
+
*/
|
|
1438
|
+
status: ReceiptStatus | null;
|
|
1439
|
+
/**
|
|
1440
|
+
* The friendly status of the payment.
|
|
1441
|
+
*/
|
|
1442
|
+
substatus: FriendlyReceiptStatus;
|
|
1443
|
+
/**
|
|
1444
|
+
* The subtotal to show to the creator (excluding buyer fees).
|
|
1445
|
+
*/
|
|
1446
|
+
subtotal: number | null;
|
|
1447
|
+
/**
|
|
1448
|
+
* The total to show to the creator (excluding buyer fees).
|
|
1449
|
+
*/
|
|
1450
|
+
total: number | null;
|
|
1451
|
+
/**
|
|
1452
|
+
* The total in USD to show to the creator (excluding buyer fees).
|
|
1453
|
+
*/
|
|
1454
|
+
usd_total: number | null;
|
|
1455
|
+
/**
|
|
1456
|
+
* The user that made this payment.
|
|
1457
|
+
*/
|
|
1458
|
+
user: Payment.User | null;
|
|
1459
|
+
/**
|
|
1460
|
+
* Whether the payment can be voided.
|
|
1461
|
+
*/
|
|
1462
|
+
voidable: boolean;
|
|
1463
|
+
}
|
|
1464
|
+
export declare namespace Payment {
|
|
1465
|
+
/**
|
|
1466
|
+
* The address of the user who made the payment.
|
|
1467
|
+
*/
|
|
1468
|
+
interface BillingAddress {
|
|
1469
|
+
/**
|
|
1470
|
+
* The city of the address.
|
|
1471
|
+
*/
|
|
1472
|
+
city: string | null;
|
|
1473
|
+
/**
|
|
1474
|
+
* The country of the address.
|
|
1475
|
+
*/
|
|
1476
|
+
country: string | null;
|
|
1477
|
+
/**
|
|
1478
|
+
* The line 1 of the address.
|
|
1479
|
+
*/
|
|
1480
|
+
line1: string | null;
|
|
1481
|
+
/**
|
|
1482
|
+
* The line 2 of the address.
|
|
1483
|
+
*/
|
|
1484
|
+
line2: string | null;
|
|
1485
|
+
/**
|
|
1486
|
+
* The name of the customer.
|
|
1487
|
+
*/
|
|
1488
|
+
name: string | null;
|
|
1489
|
+
/**
|
|
1490
|
+
* The postal code of the address.
|
|
1491
|
+
*/
|
|
1492
|
+
postal_code: string | null;
|
|
1493
|
+
/**
|
|
1494
|
+
* The state of the address.
|
|
1495
|
+
*/
|
|
1496
|
+
state: string | null;
|
|
1497
|
+
}
|
|
1498
|
+
/**
|
|
1499
|
+
* The company for the payment.
|
|
1500
|
+
*/
|
|
1501
|
+
interface Company {
|
|
1502
|
+
/**
|
|
1503
|
+
* The ID of the company
|
|
1504
|
+
*/
|
|
1505
|
+
id: string;
|
|
1506
|
+
/**
|
|
1507
|
+
* The slug/route of the company on the Whop site.
|
|
1508
|
+
*/
|
|
1509
|
+
route: string;
|
|
1510
|
+
/**
|
|
1511
|
+
* The written name of the company.
|
|
1512
|
+
*/
|
|
1513
|
+
title: string;
|
|
1514
|
+
}
|
|
1515
|
+
/**
|
|
1516
|
+
* The member attached to this payment.
|
|
1517
|
+
*/
|
|
1518
|
+
interface Member {
|
|
1519
|
+
/**
|
|
1520
|
+
* The ID of the member
|
|
1521
|
+
*/
|
|
1522
|
+
id: string;
|
|
1523
|
+
/**
|
|
1524
|
+
* The phone number for the member, if available.
|
|
1525
|
+
*/
|
|
1526
|
+
phone: string | null;
|
|
1527
|
+
}
|
|
1528
|
+
/**
|
|
1529
|
+
* The membership attached to this payment.
|
|
1530
|
+
*/
|
|
1531
|
+
interface Membership {
|
|
1532
|
+
/**
|
|
1533
|
+
* The internal ID of the membership.
|
|
1534
|
+
*/
|
|
1535
|
+
id: string;
|
|
1536
|
+
/**
|
|
1537
|
+
* The state of the membership.
|
|
1538
|
+
*/
|
|
1539
|
+
status: Shared.MembershipStatus;
|
|
1540
|
+
}
|
|
1541
|
+
/**
|
|
1542
|
+
* The plan attached to this payment.
|
|
1543
|
+
*/
|
|
1544
|
+
interface Plan {
|
|
1545
|
+
/**
|
|
1546
|
+
* The internal ID of the plan.
|
|
1547
|
+
*/
|
|
1548
|
+
id: string;
|
|
1549
|
+
}
|
|
1550
|
+
/**
|
|
1551
|
+
* The access pass attached to this payment.
|
|
1552
|
+
*/
|
|
1553
|
+
interface Product {
|
|
1554
|
+
/**
|
|
1555
|
+
* The internal ID of the public product.
|
|
1556
|
+
*/
|
|
1557
|
+
id: string;
|
|
1558
|
+
/**
|
|
1559
|
+
* The route of the product.
|
|
1560
|
+
*/
|
|
1561
|
+
route: string;
|
|
1562
|
+
/**
|
|
1563
|
+
* The title of the product. Use for Whop 4.0.
|
|
1564
|
+
*/
|
|
1565
|
+
title: string;
|
|
1566
|
+
}
|
|
1567
|
+
/**
|
|
1568
|
+
* The promo code used for this payment.
|
|
1569
|
+
*/
|
|
1570
|
+
interface PromoCode {
|
|
1571
|
+
/**
|
|
1572
|
+
* The ID of the promo.
|
|
1573
|
+
*/
|
|
1574
|
+
id: string;
|
|
1575
|
+
/**
|
|
1576
|
+
* The amount off (% or flat amount) for the promo.
|
|
1577
|
+
*/
|
|
1578
|
+
amount_off: number;
|
|
1579
|
+
/**
|
|
1580
|
+
* The monetary currency of the promo code.
|
|
1581
|
+
*/
|
|
1582
|
+
base_currency: Shared.Currency;
|
|
1583
|
+
/**
|
|
1584
|
+
* The specific code used to apply the promo at checkout.
|
|
1585
|
+
*/
|
|
1586
|
+
code: string | null;
|
|
1587
|
+
/**
|
|
1588
|
+
* The number of billing cycles the promo is applied for.
|
|
1589
|
+
*/
|
|
1590
|
+
number_of_intervals: number | null;
|
|
1591
|
+
/**
|
|
1592
|
+
* The type (% or flat amount) of the promo.
|
|
1593
|
+
*/
|
|
1594
|
+
promo_type: Shared.PromoType;
|
|
1595
|
+
}
|
|
1596
|
+
/**
|
|
1597
|
+
* The user that made this payment.
|
|
1598
|
+
*/
|
|
1599
|
+
interface User {
|
|
1600
|
+
/**
|
|
1601
|
+
* The internal ID of the user.
|
|
1602
|
+
*/
|
|
1603
|
+
id: string;
|
|
1604
|
+
/**
|
|
1605
|
+
* The email of the user
|
|
1606
|
+
*/
|
|
1607
|
+
email: string | null;
|
|
1608
|
+
/**
|
|
1609
|
+
* The name of the user from their Whop account.
|
|
1610
|
+
*/
|
|
1611
|
+
name: string | null;
|
|
1612
|
+
/**
|
|
1613
|
+
* The username of the user from their Whop account.
|
|
1614
|
+
*/
|
|
1615
|
+
username: string;
|
|
1616
|
+
}
|
|
1617
|
+
}
|
|
1618
|
+
/**
|
|
1619
|
+
* An object representing a (sanitized) plan of an access pass.
|
|
1620
|
+
*/
|
|
1621
|
+
export interface Plan {
|
|
1622
|
+
/**
|
|
1623
|
+
* The internal ID of the plan.
|
|
1624
|
+
*/
|
|
1625
|
+
id: string;
|
|
1626
|
+
/**
|
|
1627
|
+
* The interval at which the plan charges (renewal plans).
|
|
1628
|
+
*/
|
|
1629
|
+
billing_period: number | null;
|
|
1630
|
+
/**
|
|
1631
|
+
* Whether or not the plan collects tax.
|
|
1632
|
+
*/
|
|
1633
|
+
collect_tax: boolean;
|
|
1634
|
+
/**
|
|
1635
|
+
* The company for the plan.
|
|
1636
|
+
*/
|
|
1637
|
+
company: Plan.Company | null;
|
|
1638
|
+
/**
|
|
1639
|
+
* When the plan was created.
|
|
1640
|
+
*/
|
|
1641
|
+
created_at: string;
|
|
1642
|
+
/**
|
|
1643
|
+
* The respective currency identifier for the plan.
|
|
1644
|
+
*/
|
|
1645
|
+
currency: Currency;
|
|
1646
|
+
/**
|
|
1647
|
+
* The custom fields for the plan.
|
|
1648
|
+
*/
|
|
1649
|
+
custom_fields: Array<Plan.CustomField>;
|
|
1650
|
+
/**
|
|
1651
|
+
* The description of the plan.
|
|
1652
|
+
*/
|
|
1653
|
+
description: string | null;
|
|
1654
|
+
/**
|
|
1655
|
+
* The interval at which the plan charges (expiration plans).
|
|
1656
|
+
*/
|
|
1657
|
+
expiration_days: number | null;
|
|
1658
|
+
/**
|
|
1659
|
+
* The price a person has to pay for a plan on the initial purchase.
|
|
1660
|
+
*/
|
|
1661
|
+
initial_price: number;
|
|
1662
|
+
/**
|
|
1663
|
+
* A personal description or notes section for the business.
|
|
1664
|
+
*/
|
|
1665
|
+
internal_notes: string | null;
|
|
1666
|
+
/**
|
|
1667
|
+
* The invoice associated with this plan.
|
|
1668
|
+
*/
|
|
1669
|
+
invoice: Plan.Invoice | null;
|
|
1670
|
+
/**
|
|
1671
|
+
* The number of members for the plan.
|
|
1672
|
+
*/
|
|
1673
|
+
member_count: number | null;
|
|
1674
|
+
/**
|
|
1675
|
+
* Indicates if the plan is a one time payment or recurring.
|
|
1676
|
+
*/
|
|
1677
|
+
plan_type: PlanType;
|
|
1678
|
+
/**
|
|
1679
|
+
* The access pass for the plan.
|
|
1680
|
+
*/
|
|
1681
|
+
product: Plan.Product | null;
|
|
1682
|
+
/**
|
|
1683
|
+
* The direct link to purchase the product.
|
|
1684
|
+
*/
|
|
1685
|
+
purchase_url: string;
|
|
1686
|
+
/**
|
|
1687
|
+
* This is the release method the business uses to sell this plan.
|
|
1688
|
+
*/
|
|
1689
|
+
release_method: ReleaseMethod;
|
|
1690
|
+
/**
|
|
1691
|
+
* The price a person has to pay for a plan on the renewal purchase.
|
|
1692
|
+
*/
|
|
1693
|
+
renewal_price: number;
|
|
1694
|
+
/**
|
|
1695
|
+
* The tax type for the plan.
|
|
1696
|
+
*/
|
|
1697
|
+
tax_type: TaxType;
|
|
1698
|
+
/**
|
|
1699
|
+
* The number of free trial days added before a renewal plan.
|
|
1700
|
+
*/
|
|
1701
|
+
trial_period_days: number | null;
|
|
1702
|
+
/**
|
|
1703
|
+
* When the plan was last updated.
|
|
1704
|
+
*/
|
|
1705
|
+
updated_at: string;
|
|
1706
|
+
/**
|
|
1707
|
+
* Shows or hides the plan from public/business view.
|
|
1708
|
+
*/
|
|
1709
|
+
visibility: Visibility;
|
|
1710
|
+
}
|
|
1711
|
+
export declare namespace Plan {
|
|
1712
|
+
/**
|
|
1713
|
+
* The company for the plan.
|
|
1714
|
+
*/
|
|
1715
|
+
interface Company {
|
|
1716
|
+
/**
|
|
1717
|
+
* The ID (tag) of the company.
|
|
1718
|
+
*/
|
|
1719
|
+
id: string;
|
|
1720
|
+
/**
|
|
1721
|
+
* The title of the company.
|
|
1722
|
+
*/
|
|
1723
|
+
title: string;
|
|
1724
|
+
}
|
|
1725
|
+
/**
|
|
1726
|
+
* An object representing a custom field for a plan.
|
|
1727
|
+
*/
|
|
1728
|
+
interface CustomField {
|
|
1729
|
+
/**
|
|
1730
|
+
* The internal ID of the given custom field
|
|
1731
|
+
*/
|
|
1732
|
+
id: string;
|
|
1733
|
+
/**
|
|
1734
|
+
* What type of input field to use.
|
|
1735
|
+
*/
|
|
1736
|
+
field_type: 'text';
|
|
1737
|
+
/**
|
|
1738
|
+
* The title/header of the custom field.
|
|
1739
|
+
*/
|
|
1740
|
+
name: string;
|
|
1741
|
+
/**
|
|
1742
|
+
* How the custom field should be ordered when rendered on the checkout page.
|
|
1743
|
+
*/
|
|
1744
|
+
order: number | null;
|
|
1745
|
+
/**
|
|
1746
|
+
* An example response displayed in the input field.
|
|
1747
|
+
*/
|
|
1748
|
+
placeholder: string | null;
|
|
1749
|
+
/**
|
|
1750
|
+
* Whether or not the custom field is required.
|
|
1751
|
+
*/
|
|
1752
|
+
required: boolean;
|
|
1753
|
+
}
|
|
1754
|
+
/**
|
|
1755
|
+
* The invoice associated with this plan.
|
|
1756
|
+
*/
|
|
1757
|
+
interface Invoice {
|
|
1758
|
+
/**
|
|
1759
|
+
* The ID of the invoice.
|
|
1760
|
+
*/
|
|
1761
|
+
id: string;
|
|
1762
|
+
}
|
|
1763
|
+
/**
|
|
1764
|
+
* The access pass for the plan.
|
|
1765
|
+
*/
|
|
1766
|
+
interface Product {
|
|
1767
|
+
/**
|
|
1768
|
+
* The internal ID of the public product.
|
|
1769
|
+
*/
|
|
1770
|
+
id: string;
|
|
1771
|
+
/**
|
|
1772
|
+
* The title of the product. Use for Whop 4.0.
|
|
1773
|
+
*/
|
|
1774
|
+
title: string;
|
|
1775
|
+
}
|
|
1776
|
+
}
|
|
1777
|
+
/**
|
|
1778
|
+
* The type of plan that can be attached to an access pass
|
|
1779
|
+
*/
|
|
1780
|
+
export type PlanType = 'renewal' | 'one_time';
|
|
1781
|
+
/**
|
|
1782
|
+
* An object representing a (sanitized) access pass.
|
|
1783
|
+
*/
|
|
1784
|
+
export interface Product {
|
|
1785
|
+
/**
|
|
1786
|
+
* The internal ID of the public product.
|
|
1787
|
+
*/
|
|
1788
|
+
id: string;
|
|
1789
|
+
/**
|
|
1790
|
+
* The different business types a company can be.
|
|
1791
|
+
*/
|
|
1792
|
+
business_type: BusinessTypes | null;
|
|
1793
|
+
/**
|
|
1794
|
+
* A short type of the company that this product belongs to.
|
|
1795
|
+
*/
|
|
1796
|
+
company: Product.Company;
|
|
1797
|
+
/**
|
|
1798
|
+
* When the product was created.
|
|
1799
|
+
*/
|
|
1800
|
+
created_at: string;
|
|
1801
|
+
/**
|
|
1802
|
+
* The custom call to action for the product.
|
|
1803
|
+
*/
|
|
1804
|
+
custom_cta: CustomCta;
|
|
1805
|
+
/**
|
|
1806
|
+
* The custom call to action URL for the product, if any.
|
|
1807
|
+
*/
|
|
1808
|
+
custom_cta_url: string | null;
|
|
1809
|
+
/**
|
|
1810
|
+
* The custom statement descriptor for the product.
|
|
1811
|
+
*/
|
|
1812
|
+
custom_statement_descriptor: string | null;
|
|
1813
|
+
/**
|
|
1814
|
+
* A short description of what the company offers or does.
|
|
1815
|
+
*/
|
|
1816
|
+
description: string | null;
|
|
1817
|
+
/**
|
|
1818
|
+
* The percentage of a transaction a user is eligible to earn from the whop
|
|
1819
|
+
* marketplace global affiliate program.
|
|
1820
|
+
*/
|
|
1821
|
+
global_affiliate_percentage: number | null;
|
|
1822
|
+
/**
|
|
1823
|
+
* The status of the global affiliate program for this product.
|
|
1824
|
+
*/
|
|
1825
|
+
global_affiliate_status: GlobalAffiliateStatus;
|
|
1826
|
+
/**
|
|
1827
|
+
* The headline of the product.
|
|
1828
|
+
*/
|
|
1829
|
+
headline: string | null;
|
|
1830
|
+
/**
|
|
1831
|
+
* The different industry types a company can be in.
|
|
1832
|
+
*/
|
|
1833
|
+
industry_type: IndustryTypes | null;
|
|
1834
|
+
/**
|
|
1835
|
+
* The percentage of a transaction a user is eligible to earn from the whop
|
|
1836
|
+
* marketplace member affiliate program.
|
|
1837
|
+
*/
|
|
1838
|
+
member_affiliate_percentage: number | null;
|
|
1839
|
+
/**
|
|
1840
|
+
* The status of the member affiliate program for this product.
|
|
1841
|
+
*/
|
|
1842
|
+
member_affiliate_status: GlobalAffiliateStatus;
|
|
1843
|
+
/**
|
|
1844
|
+
* The number of active users for this product.
|
|
1845
|
+
*/
|
|
1846
|
+
member_count: number;
|
|
1847
|
+
/**
|
|
1848
|
+
* The user that owns the product (company owner).
|
|
1849
|
+
*/
|
|
1850
|
+
owner_user: Product.OwnerUser;
|
|
1851
|
+
/**
|
|
1852
|
+
* The product tax code for the product, if any.
|
|
1853
|
+
*/
|
|
1854
|
+
product_tax_code: Product.ProductTaxCode | null;
|
|
1855
|
+
/**
|
|
1856
|
+
* The number of reviews that have been published for the product.
|
|
1857
|
+
*/
|
|
1858
|
+
published_reviews_count: number;
|
|
1859
|
+
/**
|
|
1860
|
+
* The route of the product.
|
|
1861
|
+
*/
|
|
1862
|
+
route: string;
|
|
1863
|
+
/**
|
|
1864
|
+
* The title of the product. Use for Whop 4.0.
|
|
1865
|
+
*/
|
|
1866
|
+
title: string;
|
|
1867
|
+
/**
|
|
1868
|
+
* When the product was updated.
|
|
1869
|
+
*/
|
|
1870
|
+
updated_at: string;
|
|
1871
|
+
/**
|
|
1872
|
+
* Whether this product is Whop verified.
|
|
1873
|
+
*/
|
|
1874
|
+
verified: boolean;
|
|
1875
|
+
/**
|
|
1876
|
+
* This product will/will not be displayed publicly.
|
|
1877
|
+
*/
|
|
1878
|
+
visibility: Visibility;
|
|
1879
|
+
}
|
|
1880
|
+
export declare namespace Product {
|
|
1881
|
+
/**
|
|
1882
|
+
* A short type of the company that this product belongs to.
|
|
1883
|
+
*/
|
|
1884
|
+
interface Company {
|
|
1885
|
+
/**
|
|
1886
|
+
* The ID (tag) of the company.
|
|
1887
|
+
*/
|
|
1888
|
+
id: string;
|
|
1889
|
+
/**
|
|
1890
|
+
* The slug/route of the company on the Whop site.
|
|
1891
|
+
*/
|
|
1892
|
+
route: string;
|
|
1893
|
+
/**
|
|
1894
|
+
* The title of the company.
|
|
1895
|
+
*/
|
|
1896
|
+
title: string;
|
|
1897
|
+
}
|
|
1898
|
+
/**
|
|
1899
|
+
* The user that owns the product (company owner).
|
|
1900
|
+
*/
|
|
1901
|
+
interface OwnerUser {
|
|
1902
|
+
/**
|
|
1903
|
+
* The internal ID of the user.
|
|
1904
|
+
*/
|
|
1905
|
+
id: string;
|
|
1906
|
+
/**
|
|
1907
|
+
* The name of the user from their Whop account.
|
|
1908
|
+
*/
|
|
1909
|
+
name: string | null;
|
|
1910
|
+
/**
|
|
1911
|
+
* The username of the user from their Whop account.
|
|
1912
|
+
*/
|
|
1913
|
+
username: string;
|
|
1914
|
+
}
|
|
1915
|
+
/**
|
|
1916
|
+
* The product tax code for the product, if any.
|
|
1917
|
+
*/
|
|
1918
|
+
interface ProductTaxCode {
|
|
1919
|
+
/**
|
|
1920
|
+
* The internal ID of the product tax code.
|
|
1921
|
+
*/
|
|
1922
|
+
id: string;
|
|
1923
|
+
/**
|
|
1924
|
+
* The name of the product tax code.
|
|
1925
|
+
*/
|
|
1926
|
+
name: string;
|
|
1927
|
+
/**
|
|
1928
|
+
* The type of product this tax code applies to.
|
|
1929
|
+
*/
|
|
1930
|
+
product_type: 'physical' | 'digital' | 'services';
|
|
1931
|
+
}
|
|
1932
|
+
}
|
|
1933
|
+
/**
|
|
1934
|
+
* An object representing a (sanitized) access pass.
|
|
1935
|
+
*/
|
|
1936
|
+
export interface ProductListItem {
|
|
1937
|
+
/**
|
|
1938
|
+
* The internal ID of the public product.
|
|
1939
|
+
*/
|
|
1940
|
+
id: string;
|
|
1941
|
+
/**
|
|
1942
|
+
* The different business types a company can be.
|
|
1943
|
+
*/
|
|
1944
|
+
business_type: BusinessTypes | null;
|
|
1945
|
+
/**
|
|
1946
|
+
* When the product was created.
|
|
1947
|
+
*/
|
|
1948
|
+
created_at: string;
|
|
1949
|
+
/**
|
|
1950
|
+
* The headline of the product.
|
|
1951
|
+
*/
|
|
1952
|
+
headline: string | null;
|
|
1953
|
+
/**
|
|
1954
|
+
* The different industry types a company can be in.
|
|
1955
|
+
*/
|
|
1956
|
+
industry_type: IndustryTypes | null;
|
|
1957
|
+
/**
|
|
1958
|
+
* The number of active users for this product.
|
|
1959
|
+
*/
|
|
1960
|
+
member_count: number;
|
|
1961
|
+
/**
|
|
1962
|
+
* The number of reviews that have been published for the product.
|
|
1963
|
+
*/
|
|
1964
|
+
published_reviews_count: number;
|
|
1965
|
+
/**
|
|
1966
|
+
* The route of the product.
|
|
1967
|
+
*/
|
|
1968
|
+
route: string;
|
|
1969
|
+
/**
|
|
1970
|
+
* The title of the product. Use for Whop 4.0.
|
|
1971
|
+
*/
|
|
1972
|
+
title: string;
|
|
1973
|
+
/**
|
|
1974
|
+
* When the product was updated.
|
|
1975
|
+
*/
|
|
1976
|
+
updated_at: string;
|
|
1977
|
+
/**
|
|
1978
|
+
* Whether this product is Whop verified.
|
|
1979
|
+
*/
|
|
1980
|
+
verified: boolean;
|
|
1981
|
+
/**
|
|
1982
|
+
* This product will/will not be displayed publicly.
|
|
1983
|
+
*/
|
|
1984
|
+
visibility: Visibility;
|
|
1985
|
+
}
|
|
1986
|
+
/**
|
|
1987
|
+
* The type of promo code used to discount a plan
|
|
1988
|
+
*/
|
|
1989
|
+
export type PromoType = 'percentage' | 'flat_amount';
|
|
1990
|
+
/**
|
|
1991
|
+
* Represents a reaction to a feed post
|
|
1992
|
+
*/
|
|
1993
|
+
export interface Reaction {
|
|
1994
|
+
/**
|
|
1995
|
+
* The unique identifier for the entity
|
|
1996
|
+
*/
|
|
1997
|
+
id: string;
|
|
1998
|
+
/**
|
|
1999
|
+
* The emoji that was used in shortcode format (:heart:)
|
|
2000
|
+
*/
|
|
2001
|
+
emoji: string | null;
|
|
2002
|
+
/**
|
|
2003
|
+
* The ID of the post this reaction belongs to
|
|
2004
|
+
*/
|
|
2005
|
+
resource_id: string;
|
|
2006
|
+
/**
|
|
2007
|
+
* The user who reacted to the post
|
|
2008
|
+
*/
|
|
2009
|
+
user: Reaction.User;
|
|
2010
|
+
}
|
|
2011
|
+
export declare namespace Reaction {
|
|
2012
|
+
/**
|
|
2013
|
+
* The user who reacted to the post
|
|
2014
|
+
*/
|
|
2015
|
+
interface User {
|
|
2016
|
+
/**
|
|
2017
|
+
* The internal ID of the user.
|
|
2018
|
+
*/
|
|
2019
|
+
id: string;
|
|
2020
|
+
/**
|
|
2021
|
+
* The name of the user from their Whop account.
|
|
2022
|
+
*/
|
|
2023
|
+
name: string | null;
|
|
2024
|
+
/**
|
|
2025
|
+
* The username of the user from their Whop account.
|
|
2026
|
+
*/
|
|
2027
|
+
username: string;
|
|
2028
|
+
}
|
|
2029
|
+
}
|
|
2030
|
+
/**
|
|
2031
|
+
* The status of a receipt
|
|
2032
|
+
*/
|
|
2033
|
+
export type ReceiptStatus = 'draft' | 'open' | 'paid' | 'pending' | 'uncollectible' | 'unresolved' | 'void';
|
|
2034
|
+
/**
|
|
2035
|
+
* The methods of how a plan can be released.
|
|
2036
|
+
*/
|
|
2037
|
+
export type ReleaseMethod = 'buy_now' | 'waitlist';
|
|
2038
|
+
/**
|
|
2039
|
+
* A shipment
|
|
2040
|
+
*/
|
|
2041
|
+
export interface Shipment {
|
|
2042
|
+
/**
|
|
2043
|
+
* The ID of the shipment
|
|
2044
|
+
*/
|
|
2045
|
+
id: string;
|
|
2046
|
+
/**
|
|
2047
|
+
* The carrier of the shipment
|
|
2048
|
+
*/
|
|
2049
|
+
carrier: ShipmentCarrier;
|
|
2050
|
+
/**
|
|
2051
|
+
* The date and time the shipment was created
|
|
2052
|
+
*/
|
|
2053
|
+
created_at: string;
|
|
2054
|
+
/**
|
|
2055
|
+
* The delivery estimate of the shipment
|
|
2056
|
+
*/
|
|
2057
|
+
delivery_estimate: string | null;
|
|
2058
|
+
/**
|
|
2059
|
+
* The payment of the shipment
|
|
2060
|
+
*/
|
|
2061
|
+
payment: Shipment.Payment;
|
|
2062
|
+
/**
|
|
2063
|
+
* The service of the shipment
|
|
2064
|
+
*/
|
|
2065
|
+
service: string | null;
|
|
2066
|
+
/**
|
|
2067
|
+
* The status of the shipment
|
|
2068
|
+
*/
|
|
2069
|
+
status: ShipmentStatus;
|
|
2070
|
+
/**
|
|
2071
|
+
* The substatus of a shipment
|
|
2072
|
+
*/
|
|
2073
|
+
substatus: ShipmentSubstatus | null;
|
|
2074
|
+
/**
|
|
2075
|
+
* The tracking code of the shipment
|
|
2076
|
+
*/
|
|
2077
|
+
tracking_code: string;
|
|
2078
|
+
/**
|
|
2079
|
+
* The date and time the shipment was last updated
|
|
2080
|
+
*/
|
|
2081
|
+
updated_at: string;
|
|
2082
|
+
}
|
|
2083
|
+
export declare namespace Shipment {
|
|
2084
|
+
/**
|
|
2085
|
+
* The payment of the shipment
|
|
2086
|
+
*/
|
|
2087
|
+
interface Payment {
|
|
2088
|
+
/**
|
|
2089
|
+
* The payment ID
|
|
2090
|
+
*/
|
|
2091
|
+
id: string;
|
|
2092
|
+
}
|
|
2093
|
+
}
|
|
2094
|
+
/**
|
|
2095
|
+
* The carrier of a shipment
|
|
2096
|
+
*/
|
|
2097
|
+
export type ShipmentCarrier = 'accurate' | 'amazon_mws' | 'amazon_shipping' | 'apc' | 'asendia_usa' | 'australia_post' | 'axlehire_v3' | 'better_trucks' | 'canada_post' | 'canpar' | 'columbus_last_mile' | 'chronopost' | 'cloud_sort' | 'courier_express' | 'couriers_please' | 'cs_logistics' | 'dai_post' | 'deutsche_post_uk' | 'deutsche_post' | 'dhl_ecommerce_asia' | 'dhl_ecs' | 'dhl_express' | 'dhl_paket' | 'door_dash' | 'dpd_nl' | 'dpd_uk' | 'dpd' | 'epost_global' | 'estafeta' | 'evri' | 'fastway' | 'fedex_cross_border' | 'fedex_default' | 'fedex_mailview' | 'fedex_smartpost' | 'fedex' | 'first_choice' | 'first_mile' | 'flexport' | 'gio' | 'gio_express' | 'gso' | 'hailify' | 'henry' | 'interlink_express' | 'jet' | 'kuroneko_yamato' | 'la_post' | 'lasership_v2' | 'loomis_express' | 'lso' | 'ontrac' | 'optima' | 'osm_worldwide' | 'parcelforce' | 'parcll' | 'passport_global' | 'post_nl' | 'purolator' | 'quick' | 'royal_mail' | 'omni_parcel' | 'sendle' | 'sf_express' | 'smart_kargo' | 'sonic' | 'spee_dee' | 'swyft' | 'tforce' | 'uds' | 'ups_iparcel' | 'ups_mail_innovations' | 'ups' | 'usps' | 'veho' | 'yanwen';
|
|
2098
|
+
/**
|
|
2099
|
+
* The status of a shipment
|
|
2100
|
+
*/
|
|
2101
|
+
export type ShipmentStatus = 'unknown' | 'pre_transit' | 'in_transit' | 'out_for_delivery' | 'delivered' | 'available_for_pickup' | 'return_to_sender' | 'failure' | 'cancelled' | 'error';
|
|
2102
|
+
/**
|
|
2103
|
+
* The substatus of a shipment
|
|
2104
|
+
*/
|
|
2105
|
+
export type ShipmentSubstatus = 'address_correction' | 'arrived_at_destination' | 'arrived_at_facility' | 'arrived_at_pickup_location' | 'awaiting_information' | 'substatus_cancelled' | 'damaged' | 'delayed' | 'delivery_exception' | 'departed_facility' | 'departed_origin_facility' | 'expired' | 'substatus_failure' | 'held' | 'substatus_in_transit' | 'label_created' | 'lost' | 'missorted' | 'substatus_out_for_delivery' | 'received_at_destination_facility' | 'received_at_origin_facility' | 'refused' | 'return' | 'status_update' | 'transferred_to_destination_carrier' | 'transit_exception' | 'substatus_unknown' | 'weather_delay';
|
|
2106
|
+
/**
|
|
2107
|
+
* Represents a DM channel
|
|
2108
|
+
*/
|
|
2109
|
+
export interface SupportChannel {
|
|
2110
|
+
/**
|
|
2111
|
+
* The unique identifier for the entity
|
|
2112
|
+
*/
|
|
2113
|
+
id: string;
|
|
2114
|
+
/**
|
|
2115
|
+
* The bot ID if this is a support chat
|
|
2116
|
+
*/
|
|
2117
|
+
company_id: string | null;
|
|
2118
|
+
/**
|
|
2119
|
+
* The custom name of the DM channel, if any
|
|
2120
|
+
*/
|
|
2121
|
+
custom_name: string | null;
|
|
2122
|
+
/**
|
|
2123
|
+
* The customer user if this is a support chat
|
|
2124
|
+
*/
|
|
2125
|
+
customer_user: SupportChannel.CustomerUser | null;
|
|
2126
|
+
/**
|
|
2127
|
+
* When the last message was sent
|
|
2128
|
+
*/
|
|
2129
|
+
last_message_at: string | null;
|
|
2130
|
+
/**
|
|
2131
|
+
* When the support ticket was resolved (null if unresolved)
|
|
2132
|
+
*/
|
|
2133
|
+
resolved_at: string | null;
|
|
2134
|
+
}
|
|
2135
|
+
export declare namespace SupportChannel {
|
|
2136
|
+
/**
|
|
2137
|
+
* The customer user if this is a support chat
|
|
2138
|
+
*/
|
|
2139
|
+
interface CustomerUser {
|
|
2140
|
+
/**
|
|
2141
|
+
* The internal ID of the user.
|
|
2142
|
+
*/
|
|
2143
|
+
id: string;
|
|
2144
|
+
/**
|
|
2145
|
+
* The name of the user from their Whop account.
|
|
2146
|
+
*/
|
|
2147
|
+
name: string | null;
|
|
2148
|
+
/**
|
|
2149
|
+
* The username of the user from their Whop account.
|
|
2150
|
+
*/
|
|
2151
|
+
username: string;
|
|
2152
|
+
}
|
|
2153
|
+
}
|
|
2154
|
+
/**
|
|
2155
|
+
* Whether or not the tax is included in a plan's price (or if it hasn't been set
|
|
2156
|
+
* up)
|
|
2157
|
+
*/
|
|
2158
|
+
export type TaxType = 'inclusive' | 'exclusive' | 'unspecified';
|
|
2159
|
+
/**
|
|
2160
|
+
* Credit Transaction Transfer
|
|
2161
|
+
*/
|
|
2162
|
+
export interface Transfer {
|
|
2163
|
+
/**
|
|
2164
|
+
* The unique identifier of the credit transaction transfer
|
|
2165
|
+
*/
|
|
2166
|
+
id: string;
|
|
2167
|
+
/**
|
|
2168
|
+
* The amount of the credit transaction transfer
|
|
2169
|
+
*/
|
|
2170
|
+
amount: number;
|
|
2171
|
+
/**
|
|
2172
|
+
* The timestamp when the credit transaction transfer was created
|
|
2173
|
+
*/
|
|
2174
|
+
created_at: string;
|
|
2175
|
+
/**
|
|
2176
|
+
* The currency of the credit transaction transfer
|
|
2177
|
+
*/
|
|
2178
|
+
currency: Currency;
|
|
2179
|
+
/**
|
|
2180
|
+
* The recipient of the credit transaction transfer
|
|
2181
|
+
*/
|
|
2182
|
+
destination: Transfer.User | null | Transfer.Company | null;
|
|
2183
|
+
/**
|
|
2184
|
+
* The ID of the destination ledger account
|
|
2185
|
+
*/
|
|
2186
|
+
destination_ledger_account_id: string;
|
|
2187
|
+
/**
|
|
2188
|
+
* The decimal fee of the credit transaction transfer
|
|
2189
|
+
*/
|
|
2190
|
+
fee_amount: number | null;
|
|
2191
|
+
/**
|
|
2192
|
+
* The notes of the credit transaction transfer
|
|
2193
|
+
*/
|
|
2194
|
+
notes: string | null;
|
|
2195
|
+
/**
|
|
2196
|
+
* The sender of the credit transaction transfer
|
|
2197
|
+
*/
|
|
2198
|
+
origin: Transfer.User | null | Transfer.Company | null;
|
|
2199
|
+
/**
|
|
2200
|
+
* The ID of the origin ledger account
|
|
2201
|
+
*/
|
|
2202
|
+
origin_ledger_account_id: string;
|
|
2203
|
+
}
|
|
2204
|
+
export declare namespace Transfer {
|
|
2205
|
+
/**
|
|
2206
|
+
* An object representing a (sanitized) user of the site.
|
|
2207
|
+
*/
|
|
2208
|
+
interface User {
|
|
2209
|
+
/**
|
|
2210
|
+
* The internal ID of the user.
|
|
2211
|
+
*/
|
|
2212
|
+
id: string;
|
|
2213
|
+
/**
|
|
2214
|
+
* The name of the user from their Whop account.
|
|
2215
|
+
*/
|
|
2216
|
+
name: string | null;
|
|
2217
|
+
/**
|
|
2218
|
+
* The typename of this object
|
|
2219
|
+
*/
|
|
2220
|
+
typename: 'User';
|
|
2221
|
+
/**
|
|
2222
|
+
* The username of the user from their Whop account.
|
|
2223
|
+
*/
|
|
2224
|
+
username: string;
|
|
2225
|
+
}
|
|
2226
|
+
/**
|
|
2227
|
+
* An object representing a (sanitized) company.
|
|
2228
|
+
*/
|
|
2229
|
+
interface Company {
|
|
2230
|
+
/**
|
|
2231
|
+
* The ID (tag) of the company.
|
|
2232
|
+
*/
|
|
2233
|
+
id: string;
|
|
2234
|
+
/**
|
|
2235
|
+
* The slug/route of the company on the Whop site.
|
|
2236
|
+
*/
|
|
2237
|
+
route: string;
|
|
2238
|
+
/**
|
|
2239
|
+
* The title of the company.
|
|
2240
|
+
*/
|
|
2241
|
+
title: string;
|
|
2242
|
+
/**
|
|
2243
|
+
* The typename of this object
|
|
2244
|
+
*/
|
|
2245
|
+
typename: 'Company';
|
|
2246
|
+
}
|
|
2247
|
+
/**
|
|
2248
|
+
* An object representing a (sanitized) user of the site.
|
|
2249
|
+
*/
|
|
2250
|
+
interface User {
|
|
2251
|
+
/**
|
|
2252
|
+
* The internal ID of the user.
|
|
2253
|
+
*/
|
|
2254
|
+
id: string;
|
|
2255
|
+
/**
|
|
2256
|
+
* The name of the user from their Whop account.
|
|
2257
|
+
*/
|
|
2258
|
+
name: string | null;
|
|
2259
|
+
/**
|
|
2260
|
+
* The typename of this object
|
|
2261
|
+
*/
|
|
2262
|
+
typename: 'User';
|
|
2263
|
+
/**
|
|
2264
|
+
* The username of the user from their Whop account.
|
|
2265
|
+
*/
|
|
2266
|
+
username: string;
|
|
2267
|
+
}
|
|
2268
|
+
/**
|
|
2269
|
+
* An object representing a (sanitized) company.
|
|
2270
|
+
*/
|
|
2271
|
+
interface Company {
|
|
2272
|
+
/**
|
|
2273
|
+
* The ID (tag) of the company.
|
|
2274
|
+
*/
|
|
2275
|
+
id: string;
|
|
2276
|
+
/**
|
|
2277
|
+
* The slug/route of the company on the Whop site.
|
|
2278
|
+
*/
|
|
2279
|
+
route: string;
|
|
2280
|
+
/**
|
|
2281
|
+
* The title of the company.
|
|
2282
|
+
*/
|
|
2283
|
+
title: string;
|
|
2284
|
+
/**
|
|
2285
|
+
* The typename of this object
|
|
2286
|
+
*/
|
|
2287
|
+
typename: 'Company';
|
|
2288
|
+
}
|
|
2289
|
+
}
|
|
2290
|
+
/**
|
|
2291
|
+
* Visibility of a resource
|
|
2292
|
+
*/
|
|
2293
|
+
export type Visibility = 'visible' | 'hidden' | 'archived' | 'quick_link';
|
|
2294
|
+
/**
|
|
2295
|
+
* The different levels of visibility for resources
|
|
2296
|
+
*/
|
|
2297
|
+
export type VisibilityFilter = 'visible' | 'hidden' | 'archived' | 'quick_link' | 'all' | 'not_quick_link' | 'not_archived';
|
|
2298
|
+
/**
|
|
2299
|
+
* Who can post on a chat feed
|
|
2300
|
+
*/
|
|
2301
|
+
export type WhoCanPost = 'everyone' | 'admins';
|
|
2302
|
+
/**
|
|
2303
|
+
* Who can react on a chat feed
|
|
2304
|
+
*/
|
|
2305
|
+
export type WhoCanReact = 'everyone' | 'no_one';
|
|
2306
|
+
export type InvoiceListItemsCursorPage = CursorPage<InvoiceListItem>;
|
|
2307
|
+
export type CourseLessonInteractionListItemsCursorPage = CursorPage<CourseLessonInteractionListItem>;
|
|
2308
|
+
export type ProductListItemsCursorPage = CursorPage<ProductListItem>;
|
|
2309
|
+
//# sourceMappingURL=shared.d.mts.map
|