rehive 3.1.4 → 4.0.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/README.md +211 -506
- package/dist/admin.d.mts +31284 -0
- package/dist/admin.d.ts +31284 -0
- package/dist/admin.js +1 -0
- package/dist/admin.mjs +1 -0
- package/dist/auth.d.mts +23 -0
- package/dist/auth.d.ts +23 -0
- package/dist/auth.js +1 -0
- package/dist/auth.mjs +1 -0
- package/dist/chunk-53JJUQ4V.js +1 -0
- package/dist/chunk-5MRX4DHT.js +1 -0
- package/dist/chunk-7WWCXCY2.mjs +1 -0
- package/dist/chunk-HF5XDXOU.mjs +1 -0
- package/dist/chunk-NFN3B6SG.mjs +1 -0
- package/dist/chunk-OEIQFP6T.js +1 -0
- package/dist/chunk-Q2ZX3WFY.mjs +7 -0
- package/dist/chunk-QWQ6ZENI.js +1 -0
- package/dist/chunk-RKDIBDG6.js +7 -0
- package/dist/chunk-S4QKN5WW.mjs +1 -0
- package/dist/chunk-UYUMXTPF.js +7 -0
- package/dist/chunk-V277OEVY.mjs +7 -0
- package/dist/create-api-client-BMeX50D6.d.ts +25 -0
- package/dist/create-api-client-BrsH1l8c.d.mts +25 -0
- package/dist/create-auth-UTklIOTc.d.mts +18340 -0
- package/dist/create-auth-UTklIOTc.d.ts +18340 -0
- package/dist/extensions/alchemy.d.mts +1114 -0
- package/dist/extensions/alchemy.d.ts +1114 -0
- package/dist/extensions/alchemy.js +7 -0
- package/dist/extensions/alchemy.mjs +7 -0
- package/dist/extensions/app.d.mts +2042 -0
- package/dist/extensions/app.d.ts +2042 -0
- package/dist/extensions/app.js +7 -0
- package/dist/extensions/app.mjs +7 -0
- package/dist/extensions/billing.d.mts +828 -0
- package/dist/extensions/billing.d.ts +828 -0
- package/dist/extensions/billing.js +7 -0
- package/dist/extensions/billing.mjs +7 -0
- package/dist/extensions/bridge.d.mts +2028 -0
- package/dist/extensions/bridge.d.ts +2028 -0
- package/dist/extensions/bridge.js +7 -0
- package/dist/extensions/bridge.mjs +7 -0
- package/dist/extensions/builder.d.mts +542 -0
- package/dist/extensions/builder.d.ts +542 -0
- package/dist/extensions/builder.js +7 -0
- package/dist/extensions/builder.mjs +7 -0
- package/dist/extensions/business.d.mts +8972 -0
- package/dist/extensions/business.d.ts +8972 -0
- package/dist/extensions/business.js +7 -0
- package/dist/extensions/business.mjs +7 -0
- package/dist/extensions/conversion.d.mts +2786 -0
- package/dist/extensions/conversion.d.ts +2786 -0
- package/dist/extensions/conversion.js +7 -0
- package/dist/extensions/conversion.mjs +7 -0
- package/dist/extensions/mass-send.d.mts +1294 -0
- package/dist/extensions/mass-send.d.ts +1294 -0
- package/dist/extensions/mass-send.js +7 -0
- package/dist/extensions/mass-send.mjs +7 -0
- package/dist/extensions/notifications.d.mts +2035 -0
- package/dist/extensions/notifications.d.ts +2035 -0
- package/dist/extensions/notifications.js +7 -0
- package/dist/extensions/notifications.mjs +7 -0
- package/dist/extensions/payment-requests.d.mts +3746 -0
- package/dist/extensions/payment-requests.d.ts +3746 -0
- package/dist/extensions/payment-requests.js +7 -0
- package/dist/extensions/payment-requests.mjs +7 -0
- package/dist/extensions/products.d.mts +10092 -0
- package/dist/extensions/products.d.ts +10092 -0
- package/dist/extensions/products.js +7 -0
- package/dist/extensions/products.mjs +7 -0
- package/dist/extensions/rain.d.mts +1896 -0
- package/dist/extensions/rain.d.ts +1896 -0
- package/dist/extensions/rain.js +7 -0
- package/dist/extensions/rain.mjs +7 -0
- package/dist/extensions/rewards.d.mts +2038 -0
- package/dist/extensions/rewards.d.ts +2038 -0
- package/dist/extensions/rewards.js +7 -0
- package/dist/extensions/rewards.mjs +7 -0
- package/dist/extensions/stellar-testnet.d.mts +3922 -0
- package/dist/extensions/stellar-testnet.d.ts +3922 -0
- package/dist/extensions/stellar-testnet.js +7 -0
- package/dist/extensions/stellar-testnet.mjs +7 -0
- package/dist/extensions/stellar.d.mts +3922 -0
- package/dist/extensions/stellar.d.ts +3922 -0
- package/dist/extensions/stellar.js +7 -0
- package/dist/extensions/stellar.mjs +7 -0
- package/dist/index.d.mts +6 -61050
- package/dist/index.d.ts +6 -61050
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/react.d.mts +8 -61087
- package/dist/react.d.ts +8 -61087
- package/dist/react.js +1 -1
- package/dist/react.mjs +1 -1
- package/dist/user.d.mts +1347 -0
- package/dist/user.d.ts +1347 -0
- package/dist/user.js +1 -0
- package/dist/user.mjs +1 -0
- package/package.json +99 -32
- package/src/auth/core/storage-adapters.ts +58 -0
- package/src/auth/create-auth.ts +563 -0
- package/src/auth/index.ts +4 -0
- package/src/auth/types/index.ts +28 -0
- package/src/extensions/alchemy/create-api.ts +13 -0
- package/src/extensions/alchemy/index.ts +3 -0
- package/src/extensions/alchemy/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/alchemy/openapi-ts/client/index.ts +25 -0
- package/src/extensions/alchemy/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/alchemy/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/alchemy/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/alchemy/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/alchemy/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/alchemy/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/alchemy/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/alchemy/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/alchemy/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/alchemy/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/alchemy/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/alchemy/openapi-ts/index.ts +4 -0
- package/src/extensions/alchemy/openapi-ts/sdk.gen.ts +179 -0
- package/src/extensions/alchemy/openapi-ts/types.gen.ts +851 -0
- package/src/extensions/app/create-api.ts +13 -0
- package/src/extensions/app/index.ts +3 -0
- package/src/extensions/app/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/app/openapi-ts/client/index.ts +25 -0
- package/src/extensions/app/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/app/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/app/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/app/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/app/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/app/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/app/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/app/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/app/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/app/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/app/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/app/openapi-ts/index.ts +4 -0
- package/src/extensions/app/openapi-ts/sdk.gen.ts +539 -0
- package/src/extensions/app/openapi-ts/types.gen.ts +1702 -0
- package/src/extensions/billing/create-api.ts +13 -0
- package/src/extensions/billing/index.ts +3 -0
- package/src/extensions/billing/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/billing/openapi-ts/client/index.ts +25 -0
- package/src/extensions/billing/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/billing/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/billing/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/billing/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/billing/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/billing/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/billing/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/billing/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/billing/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/billing/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/billing/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/billing/openapi-ts/index.ts +4 -0
- package/src/extensions/billing/openapi-ts/sdk.gen.ts +155 -0
- package/src/extensions/billing/openapi-ts/types.gen.ts +508 -0
- package/src/extensions/bridge/create-api.ts +13 -0
- package/src/extensions/bridge/index.ts +3 -0
- package/src/extensions/bridge/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/bridge/openapi-ts/client/index.ts +25 -0
- package/src/extensions/bridge/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/bridge/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/bridge/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/bridge/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/bridge/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/bridge/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/bridge/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/bridge/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/bridge/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/bridge/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/bridge/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/bridge/openapi-ts/index.ts +4 -0
- package/src/extensions/bridge/openapi-ts/sdk.gen.ts +383 -0
- package/src/extensions/bridge/openapi-ts/types.gen.ts +1855 -0
- package/src/extensions/builder/create-api.ts +13 -0
- package/src/extensions/builder/index.ts +3 -0
- package/src/extensions/builder/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/builder/openapi-ts/client/index.ts +25 -0
- package/src/extensions/builder/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/builder/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/builder/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/builder/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/builder/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/builder/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/builder/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/builder/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/builder/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/builder/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/builder/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/builder/openapi-ts/index.ts +4 -0
- package/src/extensions/builder/openapi-ts/sdk.gen.ts +60 -0
- package/src/extensions/builder/openapi-ts/types.gen.ts +215 -0
- package/src/extensions/business/create-api.ts +13 -0
- package/src/extensions/business/index.ts +3 -0
- package/src/extensions/business/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/business/openapi-ts/client/index.ts +25 -0
- package/src/extensions/business/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/business/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/business/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/business/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/business/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/business/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/business/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/business/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/business/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/business/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/business/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/business/openapi-ts/index.ts +4 -0
- package/src/extensions/business/openapi-ts/sdk.gen.ts +903 -0
- package/src/extensions/business/openapi-ts/types.gen.ts +8718 -0
- package/src/extensions/conversion/create-api.ts +13 -0
- package/src/extensions/conversion/index.ts +3 -0
- package/src/extensions/conversion/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/conversion/openapi-ts/client/index.ts +25 -0
- package/src/extensions/conversion/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/conversion/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/conversion/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/conversion/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/conversion/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/conversion/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/conversion/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/conversion/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/conversion/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/conversion/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/conversion/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/conversion/openapi-ts/index.ts +4 -0
- package/src/extensions/conversion/openapi-ts/sdk.gen.ts +684 -0
- package/src/extensions/conversion/openapi-ts/types.gen.ts +2467 -0
- package/src/extensions/mass-send/create-api.ts +13 -0
- package/src/extensions/mass-send/index.ts +3 -0
- package/src/extensions/mass-send/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/mass-send/openapi-ts/client/index.ts +25 -0
- package/src/extensions/mass-send/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/mass-send/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/mass-send/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/mass-send/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/mass-send/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/mass-send/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/mass-send/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/mass-send/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/mass-send/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/mass-send/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/mass-send/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/mass-send/openapi-ts/index.ts +4 -0
- package/src/extensions/mass-send/openapi-ts/sdk.gen.ts +270 -0
- package/src/extensions/mass-send/openapi-ts/types.gen.ts +988 -0
- package/src/extensions/notifications/create-api.ts +13 -0
- package/src/extensions/notifications/index.ts +3 -0
- package/src/extensions/notifications/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/notifications/openapi-ts/client/index.ts +25 -0
- package/src/extensions/notifications/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/notifications/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/notifications/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/notifications/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/notifications/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/notifications/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/notifications/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/notifications/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/notifications/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/notifications/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/notifications/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/notifications/openapi-ts/index.ts +4 -0
- package/src/extensions/notifications/openapi-ts/sdk.gen.ts +450 -0
- package/src/extensions/notifications/openapi-ts/types.gen.ts +1732 -0
- package/src/extensions/payment-requests/create-api.ts +13 -0
- package/src/extensions/payment-requests/index.ts +3 -0
- package/src/extensions/payment-requests/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/payment-requests/openapi-ts/client/index.ts +25 -0
- package/src/extensions/payment-requests/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/payment-requests/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/payment-requests/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/payment-requests/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/payment-requests/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/payment-requests/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/payment-requests/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/payment-requests/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/payment-requests/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/payment-requests/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/payment-requests/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/payment-requests/openapi-ts/index.ts +4 -0
- package/src/extensions/payment-requests/openapi-ts/sdk.gen.ts +845 -0
- package/src/extensions/payment-requests/openapi-ts/types.gen.ts +3415 -0
- package/src/extensions/products/create-api.ts +13 -0
- package/src/extensions/products/index.ts +3 -0
- package/src/extensions/products/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/products/openapi-ts/client/index.ts +25 -0
- package/src/extensions/products/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/products/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/products/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/products/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/products/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/products/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/products/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/products/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/products/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/products/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/products/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/products/openapi-ts/index.ts +4 -0
- package/src/extensions/products/openapi-ts/sdk.gen.ts +2619 -0
- package/src/extensions/products/openapi-ts/types.gen.ts +9717 -0
- package/src/extensions/rain/create-api.ts +13 -0
- package/src/extensions/rain/index.ts +3 -0
- package/src/extensions/rain/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/rain/openapi-ts/client/index.ts +25 -0
- package/src/extensions/rain/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/rain/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/rain/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/rain/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/rain/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/rain/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/rain/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/rain/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/rain/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/rain/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/rain/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/rain/openapi-ts/index.ts +4 -0
- package/src/extensions/rain/openapi-ts/sdk.gen.ts +227 -0
- package/src/extensions/rain/openapi-ts/types.gen.ts +1660 -0
- package/src/extensions/rewards/create-api.ts +13 -0
- package/src/extensions/rewards/index.ts +3 -0
- package/src/extensions/rewards/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/rewards/openapi-ts/client/index.ts +25 -0
- package/src/extensions/rewards/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/rewards/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/rewards/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/rewards/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/rewards/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/rewards/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/rewards/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/rewards/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/rewards/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/rewards/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/rewards/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/rewards/openapi-ts/index.ts +4 -0
- package/src/extensions/rewards/openapi-ts/sdk.gen.ts +345 -0
- package/src/extensions/rewards/openapi-ts/types.gen.ts +1718 -0
- package/src/extensions/stellar/create-api.ts +13 -0
- package/src/extensions/stellar/index.ts +3 -0
- package/src/extensions/stellar/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/stellar/openapi-ts/client/index.ts +25 -0
- package/src/extensions/stellar/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/stellar/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/stellar/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/stellar/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/stellar/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/stellar/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/stellar/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/stellar/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/stellar/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/stellar/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/stellar/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/stellar/openapi-ts/index.ts +4 -0
- package/src/extensions/stellar/openapi-ts/sdk.gen.ts +1049 -0
- package/src/extensions/stellar/openapi-ts/types.gen.ts +3543 -0
- package/src/extensions/stellar-testnet/create-api.ts +13 -0
- package/src/extensions/stellar-testnet/index.ts +3 -0
- package/src/extensions/stellar-testnet/openapi-ts/client/client.gen.ts +288 -0
- package/src/extensions/stellar-testnet/openapi-ts/client/index.ts +25 -0
- package/src/extensions/stellar-testnet/openapi-ts/client/types.gen.ts +213 -0
- package/src/extensions/stellar-testnet/openapi-ts/client/utils.gen.ts +316 -0
- package/src/extensions/stellar-testnet/openapi-ts/client.gen.ts +16 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/auth.gen.ts +41 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/params.gen.ts +169 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/types.gen.ts +104 -0
- package/src/extensions/stellar-testnet/openapi-ts/core/utils.gen.ts +140 -0
- package/src/extensions/stellar-testnet/openapi-ts/index.ts +4 -0
- package/src/extensions/stellar-testnet/openapi-ts/sdk.gen.ts +1049 -0
- package/src/extensions/stellar-testnet/openapi-ts/types.gen.ts +3543 -0
- package/src/platform/admin/create-api.ts +11 -0
- package/src/platform/admin/index.ts +3 -42
- package/src/platform/admin/openapi-ts/client/client.gen.ts +288 -0
- package/src/platform/admin/openapi-ts/client/index.ts +25 -0
- package/src/platform/admin/openapi-ts/client/types.gen.ts +213 -0
- package/src/platform/admin/openapi-ts/client/utils.gen.ts +316 -0
- package/src/platform/admin/openapi-ts/client.gen.ts +16 -0
- package/src/platform/admin/openapi-ts/core/auth.gen.ts +41 -0
- package/src/platform/admin/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/platform/admin/openapi-ts/core/params.gen.ts +169 -0
- package/src/platform/admin/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/platform/admin/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/platform/admin/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/platform/admin/openapi-ts/core/types.gen.ts +104 -0
- package/src/platform/admin/openapi-ts/core/utils.gen.ts +140 -0
- package/src/platform/admin/openapi-ts/index.ts +4 -0
- package/src/platform/admin/openapi-ts/sdk.gen.ts +3975 -0
- package/src/platform/admin/openapi-ts/types.gen.ts +31193 -0
- package/src/platform/user/create-api.ts +11 -0
- package/src/platform/user/index.ts +3 -42
- package/src/platform/user/openapi-ts/client/client.gen.ts +288 -0
- package/src/platform/user/openapi-ts/client/index.ts +25 -0
- package/src/platform/user/openapi-ts/client/types.gen.ts +213 -0
- package/src/platform/user/openapi-ts/client/utils.gen.ts +316 -0
- package/src/platform/user/openapi-ts/client.gen.ts +16 -0
- package/src/platform/user/openapi-ts/core/auth.gen.ts +41 -0
- package/src/platform/user/openapi-ts/core/bodySerializer.gen.ts +84 -0
- package/src/platform/user/openapi-ts/core/params.gen.ts +169 -0
- package/src/platform/user/openapi-ts/core/pathSerializer.gen.ts +171 -0
- package/src/platform/user/openapi-ts/core/queryKeySerializer.gen.ts +117 -0
- package/src/platform/user/openapi-ts/core/serverSentEvents.gen.ts +243 -0
- package/src/platform/user/openapi-ts/core/types.gen.ts +104 -0
- package/src/platform/user/openapi-ts/core/utils.gen.ts +140 -0
- package/src/platform/user/openapi-ts/index.ts +4 -0
- package/src/platform/user/openapi-ts/sdk.gen.ts +2090 -0
- package/src/platform/user/openapi-ts/types.gen.ts +19540 -0
- package/src/shared/api-utils.ts +22 -0
- package/src/shared/bind-sdk.ts +48 -0
- package/src/shared/create-api-client.ts +54 -0
- package/src/extensions/app/http-client.ts +0 -1
- package/src/extensions/app/rehive-app-api.ts +0 -1827
- package/src/extensions/bridge/rehive-bridge-api.ts +0 -1436
- package/src/extensions/business/rehive-business-api.ts +0 -9480
- package/src/extensions/conversion/rehive-conversion-api.ts +0 -3054
- package/src/extensions/mass-send/rehive-mass-send-api.ts +0 -1061
- package/src/extensions/notifications/rehive-notifications-api.ts +0 -1964
- package/src/extensions/payment-requests/rehive-payment-requests-api.ts +0 -4026
- package/src/extensions/products/rehive-products-api.ts +0 -13107
- package/src/extensions/rewards/rehive-rewards-api.ts +0 -2139
- package/src/extensions/stellar/rehive-stellar-api.ts +0 -4219
- package/src/extensions/stellar-testnet/rehive-stellar-testnet-api.ts +0 -4219
- package/src/platform/admin/rehive-platform-admin-api.ts +0 -35075
- package/src/platform/user/rehive-platform-user-api.ts +0 -21554
|
@@ -1,2139 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
// @ts-nocheck
|
|
4
|
-
/*
|
|
5
|
-
* ---------------------------------------------------------------
|
|
6
|
-
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
-
* ## ##
|
|
8
|
-
* ## AUTHOR: acacode ##
|
|
9
|
-
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
-
* ---------------------------------------------------------------
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
/** This serializer can be used if only a `status` is required in the response. */
|
|
14
|
-
export interface ActionResponse {
|
|
15
|
-
/** @default "sucess" */
|
|
16
|
-
status?: string;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface Activate {
|
|
20
|
-
token: string;
|
|
21
|
-
id: string;
|
|
22
|
-
name: string;
|
|
23
|
-
/** @format uuid */
|
|
24
|
-
secret: string;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* A ModelSerializer that takes additional arguments for
|
|
29
|
-
* "fields", "omit" and "expand" in order to
|
|
30
|
-
* control which fields are displayed, and whether to replace simple
|
|
31
|
-
* values with complex, nested serializations
|
|
32
|
-
*/
|
|
33
|
-
export interface AdminCampaign {
|
|
34
|
-
id: string;
|
|
35
|
-
/** @maxLength 50 */
|
|
36
|
-
name?: string;
|
|
37
|
-
/** @format uri */
|
|
38
|
-
image?: string | null;
|
|
39
|
-
/** @maxLength 255 */
|
|
40
|
-
description?: string;
|
|
41
|
-
start_date: number;
|
|
42
|
-
end_date: number;
|
|
43
|
-
/**
|
|
44
|
-
* A ModelSerializer that takes additional arguments for
|
|
45
|
-
* "fields", "omit" and "expand" in order to
|
|
46
|
-
* control which fields are displayed, and whether to replace simple
|
|
47
|
-
* values with complex, nested serializations
|
|
48
|
-
*/
|
|
49
|
-
currency: Currency;
|
|
50
|
-
/** @maxLength 200 */
|
|
51
|
-
credit_account_name?: string | null;
|
|
52
|
-
/** @maxLength 64 */
|
|
53
|
-
credit_account?: string | null;
|
|
54
|
-
/** @maxLength 64 */
|
|
55
|
-
account: string;
|
|
56
|
-
total: number;
|
|
57
|
-
fixed_amount: number | null;
|
|
58
|
-
/**
|
|
59
|
-
* @format decimal
|
|
60
|
-
* @pattern ^-?\d{0,7}(?:\.\d{0,2})?$
|
|
61
|
-
*/
|
|
62
|
-
percentage?: string | null;
|
|
63
|
-
balance: number;
|
|
64
|
-
/**
|
|
65
|
-
* * `percentage` - Percentage
|
|
66
|
-
* * `fixed` - Fixed
|
|
67
|
-
* * `fixedpercentage` - Fixedpercentage
|
|
68
|
-
*/
|
|
69
|
-
type?: "percentage" | "fixed" | "fixedpercentage";
|
|
70
|
-
/**
|
|
71
|
-
* * `pending` - Pending
|
|
72
|
-
* * `accepted` - Accepted
|
|
73
|
-
* * `rejected` - Rejected
|
|
74
|
-
*/
|
|
75
|
-
default_status?: "pending" | "accepted" | "rejected";
|
|
76
|
-
users?: any[];
|
|
77
|
-
groups?: any[];
|
|
78
|
-
/**
|
|
79
|
-
* @min 1
|
|
80
|
-
* @max 1000000000
|
|
81
|
-
*/
|
|
82
|
-
max_per_user?: number | null;
|
|
83
|
-
/**
|
|
84
|
-
* @min 1
|
|
85
|
-
* @max 1000000000
|
|
86
|
-
*/
|
|
87
|
-
max_per_user_per_timeframe?: number | null;
|
|
88
|
-
/**
|
|
89
|
-
* * `daily` - Daily
|
|
90
|
-
* * `weekly` - Weekly
|
|
91
|
-
* * `monthly` - Monthly
|
|
92
|
-
*/
|
|
93
|
-
timeframe?: "daily" | "weekly" | "monthly" | "" | null;
|
|
94
|
-
/**
|
|
95
|
-
* A ModelSerializer that takes additional arguments for
|
|
96
|
-
* "fields", "omit" and "expand" in order to
|
|
97
|
-
* control which fields are displayed, and whether to replace simple
|
|
98
|
-
* values with complex, nested serializations
|
|
99
|
-
*/
|
|
100
|
-
transactions_currency: Currency;
|
|
101
|
-
/**
|
|
102
|
-
* @min 1
|
|
103
|
-
* @max 1000000000
|
|
104
|
-
*/
|
|
105
|
-
min_num_transactions?: number | null;
|
|
106
|
-
min_value_transactions: number | null;
|
|
107
|
-
/** @default true */
|
|
108
|
-
active?: boolean;
|
|
109
|
-
/** @default true */
|
|
110
|
-
visible?: boolean;
|
|
111
|
-
/** @default true */
|
|
112
|
-
claim?: boolean;
|
|
113
|
-
/** @maxLength 250 */
|
|
114
|
-
expression?: string | null;
|
|
115
|
-
/**
|
|
116
|
-
* * `company.link.create` - company.link.create
|
|
117
|
-
* * `company.link.update` - company.link.update
|
|
118
|
-
* * `company.update` - company.update
|
|
119
|
-
* * `currency.create` - currency.create
|
|
120
|
-
* * `currency.update` - currency.update
|
|
121
|
-
* * `user.create` - user.create
|
|
122
|
-
* * `user.update` - user.update
|
|
123
|
-
* * `user.password.reset` - user.password.reset
|
|
124
|
-
* * `user.password.set` - user.password.set
|
|
125
|
-
* * `user.deactivate.verify` - user.deactivate.verify
|
|
126
|
-
* * `user.request_delete.verify` - user.request_delete.verify
|
|
127
|
-
* * `user.email.verify` - user.email.verify
|
|
128
|
-
* * `user.mobile.verify` - user.mobile.verify
|
|
129
|
-
* * `email.create` - email.create
|
|
130
|
-
* * `email.update` - email.update
|
|
131
|
-
* * `mobile.create` - mobile.create
|
|
132
|
-
* * `mobile.update` - mobile.update
|
|
133
|
-
* * `address.create` - address.create
|
|
134
|
-
* * `address.update` - address.update
|
|
135
|
-
* * `document.create` - document.create
|
|
136
|
-
* * `document.update` - document.update
|
|
137
|
-
* * `bank_account.create` - bank_account.create
|
|
138
|
-
* * `bank_account.update` - bank_account.update
|
|
139
|
-
* * `crypto_account.create` - crypto_account.create
|
|
140
|
-
* * `crypto_account.update` - crypto_account.update
|
|
141
|
-
* * `account.create` - account.create
|
|
142
|
-
* * `account.update` - account.update
|
|
143
|
-
* * `transaction.create` - transaction.create
|
|
144
|
-
* * `transaction.update` - transaction.update
|
|
145
|
-
* * `transaction.initiate` - transaction.initiate
|
|
146
|
-
* * `transaction.execute` - transaction.execute
|
|
147
|
-
* * `transaction.transition.create` - transaction.transition.create
|
|
148
|
-
* * `transaction.transition.update` - transaction.transition.update
|
|
149
|
-
* * `mfa.sms.verify` - mfa.sms.verify
|
|
150
|
-
*/
|
|
151
|
-
event?:
|
|
152
|
-
| "company.link.create"
|
|
153
|
-
| "company.link.update"
|
|
154
|
-
| "company.update"
|
|
155
|
-
| "currency.create"
|
|
156
|
-
| "currency.update"
|
|
157
|
-
| "user.create"
|
|
158
|
-
| "user.update"
|
|
159
|
-
| "user.password.reset"
|
|
160
|
-
| "user.password.set"
|
|
161
|
-
| "user.deactivate.verify"
|
|
162
|
-
| "user.request_delete.verify"
|
|
163
|
-
| "user.email.verify"
|
|
164
|
-
| "user.mobile.verify"
|
|
165
|
-
| "email.create"
|
|
166
|
-
| "email.update"
|
|
167
|
-
| "mobile.create"
|
|
168
|
-
| "mobile.update"
|
|
169
|
-
| "address.create"
|
|
170
|
-
| "address.update"
|
|
171
|
-
| "document.create"
|
|
172
|
-
| "document.update"
|
|
173
|
-
| "bank_account.create"
|
|
174
|
-
| "bank_account.update"
|
|
175
|
-
| "crypto_account.create"
|
|
176
|
-
| "crypto_account.update"
|
|
177
|
-
| "account.create"
|
|
178
|
-
| "account.update"
|
|
179
|
-
| "transaction.create"
|
|
180
|
-
| "transaction.update"
|
|
181
|
-
| "transaction.initiate"
|
|
182
|
-
| "transaction.execute"
|
|
183
|
-
| "transaction.transition.create"
|
|
184
|
-
| "transaction.transition.update"
|
|
185
|
-
| "mfa.sms.verify"
|
|
186
|
-
| ""
|
|
187
|
-
| null;
|
|
188
|
-
/** @maxLength 150 */
|
|
189
|
-
event_user?: string | null;
|
|
190
|
-
/** @maxLength 150 */
|
|
191
|
-
event_amount?: string | null;
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
export interface AdminCampaignResponse {
|
|
195
|
-
/** @example "success" */
|
|
196
|
-
status?: string;
|
|
197
|
-
/**
|
|
198
|
-
* A ModelSerializer that takes additional arguments for
|
|
199
|
-
* "fields", "omit" and "expand" in order to
|
|
200
|
-
* control which fields are displayed, and whether to replace simple
|
|
201
|
-
* values with complex, nested serializations
|
|
202
|
-
*/
|
|
203
|
-
data?: AdminCampaign;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
/**
|
|
207
|
-
* A ModelSerializer that takes additional arguments for
|
|
208
|
-
* "fields", "omit" and "expand" in order to
|
|
209
|
-
* control which fields are displayed, and whether to replace simple
|
|
210
|
-
* values with complex, nested serializations
|
|
211
|
-
*/
|
|
212
|
-
export interface AdminCompany {
|
|
213
|
-
id: string;
|
|
214
|
-
identifier: string;
|
|
215
|
-
/** @format uuid */
|
|
216
|
-
secret: string;
|
|
217
|
-
name: string;
|
|
218
|
-
operational_account?: string | null;
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
export interface AdminCompanyResponse {
|
|
222
|
-
/** @example "success" */
|
|
223
|
-
status?: string;
|
|
224
|
-
/**
|
|
225
|
-
* A ModelSerializer that takes additional arguments for
|
|
226
|
-
* "fields", "omit" and "expand" in order to
|
|
227
|
-
* control which fields are displayed, and whether to replace simple
|
|
228
|
-
* values with complex, nested serializations
|
|
229
|
-
*/
|
|
230
|
-
data?: AdminCompany;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
/**
|
|
234
|
-
* A ModelSerializer that takes additional arguments for
|
|
235
|
-
* "fields", "omit" and "expand" in order to
|
|
236
|
-
* control which fields are displayed, and whether to replace simple
|
|
237
|
-
* values with complex, nested serializations
|
|
238
|
-
*/
|
|
239
|
-
export interface AdminCreateReward {
|
|
240
|
-
id: string;
|
|
241
|
-
user: string;
|
|
242
|
-
campaign?: string;
|
|
243
|
-
currency?: string;
|
|
244
|
-
amount?: number;
|
|
245
|
-
/**
|
|
246
|
-
* * `pending` - Pending
|
|
247
|
-
* * `accepted` - Accepted
|
|
248
|
-
* * `rejected` - Rejected
|
|
249
|
-
*/
|
|
250
|
-
status?: "pending" | "accepted" | "rejected";
|
|
251
|
-
collection: string | null;
|
|
252
|
-
created: number;
|
|
253
|
-
data?: Record<string, any>;
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
/**
|
|
257
|
-
* A ModelSerializer that takes additional arguments for
|
|
258
|
-
* "fields", "omit" and "expand" in order to
|
|
259
|
-
* control which fields are displayed, and whether to replace simple
|
|
260
|
-
* values with complex, nested serializations
|
|
261
|
-
*/
|
|
262
|
-
export interface AdminCreateUpdateCampaign {
|
|
263
|
-
id: string;
|
|
264
|
-
/** @maxLength 50 */
|
|
265
|
-
name?: string;
|
|
266
|
-
/** @format uri */
|
|
267
|
-
image?: string | null;
|
|
268
|
-
/** @maxLength 255 */
|
|
269
|
-
description?: string;
|
|
270
|
-
start_date?: number | null;
|
|
271
|
-
end_date?: number | null;
|
|
272
|
-
currency: string;
|
|
273
|
-
/** @maxLength 200 */
|
|
274
|
-
credit_account_name?: string | null;
|
|
275
|
-
/** @maxLength 64 */
|
|
276
|
-
credit_account?: string | null;
|
|
277
|
-
account?: string | null;
|
|
278
|
-
total: number;
|
|
279
|
-
fixed_amount?: number;
|
|
280
|
-
/**
|
|
281
|
-
* @format double
|
|
282
|
-
* @min 0
|
|
283
|
-
* @max 10000000
|
|
284
|
-
* @exclusiveMax true
|
|
285
|
-
*/
|
|
286
|
-
percentage?: number | null;
|
|
287
|
-
balance: number;
|
|
288
|
-
/**
|
|
289
|
-
* * `percentage` - Percentage
|
|
290
|
-
* * `fixed` - Fixed
|
|
291
|
-
* * `fixedpercentage` - Fixedpercentage
|
|
292
|
-
*/
|
|
293
|
-
type?: "percentage" | "fixed" | "fixedpercentage";
|
|
294
|
-
/**
|
|
295
|
-
* * `pending` - Pending
|
|
296
|
-
* * `accepted` - Accepted
|
|
297
|
-
* * `rejected` - Rejected
|
|
298
|
-
*/
|
|
299
|
-
default_status?: "pending" | "accepted" | "rejected";
|
|
300
|
-
users?: any[];
|
|
301
|
-
groups?: any[];
|
|
302
|
-
/**
|
|
303
|
-
* @min 1
|
|
304
|
-
* @max 1000000000
|
|
305
|
-
*/
|
|
306
|
-
max_per_user?: number | null;
|
|
307
|
-
/**
|
|
308
|
-
* @min 1
|
|
309
|
-
* @max 1000000000
|
|
310
|
-
*/
|
|
311
|
-
max_per_user_per_timeframe?: number | null;
|
|
312
|
-
/**
|
|
313
|
-
* * `daily` - Daily
|
|
314
|
-
* * `weekly` - Weekly
|
|
315
|
-
* * `monthly` - Monthly
|
|
316
|
-
*/
|
|
317
|
-
timeframe?: "daily" | "weekly" | "monthly" | "" | null;
|
|
318
|
-
transactions_currency?: string | null;
|
|
319
|
-
/**
|
|
320
|
-
* @min 1
|
|
321
|
-
* @max 1000000000
|
|
322
|
-
*/
|
|
323
|
-
min_num_transactions?: number | null;
|
|
324
|
-
min_value_transactions?: number | null;
|
|
325
|
-
/** @default true */
|
|
326
|
-
active?: boolean;
|
|
327
|
-
/** @default true */
|
|
328
|
-
visible?: boolean;
|
|
329
|
-
/** @default true */
|
|
330
|
-
claim?: boolean;
|
|
331
|
-
/** @maxLength 250 */
|
|
332
|
-
expression?: string | null;
|
|
333
|
-
/**
|
|
334
|
-
* * `company.link.create` - company.link.create
|
|
335
|
-
* * `company.link.update` - company.link.update
|
|
336
|
-
* * `company.update` - company.update
|
|
337
|
-
* * `currency.create` - currency.create
|
|
338
|
-
* * `currency.update` - currency.update
|
|
339
|
-
* * `user.create` - user.create
|
|
340
|
-
* * `user.update` - user.update
|
|
341
|
-
* * `user.password.reset` - user.password.reset
|
|
342
|
-
* * `user.password.set` - user.password.set
|
|
343
|
-
* * `user.deactivate.verify` - user.deactivate.verify
|
|
344
|
-
* * `user.request_delete.verify` - user.request_delete.verify
|
|
345
|
-
* * `user.email.verify` - user.email.verify
|
|
346
|
-
* * `user.mobile.verify` - user.mobile.verify
|
|
347
|
-
* * `email.create` - email.create
|
|
348
|
-
* * `email.update` - email.update
|
|
349
|
-
* * `mobile.create` - mobile.create
|
|
350
|
-
* * `mobile.update` - mobile.update
|
|
351
|
-
* * `address.create` - address.create
|
|
352
|
-
* * `address.update` - address.update
|
|
353
|
-
* * `document.create` - document.create
|
|
354
|
-
* * `document.update` - document.update
|
|
355
|
-
* * `bank_account.create` - bank_account.create
|
|
356
|
-
* * `bank_account.update` - bank_account.update
|
|
357
|
-
* * `crypto_account.create` - crypto_account.create
|
|
358
|
-
* * `crypto_account.update` - crypto_account.update
|
|
359
|
-
* * `account.create` - account.create
|
|
360
|
-
* * `account.update` - account.update
|
|
361
|
-
* * `transaction.create` - transaction.create
|
|
362
|
-
* * `transaction.update` - transaction.update
|
|
363
|
-
* * `transaction.initiate` - transaction.initiate
|
|
364
|
-
* * `transaction.execute` - transaction.execute
|
|
365
|
-
* * `transaction.transition.create` - transaction.transition.create
|
|
366
|
-
* * `transaction.transition.update` - transaction.transition.update
|
|
367
|
-
* * `mfa.sms.verify` - mfa.sms.verify
|
|
368
|
-
*/
|
|
369
|
-
event?:
|
|
370
|
-
| "company.link.create"
|
|
371
|
-
| "company.link.update"
|
|
372
|
-
| "company.update"
|
|
373
|
-
| "currency.create"
|
|
374
|
-
| "currency.update"
|
|
375
|
-
| "user.create"
|
|
376
|
-
| "user.update"
|
|
377
|
-
| "user.password.reset"
|
|
378
|
-
| "user.password.set"
|
|
379
|
-
| "user.deactivate.verify"
|
|
380
|
-
| "user.request_delete.verify"
|
|
381
|
-
| "user.email.verify"
|
|
382
|
-
| "user.mobile.verify"
|
|
383
|
-
| "email.create"
|
|
384
|
-
| "email.update"
|
|
385
|
-
| "mobile.create"
|
|
386
|
-
| "mobile.update"
|
|
387
|
-
| "address.create"
|
|
388
|
-
| "address.update"
|
|
389
|
-
| "document.create"
|
|
390
|
-
| "document.update"
|
|
391
|
-
| "bank_account.create"
|
|
392
|
-
| "bank_account.update"
|
|
393
|
-
| "crypto_account.create"
|
|
394
|
-
| "crypto_account.update"
|
|
395
|
-
| "account.create"
|
|
396
|
-
| "account.update"
|
|
397
|
-
| "transaction.create"
|
|
398
|
-
| "transaction.update"
|
|
399
|
-
| "transaction.initiate"
|
|
400
|
-
| "transaction.execute"
|
|
401
|
-
| "transaction.transition.create"
|
|
402
|
-
| "transaction.transition.update"
|
|
403
|
-
| "mfa.sms.verify"
|
|
404
|
-
| ""
|
|
405
|
-
| null;
|
|
406
|
-
/** @maxLength 150 */
|
|
407
|
-
event_user?: string | null;
|
|
408
|
-
/** @maxLength 150 */
|
|
409
|
-
event_amount?: string | null;
|
|
410
|
-
}
|
|
411
|
-
|
|
412
|
-
/**
|
|
413
|
-
* A ModelSerializer that takes additional arguments for
|
|
414
|
-
* "fields", "omit" and "expand" in order to
|
|
415
|
-
* control which fields are displayed, and whether to replace simple
|
|
416
|
-
* values with complex, nested serializations
|
|
417
|
-
*/
|
|
418
|
-
export interface AdminReward {
|
|
419
|
-
id: string;
|
|
420
|
-
user: string;
|
|
421
|
-
campaign: Campaign;
|
|
422
|
-
currency: Currency;
|
|
423
|
-
amount: number;
|
|
424
|
-
/**
|
|
425
|
-
* * `pending` - Pending
|
|
426
|
-
* * `accepted` - Accepted
|
|
427
|
-
* * `rejected` - Rejected
|
|
428
|
-
*/
|
|
429
|
-
status?: "pending" | "accepted" | "rejected";
|
|
430
|
-
collection: string | null;
|
|
431
|
-
type: string;
|
|
432
|
-
created: number;
|
|
433
|
-
}
|
|
434
|
-
|
|
435
|
-
export interface AdminRewardResponse {
|
|
436
|
-
/** @example "success" */
|
|
437
|
-
status?: string;
|
|
438
|
-
/**
|
|
439
|
-
* A ModelSerializer that takes additional arguments for
|
|
440
|
-
* "fields", "omit" and "expand" in order to
|
|
441
|
-
* control which fields are displayed, and whether to replace simple
|
|
442
|
-
* values with complex, nested serializations
|
|
443
|
-
*/
|
|
444
|
-
data?: AdminReward;
|
|
445
|
-
}
|
|
446
|
-
|
|
447
|
-
/**
|
|
448
|
-
* A ModelSerializer that takes additional arguments for
|
|
449
|
-
* "fields", "omit" and "expand" in order to
|
|
450
|
-
* control which fields are displayed, and whether to replace simple
|
|
451
|
-
* values with complex, nested serializations
|
|
452
|
-
*/
|
|
453
|
-
export interface AdminUser {
|
|
454
|
-
id: string;
|
|
455
|
-
referral_code: string | null;
|
|
456
|
-
referee_code: string | null;
|
|
457
|
-
}
|
|
458
|
-
|
|
459
|
-
export interface AdminUserResponse {
|
|
460
|
-
/** @example "success" */
|
|
461
|
-
status?: string;
|
|
462
|
-
/**
|
|
463
|
-
* A ModelSerializer that takes additional arguments for
|
|
464
|
-
* "fields", "omit" and "expand" in order to
|
|
465
|
-
* control which fields are displayed, and whether to replace simple
|
|
466
|
-
* values with complex, nested serializations
|
|
467
|
-
*/
|
|
468
|
-
data?: AdminUser;
|
|
469
|
-
}
|
|
470
|
-
|
|
471
|
-
/**
|
|
472
|
-
* A ModelSerializer that takes additional arguments for
|
|
473
|
-
* "fields", "omit" and "expand" in order to
|
|
474
|
-
* control which fields are displayed, and whether to replace simple
|
|
475
|
-
* values with complex, nested serializations
|
|
476
|
-
*/
|
|
477
|
-
export interface Campaign {
|
|
478
|
-
id: string;
|
|
479
|
-
/** @maxLength 50 */
|
|
480
|
-
name?: string;
|
|
481
|
-
/** @maxLength 255 */
|
|
482
|
-
description?: string;
|
|
483
|
-
active?: boolean;
|
|
484
|
-
default_status: string;
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
/**
|
|
488
|
-
* A ModelSerializer that takes additional arguments for
|
|
489
|
-
* "fields", "omit" and "expand" in order to
|
|
490
|
-
* control which fields are displayed, and whether to replace simple
|
|
491
|
-
* values with complex, nested serializations
|
|
492
|
-
*/
|
|
493
|
-
export interface Currency {
|
|
494
|
-
/** @maxLength 30 */
|
|
495
|
-
code: string;
|
|
496
|
-
/** @maxLength 30 */
|
|
497
|
-
display_code?: string | null;
|
|
498
|
-
/** @maxLength 255 */
|
|
499
|
-
description?: string | null;
|
|
500
|
-
/** @maxLength 30 */
|
|
501
|
-
symbol?: string | null;
|
|
502
|
-
/** @maxLength 30 */
|
|
503
|
-
unit?: string | null;
|
|
504
|
-
/**
|
|
505
|
-
* @min -2147483648
|
|
506
|
-
* @max 2147483647
|
|
507
|
-
*/
|
|
508
|
-
divisibility?: number;
|
|
509
|
-
enabled?: boolean;
|
|
510
|
-
}
|
|
511
|
-
|
|
512
|
-
export interface CurrencyResponse {
|
|
513
|
-
/** @example "success" */
|
|
514
|
-
status?: string;
|
|
515
|
-
/**
|
|
516
|
-
* A ModelSerializer that takes additional arguments for
|
|
517
|
-
* "fields", "omit" and "expand" in order to
|
|
518
|
-
* control which fields are displayed, and whether to replace simple
|
|
519
|
-
* values with complex, nested serializations
|
|
520
|
-
*/
|
|
521
|
-
data?: Currency;
|
|
522
|
-
}
|
|
523
|
-
|
|
524
|
-
export interface Deactivate {
|
|
525
|
-
token: string;
|
|
526
|
-
/** @default false */
|
|
527
|
-
purge?: boolean;
|
|
528
|
-
}
|
|
529
|
-
|
|
530
|
-
export interface PaginatedAdminCampaignList {
|
|
531
|
-
/** @example 123 */
|
|
532
|
-
count?: number;
|
|
533
|
-
/**
|
|
534
|
-
* @format uri
|
|
535
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
536
|
-
*/
|
|
537
|
-
next?: string | null;
|
|
538
|
-
/**
|
|
539
|
-
* @format uri
|
|
540
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
541
|
-
*/
|
|
542
|
-
previous?: string | null;
|
|
543
|
-
results?: AdminCampaign[];
|
|
544
|
-
}
|
|
545
|
-
|
|
546
|
-
export interface PaginatedAdminCampaignListResponse {
|
|
547
|
-
/** @example "success" */
|
|
548
|
-
status?: string;
|
|
549
|
-
data?: PaginatedAdminCampaignList;
|
|
550
|
-
}
|
|
551
|
-
|
|
552
|
-
export interface PaginatedAdminRewardList {
|
|
553
|
-
/** @example 123 */
|
|
554
|
-
count?: number;
|
|
555
|
-
/**
|
|
556
|
-
* @format uri
|
|
557
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
558
|
-
*/
|
|
559
|
-
next?: string | null;
|
|
560
|
-
/**
|
|
561
|
-
* @format uri
|
|
562
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
563
|
-
*/
|
|
564
|
-
previous?: string | null;
|
|
565
|
-
results?: AdminReward[];
|
|
566
|
-
}
|
|
567
|
-
|
|
568
|
-
export interface PaginatedAdminRewardListResponse {
|
|
569
|
-
/** @example "success" */
|
|
570
|
-
status?: string;
|
|
571
|
-
data?: PaginatedAdminRewardList;
|
|
572
|
-
}
|
|
573
|
-
|
|
574
|
-
export interface PaginatedAdminUserList {
|
|
575
|
-
/** @example 123 */
|
|
576
|
-
count?: number;
|
|
577
|
-
/**
|
|
578
|
-
* @format uri
|
|
579
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
580
|
-
*/
|
|
581
|
-
next?: string | null;
|
|
582
|
-
/**
|
|
583
|
-
* @format uri
|
|
584
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
585
|
-
*/
|
|
586
|
-
previous?: string | null;
|
|
587
|
-
results?: AdminUser[];
|
|
588
|
-
}
|
|
589
|
-
|
|
590
|
-
export interface PaginatedAdminUserListResponse {
|
|
591
|
-
/** @example "success" */
|
|
592
|
-
status?: string;
|
|
593
|
-
data?: PaginatedAdminUserList;
|
|
594
|
-
}
|
|
595
|
-
|
|
596
|
-
export interface PaginatedCurrencyList {
|
|
597
|
-
/** @example 123 */
|
|
598
|
-
count?: number;
|
|
599
|
-
/**
|
|
600
|
-
* @format uri
|
|
601
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
602
|
-
*/
|
|
603
|
-
next?: string | null;
|
|
604
|
-
/**
|
|
605
|
-
* @format uri
|
|
606
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
607
|
-
*/
|
|
608
|
-
previous?: string | null;
|
|
609
|
-
results?: Currency[];
|
|
610
|
-
}
|
|
611
|
-
|
|
612
|
-
export interface PaginatedCurrencyListResponse {
|
|
613
|
-
/** @example "success" */
|
|
614
|
-
status?: string;
|
|
615
|
-
data?: PaginatedCurrencyList;
|
|
616
|
-
}
|
|
617
|
-
|
|
618
|
-
export interface PaginatedUserCampaignList {
|
|
619
|
-
/** @example 123 */
|
|
620
|
-
count?: number;
|
|
621
|
-
/**
|
|
622
|
-
* @format uri
|
|
623
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
624
|
-
*/
|
|
625
|
-
next?: string | null;
|
|
626
|
-
/**
|
|
627
|
-
* @format uri
|
|
628
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
629
|
-
*/
|
|
630
|
-
previous?: string | null;
|
|
631
|
-
results?: UserCampaign[];
|
|
632
|
-
}
|
|
633
|
-
|
|
634
|
-
export interface PaginatedUserCampaignListResponse {
|
|
635
|
-
/** @example "success" */
|
|
636
|
-
status?: string;
|
|
637
|
-
data?: PaginatedUserCampaignList;
|
|
638
|
-
}
|
|
639
|
-
|
|
640
|
-
export interface PaginatedUserRewardList {
|
|
641
|
-
/** @example 123 */
|
|
642
|
-
count?: number;
|
|
643
|
-
/**
|
|
644
|
-
* @format uri
|
|
645
|
-
* @example "http://api.example.org/accounts/?page=4"
|
|
646
|
-
*/
|
|
647
|
-
next?: string | null;
|
|
648
|
-
/**
|
|
649
|
-
* @format uri
|
|
650
|
-
* @example "http://api.example.org/accounts/?page=2"
|
|
651
|
-
*/
|
|
652
|
-
previous?: string | null;
|
|
653
|
-
results?: UserReward[];
|
|
654
|
-
}
|
|
655
|
-
|
|
656
|
-
export interface PaginatedUserRewardListResponse {
|
|
657
|
-
/** @example "success" */
|
|
658
|
-
status?: string;
|
|
659
|
-
data?: PaginatedUserRewardList;
|
|
660
|
-
}
|
|
661
|
-
|
|
662
|
-
/**
|
|
663
|
-
* A ModelSerializer that takes additional arguments for
|
|
664
|
-
* "fields", "omit" and "expand" in order to
|
|
665
|
-
* control which fields are displayed, and whether to replace simple
|
|
666
|
-
* values with complex, nested serializations
|
|
667
|
-
*/
|
|
668
|
-
export interface PatchedAdminCompany {
|
|
669
|
-
id?: string;
|
|
670
|
-
identifier?: string;
|
|
671
|
-
/** @format uuid */
|
|
672
|
-
secret?: string;
|
|
673
|
-
name?: string;
|
|
674
|
-
operational_account?: string | null;
|
|
675
|
-
}
|
|
676
|
-
|
|
677
|
-
/**
|
|
678
|
-
* A ModelSerializer that takes additional arguments for
|
|
679
|
-
* "fields", "omit" and "expand" in order to
|
|
680
|
-
* control which fields are displayed, and whether to replace simple
|
|
681
|
-
* values with complex, nested serializations
|
|
682
|
-
*/
|
|
683
|
-
export interface PatchedAdminCreateUpdateCampaign {
|
|
684
|
-
id?: string;
|
|
685
|
-
/** @maxLength 50 */
|
|
686
|
-
name?: string;
|
|
687
|
-
/** @format uri */
|
|
688
|
-
image?: string | null;
|
|
689
|
-
/** @maxLength 255 */
|
|
690
|
-
description?: string;
|
|
691
|
-
start_date?: number | null;
|
|
692
|
-
end_date?: number | null;
|
|
693
|
-
currency?: string;
|
|
694
|
-
/** @maxLength 200 */
|
|
695
|
-
credit_account_name?: string | null;
|
|
696
|
-
/** @maxLength 64 */
|
|
697
|
-
credit_account?: string | null;
|
|
698
|
-
account?: string | null;
|
|
699
|
-
total?: number;
|
|
700
|
-
fixed_amount?: number;
|
|
701
|
-
/**
|
|
702
|
-
* @format double
|
|
703
|
-
* @min 0
|
|
704
|
-
* @max 10000000
|
|
705
|
-
* @exclusiveMax true
|
|
706
|
-
*/
|
|
707
|
-
percentage?: number | null;
|
|
708
|
-
balance?: number;
|
|
709
|
-
/**
|
|
710
|
-
* * `percentage` - Percentage
|
|
711
|
-
* * `fixed` - Fixed
|
|
712
|
-
* * `fixedpercentage` - Fixedpercentage
|
|
713
|
-
*/
|
|
714
|
-
type?: "percentage" | "fixed" | "fixedpercentage";
|
|
715
|
-
/**
|
|
716
|
-
* * `pending` - Pending
|
|
717
|
-
* * `accepted` - Accepted
|
|
718
|
-
* * `rejected` - Rejected
|
|
719
|
-
*/
|
|
720
|
-
default_status?: "pending" | "accepted" | "rejected";
|
|
721
|
-
users?: any[];
|
|
722
|
-
groups?: any[];
|
|
723
|
-
/**
|
|
724
|
-
* @min 1
|
|
725
|
-
* @max 1000000000
|
|
726
|
-
*/
|
|
727
|
-
max_per_user?: number | null;
|
|
728
|
-
/**
|
|
729
|
-
* @min 1
|
|
730
|
-
* @max 1000000000
|
|
731
|
-
*/
|
|
732
|
-
max_per_user_per_timeframe?: number | null;
|
|
733
|
-
/**
|
|
734
|
-
* * `daily` - Daily
|
|
735
|
-
* * `weekly` - Weekly
|
|
736
|
-
* * `monthly` - Monthly
|
|
737
|
-
*/
|
|
738
|
-
timeframe?: "daily" | "weekly" | "monthly" | "" | null;
|
|
739
|
-
transactions_currency?: string | null;
|
|
740
|
-
/**
|
|
741
|
-
* @min 1
|
|
742
|
-
* @max 1000000000
|
|
743
|
-
*/
|
|
744
|
-
min_num_transactions?: number | null;
|
|
745
|
-
min_value_transactions?: number | null;
|
|
746
|
-
/** @default true */
|
|
747
|
-
active?: boolean;
|
|
748
|
-
/** @default true */
|
|
749
|
-
visible?: boolean;
|
|
750
|
-
/** @default true */
|
|
751
|
-
claim?: boolean;
|
|
752
|
-
/** @maxLength 250 */
|
|
753
|
-
expression?: string | null;
|
|
754
|
-
/**
|
|
755
|
-
* * `company.link.create` - company.link.create
|
|
756
|
-
* * `company.link.update` - company.link.update
|
|
757
|
-
* * `company.update` - company.update
|
|
758
|
-
* * `currency.create` - currency.create
|
|
759
|
-
* * `currency.update` - currency.update
|
|
760
|
-
* * `user.create` - user.create
|
|
761
|
-
* * `user.update` - user.update
|
|
762
|
-
* * `user.password.reset` - user.password.reset
|
|
763
|
-
* * `user.password.set` - user.password.set
|
|
764
|
-
* * `user.deactivate.verify` - user.deactivate.verify
|
|
765
|
-
* * `user.request_delete.verify` - user.request_delete.verify
|
|
766
|
-
* * `user.email.verify` - user.email.verify
|
|
767
|
-
* * `user.mobile.verify` - user.mobile.verify
|
|
768
|
-
* * `email.create` - email.create
|
|
769
|
-
* * `email.update` - email.update
|
|
770
|
-
* * `mobile.create` - mobile.create
|
|
771
|
-
* * `mobile.update` - mobile.update
|
|
772
|
-
* * `address.create` - address.create
|
|
773
|
-
* * `address.update` - address.update
|
|
774
|
-
* * `document.create` - document.create
|
|
775
|
-
* * `document.update` - document.update
|
|
776
|
-
* * `bank_account.create` - bank_account.create
|
|
777
|
-
* * `bank_account.update` - bank_account.update
|
|
778
|
-
* * `crypto_account.create` - crypto_account.create
|
|
779
|
-
* * `crypto_account.update` - crypto_account.update
|
|
780
|
-
* * `account.create` - account.create
|
|
781
|
-
* * `account.update` - account.update
|
|
782
|
-
* * `transaction.create` - transaction.create
|
|
783
|
-
* * `transaction.update` - transaction.update
|
|
784
|
-
* * `transaction.initiate` - transaction.initiate
|
|
785
|
-
* * `transaction.execute` - transaction.execute
|
|
786
|
-
* * `transaction.transition.create` - transaction.transition.create
|
|
787
|
-
* * `transaction.transition.update` - transaction.transition.update
|
|
788
|
-
* * `mfa.sms.verify` - mfa.sms.verify
|
|
789
|
-
*/
|
|
790
|
-
event?:
|
|
791
|
-
| "company.link.create"
|
|
792
|
-
| "company.link.update"
|
|
793
|
-
| "company.update"
|
|
794
|
-
| "currency.create"
|
|
795
|
-
| "currency.update"
|
|
796
|
-
| "user.create"
|
|
797
|
-
| "user.update"
|
|
798
|
-
| "user.password.reset"
|
|
799
|
-
| "user.password.set"
|
|
800
|
-
| "user.deactivate.verify"
|
|
801
|
-
| "user.request_delete.verify"
|
|
802
|
-
| "user.email.verify"
|
|
803
|
-
| "user.mobile.verify"
|
|
804
|
-
| "email.create"
|
|
805
|
-
| "email.update"
|
|
806
|
-
| "mobile.create"
|
|
807
|
-
| "mobile.update"
|
|
808
|
-
| "address.create"
|
|
809
|
-
| "address.update"
|
|
810
|
-
| "document.create"
|
|
811
|
-
| "document.update"
|
|
812
|
-
| "bank_account.create"
|
|
813
|
-
| "bank_account.update"
|
|
814
|
-
| "crypto_account.create"
|
|
815
|
-
| "crypto_account.update"
|
|
816
|
-
| "account.create"
|
|
817
|
-
| "account.update"
|
|
818
|
-
| "transaction.create"
|
|
819
|
-
| "transaction.update"
|
|
820
|
-
| "transaction.initiate"
|
|
821
|
-
| "transaction.execute"
|
|
822
|
-
| "transaction.transition.create"
|
|
823
|
-
| "transaction.transition.update"
|
|
824
|
-
| "mfa.sms.verify"
|
|
825
|
-
| ""
|
|
826
|
-
| null;
|
|
827
|
-
/** @maxLength 150 */
|
|
828
|
-
event_user?: string | null;
|
|
829
|
-
/** @maxLength 150 */
|
|
830
|
-
event_amount?: string | null;
|
|
831
|
-
}
|
|
832
|
-
|
|
833
|
-
/**
|
|
834
|
-
* A ModelSerializer that takes additional arguments for
|
|
835
|
-
* "fields", "omit" and "expand" in order to
|
|
836
|
-
* control which fields are displayed, and whether to replace simple
|
|
837
|
-
* values with complex, nested serializations
|
|
838
|
-
*/
|
|
839
|
-
export interface PatchedAdminReward {
|
|
840
|
-
id?: string;
|
|
841
|
-
user?: string;
|
|
842
|
-
campaign?: Campaign;
|
|
843
|
-
currency?: Currency;
|
|
844
|
-
amount?: number;
|
|
845
|
-
/**
|
|
846
|
-
* * `pending` - Pending
|
|
847
|
-
* * `accepted` - Accepted
|
|
848
|
-
* * `rejected` - Rejected
|
|
849
|
-
*/
|
|
850
|
-
status?: "pending" | "accepted" | "rejected";
|
|
851
|
-
collection?: string | null;
|
|
852
|
-
type?: string;
|
|
853
|
-
created?: number;
|
|
854
|
-
}
|
|
855
|
-
|
|
856
|
-
/**
|
|
857
|
-
* A ModelSerializer that takes additional arguments for
|
|
858
|
-
* "fields", "omit" and "expand" in order to
|
|
859
|
-
* control which fields are displayed, and whether to replace simple
|
|
860
|
-
* values with complex, nested serializations
|
|
861
|
-
*/
|
|
862
|
-
export interface PatchedUserUpdateReferral {
|
|
863
|
-
referral_code?: string | null;
|
|
864
|
-
referee_code?: string;
|
|
865
|
-
}
|
|
866
|
-
|
|
867
|
-
/**
|
|
868
|
-
* A ModelSerializer that takes additional arguments for
|
|
869
|
-
* "fields", "omit" and "expand" in order to
|
|
870
|
-
* control which fields are displayed, and whether to replace simple
|
|
871
|
-
* values with complex, nested serializations
|
|
872
|
-
*/
|
|
873
|
-
export interface User {
|
|
874
|
-
id: string;
|
|
875
|
-
referral_code: string | null;
|
|
876
|
-
referee_code: string | null;
|
|
877
|
-
}
|
|
878
|
-
|
|
879
|
-
/**
|
|
880
|
-
* A ModelSerializer that takes additional arguments for
|
|
881
|
-
* "fields", "omit" and "expand" in order to
|
|
882
|
-
* control which fields are displayed, and whether to replace simple
|
|
883
|
-
* values with complex, nested serializations
|
|
884
|
-
*/
|
|
885
|
-
export interface UserCampaign {
|
|
886
|
-
id: string;
|
|
887
|
-
/** @maxLength 50 */
|
|
888
|
-
name?: string;
|
|
889
|
-
description: string;
|
|
890
|
-
/** @format uri */
|
|
891
|
-
image?: string | null;
|
|
892
|
-
start_date: number;
|
|
893
|
-
end_date: number;
|
|
894
|
-
/**
|
|
895
|
-
* A ModelSerializer that takes additional arguments for
|
|
896
|
-
* "fields", "omit" and "expand" in order to
|
|
897
|
-
* control which fields are displayed, and whether to replace simple
|
|
898
|
-
* values with complex, nested serializations
|
|
899
|
-
*/
|
|
900
|
-
currency: Currency;
|
|
901
|
-
total: number;
|
|
902
|
-
fixed_amount: number;
|
|
903
|
-
/**
|
|
904
|
-
* @format decimal
|
|
905
|
-
* @pattern ^-?\d{0,7}(?:\.\d{0,2})?$
|
|
906
|
-
*/
|
|
907
|
-
percentage?: string | null;
|
|
908
|
-
balance: number;
|
|
909
|
-
type: string;
|
|
910
|
-
default_status: string;
|
|
911
|
-
users?: any[];
|
|
912
|
-
groups?: any[];
|
|
913
|
-
/**
|
|
914
|
-
* @min -2147483648
|
|
915
|
-
* @max 2147483647
|
|
916
|
-
*/
|
|
917
|
-
max_per_user?: number | null;
|
|
918
|
-
/**
|
|
919
|
-
* @min -2147483648
|
|
920
|
-
* @max 2147483647
|
|
921
|
-
*/
|
|
922
|
-
max_per_user_per_timeframe?: number | null;
|
|
923
|
-
timeframe?: string;
|
|
924
|
-
/**
|
|
925
|
-
* A ModelSerializer that takes additional arguments for
|
|
926
|
-
* "fields", "omit" and "expand" in order to
|
|
927
|
-
* control which fields are displayed, and whether to replace simple
|
|
928
|
-
* values with complex, nested serializations
|
|
929
|
-
*/
|
|
930
|
-
transactions_currency: Currency;
|
|
931
|
-
/**
|
|
932
|
-
* @min 1
|
|
933
|
-
* @max 1000000000
|
|
934
|
-
*/
|
|
935
|
-
min_num_transactions?: number | null;
|
|
936
|
-
min_value_transactions: number | null;
|
|
937
|
-
active?: boolean;
|
|
938
|
-
claim?: boolean;
|
|
939
|
-
}
|
|
940
|
-
|
|
941
|
-
export interface UserCampaignResponse {
|
|
942
|
-
/** @example "success" */
|
|
943
|
-
status?: string;
|
|
944
|
-
/**
|
|
945
|
-
* A ModelSerializer that takes additional arguments for
|
|
946
|
-
* "fields", "omit" and "expand" in order to
|
|
947
|
-
* control which fields are displayed, and whether to replace simple
|
|
948
|
-
* values with complex, nested serializations
|
|
949
|
-
*/
|
|
950
|
-
data?: UserCampaign;
|
|
951
|
-
}
|
|
952
|
-
|
|
953
|
-
/**
|
|
954
|
-
* A ModelSerializer that takes additional arguments for
|
|
955
|
-
* "fields", "omit" and "expand" in order to
|
|
956
|
-
* control which fields are displayed, and whether to replace simple
|
|
957
|
-
* values with complex, nested serializations
|
|
958
|
-
*/
|
|
959
|
-
export interface UserCreateReward {
|
|
960
|
-
id: string;
|
|
961
|
-
user: string;
|
|
962
|
-
campaign: string;
|
|
963
|
-
currency: Currency;
|
|
964
|
-
amount: number;
|
|
965
|
-
status: string;
|
|
966
|
-
collection: string | null;
|
|
967
|
-
created: number;
|
|
968
|
-
data?: Record<string, any>;
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
export interface UserResponse {
|
|
972
|
-
/** @example "success" */
|
|
973
|
-
status?: string;
|
|
974
|
-
/**
|
|
975
|
-
* A ModelSerializer that takes additional arguments for
|
|
976
|
-
* "fields", "omit" and "expand" in order to
|
|
977
|
-
* control which fields are displayed, and whether to replace simple
|
|
978
|
-
* values with complex, nested serializations
|
|
979
|
-
*/
|
|
980
|
-
data?: User;
|
|
981
|
-
}
|
|
982
|
-
|
|
983
|
-
/**
|
|
984
|
-
* A ModelSerializer that takes additional arguments for
|
|
985
|
-
* "fields", "omit" and "expand" in order to
|
|
986
|
-
* control which fields are displayed, and whether to replace simple
|
|
987
|
-
* values with complex, nested serializations
|
|
988
|
-
*/
|
|
989
|
-
export interface UserReward {
|
|
990
|
-
id: string;
|
|
991
|
-
user: string;
|
|
992
|
-
campaign: Campaign;
|
|
993
|
-
currency: Currency;
|
|
994
|
-
amount: number;
|
|
995
|
-
status: string;
|
|
996
|
-
type: string;
|
|
997
|
-
/** @maxLength 64 */
|
|
998
|
-
collection?: string | null;
|
|
999
|
-
created: number;
|
|
1000
|
-
}
|
|
1001
|
-
|
|
1002
|
-
export interface UserRewardResponse {
|
|
1003
|
-
/** @example "success" */
|
|
1004
|
-
status?: string;
|
|
1005
|
-
/**
|
|
1006
|
-
* A ModelSerializer that takes additional arguments for
|
|
1007
|
-
* "fields", "omit" and "expand" in order to
|
|
1008
|
-
* control which fields are displayed, and whether to replace simple
|
|
1009
|
-
* values with complex, nested serializations
|
|
1010
|
-
*/
|
|
1011
|
-
data?: UserReward;
|
|
1012
|
-
}
|
|
1013
|
-
|
|
1014
|
-
/**
|
|
1015
|
-
* A ModelSerializer that takes additional arguments for
|
|
1016
|
-
* "fields", "omit" and "expand" in order to
|
|
1017
|
-
* control which fields are displayed, and whether to replace simple
|
|
1018
|
-
* values with complex, nested serializations
|
|
1019
|
-
*/
|
|
1020
|
-
export interface UserUpdateReferral {
|
|
1021
|
-
referral_code: string | null;
|
|
1022
|
-
referee_code: string;
|
|
1023
|
-
}
|
|
1024
|
-
|
|
1025
|
-
export interface Webhook {
|
|
1026
|
-
id: string;
|
|
1027
|
-
/**
|
|
1028
|
-
* * `company.link.create` - company.link.create
|
|
1029
|
-
* * `company.link.update` - company.link.update
|
|
1030
|
-
* * `company.update` - company.update
|
|
1031
|
-
* * `currency.create` - currency.create
|
|
1032
|
-
* * `currency.update` - currency.update
|
|
1033
|
-
* * `user.create` - user.create
|
|
1034
|
-
* * `user.update` - user.update
|
|
1035
|
-
* * `user.password.reset` - user.password.reset
|
|
1036
|
-
* * `user.password.set` - user.password.set
|
|
1037
|
-
* * `user.deactivate.verify` - user.deactivate.verify
|
|
1038
|
-
* * `user.request_delete.verify` - user.request_delete.verify
|
|
1039
|
-
* * `user.email.verify` - user.email.verify
|
|
1040
|
-
* * `user.mobile.verify` - user.mobile.verify
|
|
1041
|
-
* * `email.create` - email.create
|
|
1042
|
-
* * `email.update` - email.update
|
|
1043
|
-
* * `mobile.create` - mobile.create
|
|
1044
|
-
* * `mobile.update` - mobile.update
|
|
1045
|
-
* * `address.create` - address.create
|
|
1046
|
-
* * `address.update` - address.update
|
|
1047
|
-
* * `document.create` - document.create
|
|
1048
|
-
* * `document.update` - document.update
|
|
1049
|
-
* * `bank_account.create` - bank_account.create
|
|
1050
|
-
* * `bank_account.update` - bank_account.update
|
|
1051
|
-
* * `crypto_account.create` - crypto_account.create
|
|
1052
|
-
* * `crypto_account.update` - crypto_account.update
|
|
1053
|
-
* * `account.create` - account.create
|
|
1054
|
-
* * `account.update` - account.update
|
|
1055
|
-
* * `transaction.create` - transaction.create
|
|
1056
|
-
* * `transaction.update` - transaction.update
|
|
1057
|
-
* * `transaction.initiate` - transaction.initiate
|
|
1058
|
-
* * `transaction.execute` - transaction.execute
|
|
1059
|
-
* * `transaction.transition.create` - transaction.transition.create
|
|
1060
|
-
* * `transaction.transition.update` - transaction.transition.update
|
|
1061
|
-
* * `mfa.sms.verify` - mfa.sms.verify
|
|
1062
|
-
*/
|
|
1063
|
-
event:
|
|
1064
|
-
| "company.link.create"
|
|
1065
|
-
| "company.link.update"
|
|
1066
|
-
| "company.update"
|
|
1067
|
-
| "currency.create"
|
|
1068
|
-
| "currency.update"
|
|
1069
|
-
| "user.create"
|
|
1070
|
-
| "user.update"
|
|
1071
|
-
| "user.password.reset"
|
|
1072
|
-
| "user.password.set"
|
|
1073
|
-
| "user.deactivate.verify"
|
|
1074
|
-
| "user.request_delete.verify"
|
|
1075
|
-
| "user.email.verify"
|
|
1076
|
-
| "user.mobile.verify"
|
|
1077
|
-
| "email.create"
|
|
1078
|
-
| "email.update"
|
|
1079
|
-
| "mobile.create"
|
|
1080
|
-
| "mobile.update"
|
|
1081
|
-
| "address.create"
|
|
1082
|
-
| "address.update"
|
|
1083
|
-
| "document.create"
|
|
1084
|
-
| "document.update"
|
|
1085
|
-
| "bank_account.create"
|
|
1086
|
-
| "bank_account.update"
|
|
1087
|
-
| "crypto_account.create"
|
|
1088
|
-
| "crypto_account.update"
|
|
1089
|
-
| "account.create"
|
|
1090
|
-
| "account.update"
|
|
1091
|
-
| "transaction.create"
|
|
1092
|
-
| "transaction.update"
|
|
1093
|
-
| "transaction.initiate"
|
|
1094
|
-
| "transaction.execute"
|
|
1095
|
-
| "transaction.transition.create"
|
|
1096
|
-
| "transaction.transition.update"
|
|
1097
|
-
| "mfa.sms.verify";
|
|
1098
|
-
company: string;
|
|
1099
|
-
data: Record<string, any>;
|
|
1100
|
-
}
|
|
1101
|
-
|
|
1102
|
-
export type ActivateCreateData = ActionResponse;
|
|
1103
|
-
|
|
1104
|
-
export interface AdminCampaignsListParams {
|
|
1105
|
-
active?: boolean;
|
|
1106
|
-
available?: string;
|
|
1107
|
-
currency?: string;
|
|
1108
|
-
end_date?: string;
|
|
1109
|
-
end_date__gt?: string;
|
|
1110
|
-
end_date__lt?: string;
|
|
1111
|
-
/** @format uuid */
|
|
1112
|
-
id?: string;
|
|
1113
|
-
name__contains?: string;
|
|
1114
|
-
/** A page number within the paginated result set. */
|
|
1115
|
-
page?: number;
|
|
1116
|
-
/** Number of results to return per page. */
|
|
1117
|
-
page_size?: number;
|
|
1118
|
-
search?: string;
|
|
1119
|
-
start_date?: string;
|
|
1120
|
-
start_date__gt?: string;
|
|
1121
|
-
start_date__lt?: string;
|
|
1122
|
-
type?: string;
|
|
1123
|
-
visible?: boolean;
|
|
1124
|
-
}
|
|
1125
|
-
|
|
1126
|
-
export type AdminCampaignsListData = PaginatedAdminCampaignListResponse;
|
|
1127
|
-
|
|
1128
|
-
export type AdminCampaignsCreateData = AdminCampaignResponse;
|
|
1129
|
-
|
|
1130
|
-
export type AdminCampaignsRetrieveData = AdminCampaignResponse;
|
|
1131
|
-
|
|
1132
|
-
export type AdminCampaignsUpdateData = AdminCampaignResponse;
|
|
1133
|
-
|
|
1134
|
-
export type AdminCampaignsPartialUpdateData = AdminCampaignResponse;
|
|
1135
|
-
|
|
1136
|
-
export type AdminCampaignsDestroyData = AdminCampaignResponse;
|
|
1137
|
-
|
|
1138
|
-
export type AdminCompanyRetrieveData = AdminCompanyResponse;
|
|
1139
|
-
|
|
1140
|
-
export type AdminCompanyUpdateData = AdminCompanyResponse;
|
|
1141
|
-
|
|
1142
|
-
export type AdminCompanyPartialUpdateData = AdminCompanyResponse;
|
|
1143
|
-
|
|
1144
|
-
export interface AdminCurrenciesListParams {
|
|
1145
|
-
code?: string;
|
|
1146
|
-
/** A page number within the paginated result set. */
|
|
1147
|
-
page?: number;
|
|
1148
|
-
/** Number of results to return per page. */
|
|
1149
|
-
page_size?: number;
|
|
1150
|
-
}
|
|
1151
|
-
|
|
1152
|
-
export type AdminCurrenciesListData = PaginatedCurrencyListResponse;
|
|
1153
|
-
|
|
1154
|
-
export type AdminCurrenciesRetrieveData = CurrencyResponse;
|
|
1155
|
-
|
|
1156
|
-
export interface AdminRewardsListParams {
|
|
1157
|
-
campaign?: string;
|
|
1158
|
-
currency?: string;
|
|
1159
|
-
/** @format uuid */
|
|
1160
|
-
id?: string;
|
|
1161
|
-
/** A page number within the paginated result set. */
|
|
1162
|
-
page?: number;
|
|
1163
|
-
/** Number of results to return per page. */
|
|
1164
|
-
page_size?: number;
|
|
1165
|
-
status?: string;
|
|
1166
|
-
status__in?: string;
|
|
1167
|
-
type?: string;
|
|
1168
|
-
user?: string;
|
|
1169
|
-
}
|
|
1170
|
-
|
|
1171
|
-
export type AdminRewardsListData = PaginatedAdminRewardListResponse;
|
|
1172
|
-
|
|
1173
|
-
export type AdminRewardsCreateData = AdminRewardResponse;
|
|
1174
|
-
|
|
1175
|
-
export type AdminRewardsRetrieveData = AdminRewardResponse;
|
|
1176
|
-
|
|
1177
|
-
export type AdminRewardsUpdateData = AdminRewardResponse;
|
|
1178
|
-
|
|
1179
|
-
export type AdminRewardsPartialUpdateData = AdminRewardResponse;
|
|
1180
|
-
|
|
1181
|
-
export interface AdminUsersListParams {
|
|
1182
|
-
/** @format uuid */
|
|
1183
|
-
id?: string;
|
|
1184
|
-
/** A page number within the paginated result set. */
|
|
1185
|
-
page?: number;
|
|
1186
|
-
/** Number of results to return per page. */
|
|
1187
|
-
page_size?: number;
|
|
1188
|
-
referee_code?: string;
|
|
1189
|
-
referral_code?: string;
|
|
1190
|
-
}
|
|
1191
|
-
|
|
1192
|
-
export type AdminUsersListData = PaginatedAdminUserListResponse;
|
|
1193
|
-
|
|
1194
|
-
export type AdminUsersRetrieveData = AdminUserResponse;
|
|
1195
|
-
|
|
1196
|
-
export type AdminWebhookCreateData = ActionResponse;
|
|
1197
|
-
|
|
1198
|
-
export type DeactivateCreateData = ActionResponse;
|
|
1199
|
-
|
|
1200
|
-
export type UserRetrieveData = UserResponse;
|
|
1201
|
-
|
|
1202
|
-
export type UserUpdateData = UserResponse;
|
|
1203
|
-
|
|
1204
|
-
export type UserPartialUpdateData = UserResponse;
|
|
1205
|
-
|
|
1206
|
-
export interface UserCampaignsListParams {
|
|
1207
|
-
active?: boolean;
|
|
1208
|
-
available?: string;
|
|
1209
|
-
currency?: string;
|
|
1210
|
-
end_date?: string;
|
|
1211
|
-
end_date__gt?: string;
|
|
1212
|
-
end_date__lt?: string;
|
|
1213
|
-
/** @format uuid */
|
|
1214
|
-
id?: string;
|
|
1215
|
-
name__contains?: string;
|
|
1216
|
-
/** A page number within the paginated result set. */
|
|
1217
|
-
page?: number;
|
|
1218
|
-
/** Number of results to return per page. */
|
|
1219
|
-
page_size?: number;
|
|
1220
|
-
search?: string;
|
|
1221
|
-
start_date?: string;
|
|
1222
|
-
start_date__gt?: string;
|
|
1223
|
-
start_date__lt?: string;
|
|
1224
|
-
type?: string;
|
|
1225
|
-
visible?: boolean;
|
|
1226
|
-
}
|
|
1227
|
-
|
|
1228
|
-
export type UserCampaignsListData = PaginatedUserCampaignListResponse;
|
|
1229
|
-
|
|
1230
|
-
export type UserCampaignsRetrieveData = UserCampaignResponse;
|
|
1231
|
-
|
|
1232
|
-
export interface UserRewardsListParams {
|
|
1233
|
-
campaign?: string;
|
|
1234
|
-
currency?: string;
|
|
1235
|
-
/** @format uuid */
|
|
1236
|
-
id?: string;
|
|
1237
|
-
/** A page number within the paginated result set. */
|
|
1238
|
-
page?: number;
|
|
1239
|
-
/** Number of results to return per page. */
|
|
1240
|
-
page_size?: number;
|
|
1241
|
-
status?: string;
|
|
1242
|
-
status__in?: string;
|
|
1243
|
-
type?: string;
|
|
1244
|
-
}
|
|
1245
|
-
|
|
1246
|
-
export type UserRewardsListData = PaginatedUserRewardListResponse;
|
|
1247
|
-
|
|
1248
|
-
export type UserRewardsCreateData = UserRewardResponse;
|
|
1249
|
-
|
|
1250
|
-
export type UserRewardsRetrieveData = UserRewardResponse;
|
|
1251
|
-
|
|
1252
|
-
export type WebhookCreateData = ActionResponse;
|
|
1253
|
-
|
|
1254
|
-
export type QueryParamsType = Record<string | number, any>;
|
|
1255
|
-
export type ResponseFormat = keyof Omit<Body, "body" | "bodyUsed">;
|
|
1256
|
-
|
|
1257
|
-
export interface FullRequestParams extends Omit<RequestInit, "body"> {
|
|
1258
|
-
/** set parameter to `true` for call `securityWorker` for this request */
|
|
1259
|
-
secure?: boolean;
|
|
1260
|
-
/** request path */
|
|
1261
|
-
path: string;
|
|
1262
|
-
/** content type of request body */
|
|
1263
|
-
type?: ContentType;
|
|
1264
|
-
/** query params */
|
|
1265
|
-
query?: QueryParamsType;
|
|
1266
|
-
/** format of response (i.e. response.json() -> format: "json") */
|
|
1267
|
-
format?: ResponseFormat;
|
|
1268
|
-
/** request body */
|
|
1269
|
-
body?: unknown;
|
|
1270
|
-
/** base url */
|
|
1271
|
-
baseUrl?: string;
|
|
1272
|
-
/** request cancellation token */
|
|
1273
|
-
cancelToken?: CancelToken;
|
|
1274
|
-
}
|
|
1275
|
-
|
|
1276
|
-
export type RequestParams = Omit<
|
|
1277
|
-
FullRequestParams,
|
|
1278
|
-
"body" | "method" | "query" | "path"
|
|
1279
|
-
>;
|
|
1280
|
-
|
|
1281
|
-
export interface ApiConfig<SecurityDataType = unknown> {
|
|
1282
|
-
baseUrl?: string;
|
|
1283
|
-
baseApiParams?: Omit<RequestParams, "baseUrl" | "cancelToken" | "signal">;
|
|
1284
|
-
securityWorker?: (
|
|
1285
|
-
securityData: SecurityDataType | null,
|
|
1286
|
-
) => Promise<RequestParams | void> | RequestParams | void;
|
|
1287
|
-
customFetch?: typeof fetch;
|
|
1288
|
-
}
|
|
1289
|
-
|
|
1290
|
-
export interface HttpResponse<D extends unknown, E extends unknown = unknown>
|
|
1291
|
-
extends Response {
|
|
1292
|
-
data: D;
|
|
1293
|
-
error: E;
|
|
1294
|
-
}
|
|
1295
|
-
|
|
1296
|
-
type CancelToken = Symbol | string | number;
|
|
1297
|
-
|
|
1298
|
-
export enum ContentType {
|
|
1299
|
-
Json = "application/json",
|
|
1300
|
-
JsonApi = "application/vnd.api+json",
|
|
1301
|
-
FormData = "multipart/form-data",
|
|
1302
|
-
UrlEncoded = "application/x-www-form-urlencoded",
|
|
1303
|
-
Text = "text/plain",
|
|
1304
|
-
}
|
|
1305
|
-
|
|
1306
|
-
export class HttpClient<SecurityDataType = unknown> {
|
|
1307
|
-
public baseUrl: string = "https://reward.services.rehive.io/api/";
|
|
1308
|
-
private securityData: SecurityDataType | null = null;
|
|
1309
|
-
private securityWorker?: ApiConfig<SecurityDataType>["securityWorker"];
|
|
1310
|
-
private abortControllers = new Map<CancelToken, AbortController>();
|
|
1311
|
-
private customFetch = (...fetchParams: Parameters<typeof fetch>) =>
|
|
1312
|
-
fetch(...fetchParams);
|
|
1313
|
-
|
|
1314
|
-
private baseApiParams: RequestParams = {
|
|
1315
|
-
credentials: "same-origin",
|
|
1316
|
-
headers: {},
|
|
1317
|
-
redirect: "follow",
|
|
1318
|
-
referrerPolicy: "no-referrer",
|
|
1319
|
-
};
|
|
1320
|
-
|
|
1321
|
-
constructor(apiConfig: ApiConfig<SecurityDataType> = {}) {
|
|
1322
|
-
Object.assign(this, apiConfig);
|
|
1323
|
-
}
|
|
1324
|
-
|
|
1325
|
-
public setSecurityData = (data: SecurityDataType | null) => {
|
|
1326
|
-
this.securityData = data;
|
|
1327
|
-
};
|
|
1328
|
-
|
|
1329
|
-
protected encodeQueryParam(key: string, value: any) {
|
|
1330
|
-
const encodedKey = encodeURIComponent(key);
|
|
1331
|
-
return `${encodedKey}=${encodeURIComponent(typeof value === "number" ? value : `${value}`)}`;
|
|
1332
|
-
}
|
|
1333
|
-
|
|
1334
|
-
protected addQueryParam(query: QueryParamsType, key: string) {
|
|
1335
|
-
return this.encodeQueryParam(key, query[key]);
|
|
1336
|
-
}
|
|
1337
|
-
|
|
1338
|
-
protected addArrayQueryParam(query: QueryParamsType, key: string) {
|
|
1339
|
-
const value = query[key];
|
|
1340
|
-
return value.map((v: any) => this.encodeQueryParam(key, v)).join("&");
|
|
1341
|
-
}
|
|
1342
|
-
|
|
1343
|
-
protected toQueryString(rawQuery?: QueryParamsType): string {
|
|
1344
|
-
const query = rawQuery || {};
|
|
1345
|
-
const keys = Object.keys(query).filter(
|
|
1346
|
-
(key) => "undefined" !== typeof query[key],
|
|
1347
|
-
);
|
|
1348
|
-
return keys
|
|
1349
|
-
.map((key) =>
|
|
1350
|
-
Array.isArray(query[key])
|
|
1351
|
-
? this.addArrayQueryParam(query, key)
|
|
1352
|
-
: this.addQueryParam(query, key),
|
|
1353
|
-
)
|
|
1354
|
-
.join("&");
|
|
1355
|
-
}
|
|
1356
|
-
|
|
1357
|
-
protected addQueryParams(rawQuery?: QueryParamsType): string {
|
|
1358
|
-
const queryString = this.toQueryString(rawQuery);
|
|
1359
|
-
return queryString ? `?${queryString}` : "";
|
|
1360
|
-
}
|
|
1361
|
-
|
|
1362
|
-
private contentFormatters: Record<ContentType, (input: any) => any> = {
|
|
1363
|
-
[ContentType.Json]: (input: any) =>
|
|
1364
|
-
input !== null && (typeof input === "object" || typeof input === "string")
|
|
1365
|
-
? JSON.stringify(input)
|
|
1366
|
-
: input,
|
|
1367
|
-
[ContentType.JsonApi]: (input: any) =>
|
|
1368
|
-
input !== null && (typeof input === "object" || typeof input === "string")
|
|
1369
|
-
? JSON.stringify(input)
|
|
1370
|
-
: input,
|
|
1371
|
-
[ContentType.Text]: (input: any) =>
|
|
1372
|
-
input !== null && typeof input !== "string"
|
|
1373
|
-
? JSON.stringify(input)
|
|
1374
|
-
: input,
|
|
1375
|
-
[ContentType.FormData]: (input: any) =>
|
|
1376
|
-
Object.keys(input || {}).reduce((formData, key) => {
|
|
1377
|
-
const property = input[key];
|
|
1378
|
-
formData.append(
|
|
1379
|
-
key,
|
|
1380
|
-
property instanceof Blob
|
|
1381
|
-
? property
|
|
1382
|
-
: typeof property === "object" && property !== null
|
|
1383
|
-
? JSON.stringify(property)
|
|
1384
|
-
: `${property}`,
|
|
1385
|
-
);
|
|
1386
|
-
return formData;
|
|
1387
|
-
}, new FormData()),
|
|
1388
|
-
[ContentType.UrlEncoded]: (input: any) => this.toQueryString(input),
|
|
1389
|
-
};
|
|
1390
|
-
|
|
1391
|
-
protected mergeRequestParams(
|
|
1392
|
-
params1: RequestParams,
|
|
1393
|
-
params2?: RequestParams,
|
|
1394
|
-
): RequestParams {
|
|
1395
|
-
return {
|
|
1396
|
-
...this.baseApiParams,
|
|
1397
|
-
...params1,
|
|
1398
|
-
...(params2 || {}),
|
|
1399
|
-
headers: {
|
|
1400
|
-
...(this.baseApiParams.headers || {}),
|
|
1401
|
-
...(params1.headers || {}),
|
|
1402
|
-
...((params2 && params2.headers) || {}),
|
|
1403
|
-
},
|
|
1404
|
-
};
|
|
1405
|
-
}
|
|
1406
|
-
|
|
1407
|
-
protected createAbortSignal = (
|
|
1408
|
-
cancelToken: CancelToken,
|
|
1409
|
-
): AbortSignal | undefined => {
|
|
1410
|
-
if (this.abortControllers.has(cancelToken)) {
|
|
1411
|
-
const abortController = this.abortControllers.get(cancelToken);
|
|
1412
|
-
if (abortController) {
|
|
1413
|
-
return abortController.signal;
|
|
1414
|
-
}
|
|
1415
|
-
return void 0;
|
|
1416
|
-
}
|
|
1417
|
-
|
|
1418
|
-
const abortController = new AbortController();
|
|
1419
|
-
this.abortControllers.set(cancelToken, abortController);
|
|
1420
|
-
return abortController.signal;
|
|
1421
|
-
};
|
|
1422
|
-
|
|
1423
|
-
public abortRequest = (cancelToken: CancelToken) => {
|
|
1424
|
-
const abortController = this.abortControllers.get(cancelToken);
|
|
1425
|
-
|
|
1426
|
-
if (abortController) {
|
|
1427
|
-
abortController.abort();
|
|
1428
|
-
this.abortControllers.delete(cancelToken);
|
|
1429
|
-
}
|
|
1430
|
-
};
|
|
1431
|
-
|
|
1432
|
-
public request = async <T = any, E = any>({
|
|
1433
|
-
body,
|
|
1434
|
-
secure,
|
|
1435
|
-
path,
|
|
1436
|
-
type,
|
|
1437
|
-
query,
|
|
1438
|
-
format,
|
|
1439
|
-
baseUrl,
|
|
1440
|
-
cancelToken,
|
|
1441
|
-
...params
|
|
1442
|
-
}: FullRequestParams): Promise<HttpResponse<T, E>> => {
|
|
1443
|
-
const secureParams =
|
|
1444
|
-
((typeof secure === "boolean" ? secure : this.baseApiParams.secure) &&
|
|
1445
|
-
this.securityWorker &&
|
|
1446
|
-
(await this.securityWorker(this.securityData))) ||
|
|
1447
|
-
{};
|
|
1448
|
-
const requestParams = this.mergeRequestParams(params, secureParams);
|
|
1449
|
-
const queryString = query && this.toQueryString(query);
|
|
1450
|
-
const payloadFormatter = this.contentFormatters[type || ContentType.Json];
|
|
1451
|
-
const responseFormat = format || requestParams.format;
|
|
1452
|
-
|
|
1453
|
-
return this.customFetch(
|
|
1454
|
-
`${baseUrl || this.baseUrl || ""}${path}${queryString ? `?${queryString}` : ""}`,
|
|
1455
|
-
{
|
|
1456
|
-
...requestParams,
|
|
1457
|
-
headers: {
|
|
1458
|
-
...(requestParams.headers || {}),
|
|
1459
|
-
...(type && type !== ContentType.FormData
|
|
1460
|
-
? { "Content-Type": type }
|
|
1461
|
-
: {}),
|
|
1462
|
-
},
|
|
1463
|
-
signal:
|
|
1464
|
-
(cancelToken
|
|
1465
|
-
? this.createAbortSignal(cancelToken)
|
|
1466
|
-
: requestParams.signal) || null,
|
|
1467
|
-
body:
|
|
1468
|
-
typeof body === "undefined" || body === null
|
|
1469
|
-
? null
|
|
1470
|
-
: payloadFormatter(body),
|
|
1471
|
-
},
|
|
1472
|
-
).then(async (response) => {
|
|
1473
|
-
const r = response.clone() as HttpResponse<T, E>;
|
|
1474
|
-
r.data = null as unknown as T;
|
|
1475
|
-
r.error = null as unknown as E;
|
|
1476
|
-
|
|
1477
|
-
const data = !responseFormat
|
|
1478
|
-
? r
|
|
1479
|
-
: await response[responseFormat]()
|
|
1480
|
-
.then((data) => {
|
|
1481
|
-
if (r.ok) {
|
|
1482
|
-
r.data = data;
|
|
1483
|
-
} else {
|
|
1484
|
-
r.error = data;
|
|
1485
|
-
}
|
|
1486
|
-
return r;
|
|
1487
|
-
})
|
|
1488
|
-
.catch((e) => {
|
|
1489
|
-
r.error = e;
|
|
1490
|
-
return r;
|
|
1491
|
-
});
|
|
1492
|
-
|
|
1493
|
-
if (cancelToken) {
|
|
1494
|
-
this.abortControllers.delete(cancelToken);
|
|
1495
|
-
}
|
|
1496
|
-
|
|
1497
|
-
if (!response.ok) throw data;
|
|
1498
|
-
return data;
|
|
1499
|
-
});
|
|
1500
|
-
};
|
|
1501
|
-
}
|
|
1502
|
-
|
|
1503
|
-
/**
|
|
1504
|
-
* @title Reward Service API
|
|
1505
|
-
* @version 1 (1)
|
|
1506
|
-
* @termsOfService https://rehive.com/terms/
|
|
1507
|
-
* @baseUrl https://reward.services.rehive.io/api/
|
|
1508
|
-
* @externalDocs https://docs.rehive.com
|
|
1509
|
-
* @contact Rehive Support <support@rehive.com> (https://rehive.com/support/)
|
|
1510
|
-
*
|
|
1511
|
-
*
|
|
1512
|
-
* The **Reward Service API** is used for reward campaigns in Rehive.
|
|
1513
|
-
*
|
|
1514
|
-
*/
|
|
1515
|
-
export class Api<
|
|
1516
|
-
SecurityDataType extends unknown,
|
|
1517
|
-
> extends HttpClient<SecurityDataType> {
|
|
1518
|
-
activate = {
|
|
1519
|
-
/**
|
|
1520
|
-
* No description
|
|
1521
|
-
*
|
|
1522
|
-
* @tags activate
|
|
1523
|
-
* @name ActivateCreate
|
|
1524
|
-
* @summary Activate service
|
|
1525
|
-
* @request POST:/activate/
|
|
1526
|
-
* @secure
|
|
1527
|
-
*/
|
|
1528
|
-
activateCreate: (data: Activate, params: RequestParams = {}) =>
|
|
1529
|
-
this.request<ActivateCreateData, any>({
|
|
1530
|
-
path: `/activate/`,
|
|
1531
|
-
method: "POST",
|
|
1532
|
-
body: data,
|
|
1533
|
-
secure: true,
|
|
1534
|
-
type: ContentType.Json,
|
|
1535
|
-
format: "json",
|
|
1536
|
-
...params,
|
|
1537
|
-
}),
|
|
1538
|
-
};
|
|
1539
|
-
admin = {
|
|
1540
|
-
/**
|
|
1541
|
-
* No description
|
|
1542
|
-
*
|
|
1543
|
-
* @tags admin
|
|
1544
|
-
* @name AdminCampaignsList
|
|
1545
|
-
* @summary List campaign
|
|
1546
|
-
* @request GET:/admin/campaigns/
|
|
1547
|
-
* @secure
|
|
1548
|
-
*/
|
|
1549
|
-
adminCampaignsList: (
|
|
1550
|
-
query: AdminCampaignsListParams,
|
|
1551
|
-
params: RequestParams = {},
|
|
1552
|
-
) =>
|
|
1553
|
-
this.request<AdminCampaignsListData, any>({
|
|
1554
|
-
path: `/admin/campaigns/`,
|
|
1555
|
-
method: "GET",
|
|
1556
|
-
query: query,
|
|
1557
|
-
secure: true,
|
|
1558
|
-
format: "json",
|
|
1559
|
-
...params,
|
|
1560
|
-
}),
|
|
1561
|
-
|
|
1562
|
-
/**
|
|
1563
|
-
* No description
|
|
1564
|
-
*
|
|
1565
|
-
* @tags admin
|
|
1566
|
-
* @name AdminCampaignsCreate
|
|
1567
|
-
* @summary Create campaign
|
|
1568
|
-
* @request POST:/admin/campaigns/
|
|
1569
|
-
* @secure
|
|
1570
|
-
*/
|
|
1571
|
-
adminCampaignsCreate: (
|
|
1572
|
-
data: AdminCreateUpdateCampaign,
|
|
1573
|
-
params: RequestParams = {},
|
|
1574
|
-
) =>
|
|
1575
|
-
this.request<AdminCampaignsCreateData, any>({
|
|
1576
|
-
path: `/admin/campaigns/`,
|
|
1577
|
-
method: "POST",
|
|
1578
|
-
body: data,
|
|
1579
|
-
secure: true,
|
|
1580
|
-
type: ContentType.Json,
|
|
1581
|
-
format: "json",
|
|
1582
|
-
...params,
|
|
1583
|
-
}),
|
|
1584
|
-
|
|
1585
|
-
/**
|
|
1586
|
-
* No description
|
|
1587
|
-
*
|
|
1588
|
-
* @tags admin
|
|
1589
|
-
* @name AdminCampaignsRetrieve
|
|
1590
|
-
* @summary Retrieve campaign
|
|
1591
|
-
* @request GET:/admin/campaigns/{id}/
|
|
1592
|
-
* @secure
|
|
1593
|
-
*/
|
|
1594
|
-
adminCampaignsRetrieve: (id: string, params: RequestParams = {}) =>
|
|
1595
|
-
this.request<AdminCampaignsRetrieveData, any>({
|
|
1596
|
-
path: `/admin/campaigns/${id}/`,
|
|
1597
|
-
method: "GET",
|
|
1598
|
-
secure: true,
|
|
1599
|
-
format: "json",
|
|
1600
|
-
...params,
|
|
1601
|
-
}),
|
|
1602
|
-
|
|
1603
|
-
/**
|
|
1604
|
-
* No description
|
|
1605
|
-
*
|
|
1606
|
-
* @tags admin
|
|
1607
|
-
* @name AdminCampaignsUpdate
|
|
1608
|
-
* @summary Update campaign
|
|
1609
|
-
* @request PUT:/admin/campaigns/{id}/
|
|
1610
|
-
* @secure
|
|
1611
|
-
*/
|
|
1612
|
-
adminCampaignsUpdate: (
|
|
1613
|
-
id: string,
|
|
1614
|
-
data: AdminCreateUpdateCampaign,
|
|
1615
|
-
params: RequestParams = {},
|
|
1616
|
-
) =>
|
|
1617
|
-
this.request<AdminCampaignsUpdateData, any>({
|
|
1618
|
-
path: `/admin/campaigns/${id}/`,
|
|
1619
|
-
method: "PUT",
|
|
1620
|
-
body: data,
|
|
1621
|
-
secure: true,
|
|
1622
|
-
type: ContentType.Json,
|
|
1623
|
-
format: "json",
|
|
1624
|
-
...params,
|
|
1625
|
-
}),
|
|
1626
|
-
|
|
1627
|
-
/**
|
|
1628
|
-
* No description
|
|
1629
|
-
*
|
|
1630
|
-
* @tags admin
|
|
1631
|
-
* @name AdminCampaignsPartialUpdate
|
|
1632
|
-
* @summary Partially update campaign
|
|
1633
|
-
* @request PATCH:/admin/campaigns/{id}/
|
|
1634
|
-
* @secure
|
|
1635
|
-
*/
|
|
1636
|
-
adminCampaignsPartialUpdate: (
|
|
1637
|
-
id: string,
|
|
1638
|
-
data: PatchedAdminCreateUpdateCampaign,
|
|
1639
|
-
params: RequestParams = {},
|
|
1640
|
-
) =>
|
|
1641
|
-
this.request<AdminCampaignsPartialUpdateData, any>({
|
|
1642
|
-
path: `/admin/campaigns/${id}/`,
|
|
1643
|
-
method: "PATCH",
|
|
1644
|
-
body: data,
|
|
1645
|
-
secure: true,
|
|
1646
|
-
type: ContentType.Json,
|
|
1647
|
-
format: "json",
|
|
1648
|
-
...params,
|
|
1649
|
-
}),
|
|
1650
|
-
|
|
1651
|
-
/**
|
|
1652
|
-
* No description
|
|
1653
|
-
*
|
|
1654
|
-
* @tags admin
|
|
1655
|
-
* @name AdminCampaignsDestroy
|
|
1656
|
-
* @summary Delete campaign
|
|
1657
|
-
* @request DELETE:/admin/campaigns/{id}/
|
|
1658
|
-
* @secure
|
|
1659
|
-
*/
|
|
1660
|
-
adminCampaignsDestroy: (id: string, params: RequestParams = {}) =>
|
|
1661
|
-
this.request<AdminCampaignsDestroyData, any>({
|
|
1662
|
-
path: `/admin/campaigns/${id}/`,
|
|
1663
|
-
method: "DELETE",
|
|
1664
|
-
secure: true,
|
|
1665
|
-
format: "json",
|
|
1666
|
-
...params,
|
|
1667
|
-
}),
|
|
1668
|
-
|
|
1669
|
-
/**
|
|
1670
|
-
* No description
|
|
1671
|
-
*
|
|
1672
|
-
* @tags admin
|
|
1673
|
-
* @name AdminCompanyRetrieve
|
|
1674
|
-
* @summary Retrieve company
|
|
1675
|
-
* @request GET:/admin/company/
|
|
1676
|
-
* @secure
|
|
1677
|
-
*/
|
|
1678
|
-
adminCompanyRetrieve: (params: RequestParams = {}) =>
|
|
1679
|
-
this.request<AdminCompanyRetrieveData, any>({
|
|
1680
|
-
path: `/admin/company/`,
|
|
1681
|
-
method: "GET",
|
|
1682
|
-
secure: true,
|
|
1683
|
-
format: "json",
|
|
1684
|
-
...params,
|
|
1685
|
-
}),
|
|
1686
|
-
|
|
1687
|
-
/**
|
|
1688
|
-
* No description
|
|
1689
|
-
*
|
|
1690
|
-
* @tags admin
|
|
1691
|
-
* @name AdminCompanyUpdate
|
|
1692
|
-
* @summary Update company
|
|
1693
|
-
* @request PUT:/admin/company/
|
|
1694
|
-
* @secure
|
|
1695
|
-
*/
|
|
1696
|
-
adminCompanyUpdate: (data: AdminCompany, params: RequestParams = {}) =>
|
|
1697
|
-
this.request<AdminCompanyUpdateData, any>({
|
|
1698
|
-
path: `/admin/company/`,
|
|
1699
|
-
method: "PUT",
|
|
1700
|
-
body: data,
|
|
1701
|
-
secure: true,
|
|
1702
|
-
type: ContentType.Json,
|
|
1703
|
-
format: "json",
|
|
1704
|
-
...params,
|
|
1705
|
-
}),
|
|
1706
|
-
|
|
1707
|
-
/**
|
|
1708
|
-
* No description
|
|
1709
|
-
*
|
|
1710
|
-
* @tags admin
|
|
1711
|
-
* @name AdminCompanyPartialUpdate
|
|
1712
|
-
* @summary Partially update company
|
|
1713
|
-
* @request PATCH:/admin/company/
|
|
1714
|
-
* @secure
|
|
1715
|
-
*/
|
|
1716
|
-
adminCompanyPartialUpdate: (
|
|
1717
|
-
data: PatchedAdminCompany,
|
|
1718
|
-
params: RequestParams = {},
|
|
1719
|
-
) =>
|
|
1720
|
-
this.request<AdminCompanyPartialUpdateData, any>({
|
|
1721
|
-
path: `/admin/company/`,
|
|
1722
|
-
method: "PATCH",
|
|
1723
|
-
body: data,
|
|
1724
|
-
secure: true,
|
|
1725
|
-
type: ContentType.Json,
|
|
1726
|
-
format: "json",
|
|
1727
|
-
...params,
|
|
1728
|
-
}),
|
|
1729
|
-
|
|
1730
|
-
/**
|
|
1731
|
-
* No description
|
|
1732
|
-
*
|
|
1733
|
-
* @tags admin
|
|
1734
|
-
* @name AdminCurrenciesList
|
|
1735
|
-
* @summary List currencies
|
|
1736
|
-
* @request GET:/admin/currencies/
|
|
1737
|
-
* @secure
|
|
1738
|
-
*/
|
|
1739
|
-
adminCurrenciesList: (
|
|
1740
|
-
query: AdminCurrenciesListParams,
|
|
1741
|
-
params: RequestParams = {},
|
|
1742
|
-
) =>
|
|
1743
|
-
this.request<AdminCurrenciesListData, any>({
|
|
1744
|
-
path: `/admin/currencies/`,
|
|
1745
|
-
method: "GET",
|
|
1746
|
-
query: query,
|
|
1747
|
-
secure: true,
|
|
1748
|
-
format: "json",
|
|
1749
|
-
...params,
|
|
1750
|
-
}),
|
|
1751
|
-
|
|
1752
|
-
/**
|
|
1753
|
-
* No description
|
|
1754
|
-
*
|
|
1755
|
-
* @tags admin
|
|
1756
|
-
* @name AdminCurrenciesRetrieve
|
|
1757
|
-
* @summary Retrieve currency
|
|
1758
|
-
* @request GET:/admin/currencies/{code}/
|
|
1759
|
-
* @secure
|
|
1760
|
-
*/
|
|
1761
|
-
adminCurrenciesRetrieve: (code: string, params: RequestParams = {}) =>
|
|
1762
|
-
this.request<AdminCurrenciesRetrieveData, any>({
|
|
1763
|
-
path: `/admin/currencies/${code}/`,
|
|
1764
|
-
method: "GET",
|
|
1765
|
-
secure: true,
|
|
1766
|
-
format: "json",
|
|
1767
|
-
...params,
|
|
1768
|
-
}),
|
|
1769
|
-
|
|
1770
|
-
/**
|
|
1771
|
-
* No description
|
|
1772
|
-
*
|
|
1773
|
-
* @tags admin
|
|
1774
|
-
* @name AdminRewardsList
|
|
1775
|
-
* @summary List rewards
|
|
1776
|
-
* @request GET:/admin/rewards/
|
|
1777
|
-
* @secure
|
|
1778
|
-
*/
|
|
1779
|
-
adminRewardsList: (
|
|
1780
|
-
query: AdminRewardsListParams,
|
|
1781
|
-
params: RequestParams = {},
|
|
1782
|
-
) =>
|
|
1783
|
-
this.request<AdminRewardsListData, any>({
|
|
1784
|
-
path: `/admin/rewards/`,
|
|
1785
|
-
method: "GET",
|
|
1786
|
-
query: query,
|
|
1787
|
-
secure: true,
|
|
1788
|
-
format: "json",
|
|
1789
|
-
...params,
|
|
1790
|
-
}),
|
|
1791
|
-
|
|
1792
|
-
/**
|
|
1793
|
-
* No description
|
|
1794
|
-
*
|
|
1795
|
-
* @tags admin
|
|
1796
|
-
* @name AdminRewardsCreate
|
|
1797
|
-
* @summary Create reward
|
|
1798
|
-
* @request POST:/admin/rewards/
|
|
1799
|
-
* @secure
|
|
1800
|
-
*/
|
|
1801
|
-
adminRewardsCreate: (data: AdminCreateReward, params: RequestParams = {}) =>
|
|
1802
|
-
this.request<AdminRewardsCreateData, any>({
|
|
1803
|
-
path: `/admin/rewards/`,
|
|
1804
|
-
method: "POST",
|
|
1805
|
-
body: data,
|
|
1806
|
-
secure: true,
|
|
1807
|
-
type: ContentType.Json,
|
|
1808
|
-
format: "json",
|
|
1809
|
-
...params,
|
|
1810
|
-
}),
|
|
1811
|
-
|
|
1812
|
-
/**
|
|
1813
|
-
* No description
|
|
1814
|
-
*
|
|
1815
|
-
* @tags admin
|
|
1816
|
-
* @name AdminRewardsRetrieve
|
|
1817
|
-
* @summary Retrieve reward
|
|
1818
|
-
* @request GET:/admin/rewards/{id}/
|
|
1819
|
-
* @secure
|
|
1820
|
-
*/
|
|
1821
|
-
adminRewardsRetrieve: (id: string, params: RequestParams = {}) =>
|
|
1822
|
-
this.request<AdminRewardsRetrieveData, any>({
|
|
1823
|
-
path: `/admin/rewards/${id}/`,
|
|
1824
|
-
method: "GET",
|
|
1825
|
-
secure: true,
|
|
1826
|
-
format: "json",
|
|
1827
|
-
...params,
|
|
1828
|
-
}),
|
|
1829
|
-
|
|
1830
|
-
/**
|
|
1831
|
-
* No description
|
|
1832
|
-
*
|
|
1833
|
-
* @tags admin
|
|
1834
|
-
* @name AdminRewardsUpdate
|
|
1835
|
-
* @summary Update reward
|
|
1836
|
-
* @request PUT:/admin/rewards/{id}/
|
|
1837
|
-
* @secure
|
|
1838
|
-
*/
|
|
1839
|
-
adminRewardsUpdate: (
|
|
1840
|
-
id: string,
|
|
1841
|
-
data: AdminReward,
|
|
1842
|
-
params: RequestParams = {},
|
|
1843
|
-
) =>
|
|
1844
|
-
this.request<AdminRewardsUpdateData, any>({
|
|
1845
|
-
path: `/admin/rewards/${id}/`,
|
|
1846
|
-
method: "PUT",
|
|
1847
|
-
body: data,
|
|
1848
|
-
secure: true,
|
|
1849
|
-
type: ContentType.Json,
|
|
1850
|
-
format: "json",
|
|
1851
|
-
...params,
|
|
1852
|
-
}),
|
|
1853
|
-
|
|
1854
|
-
/**
|
|
1855
|
-
* No description
|
|
1856
|
-
*
|
|
1857
|
-
* @tags admin
|
|
1858
|
-
* @name AdminRewardsPartialUpdate
|
|
1859
|
-
* @summary Partially update reward
|
|
1860
|
-
* @request PATCH:/admin/rewards/{id}/
|
|
1861
|
-
* @secure
|
|
1862
|
-
*/
|
|
1863
|
-
adminRewardsPartialUpdate: (
|
|
1864
|
-
id: string,
|
|
1865
|
-
data: PatchedAdminReward,
|
|
1866
|
-
params: RequestParams = {},
|
|
1867
|
-
) =>
|
|
1868
|
-
this.request<AdminRewardsPartialUpdateData, any>({
|
|
1869
|
-
path: `/admin/rewards/${id}/`,
|
|
1870
|
-
method: "PATCH",
|
|
1871
|
-
body: data,
|
|
1872
|
-
secure: true,
|
|
1873
|
-
type: ContentType.Json,
|
|
1874
|
-
format: "json",
|
|
1875
|
-
...params,
|
|
1876
|
-
}),
|
|
1877
|
-
|
|
1878
|
-
/**
|
|
1879
|
-
* No description
|
|
1880
|
-
*
|
|
1881
|
-
* @tags admin
|
|
1882
|
-
* @name AdminUsersList
|
|
1883
|
-
* @summary List users
|
|
1884
|
-
* @request GET:/admin/users/
|
|
1885
|
-
* @secure
|
|
1886
|
-
*/
|
|
1887
|
-
adminUsersList: (query: AdminUsersListParams, params: RequestParams = {}) =>
|
|
1888
|
-
this.request<AdminUsersListData, any>({
|
|
1889
|
-
path: `/admin/users/`,
|
|
1890
|
-
method: "GET",
|
|
1891
|
-
query: query,
|
|
1892
|
-
secure: true,
|
|
1893
|
-
format: "json",
|
|
1894
|
-
...params,
|
|
1895
|
-
}),
|
|
1896
|
-
|
|
1897
|
-
/**
|
|
1898
|
-
* No description
|
|
1899
|
-
*
|
|
1900
|
-
* @tags admin
|
|
1901
|
-
* @name AdminUsersRetrieve
|
|
1902
|
-
* @summary Retrieve user
|
|
1903
|
-
* @request GET:/admin/users/{id}/
|
|
1904
|
-
* @secure
|
|
1905
|
-
*/
|
|
1906
|
-
adminUsersRetrieve: (id: string, params: RequestParams = {}) =>
|
|
1907
|
-
this.request<AdminUsersRetrieveData, any>({
|
|
1908
|
-
path: `/admin/users/${id}/`,
|
|
1909
|
-
method: "GET",
|
|
1910
|
-
secure: true,
|
|
1911
|
-
format: "json",
|
|
1912
|
-
...params,
|
|
1913
|
-
}),
|
|
1914
|
-
|
|
1915
|
-
/**
|
|
1916
|
-
* No description
|
|
1917
|
-
*
|
|
1918
|
-
* @tags admin
|
|
1919
|
-
* @name AdminWebhookCreate
|
|
1920
|
-
* @summary Receive Platform webhook
|
|
1921
|
-
* @request POST:/admin/webhook/
|
|
1922
|
-
* @secure
|
|
1923
|
-
*/
|
|
1924
|
-
adminWebhookCreate: (data: Webhook, params: RequestParams = {}) =>
|
|
1925
|
-
this.request<AdminWebhookCreateData, any>({
|
|
1926
|
-
path: `/admin/webhook/`,
|
|
1927
|
-
method: "POST",
|
|
1928
|
-
body: data,
|
|
1929
|
-
secure: true,
|
|
1930
|
-
type: ContentType.Json,
|
|
1931
|
-
format: "json",
|
|
1932
|
-
...params,
|
|
1933
|
-
}),
|
|
1934
|
-
};
|
|
1935
|
-
deactivate = {
|
|
1936
|
-
/**
|
|
1937
|
-
* No description
|
|
1938
|
-
*
|
|
1939
|
-
* @tags deactivate
|
|
1940
|
-
* @name DeactivateCreate
|
|
1941
|
-
* @summary Deactivate service
|
|
1942
|
-
* @request POST:/deactivate/
|
|
1943
|
-
* @secure
|
|
1944
|
-
*/
|
|
1945
|
-
deactivateCreate: (data: Deactivate, params: RequestParams = {}) =>
|
|
1946
|
-
this.request<DeactivateCreateData, any>({
|
|
1947
|
-
path: `/deactivate/`,
|
|
1948
|
-
method: "POST",
|
|
1949
|
-
body: data,
|
|
1950
|
-
secure: true,
|
|
1951
|
-
type: ContentType.Json,
|
|
1952
|
-
format: "json",
|
|
1953
|
-
...params,
|
|
1954
|
-
}),
|
|
1955
|
-
};
|
|
1956
|
-
user = {
|
|
1957
|
-
/**
|
|
1958
|
-
* No description
|
|
1959
|
-
*
|
|
1960
|
-
* @tags user
|
|
1961
|
-
* @name UserRetrieve
|
|
1962
|
-
* @summary Retrieve user
|
|
1963
|
-
* @request GET:/user/
|
|
1964
|
-
* @secure
|
|
1965
|
-
*/
|
|
1966
|
-
userRetrieve: (params: RequestParams = {}) =>
|
|
1967
|
-
this.request<UserRetrieveData, any>({
|
|
1968
|
-
path: `/user/`,
|
|
1969
|
-
method: "GET",
|
|
1970
|
-
secure: true,
|
|
1971
|
-
format: "json",
|
|
1972
|
-
...params,
|
|
1973
|
-
}),
|
|
1974
|
-
|
|
1975
|
-
/**
|
|
1976
|
-
* No description
|
|
1977
|
-
*
|
|
1978
|
-
* @tags user
|
|
1979
|
-
* @name UserUpdate
|
|
1980
|
-
* @summary Update user
|
|
1981
|
-
* @request PUT:/user/
|
|
1982
|
-
* @secure
|
|
1983
|
-
*/
|
|
1984
|
-
userUpdate: (data: UserUpdateReferral, params: RequestParams = {}) =>
|
|
1985
|
-
this.request<UserUpdateData, any>({
|
|
1986
|
-
path: `/user/`,
|
|
1987
|
-
method: "PUT",
|
|
1988
|
-
body: data,
|
|
1989
|
-
secure: true,
|
|
1990
|
-
type: ContentType.Json,
|
|
1991
|
-
format: "json",
|
|
1992
|
-
...params,
|
|
1993
|
-
}),
|
|
1994
|
-
|
|
1995
|
-
/**
|
|
1996
|
-
* No description
|
|
1997
|
-
*
|
|
1998
|
-
* @tags user
|
|
1999
|
-
* @name UserPartialUpdate
|
|
2000
|
-
* @summary Partially update user
|
|
2001
|
-
* @request PATCH:/user/
|
|
2002
|
-
* @secure
|
|
2003
|
-
*/
|
|
2004
|
-
userPartialUpdate: (
|
|
2005
|
-
data: PatchedUserUpdateReferral,
|
|
2006
|
-
params: RequestParams = {},
|
|
2007
|
-
) =>
|
|
2008
|
-
this.request<UserPartialUpdateData, any>({
|
|
2009
|
-
path: `/user/`,
|
|
2010
|
-
method: "PATCH",
|
|
2011
|
-
body: data,
|
|
2012
|
-
secure: true,
|
|
2013
|
-
type: ContentType.Json,
|
|
2014
|
-
format: "json",
|
|
2015
|
-
...params,
|
|
2016
|
-
}),
|
|
2017
|
-
|
|
2018
|
-
/**
|
|
2019
|
-
* No description
|
|
2020
|
-
*
|
|
2021
|
-
* @tags user
|
|
2022
|
-
* @name UserCampaignsList
|
|
2023
|
-
* @summary List campaigns
|
|
2024
|
-
* @request GET:/user/campaigns/
|
|
2025
|
-
* @secure
|
|
2026
|
-
*/
|
|
2027
|
-
userCampaignsList: (
|
|
2028
|
-
query: UserCampaignsListParams,
|
|
2029
|
-
params: RequestParams = {},
|
|
2030
|
-
) =>
|
|
2031
|
-
this.request<UserCampaignsListData, any>({
|
|
2032
|
-
path: `/user/campaigns/`,
|
|
2033
|
-
method: "GET",
|
|
2034
|
-
query: query,
|
|
2035
|
-
secure: true,
|
|
2036
|
-
format: "json",
|
|
2037
|
-
...params,
|
|
2038
|
-
}),
|
|
2039
|
-
|
|
2040
|
-
/**
|
|
2041
|
-
* No description
|
|
2042
|
-
*
|
|
2043
|
-
* @tags user
|
|
2044
|
-
* @name UserCampaignsRetrieve
|
|
2045
|
-
* @summary Retrieve campaign
|
|
2046
|
-
* @request GET:/user/campaigns/{id}/
|
|
2047
|
-
* @secure
|
|
2048
|
-
*/
|
|
2049
|
-
userCampaignsRetrieve: (id: string, params: RequestParams = {}) =>
|
|
2050
|
-
this.request<UserCampaignsRetrieveData, any>({
|
|
2051
|
-
path: `/user/campaigns/${id}/`,
|
|
2052
|
-
method: "GET",
|
|
2053
|
-
secure: true,
|
|
2054
|
-
format: "json",
|
|
2055
|
-
...params,
|
|
2056
|
-
}),
|
|
2057
|
-
|
|
2058
|
-
/**
|
|
2059
|
-
* No description
|
|
2060
|
-
*
|
|
2061
|
-
* @tags user
|
|
2062
|
-
* @name UserRewardsList
|
|
2063
|
-
* @summary List rewards
|
|
2064
|
-
* @request GET:/user/rewards/
|
|
2065
|
-
* @secure
|
|
2066
|
-
*/
|
|
2067
|
-
userRewardsList: (
|
|
2068
|
-
query: UserRewardsListParams,
|
|
2069
|
-
params: RequestParams = {},
|
|
2070
|
-
) =>
|
|
2071
|
-
this.request<UserRewardsListData, any>({
|
|
2072
|
-
path: `/user/rewards/`,
|
|
2073
|
-
method: "GET",
|
|
2074
|
-
query: query,
|
|
2075
|
-
secure: true,
|
|
2076
|
-
format: "json",
|
|
2077
|
-
...params,
|
|
2078
|
-
}),
|
|
2079
|
-
|
|
2080
|
-
/**
|
|
2081
|
-
* No description
|
|
2082
|
-
*
|
|
2083
|
-
* @tags user
|
|
2084
|
-
* @name UserRewardsCreate
|
|
2085
|
-
* @summary Create reward
|
|
2086
|
-
* @request POST:/user/rewards/
|
|
2087
|
-
* @secure
|
|
2088
|
-
*/
|
|
2089
|
-
userRewardsCreate: (data: UserCreateReward, params: RequestParams = {}) =>
|
|
2090
|
-
this.request<UserRewardsCreateData, any>({
|
|
2091
|
-
path: `/user/rewards/`,
|
|
2092
|
-
method: "POST",
|
|
2093
|
-
body: data,
|
|
2094
|
-
secure: true,
|
|
2095
|
-
type: ContentType.Json,
|
|
2096
|
-
format: "json",
|
|
2097
|
-
...params,
|
|
2098
|
-
}),
|
|
2099
|
-
|
|
2100
|
-
/**
|
|
2101
|
-
* No description
|
|
2102
|
-
*
|
|
2103
|
-
* @tags user
|
|
2104
|
-
* @name UserRewardsRetrieve
|
|
2105
|
-
* @summary Retrieve user
|
|
2106
|
-
* @request GET:/user/rewards/{id}/
|
|
2107
|
-
* @secure
|
|
2108
|
-
*/
|
|
2109
|
-
userRewardsRetrieve: (id: string, params: RequestParams = {}) =>
|
|
2110
|
-
this.request<UserRewardsRetrieveData, any>({
|
|
2111
|
-
path: `/user/rewards/${id}/`,
|
|
2112
|
-
method: "GET",
|
|
2113
|
-
secure: true,
|
|
2114
|
-
format: "json",
|
|
2115
|
-
...params,
|
|
2116
|
-
}),
|
|
2117
|
-
};
|
|
2118
|
-
webhook = {
|
|
2119
|
-
/**
|
|
2120
|
-
* No description
|
|
2121
|
-
*
|
|
2122
|
-
* @tags webhook
|
|
2123
|
-
* @name WebhookCreate
|
|
2124
|
-
* @summary Receive Platform webhook
|
|
2125
|
-
* @request POST:/webhook/
|
|
2126
|
-
* @secure
|
|
2127
|
-
*/
|
|
2128
|
-
webhookCreate: (data: Webhook, params: RequestParams = {}) =>
|
|
2129
|
-
this.request<WebhookCreateData, any>({
|
|
2130
|
-
path: `/webhook/`,
|
|
2131
|
-
method: "POST",
|
|
2132
|
-
body: data,
|
|
2133
|
-
secure: true,
|
|
2134
|
-
type: ContentType.Json,
|
|
2135
|
-
format: "json",
|
|
2136
|
-
...params,
|
|
2137
|
-
}),
|
|
2138
|
-
};
|
|
2139
|
-
}
|