2
0

Add usage-based new pricing plans

This commit is contained in:
Baptiste Arnaud
2022-09-17 16:37:33 +02:00
committed by Baptiste Arnaud
parent 6a1eaea700
commit 898367a33b
144 changed files with 4631 additions and 1624 deletions

View File

@ -19,7 +19,19 @@ export const useWorkspaces = ({ userId }: { userId?: string }) => {
}
export const createNewWorkspace = async (
body: Omit<Workspace, 'id' | 'icon' | 'createdAt' | 'stripeId'>
body: Omit<
Workspace,
| 'id'
| 'icon'
| 'createdAt'
| 'stripeId'
| 'additionalChatsIndex'
| 'additionalStorageIndex'
| 'chatsLimitFirstEmailSentAt'
| 'chatsLimitSecondEmailSentAt'
| 'storageLimitFirstEmailSentAt'
| 'storageLimitSecondEmailSentAt'
>
) =>
sendRequest<{
workspace: Workspace
@ -57,8 +69,6 @@ export const planToReadable = (plan?: Plan) => {
return 'Offered'
case Plan.PRO:
return 'Pro'
case Plan.TEAM:
return 'Team'
}
}