feat(medusa, types, core-flows): Add invite endpoints for api-v2 (#6395)

**What**
- Add invite endpoints for simple operations on invites
This commit is contained in:
Philip Korsholm
2024-02-14 23:33:26 +08:00
committed by GitHub
parent 1ed5f918c3
commit 02c53ec93f
26 changed files with 649 additions and 9 deletions
-2
View File
@@ -12,8 +12,6 @@ export interface UpdateUserDTO extends Partial<Omit<CreateUserDTO, "email">> {
export interface CreateInviteDTO {
email: string
accepted?: boolean
token: string
expires_at: Date
metadata?: Record<string, unknown> | null
}
+1
View File
@@ -4,3 +4,4 @@ export * as ProductWorkflow from "./product"
export * as InventoryWorkflow from "./inventory"
export * as PriceListWorkflow from "./price-list"
export * as UserWorkflow from "./user"
export * as InviteWorkflow from "./invite"
@@ -0,0 +1,5 @@
import { CreateInviteDTO } from "../../user"
export interface CreateInvitesWorkflowInputDTO {
invites: CreateInviteDTO[]
}
@@ -0,0 +1,3 @@
export interface DeleteInvitesWorkflowInput {
ids: string[]
}
@@ -0,0 +1,3 @@
export * from "./create-invite"
export * from "./update-invite"
export * from "./delete-invite"
@@ -0,0 +1,5 @@
import { UpdateInviteDTO } from "../../user"
export interface UpdateInvitesWorkflowInputDTO {
updates: UpdateInviteDTO[]
}